summaryrefslogtreecommitdiff
path: root/client/macro.cc
diff options
context:
space:
mode:
authordeva <deva>2011-03-11 13:41:42 +0000
committerdeva <deva>2011-03-11 13:41:42 +0000
commit33ca5716dd3bb93caf87bce65de15986dde86c63 (patch)
tree3571e4e0426f6516f09632281b2cefc70e8b67f9 /client/macro.cc
parent0a1d9ad482e343fe96e0e447a1c173654d6fd3af (diff)
Huge improvements on 'keyboard-only' use.
Diffstat (limited to 'client/macro.cc')
-rw-r--r--client/macro.cc8
1 files changed, 5 insertions, 3 deletions
diff --git a/client/macro.cc b/client/macro.cc
index ad21cc4..0dcf590 100644
--- a/client/macro.cc
+++ b/client/macro.cc
@@ -61,11 +61,15 @@ void Macro::update(QDomNode &node)
name = elem.attribute("name");
iscompleted = elem.attribute("completed", "false") == "true";
+ if(drawer == NULL) {
+ drawer = new MacroDrawer(this, elem.attribute("caption", name));
+
if(window == NULL) {
isstatic = elem.attribute("static", "false") == "true";
iscompact = elem.attribute("compact", "false") == "true";
- window = new MacroWindow(netcom, templ, isstatic, iscompact, scrollarea);
+ window = new MacroWindow(netcom, templ, isstatic, iscompact,
+ scrollarea, drawer);
QFont f = window->font();
f.setBold(false);
@@ -73,8 +77,6 @@ void Macro::update(QDomNode &node)
window->setFont(f);
}
- if(drawer == NULL) {
- drawer = new MacroDrawer(this, elem.attribute("caption", name));
QHBoxLayout *l = new QHBoxLayout();
l->setContentsMargins(10,0,10,0);
drawer->setLayout(l);