#include <QInputDialog>
#include "mainwindow.h"
+#include "optiondialog.h"
#include "time.h"
//#define AVOID_INPUT_DIALOG 0
next ();
break;
case Phonon::PlayingState:
- setWindowTitle(mediaObject->metaData().value("TITLE") + " - TomAmp");
+ setWindowTitle(mediaObject->metaData().value("TITLE") + "(" + mediaObject->metaData().value("ARTIST") + ") - TomAmp");
pauseAction->setVisible(true);
playAction->setVisible (false);
playAction->setEnabled(false);
loadPlaylistAction->setShortcut(tr("Ctrl+L"));
clearPlaylistAction = new QAction (tr("&Clear Playlist"), this);
clearPlaylistAction->setShortcut(tr("Ctrl+C"));
+ optionAction = new QAction (tr("Op&tions"), this);
+ optionAction->setShortcut(tr("Ctrl+T"));
exitAction = new QAction(tr("E&xit"), this);
exitAction->setShortcut(tr("Ctrl+X"));
aboutAction = new QAction(tr("A&bout"), this);
connect (savePlaylistAction, SIGNAL (triggered()), this, SLOT (savePlaylist()));
connect (loadPlaylistAction, SIGNAL (triggered()), this, SLOT (loadPlaylist()));
connect (clearPlaylistAction, SIGNAL (triggered()), &plman, SLOT (clearPlaylist()));
+ connect (optionAction, SIGNAL (triggered()), &plman, SLOT (showOptions()));
connect (nextAction, SIGNAL(triggered()), this, SLOT(next()));
connect (previousAction, SIGNAL(triggered()), this, SLOT(previous()));
connect(exitAction, SIGNAL(triggered()), this, SLOT(close()));
fileMenu->addAction(savePlaylistAction);
fileMenu->addAction(loadPlaylistAction);
fileMenu->addAction(clearPlaylistAction);
+ fileMenu->addAction(optionAction);
// fileMenu->addAction(exitAction);
QMenu *aboutMenu = menuBar()->addMenu(tr("&Help"));
musicTable->cellWidget(j, 3)->setProperty("row", j);
}
}
+
+void MainWindow::showOptions ()
+{
+ OptionDialog dlg (this, settings);
+ dlg.show();
+}