summaryrefslogtreecommitdiff
path: root/client/widgets/frame.cc
diff options
context:
space:
mode:
authordeva <deva>2008-08-28 14:13:48 +0000
committerdeva <deva>2008-08-28 14:13:48 +0000
commit477c9fd7f038cd43207c8634d53d0949814ecb4c (patch)
tree4d4f849c281aa4402c3f7bd95546c21ebe287e55 /client/widgets/frame.cc
parentb74d14e7e8625ce1a148105f69e3406f7d88ecd6 (diff)
Added common stuff in central file. Fixed help text reformatting.
Diffstat (limited to 'client/widgets/frame.cc')
-rw-r--r--client/widgets/frame.cc17
1 files changed, 4 insertions, 13 deletions
diff --git a/client/widgets/frame.cc b/client/widgets/frame.cc
index 1c0955e..872c3fc 100644
--- a/client/widgets/frame.cc
+++ b/client/widgets/frame.cc
@@ -28,23 +28,14 @@
#include <QVBoxLayout>
#include <QHBoxLayout>
+#include "common.h"
+
Frame::Frame(QDomNode &node, MacroWindow *macrowindow)
: QFrame(), Widget(node, macrowindow)
{
- QDomElement elem = node.toElement();
+ setCommonAttributes(this, node);
+ setCommonLayout(this, node);
- if(elem.hasAttribute("layout")) {
- if(elem.attribute("layout") == "hbox") {
- QHBoxLayout *layout = new QHBoxLayout();
- setLayout(layout);
- } else if (elem.attribute("layout") == "vbox") {
- QVBoxLayout *layout = new QVBoxLayout();
- setLayout(layout);
- }
- }
- setLineWidth(0);
- setMidLineWidth(0);
- setContentsMargins(0,0,0,0);
layout()->setContentsMargins(0,0,0,0);
}