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

Function GUI_Widget_DrawBlocked

src/gui/widget.c:99–112  ·  view source on GitHub ↗

* Draw a chess-pattern filled rectangle over the widget. * * @param w The widget to draw. * @param colour The colour of the chess pattern. */

Source from the content-addressed store, hash-verified

97 * @param colour The colour of the chess pattern.
98 */
99static void GUI_Widget_DrawBlocked(Widget *w, uint8 colour)
100{
101 if (GFX_Screen_IsActive(SCREEN_0)) {
102 GUI_Mouse_Hide_InRegion(w->offsetX, w->offsetY, w->offsetX + w->width, w->offsetY + w->height);
103 }
104
105 GUI_DrawSprite(SCREEN_ACTIVE, w->drawParameterNormal.sprite, w->offsetX, w->offsetY, w->parentID, 0);
106
107 GUI_DrawBlockedRectangle(w->offsetX, w->offsetY, w->width, w->height, colour);
108
109 if (GFX_Screen_IsActive(SCREEN_0)) {
110 GUI_Mouse_Show_InRegion();
111 }
112}
113
114/**
115 * Make the widget invisible.

Callers 1

GUI_Widget_DrawFunction · 0.85

Calls 5

GFX_Screen_IsActiveFunction · 0.85
GUI_Mouse_Hide_InRegionFunction · 0.85
GUI_DrawSpriteFunction · 0.85
GUI_DrawBlockedRectangleFunction · 0.85
GUI_Mouse_Show_InRegionFunction · 0.85

Tested by

no test coverage detected