From a6d90b4dfe687e365adf37413996d03d6110ad7a Mon Sep 17 00:00:00 2001 From: mcmartin Date: Sun, 2 Sep 2007 01:10:42 +0000 Subject: [PATCH] Have presentations request their own full-screen clears This will let custom ship spins use Presentations to display data over themselves without wiping out the underlyin image. git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@2845 8092fc87-c524-0410-9efc-e669fe64eaf9 --- sc2/ChangeLog | 2 ++ sc2/content/slides/ending/ending.txt | 7 ++++++- sc2/content/slides/intro/intro.txt | 6 ++++++ sc2/src/sc2code/intro.c | 4 ---- 4 files changed, 14 insertions(+), 5 deletions(-) diff --git a/sc2/ChangeLog b/sc2/ChangeLog index 127f2d83f..a7c87da56 100644 --- a/sc2/ChangeLog +++ b/sc2/ChangeLog @@ -1,4 +1,6 @@ Changes towards version 0.7: +- ShowPresentation() no longer clears the screen by force; presentations + now do this by request - Michael - Added match_matchPatternOnce() - SvdB - Fixed a problem with blue ships after Avatar's tractor beam, along with some other fill-stamp situations; bug #929 - Alex diff --git a/sc2/content/slides/ending/ending.txt b/sc2/content/slides/ending/ending.txt index 7c503a6bf..95c2cb06a 100644 --- a/sc2/content/slides/ending/ending.txt +++ b/sc2/content/slides/ending/ending.txt @@ -2,11 +2,16 @@ #(**** This script is a wrapper for 3 sequences ****) +#(Clear entire screen first; set size...) +DIMS 320 240 + +#(... and clear) +CLS + #(Set sequence dimensions; param1=width; param2=height) DIMS 320 200 #(Everything is drawn within the clipping rect defined by DIMS, from 0, 0) - #(Sequence 1 -- position the bomb) CALL slides/ending/victory1.txt diff --git a/sc2/content/slides/intro/intro.txt b/sc2/content/slides/intro/intro.txt index dc1a11c0b..9ced1d49f 100644 --- a/sc2/content/slides/intro/intro.txt +++ b/sc2/content/slides/intro/intro.txt @@ -5,6 +5,12 @@ #( you MUST change timing of a subtitle, make sure this change is ) #( balanced off by another subtitle within the same slide! ) +#(Clear entire screen first; set size...) +DIMS 320 240 + +#(... and clear) +CLS + #(Set sequence dimensions; param1=width; param2=height) DIMS 320 200 #(Everything is drawn within the clipping rect defined by DIMS, from 0, 0) diff --git a/sc2/src/sc2code/intro.c b/sc2/src/sc2code/intro.c index 590521acb..c422965e7 100644 --- a/sc2/src/sc2code/intro.c +++ b/sc2/src/sc2code/intro.c @@ -730,10 +730,6 @@ ShowPresentation (STRING PresStr) OldContext = SetContext (ScreenContext); GetContextClipRect (&OldRect); OldFont = SetContextFont (NULL); - /* paint black rect over screen */ - SetContextBackGroundColor ( - BUILD_COLOR (MAKE_RGB15 (0x00, 0x00, 0x00), 0x00)); - ClearDrawable (); UnlockMutex (GraphicsLock); FlushInput ();