Screen keep lit when playing
[chessclock] / chessclockwindow.cpp
index 4f49a63..43b64cd 100644 (file)
@@ -40,6 +40,7 @@
 #include <QMessageBox>
 #include <QStackedWidget>
 #include <QProcess>
+#include <QAction>
 
 ChessClockWindow::ChessClockWindow(QWidget *parent)
     : QMainWindow(parent)
@@ -61,9 +62,11 @@ ChessClockWindow::ChessClockWindow(QWidget *parent)
 
     connect( start_, SIGNAL(selected(TimeControl*)), this, SLOT(startGame(TimeControl*)));
 
+
     // Set up menu
-    menuBar()->addAction( tr("Pause"), this, SLOT(pause()));
+//    menuBar()->addAction( tr("Pause"), this, SLOT(pause()));   // UNUSED - Pause button
     menuBar()->addAction( tr("New game"), this, SLOT(newGame()));
+    menuBar()->addAction( keepAction );
     menuBar()->addAction( tr("Visit web page"), this, SLOT(visitWeb()));
     menuBar()->addAction( tr("About"),this, SLOT(about()));
     menuBar()->addAction(tr("About Qt"), this, SLOT(aboutQt()));
@@ -80,7 +83,7 @@ void ChessClockWindow::newGame()
 {
     pause();
     if(  clocks_ == 0 ||  !clocks_->isPlayStarted()  || QMessageBox::question(this, tr("Start new game"),
-                              tr("Really quit current game and start new one with current settings?"),
+                              tr("Really quit the current game and start a new one?"),
                               QMessageBox::Yes, QMessageBox::No) == QMessageBox::Yes)
     {
         stack_->setCurrentWidget(start_);