diff options
author | Simon Rettberg | 2018-08-30 15:47:44 +0200 |
---|---|---|
committer | Simon Rettberg | 2018-08-30 15:47:44 +0200 |
commit | 6549dede60bc1b2dde4e29aad19cf7ec71076c96 (patch) | |
tree | 984b01d732a8a5ee981ee3867ee69f483951326d /src/mainwindow.cpp | |
parent | Make username placeholder configurable (diff) | |
download | slxgreeter-6549dede60bc1b2dde4e29aad19cf7ec71076c96.tar.gz slxgreeter-6549dede60bc1b2dde4e29aad19cf7ec71076c96.tar.xz slxgreeter-6549dede60bc1b2dde4e29aad19cf7ec71076c96.zip |
Sanitize C++11
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r-- | src/mainwindow.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 0ebdb59..b66a73d 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -31,7 +31,7 @@ MainWindow::MainWindow(bool primary, int screen, const QRect &screenRect, QWidge QWidget(parent), m_ScreenRect(screenRect), m_Primary(primary), - m_LoginForm(NULL), + m_LoginForm(nullptr), m_messages(nullptr), m_Clock(nullptr) { @@ -310,7 +310,7 @@ void MainWindow::setBackground() void MainWindow::showStandby() { - if (m_LoginForm != NULL) { + if (m_LoginForm != nullptr) { m_LoginForm->hide(); } QSvgWidget *img = new QSvgWidget(":/resources/gnome-face-tired.svg", this); @@ -324,7 +324,7 @@ void MainWindow::showStandby() QTimer::singleShot(4000, [this, img]() { img->hide(); img->deleteLater(); - if (this->m_LoginForm != NULL) { + if (this->m_LoginForm != nullptr) { m_LoginForm->show(); } }); @@ -346,6 +346,6 @@ int MainWindow::drawClock() QLocale loc; m_Clock->setText(time.toString(loc.dateFormat() + " HH:mm ")); m_Clock->adjustSize(); - ((QWidget*)m_Clock->parent())->adjustSize(); + reinterpret_cast<QWidget*>(m_Clock->parent())->adjustSize(); return (60 - time.time().second()) * 1000 + 100; } |