Skip to content

Commit 5287c89

Browse files
committed
rename all with _key suffix
1 parent 7d04859 commit 5287c89

2 files changed

Lines changed: 12 additions & 12 deletions

File tree

editor/src/messages/input_mapper/input_mappings.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ pub fn input_mappings() -> Mapping {
9797
//
9898
// SelectToolMessage
9999
entry!(PointerMove; refresh_keys=[Control, Alt, Shift], action_dispatch=SelectToolMessage::PointerMove(SelectToolPointerKeys { axis_align: Shift, snap_angle: Shift, center: Alt, duplicate: Alt })),
100-
entry!(KeyDown(MouseLeft); action_dispatch=SelectToolMessage::DragStart { extend_selection: Shift, remove_from_selection: Alt, select_deepest_key: Accel, lasso_select_key: Control, skew: Control }),
100+
entry!(KeyDown(MouseLeft); action_dispatch=SelectToolMessage::DragStart { extend_selection_key: Shift, remove_from_selection_key: Alt, select_deepest_key: Accel, lasso_select_key: Control, skew_key: Control }),
101101
entry!(KeyUp(MouseLeft); action_dispatch=SelectToolMessage::DragStop { remove_from_selection: Alt }),
102102
entry!(KeyDown(Enter); action_dispatch=SelectToolMessage::Enter),
103103
entry!(DoubleClick(MouseButton::Left); action_dispatch=SelectToolMessage::EditLayer),

editor/src/messages/tool/tool_messages/select_tool.rs

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,11 @@ pub enum SelectToolMessage {
7878

7979
// Tool-specific messages
8080
DragStart {
81-
extend_selection: Key,
82-
remove_from_selection: Key,
81+
extend_selection_key: Key,
82+
remove_from_selection_key: Key,
8383
select_deepest_key: Key,
8484
lasso_select_key: Key,
85-
skew: Key,
85+
skew_key: Key,
8686
},
8787
DragStop {
8888
remove_from_selection: Key,
@@ -864,8 +864,8 @@ impl Fsm for SelectToolFsmState {
864864
(
865865
SelectToolFsmState::Ready { .. },
866866
SelectToolMessage::DragStart {
867-
extend_selection,
868-
remove_from_selection,
867+
extend_selection_key,
868+
remove_from_selection_key,
869869
select_deepest_key,
870870
lasso_select_key,
871871
..
@@ -954,14 +954,14 @@ impl Fsm for SelectToolFsmState {
954954
using_compass,
955955
has_dragged: false,
956956
deepest: input.keyboard.key(select_deepest_key),
957-
remove: input.keyboard.key(extend_selection),
957+
remove: input.keyboard.key(extend_selection_key),
958958
}
959959
}
960960
DragStartIntent::Rotate => SelectToolFsmState::RotatingBounds,
961961
DragStartIntent::DragWithNewSelection(layer) => {
962962
tool_data.layers_dragging = selected;
963-
let extend = input.keyboard.key(extend_selection);
964-
if !extend && !input.keyboard.key(remove_from_selection) {
963+
let extend = input.keyboard.key(extend_selection_key);
964+
if !extend && !input.keyboard.key(remove_from_selection_key) {
965965
responses.add(DocumentMessage::DeselectAllLayers);
966966
tool_data.layers_dragging.clear();
967967
}
@@ -980,13 +980,13 @@ impl Fsm for SelectToolFsmState {
980980
using_compass: false,
981981
has_dragged: false,
982982
deepest: input.keyboard.key(select_deepest_key),
983-
remove: input.keyboard.key(extend_selection),
983+
remove: input.keyboard.key(extend_selection_key),
984984
}
985985
}
986986
DragStartIntent::Draw => {
987987
tool_data.layers_dragging = selected;
988-
let extend = input.keyboard.key(extend_selection);
989-
if !extend && !input.keyboard.key(remove_from_selection) {
988+
let extend = input.keyboard.key(extend_selection_key);
989+
if !extend && !input.keyboard.key(remove_from_selection_key) {
990990
responses.add(DocumentMessage::DeselectAllLayers);
991991
tool_data.layers_dragging.clear();
992992
}

0 commit comments

Comments
 (0)