diff options
Diffstat (limited to 'gui/dummy')
-rw-r--r-- | gui/dummy/mainwindow.cc | 30 | ||||
-rw-r--r-- | gui/dummy/mainwindow.h | 26 | ||||
-rw-r--r-- | gui/dummy/nextpnr.qrc | 2 |
3 files changed, 58 insertions, 0 deletions
diff --git a/gui/dummy/mainwindow.cc b/gui/dummy/mainwindow.cc new file mode 100644 index 00000000..da162dd0 --- /dev/null +++ b/gui/dummy/mainwindow.cc @@ -0,0 +1,30 @@ +#include "mainwindow.h"
+
+static void initMainResource() { Q_INIT_RESOURCE(nextpnr); }
+
+NEXTPNR_NAMESPACE_BEGIN
+
+MainWindow::MainWindow(Context *_ctx, QWidget *parent)
+ : BaseMainWindow(_ctx, parent)
+{
+ initMainResource();
+
+ std::string title = "nextpnr-dummy - " + ctx->getChipName();
+ setWindowTitle(title.c_str());
+
+ createMenu();
+}
+
+MainWindow::~MainWindow() {}
+
+void MainWindow::createMenu()
+{
+ QMenu *menu_Custom = new QMenu("&Dummy", menuBar);
+ menuBar->addAction(menu_Custom->menuAction());
+}
+
+void MainWindow::open() {}
+
+bool MainWindow::save() { return false; }
+
+NEXTPNR_NAMESPACE_END
diff --git a/gui/dummy/mainwindow.h b/gui/dummy/mainwindow.h new file mode 100644 index 00000000..c2786906 --- /dev/null +++ b/gui/dummy/mainwindow.h @@ -0,0 +1,26 @@ +#ifndef MAINWINDOW_H
+#define MAINWINDOW_H
+
+#include "../basewindow.h"
+
+NEXTPNR_NAMESPACE_BEGIN
+
+class MainWindow : public BaseMainWindow
+{
+ Q_OBJECT
+
+ public:
+ explicit MainWindow(Context *ctx, QWidget *parent = 0);
+ virtual ~MainWindow();
+
+ public:
+ void createMenu();
+
+ protected Q_SLOTS:
+ virtual void open();
+ virtual bool save();
+};
+
+NEXTPNR_NAMESPACE_END
+
+#endif // MAINWINDOW_H
diff --git a/gui/dummy/nextpnr.qrc b/gui/dummy/nextpnr.qrc new file mode 100644 index 00000000..03585ec0 --- /dev/null +++ b/gui/dummy/nextpnr.qrc @@ -0,0 +1,2 @@ +<RCC> +</RCC> |