--- a/hedgewars/hwengine.pas Sun Feb 12 15:04:17 2012 +0100
+++ b/hedgewars/hwengine.pas Sun Feb 12 15:27:25 2012 +0100
@@ -267,7 +267,7 @@
ParseCommand('fullscr '+intToStr(LongInt(cFullScreen)), true);
WriteLnToConsole('window resize: ' + IntToStr(cScreenWidth) + ' x ' + IntToStr(cScreenHeight));
ScriptOnScreenResize();
- InitCameraBorders()
+ InitCameraBorders();
end;
if isTerminated = false then
--- a/hedgewars/options.inc Sun Feb 12 15:04:17 2012 +0100
+++ b/hedgewars/options.inc Sun Feb 12 15:27:25 2012 +0100
@@ -33,8 +33,9 @@
{$DEFINE S3D_DISABLED}
{$DEFINE GLunit:=gles11}
{$DEFINE MOBILE}
- {$DEFINE Java_Prefix := 'Java_org_hedgewars_hedgeroid_EngineProtocol_PascalExports_'}
+ {$DEFINE Java_Prefix:= 'Java_org_hedgewars_hedgeroid_EngineProtocol_PascalExports_'}
{$DEFINE USE_SDLTHREADS}
+ {$DEFINE USE_CONTEXT_RESTORE}
{$ENDIF}
{$IFDEF IPHONEOS}
@@ -45,8 +46,15 @@
{$DEFINE MOBILE}
{$ENDIF}
+{$IFDEF WIN32}
+ {$DEFINE USE_CONTEXT_RESTORE}
+{$ENDIF}
+
{$IFNDEF IPHONEOS}
- // not needed on ios because it is switched from the compiler command line arguments
+ {$IFDEF DARWIN}
+ {$DEFINE USE_CONTEXT_RESTORE}
+ {$ENDIF}
+ // not needed on ios because DEBUGFILE is switched from command line
{$DEFINE DEBUGFILE}
//{$DEFINE TRACEAIACTIONS}
//{$DEFINE COUNTTICKS}
--- a/hedgewars/uLocale.pas Sun Feb 12 15:04:17 2012 +0100
+++ b/hedgewars/uLocale.pas Sun Feb 12 15:27:25 2012 +0100
@@ -96,7 +96,7 @@
end;
end;
Close(f);
- {$IFNDEF IPHONEOS}WriteLnToConsole('Locale loaded "' + FileName + '"');{$ENDIF}
+ {$IFNDEF HWLIBRARY}WriteLnToConsole('Locale loaded "' + FileName + '"');{$ENDIF}
end;
{$I+}
end;
--- a/hedgewars/uStore.pas Sun Feb 12 15:04:17 2012 +0100
+++ b/hedgewars/uStore.pas Sun Feb 12 15:27:25 2012 +0100
@@ -126,7 +126,6 @@
r, rr: TSDL_Rect;
drY: LongInt;
texsurf, flagsurf, iconsurf: PSDL_Surface;
- s: shortstring;
begin
r.x:= 0;
r.y:= 0;
@@ -369,7 +368,7 @@
// This should maybe be flagged. It wastes quite a bit of memory.
if not reload then
begin
-{$IF DEFINED(DARWIN) OR DEFINED(WIN32) or DEFINED(ANDROID)}
+{$IFDEF USE_CONTEXT_RESTORE}
Surface:= tmpsurf
{$ELSE}
if saveSurf then
@@ -1030,7 +1029,7 @@
exit;
{$ELSE}
SetScale(cDefaultZoomLevel);
- {$IF DEFINED(DARWIN) OR DEFINED(WIN32) or DEFINED(ANDROID)}
+ {$IFDEF USE_CONTEXT_RESTORE}
reinit:= true;
StoreRelease(true);
ResetLand;