1999-01-13 09:23:31 -05:00
|
|
|
\section{\class{wxDropTarget}}\label{wxdroptarget}
|
|
|
|
|
|
|
|
\overview{Overview}{wxdndoverview}
|
|
|
|
|
|
|
|
This class represents a target for a drag and drop operation.
|
|
|
|
|
|
|
|
\wxheading{Derived from}
|
|
|
|
|
|
|
|
\helpref{wxObject}{wxobject}
|
|
|
|
|
1999-02-15 15:41:29 -05:00
|
|
|
\wxheading{Include files}
|
|
|
|
|
|
|
|
<wx/dnd.h>
|
|
|
|
|
1999-01-13 09:23:31 -05:00
|
|
|
\wxheading{See also}
|
|
|
|
|
|
|
|
\helpref{Drag and drop overview}{wxdndoverview}, \helpref{wxDropSource}{wxdropsource},
|
|
|
|
\helpref{wxTextDropTarget}{wxtextdroptarget}, \helpref{wxFileDropTarget}{wxfiledroptarget}
|
|
|
|
|
|
|
|
\latexignore{\rtfignore{\wxheading{Members}}}
|
|
|
|
|
|
|
|
\membersection{wxDropTarget::wxDropTarget}\label{wxdroptargetwxdroptarget}
|
|
|
|
|
|
|
|
\func{}{wxDropTarget}{\void}
|
|
|
|
|
|
|
|
Constructor.
|
|
|
|
|
|
|
|
\membersection{wxDropTarget::\destruct{wxDropTarget}}\label{wxdroptargetdtor}
|
|
|
|
|
|
|
|
\func{}{\destruct{wxDropTarget}}{\void}
|
|
|
|
|
|
|
|
Destructor.
|
|
|
|
|
|
|
|
\membersection{wxDropTarget::GetFormatCount}\label{wxdroptargetgetformatcount}
|
|
|
|
|
|
|
|
\constfunc{virtual size\_t}{GetFormatCount}{\void}
|
|
|
|
|
|
|
|
Override this to indicate how many formats you support.
|
|
|
|
|
|
|
|
\membersection{wxDropTarget::GetFormat}\label{wxdroptargetgetformat}
|
|
|
|
|
|
|
|
\constfunc{virtual wxDataFormat}{GetFormat}{\param{size\_t }{n}}
|
|
|
|
|
|
|
|
Override this to indicate what kind of data you support.
|
|
|
|
|
1999-11-02 09:04:44 -05:00
|
|
|
\membersection{wxDropTarget::OnData}\label{wxdroptargetondata}
|
1999-01-13 09:23:31 -05:00
|
|
|
|
1999-11-02 09:04:44 -05:00
|
|
|
\func{virtual wxDragResult}{OnData}{\param{wxCoord}{ x}, \param{wxCoord}{ y}, \param{wxDragResult}{ def}}
|
1999-01-13 09:23:31 -05:00
|
|
|
|
1999-11-02 09:04:44 -05:00
|
|
|
Called after OnDrop() returns TRUE: you will usually just call
|
|
|
|
GetData() from here and, probably, also refresh something to update the
|
|
|
|
new data and, finally, return the code indicating how did the operation
|
|
|
|
complete (returning default value in case of success and wxDragError on
|
|
|
|
failure is usually ok).
|
1999-01-13 09:23:31 -05:00
|
|
|
|
|
|
|
\membersection{wxDropTarget::OnDrop}\label{wxdroptargetondrop}
|
|
|
|
|
|
|
|
\func{virtual bool}{OnDrop}{\param{long }{x}, \param{long }{y}, \param{const void* }{data}, \param{size\_t }{size}}
|
|
|
|
|
|
|
|
Called when the user drops a data object on the target. Return FALSE to veto the operation.
|
|
|
|
|
|
|
|
\wxheading{Parameters}
|
|
|
|
|
|
|
|
\docparam{x}{The x coordinate of the mouse.}
|
|
|
|
|
|
|
|
\docparam{y}{The y coordinate of the mouse.}
|
|
|
|
|
|
|
|
\docparam{data}{The data being dropped.}
|
|
|
|
|
|
|
|
\docparam{size}{The size of the data being dropped.}
|
|
|
|
|
|
|
|
\wxheading{Return value}
|
|
|
|
|
|
|
|
Return TRUE to accept the data, FALSE to veto the operation.
|
|
|
|
|
1999-11-02 09:04:44 -05:00
|
|
|
\membersection{wxDropTarget::OnEnter}\label{wxdroptargetonenter}
|
|
|
|
|
|
|
|
\func{virtual void}{OnEnter}{\void}
|
|
|
|
|
|
|
|
Called when the mouse enters the drop target.
|
|
|
|
|
1999-01-13 09:23:31 -05:00
|
|
|
\membersection{wxDropTarget::OnLeave}\label{wxdroptargetonleave}
|
|
|
|
|
|
|
|
\func{virtual void}{OnLeave}{\void}
|
|
|
|
|
|
|
|
Called when the mouse leaves the drop target.
|
1999-01-17 14:25:06 -05:00
|
|
|
|