From 3bdb7ebbcc6f7d08ed90f2232f0901b1c0e92d51 Mon Sep 17 00:00:00 2001 From: Yohann Ferreira Date: Fri, 15 Jul 2011 02:55:31 +0200 Subject: Added icons to the confirm and cancel button of the quit dialog. This a good example of use for the new graphics and button functionalities. --- src/gui/quitdialog.cpp | 2 ++ src/gui/quitdialog.h | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/gui/quitdialog.cpp b/src/gui/quitdialog.cpp index 6ecc62a6..3da07206 100644 --- a/src/gui/quitdialog.cpp +++ b/src/gui/quitdialog.cpp @@ -44,7 +44,9 @@ QuitDialog::QuitDialog(QuitDialog** pointerToMe): mSwitchAccountServer = new RadioButton(_("Switch server"), "quitdialog"); mSwitchCharacter = new RadioButton(_("Switch character"), "quitdialog"); mOkButton = new Button(_("OK"), "ok", this); + mOkButton->setButtonIcon("button-icon-confirm.png"); mCancelButton = new Button(_("Cancel"), "cancel", this); + mCancelButton->setButtonIcon("button-icon-cancel.png"); addKeyListener(this); diff --git a/src/gui/quitdialog.h b/src/gui/quitdialog.h index 65a325b8..21fe2f8a 100644 --- a/src/gui/quitdialog.h +++ b/src/gui/quitdialog.h @@ -29,6 +29,8 @@ #include +class Button; + /** * The quit dialog. * @@ -62,8 +64,8 @@ class QuitDialog : public Window, public gcn::ActionListener, gcn::RadioButton *mForceQuit; gcn::RadioButton *mSwitchAccountServer; gcn::RadioButton *mSwitchCharacter; - gcn::Button *mOkButton; - gcn::Button *mCancelButton; + Button *mOkButton; + Button *mCancelButton; QuitDialog **mMyPointer; }; -- cgit v1.2.3-70-g09d2