summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWerner Schweer <ws.seh.de>2006-06-26 09:14:05 +0000
committerWerner Schweer <ws.seh.de>2006-06-26 09:14:05 +0000
commit90f0715febd8673084eb1d3d86a91e2e1487b1bb (patch)
tree17981bee8fc6c02f45bb8cc2965cf51c4871675a
parent584f6f7457e6f165de9c6f3716e0ad7be7b57150 (diff)
add missing file
-rw-r--r--muse/muse/master/masteredit.cpp2
-rw-r--r--muse/muse/midiedit/pianoroll.cpp2
-rw-r--r--muse/muse/projectpropsdialog.cpp64
3 files changed, 67 insertions, 1 deletions
diff --git a/muse/muse/master/masteredit.cpp b/muse/muse/master/masteredit.cpp
index 2b2d84d7..97873a2b 100644
--- a/muse/muse/master/masteredit.cpp
+++ b/muse/muse/master/masteredit.cpp
@@ -115,6 +115,8 @@ MasterEdit::MasterEdit()
connect(song, SIGNAL(tempoChanged()), tcanvas, SLOT(tempoChanged()));
connect(tcanvas, SIGNAL(posChanged(int,const AL::Pos&)), song, SLOT(setPos(int,const AL::Pos&)));
+ connect(tcanvas, SIGNAL(cursorPos(const AL::Pos&,bool)), cursorPos, SLOT(setValue(const AL::Pos&,bool)));
+
connect(tcanvas, SIGNAL(tempoChanged(int)), SLOT(setTempo(int)));
connect(tools2, SIGNAL(toolChanged(int)), tcanvas, SLOT(setTool(int)));
connect(song, SIGNAL(songChanged(int)), SLOT(songChanged(int)));
diff --git a/muse/muse/midiedit/pianoroll.cpp b/muse/muse/midiedit/pianoroll.cpp
index 06d4c64f..f5d1aa42 100644
--- a/muse/muse/midiedit/pianoroll.cpp
+++ b/muse/muse/midiedit/pianoroll.cpp
@@ -215,7 +215,7 @@ PianoRoll::PianoRoll(PartList* pl, bool init)
setCentralWidget(tcanvas);
tcanvas->setCornerWidget(new QSizeGrip(tcanvas));
- connect(song, SIGNAL(posChanged(int,const AL::Pos&,bool)), canvas(), SLOT(setLocatorPos(int,const AL::Pos&,bool)));
+ connect(song, SIGNAL(posChanged(int,const AL::Pos&,bool)), canvas(), SLOT(setLocatorPos(int,const AL::Pos&,bool)));
connect(canvas(), SIGNAL(posChanged(int,const AL::Pos&)), SLOT(setPos(int,const AL::Pos&)));
connect(canvas(), SIGNAL(toolChanged(int)), tools2, SLOT(set(int)));
diff --git a/muse/muse/projectpropsdialog.cpp b/muse/muse/projectpropsdialog.cpp
new file mode 100644
index 00000000..eb983801
--- /dev/null
+++ b/muse/muse/projectpropsdialog.cpp
@@ -0,0 +1,64 @@
+//=============================================================================
+// MusE
+// Linux Music Editor
+// $Id:$
+//
+// Copyright (C) 2002-2006 by Werner Schweer and others
+//
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU General Public License version 2.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+//=============================================================================
+
+#include "projectpropsdialog.h"
+#include "song.h"
+
+#include "al/al.h"
+#include "al/tempo.h"
+
+//---------------------------------------------------------
+// ProjectPropsDialog
+//---------------------------------------------------------
+
+ProjectPropsDialog::ProjectPropsDialog(QWidget* parent)
+ : QDialog(parent)
+ {
+ setupUi(this);
+ comment->setPlainText(song->comment());
+ projectName->setText(song->projectName());
+ createdDate->setDateTime(song->createDate());
+ int n = AL::tempomap.tick2frame(song->len()) / AL::sampleRate;
+ QTime time;
+ time = time.addSecs(n);
+ length->setTime(time);
+ }
+
+//---------------------------------------------------------
+// accept
+//---------------------------------------------------------
+
+void ProjectPropsDialog::accept()
+ {
+ song->setComment(comment->toPlainText());
+ song->dirty = true;
+ QDialog::accept();
+ }
+
+//---------------------------------------------------------
+// reject
+//---------------------------------------------------------
+
+void ProjectPropsDialog::reject()
+ {
+ comment->setPlainText(song->comment());
+ QDialog::reject();
+ }
+