# HG changeset patch # User koda # Date 1333903569 -7200 # Node ID 4d1ce4b4f7c686afc614c3481d6a81c34f5de09a # Parent 87e060b69926a85483bd9799c88b24cf2718d9fb formatting diff -r 87e060b69926 -r 4d1ce4b4f7c6 hedgewars/hwengine.pas --- a/hedgewars/hwengine.pas Sun Apr 08 18:11:37 2012 +0200 +++ b/hedgewars/hwengine.pas Sun Apr 08 18:46:09 2012 +0200 @@ -250,31 +250,31 @@ end; //end case event.type_ of end; //end while SDL_PollEvent(@event) <> 0 do - if (cScreenResizeDelay <> 0) and (cScreenResizeDelay < RealTicks) - and ((cNewScreenWidth <> cScreenWidth) or (cNewScreenHeight <> cScreenHeight)) then - begin - cScreenResizeDelay:= 0; - cScreenWidth:= cNewScreenWidth; - cScreenHeight:= cNewScreenHeight; + if (cScreenResizeDelay <> 0) and (cScreenResizeDelay < RealTicks) and + ((cNewScreenWidth <> cScreenWidth) or (cNewScreenHeight <> cScreenHeight)) then + begin + cScreenResizeDelay:= 0; + cScreenWidth:= cNewScreenWidth; + cScreenHeight:= cNewScreenHeight; - ParseCommand('fullscr '+intToStr(LongInt(cFullScreen)), true); - WriteLnToConsole('window resize: ' + IntToStr(cScreenWidth) + ' x ' + IntToStr(cScreenHeight)); - ScriptOnScreenResize(); - InitCameraBorders(); - InitTouchInterface(); - end; + ParseCommand('fullscr '+intToStr(LongInt(cFullScreen)), true); + WriteLnToConsole('window resize: ' + IntToStr(cScreenWidth) + ' x ' + IntToStr(cScreenHeight)); + ScriptOnScreenResize(); + InitCameraBorders(); + InitTouchInterface(); + end; - if isTerminated = false then - begin - CurrTime:= SDL_GetTicks; - if PrevTime + longword(cTimerInterval) <= CurrTime then - begin - DoTimer(CurrTime - PrevTime); - PrevTime:= CurrTime - end - else SDL_Delay(1); - IPCCheckSock(); - end; + if isTerminated = false then + begin + CurrTime:= SDL_GetTicks; + if PrevTime + longword(cTimerInterval) <= CurrTime then + begin + DoTimer(CurrTime - PrevTime); + PrevTime:= CurrTime + end + else SDL_Delay(1); + IPCCheckSock(); + end; end; end; diff -r 87e060b69926 -r 4d1ce4b4f7c6 hedgewars/uKeys.pas --- a/hedgewars/uKeys.pas Sun Apr 08 18:11:37 2012 +0200 +++ b/hedgewars/uKeys.pas Sun Apr 08 18:46:09 2012 +0200 @@ -138,9 +138,9 @@ // ctrl/cmd + q to close engine and frontend {$IFDEF DARWIN} if ((tkbdn[KeyNameToCode('left_meta')] = 1) or (tkbdn[KeyNameToCode('right_meta')] = 1)) then - {$ELSE} +{$ELSE} if ((tkbdn[KeyNameToCode('left_ctrl')] = 1) or (tkbdn[KeyNameToCode('right_ctrl')] = 1)) then - {$ENDIF} +{$ENDIF} begin if tkbdn[KeyNameToCode('q')] = 1 then ParseCommand ('halt', true) end;