[go: up one dir, main page]

Menu

[96b3e1]: / dragndrop.h  Maximize  Restore  History

Download this file

44 lines (33 with data), 901 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/////////////////////////////////////////////////////////////////////////////////
// Author: Steven Lamerton
// Copyright: Copyright (C) 2007-2009 Steven Lamerton
// License: GNU GPL 2 (See readme for more info)
/////////////////////////////////////////////////////////////////////////////////
#ifndef H_DRAGNDROP
#define H_DRAGNDROP
class DirCtrl;
class wxTextCtrl;
#include <wx/dnd.h>
class DnDFileTree : public wxFileDropTarget
{
public:
DnDFileTree(DirCtrl *tree) {
m_Tree = tree;
}
bool OnDropFiles(wxCoord x, wxCoord y, const wxArrayString& arrFilenames);
private:
DirCtrl *m_Tree;
};
class DnDFileTreeText : public wxFileDropTarget
{
public:
DnDFileTreeText(wxTextCtrl *text, DirCtrl *tree) {
m_Text = text;
m_Tree = tree;
}
bool OnDropFiles(wxCoord x, wxCoord y, const wxArrayString& arrFilenames);
private:
wxTextCtrl *m_Text;
DirCtrl *m_Tree;
};
#endif