Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/interface/interface_context_menu.c
| Show First 20 Lines • Show All 1,236 Lines • ▼ Show 20 Lines | |||||
| } | } | ||||
| /** \} */ | /** \} */ | ||||
| /* -------------------------------------------------------------------- */ | /* -------------------------------------------------------------------- */ | ||||
| /** \name Panel Context Menu | /** \name Panel Context Menu | ||||
| * \{ */ | * \{ */ | ||||
| /** | |||||
| * menu to show when right clicking on the panel header | |||||
| */ | |||||
| void ui_popup_context_menu_for_panel(bContext *C, ARegion *region, Panel *panel) | void ui_popup_context_menu_for_panel(bContext *C, ARegion *region, Panel *panel) | ||||
| { | { | ||||
| bScreen *screen = CTX_wm_screen(C); | bScreen *screen = CTX_wm_screen(C); | ||||
| const bool has_panel_category = UI_panel_category_is_visible(region); | const bool has_panel_category = UI_panel_category_is_visible(region); | ||||
| const bool any_item_visible = has_panel_category; | const bool any_item_visible = has_panel_category; | ||||
| if (!any_item_visible) { | if (!any_item_visible) { | ||||
| return; | return; | ||||
| Show All 34 Lines | |||||