|
Blender V4.5
|
#include <cfloat>#include <cstring>#include "MEM_guardedalloc.h"#include "BLI_listbase.h"#include "BLI_string.h"#include "BLI_utildefines.h"#include "BLT_translation.hh"#include "BKE_blender_user_menu.hh"#include "BKE_context.hh"#include "BKE_idprop.hh"#include "BKE_screen.hh"#include "WM_api.hh"#include "WM_types.hh"#include "ED_screen.hh"#include "UI_interface.hh"#include "UI_resources.hh"#include "RNA_access.hh"#include "RNA_path.hh"#include "RNA_prototypes.hh"Go to the source code of this file.
Definition at line 82 of file screen_user_menu.cc.
References BKE_blender_user_menu_ensure(), C, CTX_wm_space_data(), ED_screen_user_menu_ensure(), screen_menu_context_string(), SpaceLink::spacetype, and U.
Referenced by ED_screen_user_menu_ensure(), and ui_popup_context_menu_for_button().
Definition at line 167 of file screen_user_menu.cc.
References BKE_blender_user_menu_item_add(), ED_screen_user_menu_item_add_menu(), MenuType::idname, bUserMenuItem_Menu::item, MenuType::label, bUserMenuItem_Menu::mt_idname, STREQ, STRNCPY(), bUserMenuItem::ui_name, and USER_MENU_TYPE_MENU.
Referenced by ED_screen_user_menu_item_add_menu(), and ui_but_user_menu_add().
| void ED_screen_user_menu_item_add_operator | ( | ListBase * | lb, |
| const char * | ui_name, | ||
| const wmOperatorType * | ot, | ||
| const IDProperty * | prop, | ||
| const char * | op_prop_enum, | ||
| wmOperatorCallContext | opcontext ) |
Definition at line 149 of file screen_user_menu.cc.
References BKE_blender_user_menu_item_add(), ED_screen_user_menu_item_add_operator(), wmOperatorType::idname, IDP_CopyProperty(), bUserMenuItem_Op::item, wmOperatorType::name, bUserMenuItem_Op::op_idname, bUserMenuItem_Op::op_prop_enum, bUserMenuItem_Op::opcontext, bUserMenuItem_Op::prop, STREQ, STRNCPY(), bUserMenuItem::ui_name, and USER_MENU_TYPE_OPERATOR.
Referenced by ED_screen_user_menu_item_add_operator(), and ui_but_user_menu_add().
| void ED_screen_user_menu_item_add_prop | ( | ListBase * | lb, |
| const char * | ui_name, | ||
| const char * | context_data_path, | ||
| const char * | prop_id, | ||
| int | prop_index ) |
Definition at line 177 of file screen_user_menu.cc.
References BKE_blender_user_menu_item_add(), bUserMenuItem_Prop::context_data_path, ED_screen_user_menu_item_add_prop(), bUserMenuItem_Prop::item, bUserMenuItem_Prop::prop_id, bUserMenuItem_Prop::prop_index, STRNCPY(), bUserMenuItem::ui_name, and USER_MENU_TYPE_PROP.
Referenced by ED_screen_user_menu_item_add_prop(), and ui_but_user_menu_add().
| bUserMenuItem_Menu * ED_screen_user_menu_item_find_menu | ( | ListBase * | lb, |
| const MenuType * | mt ) |
Definition at line 118 of file screen_user_menu.cc.
References ED_screen_user_menu_item_find_menu(), MenuType::idname, LISTBASE_FOREACH, bUserMenuItem_Menu::mt_idname, STREQ, and USER_MENU_TYPE_MENU.
Referenced by ED_screen_user_menu_item_find_menu(), and ui_but_user_menu_find().
| bUserMenuItem_Op * ED_screen_user_menu_item_find_operator | ( | ListBase * | lb, |
| const wmOperatorType * | ot, | ||
| IDProperty * | prop, | ||
| const char * | op_prop_enum, | ||
| wmOperatorCallContext | opcontext ) |
Finds a menu item associated with an operator in user menus (aka Quick Favorites)
| op_prop_enum | name of an operator property when the operator is called with an enum (to be an empty string otherwise) |
Definition at line 95 of file screen_user_menu.cc.
References ED_screen_user_menu_item_find_operator(), wmOperatorType::idname, IDP_EqualsProperties_ex(), LISTBASE_FOREACH, bUserMenuItem_Op::op_idname, bUserMenuItem_Op::op_prop_enum, bUserMenuItem_Op::opcontext, bUserMenuItem_Op::prop, STREQ, and USER_MENU_TYPE_OPERATOR.
Referenced by ED_screen_user_menu_item_find_operator(), and ui_but_user_menu_find().
| bUserMenuItem_Prop * ED_screen_user_menu_item_find_prop | ( | ListBase * | lb, |
| const char * | context_data_path, | ||
| const char * | prop_id, | ||
| int | prop_index ) |
Definition at line 131 of file screen_user_menu.cc.
References bUserMenuItem_Prop::context_data_path, ED_screen_user_menu_item_find_prop(), LISTBASE_FOREACH, bUserMenuItem_Prop::prop_id, bUserMenuItem_Prop::prop_index, STREQ, and USER_MENU_TYPE_PROP.
Referenced by ED_screen_user_menu_item_find_prop(), and ui_but_user_menu_find().
| void ED_screen_user_menu_item_remove | ( | ListBase * | lb, |
| bUserMenuItem * | umi ) |
Definition at line 191 of file screen_user_menu.cc.
References BKE_blender_user_menu_item_free(), BLI_remlink(), and ED_screen_user_menu_item_remove().
Referenced by ED_screen_user_menu_item_remove(), and ui_popup_context_menu_for_button().
| void ED_screen_user_menu_register | ( | ) |
Definition at line 322 of file screen_user_menu.cc.
References BLT_I18NCONTEXT_DEFAULT_BPYRNA, MenuType::draw, ED_screen_user_menu_register(), MenuType::idname, MenuType::label, MEM_callocN(), N_, screen_user_menu_draw(), STRNCPY(), MenuType::translation_context, and WM_menutype_add().
Referenced by ED_screen_user_menu_register(), and ED_spacetypes_init().
Definition at line 56 of file screen_user_menu.cc.
References BKE_blender_user_menu_find(), C, CTX_data_mode_string(), CTX_wm_space_data(), ED_screen_user_menus_find(), MEM_calloc_arrayN(), screen_menu_context_string(), SPACE_PROPERTIES, SPACE_TOPBAR, SPACE_VIEW3D, SpaceLink::spacetype, and U.
Referenced by ED_screen_user_menus_find(), screen_user_menu_draw(), and ui_popup_context_menu_for_button().
Definition at line 41 of file screen_user_menu.cc.
References C, CTX_data_mode_string(), screen_menu_context_string(), SPACE_NODE, SpaceLink::spacetype, and SpaceNode::tree_idname.
Referenced by ED_screen_user_menu_ensure(), ED_screen_user_menus_find(), and screen_menu_context_string().
Definition at line 203 of file screen_user_menu.cc.
References C, bUserMenuItem_Prop::context_data_path, CTX_data_pointer_get(), CTX_IFACE_, PointerRNA::data_as(), ED_screen_user_menus_find(), IDP_CopyPropertyContent(), bUserMenu::items, uiLayout::label(), Menu::layout, LISTBASE_FOREACH, MEM_freeN(), uiLayout::menu(), bUserMenuItem_Menu::mt_idname, uiLayout::op(), bUserMenuItem_Op::op_idname, bUserMenuItem_Op::op_prop_enum, bUserMenuItem_Op::opcontext, bUserMenuItem_Op::prop, uiLayout::prop(), bUserMenuItem_Prop::prop_id, bUserMenuItem_Prop::prop_index, RNA_path_resolve_full(), RNA_pointer_create_discrete(), RNA_struct_find_property(), RPT_, screen_user_menu_draw(), uiLayout::separator(), SNPRINTF, PointerRNA::type, UI_ITEM_NONE, uiItemMenuEnumFullO_ptr(), USER_MENU_TYPE_MENU, USER_MENU_TYPE_OPERATOR, USER_MENU_TYPE_PROP, USER_MENU_TYPE_SEP, WM_menutype_find(), and WM_operatortype_find().
Referenced by ED_screen_user_menu_register(), and screen_user_menu_draw().