]> vaikene.ee Git - evaf/blobdiff - src/plugins/SdiWindow/sdiwindow.h
Changed the way how the main window is used.
[evaf] / src / plugins / SdiWindow / sdiwindow.h
index d886cca5d842914472e0e92b939abb7e7e04e78c..b2c3bc6c2fbdd69a1120d997091dd1bd586e489c 100644 (file)
@@ -27,6 +27,9 @@
 #include <QObject>
 #include <QString>
 #include <QWidget>
+#include <QList>
+
+class QVBoxLayout;
 
 namespace eVaf {
 namespace SdiWindow {
@@ -49,6 +52,10 @@ public:
 
     void done();
 
+    void addWidget(QWidget * widget);
+
+    void addLayout(QLayout * layout);
+
 
 private: // Methods
 
@@ -57,6 +64,16 @@ private: // Methods
     void saveSettings();
 
     void restoreSettings();
+
+
+private: // Members
+
+    /// The layout of the window
+    QVBoxLayout * mLayout;
+
+    /// Widgets and layouts added to the main window
+    QList<QObject *> mItemsAdded;
+
 };
 
 /**
@@ -78,7 +95,9 @@ public:
 
     bool isReady() const { return mReady; }
 
-    virtual QWidget * widget() const { return wWindow; }
+    virtual void addWidget(QWidget * widget) { wWindow->addWidget(widget); }
+
+    virtual void addLayout(QLayout * layout) { wWindow->addLayout(layout); }
 
 
 private: // Members