aboutsummaryrefslogtreecommitdiffstats
path: root/gui/dummy
diff options
context:
space:
mode:
authorSergiusz Bazanski <q3k@q3k.org>2018-06-22 14:29:28 +0100
committerSergiusz Bazanski <q3k@q3k.org>2018-06-22 14:29:28 +0100
commit858acc5c1c0ee4bbdfb8d2012b80cda656ca39db (patch)
tree7cc94b94e40c05c5a7baae61c9d0db4f23a31b60 /gui/dummy
parent98b1f0c041b01d07f64e8e04503f8eccb05a93de (diff)
parentf86a0d6c8c8792c36c87cf345665ce7c9fbcc60f (diff)
downloadnextpnr-858acc5c1c0ee4bbdfb8d2012b80cda656ca39db.tar.gz
nextpnr-858acc5c1c0ee4bbdfb8d2012b80cda656ca39db.tar.bz2
nextpnr-858acc5c1c0ee4bbdfb8d2012b80cda656ca39db.zip
Merge branch 'master' of gitlab.com:SymbioticEDA/nextpnr into q3k/gl
Diffstat (limited to 'gui/dummy')
-rw-r--r--gui/dummy/mainwindow.cc30
-rw-r--r--gui/dummy/mainwindow.h26
-rw-r--r--gui/dummy/nextpnr.qrc2
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>