summaryrefslogtreecommitdiff
path: root/src/gui/gui.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-07-25 22:13:12 +0300
committerAndrei Karas <akaras@inbox.ru>2017-07-25 22:13:12 +0300
commitc2b3279615398942adce087119bde9e4fcfd9ab0 (patch)
tree21b43a51e437f08ef661c7095facd16d0ad72518 /src/gui/gui.cpp
parentfe64e7204c8ab7b91f36c305cce9f82e92792cb9 (diff)
downloadManaVerse-c2b3279615398942adce087119bde9e4fcfd9ab0.tar.gz
ManaVerse-c2b3279615398942adce087119bde9e4fcfd9ab0.tar.bz2
ManaVerse-c2b3279615398942adce087119bde9e4fcfd9ab0.tar.xz
ManaVerse-c2b3279615398942adce087119bde9e4fcfd9ab0.zip
Remove command line option --default-cursor and add option --hide-cursor.s20170725
Diffstat (limited to 'src/gui/gui.cpp')
-rw-r--r--src/gui/gui.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp
index 28eef21dd..c27aeec35 100644
--- a/src/gui/gui.cpp
+++ b/src/gui/gui.cpp
@@ -258,8 +258,7 @@ void Gui::postInit(Graphics *const graphics)
Widget::setGlobalFont(mGuiFont);
// Initialize mouse cursor and listen for changes to the option
- setUseCustomCursor(config.getBoolValue("customcursor") &&
- !settings.options.defaultCursor);
+ setUseCustomCursor(config.getBoolValue("customcursor"));
setDoubleClick(config.getBoolValue("doubleClick"));
config.addListener("customcursor", mConfigListener);
config.addListener("doubleClick", mConfigListener);
@@ -554,6 +553,11 @@ void Gui::videoResized() const
void Gui::setUseCustomCursor(const bool customCursor)
{
+ if (settings.options.hideCursor)
+ {
+ SDL::showCursor(false);
+ return;
+ }
if (customCursor != mCustomCursor)
{
mCustomCursor = customCursor;