diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-07-02 12:47:00 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-07-02 12:51:31 +0300 |
commit | b88e51dd55c62bdc160f33f9b2ae1727a892560a (patch) | |
tree | c9b9e00d51be18250df443c47ad31b1341a50f01 /source/blender/windowmanager/intern/wm_operators.c | |
parent | bfbfb1c47e8c60732f45638513ed7e39bedc730a (diff) |
Cleanup: use bool for poll functions
Diffstat (limited to 'source/blender/windowmanager/intern/wm_operators.c')
-rw-r--r-- | source/blender/windowmanager/intern/wm_operators.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c index ed2cb1134d8..b81790abaad 100644 --- a/source/blender/windowmanager/intern/wm_operators.c +++ b/source/blender/windowmanager/intern/wm_operators.c @@ -1265,7 +1265,7 @@ bool WM_operator_filesel_ensure_ext_imtype(wmOperator *op, const struct ImageFor } /* op->poll */ -int WM_operator_winactive(bContext *C) +bool WM_operator_winactive(bContext *C) { if (CTX_wm_window(C) == NULL) return 0; return 1; @@ -2028,7 +2028,7 @@ static int wm_search_menu_invoke(bContext *C, wmOperator *UNUSED(op), const wmEv } /* op->poll */ -static int wm_search_menu_poll(bContext *C) +static bool wm_search_menu_poll(bContext *C) { if (CTX_wm_window(C) == NULL) { return 0; @@ -2115,7 +2115,7 @@ static void WM_OT_call_menu_pie(wmOperatorType *ot) /* this poll functions is needed in place of WM_operator_winactive * while it crashes on full screen */ -static int wm_operator_winactive_normal(bContext *C) +static bool wm_operator_winactive_normal(bContext *C) { wmWindow *win = CTX_wm_window(C); @@ -2212,8 +2212,9 @@ static void WM_OT_console_toggle(wmOperatorType *ot) * - draw(bContext): drawing callback for paint cursor */ -void *WM_paint_cursor_activate(wmWindowManager *wm, int (*poll)(bContext *C), - wmPaintCursorDraw draw, void *customdata) +void *WM_paint_cursor_activate( + wmWindowManager *wm, bool (*poll)(bContext *C), + wmPaintCursorDraw draw, void *customdata) { wmPaintCursor *pc = MEM_callocN(sizeof(wmPaintCursor), "paint cursor"); |