diff --git a/CMakeLists.txt b/CMakeLists.txt index 300b776..a6c5aff 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -41,6 +41,7 @@ else() custombutton.h custombutton.cpp statusdot.h statusdot.cpp jsonparser.h jsonparser.cpp + resources.qrc ) endif() diff --git a/icon.svg b/icon.svg new file mode 100644 index 0000000..5ea4de0 --- /dev/null +++ b/icon.svg @@ -0,0 +1,373 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + i + diff --git a/main.cpp b/main.cpp index fd3e533..c9001a9 100644 --- a/main.cpp +++ b/main.cpp @@ -6,6 +6,7 @@ int main(int argc, char *argv[]) { QApplication a(argc, argv); MainWindow w; + w.setWindowIcon(QIcon(":/icons/icon.svg")); w.show(); return a.exec(); } diff --git a/mainwindow.cpp b/mainwindow.cpp index 737fbf9..8871ddf 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -725,3 +725,13 @@ void MainWindow::on_actionRescan_Refresh_triggered() scanDevices(); } + +void MainWindow::on_actionAbout_triggered() +{ + QString message = "An ATA and NVMe S.M.A.R.T. data viewer for Linux\n\n"; + message += "Licensed under the GNU G.P.L. Version 3\n\n"; + message += "Made by Samantas5855"; + + QMessageBox::about(this, "About KDiskInfo", message); +} + diff --git a/mainwindow.h b/mainwindow.h index ba78a7f..cdbbec2 100644 --- a/mainwindow.h +++ b/mainwindow.h @@ -43,6 +43,8 @@ private slots: void on_actionRescan_Refresh_triggered(); + void on_actionAbout_triggered(); + private: Ui::MainWindow *ui; QButtonGroup *buttonGroup; diff --git a/mainwindow.ui b/mainwindow.ui index 0262c3e..7c67a87 100644 --- a/mainwindow.ui +++ b/mainwindow.ui @@ -392,6 +392,9 @@ + + + &GitHub @@ -420,7 +423,7 @@ true - Decimal Raw Values + &Decimal Raw Values @@ -428,7 +431,7 @@ true - Use Fahrenheit + &Use Fahrenheit diff --git a/resources.qrc b/resources.qrc new file mode 100644 index 0000000..474bfc3 --- /dev/null +++ b/resources.qrc @@ -0,0 +1,5 @@ + + + icon.svg + +