1. wxDropTarget::OnData() returns wxDragResult now, not bool
2. fixed assert failure in wxMSW::wxListBox 3. wxFileHistory automatically deletes non existinf files from menu 4. wxDropTarget coordinates are client (and not screen) under MSW too 5. wxConvertBitmapToDib and vice versa seem to work! 6. client data field if filled by wxListBox and wxChoice and it's also deleted (this just wasn't done before!) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4153 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -44,10 +44,10 @@ class wxDropTarget: public wxDropTargetBase
|
||||
{
|
||||
public:
|
||||
wxDropTarget(wxDataObject *dataObject = (wxDataObject*) NULL );
|
||||
|
||||
|
||||
virtual wxDragResult OnDragOver(wxCoord x, wxCoord y, wxDragResult def);
|
||||
virtual bool OnDrop(wxCoord x, wxCoord y);
|
||||
virtual bool OnData(wxCoord x, wxCoord y);
|
||||
virtual wxDragResult OnData(wxCoord x, wxCoord y, wxDragResult def);
|
||||
virtual bool GetData();
|
||||
|
||||
// implementation
|
||||
@@ -69,37 +69,6 @@ public:
|
||||
void SetDragTime( guint time ) { m_dragTime = time; }
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// A simple wxDropTarget derived class for text data: you only need to
|
||||
// override OnDropText() to get something working
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class wxTextDropTarget : public wxDropTarget
|
||||
{
|
||||
public:
|
||||
wxTextDropTarget();
|
||||
|
||||
virtual bool OnDropText(wxCoord x, wxCoord y, const wxString& text) = 0;
|
||||
|
||||
virtual bool OnData(wxCoord x, wxCoord y);
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// A drop target which accepts files (dragged from File Manager or Explorer)
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class wxFileDropTarget : public wxDropTarget
|
||||
{
|
||||
public:
|
||||
wxFileDropTarget();
|
||||
|
||||
// parameters are the number of files and the array of file names
|
||||
virtual bool OnDropFiles(wxCoord x, wxCoord y,
|
||||
const wxArrayString& filenames) = 0;
|
||||
|
||||
virtual bool OnData(wxCoord x, wxCoord y);
|
||||
};
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// wxDropSource
|
||||
//-------------------------------------------------------------------------
|
||||
@@ -126,15 +95,15 @@ public:
|
||||
void UnregisterWindow();
|
||||
|
||||
void PrepareIcon( int hot_x, int hot_y, GdkDragContext *context );
|
||||
|
||||
|
||||
GtkWidget *m_widget;
|
||||
GtkWidget *m_iconWindow;
|
||||
GdkDragContext *m_dragContext;
|
||||
wxWindow *m_window;
|
||||
|
||||
|
||||
wxDragResult m_retValue;
|
||||
wxIcon m_icon;
|
||||
|
||||
|
||||
bool m_waiting;
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user