|
Blender
V2.93
|
#include <ctype.h>#include <float.h>#include <limits.h>#include <math.h>#include <stdlib.h>#include <string.h>#include "MEM_guardedalloc.h"#include "DNA_brush_types.h"#include "DNA_curveprofile_types.h"#include "DNA_scene_types.h"#include "DNA_screen_types.h"#include "BLI_linklist.h"#include "BLI_listbase.h"#include "BLI_math.h"#include "BLI_rect.h"#include "BLI_string.h"#include "BLI_string_cursor_utf8.h"#include "BLI_string_utf8.h"#include "BLI_utildefines.h"#include "PIL_time.h"#include "BKE_animsys.h"#include "BKE_blender_undo.h"#include "BKE_brush.h"#include "BKE_colorband.h"#include "BKE_colortools.h"#include "BKE_context.h"#include "BKE_curveprofile.h"#include "BKE_movieclip.h"#include "BKE_paint.h"#include "BKE_report.h"#include "BKE_screen.h"#include "BKE_tracking.h"#include "BKE_unit.h"#include "IMB_colormanagement.h"#include "ED_screen.h"#include "ED_undo.h"#include "UI_interface.h"#include "UI_view2d.h"#include "BLF_api.h"#include "interface_intern.h"#include "RNA_access.h"#include "WM_api.h"#include "WM_types.h"#include "wm_event_system.h"Go to the source code of this file.
Classes | |
| struct | uiSelectContextElem |
| struct | uiSelectContextStore |
| struct | uiButMultiState |
| struct | uiHandleButtonMulti |
| struct | uiHandleButtonData |
| struct | uiAfterFunc |
| struct | uiDragToggleHandle |
Macros | |
| #define | CASE_NUM_TO_DIR(n, d) |
Feature Defines | |
These defines allow developers to locally toggle functionality which may be useful for testing (especially conflicts in dragging). Ideally the code would be refactored to support this functionality in a less fragile way. Until then keep these defines. | |
| #define | USE_CONT_MOUSE_CORRECT |
| #define | USE_DRAG_TOGGLE |
| #define | USE_DRAG_MULTINUM |
| #define | USE_ALLSELECT |
| #define | USE_KEYNAV_LIMIT |
| #define | USE_DRAG_POPUP |
Local Defines | |
| #define | UI_MAX_PASSWORD_STR 128 |
| #define | UI_DRAG_MAP_SOFT_RANGE_PIXEL_MAX 1000 |
Button Snap Values | |
| enum | eSnapType { SNAP_OFF = 0 , SNAP_ON , SNAP_ON_SMALL } |
| static enum eSnapType | ui_event_to_snap (const wmEvent *event) |
| static bool | ui_event_is_snap (const wmEvent *event) |
| static void | ui_color_snap_hue (const enum eSnapType snap, float *r_hue) |
Button Drag Toggle | |
| typedef struct uiDragToggleHandle | uiDragToggleHandle |
| static bool | ui_drag_toggle_but_is_supported (const uiBut *but) |
| static int | ui_drag_toggle_but_pushed_state (bContext *C, uiBut *but) |
| static bool | ui_drag_toggle_set_xy_xy (bContext *C, ARegion *region, const int pushed_state, const int xy_src[2], const int xy_dst[2]) |
| static void | ui_drag_toggle_set (bContext *C, uiDragToggleHandle *drag_info, const int xy_input[2]) |
| static void | ui_handler_region_drag_toggle_remove (bContext *UNUSED(C), void *userdata) |
| static int | ui_handler_region_drag_toggle (bContext *C, const wmEvent *event, void *userdata) |
| static bool | ui_but_is_drag_toggle (const uiBut *but) |
| #define BUTTON_AUTO_OPEN_THRESH 0.2 |
Definition at line 169 of file interface_handlers.c.
| #define BUTTON_DRAGLOCK_THRESH 3 |
Drag-lock distance threshold (in pixels).
Definition at line 179 of file interface_handlers.c.
| #define BUTTON_FLASH_DELAY 0.020 |
Definition at line 166 of file interface_handlers.c.
| #define BUTTON_KEYNAV_PX_LIMIT 8 |
Pixels to move the cursor to get out of keyboard navigation.
Definition at line 172 of file interface_handlers.c.
| #define BUTTON_MOUSE_TOWARDS_THRESH 1.0 |
Definition at line 170 of file interface_handlers.c.
| #define CASE_NUM_TO_DIR | ( | n, | |
| d | |||
| ) |
| #define DRAG_MULTINUM_THRESHOLD_DRAG_X (UI_UNIT_Y / 4) |
how far to drag before we check for gesture direction (in pixels), note: half the height of a button is about right...
Definition at line 259 of file interface_handlers.c.
| #define DRAG_MULTINUM_THRESHOLD_DRAG_Y (UI_UNIT_Y / 4) |
How far to drag horizontally before we stop checking which buttons the gesture spans (in pixels), locking down the buttons so we can drag freely without worrying about vertical movement.
Definition at line 266 of file interface_handlers.c.
| #define DRAG_MULTINUM_THRESHOLD_VERTICAL (0.75f) |
How strict to be when detecting a vertical gesture: [0.5 == sloppy], [0.9 == strict], (unsigned dot-product).
Definition at line 276 of file interface_handlers.c.
| #define IS_ALLSELECT_EVENT | ( | event | ) | ((event)->alt != 0) |
Definition at line 247 of file interface_handlers.c.
| #define MENU_SCROLL_INTERVAL 0.1 |
Definition at line 167 of file interface_handlers.c.
| #define MENU_TOWARDS_MARGIN 20 |
Margin around the menu, use to check if we're moving towards this rectangle (in pixels).
Definition at line 175 of file interface_handlers.c.
| #define MENU_TOWARDS_WIGGLE_ROOM 64 |
Tolerance for closing menus (in pixels).
Definition at line 177 of file interface_handlers.c.
| #define PIE_MENU_INTERVAL 0.01 |
Definition at line 168 of file interface_handlers.c.
| #define UI_BUT_IS_SELECT_CONTEXT UI_BUT_NODE_ACTIVE |
just show a tinted color so users know its activated
Definition at line 250 of file interface_handlers.c.
| #define UI_DRAG_MAP_SOFT_RANGE_PIXEL_MAX 1000 |
When USER_CONTINUOUS_MOUSE is disabled or tablet input is used, Use this as a maximum soft range for mapping cursor motion to the value. Otherwise min/max of #FLT_MAX, #INT_MAX cause small adjustments to jump to large numbers.
This is needed for values such as location & dimensions which don't have a meaningful min/max, Instead of mapping cursor motion to the min/max, map the motion to the click-step.
This value is multiplied by the click step to calculate a range to clamp the soft-range by. See: T68130
Definition at line 139 of file interface_handlers.c.
| #define UI_MAX_PASSWORD_STR 128 |
The buffer side used for password strings, where the password is stored internally, but not displayed.
Definition at line 126 of file interface_handlers.c.
| #define USE_ALLSELECT |
Allow dragging/editing all other selected items at once.
Definition at line 105 of file interface_handlers.c.
| #define USE_ALLSELECT_LAYER_HACK |
Definition at line 214 of file interface_handlers.c.
| #define USE_CONT_MOUSE_CORRECT |
Place the mouse at the scaled down location when un-grabbing.
Definition at line 97 of file interface_handlers.c.
| #define USE_DRAG_MULTINUM |
Support dragging multiple number buttons at once.
Definition at line 102 of file interface_handlers.c.
| #define USE_DRAG_POPUP |
Support dragging popups by their header.
Definition at line 114 of file interface_handlers.c.
| #define USE_DRAG_TOGGLE |
Support dragging toggle buttons.
Definition at line 99 of file interface_handlers.c.
| #define USE_KEYNAV_LIMIT |
Check to avoid very small mouse-moves from jumping away from keyboard navigation, while larger mouse motion will override keyboard input, see: T34936.
Definition at line 111 of file interface_handlers.c.
| typedef struct uiAfterFunc uiAfterFunc |
| typedef struct uiButMultiState uiButMultiState |
| typedef enum uiButtonActivateType uiButtonActivateType |
| typedef struct uiDragToggleHandle uiDragToggleHandle |
| typedef struct uiHandleButtonData uiHandleButtonData |
| typedef struct uiHandleButtonMulti uiHandleButtonMulti |
| typedef enum uiHandleButtonState uiHandleButtonState |
| typedef enum uiMenuScrollType uiMenuScrollType |
| typedef struct uiSelectContextElem uiSelectContextElem |
| typedef struct uiSelectContextStore uiSelectContextStore |
| anonymous enum |
| Enumerator | |
|---|---|
| UI_TEXTEDIT_PASTE | |
| UI_TEXTEDIT_COPY | |
| UI_TEXTEDIT_CUT | |
Definition at line 3212 of file interface_handlers.c.
| enum eSnapType |
| Enumerator | |
|---|---|
| SNAP_OFF | |
| SNAP_ON | |
| SNAP_ON_SMALL | |
Definition at line 672 of file interface_handlers.c.
| enum uiButtonActivateType |
| Enumerator | |
|---|---|
| BUTTON_ACTIVATE_OVER | |
| BUTTON_ACTIVATE | |
| BUTTON_ACTIVATE_APPLY | |
| BUTTON_ACTIVATE_TEXT_EDITING | |
| BUTTON_ACTIVATE_OPEN | |
Definition at line 181 of file interface_handlers.c.
| enum uiHandleButtonState |
Definition at line 189 of file interface_handlers.c.
| enum uiMenuScrollType |
| Enumerator | |
|---|---|
| MENU_SCROLL_UP | |
| MENU_SCROLL_DOWN | |
| MENU_SCROLL_TOP | |
| MENU_SCROLL_BOTTOM | |
Definition at line 203 of file interface_handlers.c.
|
static |
Definition at line 8196 of file interface_handlers.c.
References uiBut::active, uiBut::block, uiPopupBlockHandle::butretval, button_activate_state(), BUTTON_STATE_EXIT, uiBlock::buttons, C, CTX_wm_window(), data, ED_region_tag_redraw_no_rebuild(), ED_region_tag_refresh_ui(), uiSelectContextStore::elems, uiSelectContextStore::elems_len, uiBut::flag, uiBlock::flag, uiBlock::handle, LISTBASE_FOREACH, MEM_freeN, uiPopupBlockHandle::menuretval, NULL, uiSelectContextElem::ptr, uiBut::rnapoin, uiBut::type, UI_ACTIVE, ui_apply_but(), ui_apply_but_autokey(), ui_apply_but_undo(), UI_BLOCK_KEEP_OPEN, UI_BLOCK_POPUP_MEMORY, ui_blocks_set_tooltips(), UI_BTYPE_GRIP, UI_BUT_DRAG_MULTI, UI_BUT_LAST_ACTIVE, ui_but_update(), ui_but_update_preferences_dirty(), ui_multibut_free(), ui_popup_menu_memory_set(), UI_RETURN_CANCEL, UI_RETURN_OK, UI_SELECT, ui_selectcontext_end(), WM_cursor_modal_restore(), and WM_event_add_mousemove().
Referenced by ui_but_active_free(), ui_but_execute_end(), ui_but_list_row_text_activate(), ui_but_pie_button_activate(), ui_but_pie_menu_apply(), ui_do_but_TOG(), ui_handle_button_activate(), ui_handle_button_event(), ui_handle_button_return_submenu(), and ui_handle_menu_event().
|
static |
Definition at line 8093 of file interface_handlers.c.
References uiBut::active, uiBlock::auto_open, uiBlock::auto_open_last, BLI_assert, BLI_rctf_size_x(), BLI_rctf_size_y(), uiBut::block, BUTTON_ACTIVATE, BUTTON_ACTIVATE_APPLY, BUTTON_ACTIVATE_OPEN, BUTTON_ACTIVATE_OVER, button_activate_state(), BUTTON_ACTIVATE_TEXT_EDITING, BUTTON_AUTO_OPEN_THRESH, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_INIT, BUTTON_STATE_MENU_OPEN, BUTTON_STATE_TEXT_EDITING, BUTTON_STATE_WAIT_FLASH, BUTTON_STATE_WAIT_KEY_EVENT, C, copy_v2_fl(), CTX_wm_area(), CTX_wm_manager(), CTX_wm_window(), data, ELEM, ListBase::first, uiBut::flag, MEM_callocN, NULL, wmTooltipState::pass, PIL_check_seconds_timer(), uiBut::rect, bScreen::tool_tip, uiBut::type, type, UI_ACTIVE, UI_BTYPE_CURVE, UI_BTYPE_CURVEPROFILE, UI_BTYPE_GRIP, UI_BTYPE_HOTKEY_EVENT, UI_BTYPE_NUM, UI_BTYPE_SEARCH_MENU, ui_but_first(), UI_but_has_tooltip_label(), UI_BUT_IMMEDIATE, ui_but_tooltip_init(), UI_BUT_UPDATE_DELAY, ui_handle_button_activate(), ui_numedit_set_active(), ui_region_find_active_but(), ARegion::uiblocks, WM_cursor_modal_set(), WM_CURSOR_X_MOVE, WM_CURSOR_Y_MOVE, WM_tooltip_immediate_init(), WM_tooltip_time_closed(), and WM_window_get_active_screen().
Referenced by ui_but_activate_event(), ui_but_activate_over(), ui_but_list_row_text_activate(), ui_but_pie_button_activate(), ui_but_pie_menu_apply(), ui_do_but_TOG(), ui_handle_button_activate(), ui_handle_button_event(), and ui_handle_button_over().
|
static |
Definition at line 7926 of file interface_handlers.c.
References uiBut::active, uiBlock::auto_open, uiBut::block, BUTTON_AUTO_OPEN_THRESH, BUTTON_FLASH_DELAY, button_modal_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_MENU_OPEN, BUTTON_STATE_NUM_EDITING, BUTTON_STATE_TEXT_EDITING, BUTTON_STATE_TEXT_SELECTING, BUTTON_STATE_WAIT_DRAG, BUTTON_STATE_WAIT_FLASH, BUTTON_STATE_WAIT_RELEASE, button_tooltip_timer_reset(), C, CTX_wm_window(), data, ED_region_tag_redraw_no_rebuild(), ELEM, uiBut::flag, uiBlock::flag, uiBlock::handle, uiBut::hold_func, NULL, uiPopupBlockHandle::popup, RPT_INFO, state, time, TIMER, uiBut::type, UI_BLOCK_LOOP, ui_block_open_begin(), ui_block_open_end(), ui_block_to_window_fl(), UI_BTYPE_BLOCK, UI_BTYPE_MENU, UI_BTYPE_POPOVER, UI_BTYPE_PULLDOWN, UI_BUT_DRIVEN, ui_but_is_cursor_warp(), ui_but_menu_draw_as_popover(), UI_but_paneltype_get(), UI_but_tooltip_timer_remove(), ui_but_update(), ui_handler_region_menu(), ui_numedit_begin(), ui_numedit_end(), UI_SELECT, ui_textedit_begin(), ui_textedit_end(), USER_MENUOPENAUTO, WM_cursor_grab_disable(), WM_cursor_grab_enable(), WM_CURSOR_WRAP_XY, WM_event_add_timer(), WM_event_add_ui_handler(), WM_event_remove_timer(), WM_event_remove_ui_handler(), WM_report(), and WM_stereo3d_enabled().
Referenced by button_activate_exit(), button_activate_init(), ui_but_active_string_clear_and_exit(), ui_but_drag_init(), ui_but_drop(), ui_but_extra_operator_icon_apply(), ui_but_paste_colorband(), ui_but_paste_curvemapping(), ui_but_paste_CurveProfile(), ui_but_paste_numeric_value(), ui_but_paste_text(), ui_but_set_float_array(), ui_do_but_ANY_drag_toggle(), ui_do_but_BLOCK(), ui_do_but_BUT(), ui_do_but_COLOR(), ui_do_but_COLORBAND(), ui_do_but_CURVE(), ui_do_but_CURVEPROFILE(), ui_do_but_EXIT(), ui_do_but_GRIP(), ui_do_but_HISTOGRAM(), ui_do_but_HOTKEYEVT(), ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_do_but_KEYEVT(), ui_do_but_NUM(), ui_do_but_SCROLL(), ui_do_but_SLI(), ui_do_but_TAB(), ui_do_but_TEX(), ui_do_but_textedit(), ui_do_but_textedit_select(), ui_do_but_TOG(), ui_do_but_TRACKPREVIEW(), ui_do_but_UNITVEC(), ui_do_but_WAVEFORM(), ui_handle_button_event(), ui_handle_button_return_submenu(), and ui_handler_region_menu().
|
static |
Definition at line 7915 of file interface_handlers.c.
References BUTTON_STATE_MENU_OPEN, BUTTON_STATE_NUM_EDITING, BUTTON_STATE_TEXT_EDITING, BUTTON_STATE_TEXT_SELECTING, BUTTON_STATE_WAIT_KEY_EVENT, BUTTON_STATE_WAIT_RELEASE, ELEM, and state.
Referenced by button_activate_state(), ui_handle_menu_event(), and ui_pie_handler().
Definition at line 7884 of file interface_handlers.c.
References uiBut::active, uiBut::block, C, CTX_wm_manager(), data, wmWindowManager::drags, ListBase::first, wmTooltipState::pass, bScreen::tool_tip, uiBlock::tooltipdisabled, UI_but_has_tooltip_label(), ui_but_tooltip_init(), UI_TOOLTIP_DELAY, UI_TOOLTIP_DELAY_LABEL, USER_TOOLTIPS, WM_tooltip_timer_clear(), WM_tooltip_timer_init_ex(), and WM_window_get_active_screen().
Referenced by button_activate_state(), ui_do_but_extra_operator_icon(), and ui_handle_button_event().
Definition at line 6052 of file interface_handlers.c.
References max, max_fff(), mul_v3_fl(), and v.
Referenced by ui_numedit_but_HSVCUBE().
|
static |
Definition at line 2343 of file interface_handlers.c.
References BLI_assert, BLI_snprintf(), length(), and output.
Referenced by ui_but_copy_color(), and ui_but_copy_numeric_array().
|
static |
Definition at line 2317 of file interface_handlers.c.
References RNA_property_array_length(), uiBut::rnapoin, and uiBut::rnaprop.
Referenced by ui_but_copy_color(), ui_but_copy_numeric_array(), ui_but_paste_color(), and ui_but_paste_numeric_array().
|
static |
Definition at line 2382 of file interface_handlers.c.
References BLI_assert, and v.
Referenced by ui_but_paste_color(), ui_but_paste_normalized_vector(), and ui_but_paste_numeric_array().
|
static |
Helper for ui_do_but_CURVEPROFILE. Used to tell whether to select a control point's handles.
Definition at line 7164 of file interface_handlers.c.
References ELEM, CurveProfilePoint::flag, CurveProfilePoint::h1, CurveProfilePoint::h2, HD_ALIGN, HD_FREE, PROF_H1_SELECT, PROF_H2_SELECT, and PROF_SELECT.
Referenced by ui_do_but_CURVEPROFILE().
|
static |
Definition at line 736 of file interface_handlers.c.
References C, wmOperatorType::check, and wmOperator::type.
Referenced by ui_apply_but_funcs_after().
Check if a uiAfterFunc is needed for this button.
Definition at line 746 of file interface_handlers.c.
References uiBlock::butm_func, uiBut::func, uiBut::funcN, uiBlock::handle, uiBlock::handle_func, uiBut::optype, uiPopupBlockHandle::popup_op, uiBut::rename_func, uiBut::rnaprop, uiBut::type, and UI_BTYPE_BUT_MENU.
Referenced by ui_apply_but_func(), and ui_apply_but_TEX().
|
static |
Definition at line 704 of file interface_handlers.c.
References BLI_addtail(), MEM_callocN, and UIAfterFuncs.
Referenced by ui_apply_but_func(), ui_apply_but_undo(), and ui_handle_afterfunc_add_operator().
|
static |
Definition at line 661 of file interface_handlers.c.
References uiAfterFunc::rnapoin, uiAfterFunc::rnaprop, and ui_rna_update_preferences_dirty().
Referenced by ui_apply_but_funcs_after().
|
static |
Definition at line 2051 of file interface_handlers.c.
References C, copy_v3_v3(), CTX_wm_window(), data, uiButColorBand::edit_coba, uiButCurveMapping::edit_cumap, uiButCurveProfile::edit_profile, uiBut::editstr, uiBut::editval, uiBut::editvec, wmWindow::eventstate, uiBut::flag, IS_ALLSELECT_EVENT, MEM_freeN, NULL, uiBut::type, ui_apply_but_BLOCK(), ui_apply_but_BUT(), ui_apply_but_BUTM(), ui_apply_but_COLORBAND(), ui_apply_but_CURVE(), ui_apply_but_CURVEPROFILE(), ui_apply_but_HISTOGRAM(), ui_apply_but_IMAGE(), ui_apply_but_NUM(), ui_apply_but_ROW(), ui_apply_but_TAB(), ui_apply_but_TEX(), ui_apply_but_TOG(), ui_apply_but_TRACKPREVIEW(), ui_apply_but_VEC(), ui_apply_but_WAVEFORM(), UI_BTYPE_BLOCK, UI_BTYPE_BUT, UI_BTYPE_BUT_MENU, UI_BTYPE_BUT_TOGGLE, UI_BTYPE_CHECKBOX, UI_BTYPE_CHECKBOX_N, UI_BTYPE_COLOR, UI_BTYPE_COLORBAND, UI_BTYPE_CURVE, UI_BTYPE_CURVEPROFILE, UI_BTYPE_DECORATOR, UI_BTYPE_GRIP, UI_BTYPE_HISTOGRAM, UI_BTYPE_HOTKEY_EVENT, UI_BTYPE_HSVCIRCLE, UI_BTYPE_HSVCUBE, UI_BTYPE_ICON_TOGGLE, UI_BTYPE_ICON_TOGGLE_N, UI_BTYPE_IMAGE, UI_BTYPE_KEY_EVENT, UI_BTYPE_LISTROW, UI_BTYPE_MENU, UI_BTYPE_NUM, UI_BTYPE_NUM_SLIDER, UI_BTYPE_PULLDOWN, UI_BTYPE_ROW, UI_BTYPE_SCROLL, UI_BTYPE_SEARCH_MENU, UI_BTYPE_TAB, UI_BTYPE_TEXT, UI_BTYPE_TOGGLE, UI_BTYPE_TOGGLE_N, UI_BTYPE_TRACK_PREVIEW, UI_BTYPE_UNITVEC, UI_BTYPE_WAVEFORM, UI_BUT_DRAG_MULTI, ui_multibut_restore(), ui_multibut_states_apply(), ui_selectcontext_apply(), ui_selectcontext_begin(), and zero_v3().
Referenced by button_activate_exit(), ui_but_execute_end(), ui_but_extra_operator_icon_apply(), ui_do_but_ANY_drag_toggle(), ui_do_but_BLOCK(), ui_do_but_COLOR(), ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_do_but_textedit(), ui_do_but_TOG(), ui_handle_button_return_submenu(), ui_numedit_apply(), and ui_textedit_begin().
Definition at line 886 of file interface_handlers.c.
References BKE_report(), C, RenderData::cfra, CTX_data_scene(), CTX_wm_reports(), MEM_freeN, NC_SPACE, ND_SPACE_INFO_REPORT, NULL, PROP_PASSWORD, Scene::r, RNA_property_subtype(), uiBut::rnaindex, uiBut::rnapoin, uiBut::rnaprop, RPT_PROPERTY, scene, ui_but_anim_autokey(), WM_event_add_notifier(), and WM_prop_pystring_assign().
Referenced by button_activate_exit(), ui_but_drag_init(), and ui_but_execute_end().
|
static |
Definition at line 1006 of file interface_handlers.c.
References C, data, uiBut::retval, uiBut::type, ui_apply_but_func(), UI_BTYPE_MENU, ui_but_update_edited(), and ui_but_value_set().
Referenced by ui_apply_but().
|
static |
Definition at line 989 of file interface_handlers.c.
References C, data, uiBut::retval, and ui_apply_but_func().
Referenced by ui_apply_but().
|
static |
Definition at line 997 of file interface_handlers.c.
References C, data, uiBut::hardmin, uiBut::retval, ui_apply_but_func(), and ui_but_value_set().
Referenced by ui_apply_but().
|
static |
Definition at line 1146 of file interface_handlers.c.
References C, data, uiBut::retval, and ui_apply_but_func().
Referenced by ui_apply_but().
|
static |
Definition at line 1153 of file interface_handlers.c.
References C, data, uiBut::retval, and ui_apply_but_func().
Referenced by ui_apply_but().
|
static |
Definition at line 1160 of file interface_handlers.c.
References C, data, uiBut::retval, and ui_apply_but_func().
Referenced by ui_apply_but().
Definition at line 753 of file interface_handlers.c.
References uiAfterFunc::a2, uiBut::a2, uiButSearch::arg, uiButSearch::arg_free_fn, uiBut::block, uiAfterFunc::butm_func, uiBlock::butm_func, uiAfterFunc::butm_func_arg, uiBlock::butm_func_arg, C, uiAfterFunc::context, uiBut::context, CTX_store_copy(), ELEM, uiAfterFunc::func, uiBut::func, uiAfterFunc::func_arg1, uiBut::func_arg1, uiAfterFunc::func_arg2, uiBut::func_arg2, uiAfterFunc::func_argN, uiBut::func_argN, uiAfterFunc::funcN, uiBut::funcN, uiBlock::handle, uiAfterFunc::handle_func, uiBlock::handle_func, uiAfterFunc::handle_func_arg, uiBlock::handle_func_arg, MEM_dupallocN, NULL, uiAfterFunc::opcontext, uiBut::opcontext, uiAfterFunc::opptr, uiBut::opptr, uiAfterFunc::optype, uiBut::optype, uiAfterFunc::popup_op, uiPopupBlockHandle::popup_op, uiAfterFunc::rename_arg1, uiBut::rename_arg1, uiAfterFunc::rename_func, uiBut::rename_func, uiAfterFunc::rename_orig, uiBut::rename_orig, uiAfterFunc::retval, uiBut::retval, uiAfterFunc::rnapoin, uiBut::rnapoin, uiAfterFunc::rnaprop, uiBut::rnaprop, uiAfterFunc::search_arg, uiAfterFunc::search_arg_free_fn, uiBut::type, ui_afterfunc_check(), ui_afterfunc_new(), UI_BTYPE_BUT_MENU, and UI_BTYPE_SEARCH_MENU.
Referenced by ui_apply_but_BLOCK(), ui_apply_but_BUT(), ui_apply_but_BUTM(), ui_apply_but_COLORBAND(), ui_apply_but_CURVE(), ui_apply_but_CURVEPROFILE(), ui_apply_but_HISTOGRAM(), ui_apply_but_IMAGE(), ui_apply_but_NUM(), ui_apply_but_ROW(), ui_apply_but_TAB(), ui_apply_but_TEX(), ui_apply_but_TOG(), ui_apply_but_TRACKPREVIEW(), ui_apply_but_VEC(), and ui_apply_but_WAVEFORM().
|
static |
Definition at line 911 of file interface_handlers.c.
References uiAfterFunc::a2, BLI_freelinkN(), BLI_listbase_clear(), uiAfterFunc::butm_func, uiAfterFunc::butm_func_arg, C, uiAfterFunc::context, CTX_store_free(), CTX_store_set(), PointerRNA::data, ED_undo_push(), uiAfterFunc::func, uiAfterFunc::func_arg1, uiAfterFunc::func_arg2, uiAfterFunc::func_argN, uiAfterFunc::funcN, uiAfterFunc::handle_func, uiAfterFunc::handle_func_arg, LISTBASE_FOREACH_MUTABLE, MEM_freeN, NULL, uiAfterFunc::opcontext, uiAfterFunc::opptr, uiAfterFunc::optype, popup_check(), uiAfterFunc::popup_op, uiAfterFunc::rename_arg1, uiAfterFunc::rename_func, uiAfterFunc::rename_orig, uiAfterFunc::retval, RNA_property_update(), uiAfterFunc::rnapoin, uiAfterFunc::rnaprop, uiAfterFunc::search_arg, uiAfterFunc::search_arg_free_fn, ui_afterfunc_update_preferences_dirty(), UIAfterFuncs, uiAfterFunc::undostr, WM_operator_name_call_ptr(), and WM_operator_properties_free().
Referenced by ui_drag_toggle_set_xy_xy(), ui_handler_region_menu(), ui_popup_handler(), ui_popup_handler_remove(), ui_region_handler(), and ui_region_handler_remove().
|
static |
Definition at line 2030 of file interface_handlers.c.
References C, data, uiBut::retval, and ui_apply_but_func().
Referenced by ui_apply_but().
|
static |
Definition at line 2023 of file interface_handlers.c.
References C, data, uiBut::retval, and ui_apply_but_func().
Referenced by ui_apply_but().
|
static |
Definition at line 1114 of file interface_handlers.c.
References C, data, uiBut::retval, ui_apply_but_func(), ui_but_string_set(), ui_but_update_edited(), ui_but_value_get(), and ui_but_value_set().
Referenced by ui_apply_but().
|
static |
Definition at line 1043 of file interface_handlers.c.
References uiBlock::buttons, C, data, ELEM, uiBut::hardmax, LISTBASE_FOREACH, uiBut::poin, uiBut::retval, ui_apply_but_func(), UI_BTYPE_LISTROW, UI_BTYPE_ROW, ui_but_update_edited(), and ui_but_value_set().
Referenced by ui_apply_but().
|
static |
Definition at line 1099 of file interface_handlers.c.
References C, data, uiBut::hardmax, uiBut::retval, ui_apply_but_func(), ui_but_string_set(), ui_but_update_edited(), and ui_but_value_set().
Referenced by ui_apply_but().
|
static |
Definition at line 1060 of file interface_handlers.c.
References BLI_strdup(), uiBut::block, C, data, uiBut::flag, uiBut::func_arg2, uiButSearch::item_active, NULL, uiBut::rename_orig, uiBut::retval, uiBut::type, ui_afterfunc_check(), ui_apply_but_func(), UI_BTYPE_SEARCH_MENU, ui_but_string_set(), UI_BUT_TEXTEDIT_UPDATE, and ui_but_update_edited().
Referenced by ui_apply_but(), and ui_but_active_string_clear_and_exit().
|
static |
Definition at line 1018 of file interface_handlers.c.
References uiBut::bit, uiBut::bitnr, C, data, ELEM, uiBut::retval, uiBut::type, ui_apply_but_func(), UI_BITBUT_VALUE_TOGGLED, UI_BTYPE_CHECKBOX_N, UI_BTYPE_ICON_TOGGLE, UI_BTYPE_ICON_TOGGLE_N, UI_BTYPE_TOGGLE_N, ui_but_update_edited(), ui_but_value_get(), and ui_but_value_set().
Referenced by ui_apply_but().
|
static |
Definition at line 2044 of file interface_handlers.c.
References C, data, uiBut::retval, and ui_apply_but_func().
Referenced by ui_apply_but().
|
static |
Definition at line 822 of file interface_handlers.c.
References BKE_paintmode_get_active_from_context(), BLI_strncpy(), uiBut::block, uiBut::drawstr, ED_undo_is_legacy_compatible_for_property(), ELEM, uiBlock::evil_C, uiBut::flag, min_zz(), NULL, PointerRNA::owner_id, PAINT_MODE_SCULPT, uiBut::rnapoin, uiBut::rnaprop, SIZE_MAX, str, uiBut::tip, uiBut::type, ui_afterfunc_new(), UI_BTYPE_MENU, ui_but_drawstr_len_without_sep_char(), ui_but_tip_len_only_first_line(), UI_BUT_UNDO, and uiAfterFunc::undostr.
Referenced by button_activate_exit(), ui_handle_list_event(), and ui_handler_region_drag_toggle().
|
static |
Definition at line 1136 of file interface_handlers.c.
References C, data, uiBut::retval, ui_apply_but_func(), ui_but_update_edited(), and ui_but_v3_set().
Referenced by ui_apply_but().
|
static |
Definition at line 2037 of file interface_handlers.c.
References C, data, uiBut::retval, and ui_apply_but_func().
Referenced by ui_apply_but().
Definition at line 9574 of file interface_handlers.c.
References copy_v2_v2(), PieMenuData::flags, len, normalize_v2_v2(), PieMenuData::pie_center_init, PieMenuData::pie_center_spawned, uiBlock::pie_data, PieMenuData::pie_dir, sub_v2_v2v2(), UI_PIE_INITIAL_DIRECTION, and UI_PIE_INVALID_DIR.
Referenced by ui_pie_handler(), and ui_popup_block_refresh().
|
static |
Definition at line 4051 of file interface_handlers.c.
References BLI_assert, uiBut::block, uiBut::block_create_func, C, copy_v3_v3(), data, uiBut::editvec, uiBut::func_argN, uiBlock::handle, IS_ALLSELECT_EVENT, uiBut::menu_create_func, NULL, uiBut::poin, uiPopupBlockHandle::popup, uiBut::type, ui_block_func_COLOR(), UI_BTYPE_BLOCK, UI_BTYPE_COLOR, UI_BTYPE_MENU, UI_BTYPE_POPOVER, UI_BTYPE_PULLDOWN, ui_but_menu_draw_as_popover(), ui_but_v3_get(), ui_popover_panel_create(), ui_popup_block_create(), and ui_popup_menu_create().
Referenced by button_activate_state().
|
static |
Definition at line 4134 of file interface_handlers.c.
References uiBlock::auto_open_last, uiBut::block, C, data, uiBut::editval, uiBut::editvec, NULL, PIL_check_seconds_timer(), and ui_popup_block_free().
Referenced by button_activate_state().
|
static |
Definition at line 10318 of file interface_handlers.c.
References uiBlock::buttons, ELEM, uiBlock::flag, KM_PRESS, LISTBASE_FOREACH, NULL, uiBut::pie_dir, uiBut::type, UI_BLOCK_NUMSELECT, UI_BTYPE_SEPR, UI_BTYPE_SEPR_LINE, and wmEvent::val.
Referenced by ui_pie_handler().
|
static |
Definition at line 7820 of file interface_handlers.c.
References LISTBASE_FOREACH, and ARegion::uiblocks.
Referenced by button_activate_exit(), ui_handle_button_event(), ui_handler_region_menu(), ui_popup_handler(), and ui_region_handler().
Exported to interface.c: UI_but_active_only()
Definition at line 8607 of file interface_handlers.c.
References uiBut::block, button_activate_init(), BUTTON_ACTIVATE_OVER, C, CTX_wm_window(), EVT_BUT_OPEN, KM_PRESS, ui_do_button(), and wm_event_init_from_window().
Referenced by UI_but_active_only_ex().
Simulate moving the mouse over a button (or navigating to it with arrow keys).
exported so menus can start with a highlighted button, even if the mouse isn't over it
Definition at line 8630 of file interface_handlers.c.
References button_activate_init(), BUTTON_ACTIVATE_OVER, and C.
Referenced by ui_block_func_POPUP().
| bool UI_but_active_drop_color | ( | bContext * | C | ) |
Definition at line 11135 of file interface_handlers.c.
References C, CTX_wm_region(), uiBut::type, UI_BTYPE_COLOR, and ui_region_find_active_but().
Referenced by UI_drop_color_poll().
| bool UI_but_active_drop_name | ( | bContext * | C | ) |
Definition at line 11121 of file interface_handlers.c.
References C, CTX_wm_region(), ELEM, uiBut::type, UI_BTYPE_SEARCH_MENU, UI_BTYPE_TEXT, and ui_region_find_active_but().
Referenced by node_add_collection_poll(), node_add_object_poll(), node_add_texture_poll(), and wm_drop_operator_options().
Definition at line 8324 of file interface_handlers.c.
References uiBut::active, button_activate_exit(), C, and data.
Referenced by UI_but_active_only_ex(), ui_but_free(), and UI_screen_free_active_but().
Definition at line 2862 of file interface_handlers.c.
References uiBut::active, button_activate_state(), BUTTON_STATE_EXIT, C, MEM_callocN, uiHandleButtonData::str, and ui_apply_but_TEX().
Referenced by button_string_clear_exec().
| void ui_but_clipboard_free | ( | void | ) |
Definition at line 2779 of file interface_handlers.c.
References BKE_curvemapping_free_data(), BKE_curveprofile_free_data(), but_copypaste_curve, and but_copypaste_profile.
Referenced by UI_exit().
Definition at line 2618 of file interface_handlers.c.
References C, copy_array(), PointerRNA::data, NULL, uiBut::optype, uiBut::poin, uiBut::rnapoin, uiBut::type, UI_BTYPE_BUT, UI_BTYPE_COLOR, UI_BTYPE_COLORBAND, UI_BTYPE_CURVE, UI_BTYPE_CURVEPROFILE, UI_BTYPE_MENU, UI_BTYPE_NUM, UI_BTYPE_NUM_SLIDER, UI_BTYPE_POPOVER, UI_BTYPE_PULLDOWN, UI_BTYPE_SEARCH_MENU, UI_BTYPE_TEXT, UI_BTYPE_UNITVEC, ui_but_contains_password(), ui_but_copy_color(), ui_but_copy_colorband(), ui_but_copy_curvemapping(), ui_but_copy_CurveProfile(), ui_but_copy_menu(), ui_but_copy_numeric_array(), ui_but_copy_numeric_value(), ui_but_copy_operator(), ui_but_copy_popover(), ui_but_copy_text(), ui_but_has_array_value(), and WM_clipboard_text_set().
Referenced by ui_do_button().
|
static |
Definition at line 2462 of file interface_handlers.c.
References float_array_to_string(), get_but_property_array_length(), output, PROP_COLOR_GAMMA, RNA_property_float_get_index(), RNA_property_subtype(), uiBut::rnapoin, uiBut::rnaprop, srgb_to_linearrgb_v3_v3(), and ui_but_v3_get().
Referenced by ui_but_copy().
|
static |
Definition at line 2522 of file interface_handlers.c.
References but_copypaste_coba, NULL, and uiBut::poin.
Referenced by ui_but_copy().
|
static |
Definition at line 2542 of file interface_handlers.c.
References BKE_curvemapping_copy_data(), BKE_curvemapping_free_data(), but_copypaste_curve, but_copypaste_curve_alive, NULL, and uiBut::poin.
Referenced by ui_but_copy().
|
static |
Definition at line 2565 of file interface_handlers.c.
References BKE_curveprofile_copy_data(), BKE_curveprofile_free_data(), but_copypaste_profile, but_copypaste_profile_alive, NULL, and uiBut::poin.
Referenced by ui_but_copy().
|
static |
Definition at line 2598 of file interface_handlers.c.
References BLI_snprintf(), MenuType::idname, output, and UI_but_menutype_get().
Referenced by ui_but_copy().
|
static |
Definition at line 2374 of file interface_handlers.c.
References float_array_to_string(), get_but_property_array_length(), output, RNA_property_float_get_array(), uiBut::rnapoin, and uiBut::rnaprop.
Referenced by ui_but_copy().
|
static |
Definition at line 2419 of file interface_handlers.c.
References BLI_str_rstrip_float_zero(), NULL, output, ui_but_string_get_ex(), and UI_PRECISION_FLOAT_MAX.
Referenced by ui_but_copy().
|
static |
Definition at line 2588 of file interface_handlers.c.
References BLI_strncpy(), C, MEM_freeN, NULL, uiBut::optype, output, str, UI_but_operator_ptr_get(), and WM_operator_pystring_ex().
Referenced by ui_but_copy().
|
static |
Definition at line 2608 of file interface_handlers.c.
References BLI_snprintf(), PanelType::idname, output, and UI_but_paneltype_get().
Referenced by ui_but_copy().
|
static |
Definition at line 2504 of file interface_handlers.c.
References output, and ui_but_string_get().
Referenced by ui_but_copy().
|
static |
Definition at line 1894 of file interface_handlers.c.
References abs(), BLI_rctf_cent_x(), BLI_rctf_cent_y(), BLI_rctf_size_x(), BLI_rctf_size_y(), uiBut::block, uiDragToggleHandle::but_cent_start, button_activate_state(), BUTTON_STATE_EXIT, C, uiDragColorHandle::color, copy_v2_v2_int(), copy_v3_v3(), CTX_wm_region(), CTX_wm_region_set(), CTX_wm_window(), data, uiBut::dragflag, uiBut::dragpoin, uiBut::dragtype, ELEM, uiDragColorHandle::gamma_corrected, uiBut::icon, uiBut::imb, uiBut::imb_scale, uiDragToggleHandle::is_xy_lock_init, MEM_callocN, MEM_freeN, min_ii(), NULL, uiBut::poin, uiBut::pointype, PROP_COLOR, PROP_COLOR_GAMMA, uiDragToggleHandle::pushed_state, uiBut::rect, RGN_ALIGN_BOTTOM, RGN_ALIGN_ENUM_FROM_MASK, RGN_ALIGN_LEFT, RGN_ALIGN_RIGHT, RGN_ALIGN_TOP, RGN_TYPE_FOOTER, RGN_TYPE_HEADER, RGN_TYPE_NAV_BAR, RGN_TYPE_TOOL_HEADER, RNA_property_subtype(), uiBut::rnaprop, uiBut::type, ui_apply_but_autokey(), ui_block_to_window_scale(), UI_BTYPE_COLOR, UI_BUT_DRAGPOIN_FREE, UI_BUT_POIN_CHAR, UI_BUT_POIN_FLOAT, ui_but_v3_get(), ui_but_value_get(), ui_drag_toggle_but_is_supported(), ui_drag_toggle_but_pushed_state(), ui_handler_region_drag_toggle(), ui_handler_region_drag_toggle_remove(), UI_UNIT_Y, WM_DRAG_COLOR, WM_DRAG_FREE_DATA, WM_DRAG_NOP, WM_event_add_ui_handler(), WM_event_drag_image(), WM_event_drag_threshold(), WM_event_start_drag(), WM_gestures_remove(), WM_HANDLER_BLOCKING, wmEvent::x, uiDragToggleHandle::xy_init, uiDragToggleHandle::xy_last, uiDragToggleHandle::xy_lock, and wmEvent::y.
Referenced by ui_do_but_BLOCK(), ui_do_but_COLOR(), and ui_do_but_EXIT().
|
static |
Ignore mouse movements within some horizontal pixel threshold before starting to drag
Definition at line 600 of file interface_handlers.c.
References abs(), BUTTON_DRAGLOCK_THRESH, data, and ELEM.
Referenced by ui_numedit_but_NUM(), and ui_numedit_but_SLI().
|
static |
Definition at line 2269 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_TEXT_EDITING, C, uiBut::changed, data, ELEM, id, LISTBASE_FOREACH, ID::name, uiBut::type, UI_BTYPE_SEARCH_MENU, UI_BTYPE_TEXT, ui_searchbox_update(), ui_textedit_string_set(), WM_drag_get_local_ID(), and WM_DRAG_ID.
Referenced by ui_do_button().
| void ui_but_execute_begin | ( | struct bContext * | UNUSEDC, |
| struct ARegion * | region, | ||
| uiBut * | but, | ||
| void ** | active_back | ||
| ) |
Definition at line 8635 of file interface_handlers.c.
References uiBut::active, BLI_assert, BLI_findindex(), uiBut::block, data, MEM_callocN, NULL, and ARegion::uiblocks.
Referenced by UI_but_execute(), and ui_multibut_states_apply().
| void ui_but_execute_end | ( | struct bContext * | C, |
| struct ARegion * | UNUSEDregion, | ||
| uiBut * | but, | ||
| void * | active_back | ||
| ) |
Definition at line 8652 of file interface_handlers.c.
References uiBut::active, uiBut::block, button_activate_exit(), C, uiBut::flag, ui_apply_but(), ui_apply_but_autokey(), and UI_BUT_DRAG_MULTI.
Referenced by UI_but_execute(), and ui_multibut_states_apply().
|
static |
Definition at line 4028 of file interface_handlers.c.
References uiBut::active, uiBut::block, button_activate_state(), BUTTON_STATE_EXIT, C, CTX_wm_window(), uiHandleButtonData::interactive, wmOperatorCallParams::opcontext, wmOperatorCallParams::opptr, wmOperatorCallParams::optype, uiButExtraOpIcon::optype_params, ui_apply_but(), ui_but_extra_operator_icons_free(), WM_event_add_mousemove(), and WM_operator_name_call_ptr().
Referenced by ui_do_but_extra_operator_icon().
|
static |
Definition at line 4192 of file interface_handlers.c.
References BLI_rctf_isect_pt(), BLI_rctf_size_y(), uiBut::block, data, uiBut::extra_op_icons, ListBase::last, LISTBASE_FOREACH_BACKWARD, NULL, uiBut::rect, ui_window_to_block(), x, rctf::xmax, and y.
Referenced by ui_do_but_extra_operator_icon(), ui_do_but_extra_operator_icons_mousemove(), and ui_do_but_TEX().
Definition at line 8565 of file interface_handlers.c.
References wmEvent::customdata, LISTBASE_FOREACH, NULL, and ARegion::uiblocks.
Referenced by ui_handle_button_over().
Finds the pressed button in an aligned row (typically an expanded enum).
| direction | Use when there may be multiple buttons pressed. |
Definition at line 549 of file interface_handlers.c.
References BLI_assert, ELEM, uiBut::flag, uiBut::next, NULL, uiBut::prev, ui_but_find_select_in_enum__cmp(), and UI_SELECT.
Referenced by ui_do_but_TOG().
Definition at line 537 of file interface_handlers.c.
References uiBut::alignnr, uiBut::poin, uiBut::rnapoin, uiBut::rnaprop, uiBut::type, and PointerRNA::type.
Referenced by ui_but_find_select_in_enum(), and ui_do_but_TOG().
|
static |
Definition at line 2301 of file interface_handlers.c.
References length(), MEM_callocN, and WM_clipboard_text_get_firstline().
Referenced by ui_but_paste().
|
static |
Definition at line 1618 of file interface_handlers.c.
References uiBut::block, ui_block_is_menu(), and ui_drag_toggle_but_is_supported().
Referenced by ui_do_but_ANY_drag_toggle(), ui_do_but_BLOCK(), and ui_do_but_EXIT().
| bool ui_but_is_editing | ( | const uiBut * | but | ) |
Definition at line 499 of file interface_handlers.c.
References uiBut::active, BUTTON_STATE_NUM_EDITING, BUTTON_STATE_TEXT_EDITING, data, and ELEM.
Referenced by ui_but_update_ex().
| bool UI_but_is_userdef | ( | const uiBut * | but | ) |
Definition at line 642 of file interface_handlers.c.
References uiBut::rnapoin, uiBut::rnaprop, and ui_rna_is_userdef().
Referenced by UI_context_active_but_prop_get_filebrowser().
|
static |
Hack for uiList UI_BTYPE_LISTROW buttons to "give" events to overlaying UI_BTYPE_TEXT buttons (Ctrl-Click rename feature & co).
Definition at line 4164 of file interface_handlers.c.
References button_activate_exit(), button_activate_init(), C, CTX_wm_region(), data, uiBut::flag, NULL, uiBut::type, UI_BTYPE_TEXT, UI_BUT_DISABLED, ui_but_find_mouse_over_ex(), wmEvent::x, and wmEvent::y.
Referenced by ui_do_but_LISTROW(), and ui_do_button().
| int ui_but_menu_direction | ( | uiBut * | but | ) |
Definition at line 4149 of file interface_handlers.c.
References uiBut::active, and data.
Referenced by widget_roundbox_set().
|
static |
Definition at line 2714 of file interface_handlers.c.
References BLI_assert, C, data, PointerRNA::data, uiBut::flag, MEM_freeN, NULL, uiBut::poin, uiBut::rnapoin, uiBut::type, UI_BTYPE_COLOR, UI_BTYPE_COLORBAND, UI_BTYPE_CURVE, UI_BTYPE_CURVEPROFILE, UI_BTYPE_NUM, UI_BTYPE_NUM_SLIDER, UI_BTYPE_SEARCH_MENU, UI_BTYPE_TEXT, UI_BTYPE_UNITVEC, UI_BUT_DISABLED, ui_but_get_pasted_text_from_clipboard(), ui_but_has_array_value(), ui_but_paste_color(), ui_but_paste_colorband(), ui_but_paste_curvemapping(), ui_but_paste_CurveProfile(), ui_but_paste_normalized_vector(), ui_but_paste_numeric_array(), ui_but_paste_numeric_value(), and ui_but_paste_text().
Referenced by ui_do_button().
Definition at line 2483 of file interface_handlers.c.
References BLI_assert, C, ELEM, get_but_property_array_length(), linearrgb_to_srgb_v3_v3(), NULL, parse_float_array(), PROP_COLOR_GAMMA, RNA_property_subtype(), uiBut::rnaprop, RPT_ERROR, ui_but_set_float_array(), and WM_report().
Referenced by ui_but_paste().
|
static |
Definition at line 2529 of file interface_handlers.c.
References but_copypaste_coba, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_NUM_EDITING, C, data, MEM_callocN, uiBut::poin, and ColorBand::tot.
Referenced by ui_but_paste().
Definition at line 2551 of file interface_handlers.c.
References BKE_curvemapping_copy_data(), BKE_curvemapping_free_data(), but_copypaste_curve, but_copypaste_curve_alive, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_NUM_EDITING, C, MEM_callocN, and uiBut::poin.
Referenced by ui_but_paste().
Definition at line 2574 of file interface_handlers.c.
References BKE_curveprofile_copy_data(), BKE_curveprofile_free_data(), but_copypaste_profile, but_copypaste_profile_alive, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_NUM_EDITING, C, MEM_callocN, and uiBut::poin.
Referenced by ui_but_paste().
|
static |
Definition at line 2444 of file interface_handlers.c.
References C, data, normalize_v3(), parse_float_array(), RPT_ERROR, ui_but_set_float_array(), and WM_report().
Referenced by ui_but_paste().
|
static |
Definition at line 2398 of file interface_handlers.c.
References C, data, get_but_property_array_length(), parse_float_array(), RPT_ERROR, ui_but_set_float_array(), and WM_report().
Referenced by ui_but_paste().
|
static |
Definition at line 2427 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_NUM_EDITING, C, data, RPT_ERROR, ui_but_string_eval_number(), ui_but_string_set(), and WM_report().
Referenced by ui_but_paste().
|
static |
Definition at line 2509 of file interface_handlers.c.
References uiBut::active, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_TEXT_EDITING, C, uiBut::changed, data, uiBut::type, UI_BTYPE_SEARCH_MENU, ui_searchbox_update(), and ui_textedit_string_set().
Referenced by ui_but_paste().
|
static |
Definition at line 10331 of file interface_handlers.c.
References uiBut::active, button_activate_exit(), button_activate_init(), BUTTON_ACTIVATE_OVER, C, NULL, uiPopupBlockHandle::region, ui_but_pie_menu_apply(), ui_region_find_active_but(), and WM_UI_HANDLER_BREAK.
Referenced by ui_pie_handler().
|
static |
Definition at line 10281 of file interface_handlers.c.
References uiBut::active, button_activate_exit(), button_activate_init(), BUTTON_ACTIVATE_OPEN, C, ED_region_tag_redraw(), uiPopupBlockHandle::menuretval, uiPopupBlockHandle::region, uiBut::type, UI_BTYPE_MENU, ui_but_pie_menu_supported_apply(), ui_region_find_active_but(), UI_RETURN_CANCEL, UI_RETURN_OK, and WM_UI_HANDLER_BREAK.
Referenced by ui_but_pie_button_activate(), and ui_pie_handler().
|
static |
Definition at line 10276 of file interface_handlers.c.
References ELEM, uiBut::type, UI_BTYPE_NUM, and UI_BTYPE_NUM_SLIDER.
Referenced by ui_but_pie_menu_apply().
|
static |
Definition at line 2322 of file interface_handlers.c.
References BLI_assert, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_NUM_EDITING, C, copy_v3_v3(), data, RNA_property_float_set_index(), uiBut::rnaindex, uiBut::rnapoin, uiBut::rnaprop, uiBut::type, and UI_BTYPE_UNITVEC.
Referenced by ui_but_paste_color(), ui_but_paste_normalized_vector(), and ui_but_paste_numeric_array().
| void ui_but_text_password_hide | ( | char | password_str[UI_MAX_PASSWORD_STR], |
| uiBut * | but, | ||
| const bool | restore | ||
| ) |
Definition at line 2817 of file interface_handlers.c.
References BLI_strlen_utf8(), BLI_strncpy(), uiBut::drawstr, uiBut::editstr, if(), len, uiBut::pos, PROP_PASSWORD, RNA_property_subtype(), uiBut::rnaprop, uiBut::selend, uiBut::selsta, UI_MAX_PASSWORD_STR, ui_text_position_from_hidden(), and ui_text_position_to_hidden().
Referenced by ui_textedit_set_cursor_pos(), and widget_draw_text_icon().
|
static |
Definition at line 7866 of file interface_handlers.c.
References C, NULL, UI_region_active_but_get(), UI_tooltip_create_from_button(), UI_TOOLTIP_DELAY, and UI_TOOLTIP_DELAY_LABEL.
Referenced by button_activate_init(), and button_tooltip_timer_reset().
Recreate tool-tip (use to update dynamic tips)
Definition at line 7836 of file interface_handlers.c.
References uiBut::active, C, data, wmTooltipState::region, bScreen::tool_tip, WM_tooltip_refresh(), and WM_window_get_active_screen().
Referenced by UI_block_update_from_old().
Removes tool-tip timer from active but (meaning tool-tip is disabled until it's re-enabled again).
Definition at line 7851 of file interface_handlers.c.
References uiBut::active, C, data, NULL, WM_event_remove_timer(), and WM_tooltip_clear().
Referenced by button_activate_state(), outliner_operation(), ui_handle_button_event(), ui_handle_menu_event(), ui_popup_block_create(), and ui_region_handler().
|
static |
Definition at line 656 of file interface_handlers.c.
References uiBut::rnapoin, uiBut::rnaprop, and ui_rna_update_preferences_dirty().
Referenced by button_activate_exit(), and ui_drag_toggle_set_xy_xy().
Definition at line 8714 of file interface_handlers.c.
References double(), ELEM, NULL, PROP_FLOAT, PROP_INT, RNA_property_array_check(), RNA_property_float_get_default(), RNA_property_float_get_default_index(), RNA_property_int_get_default(), RNA_property_int_get_default_index(), RNA_property_type(), uiBut::rnaindex, uiBut::rnapoin, uiBut::rnaprop, type, and ui_but_is_rna_valid().
Referenced by ui_handle_button_event().
|
static |
Definition at line 6093 of file interface_handlers.c.
References uiButHSVCube::gradient_type, hsl_to_rgb_v(), hsv_to_rgb_v(), and UI_GRAD_L_ALT.
Referenced by ui_do_but_HSVCUBE(), and ui_numedit_but_HSVCUBE().
Definition at line 689 of file interface_handlers.c.
References BLI_assert, snap(), SNAP_OFF, and SNAP_ON_SMALL.
Referenced by ui_numedit_but_HSVCIRCLE(), and ui_numedit_but_HSVCUBE().
Definition at line 8461 of file interface_handlers.c.
References C, and wm_event_handler_ui_cancel_ex().
Referenced by datadropper_invoke(), depthdropper_invoke(), driverdropper_invoke(), eyedropper_colorband_invoke(), and eyedropper_invoke().
Definition at line 8387 of file interface_handlers.c.
References C, CTX_wm_region(), NULL, and ui_context_button_active().
Definition at line 8397 of file interface_handlers.c.
References C, CTX_wm_menu(), CTX_wm_region(), NULL, and ui_context_button_active().
| uiBut* UI_context_active_but_prop_get | ( | const bContext * | C, |
| struct PointerRNA * | r_ptr, | ||
| struct PropertyRNA ** | r_prop, | ||
| int * | r_index | ||
| ) |
Version of UI_context_active_but_get that also returns RNA property info. Helper function for insert keyframe, reset to default, etc operators.
Definition at line 8426 of file interface_handlers.c.
References C, PointerRNA::data, NULL, uiBut::rnaindex, uiBut::rnapoin, uiBut::rnaprop, and ui_context_rna_button_active().
| void UI_context_active_but_prop_handle | ( | bContext * | C | ) |
Definition at line 8447 of file interface_handlers.c.
References uiBut::block, C, uiBlock::handle_func, uiBlock::handle_func_arg, uiBut::retval, and ui_context_rna_button_active().
Referenced by operator_button_property_finish().
| wmOperator* UI_context_active_operator_get | ( | const struct bContext * | C | ) |
Definition at line 8466 of file interface_handlers.c.
References C, CTX_wm_region(), CTX_wm_screen(), LISTBASE_FOREACH, NULL, bScreen::regionbase, and ARegion::uiblocks.
Referenced by screen_ctx_active_operator().
|
static |
Definition at line 8337 of file interface_handlers.c.
References uiBut::active, data, uiBut::flag, LISTBASE_FOREACH, NULL, UI_BUT_LAST_ACTIVE, and ARegion::uiblocks.
Referenced by UI_context_active_but_get(), UI_context_active_but_get_respect_menu(), ui_context_rna_button_active(), and UI_region_active_but_get().
Definition at line 8382 of file interface_handlers.c.
References C, CTX_wm_region(), ui_context_button_active(), and ui_context_rna_button_active_test().
Referenced by UI_context_active_but_prop_get(), and UI_context_active_but_prop_handle().
|
static |
Definition at line 8378 of file interface_handlers.c.
References PointerRNA::data, NULL, and uiBut::rnapoin.
Referenced by ui_context_rna_button_active().
| void UI_context_update_anim_flag | ( | const bContext * | C | ) |
Definition at line 8511 of file interface_handlers.c.
References uiBut::active, BKE_animsys_eval_context_construct(), C, RenderData::cfra, CTX_data_depsgraph_pointer(), CTX_data_main(), CTX_data_scene(), CTX_wm_region(), data, depsgraph, ED_region_tag_redraw(), uiBut::flag, LISTBASE_FOREACH, NULL, Scene::r, scene, ui_but_anim_decorate_update_from_flag(), ui_but_anim_flag(), UI_but_is_decorator, UI_BUT_LAST_ACTIVE, ui_but_override_flag(), and ARegion::uiblocks.
|
static |
Definition at line 4277 of file interface_handlers.c.
References uiBut::block, button_activate_state(), BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_WAIT_DRAG, C, data, KM_PRESS, LEFTMOUSE, wmEvent::type, ui_apply_but(), ui_but_is_drag_toggle(), ui_do_but_EXIT(), wmEvent::val, and WM_UI_HANDLER_BREAK.
Referenced by ui_do_but_BUT(), ui_do_but_TAB(), and ui_do_but_TOG().
|
static |
Definition at line 5669 of file interface_handlers.c.
References uiBut::block, BUTTON_ACTIVATE_OVER, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_MENU_OPEN, BUTTON_STATE_WAIT_DRAG, C, wmEvent::ctrl, data, uiBut::dragpoin, ELEM, EVT_PADENTER, EVT_RETKEY, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEPAN, type, wmEvent::type, ui_apply_but(), ui_but_contains_point_px_icon(), ui_but_drag_init(), ui_but_is_drag_toggle(), ui_but_menu_step(), ui_but_supports_cycling(), ui_pan_to_scroll(), wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_event_add_mousemove(), WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 4305 of file interface_handlers.c.
References uiBut::block, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_WAIT_FLASH, BUTTON_STATE_WAIT_RELEASE, C, data, ELEM, EVT_PADENTER, EVT_RETKEY, uiBut::flag, uiBlock::handle, KM_PRESS, KM_RELEASE, LEFTMOUSE, wmEvent::type, UI_ACTIVE, ui_do_but_ANY_drag_toggle(), UI_SELECT, wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 5852 of file interface_handlers.c.
References BKE_brush_color_set(), BKE_paint_brush(), BKE_paint_get_active_from_context(), BKE_palette_color_remove(), BLI_assert, uiBut::block, BRUSH_USE_GRADIENT, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_MENU_OPEN, BUTTON_STATE_WAIT_DRAG, C, clamp_f(), col, wmEvent::ctrl, CTX_data_scene(), ColorBand::cur, uiBut::custom_data, data, ColorBand::data, PointerRNA::data, uiBut::dragpoin, ELEM, EVT_DELKEY, EVT_PADENTER, EVT_RETKEY, Brush::flag, Brush::gradient, ColorPicker::hsv_perceptual, hsv_to_rgb_v(), Brush::id, IMB_colormanagement_scene_linear_to_srgb_v3(), IMB_colormanagement_srgb_to_scene_linear_v3(), uiButColor::is_pallete_color, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEPAN, NULL, PointerRNA::owner_id, PointerRNA_NULL, PROP_COLOR, PROP_COLOR_GAMMA, CBData::r, rgb_to_hsv_compat_v(), RNA_id_pointer_create(), RNA_property_float_get_array(), RNA_property_subtype(), RNA_property_update(), RNA_struct_find_property(), uiBut::rnapoin, uiBut::rnaprop, scene, uiBut::type, wmEvent::type, ui_apply_but(), UI_BTYPE_COLOR, ui_but_contains_point_px_icon(), ui_but_drag_init(), ui_but_v3_get(), ui_but_v3_set(), ui_palette_set_active(), wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 6699 of file interface_handlers.c.
References Freestyle::a, abs(), uiBlock::aspect, BKE_colorband_element_add(), BKE_colorband_update_sort(), BLI_rctf_size_x(), button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, wmEvent::ctrl, ColorBand::cur, data, ColorBand::data, ELEM, EVT_ESCKEY, float(), if(), KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, uiBut::poin, pos, CBData::pos, uiBut::rect, RIGHTMOUSE, wmEvent::type, UI_DPI_FAC, ui_numedit_apply(), ui_numedit_but_COLORBAND(), ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, and rctf::xmin.
Referenced by ui_do_button().
|
static |
Definition at line 6891 of file interface_handlers.c.
References Freestyle::a, BKE_curvemap_insert(), BKE_curvemapping_changed(), BLI_rctf_transform_pt_v(), button_activate_state(), BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, CurveMapping::cm, CM_TABLE, copy_v2_v2(), wmEvent::ctrl, CTX_data_scene(), CTX_data_view_layer(), CUMA_SELECT, CurveMapping::cur, data, dist_squared_to_line_segment_v2(), CurveMapPoint::flag, KM_PRESS, LEFTMOUSE, len_squared_v2v2(), uiBut::poin, uiBut::rect, scene, wmEvent::shift, square_f(), wmEvent::type, ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, x, and CurveMapPoint::x.
Referenced by ui_do_button().
|
static |
Interaction for curve profile widget.
Definition at line 7175 of file interface_handlers.c.
References BKE_curveprofile_insert(), BKE_curveprofile_remove_by_flag(), BKE_curveprofile_update(), BLI_assert, BLI_rctf_transform_pt_v(), button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, copy_v2_v2(), wmEvent::ctrl, data, dist_squared_to_line_segment_v2(), ELEM, EVT_GKEY, EVT_XKEY, CurveProfilePoint::flag, CurveProfilePoint::h1, CurveProfilePoint::h1_loc, CurveProfilePoint::h2, CurveProfilePoint::h2_loc, HD_ALIGN, HD_FREE, KM_PRESS, KM_RELEASE, LEFTMOUSE, len_squared_v2v2(), MOUSEMOVE, CurveProfile::path, CurveProfile::path_len, uiBut::poin, point_draw_handles(), PROF_H1_SELECT, PROF_H2_SELECT, PROF_SELECT, PROF_TABLE_LEN, PROF_UPDATE_CLIP, PROF_UPDATE_NONE, PROF_UPDATE_REMOVE_DOUBLES, uiBut::rect, wmEvent::shift, square_f(), CurveProfile::table, wmEvent::type, ui_numedit_apply(), ui_numedit_but_CURVEPROFILE(), ui_window_to_block(), wmEvent::val, CurveProfile::view_rect, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, CurveProfilePoint::x, wmEvent::x, and wmEvent::y.
Referenced by ui_do_button().
|
static |
Definition at line 4634 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_WAIT_DRAG, C, data, uiBut::dragpoin, ELEM, EVT_PADENTER, EVT_RETKEY, uiBut::imb, KM_PRESS, KM_RELEASE, LEFTMOUSE, ret, wmEvent::type, ui_but_contains_point_px_icon(), ui_but_drag_init(), ui_but_is_drag_toggle(), wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_but_ANY_drag_toggle(), ui_do_but_LISTROW(), and ui_do_button().
|
static |
Definition at line 4224 of file interface_handlers.c.
References button_tooltip_timer_reset(), C, data, ED_region_tag_redraw(), KM_RELEASE, ui_but_extra_operator_icon_apply(), ui_but_extra_operator_icon_mouse_over_get(), and wmEvent::val.
Referenced by ui_do_but_SEARCH_UNLINK(), ui_do_but_textedit(), and ui_do_button().
|
static |
Definition at line 4250 of file interface_handlers.c.
References data, ED_region_tag_redraw_no_rebuild(), uiBut::extra_op_icons, uiButExtraOpIcon::highlighted, LISTBASE_FOREACH, NULL, and ui_but_extra_operator_icon_mouse_over_get().
Referenced by ui_do_but_textedit(), and ui_handle_button_event().
|
static |
Definition at line 5594 of file interface_handlers.c.
References BLI_rctf_size_x(), BLI_rctf_size_y(), button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, data, EVT_ESCKEY, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, uiBut::rect, wmEvent::type, ui_numedit_apply(), ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 7359 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, data, EVT_BACKSPACEKEY, EVT_ESCKEY, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, uiBut::poin, wmEvent::type, ui_numedit_apply(), ui_numedit_but_HISTOGRAM(), ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, and Histogram::ymax.
Referenced by ui_do_button().
|
static |
Definition at line 4347 of file interface_handlers.c.
References uiBut::active, wmEvent::alt, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_WAIT_KEY_EVENT, C, wmEvent::ctrl, data, uiBut::drawstr, ED_region_tag_redraw(), ELEM, EVT_CAPSLOCKKEY, EVT_ESCKEY, EVT_PADENTER, EVT_RETKEY, EVT_UNKNOWNKEY, uiBut::flag, INBETWEEN_MOUSEMOVE, ISHOTKEY, KM_ALT, KM_CTRL, KM_OSKEY, KM_PRESS, KM_SHIFT, LEFTMOUSE, uiBut::modifier_key, MOUSEMOVE, wmEvent::oskey, uiHandleButtonData::region, RPT_WARNING, wmEvent::shift, wmEvent::type, ui_but_contains_point_px(), UI_BUT_IMMEDIATE, ui_but_update(), ui_but_value_set(), wmEvent::val, WM_key_event_string(), WM_report(), WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, and wmEvent::y.
Referenced by ui_do_button().
|
static |
Definition at line 6568 of file interface_handlers.c.
References uiBut::block, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, clamp_f(), uiBut::custom_data, data, ELEM, EVT_BACKSPACEKEY, EVT_ESCKEY, ColorPicker::hsv_perceptual, hsv_to_rgb_v(), KM_PRESS, KM_RELEASE, LEFTMOUSE, len, MEM_callocN, MEM_freeN, MOUSEMOVE, NDOF_MOTION, RIGHTMOUSE, RNA_property_array_length(), RNA_property_float_get_default_array(), RNA_property_update(), uiBut::rnapoin, uiBut::rnaprop, wmEvent::shift, snap(), wmEvent::type, ui_apply_but(), ui_but_hsv_set(), ui_but_v3_get(), ui_but_v3_set(), ui_color_picker_hsv_to_rgb(), ui_color_picker_rgb_to_hsv_compat(), ui_event_is_snap(), ui_event_to_snap(), ui_numedit_apply(), ui_numedit_but_HSVCIRCLE(), ui_window_to_block(), wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 6293 of file interface_handlers.c.
References uiBut::block, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, uiBut::custom_data, data, ELEM, EVT_BACKSPACEKEY, EVT_ESCKEY, uiButHSVCube::gradient_type, ColorPicker::hsv_perceptual, KM_PRESS, KM_RELEASE, LEFTMOUSE, len, MOUSEMOVE, NDOF_MOTION, RIGHTMOUSE, RNA_property_array_length(), RNA_property_float_get_default_array(), RNA_property_update(), uiBut::rnapoin, uiBut::rnaprop, wmEvent::shift, snap(), wmEvent::type, ui_apply_but(), ui_but_v3_get(), ui_but_v3_set(), ui_color_picker_to_rgb_HSVCUBE_v(), ui_event_is_snap(), ui_event_to_snap(), UI_GRAD_L_ALT, UI_GRAD_V_ALT, ui_numedit_apply(), ui_numedit_but_HSVCUBE(), ui_rgb_to_color_picker_HSVCUBE_compat_v(), ui_rgb_to_color_picker_HSVCUBE_v(), ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 4431 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_WAIT_KEY_EVENT, C, data, ELEM, EVT_PADENTER, EVT_RETKEY, INBETWEEN_MOUSEMOVE, KM_PRESS, LEFTMOUSE, MOUSEMOVE, wmEvent::type, ui_but_value_set(), wmEvent::val, WM_key_event_string(), WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 5645 of file interface_handlers.c.
References BUTTON_ACTIVATE_TEXT_EDITING, BUTTON_STATE_HIGHLIGHT, C, wmEvent::ctrl, data, ELEM, EVT_PADENTER, EVT_RETKEY, KM_DBL_CLICK, KM_PRESS, LEFTMOUSE, wmEvent::type, ui_but_list_row_text_activate(), ui_do_but_EXIT(), wmEvent::val, and WM_UI_HANDLER_BREAK.
Referenced by ui_do_button().
|
static |
Definition at line 5020 of file interface_handlers.c.
References abs(), BLI_assert, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, BUTTON_STATE_TEXT_EDITING, BUTTON_STATE_TEXT_SELECTING, C, copy_v2_v2_int(), wmEvent::ctrl, data, double(), uiBut::drawflag, ELEM, EVT_ESCKEY, EVT_MINUSKEY, EVT_PADENTER, EVT_RETKEY, KM_PRESS, KM_RELEASE, LEFTMOUSE, max_ff(), max_ii(), min_ff(), min_ii(), MOUSEMOVE, MOUSEPAN, uiBut::rect, RIGHTMOUSE, round_fl_to_int_clamp(), wmEvent::shift, snap(), uiBut::softmax, uiBut::softmin, uiButNumber::step_size, uiBut::type, type, wmEvent::type, UI_BTYPE_NUM, UI_BUT_ACTIVE_LEFT, UI_BUT_ACTIVE_RIGHT, ui_but_is_cursor_warp(), ui_but_is_float(), ui_do_but_textedit(), ui_do_but_textedit_select(), ui_event_is_snap(), ui_event_to_snap(), ui_multibut_states_apply(), ui_numedit_apply(), ui_numedit_but_NUM(), ui_numedit_set_active(), ui_pan_to_scroll(), UI_PRECISION_FLOAT_SCALE, ui_window_to_block(), wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, rctf::xmax, and rctf::xmin.
Referenced by ui_do_button().
|
static |
Definition at line 5543 of file interface_handlers.c.
References BLI_rctf_size_x(), BLI_rctf_size_y(), button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, data, EVT_ESCKEY, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, uiBut::rect, wmEvent::type, ui_numedit_apply(), ui_numedit_but_SLI(), ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 4536 of file interface_handlers.c.
References C, data, ELEM, EVT_BUT_OPEN, EVT_PADENTER, EVT_RETKEY, KM_RELEASE, LEFTMOUSE, wmEvent::type, ui_do_but_extra_operator_icon(), ui_do_but_TEX(), wmEvent::val, and WM_UI_HANDLER_BREAK.
Referenced by ui_do_button().
|
static |
Definition at line 5340 of file interface_handlers.c.
References abs(), wmEvent::alt, BLI_rctf_cent_x(), BLI_rctf_size_x(), button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, BUTTON_STATE_TEXT_EDITING, BUTTON_STATE_TEXT_SELECTING, C, copy_v2_fl(), copy_v2_v2_int(), wmEvent::ctrl, data, ELEM, EVT_ESCKEY, EVT_MINUSKEY, EVT_PADENTER, EVT_RETKEY, float(), if(), KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, MOUSEPAN, uiBut::rect, RIGHTMOUSE, wmEvent::shift, uiBut::softmax, uiBut::softmin, uiBut::type, type, wmEvent::type, ui_but_is_float(), ui_do_but_textedit(), ui_do_but_textedit_select(), ui_event_is_snap(), ui_multibut_states_apply(), ui_numedit_apply(), ui_numedit_but_SLI(), ui_pan_to_scroll(), ui_window_to_block(), wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, rctf::xmax, and rctf::xmin.
Referenced by ui_do_button().
|
static |
Definition at line 4462 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_TEXT_EDITING, BUTTON_STATE_TEXT_SELECTING, C, wmEvent::ctrl, uiBut::custom_data, data, ELEM, EVT_PADENTER, EVT_RETKEY, KM_CLICK, KM_DBL_CLICK, KM_PRESS, LEFTMOUSE, NULL, PROP_POINTER, PROP_STRING, RNA_property_type(), uiBut::rnaprop, wmEvent::type, ui_do_but_ANY_drag_toggle(), ui_do_but_textedit(), ui_do_but_textedit_select(), wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 4504 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_TEXT_EDITING, BUTTON_STATE_TEXT_SELECTING, C, wmEvent::ctrl, data, ELEM, uiBut::emboss, EVT_BUT_OPEN, EVT_PADENTER, EVT_RETKEY, KM_PRESS, LEFTMOUSE, wmEvent::type, ui_but_extra_operator_icon_mouse_over_get(), UI_but_is_utf8(), ui_do_but_textedit(), ui_do_but_textedit_select(), UI_EMBOSS_NONE, UI_EMBOSS_NONE_OR_STATUS, wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_but_SEARCH_UNLINK(), and ui_do_button().
|
static |
Definition at line 3514 of file interface_handlers.c.
References wmEvent::ascii, ATTR_FALLTHROUGH, AUTOCOMPLETE_FULL_MATCH, uiBut::autocomplete_func, AUTOCOMPLETE_NO_MATCH, BLI_assert, BLI_str_utf8_size(), BLT_lang_is_ime_supported(), button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_TEXT_SELECTING, C, uiBut::changed, wmEvent::ctrl, CTX_wm_window(), data, ED_region_tag_redraw(), ELEM, EVT_AKEY, EVT_BACKSPACEKEY, EVT_CKEY, EVT_DELKEY, EVT_DOWNARROWKEY, EVT_ENDKEY, EVT_ESCKEY, EVT_HOMEKEY, EVT_LEFTARROWKEY, EVT_PADENTER, EVT_PADPERIOD, EVT_RETKEY, EVT_RIGHTARROWKEY, EVT_TABKEY, EVT_UPARROWKEY, EVT_VKEY, EVT_XKEY, EVT_ZKEY, uiBut::flag, wmWindow::ime_data, IS_EVENT_MOD, KM_DBL_CLICK, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, MOUSEPAN, NULL, wmEvent::oskey, uiBut::pos, RIGHTMOUSE, uiBut::selend, uiBut::selsta, wmEvent::shift, STRCUR_DIR_NEXT, STRCUR_DIR_PREV, STRCUR_JUMP_ALL, STRCUR_JUMP_DELIM, STRCUR_JUMP_NONE, uiBut::type, wmEvent::type, ui_apply_but(), UI_BTYPE_NUM, UI_BTYPE_NUM_SLIDER, ui_but_contains_pt(), UI_BUT_TEXTEDIT_UPDATE, ui_but_update_edited(), ui_do_but_extra_operator_icon(), ui_do_but_extra_operator_icons_mousemove(), ui_mouse_motion_keynav_init(), ui_mouse_motion_keynav_test(), ui_searchbox_event(), ui_searchbox_inside(), ui_searchbox_update(), ui_textedit_autocomplete(), UI_TEXTEDIT_COPY, ui_textedit_copypaste(), UI_TEXTEDIT_CUT, ui_textedit_delete(), ui_textedit_delete_selection(), ui_textedit_insert_ascii(), ui_textedit_insert_buf(), ui_textedit_move(), ui_textedit_next_but(), UI_TEXTEDIT_PASTE, ui_textedit_prev_but(), ui_textedit_set_cursor_pos(), ui_textedit_string_set(), ui_textedit_undo(), ui_textedit_undo_push(), ui_window_to_block_fl(), update(), wmEvent::utf8_buf, wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_IME_COMPOSITE_END, WM_IME_COMPOSITE_EVENT, WM_IME_COMPOSITE_START, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, and wmEvent::y.
Referenced by ui_do_but_NUM(), ui_do_but_SLI(), ui_do_but_TAB(), and ui_do_but_TEX().
|
static |
Definition at line 3858 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_TEXT_EDITING, C, data, ED_region_tag_redraw(), KM_RELEASE, LEFTMOUSE, MOUSEMOVE, wmEvent::type, ui_but_update(), ui_textedit_set_cursor_select(), ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, and wmEvent::x.
Referenced by ui_do_but_NUM(), ui_do_but_SLI(), ui_do_but_TAB(), and ui_do_but_TEX().
|
static |
Definition at line 4549 of file interface_handlers.c.
References uiBut::active, BLI_assert, uiBut::block, button_activate_exit(), button_activate_init(), BUTTON_ACTIVATE_OVER, button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, C, wmEvent::ctrl, data, ELEM, EVT_PADENTER, EVT_RETKEY, if(), KM_DBL_CLICK, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEPAN, uiBut::next, uiBut::prev, uiBut::type, type, wmEvent::type, ui_apply_but(), ui_block_is_menu(), UI_BTYPE_ROW, ui_but_find_select_in_enum(), ui_but_find_select_in_enum__cmp(), ui_do_but_ANY_drag_toggle(), ui_pan_to_scroll(), wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 7523 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, data, EVT_ESCKEY, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, wmEvent::shift, wmEvent::type, ui_numedit_apply(), ui_numedit_but_TRACKPREVIEW(), ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 6000 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, data, ELEM, EVT_ESCKEY, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, RIGHTMOUSE, snap(), wmEvent::type, ui_event_is_snap(), ui_event_to_snap(), ui_numedit_apply(), ui_numedit_but_UNITVEC(), ui_window_to_block(), wmEvent::val, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 7432 of file interface_handlers.c.
References button_activate_state(), BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, C, data, EVT_BACKSPACEKEY, EVT_ESCKEY, KM_PRESS, KM_RELEASE, LEFTMOUSE, MOUSEMOVE, uiBut::poin, wmEvent::type, ui_numedit_apply(), ui_numedit_but_WAVEFORM(), ui_window_to_block(), wmEvent::val, Scopes::wavefrm_yfac, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_do_button().
|
static |
Definition at line 7570 of file interface_handlers.c.
References abs(), uiBut::active, wmEvent::alt, uiBlock::aspect, BLI_assert, BUTTON_ACTIVATE_OVER, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_NUM_EDITING, BUTTON_STATE_TEXT_EDITING, C, data, dot_v2v2(), DRAG_MULTINUM_THRESHOLD_DRAG_X, DRAG_MULTINUM_THRESHOLD_DRAG_Y, DRAG_MULTINUM_THRESHOLD_VERTICAL, ED_region_tag_redraw(), ELEM, EVT_BUT_OPEN, EVT_CKEY, EVT_DROP, EVT_PADENTER, EVT_RETKEY, EVT_VKEY, fabsf, uiBut::flag, INBETWEEN_MOUSEMOVE, is_disabled, IS_EVENT_MOD, KM_PRESS, KM_RELEASE, LEFTMOUSE, len_squared_v2(), MOUSEMOVE, normalize_v2_v2(), uiBut::poin, uiBut::pointype, wmEvent::prevx, wmEvent::prevy, RIGHTMOUSE, sqrtf, uiBut::type, wmEvent::type, UI_BTYPE_BLOCK, UI_BTYPE_BUT, UI_BTYPE_BUT_MENU, UI_BTYPE_BUT_TOGGLE, UI_BTYPE_CHECKBOX, UI_BTYPE_CHECKBOX_N, UI_BTYPE_COLOR, UI_BTYPE_COLORBAND, UI_BTYPE_CURVE, UI_BTYPE_CURVEPROFILE, UI_BTYPE_DECORATOR, UI_BTYPE_EXTRA, UI_BTYPE_GRIP, UI_BTYPE_HISTOGRAM, UI_BTYPE_HOTKEY_EVENT, UI_BTYPE_HSVCIRCLE, UI_BTYPE_HSVCUBE, UI_BTYPE_ICON_TOGGLE, UI_BTYPE_ICON_TOGGLE_N, UI_BTYPE_IMAGE, UI_BTYPE_KEY_EVENT, UI_BTYPE_LABEL, UI_BTYPE_LISTBOX, UI_BTYPE_LISTROW, UI_BTYPE_MENU, UI_BTYPE_NODE_SOCKET, UI_BTYPE_NUM, UI_BTYPE_NUM_SLIDER, UI_BTYPE_POPOVER, UI_BTYPE_PROGRESS_BAR, UI_BTYPE_PULLDOWN, UI_BTYPE_ROUNDBOX, UI_BTYPE_ROW, UI_BTYPE_SCROLL, UI_BTYPE_SEARCH_MENU, UI_BTYPE_SEPR, UI_BTYPE_SEPR_LINE, UI_BTYPE_SEPR_SPACER, UI_BTYPE_TAB, UI_BTYPE_TEXT, UI_BTYPE_TOGGLE, UI_BTYPE_TOGGLE_N, UI_BTYPE_TRACK_PREVIEW, UI_BTYPE_UNITVEC, UI_BTYPE_VECTORSCOPE, UI_BTYPE_WAVEFORM, ui_but_copy(), UI_BUT_DISABLED, ui_but_drop(), ui_but_list_row_text_activate(), ui_but_paste(), UI_BUT_VALUE_CLEAR, ui_do_but_BLOCK(), ui_do_but_BUT(), ui_do_but_COLOR(), ui_do_but_COLORBAND(), ui_do_but_CURVE(), ui_do_but_CURVEPROFILE(), ui_do_but_EXIT(), ui_do_but_extra_operator_icon(), ui_do_but_GRIP(), ui_do_but_HISTOGRAM(), ui_do_but_HOTKEYEVT(), ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_do_but_KEYEVT(), ui_do_but_LISTROW(), ui_do_but_NUM(), ui_do_but_SCROLL(), ui_do_but_SEARCH_UNLINK(), ui_do_but_SLI(), ui_do_but_TAB(), ui_do_but_TEX(), ui_do_but_TOG(), ui_do_but_TRACKPREVIEW(), ui_do_but_UNITVEC(), ui_do_but_WAVEFORM(), ui_multibut_states_create(), ui_multibut_states_tag(), ui_popup_context_menu_for_button(), wmEvent::val, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, and wmEvent::y.
Referenced by ui_but_activate_event(), ui_handle_button_event(), and ui_handle_button_over().
|
static |
Definition at line 1418 of file interface_handlers.c.
References ELEM, uiBut::flag, uiBut::icon, UI_BUT_DISABLED, ui_but_is_bool(), and UI_but_is_decorator.
Referenced by ui_but_drag_init(), ui_but_is_drag_toggle(), and ui_drag_toggle_set_xy_xy().
Definition at line 1438 of file interface_handlers.c.
References C, PointerRNA::data, uiBut::icon, uiBut::iconadd, NULL, uiBut::poin, uiBut::pushed_state_arg, uiBut::pushed_state_func, uiBut::rnapoin, ui_but_is_bool(), and ui_but_is_pushed().
Referenced by ui_but_drag_init(), and ui_drag_toggle_set_xy_xy().
|
static |
Initialize Locking:
Check if we need to initialize the lock axis by finding if the first button we mouse over is X or Y aligned, then lock the mouse to that axis after.
Definition at line 1515 of file interface_handlers.c.
References BLI_rctf_cent_x(), BLI_rctf_cent_y(), uiDragToggleHandle::but_cent_start, C, copy_v2_v2_int(), CTX_wm_region(), ED_region_tag_redraw(), fabsf, uiBut::flag, uiDragToggleHandle::is_xy_lock_init, len_manhattan_v2v2(), uiDragToggleHandle::pushed_state, uiBut::rect, UI_BUT_DRAG_LOCK, ui_but_find_mouse_over_ex(), ui_drag_toggle_set_xy_xy(), uiDragToggleHandle::xy_last, and uiDragToggleHandle::xy_lock.
Referenced by ui_handler_region_drag_toggle().
|
static |
Definition at line 1467 of file interface_handlers.c.
References BLI_rctf_isect_segment(), C, LISTBASE_FOREACH, ARegion::regiontype, RGN_TYPE_TEMPORARY, ui_apply_but_funcs_after(), UI_but_execute(), ui_but_is_interactive(), ui_but_update_edited(), ui_but_update_preferences_dirty(), ui_drag_toggle_but_is_supported(), ui_drag_toggle_but_pushed_state(), ui_window_to_block_fl(), ARegion::uiblocks, and UNPACK2.
Referenced by ui_drag_toggle_set().
|
static |
Definition at line 683 of file interface_handlers.c.
References ELEM, EVT_LEFTCTRLKEY, EVT_LEFTSHIFTKEY, EVT_RIGHTCTRLKEY, EVT_RIGHTSHIFTKEY, and wmEvent::type.
Referenced by ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_do_but_NUM(), ui_do_but_SLI(), and ui_do_but_UNITVEC().
Definition at line 661 of file interface_handlers.c.
Referenced by ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_do_but_NUM(), and ui_do_but_UNITVEC().
| PointerRNA* ui_handle_afterfunc_add_operator | ( | wmOperatorType * | ot, |
| int | opcontext, | ||
| bool | create_props | ||
| ) |
For executing operators after the button is pressed. (some non operator buttons need to trigger operators), see: T37795.
Definition at line 719 of file interface_handlers.c.
References MEM_callocN, NULL, uiAfterFunc::opcontext, uiAfterFunc::opptr, uiAfterFunc::optype, ot, ptr, ui_afterfunc_new(), and WM_operator_properties_create_ptr().
Referenced by panel_activate_state().
|
static |
Definition at line 8667 of file interface_handlers.c.
References uiBut::active, button_activate_exit(), button_activate_init(), C, data, type, and ui_region_find_active_but().
Referenced by button_activate_init(), ui_handle_button_activate_by_type(), ui_handle_button_event(), ui_handle_menu_event(), and ui_handler_region_menu().
|
static |
Use for key accelerator or default key to activate the button even if its not active.
Definition at line 8685 of file interface_handlers.c.
References BUTTON_ACTIVATE, BUTTON_ACTIVATE_APPLY, BUTTON_ACTIVATE_OPEN, C, ELEM, uiBut::type, UI_BTYPE_BLOCK, UI_BTYPE_BUT_MENU, UI_BTYPE_MENU, UI_BTYPE_PULLDOWN, and ui_handle_button_activate().
Referenced by ui_handle_menu_event().
Definition at line 8747 of file interface_handlers.c.
References uiBut::active, ATTR_FALLTHROUGH, uiBut::block, button_activate_exit(), button_activate_init(), BUTTON_ACTIVATE_OVER, button_activate_state(), BUTTON_ACTIVATE_TEXT_EDITING, BUTTON_STATE_EXIT, BUTTON_STATE_HIGHLIGHT, BUTTON_STATE_INIT, BUTTON_STATE_MENU_OPEN, BUTTON_STATE_WAIT_DRAG, BUTTON_STATE_WAIT_FLASH, BUTTON_STATE_WAIT_RELEASE, button_tooltip_timer_reset(), C, wmEvent::customdata, data, ED_region_tag_redraw_no_rebuild(), ELEM, EVT_BUT_CANCEL, uiBut::flag, uiBlock::flag, uiBlock::handle, uiBut::hold_func, KM_PRESS, KM_RELEASE, l, LEFTMOUSE, len_manhattan_v2v2_int(), MEM_SAFE_FREE, uiPopupBlockHandle::menuretval, MIDDLEMOUSE, MOUSEMOVE, MOUSEPAN, BMLoop::next, NULL, wmEvent::prevx, wmEvent::prevy, PROP_FLOAT, PROP_INT, RIGHTMOUSE, RNA_property_type(), uiBut::rnaprop, state, TIMER, uiBut::type, wmEvent::type, UI_ACTIVE, ui_block_is_menu(), ui_block_is_pie_menu(), UI_BLOCK_POPOVER_ONCE, ui_blocks_set_tooltips(), UI_BTYPE_COLOR, ui_but_contains_point_px(), UI_BUT_DISABLED, ui_but_find_mouse_over(), ui_but_is_editable(), ui_but_is_editable_as_text(), ui_but_is_popover_once_compat(), ui_but_range_set_hard(), ui_but_range_set_soft(), UI_but_tooltip_timer_remove(), ui_but_value_set(), ui_button_value_default(), ui_do_but_extra_operator_icons_mousemove(), ui_do_button(), ui_handle_button_activate(), ui_region_contains_point_px(), UI_RETURN_CANCEL, UI_SELECT, wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WINDEACTIVATE, WM_event_add_timer(), WM_EVENT_CURSOR_MOTION_THRESHOLD, WM_event_remove_timer(), WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, and wmEvent::y.
Referenced by ui_handle_menu_button(), ui_handler_region_menu(), and ui_region_handler().
Definition at line 8577 of file interface_handlers.c.
References uiBut::active, wmEvent::alt, uiBut::block, button_activate_init(), BUTTON_ACTIVATE_OVER, C, EVT_BUT_OPEN, MOUSEMOVE, uiHandleButtonData::tooltip_force, wmEvent::type, ui_but_find_mouse_over(), ui_but_find_open_event(), ui_do_button(), and WM_UI_HANDLER_CONTINUE.
Referenced by ui_handle_menu_button(), and ui_region_handler().
|
static |
Definition at line 9159 of file interface_handlers.c.
References uiBut::active, uiBut::block, button_activate_exit(), button_activate_state(), BUTTON_STATE_HIGHLIGHT, C, copy_v3_v3(), data, ISKEYBOARD, uiPopupBlockHandle::menuretval, MOUSEMOVE, uiPopupBlockHandle::retvalue, uiPopupBlockHandle::retvec, uiBut::type, wmEvent::type, ui_apply_but(), UI_BTYPE_COLOR, UI_BTYPE_MENU, ui_but_contains_point_px(), ui_but_update(), UI_RETURN_CANCEL, UI_RETURN_OK, UI_RETURN_OUT, UI_RETURN_UPDATE, uiHandleButtonData::used_mouse, wmEvent::x, and wmEvent::y.
Referenced by ui_handle_menu_return_submenu(), and ui_handler_region_menu().
|
static |
Definition at line 9023 of file interface_handlers.c.
References uiBut::block, C, CLAMP, wmEvent::ctrl, uiBut::custom_data, uiList::dyn_data, ED_region_tag_redraw(), ED_region_tag_refresh_ui(), ELEM, EVT_DOWNARROWKEY, EVT_UPARROWKEY, uiList::filter_flag, uiList::filter_sort_flag, uiList::flag, uiListDyn::height, wmEvent::is_direction_inverted, IS_EVENT_MOD, uiListDyn::items_filter_flags, uiListDyn::items_filter_neworder, uiListDyn::items_len, uiListDyn::items_shown, KM_PRESS, len, uiList::list_grip, uiList::list_scroll, max, MEM_freeN, MEM_mallocN, min, MOUSEPAN, RNA_property_int_get(), RNA_property_int_range(), RNA_property_int_set(), RNA_property_update(), uiBut::rnapoin, uiBut::rnaprop, wmEvent::shift, type, ui_apply_but_undo(), UI_LIST_AUTO_SIZE_THRESHOLD, ui_pan_to_scroll(), ui_window_to_block(), UILST_FLT_EXCLUDE, UILST_FLT_ITEM, UILST_FLT_SORT_REVERSE, UILST_SCROLL_TO_ACTIVE_ITEM, uiListDyn::visual_height, uiListDyn::visual_height_min, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_handle_menus_recursive(), and ui_region_handler().
|
static |
Definition at line 9515 of file interface_handlers.c.
References uiBut::active, uiBut::block, C, uiPopupBlockHandle::ctx_area, uiPopupBlockHandle::ctx_region, CTX_wm_area(), CTX_wm_area_set(), CTX_wm_region(), CTX_wm_region_set(), ELEM, ISMOUSE, KM_RELEASE, MOUSEMOVE, MOUSEPAN, NULL, uiHandleButtonData::region, uiPopupBlockHandle::region, uiBut::type, wmEvent::type, ui_block_is_menu(), ui_block_is_pie_menu(), UI_BTYPE_SEARCH_MENU, ui_but_contains_point_px(), ui_handle_button_event(), ui_handle_button_over(), ui_region_auto_open_clear(), ui_region_contains_point_px(), ui_region_find_active_but(), wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, wmEvent::x, and wmEvent::y.
Referenced by ui_handle_menu_event(), ui_handle_menus_recursive(), and ui_pie_handler().
|
static |
Definition at line 9600 of file interface_handlers.c.
References activate(), uiBut::active, add_v2_v2v2_int(), wmEvent::alt, uiPopupBlockCreate::arg, ATTR_FALLTHROUGH, BLI_rctf_isect_pt(), uiBlock::block_event_func, BUTTON_ACTIVATE, BUTTON_ACTIVATE_APPLY, button_activate_exit(), BUTTON_ACTIVATE_OPEN, button_modal_state(), uiBlock::buttons, C, uiHandleButtonData::cancel, copy_v2_v2_int(), count, CTX_wm_manager(), CTX_wm_window(), wmEvent::customdata, PointerRNA::data, uiBlock::direction, uiPopupBlockHandle::dotowards, ELEM, uiPopupBlockCreate::event_xy, EVT_AKEY, EVT_BKEY, EVT_CKEY, EVT_DKEY, EVT_DOWNARROWKEY, EVT_EIGHTKEY, EVT_EKEY, EVT_ENDKEY, EVT_ESCKEY, EVT_FIVEKEY, EVT_FKEY, EVT_FOURKEY, EVT_GKEY, EVT_HKEY, EVT_HOMEKEY, EVT_IKEY, EVT_JKEY, EVT_KKEY, EVT_LEFTARROWKEY, EVT_LKEY, EVT_MKEY, EVT_NINEKEY, EVT_NKEY, EVT_OKEY, EVT_ONEKEY, EVT_PAD0, EVT_PAD1, EVT_PAD2, EVT_PAD3, EVT_PAD4, EVT_PAD5, EVT_PAD6, EVT_PAD7, EVT_PAD8, EVT_PAD9, EVT_PADENTER, EVT_PAGEDOWNKEY, EVT_PAGEUPKEY, EVT_PKEY, EVT_QKEY, EVT_RETKEY, EVT_RIGHTARROWKEY, EVT_RKEY, EVT_SEVENKEY, EVT_SIXKEY, EVT_SKEY, EVT_THREEKEY, EVT_TKEY, EVT_TWOKEY, EVT_UKEY, EVT_UPARROWKEY, EVT_VKEY, EVT_WKEY, EVT_XKEY, EVT_YKEY, EVT_ZEROKEY, EVT_ZKEY, ListBase::first, uiBut::flag, uiBlock::flag, uiPopupBlockHandle::grab_xy_prev, IS_EVENT_MOD, uiPopupBlockHandle::is_grab, wmEvent::is_repeat, uiPopupBlockHandle::keynav_state, KM_CLICK, KM_DBL_CLICK, KM_PRESS, KM_RELEASE, LEFTMOUSE, uiBut::menu_key, MENU_SCROLL_BOTTOM, MENU_SCROLL_DOWN, MENU_SCROLL_INTERVAL, MENU_SCROLL_TOP, MENU_SCROLL_UP, uiPopupBlockHandle::menuretval, MIDDLEMOUSE, MOUSEMOVE, MOUSEPAN, uiBut::next, uiSafetyRct::next, NULL, uiSafetyRct::parent, uiPopupBlockHandle::popup_create_vars, PROP_LAYER, PROP_LAYER_MEMBER, uiBlock::rect, uiPopupBlockHandle::region, RIGHTMOUSE, RNA_property_subtype(), uiBut::rnaindex, uiBut::rnapoin, uiBut::rnaprop, uiBlock::saferct, uiSafetyRct::safety, uiPopupBlockHandle::scrolltimer, uiHandleButtonData::state, sub_v2_v2v2_int(), TIMER, uiBut::type, type, wmEvent::type, UI_BLOCK_CLIPBOTTOM, UI_BLOCK_CLIPTOP, UI_BLOCK_IS_FLIP, ui_block_is_menu(), UI_BLOCK_LOOP, UI_BLOCK_MOVEMOUSE_QUIT, UI_BLOCK_NUMSELECT, UI_BLOCK_OUT_1, UI_BLOCK_POPOVER, UI_BLOCK_POPOVER_ONCE, UI_BLOCK_POPUP_HOLD, UI_BTYPE_BLOCK, UI_BTYPE_BUT, UI_BTYPE_BUT_MENU, UI_BTYPE_IMAGE, UI_BTYPE_LABEL, UI_BTYPE_MENU, UI_BTYPE_PULLDOWN, UI_BTYPE_SEPR, UI_BTYPE_SEPR_LINE, UI_BUT_ACTIVE_DEFAULT, ui_but_contains_point_px(), UI_BUT_DISABLED, UI_but_execute(), ui_but_first(), ui_but_last(), ui_but_next(), ui_but_prev(), UI_but_tooltip_timer_remove(), UI_DIR_UP, ui_handle_button_activate(), ui_handle_button_activate_by_type(), ui_handle_menu_button(), UI_HIDDEN, ui_menu_pass_event_to_parent_if_nonactive(), ui_menu_scroll_apply_offset_y(), ui_menu_scroll_step(), ui_menu_scroll_test(), ui_menu_scroll_to_but(), ui_menu_scroll_to_y(), ui_mouse_motion_keynav_init(), ui_mouse_motion_keynav_test(), ui_mouse_motion_towards_check(), ui_mouse_motion_towards_init(), ui_mouse_motion_towards_reinit(), ui_pan_to_scroll(), UI_popover_once_clear(), ui_popup_translate(), ui_region_find_active_but(), ui_region_find_first_but_test_flag(), UI_RETURN_CANCEL, UI_RETURN_OK, UI_RETURN_OUT, UI_RETURN_OUT_PARENT, UI_RETURN_POPUP_OK, UI_RETURN_UPDATE, UI_UNIT_Y, ui_window_to_block(), ARegion::uiblocks, USER_MENUOPENAUTO, wmEvent::val, WHEELDOWNMOUSE, WHEELUPMOUSE, WM_event_add_mousemove(), WM_event_add_timer(), WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, wmEvent::y, and rctf::ymax.
Referenced by ui_handle_menus_recursive().
|
static |
Definition at line 10227 of file interface_handlers.c.
References uiBut::active, BLI_assert, uiPopupBlockHandle::butretval, C, data, ListBase::first, uiBlock::flag, uiPopupBlockHandle::menuretval, uiPopupBlockHandle::region, UI_BLOCK_KEEP_OPEN, UI_BLOCK_MOVEMOUSE_QUIT, UI_BLOCK_POPOVER, ui_handle_button_return_submenu(), ui_mouse_motion_towards_reinit(), ui_region_find_active_but(), UI_RETURN_CANCEL, UI_RETURN_OK, UI_RETURN_UPDATE, ARegion::uiblocks, update(), WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, and wmEvent::x.
Referenced by ui_handle_menus_recursive().
|
static |
Definition at line 10603 of file interface_handlers.c.
References uiBut::active, BLI_rctf_isect_pt(), C, data, PieMenuData::event_type, ListBase::first, uiBlock::flag, KM_DBL_CLICK, LEFTMOUSE, NULL, uiBlock::pie_data, uiBlock::rect, uiPopupBlockHandle::region, TIMER, uiBut::type, wmEvent::type, ui_block_is_menu(), UI_BLOCK_MOVEMOUSE_QUIT, UI_BLOCK_POPOVER, UI_BLOCK_RADIAL, UI_BTYPE_SEARCH_MENU, ui_handle_list_event(), ui_handle_menu_button(), ui_handle_menu_event(), ui_handle_menu_return_submenu(), ui_list_find_mouse_over(), ui_mouse_motion_towards_reinit(), ui_pie_handler(), ui_region_find_active_but(), UI_RETURN_OUT_PARENT, ui_window_to_block(), ARegion::uiblocks, wmEvent::val, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, and wmEvent::x.
Referenced by ui_handler_region_menu(), and ui_popup_handler().
|
static |
Definition at line 1577 of file interface_handlers.c.
References C, CTX_wm_region(), CTX_wm_window(), KM_RELEASE, LEFTMOUSE, wmWindow::modalhandlers, MOUSEMOVE, wmEvent::type, ui_apply_but_undo(), ui_but_find_mouse_over_ex(), ui_drag_toggle_set(), ui_handler_region_drag_toggle_remove(), wmEvent::val, WM_event_add_mousemove(), WM_event_remove_ui_handler(), WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, and uiDragToggleHandle::xy_init.
Referenced by ui_but_drag_init(), and ui_popup_handler().
|
static |
Definition at line 1571 of file interface_handlers.c.
References MEM_freeN.
Referenced by ui_but_drag_init(), ui_handler_region_drag_toggle(), and ui_popup_handler().
|
static |
Definition at line 10792 of file interface_handlers.c.
References uiBut::active, BLI_rctf_isect_rect_x(), BLI_rctf_isect_rect_y(), BUTTON_ACTIVATE_OVER, button_activate_state(), BUTTON_STATE_MENU_OPEN, C, CTX_wm_menu(), CTX_wm_menu_set(), CTX_wm_region(), CTX_wm_screen(), data, ELEM, uiBut::flag, KM_DBL_CLICK, uiHandleButtonData::menu, MOUSEMOVE, NULL, wmEvent::prevx, wmEvent::prevy, uiBut::rect, uiPopupBlockHandle::region, TIMER, uiBut::type, wmEvent::type, ui_apply_but_funcs_after(), ui_blocks_set_tooltips(), UI_BTYPE_MENU, UI_BTYPE_POPOVER, UI_BTYPE_PULLDOWN, UI_BUT_DISABLED, ui_but_find_mouse_over(), UI_DIR_DOWN, UI_DIR_LEFT, UI_DIR_RIGHT, UI_DIR_UP, ui_handle_button_activate(), ui_handle_button_event(), ui_handle_button_return_submenu(), ui_handle_menus_recursive(), ui_region_find_active_but(), ui_screen_region_find_mouse_over(), wmEvent::val, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, and wmEvent::y.
Referenced by button_activate_state().
|
static |
Special function to handle nested menus. let the parent menu get the event.
This allows a menu to be open, but send key events to the parent if there's no active buttons.
Without this keyboard navigation from menu's wont work.
Definition at line 9501 of file interface_handlers.c.
References BLI_assert, uiPopupBlockHandle::menuretval, NULL, UI_RETURN_OUT, UI_RETURN_OUT_PARENT, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_handle_menu_event().
Definition at line 9375 of file interface_handlers.c.
References BLI_assert, uiBlock::buttons, ED_region_tag_redraw(), uiBlock::handle, LISTBASE_FOREACH, max_ff(), min_ff(), uiBlock::rect, uiPopupBlockHandle::scrolloffset, ui_block_is_menu(), UI_MENU_SCROLL_PAD, ui_popup_block_scrolltest(), UI_UNIT_Y, rctf::ymax, and rctf::ymin.
Referenced by ui_handle_menu_event(), ui_menu_scroll_to_but(), and ui_menu_scroll_to_y().
Definition at line 9456 of file interface_handlers.c.
References BLI_assert, uiBlock::flag, uiBlock::rect, UI_BLOCK_CLIPBOTTOM, UI_BLOCK_CLIPTOP, ui_menu_scroll_to_y(), UI_UNIT_Y, rctf::ymax, and rctf::ymin.
Referenced by ui_handle_menu_event().
|
static |
Definition at line 9358 of file interface_handlers.c.
References uiBlock::flag, uiBlock::rect, UI_BLOCK_CLIPBOTTOM, UI_BLOCK_CLIPTOP, UI_MENU_SCROLL_MOUSE, and rctf::ymax.
Referenced by ui_handle_menu_event(), and ui_menu_scroll_to_y().
Scroll to activated button.
Definition at line 9418 of file interface_handlers.c.
References uiBlock::flag, uiBut::rect, uiBlock::rect, UI_BLOCK_CLIPBOTTOM, UI_BLOCK_CLIPTOP, ui_menu_scroll_apply_offset_y(), UI_MENU_SCROLL_ARROW, rctf::ymax, and rctf::ymin.
Referenced by ui_handle_menu_event().
Scroll to y location (in block space, see ui_window_to_block).
Definition at line 9439 of file interface_handlers.c.
References ui_menu_scroll_apply_offset_y(), ui_menu_scroll_test(), UI_UNIT_Y, and y.
Referenced by ui_handle_menu_event(), and ui_menu_scroll_step().
|
static |
Definition at line 9332 of file interface_handlers.c.
References copy_v2_v2_int(), uiKeyNavLock::event_xy, uiKeyNavLock::is_keynav, and wmEvent::x.
Referenced by ui_do_but_textedit(), and ui_handle_menu_event().
|
static |
Return true if key-input isn't blocking mouse-motion, or if the mouse-motion is enough to disable key-input.
Definition at line 9341 of file interface_handlers.c.
References BUTTON_KEYNAV_PX_LIMIT, uiKeyNavLock::event_xy, uiKeyNavLock::is_keynav, len_manhattan_v2v2_int(), and wmEvent::x.
Referenced by ui_do_but_textedit(), and ui_handle_menu_event().
|
static |
Definition at line 9259 of file interface_handlers.c.
References add_v2_v2(), BLI_assert, BLI_rctf_cent_x(), BLI_rctf_cent_y(), BUTTON_MOUSE_TOWARDS_THRESH, uiPopupBlockHandle::dotowards, ListBase::first, uiBlock::flag, isect_point_tri_v2(), len_squared_v2v2(), MENU_TOWARDS_MARGIN, MENU_TOWARDS_WIGGLE_ROOM, ARegion::next, normalize_v2_length(), PIL_check_seconds_timer(), uiBlock::rect, uiPopupBlockHandle::region, sub_v2_v2v2(), uiPopupBlockHandle::towards_xy, uiPopupBlockHandle::towardstime, ui_block_is_menu(), UI_BLOCK_MOVEMOUSE_QUIT, UI_BLOCK_POPOVER, ui_block_to_window_rctf(), ARegion::uiblocks, rctf::xmax, rctf::xmin, rctf::ymax, and rctf::ymin.
Referenced by ui_handle_menu_event().
|
static |
Definition at line 9249 of file interface_handlers.c.
References ui_mouse_motion_towards_init_ex().
Referenced by ui_handle_menu_event().
|
static |
Function used to prevent losing the open menu when using nested pull-downs, when moving mouse towards the pull-down menu over other buttons that could steal the highlight from the current button, only checks:
Definition at line 9228 of file interface_handlers.c.
References BLI_assert, uiPopupBlockHandle::dotowards, ListBase::first, PIL_check_seconds_timer(), uiPopupBlockHandle::region, uiPopupBlockHandle::towards_xy, uiPopupBlockHandle::towardstime, UI_BLOCK_MOVEMOUSE_QUIT, UI_BLOCK_POPOVER, and ARegion::uiblocks.
Referenced by ui_mouse_motion_towards_init(), and ui_mouse_motion_towards_reinit().
|
static |
Definition at line 9254 of file interface_handlers.c.
References ui_mouse_motion_towards_init_ex().
Referenced by ui_handle_menu_event(), ui_handle_menu_return_submenu(), and ui_handle_menus_recursive().
|
static |
Definition at line 577 of file interface_handlers.c.
References data, and ui_mouse_scale_warp_factor().
Referenced by ui_numedit_but_HSVCIRCLE(), ui_numedit_but_HSVCUBE(), and ui_numedit_but_SLI().
|
static |
Definition at line 572 of file interface_handlers.c.
Referenced by ui_mouse_scale_warp(), ui_numedit_but_CURVE(), and ui_numedit_but_CURVEPROFILE().
|
static |
Definition at line 1176 of file interface_handlers.c.
References BLI_assert, BLI_linklist_prepend(), uiButMultiState::but, data, uiBut::flag, uiSelectContextStore::is_copy, MEM_callocN, uiButMultiState::origvalue, uiButMultiState::select_others, UI_BUT_DRAG_MULTI, ui_but_value_get(), and UI_butstore_register().
Referenced by ui_multibut_states_create().
|
static |
Definition at line 1227 of file interface_handlers.c.
References BLI_linklist_freeN(), data, uiSelectContextStore::elems, LinkNode::link, MEM_freeN, LinkNode::next, next, NULL, uiButMultiState::select_others, and UI_butstore_free().
Referenced by button_activate_exit().
|
static |
Definition at line 1193 of file interface_handlers.c.
References uiButMultiState::but, data, l, BMLoop::next, and NULL.
Referenced by ui_multibut_restore(), and ui_multibut_states_apply().
|
static |
Definition at line 1206 of file interface_handlers.c.
References uiBlock::buttons, C, data, uiSelectContextStore::elems_len, LISTBASE_FOREACH, uiButMultiState::origvalue, uiButMultiState::select_others, UI_BUT_DRAG_MULTI, ui_but_value_set(), ui_multibut_lookup(), ui_selectcontext_apply(), and UNUSED_VARS.
Referenced by ui_apply_but().
|
static |
Definition at line 1337 of file interface_handlers.c.
References BLI_assert, uiBlock::buttons, C, CLAMP, data, uiSelectContextStore::do_free, uiSelectContextStore::elems_len, LISTBASE_FOREACH, NULL, uiButMultiState::origvalue, uiButMultiState::select_others, UI_BUT_DRAG_MULTI, ui_but_execute_begin(), ui_but_execute_end(), ui_but_string_set(), ui_multibut_lookup(), and ui_selectcontext_begin().
Referenced by ui_apply_but(), ui_do_but_NUM(), and ui_do_but_SLI().
|
static |
Definition at line 1313 of file interface_handlers.c.
References BLI_assert, uiBut::block, uiBlock::buttons, data, ELEM, LISTBASE_FOREACH, PROP_PROPORTIONAL, PROP_UNIT_LENGTH, RNA_property_flag(), RNA_SUBTYPE_UNIT_VALUE, uiBut::rnaprop, UI_BUT_DRAG_MULTI, UI_butstore_create(), ui_multibut_add(), and uiBut::unit_type.
Referenced by ui_do_button().
|
static |
Definition at line 1257 of file interface_handlers.c.
References BLI_assert, BLI_rctf_isect_segment(), uiBut::block, uiBlock::buttons, data, LISTBASE_FOREACH, NULL, UI_BUT_DRAG_MULTI, ui_but_is_compatible(), ui_but_is_interactive(), and ui_window_to_block_fl().
Referenced by ui_do_button().
|
static |
Definition at line 4016 of file interface_handlers.c.
References C, data, ED_region_tag_redraw(), ui_apply_but(), and ui_but_update().
Referenced by ui_do_but_COLORBAND(), ui_do_but_CURVEPROFILE(), ui_do_but_GRIP(), ui_do_but_HISTOGRAM(), ui_do_but_HSVCIRCLE(), ui_do_but_HSVCUBE(), ui_do_but_NUM(), ui_do_but_SCROLL(), ui_do_but_SLI(), ui_do_but_TRACKPREVIEW(), ui_do_but_UNITVEC(), and ui_do_but_WAVEFORM().
|
static |
Definition at line 4771 of file interface_handlers.c.
References ELEM, snap(), SNAP_OFF, SNAP_ON, and SNAP_ON_SMALL.
Referenced by ui_numedit_but_NUM().
|
static |
Definition at line 4693 of file interface_handlers.c.
References B_UNIT_AREA, B_UNIT_LENGTH, B_UNIT_VOLUME, BKE_unit_base_scalar(), BKE_unit_is_valid(), BLI_assert, uiBut::block, ELEM, float(), PROP_UNIT_ROTATION, RNA_SUBTYPE_UNIT_VALUE, UnitSettings::scale_length, snap(), SNAP_OFF, SNAP_ON, SNAP_ON_SMALL, UnitSettings::system, UnitSettings::system_rotation, ui_but_is_unit(), UI_but_unit_type_get(), uiBlock::unit, and USER_UNIT_ROT_RADIANS.
Referenced by ui_numedit_but_NUM().
|
static |
Definition at line 3900 of file interface_handlers.c.
References copy_v3_v3(), data, double(), uiButColorBand::edit_coba, uiButCurveMapping::edit_cumap, uiButCurveProfile::edit_profile, uiBut::editval, uiBut::editvec, ELEM, CCL_NAMESPACE_BEGIN::isfinite(), min_ff(), uiBut::poin, uiBut::softmax, uiBut::softmin, uiButNumber::step_size, uiBut::type, UI_BTYPE_COLOR, UI_BTYPE_COLORBAND, UI_BTYPE_CURVE, UI_BTYPE_CURVEPROFILE, UI_BTYPE_HSVCIRCLE, UI_BTYPE_HSVCUBE, UI_BTYPE_NUM, UI_BTYPE_UNITVEC, ui_but_is_cursor_warp(), ui_but_is_float(), ui_but_v3_get(), UI_DPI_FAC, UI_DRAG_MAP_SOFT_RANGE_PIXEL_MAX, ui_numedit_begin_set_values(), UI_PRECISION_FLOAT_SCALE, and UNLIKELY.
Referenced by button_activate_state().
|
static |
Definition at line 3893 of file interface_handlers.c.
References data, and ui_but_value_get().
Referenced by ui_numedit_begin().
|
static |
Definition at line 6674 of file interface_handlers.c.
References BKE_colorband_update_sort(), BLI_rctf_size_x(), CLAMP, data, float(), and uiBut::rect.
Referenced by ui_do_but_COLORBAND().
|
static |
Definition at line 6775 of file interface_handlers.c.
References Freestyle::a, BKE_curvemapping_changed(), BLI_rctf_clamp_pt_v(), BLI_rctf_size_x(), BLI_rctf_size_y(), CurveMapping::clipr, CurveMapping::cm, CUMA_DO_CLIP, CUMA_SELECT, CurveMapping::cur, CurveMapping::curr, data, CurveMapping::flag, len_squared_v2(), NULL, uiBut::poin, uiBut::rect, snap(), ui_but_is_cursor_warp(), ui_mouse_scale_warp_factor(), ui_window_to_block(), x, CurveMapPoint::x, rctf::xmax, rctf::xmin, y, CurveMapPoint::y, rctf::ymax, and rctf::ymin.
|
static |
Definition at line 7044 of file interface_handlers.c.
References Freestyle::a, BKE_curveprofile_move_handle(), BKE_curveprofile_move_point(), BKE_curveprofile_update(), BLI_rctf_clamp_pt_v(), BLI_rctf_size_x(), BLI_rctf_size_y(), CurveProfile::clip_rect, data, ELEM, CurveProfile::flag, HD_ALIGN, HD_FREE, len_squared_v2(), CurveProfile::path, CurveProfile::path_len, uiBut::poin, PROF_H1_SELECT, PROF_H2_SELECT, PROF_SELECT, PROF_UPDATE_NONE, PROF_USE_CLIP, uiBut::rect, snap(), ui_but_is_cursor_warp(), ui_mouse_scale_warp_factor(), ui_window_to_block(), CurveProfile::view_rect, rctf::xmax, rctf::xmin, rctf::ymax, and rctf::ymin.
Referenced by ui_do_but_CURVEPROFILE().
|
static |
Definition at line 7340 of file interface_handlers.c.
References CLAMP, data, min_ff(), uiBut::poin, pow2f(), and Histogram::ymax.
Referenced by ui_do_but_HISTOGRAM().
|
static |
Definition at line 6390 of file interface_handlers.c.
References BLI_rctf_cent_x(), BLI_rctf_cent_y(), BLI_rctf_size_x(), BLI_rctf_size_y(), BLI_rcti_rctf_copy(), copy_v3_v3(), uiBut::custom_data, data, dist_ensure_v2_v2fl(), ColorPicker::hsv_perceptual, is_zero_v3(), len, len_v2v2(), ColorPicker::luminosity_lock_value, min_ff(), normalize_v3_length(), uiBut::rect, snap(), SNAP_OFF, sqrt3f(), ui_but_is_cursor_warp(), ui_but_v3_get(), ui_but_v3_set(), ui_color_picker_hsv_to_rgb(), ui_color_picker_rgb_to_hsv_compat(), ui_color_snap_hue(), ui_hsvcircle_pos_from_vals(), ui_hsvcircle_vals_from_pos(), ui_mouse_scale_warp(), ui_perceptual_to_scene_linear_space(), ui_scene_linear_to_perceptual_space(), ColorPicker::use_color_cubic, ColorPicker::use_color_lock, ColorPicker::use_luminosity_lock, and USER_CP_CIRCLE_HSV.
Referenced by ui_do_but_HSVCIRCLE().
|
static |
Definition at line 6105 of file interface_handlers.c.
References BLI_assert, BLI_rctf_clamp_pt_v(), BLI_rctf_size_x(), BLI_rctf_size_y(), BLI_rcti_rctf_copy(), CLAMP, clamp_axis_max_v3(), copy_v3_v3(), uiBut::custom_data, data, ELEM, float(), uiButHSVCube::gradient_type, ColorPicker::hsv_perceptual, max, min, uiBut::rect, snap(), SNAP_OFF, uiBut::softmax, uiBut::softmin, ui_but_is_cursor_warp(), ui_but_v3_get(), ui_color_picker_to_rgb_HSVCUBE_v(), ui_color_snap_hue(), UI_GRAD_H, UI_GRAD_HS, UI_GRAD_HV, UI_GRAD_L_ALT, UI_GRAD_S, UI_GRAD_SV, UI_GRAD_V, UI_GRAD_V_ALT, ui_hsvcube_pos_from_vals(), ui_mouse_scale_warp(), ui_perceptual_to_scene_linear_space(), ui_rgb_to_color_picker_HSVCUBE_compat_v(), ui_scene_linear_to_perceptual_space(), x, rctf::xmin, y, and rctf::ymin.
Referenced by ui_do_but_HSVCUBE().
|
static |
Definition at line 4794 of file interface_handlers.c.
References abs(), uiButNumber::but, CLAMP, CLAMP_MAX, CLAMP_MIN, data, double(), float(), if(), powf, round_fl_to_int(), snap(), uiBut::softmax, uiBut::softmin, uiButNumber::step_size, ui_but_dragedit_update_mval(), ui_but_is_cursor_warp(), ui_but_is_float(), UI_DPI_FAC, ui_numedit_apply_snap(), and ui_numedit_apply_snapf().
Referenced by ui_do_but_NUM().
|
static |
Definition at line 5216 of file interface_handlers.c.
References uiBut::a1, BLI_rctf_cent_x(), BLI_rctf_cent_y(), BLI_rctf_clamp_pt_v(), BLI_rctf_size_x(), BLI_rctf_size_y(), CLAMP, data, ELEM, uiBut::rect, round_fl_to_int(), size(), snap(), uiBut::softmax, uiBut::softmin, uiBut::type, UI_BTYPE_NUM_SLIDER, UI_BTYPE_SCROLL, ui_but_dragedit_update_mval(), ui_but_is_cursor_warp(), ui_but_is_float(), ui_mouse_scale_warp(), rctf::xmin, and rctf::ymin.
Referenced by ui_do_but_SCROLL(), and ui_do_but_SLI().
|
static |
Definition at line 7487 of file interface_handlers.c.
References BKE_movieclip_remap_scene_to_clip_frame(), BKE_tracking_marker_ensure(), BLI_rctf_size_x(), BLI_rctf_size_y(), uiBut::block, C, CTX_data_edit_movieclip(), data, MovieTrackingMarker::flag, MovieTrackingMarker::framenr, if(), MovieClipScopes::marker, MARKER_DISABLED, MARKER_TRACKED, NA_EDITED, NC_MOVIECLIP, NULL, MovieClipScopes::ok, uiBut::poin, MovieTrackingMarker::pos, uiBlock::rect, MovieClipScopes::scene_framenr, MovieClipScopes::slide_scale, MovieClipScopes::track, MovieClipScopes::track_locked, and WM_event_add_notifier().
Referenced by ui_do_but_TRACKPREVIEW().
|
static |
Definition at line 5764 of file interface_handlers.c.
References angle(), asinf, BLI_rctf_size_x(), compare_v3v3(), data, float(), M_PI, normalize_v3(), uiBut::rect, sinf, snap(), SNAP_OFF, SNAP_ON, and sqrtf.
Referenced by ui_do_but_UNITVEC().
|
static |
Definition at line 7414 of file interface_handlers.c.
References CLAMP, data, uiBut::poin, and Scopes::wavefrm_yfac.
Referenced by ui_do_but_WAVEFORM().
|
static |
Definition at line 3993 of file interface_handlers.c.
References data, uiButColorBand::edit_coba, uiButCurveMapping::edit_cumap, uiButCurveProfile::edit_profile, uiBut::editval, uiBut::editvec, NULL, uiBut::type, UI_BTYPE_COLORBAND, UI_BTYPE_CURVE, and UI_BTYPE_CURVEPROFILE.
Referenced by button_activate_state().
|
static |
Definition at line 4971 of file interface_handlers.c.
References uiBut::active, BLI_rctf_size_x(), BLI_rctf_size_y(), uiBut::block, data, uiBut::drawflag, ED_region_tag_redraw(), uiBut::flag, min_ff(), uiBut::rect, UI_BUT_ACTIVE_LEFT, UI_BUT_ACTIVE_RIGHT, UI_SELECT, ui_window_to_block(), WM_cursor_modal_restore(), WM_cursor_modal_set(), WM_CURSOR_X_MOVE, rctf::xmax, and rctf::xmin.
Referenced by button_activate_init(), and ui_do_but_NUM().
|
static |
Definition at line 5843 of file interface_handlers.c.
References Palette::active_color, BLI_findindex(), uiButColor::but, Palette::colors, PointerRNA::data, uiButColor::is_pallete_color, PointerRNA::owner_id, and uiBut::rnapoin.
Referenced by ui_do_but_COLOR().
| void ui_pan_to_scroll | ( | const wmEvent * | event, |
| int * | type, | ||
| int * | val | ||
| ) |
Definition at line 506 of file interface_handlers.c.
References abs(), BLI_assert, KM_PRESS, MOUSEPAN, type, UI_UNIT_Y, WHEELDOWNMOUSE, WHEELUPMOUSE, and WM_event_absolute_delta_y().
Referenced by ui_do_but_BLOCK(), ui_do_but_NUM(), ui_do_but_SLI(), ui_do_but_TOG(), ui_handle_list_event(), ui_handle_menu_event(), and ui_searchbox_event().
|
static |
Definition at line 10347 of file interface_handlers.c.
References uiBut::active, add_v2_v2(), PieMenuData::alphafac, ATTR_FALLTHROUGH, BLI_rctf_recenter(), BLI_rctf_size_x(), BLI_rctf_size_y(), button_modal_state(), uiBlock::buttons, C, CASE_NUM_TO_DIR, center, copy_v2_v2(), CTX_wm_manager(), CTX_wm_window(), wmEvent::customdata, wmTimer::duration, PieMenuData::duration_gesture, ED_region_tag_redraw(), PieMenuData::event_type, EVT_AKEY, EVT_BKEY, EVT_CKEY, EVT_DKEY, EVT_DROP, EVT_EKEY, EVT_ESCKEY, EVT_FKEY, EVT_GKEY, EVT_HKEY, EVT_IKEY, EVT_JKEY, EVT_KKEY, EVT_LKEY, EVT_MKEY, EVT_NKEY, EVT_OKEY, EVT_PKEY, EVT_QKEY, EVT_RKEY, EVT_SKEY, EVT_TKEY, EVT_UKEY, EVT_VKEY, EVT_WKEY, EVT_XKEY, EVT_YKEY, EVT_ZKEY, ListBase::first, PieMenuData::flags, IS_EVENT_MOD, KM_DBL_CLICK, KM_PRESS, KM_RELEASE, PieMenuData::last_pos, LEFTMOUSE, len_squared_v2v2(), LISTBASE_FOREACH, uiBut::menu_key, uiPopupBlockHandle::menuretval, MOUSEMOVE, mul_v2_fl(), NULL, PieMenuData::pie_center_init, PieMenuData::pie_center_spawned, PIE_CLICK_THRESHOLD_SQ, uiBlock::pie_data, uiBut::pie_dir, PIE_MENU_INTERVAL, uiBut::rect, uiPopupBlockHandle::region, RIGHTMOUSE, uiPopupBlockHandle::scrolltimer, uiHandleButtonData::state, TIMER, wmEvent::type, ui_block_calc_pie_segment(), ui_block_pie_dir_activate(), ui_but_pie_button_activate(), ui_but_pie_dir(), ui_but_pie_menu_apply(), UI_DPI_FAC, ui_handle_menu_button(), UI_PIE_ANIMATION_FINISHED, UI_PIE_CLICK_STYLE, UI_PIE_DRAG_STYLE, UI_PIE_GESTURE_END_WAIT, UI_PIE_INITIAL_DIRECTION, UI_PIE_INVALID_DIR, UI_RADIAL_E, UI_RADIAL_N, UI_RADIAL_NE, UI_RADIAL_NONE, UI_RADIAL_NW, UI_RADIAL_S, UI_RADIAL_SE, UI_RADIAL_SW, UI_RADIAL_W, ui_region_find_active_but(), UI_RETURN_CANCEL, ui_window_to_block_fl(), ARegion::uiblocks, wmEvent::val, WM_event_add_timer(), WM_UI_HANDLER_BREAK, and WM_UI_HANDLER_CONTINUE.
Referenced by ui_handle_menus_recursive().
Definition at line 10884 of file interface_handlers.c.
References C, uiPopupBlockHandle::cancel_func, CTX_wm_menu(), CTX_wm_menu_set(), CTX_wm_region_set(), CTX_wm_window(), EVENT_NONE, PieMenuData::event_type, EVT_DROP, ListBase::first, uiBlock::flag, KM_DBL_CLICK, uiPopupBlockHandle::menuretval, wmWindow::modalhandlers, MOUSEMOVE, NULL, uiBlock::pie_data, wmWindow::pie_event_type_last, uiPopupBlockHandle::popup_arg, uiPopupBlockHandle::popup_func, wmEvent::prevx, wmEvent::prevy, uiPopupBlockHandle::region, uiPopupBlockHandle::retvalue, wmEvent::type, ui_apply_but_funcs_after(), UI_BLOCK_RADIAL, ui_blocks_set_tooltips(), ui_handle_menus_recursive(), ui_handler_region_drag_toggle(), ui_handler_region_drag_toggle_remove(), ui_popup_block_free(), UI_popup_handlers_remove(), UI_RETURN_OK, UI_RETURN_POPUP_OK, ARegion::uiblocks, wmEvent::val, WM_event_add_mousemove(), WM_event_free_ui_handler_all(), WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, and wmEvent::y.
Referenced by UI_popup_handlers_add(), UI_popup_handlers_remove(), and UI_popup_handlers_remove_all().
|
static |
Definition at line 10971 of file interface_handlers.c.
References C, uiPopupBlockHandle::cancel_func, uiPopupBlockHandle::menuretval, uiPopupBlockHandle::popup_arg, ui_apply_but_funcs_after(), ui_popup_block_free(), and UI_RETURN_OK.
Referenced by UI_popup_handlers_add(), UI_popup_handlers_remove(), and UI_popup_handlers_remove_all().
| void UI_popup_handlers_add | ( | bContext * | C, |
| ListBase * | handlers, | ||
| uiPopupBlockHandle * | popup, | ||
| const char | flag | ||
| ) |
Definition at line 10996 of file interface_handlers.c.
References C, ui_popup_handler(), ui_popup_handler_remove(), and WM_event_add_ui_handler().
Referenced by UI_pie_menu_end(), UI_popover_end(), ui_popover_panel_create(), UI_popup_block_ex(), UI_popup_block_invoke_ex(), ui_popup_menu_create(), and UI_popup_menu_end().
| void UI_popup_handlers_remove | ( | ListBase * | handlers, |
| uiPopupBlockHandle * | popup | ||
| ) |
Definition at line 11004 of file interface_handlers.c.
References ED_region_tag_refresh_ui(), wmEventHandler_UI::handle_fn, wmEventHandler_UI::head, if(), LISTBASE_FOREACH, wmEventHandler::next, uiPopupBlockHandle::region, wmEventHandler_UI::remove_fn, wmEventHandler::type, ui_popup_handler(), ui_popup_handler_remove(), wmEventHandler_UI::user_data, WM_event_remove_ui_handler(), and WM_HANDLER_TYPE_UI.
Referenced by UI_popup_block_close(), and ui_popup_handler().
Definition at line 11028 of file interface_handlers.c.
References C, ui_popup_handler(), ui_popup_handler_remove(), and WM_event_free_ui_handler_all().
Referenced by ghost_event_proc(), WM_event_add_fileselect(), and wm_event_do_notifiers().
| void UI_popup_menu_retval_set | ( | const uiBlock * | block, |
| const int | retval, | ||
| const bool | enable | ||
| ) |
Allow setting menu return value from externals. E.g. WM might need to do this for exiting files correctly.
Definition at line 10707 of file interface_handlers.c.
References uiBlock::handle, and uiPopupBlockHandle::menuretval.
Referenced by dialog_exec_cb().
Definition at line 8403 of file interface_handlers.c.
References NULL, and ui_context_button_active().
Referenced by ui_but_tooltip_init(), and UI_region_searchbox_region_get().
|
static |
Definition at line 9485 of file interface_handlers.c.
References LISTBASE_FOREACH, and ARegion::uiblocks.
Referenced by ui_handle_menu_button().
| uiBlock* UI_region_block_find_mouse_over | ( | const struct ARegion * | region, |
| const int | xy[2], | ||
| bool | only_clip | ||
| ) |
Definition at line 8413 of file interface_handlers.c.
References ui_block_find_mouse_over_ex().
Referenced by wm_handlers_do_gizmo_handler().
Definition at line 8408 of file interface_handlers.c.
References ui_but_find_rect_over().
Definition at line 10721 of file interface_handlers.c.
References BLI_listbase_is_empty(), C, CTX_wm_region(), MOUSEMOVE, NULL, wmEvent::prevx, wmEvent::prevy, wmEvent::type, ui_apply_but_funcs_after(), ui_blocks_set_tooltips(), UI_but_tooltip_timer_remove(), ui_handle_button_event(), ui_handle_button_over(), ui_handle_list_event(), ui_handler_panel_region(), ui_list_find_mouse_over(), ui_region_find_active_but(), ARegion::uiblocks, WM_UI_HANDLER_BREAK, WM_UI_HANDLER_CONTINUE, wmEvent::x, and wmEvent::y.
Referenced by UI_region_handlers_add().
|
static |
Definition at line 10768 of file interface_handlers.c.
References BLI_findindex(), C, CTX_wm_region(), CTX_wm_screen(), NULL, bScreen::regionbase, ui_apply_but_funcs_after(), UI_blocklist_free(), and ARegion::uiblocks.
Referenced by UI_region_handlers_add().
| void UI_region_handlers_add | ( | ListBase * | handlers | ) |
Definition at line 10990 of file interface_handlers.c.
References NULL, ui_region_handler(), ui_region_handler_remove(), WM_event_add_ui_handler(), and WM_event_remove_ui_handler().
Referenced by ed_default_handlers(), hud_region_init(), and ui_popup_block_create().
Try to find a search-box region opened from a button in button_region.
Definition at line 8504 of file interface_handlers.c.
References uiBut::active, NULL, uiHandleButtonData::searchbox, and UI_region_active_but_get().
|
static |
Definition at line 6069 of file interface_handlers.c.
References uiButHSVCube::gradient_type, rgb_to_hsl_compat_v(), rgb_to_hsv_compat_v(), and UI_GRAD_L_ALT.
Referenced by ui_do_but_HSVCUBE(), and ui_numedit_but_HSVCUBE().
|
static |
Definition at line 6081 of file interface_handlers.c.
References uiButHSVCube::gradient_type, rgb_to_hsl_v(), rgb_to_hsv_v(), and UI_GRAD_L_ALT.
Referenced by ui_do_but_HSVCUBE().
|
static |
Definition at line 622 of file interface_handlers.c.
References ELEM, NULL, PROP_NO_DEG_UPDATE, ptr, RNA_AddonPreferences, RNA_KeyConfigPreferences, RNA_KeyMapItem, RNA_property_flag(), RNA_struct_base(), RNA_UserAssetLibrary, and PointerRNA::type.
Referenced by UI_but_is_userdef(), and ui_rna_update_preferences_dirty().
|
static |
Definition at line 648 of file interface_handlers.c.
References NC_WINDOW, NULL, ptr, ui_rna_is_userdef(), and WM_main_add_notifier().
Referenced by ui_afterfunc_update_preferences_dirty(), and ui_but_update_preferences_dirty().
Definition at line 11099 of file interface_handlers.c.
References uiBut::active, blender::compositor::area(), BUTTON_STATE_HIGHLIGHT, C, CTX_wm_window(), data, ED_screen_areas_iter, LISTBASE_FOREACH, NULL, ui_but_active_free(), and ui_region_find_active_but().
|
static |
Definition at line 1759 of file interface_handlers.c.
References BLI_assert, C, CLAMP, CTX_wm_window(), ELEM, uiSelectContextStore::elems, uiSelectContextStore::elems_len, wmWindow::eventstate, uiBut::func, uiSelectContextStore::is_copy, len, max, MEM_callocN, MEM_freeN, min, NULL, PROP_BOOLEAN, PROP_ENUM, PROP_FLOAT, PROP_INT, PROP_LAYER, PROP_LAYER_MEMBER, PROP_POINTER, uiSelectContextElem::ptr, RNA_property_array_check(), RNA_property_array_length(), RNA_property_boolean_get(), RNA_property_boolean_get_index(), RNA_property_boolean_set(), RNA_property_boolean_set_array(), RNA_property_boolean_set_index(), RNA_property_enum_get(), RNA_property_enum_set(), RNA_property_float_range(), RNA_property_float_set(), RNA_property_float_set_index(), RNA_property_int_range(), RNA_property_int_set(), RNA_property_int_set_index(), RNA_property_pointer_get(), RNA_property_pointer_set(), RNA_property_subtype(), RNA_property_type(), RNA_property_update(), uiBut::rnaindex, uiBut::rnapoin, uiBut::rnaprop, wmEvent::shift, uiSelectContextElem::val_f, and uiSelectContextElem::val_i.
Referenced by ui_apply_but(), and ui_multibut_restore().
|
static |
Definition at line 1629 of file interface_handlers.c.
References BLI_freelistN(), BLI_listbase_count(), BLI_listbase_is_empty(), C, PointerRNA::data, uiSelectContextStore::do_free, uiSelectContextStore::elems, uiSelectContextStore::elems_len, uiBut::flag, LISTBASE_FOREACH_INDEX, MEM_mallocN, MEM_SAFE_FREE, NULL, PROP_BOOLEAN, PROP_ENUM, PROP_FLOAT, PROP_INT, uiSelectContextElem::ptr, ptr, RNA_id_pointer_create(), RNA_path_resolve_property(), RNA_property_array_check(), RNA_property_boolean_get(), RNA_property_boolean_get_index(), RNA_property_editable(), RNA_property_enum_get(), RNA_property_float_get(), RNA_property_float_get_index(), RNA_property_int_get(), RNA_property_int_get_index(), RNA_property_type(), uiBut::rnaindex, uiBut::rnapoin, uiBut::rnaprop, UI_BUT_IS_SELECT_CONTEXT, UI_context_copy_to_selected_list(), uiSelectContextElem::val_b, uiSelectContextElem::val_f, and uiSelectContextElem::val_i.
Referenced by ui_apply_but(), and ui_multibut_states_apply().
|
static |
Definition at line 1748 of file interface_handlers.c.
References uiSelectContextStore::do_free, uiSelectContextStore::elems, uiBut::flag, MEM_freeN, and UI_BUT_IS_SELECT_CONTEXT.
Referenced by button_activate_exit().
|
static |
Definition at line 2800 of file interface_handlers.c.
References BLI_str_find_next_char_utf8(), uiBut::drawstr, uiBut::editstr, NULL, and pos.
Referenced by ui_but_text_password_hide().
|
static |
Definition at line 2811 of file interface_handlers.c.
References BLI_strnlen_utf8(), uiBut::drawstr, uiBut::editstr, and pos.
Referenced by ui_but_text_password_hide().
Definition at line 11065 of file interface_handlers.c.
References C, CTX_wm_region(), LISTBASE_FOREACH, NULL, uiBut::type, UI_BTYPE_TEXT, UI_but_active_only(), and ARegion::uiblocks.
| bool UI_textbutton_activate_rna | ( | const bContext * | C, |
| ARegion * | region, | ||
| const void * | rna_poin_data, | ||
| const char * | rna_prop_id | ||
| ) |
Definition at line 11033 of file interface_handlers.c.
References C, PointerRNA::data, LISTBASE_FOREACH, NULL, RNA_property_identifier(), uiBut::rnapoin, uiBut::rnaprop, STREQ, uiBut::type, UI_BTYPE_TEXT, UI_but_active_only(), and ARegion::uiblocks.
|
static |
Definition at line 3193 of file interface_handlers.c.
References uiBut::autocomplete_func, uiBut::autofunc_arg, C, data, uiBut::pos, uiBut::selend, uiBut::selsta, str, and ui_searchbox_autocomplete().
Referenced by ui_do_but_textedit().
|
static |
Definition at line 3303 of file interface_handlers.c.
References BLI_assert, BLI_str_rstrip_float_zero(), BLI_strdupn(), uiBut::block, BLT_lang_is_ime_supported(), C, data, uiBut::editstr, ELEM, wmWindow::eventstate, uiBut::flag, IS_ALLSELECT_EVENT, len, MEM_callocN, MEM_freeN, NULL, uiButSearch::popup_create_fn, uiBut::pos, uiBut::selend, uiBut::selsta, uiBut::type, ui_apply_but(), UI_BTYPE_NUM, UI_BTYPE_NUM_SLIDER, UI_BTYPE_SEARCH_MENU, ui_but_anim_expression_get(), ui_but_convert_to_unit_alt_name(), ui_but_is_float(), ui_but_is_unit(), UI_BUT_REDALERT, ui_but_string_get_dynamic(), ui_but_string_get_ex(), ui_but_string_get_max_length(), ui_but_update(), UI_PRECISION_FLOAT_MAX, ui_searchbox_update(), ui_textedit_undo_push(), ui_textedit_undo_stack_create(), WM_cursor_modal_set(), and WM_CURSOR_TEXT_EDIT.
Referenced by button_activate_state().
|
static |
Definition at line 3218 of file interface_handlers.c.
References BLI_strncpy(), BLI_utf8_invalid_strip(), data, ELEM, MEM_freeN, MEM_mallocN, uiBut::selend, uiBut::selsta, UI_but_is_utf8(), UI_TEXTEDIT_COPY, UI_TEXTEDIT_CUT, ui_textedit_delete_selection(), ui_textedit_insert_buf(), UI_TEXTEDIT_PASTE, WM_clipboard_text_get_firstline(), and WM_clipboard_text_set().
Referenced by ui_do_but_textedit().
|
static |
Definition at line 3142 of file interface_handlers.c.
References BLI_str_cursor_step_utf8(), data, jump(), len, uiBut::pos, pos, uiBut::selend, uiBut::selsta, str, STRCUR_JUMP_ALL, and ui_textedit_delete_selection().
Referenced by ui_do_but_textedit().
|
static |
Definition at line 2903 of file interface_handlers.c.
References data, len, uiBut::pos, uiBut::selend, uiBut::selsta, and str.
Referenced by ui_do_but_textedit(), ui_textedit_copypaste(), ui_textedit_delete(), and ui_textedit_insert_buf().
|
static |
Definition at line 3397 of file interface_handlers.c.
References BLI_assert, BLI_utf8_invalid_strip(), C, data, uiBut::editstr, wmWindow::ime_data, NULL, uiBut::pos, uiButSearch::results_are_suggestions, RPT_ERROR, uiBut::type, UI_BTYPE_SEARCH_MENU, UI_but_is_utf8(), ui_searchbox_apply(), ui_searchbox_find_index(), ui_searchbox_free(), ui_textedit_undo_stack_destroy(), WM_cursor_modal_restore(), WM_report_banner_show(), and WM_reportf().
Referenced by button_activate_state().
|
static |
Definition at line 3081 of file interface_handlers.c.
References BLI_str_utf8_size(), data, UI_but_is_utf8(), and ui_textedit_insert_buf().
Referenced by ui_do_but_textedit().
|
static |
This is used for both utf8 and ascii
For unicode buttons, buf is treated as unicode.
Definition at line 3037 of file interface_handlers.c.
References BLI_strnlen_utf8_ex(), data, len, uiBut::pos, uiBut::selend, uiBut::selsta, str, UI_but_is_utf8(), ui_textedit_delete_selection(), and ui_textedit_string_ensure_max_length().
Referenced by ui_do_but_textedit(), ui_textedit_copypaste(), and ui_textedit_insert_ascii().
|
static |
Definition at line 3096 of file interface_handlers.c.
References BLI_str_cursor_step_utf8(), data, jump(), len, uiBut::pos, select(), uiBut::selend, uiBut::selsta, str, STRCUR_JUMP_ALL, SWAP, and ui_but_update().
Referenced by ui_do_but_textedit().
|
static |
Definition at line 3450 of file interface_handlers.c.
References BUTTON_ACTIVATE_TEXT_EDITING, uiBlock::buttons, data, ELEM, ListBase::first, uiBut::flag, uiBut::next, uiBut::type, UI_BTYPE_LABEL, UI_BTYPE_LISTBOX, UI_BTYPE_ROUNDBOX, UI_BTYPE_SEPR, UI_BTYPE_SEPR_LINE, UI_BUT_DISABLED, and ui_but_is_editable_as_text().
Referenced by ui_do_but_textedit().
|
static |
Definition at line 3482 of file interface_handlers.c.
References BUTTON_ACTIVATE_TEXT_EDITING, uiBlock::buttons, data, ELEM, uiBut::flag, ListBase::last, uiBut::prev, uiBut::type, UI_BTYPE_LABEL, UI_BTYPE_LISTBOX, UI_BTYPE_ROUNDBOX, UI_BTYPE_SEPR, UI_BTYPE_SEPR_LINE, UI_BUT_DISABLED, and ui_but_is_editable_as_text().
Referenced by ui_do_but_textedit().
|
static |
| x | Screen space cursor location - wmEvent.x |
but->block->aspect is used here, so drawing button style is getting scaled too. Definition at line 2939 of file interface_handlers.c.
References uiBlock::aspect, BLF_boundbox_foreach_glyph(), BLF_disable(), BLF_enable(), BLF_KERNING_DEFAULT, BLF_width(), BLI_str_cursor_step_prev_utf8(), uiBut::block, data, uiBut::editstr, ELEM, uiBut::flag, uiFontStyle::kerning, uiBut::ofs, uiFontStyle::points, uiBut::pos, uiBut::rect, str, uiBut::type, ui_block_to_window_fl(), UI_BTYPE_SEARCH_MENU, UI_BTYPE_TEXT, ui_but_text_password_hide(), UI_DPI_ICON_SIZE, ui_fontscale(), UI_fontstyle_set(), UI_HAS_ICON, UI_MAX_PASSWORD_STR, UI_style_get(), UI_TEXT_MARGIN_X, ui_textedit_set_cursor_pos_foreach_glyph(), uiFontStyle::uifont_id, uiStyle::widget, x, and rctf::xmin.
Referenced by ui_do_but_textedit(), and ui_textedit_set_cursor_select().
|
static |
Definition at line 2917 of file interface_handlers.c.
References BLI_rctf_size_x(), center, user_data, and rcti::xmin.
Referenced by ui_textedit_set_cursor_pos().
|
static |
Definition at line 3019 of file interface_handlers.c.
References data, uiBut::pos, uiBut::selend, uiBut::selsta, SWAP, ui_but_update(), ui_textedit_set_cursor_pos(), and x.
Referenced by ui_do_but_textedit_select().
|
static |
Definition at line 2878 of file interface_handlers.c.
References BLI_assert, data, uiBut::editstr, and MEM_reallocN.
Referenced by ui_textedit_insert_buf(), and ui_textedit_string_set().
|
static |
Definition at line 2889 of file interface_handlers.c.
References BLI_strncpy(), BLI_strncpy_utf8(), data, str, UI_but_is_utf8(), and ui_textedit_string_ensure_max_length().
Referenced by ui_but_drop(), ui_but_paste_text(), and ui_do_but_textedit().
|
static |
Definition at line 487 of file interface_handlers.c.
Referenced by ui_but_copy_colorband(), and ui_but_paste_colorband().
|
static |
Definition at line 488 of file interface_handlers.c.
Referenced by ui_but_clipboard_free(), ui_but_copy_curvemapping(), and ui_but_paste_curvemapping().
|
static |
Definition at line 489 of file interface_handlers.c.
Referenced by ui_but_copy_curvemapping(), and ui_but_paste_curvemapping().
|
static |
Definition at line 490 of file interface_handlers.c.
Referenced by ui_but_clipboard_free(), ui_but_copy_CurveProfile(), and ui_but_paste_CurveProfile().
|
static |
Definition at line 491 of file interface_handlers.c.
Referenced by ui_but_copy_CurveProfile(), and ui_but_paste_CurveProfile().
Definition at line 702 of file interface_handlers.c.
Referenced by ui_afterfunc_new(), and ui_apply_but_funcs_after().