diff options
author | Florian Jung <flo@windfisch.org> | 2012-05-28 14:15:52 +0000 |
---|---|---|
committer | Florian Jung <flo@windfisch.org> | 2012-05-28 14:15:52 +0000 |
commit | d2a88cfaad5ac385fc3c6212c09ad7fbc38e9454 (patch) | |
tree | 387da0b38255003e1a971629ea0de32273ac3d3c /muse2/muse/cobject.cpp | |
parent | 716f5a5b56a3b7ff59004ef0a1af5f98cb2a691c (diff) |
merged with release_2_0
Diffstat (limited to 'muse2/muse/cobject.cpp')
-rw-r--r-- | muse2/muse/cobject.cpp | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/muse2/muse/cobject.cpp b/muse2/muse/cobject.cpp index 1407a7a0..b7f257ae 100644 --- a/muse2/muse/cobject.cpp +++ b/muse2/muse/cobject.cpp @@ -52,6 +52,8 @@ bool TopWin::initInited=false; TopWin::TopWin(ToplevelType t, QWidget* parent, const char* name, Qt::WindowFlags f) : QMainWindow(parent, f) { + _initalizing = true; + _isDeleting = false; if (initInited==false) initConfiguration(); @@ -128,13 +130,19 @@ TopWin::TopWin(ToplevelType t, QWidget* parent, const char* name, Qt::WindowFlag QToolBar* tempo_tb; tempo_tb = addToolBar(tr("Tempo")); tempo_tb->setObjectName("Tempo"); - tempo_tb->addWidget(new MusEGui::TempoToolbarWidget(tempo_tb)); + MusEGui::TempoToolbarWidget* tw = new MusEGui::TempoToolbarWidget(tempo_tb); + tempo_tb->addWidget(tw); QToolBar* sig_tb; sig_tb = addToolBar(tr("Signature")); sig_tb->setObjectName("Signature"); - sig_tb->addWidget(new MusEGui::SigToolbarWidget(tempo_tb)); - + MusEGui::SigToolbarWidget* sw = new MusEGui::SigToolbarWidget(tempo_tb); + sig_tb->addWidget(sw); + + connect(tw, SIGNAL(returnPressed()), SLOT(focusCanvas())); + connect(tw, SIGNAL(escapePressed()), SLOT(focusCanvas())); + connect(sw, SIGNAL(returnPressed()), SLOT(focusCanvas())); + connect(sw, SIGNAL(escapePressed()), SLOT(focusCanvas())); } @@ -565,6 +573,12 @@ void TopWin::writeConfiguration(ToplevelType t, int level, MusECore::Xml& xml) xml.etag(level, "topwin"); } +void TopWin::finalizeInit() +{ + MusEGlobal::muse->topwinMenuInited(this); + _initalizing=false; +} + void TopWin::initTopwinState() { if (sharesToolsAndMenu()) |