diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2014-04-17 17:55:59 +0200 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2014-04-17 17:55:59 +0200 |
commit | 5935492fe66e408d2656b9a3434b9a89cf5d892c (patch) | |
tree | 22244114ee093299374e549cbadca31cddd3d2ee /dgedit/mainwindow.cc | |
parent | a63f2ded039309e109019a089e3d03523b678ae0 (diff) |
Added selection editor.
Diffstat (limited to 'dgedit/mainwindow.cc')
-rw-r--r-- | dgedit/mainwindow.cc | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/dgedit/mainwindow.cc b/dgedit/mainwindow.cc index 8cefa82..d573ff4 100644 --- a/dgedit/mainwindow.cc +++ b/dgedit/mainwindow.cc @@ -49,6 +49,7 @@ #include "canvastoolthreshold.h" #include "canvastoollisten.h" #include "volumefader.h" +#include "selectioneditor.h" #define MAXVAL 10000000L #define SINGLESTEP MAXVAL/100000 @@ -96,6 +97,8 @@ MainWindow::MainWindow() tool_selections, SLOT(thresholdChanged(double))); connect(&selections, SIGNAL(activeChanged(sel_id_t)), canvas, SLOT(update())); + connect(&selections, SIGNAL(updated(sel_id_t)), + canvas, SLOT(update())); addTool(toolbar, canvas, tool_selections); QMenu *fileMenu = menuBar()->addMenu("&File"); @@ -251,7 +254,15 @@ QWidget *MainWindow::createFilesTab() QWidget *MainWindow::createEditTab() { - return new QWidget(); + SelectionEditor *se = new SelectionEditor(selections); + + connect(&selections, SIGNAL(added(sel_id_t)), se, SLOT(added(sel_id_t))); + connect(&selections, SIGNAL(updated(sel_id_t)), se, SLOT(updated(sel_id_t))); + connect(&selections, SIGNAL(removed(sel_id_t)), se, SLOT(removed(sel_id_t))); + connect(&selections, SIGNAL(activeChanged(sel_id_t)), + se, SLOT(activeChanged(sel_id_t))); + + return se; } QWidget *MainWindow::createGenerateTab() |