diff options
author | Daniel Wilhelm <daniel@wili.li> | 2014-04-18 17:15:39 +0200 |
---|---|---|
committer | Daniel Wilhelm <daniel@wili.li> | 2014-04-18 17:15:39 +0200 |
commit | d2854834e18443876c8f75e0a7f3b88d1d549fc4 (patch) | |
tree | e967b628081e50abc7c34cd264e6586271c7e728 /wx+/mouse_move_dlg.cpp | |
parent | 4.1 (diff) | |
download | FreeFileSync-d2854834e18443876c8f75e0a7f3b88d1d549fc4.tar.gz FreeFileSync-d2854834e18443876c8f75e0a7f3b88d1d549fc4.tar.bz2 FreeFileSync-d2854834e18443876c8f75e0a7f3b88d1d549fc4.zip |
4.2
Diffstat (limited to 'wx+/mouse_move_dlg.cpp')
-rw-r--r-- | wx+/mouse_move_dlg.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/wx+/mouse_move_dlg.cpp b/wx+/mouse_move_dlg.cpp index 3f7ca755..7edaa5db 100644 --- a/wx+/mouse_move_dlg.cpp +++ b/wx+/mouse_move_dlg.cpp @@ -14,6 +14,8 @@ #include <wx/panel.h> #include <wx/gauge.h> #include <wx/statusbr.h> +#include <wx/frame.h> +#include <wx/dialog.h> using namespace zen; @@ -35,7 +37,7 @@ void forEachChild(wxWindow& parent, Fun f) MouseMoveWindow::MouseMoveWindow(wxWindow& parent, bool includeParent) : wxWindow(&parent, wxID_ANY) { - wxObjectEventFunction memFunMouseDown = wxMouseEventHandler(MouseMoveWindow::LeftButtonDown); + wxObjectEventFunction memFunMouseDown = wxMouseEventHandler(MouseMoveWindow::LeftButtonDown); //wxWidgets macros are obviously not C++11 ready auto connect = [&](wxWindow& wnd) { if (dynamic_cast<wxStaticText*> (&wnd) || //redirect clicks on these "dead" controls to move dialog instead @@ -44,8 +46,10 @@ MouseMoveWindow::MouseMoveWindow(wxWindow& parent, bool includeParent) : wxWindo dynamic_cast<wxGauge*> (&wnd) || dynamic_cast<wxStaticLine*> (&wnd) || dynamic_cast<wxStatusBar*> (&wnd) || - dynamic_cast<wxPanel*> (&wnd)) - wnd.Connect(wxEVT_LEFT_DOWN, memFunMouseDown, NULL, this); //wxWidgets macros are obviously not C++11 ready + dynamic_cast<wxPanel*> (&wnd) || + dynamic_cast<wxFrame*> (&wnd) || + dynamic_cast<wxDialog*> (&wnd)) + wnd.Connect(wxEVT_LEFT_DOWN, memFunMouseDown, NULL, this); }; if (includeParent) |