From 48454a64ccb3154ad1eb06b4494b11340d64246d Mon Sep 17 00:00:00 2001 From: Dmytro Bogovych Date: Mon, 18 Apr 2022 10:27:23 +0300 Subject: [PATCH] - version 0.0.6 - fix autostart + add icon to about dialog --- app/aboutdlg.cpp | 2 +- app/aboutdlg.ui | 24 ++++++++++++++++++++---- app/assets/misc/qbreak.desktop | 2 +- app/config.h | 2 +- app/mainwindow.cpp | 2 +- 5 files changed, 24 insertions(+), 8 deletions(-) diff --git a/app/aboutdlg.cpp b/app/aboutdlg.cpp index e7f7b1e..c69a862 100644 --- a/app/aboutdlg.cpp +++ b/app/aboutdlg.cpp @@ -7,7 +7,7 @@ AboutDlg::AboutDlg(QWidget *parent) : ui(new Ui::AboutDlg) { ui->setupUi(this); - + ui->mAppIcon->setPixmap(QPixmap(":/assets/images/coffee_cup/icon_96x96")); auto version_text = QString("Version %1.%2.%3") .arg(QBREAK_VERSION_MAJOR) .arg(QBREAK_VERSION_MINOR) diff --git a/app/aboutdlg.ui b/app/aboutdlg.ui index 0f11bc7..5f146ba 100644 --- a/app/aboutdlg.ui +++ b/app/aboutdlg.ui @@ -16,10 +16,26 @@ 300 + + + 800 + 600 + + Dialog + + + + TextLabel + + + Qt::AlignCenter + + + @@ -104,8 +120,8 @@ accept() - 248 - 254 + 257 + 290 157 @@ -120,8 +136,8 @@ reject() - 316 - 260 + 325 + 290 286 diff --git a/app/assets/misc/qbreak.desktop b/app/assets/misc/qbreak.desktop index 4661425..8704fad 100644 --- a/app/assets/misc/qbreak.desktop +++ b/app/assets/misc/qbreak.desktop @@ -1,7 +1,7 @@ [Desktop Entry] GenericName=App to make the breaks Name=QBreak -Version=0.0.5 +Version=0.0.6 Exec=/usr/bin/qbreak Comment=App to make periodical breaks Icon=qbreak diff --git a/app/config.h b/app/config.h index 8dbeccb..b0f523a 100644 --- a/app/config.h +++ b/app/config.h @@ -4,6 +4,6 @@ // App version #define QBREAK_VERSION_MAJOR 0 #define QBREAK_VERSION_MINOR 0 -#define QBREAK_VERSION_SUFFIX 5 +#define QBREAK_VERSION_SUFFIX 6 #endif // CONFIG_H diff --git a/app/mainwindow.cpp b/app/mainwindow.cpp index dadeb8b..f5d30e2 100644 --- a/app/mainwindow.cpp +++ b/app/mainwindow.cpp @@ -143,7 +143,7 @@ void MainWindow::applyConfig() if (mAppConfig.autostart) { - QString path_to_me = QFileInfo(QApplication::arguments().front()).canonicalPath(); + auto path_to_me = QFileInfo(QApplication::arguments().front()).absoluteFilePath(); autostart::enable(path_to_me.toStdString()); } else