diff options
author | John Van Ostrand <john@vanostrand.com> | 2014-11-20 10:34:49 -0500 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-11-20 07:47:20 -0800 |
commit | 21675de534243a65fdd19e28be1145e5f0e2d294 (patch) | |
tree | 86a18d8ae6ead3b5f3d89b67bc695fb1ee33747d | |
parent | a4679300cc035e34f6dffa92dde72859a79334fe (diff) | |
download | subsurface-21675de534243a65fdd19e28be1145e5f0e2d294.tar.gz |
Small changes to Yearly Statistics window
Added a title bar with close button.
Set an appropriate title.
Centred the window relative to mainwindow.
Signed-off-by: John Van Ostrand <john@vanostrand.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r-- | qt-ui/mainwindow.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp index 9b82f219a..d908fcd08 100644 --- a/qt-ui/mainwindow.cpp +++ b/qt-ui/mainwindow.cpp @@ -558,10 +558,14 @@ void MainWindow::on_actionYearlyStatistics_triggered() view->setModel(m); l->addWidget(view); d.resize(width() * .8, height() / 2); + d.move(width() * .1, height() / 4); QShortcut *close = new QShortcut(QKeySequence(Qt::CTRL + Qt::Key_W), &d); connect(close, SIGNAL(activated()), &d, SLOT(close())); QShortcut *quit = new QShortcut(QKeySequence(Qt::CTRL + Qt::Key_Q), &d); connect(quit, SIGNAL(activated()), this, SLOT(close())); + d.setWindowFlags(Qt::Window | Qt::CustomizeWindowHint + | Qt::WindowCloseButtonHint | Qt::WindowTitleHint); + d.setWindowTitle(tr("Yearly Statistics")); d.exec(); } |