diff options
author | Miodrag Milanovic <mmicko@gmail.com> | 2018-06-21 13:41:16 +0200 |
---|---|---|
committer | Miodrag Milanovic <mmicko@gmail.com> | 2018-06-21 13:41:33 +0200 |
commit | 9c03909ebaec8157824a9cb13eeea774d29b35e1 (patch) | |
tree | 5d15b1bef7a8bdec74a5f9328fbe305bb59faef9 /gui/basewindow.h | |
parent | 56ed679f831f703ad2f170713e0b127a97da40b3 (diff) | |
download | nextpnr-9c03909ebaec8157824a9cb13eeea774d29b35e1.tar.gz nextpnr-9c03909ebaec8157824a9cb13eeea774d29b35e1.tar.bz2 nextpnr-9c03909ebaec8157824a9cb13eeea774d29b35e1.zip |
Make arch specific main window
Diffstat (limited to 'gui/basewindow.h')
-rw-r--r-- | gui/basewindow.h | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/gui/basewindow.h b/gui/basewindow.h new file mode 100644 index 00000000..52efd6b1 --- /dev/null +++ b/gui/basewindow.h @@ -0,0 +1,45 @@ +#ifndef BASEMAINWINDOW_H
+#define BASEMAINWINDOW_H
+
+#include "infotab.h"
+#include "nextpnr.h"
+
+#include <QMainWindow>
+#include <QTabWidget>
+#include <QMenu>
+#include <QMenuBar>
+#include <QToolBar>
+#include <QStatusBar>
+
+
+// FIXME
+USING_NEXTPNR_NAMESPACE
+
+class BaseMainWindow : public QMainWindow
+{
+ Q_OBJECT
+
+ public:
+ explicit BaseMainWindow(Context *ctx, QWidget *parent = 0);
+ ~BaseMainWindow();
+ Context *getContext() { return ctx; }
+
+ protected:
+ void createMenusAndBars();
+
+ protected Q_SLOTS:
+ void writeInfo(std::string text);
+ void open();
+ bool save();
+
+ protected:
+ Context *ctx;
+ QTabWidget *tabWidget;
+ InfoTab *info;
+
+ QMenuBar *menuBar;
+ QToolBar *mainToolBar;
+ QStatusBar *statusBar;
+};
+
+#endif // BASEMAINWINDOW_H
|