# HG changeset patch # User John Tsiombikas # Date 1422180285 -7200 # Node ID d76fb2ffe7f5df9a94e1bc90553681cf0dd21197 # Parent 6321cfa2ad62b629b6d101be4741070aa08b07d2 foo diff -r 6321cfa2ad62 -r d76fb2ffe7f5 android/AndroidManifest.xml --- a/android/AndroidManifest.xml Fri Jan 23 15:24:27 2015 +0200 +++ b/android/AndroidManifest.xml Sun Jan 25 12:04:45 2015 +0200 @@ -1,6 +1,6 @@ - + diff -r 6321cfa2ad62 -r d76fb2ffe7f5 android/res/drawable-hdpi/icon.png Binary file android/res/drawable-hdpi/icon.png has changed diff -r 6321cfa2ad62 -r d76fb2ffe7f5 android/res/drawable-ldpi/icon.png Binary file android/res/drawable-ldpi/icon.png has changed diff -r 6321cfa2ad62 -r d76fb2ffe7f5 android/res/drawable-mdpi/icon.png Binary file android/res/drawable-mdpi/icon.png has changed diff -r 6321cfa2ad62 -r d76fb2ffe7f5 data/icon-36px.png Binary file data/icon-36px.png has changed diff -r 6321cfa2ad62 -r d76fb2ffe7f5 data/icon-48px.png Binary file data/icon-48px.png has changed diff -r 6321cfa2ad62 -r d76fb2ffe7f5 data/icon-72px.png Binary file data/icon-72px.png has changed diff -r 6321cfa2ad62 -r d76fb2ffe7f5 data/icon-96px.png Binary file data/icon-96px.png has changed diff -r 6321cfa2ad62 -r d76fb2ffe7f5 mainwin.cc --- a/mainwin.cc Fri Jan 23 15:24:27 2015 +0200 +++ b/mainwin.cc Sun Jan 25 12:04:45 2015 +0200 @@ -1,3 +1,4 @@ +#include #include "mainwin.h" #include "ui_mainwin.h" @@ -42,3 +43,29 @@ { ui->spin_p2_life->setValue(ui->spin_p2_life->value() - 10); } + +void MainWin::on_action_reset_triggered() +{ + on_bn_p1_reset_clicked(); + on_bn_p2_reset_clicked(); +} + +void MainWin::on_action_quit_triggered() +{ + QApplication::quit(); +} + +void MainWin::on_action_about_triggered() +{ + static const char *about_text = + "simple_mtglife is an extremely simple and lightweight life counter " + "for magic: the gathering.\n" + "\n" + "Copyright (C) 2015 John Tsiombikas \n" + "http://nuclear.mutantstargoat.com\n" + "\n" + "This program is free software. Feel free to copy, modify, and " + "distribute copies of this application, under the terms of the " + "GNU General Public License version 3 (or any later version)."; + QMessageBox::about(this, "About simple_mtglife", about_text); +} diff -r 6321cfa2ad62 -r d76fb2ffe7f5 mainwin.h --- a/mainwin.h Fri Jan 23 15:24:27 2015 +0200 +++ b/mainwin.h Sun Jan 25 12:04:45 2015 +0200 @@ -28,6 +28,12 @@ void on_bn_p2_dec10_clicked(); + void on_action_reset_triggered(); + + void on_action_quit_triggered(); + + void on_action_about_triggered(); + private: Ui::MainWin *ui; }; diff -r 6321cfa2ad62 -r d76fb2ffe7f5 mainwin.ui --- a/mainwin.ui Fri Jan 23 15:24:27 2015 +0200 +++ b/mainwin.ui Sun Jan 25 12:04:45 2015 +0200 @@ -13,6 +13,10 @@ MainWin + + + :/data/icon-96px.png:/data/icon-96px.png + @@ -44,6 +48,14 @@ 0 + + + 20 + + + + Qt::NoFocus + Reset @@ -83,9 +95,12 @@ - 24 + 20 + + Qt::NoFocus + +10 @@ -101,9 +116,12 @@ - 24 + 20 + + Qt::NoFocus + +1 @@ -119,9 +137,12 @@ - 50 + 40 + + Qt::NoFocus + true @@ -152,9 +173,12 @@ - 24 + 20 + + Qt::NoFocus + -1 @@ -164,9 +188,12 @@ - 24 + 20 + + Qt::NoFocus + -10 @@ -206,6 +233,14 @@ 0 + + + 20 + + + + Qt::NoFocus + Reset @@ -245,9 +280,12 @@ - 24 + 20 + + Qt::NoFocus + +10 @@ -263,9 +301,12 @@ - 24 + 20 + + Qt::NoFocus + +1 @@ -281,9 +322,12 @@ - 50 + 40 + + Qt::NoFocus + true @@ -314,9 +358,12 @@ - 24 + 20 + + Qt::NoFocus + -1 @@ -326,9 +373,12 @@ - 24 + 20 + + Qt::NoFocus + -10 @@ -341,9 +391,52 @@ + + + + 0 + 0 + 623 + 20 + + + + + &File + + + + + + + + &Help + + + + + + + + + &Reset + + + + + &Quit + + + + + &About + + - + + + bn_p1_dec @@ -384,8 +477,8 @@ stepDown() - 536 - 252 + 600 + 304 540 diff -r 6321cfa2ad62 -r d76fb2ffe7f5 resources.qrc --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/resources.qrc Sun Jan 25 12:04:45 2015 +0200 @@ -0,0 +1,5 @@ + + + data/icon-96px.png + + diff -r 6321cfa2ad62 -r d76fb2ffe7f5 simple_mtglife.pro --- a/simple_mtglife.pro Fri Jan 23 15:24:27 2015 +0200 +++ b/simple_mtglife.pro Sun Jan 25 12:04:45 2015 +0200 @@ -29,7 +29,14 @@ android/build.gradle \ android/gradle/wrapper/gradle-wrapper.properties \ android/gradlew \ - android/gradlew.bat + android/gradlew.bat \ + data/icon-36px.png \ + data/icon-48px.png \ + data/icon-72px.png \ + data/icon-96px.png ANDROID_PACKAGE_SOURCE_DIR = $$PWD/android +RESOURCES += \ + resources.qrc +