diff options
author | Eugenio Favalli <elvenprogrammer@gmail.com> | 2006-05-03 17:52:04 +0000 |
---|---|---|
committer | Eugenio Favalli <elvenprogrammer@gmail.com> | 2006-05-03 17:52:04 +0000 |
commit | b344f63a95e236ffd062608dd5a320a542946d75 (patch) | |
tree | bfd3b1827795f694fb9e9438eb74715bd448b6cc /src/gui/setup_video.h | |
parent | c74ed8da3751f85b4bfb235b055f404f5340eae7 (diff) | |
download | mana-client-b344f63a95e236ffd062608dd5a320a542946d75.tar.gz mana-client-b344f63a95e236ffd062608dd5a320a542946d75.tar.bz2 mana-client-b344f63a95e236ffd062608dd5a320a542946d75.tar.xz mana-client-b344f63a95e236ffd062608dd5a320a542946d75.zip |
FPS limit can now be set in setup dialog. Default value for FPS is 50. (Code based on peoro's patch).
Diffstat (limited to 'src/gui/setup_video.h')
-rw-r--r-- | src/gui/setup_video.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/gui/setup_video.h b/src/gui/setup_video.h index d7129950..d8ee1914 100644 --- a/src/gui/setup_video.h +++ b/src/gui/setup_video.h @@ -27,10 +27,12 @@ #include "setuptab.h" #include <guichan/actionlistener.hpp> +#include <guichan/keylistener.hpp> #include "../guichanfwd.h" -class Setup_Video : public SetupTab, public gcn::ActionListener +class Setup_Video : public SetupTab, public gcn::ActionListener, + public gcn::KeyListener { public: Setup_Video(); @@ -40,12 +42,16 @@ class Setup_Video : public SetupTab, public gcn::ActionListener void cancel(); void action(const std::string&); + + /** Called when key is pressed */ + void keyPress(const gcn::Key& key); private: bool mFullScreenEnabled; bool mOpenGLEnabled; bool mCustomCursorEnabled; double mOpacity; + int mFps; class ModeListModel *mModeListModel; @@ -54,6 +60,9 @@ class Setup_Video : public SetupTab, public gcn::ActionListener gcn::CheckBox *mOpenGLCheckBox; gcn::CheckBox *mCustomCursorCheckBox; gcn::Slider *mAlphaSlider; + gcn::CheckBox *mFpsCheckBox; + gcn::Slider *mFpsSlider; + gcn::TextField *mFpsField; }; #endif |