diff options
| author | Andrew Lee <alee14498@protonmail.com> | 2020-01-19 18:03:36 -0500 |
|---|---|---|
| committer | Andrew Lee <alee14498@protonmail.com> | 2020-01-19 18:03:36 -0500 |
| commit | ecd1a4ddad4b6ad8032c5c5a59b64db74ddd38f1 (patch) | |
| tree | 949229e1e72bb21bb8bbcf2e3db337f57c4974b9 | |
| parent | 2fd212e377f6f087d12892a4327eea74a3fa9bcc (diff) | |
| download | erable-godot-ecd1a4ddad4b6ad8032c5c5a59b64db74ddd38f1.tar.gz erable-godot-ecd1a4ddad4b6ad8032c5c5a59b64db74ddd38f1.tar.bz2 erable-godot-ecd1a4ddad4b6ad8032c5c5a59b64db74ddd38f1.zip | |
Added closing function
| -rw-r--r-- | main.cpp | 2 | ||||
| -rw-r--r-- | player.cpp | 6 | ||||
| -rw-r--r-- | player.h | 5 |
3 files changed, 12 insertions, 1 deletions
@@ -5,7 +5,7 @@ int main(int argc, char *argv[]) { - std::cout << "Starting AleePlayer...\n"; + std::cout << "AleePlayer: A music player by Alee Productions. Licensed with GPL-3.0\n"; QApplication a(argc, argv); Player musicPlayer; musicPlayer.show(); @@ -1,3 +1,4 @@ +#include <iostream> #include "player.h" #include "ui_player.h" @@ -13,3 +14,8 @@ Player::~Player() delete ui; } +void Player::on_actionQuit_triggered() +{ + std::cout << "Closing AleePlayer...\n"; + close(); +} @@ -15,6 +15,11 @@ public: Player(QWidget *parent = nullptr); ~Player(); +private slots: + void on_actionQuit_toggled(bool arg1); + + void on_actionQuit_triggered(); + private: Ui::Player *ui; }; |
