From b271012d04897f788866760c1dea7d51b1b44a4d Mon Sep 17 00:00:00 2001 From: Dan Gudmundsson Date: Wed, 28 Sep 2016 13:08:10 +0200 Subject: wx: Add simple dropfiles support Added wxDropFiles event --- lib/wx/c_src/gen/wxe_funcs.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'lib/wx/c_src/gen/wxe_funcs.cpp') diff --git a/lib/wx/c_src/gen/wxe_funcs.cpp b/lib/wx/c_src/gen/wxe_funcs.cpp index 4243d8a35a..610b0a2558 100644 --- a/lib/wx/c_src/gen/wxe_funcs.cpp +++ b/lib/wx/c_src/gen/wxe_funcs.cpp @@ -32048,6 +32048,28 @@ case wxDCOverlay_Clear: { // wxDCOverlay::Clear if(!This) throw wxe_badarg(0); This->Clear(); break; +} +case wxDropFilesEvent_GetPosition: { // wxDropFilesEvent::GetPosition + wxDropFilesEvent *This = (wxDropFilesEvent *) getPtr(bp,memenv); bp += 4; + if(!This) throw wxe_badarg(0); + wxPoint Result = This->GetPosition(); + rt.add(Result); + break; +} +case wxDropFilesEvent_GetNumberOfFiles: { // wxDropFilesEvent::GetNumberOfFiles + wxDropFilesEvent *This = (wxDropFilesEvent *) getPtr(bp,memenv); bp += 4; + if(!This) throw wxe_badarg(0); + int Result = This->GetNumberOfFiles(); + rt.addInt(Result); + break; +} +case wxDropFilesEvent_GetFiles: { // wxDropFilesEvent::GetFiles + wxDropFilesEvent *This = (wxDropFilesEvent *) getPtr(bp,memenv); bp += 4; + if(!This) throw wxe_badarg(0); + wxString * Result = (wxString*)This->GetFiles(); + wxArrayString tmpArrayStr(This->m_noFiles, Result); + rt.add(tmpArrayStr); + break; } default: { wxeReturn error = wxeReturn(WXE_DRV_PORT, Ecmd.caller, false); error.addAtom("_wxe_error_"); -- cgit v1.2.3 From b8339d7edf63c8745be4be092e63f46bc4e63b91 Mon Sep 17 00:00:00 2001 From: Dan Gudmundsson Date: Wed, 28 Sep 2016 13:13:20 +0200 Subject: wx: add wxWindowDragAcceptFiles Enable window to handle drop file events. --- lib/wx/c_src/gen/wxe_funcs.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'lib/wx/c_src/gen/wxe_funcs.cpp') diff --git a/lib/wx/c_src/gen/wxe_funcs.cpp b/lib/wx/c_src/gen/wxe_funcs.cpp index 610b0a2558..927528fb32 100644 --- a/lib/wx/c_src/gen/wxe_funcs.cpp +++ b/lib/wx/c_src/gen/wxe_funcs.cpp @@ -315,6 +315,15 @@ case wxWindow_Disable: { // wxWindow::Disable rt.addBool(Result); break; } +#if wxCHECK_VERSION(2,8,10) +case wxWindow_DragAcceptFiles: { // wxWindow::DragAcceptFiles + wxWindow *This = (wxWindow *) getPtr(bp,memenv); bp += 4; + bool * accept = (bool *) bp; bp += 4; + if(!This) throw wxe_badarg(0); + This->DragAcceptFiles(*accept); + break; +} +#endif case wxWindow_Enable: { // wxWindow::Enable bool enable=true; wxWindow *This = (wxWindow *) getPtr(bp,memenv); bp += 4; -- cgit v1.2.3