summaryrefslogtreecommitdiff
path: root/client/widgets/checkbox.cc
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2012-12-21 10:41:15 +0100
committerBent Bisballe Nyeng <deva@aasimon.org>2012-12-21 10:41:15 +0100
commitfc0e7683878ac10eb9a4675f61e6443a13ced946 (patch)
tree317a57f0b1f7a1654d39c6bed4378c46934777cb /client/widgets/checkbox.cc
parent01ea1cb9ca4547c406ce0ed72b3f5f6ce18d91d9 (diff)
Implemented new shortcut key system. Fade in/out shortcut tooltips. Close pcpviewer on window close due to commit/nocommit/discard actions.
Diffstat (limited to 'client/widgets/checkbox.cc')
-rw-r--r--client/widgets/checkbox.cc10
1 files changed, 9 insertions, 1 deletions
diff --git a/client/widgets/checkbox.cc b/client/widgets/checkbox.cc
index 7d81b1a..45f59c6 100644
--- a/client/widgets/checkbox.cc
+++ b/client/widgets/checkbox.cc
@@ -28,6 +28,8 @@
#include <QCheckBox>
+#include "debug.h"
+
#include "common.h"
#include "luawidget.h"
@@ -35,7 +37,7 @@ CheckBox::CheckBox(QDomNode &node, MacroWindow *macrowindow)
: Widget(node, macrowindow)
{
checkbox = new QCheckBox();
- widget = checkbox;
+ setWidget(checkbox);
changedByUser = true;
@@ -128,6 +130,12 @@ void CheckBox::setWdgValid(bool valid)
checkbox->setPalette(palette);
}
+void CheckBox::shortcutActivated()
+{
+ setKeyboardFocus();
+ checkbox->click();//setChecked(!checked());
+}
+
int chk_checked(lua_State *L)
{
wdg_userdata *wdgu;