MCPcopy Create free account
hub / github.com/OpenDUNE/OpenDUNE / GUI_Mouse_Show_InRegion

Function GUI_Mouse_Show_InRegion

src/gui/gui.c:3976–3996  ·  view source on GitHub ↗

* Show the mouse if needed. Should be used in combination with * #GUI_Mouse_Hide_InRegion(). */

Source from the content-addressed store, hash-verified

3974 * #GUI_Mouse_Hide_InRegion().
3975 */
3976void GUI_Mouse_Show_InRegion(void)
3977{
3978 uint8 counter;
3979
3980 while (g_mouseLock != 0) sleepIdle();
3981 g_mouseLock++;
3982
3983 counter = g_regionFlags & 0xFF;
3984 if (counter == 0 || --counter != 0) {
3985 g_regionFlags = (g_regionFlags & 0xFF00) | (counter & 0xFF);
3986 g_mouseLock--;
3987 return;
3988 }
3989
3990 if ((g_regionFlags & 0x4000) != 0) {
3991 GUI_Mouse_Show();
3992 }
3993
3994 g_regionFlags = 0;
3995 g_mouseLock--;
3996}
3997
3998/**
3999 * Hide the mouse when it is inside the specified region. Works with

Callers 15

GUI_Screen_FadeInFunction · 0.85
GUI_Screen_FadeIn2Function · 0.85
GUI_Mouse_Show_InWidgetFunction · 0.85
GUI_Widget_DrawBlockedFunction · 0.85
GUI_Widget_DrawFunction · 0.85
GUI_Widget_DrawBorderFunction · 0.85
GUI_Mentat_AnimationFunction · 0.85

Calls 1

GUI_Mouse_ShowFunction · 0.85

Tested by

no test coverage detected