[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Pingus-CVS] CVS: Games/Pingus/src screen_manager.cxx,1.11,1.12
From: |
grumbel |
Subject: |
[Pingus-CVS] CVS: Games/Pingus/src screen_manager.cxx,1.11,1.12 |
Date: |
17 Aug 2002 11:50:11 -0000 |
Update of /usr/local/cvsroot/Games/Pingus/src
In directory dark:/tmp/cvs-serv21795
Modified Files:
screen_manager.cxx
Log Message:
- fixed little glitch in the screen switch procedure
Index: screen_manager.cxx
===================================================================
RCS file: /usr/local/cvsroot/Games/Pingus/src/screen_manager.cxx,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- screen_manager.cxx 17 Aug 2002 00:30:53 -0000 1.11
+++ screen_manager.cxx 17 Aug 2002 11:50:09 -0000 1.12
@@ -61,6 +61,7 @@
{
Screen* current_screen = screens.back ().first;
float time_delta = delta_manager.getset ();
+ int num_screens = screens.size ();
if (time_delta > 1.0)
{
@@ -80,21 +81,26 @@
last_screen = current_screen;
// Most likly the screen will get changed in this update call
- current_screen->update (delta);
- current_screen->draw ();
-
- Display::flip_display ();
+ current_screen->update (delta);
if (cached_action == pop)
{
real_pop_screen ();
cached_action = none;
+ continue; // skip the draw once the screen has changed
}
else if (cached_action == replace)
{
real_replace_screen (replace_screen_arg.first,
replace_screen_arg.second);
cached_action = none;
+ continue; // skip the draw once the screen has changed
}
+
+ if (num_screens != screens.size ())
+ continue;
+
+ current_screen->draw ();
+ Display::flip_display ();
// Stupid hack to make this thing take less CPU
CL_System::sleep (0);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Pingus-CVS] CVS: Games/Pingus/src screen_manager.cxx,1.11,1.12,
grumbel <=
- Prev by Date:
[Pingus-CVS] CVS: Games/Pingus/src gui_screen.cxx,1.5,1.6 gui_screen.hxx,1.5,1.6 client.cxx,1.16,1.17 client.hxx,1.11,1.12
- Next by Date:
[Pingus-CVS] CVS: Games/Pingus/src screen_manager.cxx,1.12,1.13 screen_manager.hxx,1.8,1.9
- Previous by thread:
[Pingus-CVS] CVS: Games/Pingus/src gui_screen.cxx,1.5,1.6 gui_screen.hxx,1.5,1.6 client.cxx,1.16,1.17 client.hxx,1.11,1.12
- Next by thread:
[Pingus-CVS] CVS: Games/Pingus/src screen_manager.cxx,1.12,1.13 screen_manager.hxx,1.8,1.9
- Index(es):