Accept multiple data formats via drag-and-drop in wxDataViewCtrl
Allow specifying multiple formats to be accepted when dragging data to wxDataViewCtrl in the generic and Cocoa implementations. Add wxDataViewCtrlBase::EnableDropTarget() overload taking an array of wxDataFormats to support this at the API level. Add new DoEnableDropTarget() used by both EnableDropTarget() overloads and implement it in the generic and Cocoa ports. GTK implementation still uses only a single format, as before. Also refactor the Cocoa implementation: all operations using dragged data are now handled by wxDropTarget and unnecessary DataViewPboardType as removed. Update the dataview sample to show the new functionality.
This commit is contained in:
@@ -166,7 +166,7 @@ public:
|
||||
virtual bool IsExpanded( const wxDataViewItem & item ) const wxOVERRIDE;
|
||||
|
||||
virtual bool EnableDragSource( const wxDataFormat &format ) wxOVERRIDE;
|
||||
virtual bool EnableDropTarget( const wxDataFormat &format ) wxOVERRIDE;
|
||||
virtual bool DoEnableDropTarget( const wxDataFormatArray& formats ) wxOVERRIDE;
|
||||
|
||||
virtual wxDataViewColumn *GetCurrentColumn() const wxOVERRIDE;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user