aboutsummaryrefslogtreecommitdiffstats
path: root/include/gfx_rules.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/gfx_rules.h')
-rw-r--r--include/gfx_rules.h48
1 files changed, 30 insertions, 18 deletions
diff --git a/include/gfx_rules.h b/include/gfx_rules.h
index 4b7e9506..7e14ef9d 100644
--- a/include/gfx_rules.h
+++ b/include/gfx_rules.h
@@ -46,38 +46,50 @@
#warning "GWIN: Drawing can occur outside the defined windows as GDISP_NEED_CLIP is FALSE"
#endif
#endif
- #if GWIN_NEED_BUTTON
- #if !GDISP_NEED_TEXT
- #error "GWIN: GDISP_NEED_TEXT is required if GWIN_NEED_BUTTON is TRUE."
- #endif
- #if !GFX_USE_GEVENT
+ #if GWIN_NEED_WINDOWMANAGER
+ #if !GFX_USE_GQUEUE || !GQUEUE_NEED_ASYNC
#if GFX_DISPLAY_RULE_WARNINGS
- #warning "GWIN: GFX_USE_GEVENT is required if GWIN_NEED_BUTTON is TRUE. It has been turned on for you."
+ #warning "GWIN: GFX_USE_GQUEUE and GQUEUE_NEED_ASYNC is required if GWIN_NEED_WINDOWMANAGER is TRUE. It has been turned on for you."
#endif
- #undef GFX_USE_GEVENT
- #define GFX_USE_GEVENT TRUE
+ #undef GFX_USE_GQUEUE
+ #undef GQUEUE_NEED_ASYNC
+ #define GFX_USE_GQUEUE TRUE
+ #define GQUEUE_NEED_ASYNC TRUE
#endif
- #if !GFX_USE_GINPUT || !(GINPUT_NEED_MOUSE || GINPUT_NEED_TOGGLE)
+ #endif
+ #if GWIN_NEED_CONSOLE
+ #if !GDISP_NEED_TEXT
+ #error "GWIN: GDISP_NEED_TEXT is required if GWIN_NEED_CONSOLE is TRUE."
+ #endif
+ #endif
+ #if GWIN_NEED_GRAPH
+ #endif
+ #if GWIN_NEED_BUTTON || GWIN_NEED_SLIDER || GWIN_NEED_CHECKBOX
+ #if !GWIN_NEED_WIDGET
#if GFX_DISPLAY_RULE_WARNINGS
- #warning "GWIN: You have set GWIN_NEED_BUTTON to TRUE but no supported GINPUT (mouse/toggle) devices have been included"
+ #warning "GWIN: GWIN_NEED_WIDGET is required when a Widget is used. It has been turned on for you."
#endif
+ #undef GWIN_NEED_WIDGET
+ #define GWIN_NEED_WIDGET TRUE
+ #endif
+ #endif
+ #if GWIN_NEED_WIDGET
+ #if !GDISP_NEED_TEXT
+ #error "GWIN: GDISP_NEED_TEXT is required if GWIN_NEED_WIDGET is TRUE."
+ #endif
+ #if !GFX_USE_GINPUT
+ // This test also ensures that GFX_USE_GEVENT is set
+ #error "GWIN: GFX_USE_GINPUT (and one or more input sources) is required if GWIN_NEED_WIDGET is TRUE"
#endif
#if !GDISP_NEED_MULTITHREAD && !GDISP_NEED_ASYNC
#if GFX_DISPLAY_RULE_WARNINGS
- #warning "GWIN: Either GDISP_NEED_MULTITHREAD or GDISP_NEED_ASYNC is required if GWIN_NEED_BUTTON is TRUE."
+ #warning "GWIN: Either GDISP_NEED_MULTITHREAD or GDISP_NEED_ASYNC is required if GWIN_NEED_WIDGET is TRUE."
#warning "GWIN: GDISP_NEED_MULTITHREAD has been turned on for you."
#endif
#undef GDISP_NEED_MULTITHREAD
#define GDISP_NEED_MULTITHREAD TRUE
#endif
#endif
- #if GWIN_NEED_CONSOLE
- #if !GDISP_NEED_TEXT
- #error "GWIN: GDISP_NEED_TEXT is required if GWIN_NEED_CONSOLE is TRUE."
- #endif
- #endif
- #if GWIN_NEED_GRAPH
- #endif
#endif
#if GFX_USE_GINPUT