ui/qt/container.h

changeset 67
f72c4f01bf4a
parent 66
8d490d97aab8
child 68
bd9fb6476b80
--- a/ui/qt/container.h	Wed Jan 07 17:25:33 2015 +0100
+++ b/ui/qt/container.h	Wed Jan 07 20:11:36 2015 +0100
@@ -34,6 +34,7 @@
 
 #include <string.h>
 #include <QBoxLayout>
+#include <QGridLayout>
 
 #define ui_lb2bool(b) ((b) == UI_LAYOUT_TRUE ? TRUE : FALSE)
 #define ui_bool2lb(b) ((b) ? UI_LAYOUT_TRUE : UI_LAYOUT_FALSE)
@@ -50,6 +51,7 @@
 
 struct UiLayout {
     UiLayoutBool fill;
+    bool newline;
 };
 
 struct UiContainer {
@@ -69,5 +71,17 @@
     virtual void add(QWidget *widget, bool fill);
 };
 
+class UiGridContainer : public UiContainer {
+public:
+    QGridLayout *grid;
+    int x = 0;
+    int y = 0;
+    QSpacerItem *space = NULL;
+    
+    UiGridContainer(QGridLayout *grid);
+    
+    virtual void add(QWidget *widget, bool fill);
+};
+
 #endif	/* CONTAINER_H */
 

mercurial