- Moved all BorderNeedRefresh and SB_state updating code into separate functions that won't crash if screen is NULL.
SVN r4167 (trunk)
This commit is contained in:
parent
01fed92920
commit
be0845acf1
22 changed files with 85 additions and 45 deletions
|
|
@ -41,6 +41,7 @@
|
|||
#include "farchive.h"
|
||||
#include "r_renderer.h"
|
||||
#include "r_sky.h"
|
||||
#include "sbar.h"
|
||||
|
||||
#include "m_cheat.h"
|
||||
#include "i_system.h"
|
||||
|
|
@ -1081,7 +1082,7 @@ void AM_Stop ()
|
|||
{
|
||||
automapactive = false;
|
||||
stopped = true;
|
||||
BorderNeedRefresh = screen->GetPageCount ();
|
||||
V_SetBorderNeedRefresh();
|
||||
viewactive = true;
|
||||
}
|
||||
|
||||
|
|
@ -1180,7 +1181,7 @@ void AM_ToggleMap ()
|
|||
if (dmflags2 & DF2_NO_AUTOMAP)
|
||||
return;
|
||||
|
||||
SB_state = screen->GetPageCount ();
|
||||
ST_SetNeedRefresh();
|
||||
if (!automapactive)
|
||||
{
|
||||
AM_Start ();
|
||||
|
|
@ -1191,7 +1192,7 @@ void AM_ToggleMap ()
|
|||
if (am_overlay==1 && viewactive)
|
||||
{
|
||||
viewactive = false;
|
||||
SB_state = screen->GetPageCount ();
|
||||
ST_SetNeedRefresh();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue