Also unhide mouse cursor when in gsConfirm state
authorunc0rr
Sun, 07 Aug 2011 22:24:13 +0400
changeset 5523 9ac5acc4f3e5
parent 5522 5a4bc518c59a
child 5524 40b7f95d9f18
Also unhide mouse cursor when in gsConfirm state
hedgewars/uCommandHandlers.pas
hedgewars/uWorld.pas
--- a/hedgewars/uCommandHandlers.pas	Sun Aug 07 22:20:52 2011 +0400
+++ b/hedgewars/uCommandHandlers.pas	Sun Aug 07 22:24:13 2011 +0400
@@ -46,9 +46,13 @@
     if GameState <> gsConfirm then
     begin
         prevGState:= GameState;
-        GameState:= gsConfirm
+        GameState:= gsConfirm;
+        SDL_ShowCursor(1)
     end else
-    GameState:= prevGState
+    begin
+        GameState:= prevGState;
+        SDL_ShowCursor(0)
+    end
 end;
 
 procedure chForceQuit(var s: shortstring);
--- a/hedgewars/uWorld.pas	Sun Aug 07 22:20:52 2011 +0400
+++ b/hedgewars/uWorld.pas	Sun Aug 07 22:24:13 2011 +0400
@@ -1318,7 +1318,7 @@
 procedure onFocusStateChanged;
 begin
 if (not cHasFocus) and (GameState <> gsConfirm) then
-    ParseCommand('quit', true)
+    ParseCommand('quit', true);
 end;