Fix flashing when pressing the 'spin ship' button on an empty slot

or the flag ship.



git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@3741 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
Meep-Eep
2012-01-08 13:49:39 +00:00
parent a86e795d9e
commit 3da5e55c1c
+5 -8
View File
@@ -712,10 +712,7 @@ DMS_SpinShip (MENU_STATE *pMS, HSHIPFRAG hStarShip)
SetContextClipRect (&OldClipRect);
SetContext (OldContext);
if (hStarShip)
return TRUE;
return FALSE;
return TRUE;
}
#endif /* WANT_SHIP_SPINS */
@@ -985,9 +982,9 @@ DMS_AddEscortShip (MENU_STATE *pMS, BOOLEAN special, BOOLEAN select,
if (special)
{
HSHIPFRAG hStarShip = GetEscortByStarShipIndex (pMS->delta_item);
DMS_SpinShip (pMS, hStarShip);
LockMutex (GraphicsLock);
DMS_SetMode (pMS, DMS_Mode_addEscort);
if (DMS_SpinShip (pMS, hStarShip))
DMS_SetMode (pMS, DMS_Mode_addEscort);
UnlockMutex (GraphicsLock);
return;
}
@@ -1169,8 +1166,8 @@ DMS_NavigateShipSlots (MENU_STATE *pMS, BOOLEAN special, BOOLEAN select,
#else
if (special)
{
DMS_SpinShip (pMS, hStarShip);
DMS_SetMode (pMS, DMS_Mode_navigate);
if (DMS_SpinShip (pMS, hStarShip))
DMS_SetMode (pMS, DMS_Mode_navigate);
}
else
#endif /* WANT_SHIP_SPINS */