Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-03-04 05:31:16 +0300
committerCampbell Barton <campbell@blender.org>2022-03-04 05:31:16 +0300
commit0212c423bfaa4ccb82dca6259df084960f59944f (patch)
treeb75fe7b2075cfdca277eb5dfe3f1489b7cab0f32
parent0a4fdcbb5fe3b33a276d2ab54a1e68db0fe24fd4 (diff)
Cleanup: remove outdated references to tweak
-rw-r--r--source/blender/blenloader/intern/versioning_userdef.c1
-rw-r--r--source/blender/editors/animation/anim_markers.c4
-rw-r--r--source/blender/editors/interface/interface_handlers.c2
-rw-r--r--source/blender/editors/space_action/action_select.c2
-rw-r--r--source/blender/editors/space_graph/graph_select.c2
-rw-r--r--source/blender/editors/space_nla/nla_select.c2
-rw-r--r--source/blender/editors/space_sequencer/sequencer_select.c2
-rw-r--r--source/blender/makesdna/DNA_windowmanager_types.h2
-rw-r--r--source/blender/makesrna/intern/rna_userdef.c8
-rw-r--r--source/blender/windowmanager/WM_api.h10
-rw-r--r--source/blender/windowmanager/WM_types.h2
-rw-r--r--source/blender/windowmanager/gizmo/WM_gizmo_types.h2
-rw-r--r--source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c2
-rw-r--r--source/blender/windowmanager/intern/wm_event_system.c5
-rw-r--r--source/blender/windowmanager/intern/wm_operators.c2
-rw-r--r--source/blender/windowmanager/wm.h2
16 files changed, 25 insertions, 25 deletions
diff --git a/source/blender/blenloader/intern/versioning_userdef.c b/source/blender/blenloader/intern/versioning_userdef.c
index e933964221b..3b966fe5358 100644
--- a/source/blender/blenloader/intern/versioning_userdef.c
+++ b/source/blender/blenloader/intern/versioning_userdef.c
@@ -388,6 +388,7 @@ static bool keymap_item_has_invalid_wm_context_data_path(wmKeyMapItem *kmi,
return false;
}
+/** Tweak event types have been removed, replace with click-drag. */
static bool keymap_item_update_tweak_event(wmKeyMapItem *kmi, void *UNUSED(user_data))
{
/* Tweak events for L M R mouse-buttons. */
diff --git a/source/blender/editors/animation/anim_markers.c b/source/blender/editors/animation/anim_markers.c
index 2cb8dab59ef..9297d1082e2 100644
--- a/source/blender/editors/animation/anim_markers.c
+++ b/source/blender/editors/animation/anim_markers.c
@@ -1042,7 +1042,7 @@ static void MARKER_OT_move(wmOperatorType *ot)
/* rna storage */
RNA_def_int(ot->srna, "frames", 0, INT_MIN, INT_MAX, "Frames", "", INT_MIN, INT_MAX);
PropertyRNA *prop = RNA_def_boolean(
- ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a tweak event");
+ ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a click-drag event");
RNA_def_property_flag(prop, PROP_SKIP_SAVE);
}
@@ -1418,7 +1418,7 @@ static void MARKER_OT_select_box(wmOperatorType *ot)
WM_operator_properties_select_operation_simple(ot);
PropertyRNA *prop = RNA_def_boolean(
- ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a tweak event");
+ ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a click-drag event");
RNA_def_property_flag(prop, PROP_SKIP_SAVE);
}
diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c
index dbb2ea1dd42..8262be163b7 100644
--- a/source/blender/editors/interface/interface_handlers.c
+++ b/source/blender/editors/interface/interface_handlers.c
@@ -9373,7 +9373,7 @@ static int ui_handle_button_event(bContext *C, const wmEvent *event, uiBut *but)
/**
* Activate the underlying list-row button, so the row is highlighted.
* Early exits if \a activate_dragging is true, but the custom drag operator fails to execute.
- * Gives the wanted behavior where the item is activated on a tweak event when the custom drag
+ * Gives the wanted behavior where the item is activated on a click-drag event when the custom drag
* operator is executed.
*/
static int ui_list_activate_hovered_row(bContext *C,
diff --git a/source/blender/editors/space_action/action_select.c b/source/blender/editors/space_action/action_select.c
index 1be90109c3b..65815983767 100644
--- a/source/blender/editors/space_action/action_select.c
+++ b/source/blender/editors/space_action/action_select.c
@@ -595,7 +595,7 @@ void ACTION_OT_select_box(wmOperatorType *ot)
WM_operator_properties_select_operation_simple(ot);
PropertyRNA *prop = RNA_def_boolean(
- ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a tweak event");
+ ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a click-drag event");
RNA_def_property_flag(prop, PROP_SKIP_SAVE);
}
diff --git a/source/blender/editors/space_graph/graph_select.c b/source/blender/editors/space_graph/graph_select.c
index 9e7f0d17ac4..2ed684c6e97 100644
--- a/source/blender/editors/space_graph/graph_select.c
+++ b/source/blender/editors/space_graph/graph_select.c
@@ -903,7 +903,7 @@ void GRAPH_OT_select_box(wmOperatorType *ot)
RNA_def_property_flag(prop, PROP_SKIP_SAVE);
prop = RNA_def_boolean(
- ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a tweak event");
+ ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a click-drag event");
RNA_def_property_flag(prop, PROP_SKIP_SAVE);
prop = RNA_def_boolean(
diff --git a/source/blender/editors/space_nla/nla_select.c b/source/blender/editors/space_nla/nla_select.c
index cb9b6790239..3000b4a1109 100644
--- a/source/blender/editors/space_nla/nla_select.c
+++ b/source/blender/editors/space_nla/nla_select.c
@@ -405,7 +405,7 @@ void NLA_OT_select_box(wmOperatorType *ot)
RNA_def_boolean(ot->srna, "axis_range", 0, "Axis Range", "");
PropertyRNA *prop = RNA_def_boolean(
- ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a tweak event");
+ ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a click-drag event");
RNA_def_property_flag(prop, PROP_SKIP_SAVE);
WM_operator_properties_gesture_box(ot);
diff --git a/source/blender/editors/space_sequencer/sequencer_select.c b/source/blender/editors/space_sequencer/sequencer_select.c
index aa900ec8ffa..bd6350960f1 100644
--- a/source/blender/editors/space_sequencer/sequencer_select.c
+++ b/source/blender/editors/space_sequencer/sequencer_select.c
@@ -1725,7 +1725,7 @@ void SEQUENCER_OT_select_box(wmOperatorType *ot)
WM_operator_properties_select_operation_simple(ot);
prop = RNA_def_boolean(
- ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a tweak event");
+ ot->srna, "tweak", 0, "Tweak", "Operator has been activated using a click-drag event");
RNA_def_property_flag(prop, PROP_SKIP_SAVE);
prop = RNA_def_boolean(
ot->srna, "include_handles", 0, "Select Handles", "Select the strips and their handles");
diff --git a/source/blender/makesdna/DNA_windowmanager_types.h b/source/blender/makesdna/DNA_windowmanager_types.h
index 49d68e3a1b9..42c94832a43 100644
--- a/source/blender/makesdna/DNA_windowmanager_types.h
+++ b/source/blender/makesdna/DNA_windowmanager_types.h
@@ -362,7 +362,7 @@ typedef struct wmKeyMapItem {
short type;
/** KM_ANY, KM_PRESS, KM_NOTHING etc. */
int8_t val;
- /** Use when `val == WM_CLICK_DRAG`, */
+ /** Use when `val == KM_CLICK_DRAG`, */
int8_t direction;
/** `oskey` also known as apple, windows-key or super. */
short shift, ctrl, alt, oskey;
diff --git a/source/blender/makesrna/intern/rna_userdef.c b/source/blender/makesrna/intern/rna_userdef.c
index 9c4e51c260c..339d0bf380c 100644
--- a/source/blender/makesrna/intern/rna_userdef.c
+++ b/source/blender/makesrna/intern/rna_userdef.c
@@ -5899,20 +5899,20 @@ static void rna_def_userdef_input(BlenderRNA *brna)
RNA_def_property_ui_range(prop, 0.1f, 2.0f, 0.01f, 2);
RNA_def_property_ui_text(prop, "Orbit Sensitivity", "Scale trackball orbit sensitivity");
- /* tweak tablet & mouse preset */
+ /* Click-drag threshold for tablet & mouse. */
prop = RNA_def_property(srna, "drag_threshold_mouse", PROP_INT, PROP_PIXEL);
RNA_def_property_range(prop, 1, 255);
RNA_def_property_ui_text(prop,
"Mouse Drag Threshold",
- "Number of pixels to drag before a tweak/drag event is triggered "
- "for mouse/trackpad input "
+ "Number of pixels to drag before a drag event is triggered "
+ "for mouse/track-pad input "
"(otherwise click events are detected)");
prop = RNA_def_property(srna, "drag_threshold_tablet", PROP_INT, PROP_PIXEL);
RNA_def_property_range(prop, 1, 255);
RNA_def_property_ui_text(prop,
"Tablet Drag Threshold",
- "Number of pixels to drag before a tweak/drag event is triggered "
+ "Number of pixels to drag before a drag event is triggered "
"for tablet input "
"(otherwise click events are detected)");
diff --git a/source/blender/windowmanager/WM_api.h b/source/blender/windowmanager/WM_api.h
index ca2aaf4e208..aa380928082 100644
--- a/source/blender/windowmanager/WM_api.h
+++ b/source/blender/windowmanager/WM_api.h
@@ -796,14 +796,14 @@ void WM_operator_properties_select_walk_direction(struct wmOperatorType *ot);
* For default click selection (with no modifier keys held), the select operators can do the
* following:
* - On a mouse press on an unselected item, change selection and finish immediately after.
- * This sends an undo push and allows transform to take over should a tweak event be caught now.
+ * This sends an undo push and allows transform to take over should a click-drag event be caught.
* - On a mouse press on a selected item, don't change selection state, but start modal execution
* of the operator. Idea is that we wait with deselecting other items until we know that the
* intention wasn't to tweak (mouse press+drag) all selected items.
- * - If a tweak is recognized before the release event happens, cancel the operator, so that
- * transform can take over and no undo-push is sent.
- * - If the release event occurs rather than a tweak one, deselect all items but the one under the
- * cursor, and finish the modal operator.
+ * - If a click-drag is recognized before the release event happens, cancel the operator,
+ * so that transform can take over and no undo-push is sent.
+ * - If the release event occurs rather than a click-drag one,
+ * deselect all items but the one under the cursor, and finish the modal operator.
*
* This utility, together with #WM_generic_select_invoke() and #WM_generic_select_modal() should
* help getting the wanted behavior to work. Most generic logic should be handled in these, so that
diff --git a/source/blender/windowmanager/WM_types.h b/source/blender/windowmanager/WM_types.h
index 1f9f3e2c180..d7fe34a3b4c 100644
--- a/source/blender/windowmanager/WM_types.h
+++ b/source/blender/windowmanager/WM_types.h
@@ -273,7 +273,7 @@ enum {
/**
* #wmKeyMapItem.direction
*
- * Value of tweaks and line gestures. #KM_ANY (-1) works for this case too.
+ * Direction set for #KM_CLICK_DRAG key-map items. #KM_ANY (-1) to ignore direction.
*/
enum {
KM_DIRECTION_N = 1,
diff --git a/source/blender/windowmanager/gizmo/WM_gizmo_types.h b/source/blender/windowmanager/gizmo/WM_gizmo_types.h
index 03fafdd7d74..c69658c516c 100644
--- a/source/blender/windowmanager/gizmo/WM_gizmo_types.h
+++ b/source/blender/windowmanager/gizmo/WM_gizmo_types.h
@@ -136,7 +136,7 @@ typedef enum eWM_GizmoFlagGroupTypeFlag {
*
* The result for the user is tweak events delay the gizmo from flashing under the users cursor,
* for selection operations. This means gizmos that use this check don't interfere
- * with click drag events by popping up under the cursor and catching the tweak event.
+ * with click-drag events by popping up under the cursor and catching the drag-drag event.
*/
WM_GIZMOGROUPTYPE_DELAY_REFRESH_FOR_TWEAK = (1 << 9),
diff --git a/source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c b/source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c
index 2971cdf40c3..b3ef9b27667 100644
--- a/source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c
+++ b/source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c
@@ -607,7 +607,7 @@ void GIZMOGROUP_OT_gizmo_tweak(wmOperatorType *ot)
ot->invoke = gizmo_tweak_invoke;
ot->modal = gizmo_tweak_modal;
- /* TODO(campbell): This causes problems tweaking settings for operators,
+ /* TODO(@campbellbarton): This causes problems tweaking settings for operators,
* need to find a way to support this. */
#if 0
ot->flag = OPTYPE_UNDO;
diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c
index cd8be110c36..0e262f8c388 100644
--- a/source/blender/windowmanager/intern/wm_event_system.c
+++ b/source/blender/windowmanager/intern/wm_event_system.c
@@ -3156,7 +3156,7 @@ static int wm_handlers_do(bContext *C, wmEvent *event, ListBase *handlers)
}
if (ELEM(event->type, MOUSEMOVE, INBETWEEN_MOUSEMOVE)) {
- /* Test for #WM_CLICK_DRAG events. */
+ /* Test for #KM_CLICK_DRAG events. */
/* NOTE(@campbellbarton): Needed so drag can be used for editors that support both click
* selection and passing through the drag action to box select. See #WM_generic_select_modal.
@@ -3224,8 +3224,7 @@ static int wm_handlers_do(bContext *C, wmEvent *event, ListBase *handlers)
if (win->event_queue_check_drag) {
if ((event->prev_click_type != event->type) &&
(ISKEYMODIFIER(event->type) || (event->type == event->prev_click_keymodifier))) {
- /* Support releasing modifier keys without canceling the drag event, see T89989.
- * NOTE: this logic is replicated for tweak gestures. */
+ /* Support releasing modifier keys without canceling the drag event, see T89989. */
}
else {
win->event_queue_check_drag = false;
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c
index 7e680af4537..0dce8b8f000 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -947,7 +947,7 @@ int WM_generic_select_modal(bContext *C, wmOperator *op, const wmEvent *event)
return OPERATOR_FINISHED | OPERATOR_PASS_THROUGH;
}
/* Important not to return anything other than PASS_THROUGH here,
- * otherwise it prevents underlying tweak detection code to work properly. */
+ * otherwise it prevents underlying drag detection code to work properly. */
return OPERATOR_PASS_THROUGH;
}
diff --git a/source/blender/windowmanager/wm.h b/source/blender/windowmanager/wm.h
index 172a879e118..d7723978728 100644
--- a/source/blender/windowmanager/wm.h
+++ b/source/blender/windowmanager/wm.h
@@ -72,7 +72,7 @@ void wm_operatortypes_register(void);
void wm_gesture_draw(struct wmWindow *win);
/**
- * Tweak and line gestures.
+ * Use for line gesture.
*/
void wm_gesture_tag_redraw(struct wmWindow *win);