From 477c9fd7f038cd43207c8634d53d0949814ecb4c Mon Sep 17 00:00:00 2001 From: deva Date: Thu, 28 Aug 2008 14:13:48 +0000 Subject: Added common stuff in central file. Fixed help text reformatting. --- client/widgets/frame.cc | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) (limited to 'client/widgets/frame.cc') 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 #include +#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); } -- cgit v1.2.3