]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/droptrgt.tex
DnD feedback
[wxWidgets.git] / docs / latex / wx / droptrgt.tex
1 \section{\class{wxDropTarget}}\label{wxdroptarget}
2
3 \overview{Overview}{wxdndoverview}
4
5 This class represents a target for a drag and drop operation.
6
7 \wxheading{Derived from}
8
9 \helpref{wxObject}{wxobject}
10
11 \wxheading{See also}
12
13 \helpref{Drag and drop overview}{wxdndoverview}, \helpref{wxDropSource}{wxdropsource},
14 \helpref{wxTextDropTarget}{wxtextdroptarget}, \helpref{wxFileDropTarget}{wxfiledroptarget}
15
16 \latexignore{\rtfignore{\wxheading{Members}}}
17
18 \membersection{wxDropTarget::wxDropTarget}\label{wxdroptargetwxdroptarget}
19
20 \func{}{wxDropTarget}{\void}
21
22 Constructor.
23
24 \membersection{wxDropTarget::\destruct{wxDropTarget}}\label{wxdroptargetdtor}
25
26 \func{}{\destruct{wxDropTarget}}{\void}
27
28 Destructor.
29
30 \membersection{wxDropTarget::GetFormatCount}\label{wxdroptargetgetformatcount}
31
32 \constfunc{virtual size\_t}{GetFormatCount}{\void}
33
34 Override this to indicate how many formats you support.
35
36 \membersection{wxDropTarget::GetFormat}\label{wxdroptargetgetformat}
37
38 \constfunc{virtual wxDataFormat}{GetFormat}{\param{size\_t }{n}}
39
40 Override this to indicate what kind of data you support.
41
42 \membersection{wxDropTarget::OnEnter}\label{wxdroptargetonenter}
43
44 \func{virtual void}{OnEnter}{\void}
45
46 Called when the mouse enters the drop target.
47
48 \membersection{wxDropTarget::OnDrop}\label{wxdroptargetondrop}
49
50 \func{virtual bool}{OnDrop}{\param{long }{x}, \param{long }{y}, \param{const void* }{data}, \param{size\_t }{size}}
51
52 Called when the user drops a data object on the target. Return FALSE to veto the operation.
53
54 \wxheading{Parameters}
55
56 \docparam{x}{The x coordinate of the mouse.}
57
58 \docparam{y}{The y coordinate of the mouse.}
59
60 \docparam{data}{The data being dropped.}
61
62 \docparam{size}{The size of the data being dropped.}
63
64 \wxheading{Return value}
65
66 Return TRUE to accept the data, FALSE to veto the operation.
67
68 \membersection{wxDropTarget::OnLeave}\label{wxdroptargetonleave}
69
70 \func{virtual void}{OnLeave}{\void}
71
72 Called when the mouse leaves the drop target.