summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2013-03-31 12:43:35 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2013-03-31 12:43:35 +0200
commitfa0e229e7228129099f3e772e0b2844a3f146240 (patch)
tree9047603e5b7cd2645c0652f29af379cd349d1f8b
parentbe675587812c27fac9838af844f8ecb44703ff08 (diff)
Missing file in last commit (focusEvents)
-rw-r--r--plugingui/window.cc11
-rw-r--r--plugingui/window.h4
2 files changed, 15 insertions, 0 deletions
diff --git a/plugingui/window.cc b/plugingui/window.cc
index f524ee9..7dabb4c 100644
--- a/plugingui/window.cc
+++ b/plugingui/window.cc
@@ -57,6 +57,7 @@ GUI::Window::Window(GlobalContext *gctx)
refcount = 0;
_keyboardFocus = this;
_buttonDownFocus = NULL;
+ _mouseFocus = NULL;
#ifdef X11
native = new NativeWindowX11(gctx, this);
@@ -197,3 +198,13 @@ void GUI::Window::setButtonDownFocus(GUI::Widget *widget)
_buttonDownFocus = widget;
native->grabMouse(widget != NULL);
}
+
+GUI::Widget *GUI::Window::mouseFocus()
+{
+ return _mouseFocus;
+}
+
+void GUI::Window::setMouseFocus(GUI::Widget *widget)
+{
+ _mouseFocus = widget;
+}
diff --git a/plugingui/window.h b/plugingui/window.h
index c63e38b..f07d270 100644
--- a/plugingui/window.h
+++ b/plugingui/window.h
@@ -75,6 +75,9 @@ public:
Widget *buttonDownFocus();
void setButtonDownFocus(Widget *widget);
+ Widget *mouseFocus();
+ void setMouseFocus(Widget *widget);
+
GlobalContext *gctx;
PixelBuffer wpixbuf;
@@ -85,6 +88,7 @@ protected:
Widget *_keyboardFocus;
Widget *_buttonDownFocus;
+ Widget *_mouseFocus;
NativeWindow *native;