Blender
V3.3
|
#include "wm_gizmo_fn.h"
Go to the source code of this file.
Classes | |
struct | WM_GizmoMatrixParams |
void WM_gizmo_calc_matrix_final_params | ( | const struct wmGizmo * | gz, |
const struct WM_GizmoMatrixParams * | params, | ||
float | r_mat[4][4] | ||
) |
Definition at line 139 of file wm_gizmo_group.c.
References wmGizmo::f, and wmGizmo::temp.
Definition at line 152 of file wm_gizmo_group.c.
References wmGizmo::f, and wmGizmo::temp.
Referenced by gizmo_mesh_extrude_draw_prepare(), and WIDGETGROUP_xform_shear_draw_prepare().
bool WM_gizmo_context_check_drawstep | ( | const struct bContext * | C, |
eWM_GizmoFlagMapDrawStep | step | ||
) |
Definition at line 704 of file wm_gizmo.c.
References C, CTX_wm_manager(), ED_screen_animation_playing(), WM_GIZMOMAP_DRAWSTEP_2D, and WM_GIZMOMAP_DRAWSTEP_3D.
Referenced by WM_gizmomap_draw(), and wm_gizmomap_highlight_find().
void WM_gizmo_do_msg_notify_tag_refresh | ( | struct bContext * | C, |
struct wmMsgSubscribeKey * | msg_key, | ||
struct wmMsgSubscribeValue * | msg_val | ||
) |
Definition at line 126 of file wm_gizmo.c.
References BPY_DECREF_RNA_INVALIDATE(), wmGizmoProperty::custom_func, wmGizmoType::free, wmGizmoProperty::free_fn, MEM_freeN, NULL, wmGizmo::op_data, wmGizmo::op_data_len, wmGizmoOpElem::ptr, wmGizmo::ptr, wmGizmo::py_instance, wmGizmoType::target_property_defs_len, wmGizmo::type, WM_gizmo_properties_free(), WM_gizmo_target_property_array(), and WM_operator_properties_free().
Referenced by WM_gizmo_unlink(), and wm_gizmogroup_free().
void WM_gizmo_group_refresh | ( | const struct bContext * | C, |
struct wmGizmoGroup * | gzgroup | ||
) |
void WM_gizmo_group_remove_by_tool | ( | struct bContext * | C, |
struct Main * | bmain, | ||
const struct wmGizmoGroupType * | gzgt, | ||
const struct bToolRef * | tref | ||
) |
void WM_gizmo_group_tag_remove | ( | struct wmGizmoGroup * | gzgroup | ) |
Definition at line 122 of file wm_gizmo_group.c.
References BLI_assert, wmGizmoGroup::parent_gzmap, wmGizmoGroup::tag_remove, wmGizmoGroup::type, wmGizmoGroupType::users, and WM_gizmoconfig_update_tag_group_remove().
Referenced by WM_gizmo_group_unlink_delayed_ptr_from_space(), and WM_gizmomaptype_group_init_runtime_with_region().
void WM_gizmo_group_type_add | ( | const char * | idname | ) |
Definition at line 1104 of file wm_gizmo_group.c.
References BLI_assert, NULL, WM_gizmo_group_type_add_ptr(), and WM_gizmogrouptype_find().
void WM_gizmo_group_type_add_ptr | ( | struct wmGizmoGroupType * | gzgt | ) |
Definition at line 1099 of file wm_gizmo_group.c.
References wmGizmoGroupType::gzmap_params, WM_gizmo_group_type_add_ptr_ex(), and WM_gizmomaptype_ensure().
Referenced by WM_gizmo_group_type_add().
void WM_gizmo_group_type_add_ptr_ex | ( | struct wmGizmoGroupType * | gzgt, |
struct wmGizmoMapType * | gzmap_type | ||
) |
Definition at line 1093 of file wm_gizmo_group.c.
References WM_gizmoconfig_update_tag_group_type_init(), and WM_gizmomaptype_group_link_ptr().
Referenced by WM_gizmo_group_type_add_ptr(), WM_gizmo_group_type_ensure_ptr_ex(), and WM_gizmo_group_type_reinit_ptr_ex().
bool WM_gizmo_group_type_ensure | ( | const char * | idname | ) |
Definition at line 1125 of file wm_gizmo_group.c.
References BLI_assert, NULL, WM_gizmo_group_type_ensure_ptr(), and WM_gizmogrouptype_find().
Referenced by mesh_bisect_modal(), and view3d_interactive_add_invoke().
bool WM_gizmo_group_type_ensure_ptr | ( | struct wmGizmoGroupType * | gzgt | ) |
Definition at line 1120 of file wm_gizmo_group.c.
References wmGizmoGroupType::gzmap_params, WM_gizmo_group_type_ensure_ptr_ex(), and WM_gizmomaptype_ensure().
Referenced by add_primitive_cube_gizmo_invoke(), edbm_spin_invoke(), toolsystem_ref_link(), and WM_gizmo_group_type_ensure().
bool WM_gizmo_group_type_ensure_ptr_ex | ( | struct wmGizmoGroupType * | gzgt, |
struct wmGizmoMapType * | gzmap_type | ||
) |
Definition at line 1111 of file wm_gizmo_group.c.
References NULL, WM_gizmo_group_type_add_ptr_ex(), and WM_gizmomaptype_group_find_ptr().
Referenced by WM_gizmo_group_type_ensure_ptr(), and wm_handler_operator_call().
bool WM_gizmo_group_type_free | ( | const char * | idname | ) |
Definition at line 150 of file wm_gizmo_group_type.c.
References BLI_ghash_lookup(), global_gizmogrouptype_hash, NULL, and WM_gizmo_group_type_free_ptr().
void WM_gizmo_group_type_free_ptr | ( | wmGizmoGroupType * | gzgt | ) |
Definition at line 139 of file wm_gizmo_group_type.c.
References BLI_assert, BLI_ghash_remove(), gizmogrouptype_free(), global_gizmogrouptype_hash, wmGizmoGroupType::idname, NULL, and WM_gizmogrouptype_find().
Referenced by WM_gizmo_group_type_free().
bool WM_gizmo_group_type_poll | ( | const struct bContext * | C, |
const struct wmGizmoGroupType * | gzgt | ||
) |
Definition at line 1165 of file wm_gizmo_group.c.
References BLI_assert, NULL, WM_gizmo_group_type_reinit_ptr(), and WM_gizmogrouptype_find().
void WM_gizmo_group_type_reinit_ptr | ( | struct Main * | bmain, |
struct wmGizmoGroupType * | gzgt | ||
) |
Definition at line 1160 of file wm_gizmo_group.c.
References wmGizmoGroupType::gzmap_params, WM_gizmo_group_type_reinit_ptr_ex(), and WM_gizmomaptype_ensure().
Referenced by add_primitive_cube_gizmo_invoke(), edbm_spin_invoke(), and WM_gizmo_group_type_reinit().
void WM_gizmo_group_type_reinit_ptr_ex | ( | struct Main * | bmain, |
struct wmGizmoGroupType * | gzgt, | ||
struct wmGizmoMapType * | gzmap_type | ||
) |
Has the result of unlinking and linking (re-initializes gizmo's).
Definition at line 1150 of file wm_gizmo_group.c.
References BLI_assert, NULL, UNUSED_VARS_NDEBUG, WM_gizmo_group_type_add_ptr_ex(), WM_gizmomaptype_group_find_ptr(), and WM_gizmomaptype_group_unlink().
Referenced by WM_gizmo_group_type_reinit_ptr().
Definition at line 1143 of file wm_gizmo_group.c.
References BLI_assert, NULL, WM_gizmo_group_type_remove_ptr(), and WM_gizmogrouptype_find().
void WM_gizmo_group_type_remove_ptr | ( | struct Main * | bmain, |
struct wmGizmoGroupType * | gzgt | ||
) |
Definition at line 1138 of file wm_gizmo_group.c.
References wmGizmoGroupType::gzmap_params, WM_gizmo_group_type_remove_ptr_ex(), and WM_gizmomaptype_ensure().
Referenced by WM_gizmo_group_type_remove().
void WM_gizmo_group_type_remove_ptr_ex | ( | struct Main * | bmain, |
struct wmGizmoGroupType * | gzgt, | ||
struct wmGizmoMapType * | gzmap_type | ||
) |
Call WM_gizmo_group_type_free_ptr after to remove & free.
Definition at line 1132 of file wm_gizmo_group.c.
References NULL, and WM_gizmomaptype_group_unlink().
Referenced by WM_gizmo_group_type_remove_ptr().
void WM_gizmo_group_type_unlink_delayed | ( | const char * | idname | ) |
Definition at line 1185 of file wm_gizmo_group.c.
References BLI_assert, NULL, WM_gizmo_group_type_unlink_delayed_ptr(), and WM_gizmogrouptype_find().
void WM_gizmo_group_type_unlink_delayed_ptr | ( | struct wmGizmoGroupType * | gzgt | ) |
Definition at line 1179 of file wm_gizmo_group.c.
References wmGizmoGroupType::gzmap_params, WM_gizmo_group_type_unlink_delayed_ptr_ex(), and WM_gizmomaptype_ensure().
Referenced by ED_gizmo_poll_or_unlink_delayed_from_operator(), ED_gizmo_poll_or_unlink_delayed_from_tool_ex(), and WM_gizmo_group_type_unlink_delayed().
void WM_gizmo_group_type_unlink_delayed_ptr_ex | ( | struct wmGizmoGroupType * | gzgt, |
struct wmGizmoMapType * | gzmap_type | ||
) |
Definition at line 1174 of file wm_gizmo_group.c.
References WM_gizmoconfig_update_tag_group_type_remove().
Referenced by WM_gizmo_group_type_unlink_delayed_ptr().
void WM_gizmo_group_unlink_delayed_ptr_from_space | ( | struct wmGizmoGroupType * | gzgt, |
struct wmGizmoMapType * | gzmap_type, | ||
struct ScrArea * | area | ||
) |
Definition at line 1192 of file wm_gizmo_group.c.
References blender::compositor::area(), wmGizmoMap::groups, LISTBASE_FOREACH, wmGizmoMap::type, and WM_gizmo_group_tag_remove().
Referenced by ED_gizmo_poll_or_unlink_delayed_from_tool_ex().
bool WM_gizmo_highlight_set | ( | struct wmGizmoMap * | gzmap, |
struct wmGizmo * | gz | ||
) |
Definition at line 402 of file wm_gizmo.c.
References wmGizmo::highlight_part, NULL, and wm_gizmomap_highlight_set().
Referenced by ED_screen_set_active_region(), view3d_ruler_add_invoke(), and WM_gizmo_modal_set_from_setup().
struct wmKeyMap* WM_gizmo_keymap_generic | ( | struct wmWindowManager * | wm | ) |
Definition at line 868 of file wm_gizmo_group.c.
References wmWindowManager::defaultconf, and WM_gizmo_keymap_generic_with_keyconfig().
struct wmKeyMap* WM_gizmo_keymap_generic_click_drag | ( | struct wmWindowManager * | wm | ) |
Definition at line 898 of file wm_gizmo_group.c.
References wmWindowManager::defaultconf, and WM_gizmo_keymap_generic_click_drag_with_keyconfig().
Referenced by WIDGETGROUP_navigate_setup().
struct wmKeyMap* WM_gizmo_keymap_generic_click_drag_with_keyconfig | ( | struct wmKeyConfig * | kc | ) |
Definition at line 893 of file wm_gizmo_group.c.
References wmKeyMap::idname, RGN_TYPE_WINDOW, SPACE_EMPTY, and WM_keymap_ensure().
Referenced by WM_gizmo_keymap_generic_click_drag().
struct wmKeyMap* WM_gizmo_keymap_generic_drag | ( | struct wmWindowManager * | wm | ) |
Definition at line 888 of file wm_gizmo_group.c.
References wmWindowManager::defaultconf, and WM_gizmo_keymap_generic_drag_with_keyconfig().
struct wmKeyMap* WM_gizmo_keymap_generic_drag_with_keyconfig | ( | struct wmKeyConfig * | kc | ) |
Definition at line 883 of file wm_gizmo_group.c.
References wmKeyMap::idname, RGN_TYPE_WINDOW, SPACE_EMPTY, and WM_keymap_ensure().
Referenced by WM_gizmo_keymap_generic_drag(), and WM_gizmogroup_setup_keymap_generic_drag().
struct wmKeyMap* WM_gizmo_keymap_generic_maybe_drag | ( | struct wmWindowManager * | wm | ) |
Definition at line 908 of file wm_gizmo_group.c.
References wmWindowManager::defaultconf, and WM_gizmo_keymap_generic_maybe_drag_with_keyconfig().
struct wmKeyMap* WM_gizmo_keymap_generic_maybe_drag_with_keyconfig | ( | struct wmKeyConfig * | kc | ) |
Drag or press depending on preference.
Definition at line 903 of file wm_gizmo_group.c.
References wmKeyMap::idname, RGN_TYPE_WINDOW, SPACE_EMPTY, and WM_keymap_ensure().
Referenced by WM_gizmo_keymap_generic_maybe_drag(), and WM_gizmogroup_setup_keymap_generic_maybe_drag().
struct wmKeyMap* WM_gizmo_keymap_generic_select | ( | struct wmWindowManager * | wm | ) |
Definition at line 878 of file wm_gizmo_group.c.
References wmWindowManager::defaultconf, and WM_gizmo_keymap_generic_select_with_keyconfig().
struct wmKeyMap* WM_gizmo_keymap_generic_select_with_keyconfig | ( | struct wmKeyConfig * | kc | ) |
Definition at line 873 of file wm_gizmo_group.c.
References wmKeyMap::idname, RGN_TYPE_WINDOW, SPACE_EMPTY, and WM_keymap_ensure().
Referenced by WM_gizmo_keymap_generic_select().
struct wmKeyMap* WM_gizmo_keymap_generic_with_keyconfig | ( | struct wmKeyConfig * | kc | ) |
Definition at line 863 of file wm_gizmo_group.c.
References wmKeyMap::idname, RGN_TYPE_WINDOW, SPACE_EMPTY, and WM_keymap_ensure().
Referenced by WM_gizmo_keymap_generic(), and WM_gizmogroup_setup_keymap_generic().
void WM_gizmo_modal_set_from_setup | ( | struct wmGizmoMap * | gzmap, |
struct bContext * | C, | ||
struct wmGizmo * | gz, | ||
int | part_index, | ||
const struct wmEvent * | event | ||
) |
Special function to run from setup so gizmos start out interactive.
We could do this when linking them, but this complicates things since the window update code needs to run first.
struct wmGizmo* WM_gizmo_new | ( | const char * | idname, |
struct wmGizmoGroup * | gzgroup, | ||
struct PointerRNA * | properties | ||
) |
idname | Must be a valid gizmo type name, if you need to check it exists use WM_gizmo_new_ptr because callers of this function don't NULL check the return value. |
Definition at line 94 of file wm_gizmo.c.
References WM_gizmo_new_ptr(), and WM_gizmotype_find().
Referenced by tool_generic_create_gizmo(), WIDGETGROUP_camera_view_setup(), WIDGETGROUP_empty_image_setup(), WIDGETGROUP_forcefield_setup(), WIDGETGROUP_light_area_setup(), WIDGETGROUP_light_spot_setup(), WIDGETGROUP_light_target_setup(), WIDGETGROUP_navigate_setup(), blender::ed::space_node::WIDGETGROUP_node_crop_setup(), blender::ed::space_node::WIDGETGROUP_node_sbeam_setup(), and blender::ed::space_node::WIDGETGROUP_node_transform_setup().
struct wmGizmo* WM_gizmo_new_ptr | ( | const struct wmGizmoType * | gzt, |
struct wmGizmoGroup * | gzgroup, | ||
struct PointerRNA * | properties | ||
) |
struct wmGizmoOpElem* WM_gizmo_operator_get | ( | struct wmGizmo * | gz, |
int | part_index | ||
) |
Definition at line 195 of file wm_gizmo.c.
References NULL, and wmGizmo::op_data.
Referenced by gizmo2d_resize_invoke_prepare(), gizmo2d_xform_invoke_prepare(), gizmo_mesh_extrude_invoke_prepare(), gizmo_mesh_extrude_setup(), gizmo_modal(), gizmo_tweak_start_and_finish(), ui_tooltip_data_from_gizmo(), WIDGETGROUP_gizmo_invoke_prepare(), WIDGETGROUP_navigate_setup(), WIDGETGROUP_xform_cage_refresh(), WIDGETGROUP_xform_shear_refresh(), WIDGETGROUP_xform_shear_setup(), wm_gizmomap_modal_set(), and wm_gizmomaps_handled_modal_update().
int WM_gizmo_operator_invoke | ( | struct bContext * | C, |
struct wmGizmo * | gz, | ||
struct wmGizmoOpElem * | gzop, | ||
const struct wmEvent * | event | ||
) |
struct PointerRNA* WM_gizmo_operator_set | ( | struct wmGizmo * | gz, |
int | part_index, | ||
struct wmOperatorType * | ot, | ||
struct IDProperty * | properties | ||
) |
Definition at line 203 of file wm_gizmo.c.
References BLI_assert, PointerRNA::data, MEM_recallocN, wmGizmo::op_data, wmGizmo::op_data_len, ot, wmGizmoOpElem::ptr, wmGizmoOpElem::type, WM_operator_properties_create_ptr(), and WM_operator_properties_free().
Referenced by gizmo2d_resize_setup(), gizmo2d_rotate_setup(), gizmo2d_xform_setup(), gizmo_mesh_extrude_setup(), gizmo_mesh_spin_init_refresh_axis_orientation(), gizmogroup_init_properties_from_twtype(), WIDGETGROUP_light_target_setup(), WIDGETGROUP_navigate_setup(), WIDGETGROUP_ruler_setup(), WIDGETGROUP_xform_cage_setup(), and WIDGETGROUP_xform_shear_setup().
void WM_gizmo_properties_alloc | ( | struct PointerRNA ** | ptr, |
struct IDProperty ** | properties, | ||
const char * | gtstring | ||
) |
Similar to WM_gizmo_properties_create except its uses ID properties used for key-maps and macros.
Definition at line 590 of file wm_gizmo.c.
References IDP_GROUP, IDP_New(), MEM_callocN, NULL, ptr, and WM_gizmo_properties_create().
void WM_gizmo_properties_clear | ( | struct PointerRNA * | ptr | ) |
Definition at line 679 of file wm_gizmo.c.
References PointerRNA::data, IDP_ClearProperty(), and ptr.
void WM_gizmo_properties_create | ( | struct PointerRNA * | ptr, |
const char * | gtstring | ||
) |
Definition at line 578 of file wm_gizmo.c.
References NULL, ptr, RNA_pointer_create(), WM_gizmo_properties_create_ptr(), and WM_gizmotype_find().
Referenced by WM_gizmo_properties_alloc().
void WM_gizmo_properties_create_ptr | ( | struct PointerRNA * | ptr, |
struct wmGizmoType * | gzt | ||
) |
Definition at line 573 of file wm_gizmo.c.
References NULL, ptr, RNA_pointer_create(), and wmGizmoType::srna.
Referenced by WM_gizmo_properties_create().
bool WM_gizmo_properties_default | ( | struct PointerRNA * | ptr, |
bool | do_update | ||
) |
Set all props to their default.
do_update | Only update un-initialized props. |
Definition at line 634 of file wm_gizmo.c.
References PROP_POINTER, ptr, RNA_property_is_set(), RNA_property_pointer_get(), RNA_property_pointer_type(), RNA_property_reset(), RNA_property_type(), RNA_STRUCT_BEGIN, and RNA_STRUCT_END.
void WM_gizmo_properties_free | ( | struct PointerRNA * | ptr | ) |
Definition at line 688 of file wm_gizmo.c.
References PointerRNA::data, IDP_FreeProperty(), NULL, and ptr.
Referenced by WM_gizmo_free().
Remove all props without PROP_SKIP_SAVE.
Definition at line 661 of file wm_gizmo.c.
References PointerRNA::data, PROP_SKIP_SAVE, wmGizmo::ptr, RNA_PROP_BEGIN, RNA_PROP_END, RNA_property_flag(), RNA_property_identifier(), RNA_struct_idprops_unset(), RNA_struct_iterator_property(), wmGizmoType::srna, and wmGizmo::type.
void WM_gizmo_properties_sanitize | ( | struct PointerRNA * | ptr, |
bool | no_context | ||
) |
Definition at line 605 of file wm_gizmo.c.
References PROP_ENUM, PROP_ENUM_NO_CONTEXT, PROP_POINTER, ptr, RNA_def_property_clear_flag(), RNA_def_property_flag(), RNA_property_pointer_get(), RNA_property_pointer_type(), RNA_property_type(), RNA_STRUCT_BEGIN, RNA_STRUCT_END, and RNA_struct_is_a().
Referenced by wm_gizmo_create().
bool WM_gizmo_select_set | ( | struct wmGizmoMap * | gzmap, |
struct wmGizmo * | gz, | ||
bool | select | ||
) |
Definition at line 397 of file wm_gizmo.c.
References select(), and wm_gizmo_select_set_ex().
Referenced by gizmo_select_invoke(), wm_gizmo_select_and_highlight(), and wm_gizmomap_select_all_intern().
bool WM_gizmo_select_unlink | ( | struct wmGizmoMap * | gzmap, |
struct wmGizmo * | gz | ||
) |
Remove from selection array without running callbacks.
Definition at line 392 of file wm_gizmo.c.
References wm_gizmo_select_set_ex().
Referenced by WM_gizmo_unlink(), and wm_gizmogroup_free().
Definition at line 328 of file wm_gizmo.c.
References color, wmGizmo::color, and copy_v4_v4().
Referenced by gizmo2d_resize_setup(), gizmo2d_rotate_setup(), gizmo2d_xform_setup(), gizmo_mesh_spin_init_setup(), WIDGETGROUP_gizmo_draw_prepare(), and WIDGETGROUP_ruler_setup().
Definition at line 337 of file wm_gizmo.c.
References wmGizmo::color_hi, and copy_v4_v4().
Referenced by gizmo2d_resize_setup(), gizmo2d_rotate_setup(), gizmo2d_xform_setup(), gizmo_mesh_spin_init_setup(), and WIDGETGROUP_gizmo_draw_prepare().
Definition at line 304 of file wm_gizmo.c.
References wmGizmo::flag.
Referenced by gizmo_mesh_bisect_setup(), gizmo_mesh_extrude_refresh(), gizmo_mesh_placement_setup(), gizmo_mesh_spin_init_draw_prepare(), gizmo_mesh_spin_init_refresh(), gizmo_mesh_spin_init_setup(), gizmo_mesh_spin_redo_setup(), gizmo_modal(), gizmo_refresh_from_matrix(), gizmogroup_init_properties_from_twtype(), ruler_item_add(), WIDGETGROUP_armature_spline_setup(), WIDGETGROUP_camera_refresh(), WIDGETGROUP_camera_setup(), WIDGETGROUP_camera_view_refresh(), WIDGETGROUP_empty_image_setup(), WIDGETGROUP_forcefield_refresh(), WIDGETGROUP_gizmo_draw_prepare(), WIDGETGROUP_light_area_setup(), WIDGETGROUP_light_target_draw_prepare(), WIDGETGROUP_navigate_draw_prepare(), blender::ed::space_node::WIDGETGROUP_node_corner_pin_refresh(), blender::ed::space_node::WIDGETGROUP_node_crop_refresh(), blender::ed::space_node::WIDGETGROUP_node_sbeam_refresh(), blender::ed::space_node::WIDGETGROUP_node_transform_refresh(), WIDGETGROUP_tool_generic_refresh(), WIDGETGROUP_xform_cage_refresh(), WIDGETGROUP_xform_shear_refresh(), and WIDGETGROUP_xform_shear_setup().
void WM_gizmo_set_fn_custom_modal | ( | struct wmGizmo * | gz, |
wmGizmoFnModal | fn | ||
) |
Definition at line 348 of file wm_gizmo.c.
References wmGizmo::custom_modal.
Referenced by gizmo2d_resize_setup(), gizmo2d_rotate_setup(), gizmo2d_xform_setup(), and gizmogroup_init_properties_from_twtype().
Definition at line 319 of file wm_gizmo.c.
References wmGizmo::line_width.
Referenced by gizmo2d_resize_setup(), gizmo2d_rotate_setup(), gizmo2d_xform_setup(), gizmo_mesh_spin_init_setup(), gizmo_mesh_spin_redo_setup(), gizmogroup_init_properties_from_twtype(), and tool_generic_create_gizmo().
Definition at line 284 of file wm_gizmo.c.
References copy_v3_v3(), and wmGizmo::matrix_basis.
Referenced by gizmo2d_modal(), gizmo2d_resize_draw_prepare(), gizmo2d_rotate_draw_prepare(), gizmo2d_xform_draw_prepare(), gizmo_mesh_bisect_update_from_op(), gizmo_mesh_extrude_refresh(), gizmo_mesh_spin_init_refresh(), gizmo_mesh_spin_redo_update_from_op(), gizmo_modal(), gizmo_refresh_from_matrix(), WIDGETGROUP_camera_refresh(), WIDGETGROUP_forcefield_refresh(), WIDGETGROUP_light_spot_refresh(), blender::ed::space_node::WIDGETGROUP_node_transform_refresh(), WIDGETGROUP_xform_shear_draw_prepare(), and WIDGETGROUP_xform_shear_refresh().
Definition at line 299 of file wm_gizmo.c.
References copy_v3_v3(), wmGizmo::matrix_offset, and offset.
Referenced by gizmo2d_xform_draw_prepare(), gizmo2d_xform_setup(), gizmo_refresh_from_matrix(), gizmogroup_init_properties_from_twtype(), WIDGETGROUP_camera_refresh(), and WIDGETGROUP_forcefield_refresh().
void WM_gizmo_set_matrix_offset_rotation_from_yz_axis | ( | struct wmGizmo * | gz, |
const float | y_axis[3], | ||
const float | z_axis[3] | ||
) |
wmGizmo.matrix_offset utility, set the orientation by it's Y/Z axis.
Definition at line 293 of file wm_gizmo.c.
References wmGizmo::matrix_offset, and wm_gizmo_set_matrix_rotation_from_yz_axis__internal().
Referenced by gizmo_mesh_bisect_update_from_op().
wmGizmo.matrix_offset utility, set the orientation by it's Z axis.
Definition at line 289 of file wm_gizmo.c.
References wmGizmo::matrix_offset, and wm_gizmo_set_matrix_rotation_from_z_axis__internal().
void WM_gizmo_set_matrix_rotation_from_yz_axis | ( | struct wmGizmo * | gz, |
const float | y_axis[3], | ||
const float | z_axis[3] | ||
) |
#wmGizmo.matrix utility, set the orientation by it's Y/Z axis.
Definition at line 278 of file wm_gizmo.c.
References wmGizmo::matrix_basis, and wm_gizmo_set_matrix_rotation_from_yz_axis__internal().
Referenced by gizmo_mesh_spin_init_refresh_axis_orientation(), gizmo_mesh_spin_redo_draw_prepare(), gizmo_mesh_spin_redo_update_from_op(), gizmo_refresh_from_matrix(), WIDGETGROUP_camera_refresh(), WIDGETGROUP_xform_shear_draw_prepare(), and WIDGETGROUP_xform_shear_refresh().
#wmGizmo.matrix utility, set the orientation by it's Z axis.
Definition at line 274 of file wm_gizmo.c.
References wmGizmo::matrix_basis, and wm_gizmo_set_matrix_rotation_from_z_axis__internal().
Referenced by gizmo2d_resize_draw_prepare(), gizmo2d_xform_setup(), gizmo_mesh_bisect_update_from_op(), gizmo_mesh_spin_init_refresh_axis_orientation(), gizmo_mesh_spin_redo_draw_prepare(), gizmo_mesh_spin_redo_update_from_op(), gizmo_refresh_from_matrix(), WIDGETGROUP_forcefield_refresh(), WIDGETGROUP_gizmo_draw_prepare(), and WIDGETGROUP_light_spot_refresh().
Definition at line 314 of file wm_gizmo.c.
References wmGizmo::scale_basis.
Referenced by gizmo2d_resize_setup(), gizmo2d_rotate_setup(), gizmo2d_xform_setup(), gizmo_mesh_bisect_update_from_op(), gizmo_mesh_extrude_setup(), gizmo_mesh_spin_init_setup(), gizmo_mesh_spin_redo_setup(), gizmogroup_init_properties_from_twtype(), WIDGETGROUP_camera_refresh(), and WIDGETGROUP_camera_view_setup().
void WM_gizmo_target_property_anim_autokey | ( | struct bContext * | C, |
const struct wmGizmo * | gz, | ||
struct wmGizmoProperty * | gz_prop | ||
) |
Auto-key function if auto-key is enabled.
struct wmGizmoProperty* WM_gizmo_target_property_array | ( | struct wmGizmo * | gz | ) |
Definition at line 39 of file wm_gizmo_target_props.c.
References wm_gizmo_target_property_array().
Referenced by gizmo_update_prop_data(), ui_tooltip_data_from_gizmo(), WM_gizmo_free(), and WM_gizmo_target_property_subscribe_all().
int WM_gizmo_target_property_array_length | ( | const struct wmGizmo * | gz, |
struct wmGizmoProperty * | gz_prop | ||
) |
struct wmGizmoProperty* WM_gizmo_target_property_at_index | ( | struct wmGizmo * | gz, |
int | index | ||
) |
Definition at line 44 of file wm_gizmo_target_props.c.
References BLI_assert, type, and wm_gizmo_target_property_array().
Referenced by WM_gizmo_target_property_clear_rna_ptr(), WM_gizmo_target_property_def_func_ptr(), WM_gizmo_target_property_def_rna_ptr(), and WM_gizmo_target_property_find().
Definition at line 140 of file wm_gizmo_target_props.c.
References wmGizmo::type, WM_gizmo_target_property_clear_rna_ptr(), and WM_gizmotype_target_property_find().
void WM_gizmo_target_property_clear_rna_ptr | ( | struct wmGizmo * | gz, |
const struct wmGizmoPropertyType * | gz_prop_type | ||
) |
void WM_gizmo_target_property_def_func | ( | struct wmGizmo * | gz, |
const char * | idname, | ||
const struct wmGizmoPropertyFnParams * | params | ||
) |
void WM_gizmo_target_property_def_func_ptr | ( | struct wmGizmo * | gz, |
const struct wmGizmoPropertyType * | gz_prop_type, | ||
const struct wmGizmoPropertyFnParams * | params | ||
) |
void WM_gizmo_target_property_def_rna | ( | struct wmGizmo * | gz, |
const char * | idname, | ||
struct PointerRNA * | ptr, | ||
const char * | propname, | ||
int | index | ||
) |
Definition at line 85 of file wm_gizmo_target_props.c.
References NULL, ptr, RNA_struct_find_property(), RNA_struct_identifier(), RNA_warning, PointerRNA::type, wmGizmo::type, WM_gizmo_target_property_def_rna_ptr(), and WM_gizmotype_target_property_find().
Referenced by WIDGETGROUP_camera_refresh(), WIDGETGROUP_forcefield_refresh(), WIDGETGROUP_light_spot_refresh(), blender::ed::space_node::WIDGETGROUP_node_corner_pin_refresh(), blender::ed::space_node::WIDGETGROUP_node_sbeam_refresh(), and blender::ed::space_node::WIDGETGROUP_node_transform_refresh().
void WM_gizmo_target_property_def_rna_ptr | ( | struct wmGizmo * | gz, |
const struct wmGizmoPropertyType * | gz_prop_type, | ||
struct PointerRNA * | ptr, | ||
struct PropertyRNA * | prop, | ||
int | index | ||
) |
struct wmGizmoProperty* WM_gizmo_target_property_find | ( | struct wmGizmo * | gz, |
const char * | idname | ||
) |
Definition at line 52 of file wm_gizmo_target_props.c.
References BLI_findstringindex(), NULL, wmGizmoType::target_property_defs, wmGizmo::type, and WM_gizmo_target_property_at_index().
Referenced by dial_draw_intern(), ED_gizmo_arrow3d_set_range_fac(), ED_gizmo_arrow3d_set_ui_range(), gizmo_arrow_exit(), gizmo_arrow_invoke(), gizmo_arrow_modal(), gizmo_cage2d_exit(), gizmo_cage2d_modal(), gizmo_cage3d_exit(), gizmo_cage3d_modal(), gizmo_dial_exit(), gizmo_dial_invoke(), gizmo_dial_modal(), gizmo_move_exit(), gizmo_move_invoke(), gizmo_move_modal(), py_rna_gizmo_target_id_parse(), and snap_gizmo_snap_elements_update().
float WM_gizmo_target_property_float_get | ( | const struct wmGizmo * | gz, |
struct wmGizmoProperty * | gz_prop | ||
) |
void WM_gizmo_target_property_float_get_array | ( | const struct wmGizmo * | gz, |
struct wmGizmoProperty * | gz_prop, | ||
float * | value | ||
) |
bool WM_gizmo_target_property_float_range_get | ( | const struct wmGizmo * | gz, |
struct wmGizmoProperty * | gz_prop, | ||
float | range[2] | ||
) |
void WM_gizmo_target_property_float_set | ( | struct bContext * | C, |
const struct wmGizmo * | gz, | ||
struct wmGizmoProperty * | gz_prop, | ||
float | value | ||
) |
void WM_gizmo_target_property_float_set_array | ( | struct bContext * | C, |
const struct wmGizmo * | gz, | ||
struct wmGizmoProperty * | gz_prop, | ||
const float * | value | ||
) |
bool WM_gizmo_target_property_is_valid | ( | const struct wmGizmoProperty * | gz_prop | ) |
Definition at line 152 of file wm_gizmo_target_props.c.
References wmGizmoType::target_property_defs_len, wmGizmo::type, wm_gizmo_target_property_array(), and WM_gizmo_target_property_is_valid().
void WM_gizmo_target_property_subscribe_all | ( | struct wmGizmo * | gz, |
struct wmMsgBus * | mbus, | ||
struct ARegion * | region | ||
) |
Runs on the "prepare draw" pass, drawing the region clears.
Definition at line 308 of file wm_gizmo_target_props.c.
References wmGizmoProperty::prop, wmGizmoProperty::ptr, wmGizmoType::target_property_defs_len, wmGizmo::type, WM_gizmo_target_property_array(), WM_gizmo_target_property_is_valid(), and WM_msg_subscribe_rna().
Referenced by WM_gizmomap_message_subscribe().
void WM_gizmo_unlink | ( | ListBase * | gizmolist, |
struct wmGizmoMap * | gzmap, | ||
struct wmGizmo * | gz, | ||
struct bContext * | C | ||
) |
Free gizmo and unlink from gizmolist. gizmolist is allowed to be NULL.
Definition at line 165 of file wm_gizmo.c.
References BLI_assert, BLI_remlink(), C, wmGizmoMap::gzmap_context, wmGizmoMap::highlight, wmGizmoMap::modal, NULL, wmGizmo::state, WM_gizmo_free(), WM_gizmo_select_unlink(), WM_GIZMO_STATE_HIGHLIGHT, WM_GIZMO_STATE_MODAL, WM_GIZMO_STATE_SELECT, wm_gizmomap_highlight_set(), and wm_gizmomap_modal_set().
Referenced by gizmotype_unlink(), and ruler_item_remove().
Run in case new types have been added (runs often, early exit where possible). Follows WM_keyconfig_update conventions.
Definition at line 1285 of file wm_gizmo_map.c.
References blender::compositor::area(), ED_region_tag_redraw_editor_overlays(), ListBase::first, G, ARegion::gizmo_map, gizmomaptypes, wmGizmoMap::groups, LISTBASE_FOREACH, NULL, Main::screens, wmGizmoMap::tag_remove_group, wm_gizmogroup_free(), WM_GIZMOMAPTYPE_GLOBAL_UPDATE_INIT, WM_GIZMOMAPTYPE_GLOBAL_UPDATE_REMOVE, WM_gizmomaptype_group_init_runtime(), WM_gizmomaptype_group_init_runtime_keymap(), WM_gizmomaptype_group_unlink(), WM_GIZMOMAPTYPE_KEYMAP_INIT, WM_GIZMOMAPTYPE_UPDATE_INIT, WM_GIZMOMAPTYPE_UPDATE_REMOVE, WM_GIZMOTYPE_GLOBAL_UPDATE_REMOVE, and wm_gzmap_type_update_flag.
Referenced by wm_event_do_handlers().
void WM_gizmoconfig_update_tag_group_remove | ( | struct wmGizmoMap * | gzmap | ) |
Definition at line 1278 of file wm_gizmo_map.c.
References wmGizmoMap::tag_remove_group, WM_GIZMOTYPE_GLOBAL_UPDATE_REMOVE, and wm_gzmap_type_update_flag.
Referenced by WM_gizmo_group_tag_remove().
void WM_gizmoconfig_update_tag_group_type_init | ( | struct wmGizmoMapType * | gzmap_type, |
struct wmGizmoGroupType * | gzgt | ||
) |
Definition at line 1259 of file wm_gizmo_map.c.
References wmGizmoMapType::type_update_flag, wmGizmoGroupType::type_update_flag, WM_GIZMOMAPTYPE_GLOBAL_UPDATE_INIT, WM_GIZMOMAPTYPE_KEYMAP_INIT, WM_GIZMOMAPTYPE_UPDATE_INIT, and wm_gzmap_type_update_flag.
Referenced by toolsystem_ref_link(), and WM_gizmo_group_type_add_ptr_ex().
void WM_gizmoconfig_update_tag_group_type_remove | ( | struct wmGizmoMapType * | gzmap_type, |
struct wmGizmoGroupType * | gzgt | ||
) |
Definition at line 1268 of file wm_gizmo_map.c.
References wmGizmoMapType::type_update_flag, wmGizmoGroupType::type_update_flag, WM_GIZMOMAPTYPE_GLOBAL_UPDATE_REMOVE, WM_GIZMOMAPTYPE_UPDATE_REMOVE, and wm_gzmap_type_update_flag.
Referenced by WM_gizmo_group_type_unlink_delayed_ptr_ex().
void WM_gizmogroup_ensure_init | ( | const struct bContext * | C, |
struct wmGizmoGroup * | gzgroup | ||
) |
struct wmKeyMap* WM_gizmogroup_setup_keymap_generic | ( | const struct wmGizmoGroupType * | gzgt, |
struct wmKeyConfig * | kc | ||
) |
struct wmKeyMap* WM_gizmogroup_setup_keymap_generic_drag | ( | const struct wmGizmoGroupType * | gzgt, |
struct wmKeyConfig * | kc | ||
) |
struct wmKeyMap* WM_gizmogroup_setup_keymap_generic_maybe_drag | ( | const struct wmGizmoGroupType * | gzgt, |
struct wmKeyConfig * | kc | ||
) |
struct wmKeyMap* WM_gizmogroup_setup_keymap_generic_select | ( | const struct wmGizmoGroupType * | gzgt, |
struct wmKeyConfig * | kc | ||
) |
struct wmGizmoGroupType* WM_gizmogrouptype_append | ( | void(*)(struct wmGizmoGroupType *) | wtfunc | ) |
Definition at line 99 of file wm_gizmo_group_type.c.
References wm_gizmogrouptype_append__begin(), and wm_gizmogrouptype_append__end().
Referenced by image_widgets(), MESH_OT_bisect(), MESH_OT_primitive_cube_add_gizmo(), MESH_OT_spin(), sequencer_gizmos(), view3d_widgets(), and WM_gizmogrouptype_append_and_link().
struct wmGizmoGroupTypeRef* WM_gizmogrouptype_append_and_link | ( | struct wmGizmoMapType * | gzmap_type, |
void(*)(struct wmGizmoGroupType *) | wtfunc | ||
) |
Append and insert into a gizmo typemap. This is most common for C gizmos which are enabled by default.
Definition at line 116 of file wm_gizmo_group_type.c.
References wmGizmoGroupType::gzmap_params, wmGizmoMapType::regionid, wmGizmoMapType_Params::regionid, wmGizmoMapType::spaceid, wmGizmoMapType_Params::spaceid, WM_gizmogrouptype_append(), and WM_gizmomaptype_group_link_ptr().
Referenced by clip_gizmos(), image_widgets(), blender::ed::space_node::node_widgets(), sequencer_gizmos(), and view3d_widgets().
struct wmGizmoGroupType* WM_gizmogrouptype_append_ptr | ( | void(*)(struct wmGizmoGroupType *, void *) | wtfunc, |
void * | userdata | ||
) |
Definition at line 107 of file wm_gizmo_group_type.c.
References wm_gizmogrouptype_append__begin(), and wm_gizmogrouptype_append__end().
struct wmGizmoGroupType* WM_gizmogrouptype_find | ( | const char * | idname, |
bool | quiet | ||
) |
Definition at line 38 of file wm_gizmo_group_type.c.
References BLI_ghash_lookup(), global_gizmogrouptype_hash, and NULL.
Referenced by add_primitive_cube_gizmo_invoke(), edbm_spin_invoke(), toolsystem_ref_link(), toolsystem_unlink_ref(), WM_gizmo_group_type_add(), WM_gizmo_group_type_ensure(), WM_gizmo_group_type_free_ptr(), WM_gizmo_group_type_reinit(), WM_gizmo_group_type_remove(), WM_gizmo_group_type_unlink_delayed(), WM_gizmomap_group_find(), WM_gizmomaptype_group_link(), wm_handler_operator_call(), and WM_toolsystem_ref_set_from_runtime().
void WM_gizmogrouptype_iter | ( | struct GHashIterator * | ghi | ) |
Caller must free.
Definition at line 61 of file wm_gizmo_group_type.c.
References BLI_ghashIterator_init(), and global_gizmogrouptype_hash.
void WM_gizmomap_add_handlers | ( | struct ARegion * | region, |
struct wmGizmoMap * | gzmap | ||
) |
Definition at line 790 of file wm_gizmo_map.c.
References BLI_addtail(), BLI_assert, ARegion::gizmo_map, wmEventHandler_Gizmo::gizmo_map, ARegion::handlers, wmEventHandler_Gizmo::head, LISTBASE_FOREACH, MEM_callocN, wmEventHandler::type, and WM_HANDLER_TYPE_GIZMO.
Referenced by ed_default_handlers().
bool WM_gizmomap_cursor_set | ( | const struct wmGizmoMap * | gzmap, |
struct wmWindow * | win | ||
) |
void WM_gizmomap_draw | ( | struct wmGizmoMap * | gzmap, |
const struct bContext * | C, | ||
eWM_GizmoFlagMapDrawStep | drawstep | ||
) |
eWM_GizmoFlagMapDrawStep WM_gizmomap_drawstep_from_gizmo_group | ( | const struct wmGizmoGroup * | gzgroup | ) |
struct wmGizmo* WM_gizmomap_get_modal | ( | const struct wmGizmoMap * | gzmap | ) |
struct wmGizmoGroup* WM_gizmomap_group_find | ( | struct wmGizmoMap * | gzmap, |
const char * | idname | ||
) |
Definition at line 202 of file wm_gizmo_map.c.
References NULL, WM_gizmogrouptype_find(), and WM_gizmomap_group_find_ptr().
Referenced by edbm_preselect_or_active(), gizmo_mesh_spin_redo_setup(), ringcut_invoke(), transform_from_gizmo_invoke(), UNUSED_FUNCTION_WITH_RETURN_TYPE(), view3d_ruler_add_invoke(), view3d_ruler_remove_invoke(), and wm_event_get_keymap_from_toolsystem_ex().
struct wmGizmoGroup* WM_gizmomap_group_find_ptr | ( | struct wmGizmoMap * | gzmap, |
const struct wmGizmoGroupType * | gzgt | ||
) |
Definition at line 211 of file wm_gizmo_map.c.
References wmGizmoMap::groups, LISTBASE_FOREACH, and NULL.
Referenced by v3d_cursor_snap_poll_fn(), and WM_gizmomap_group_find().
const struct ListBase* WM_gizmomap_group_list | ( | struct wmGizmoMap * | gzmap | ) |
Definition at line 222 of file wm_gizmo_map.c.
References wmGizmoMap::groups.
Referenced by gizmo_snap_rna_find_operator(), wm_handlers_do_gizmo_handler(), and wm_region_test_gizmo_do_draw().
bool WM_gizmomap_is_any_selected | ( | const struct wmGizmoMap * | gzmap | ) |
void WM_gizmomap_message_subscribe | ( | const struct bContext * | C, |
struct wmGizmoMap * | gzmap, | ||
struct ARegion * | region, | ||
struct wmMsgBus * | mbus | ||
) |
bool WM_gizmomap_minmax | ( | const struct wmGizmoMap * | gzmap, |
bool | use_hidden, | ||
bool | use_select, | ||
float | r_min[3], | ||
float | r_max[3] | ||
) |
struct wmGizmoMap* WM_gizmomap_new_from_type | ( | const struct wmGizmoMapType_Params * | gzmap_params | ) |
Creates a gizmo-map with all registered gizmos for that type
Definition at line 166 of file wm_gizmo_map.c.
References MEM_callocN, wm_gizmomap_new_from_type_ex(), and WM_gizmomaptype_ensure().
Referenced by ed_default_handlers().
void WM_gizmomap_reinit | ( | struct wmGizmoMap * | gzmap | ) |
Re-create the gizmos (use when changing theme settings).
Definition at line 194 of file wm_gizmo_map.c.
References wmGizmoMap::type, wm_gizmomap_free_data(), and wm_gizmomap_new_from_type_ex().
Referenced by WM_reinit_gizmomap_all().
bool WM_gizmomap_select_all | ( | struct bContext * | C, |
struct wmGizmoMap * | gzmap, | ||
int | action | ||
) |
Select/Deselect all selectable gizmos in gzmap.
TODO: select all by type.
Definition at line 911 of file wm_gizmo_map.c.
References BLI_assert_unreachable, C, CTX_wm_window(), SEL_DESELECT, SEL_SELECT, WM_event_add_mousemove(), wm_gizmomap_deselect_all(), and wm_gizmomap_select_all_intern().
bool WM_gizmomap_tag_delay_refresh_for_tweak_check | ( | struct wmGizmoMap * | gzmap | ) |
Definition at line 317 of file wm_gizmo_map.c.
References wmGizmoMap::groups, and LISTBASE_FOREACH.
Referenced by wm_region_tag_draw_on_gizmo_delay_refresh_for_tweak().
void WM_gizmomap_tag_refresh | ( | struct wmGizmoMap * | gzmap | ) |
Definition at line 308 of file wm_gizmo_map.c.
References GIZMOMAP_IS_PREPARE_DRAW, GIZMOMAP_IS_REFRESH_CALLBACK, wmGizmoMap::update_flag, and WM_GIZMOMAP_DRAWSTEP_MAX.
Referenced by image_main_region_listener(), blender::ed::space_node::node_main_region_init(), blender::ed::space_node::node_region_listener(), sequencer_preview_region_listener(), view3d_main_region_listener(), WM_gizmo_do_msg_notify_tag_refresh(), wm_gizmomap_new_from_type_ex(), wm_handlers_do_gizmo_handler(), and WM_init().
void WM_gizmomap_tag_refresh_drawstep | ( | struct wmGizmoMap * | gzmap, |
eWM_GizmoFlagMapDrawStep | drawstep | ||
) |
Definition at line 300 of file wm_gizmo_map.c.
References BLI_assert, GIZMOMAP_IS_PREPARE_DRAW, GIZMOMAP_IS_REFRESH_CALLBACK, wmGizmoMap::update_flag, and WM_GIZMOMAP_DRAWSTEP_MAX.
Referenced by WM_gizmo_group_refresh().
struct ARegion* WM_gizmomap_tooltip_init | ( | struct bContext * | C, |
struct ARegion * | region, | ||
int * | pass, | ||
double * | pass_delay, | ||
bool * | r_exit_on_event | ||
) |
struct wmGizmoMapType* WM_gizmomaptype_ensure | ( | const struct wmGizmoMapType_Params * | gzmap_params | ) |
Definition at line 1212 of file wm_gizmo_map.c.
References BLI_addhead(), gizmomaptypes, MEM_callocN, wmGizmoMapType::regionid, wmGizmoMapType_Params::regionid, wmGizmoMapType::spaceid, wmGizmoMapType_Params::spaceid, and WM_gizmomaptype_find().
Referenced by clip_gizmos(), ED_gizmo_poll_or_unlink_delayed_from_tool_ex(), image_widgets(), blender::ed::space_node::node_widgets(), sequencer_gizmos(), toolsystem_ref_link(), view3d_widgets(), WM_gizmo_group_type_add_ptr(), WM_gizmo_group_type_ensure_ptr(), WM_gizmo_group_type_reinit_ptr(), WM_gizmo_group_type_remove_ptr(), WM_gizmo_group_type_unlink_delayed_ptr(), WM_gizmomap_new_from_type(), and wm_handler_operator_call().
struct wmGizmoMapType* WM_gizmomaptype_find | ( | const struct wmGizmoMapType_Params * | gzmap_params | ) |
Definition at line 1200 of file wm_gizmo_map.c.
References gizmomaptypes, LISTBASE_FOREACH, NULL, wmGizmoMapType_Params::regionid, and wmGizmoMapType_Params::spaceid.
Referenced by WM_gizmo_group_remove_by_tool(), and WM_gizmomaptype_ensure().
struct wmGizmoGroupTypeRef* WM_gizmomaptype_group_find | ( | struct wmGizmoMapType * | gzmap_type, |
const char * | idname | ||
) |
Definition at line 931 of file wm_gizmo_group.c.
References wmGizmoMapType::grouptype_refs, LISTBASE_FOREACH, NULL, and STREQ.
struct wmGizmoGroupTypeRef* WM_gizmomaptype_group_find_ptr | ( | struct wmGizmoMapType * | gzmap_type, |
const struct wmGizmoGroupType * | gzgt | ||
) |
void WM_gizmomaptype_group_free | ( | struct wmGizmoGroupTypeRef * | gzgt | ) |
Unlike WM_gizmomaptype_group_unlink this doesn't maintain correct state, simply free.
Definition at line 1016 of file wm_gizmo_group.c.
References MEM_freeN.
Referenced by WM_gizmomaptype_group_unlink(), and wm_gizmomaptypes_free().
void WM_gizmomaptype_group_init_runtime | ( | const struct Main * | bmain, |
struct wmGizmoMapType * | gzmap_type, | ||
struct wmGizmoGroupType * | gzgt | ||
) |
void WM_gizmomaptype_group_init_runtime_keymap | ( | const struct Main * | bmain, |
struct wmGizmoGroupType * | gzgt | ||
) |
wmGizmoGroup* WM_gizmomaptype_group_init_runtime_with_region | ( | struct wmGizmoMapType * | gzmap_type, |
struct wmGizmoGroupType * | gzgt, | ||
struct ARegion * | region | ||
) |
Definition at line 990 of file wm_gizmo_group.c.
References BLI_assert, ED_region_tag_redraw_editor_overlays(), ARegion::gizmo_map, wmGizmoMap::groups, LISTBASE_FOREACH, NULL, wmGizmoMap::type, UNUSED_VARS_NDEBUG, WM_gizmo_group_tag_remove(), wm_gizmogroup_new_from_type(), and wm_gizmomap_highlight_set().
Referenced by WM_gizmomaptype_group_init_runtime(), and wm_handler_operator_call().
struct wmGizmoGroupTypeRef* WM_gizmomaptype_group_link | ( | struct wmGizmoMapType * | gzmap_type, |
const char * | idname | ||
) |
Use this for registering gizmos on startup. For runtime, use #WM_gizmomaptype_group_link_runtime.
Definition at line 943 of file wm_gizmo_group.c.
References BLI_assert, NULL, WM_gizmogrouptype_find(), and WM_gizmomaptype_group_link_ptr().
struct wmGizmoGroupTypeRef* WM_gizmomaptype_group_link_ptr | ( | struct wmGizmoMapType * | gzmap_type, |
struct wmGizmoGroupType * | gzgt | ||
) |
Definition at line 950 of file wm_gizmo_group.c.
References BLI_addtail(), wmGizmoMapType::grouptype_refs, MEM_callocN, and wmGizmoGroupTypeRef::type.
Referenced by WM_gizmo_group_type_add_ptr_ex(), WM_gizmogrouptype_append_and_link(), and WM_gizmomaptype_group_link().
void WM_gizmomaptype_group_unlink | ( | struct bContext * | C, |
struct Main * | bmain, | ||
struct wmGizmoMapType * | gzmap_type, | ||
const struct wmGizmoGroupType * | gzgt | ||
) |
void WM_gizmotype_append | ( | void(*)(struct wmGizmoType *) | gtfunc | ) |
Definition at line 93 of file wm_gizmo_type.c.
References wm_gizmotype_append__begin(), and wm_gizmotype_append__end().
Referenced by ED_gizmotypes_arrow_3d(), ED_gizmotypes_blank_3d(), ED_gizmotypes_button_2d(), ED_gizmotypes_cage_2d(), ED_gizmotypes_cage_3d(), ED_gizmotypes_dial_3d(), ED_gizmotypes_move_3d(), ED_gizmotypes_preselect_3d(), ED_gizmotypes_primitive_3d(), ED_gizmotypes_snap_3d(), and view3d_widgets().
void WM_gizmotype_append_ptr | ( | void(*)(struct wmGizmoType *, void *) | gtfunc, |
void * | userdata | ||
) |
Definition at line 100 of file wm_gizmo_type.c.
References wm_gizmotype_append__begin(), and wm_gizmotype_append__end().
const struct wmGizmoType* WM_gizmotype_find | ( | const char * | idname, |
bool | quiet | ||
) |
Definition at line 45 of file wm_gizmo_type.c.
References BLI_ghash_lookup(), global_gizmotype_hash, and NULL.
Referenced by gizmo_mesh_bisect_setup(), gizmo_mesh_extrude_setup(), gizmo_mesh_placement_setup(), gizmo_mesh_spin_init_setup(), gizmo_mesh_spin_redo_setup(), gizmogroup2d_init(), gizmogroup2d_resize_init(), gizmogroup2d_rotate_init(), gizmogroup_init(), ruler_item_add(), WIDGETGROUP_armature_spline_setup(), WIDGETGROUP_camera_setup(), WIDGETGROUP_mesh_preselect_edgering_setup(), WIDGETGROUP_mesh_preselect_elem_setup(), blender::ed::space_node::WIDGETGROUP_node_corner_pin_setup(), WIDGETGROUP_ruler_setup(), WIDGETGROUP_xform_cage_setup(), WIDGETGROUP_xform_shear_setup(), WM_gizmo_new(), WM_gizmo_properties_create(), and WM_gizmotype_remove_ptr().
void WM_gizmotype_free_ptr | ( | struct wmGizmoType * | gzt | ) |
Free but don't remove from GHash.
Definition at line 107 of file wm_gizmo_type.c.
References BLI_freelistN(), wmGizmoType::idname, MEM_freeN, wmGizmoType::rna_ext, ExtensionRNA::srna, and wmGizmoType::target_property_defs.
Referenced by wm_gizmotype_ghash_free_cb().
void WM_gizmotype_iter | ( | struct GHashIterator * | ghi | ) |
Caller must free.
Definition at line 68 of file wm_gizmo_type.c.
References BLI_ghashIterator_init(), and global_gizmotype_hash.
Definition at line 157 of file wm_gizmo_type.c.
References BLI_ghash_lookup(), C, global_gizmotype_hash, NULL, and WM_gizmotype_remove_ptr().
void WM_gizmotype_remove_ptr | ( | struct bContext * | C, |
struct Main * | bmain, | ||
struct wmGizmoType * | gzt | ||
) |
Definition at line 148 of file wm_gizmo_type.c.
References BLI_assert, BLI_ghash_remove(), C, gizmotype_unlink(), global_gizmotype_hash, wmGizmoType::idname, NULL, and WM_gizmotype_find().
Referenced by WM_gizmotype_remove().
void WM_gizmotype_target_property_def | ( | struct wmGizmoType * | gzt, |
const char * | idname, | ||
int | data_type, | ||
int | array_length | ||
) |
Definition at line 269 of file wm_gizmo_target_props.c.
References wmGizmoPropertyType::array_length, BLI_addtail(), BLI_assert, wmGizmoPropertyType::data_type, wmGizmoPropertyType::idname, wmGizmoPropertyType::index_in_type, MEM_callocN, NULL, wmGizmoType::target_property_defs, wmGizmoType::target_property_defs_len, and WM_gizmotype_target_property_find().
Referenced by bpy_gizmotype_target_property_def(), GIZMO_GT_arrow_3d(), GIZMO_GT_cage_2d(), GIZMO_GT_cage_3d(), GIZMO_GT_dial_3d(), GIZMO_GT_move_3d(), and GIZMO_GT_snap_3d().
const struct wmGizmoPropertyType* WM_gizmotype_target_property_find | ( | const struct wmGizmoType * | gzt, |
const char * | idname | ||
) |