summaryrefslogtreecommitdiff
path: root/client/widgets/window.cc
diff options
context:
space:
mode:
authorsenator <senator>2007-09-11 12:29:28 +0000
committersenator <senator>2007-09-11 12:29:28 +0000
commit1a0bd4c03c4045d9cc1b3c0bcec39487fa9c5486 (patch)
tree2b9933c3e38032079b6b594e1ba1636eca054343 /client/widgets/window.cc
parent07ff9de80d37dc0cd33feb027628eb95c1fccd35 (diff)
added layout to window and frame windgets
Diffstat (limited to 'client/widgets/window.cc')
-rw-r--r--client/widgets/window.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/client/widgets/window.cc b/client/widgets/window.cc
index 31f51bf..e93edca 100644
--- a/client/widgets/window.cc
+++ b/client/widgets/window.cc
@@ -25,6 +25,8 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
#include "window.h"
+#include <QVBoxLayout>
+#include <QHBoxLayout>
Window::Window(QDomNode node)
: QWidget(NULL), Widget(node)
@@ -50,6 +52,16 @@ Window::Window(QDomNode node)
} else {
setWindowTitle(elem.attribute(""));
}
+
+ 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);
+ }
+ }
}
QString Window::getValue()