Skip to content

Commit 3d0b8cf

Browse files
CZDanol-prusadanopernis
authored andcommitted
Tool mapping: Do not require double touch
BFW-5346
1 parent 1a8d2ec commit 3d0b8cf

File tree

1 file changed

+4
-14
lines changed

1 file changed

+4
-14
lines changed

src/gui/screen_tools_mapping.cpp

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1287,13 +1287,8 @@ void ToolsMappingBody::windowEvent(EventLock /*has private ctor*/, [[maybe_unuse
12871287
// Otherwise, select the appropriate item and emulate click
12881288
const auto previous_idx = current_idx;
12891289
current_idx = left_gcode_pos_to_real[it - begin];
1290-
1291-
// The tool mapping buttons are small, so we require double touch - first one selects the item, second one confirms it
1292-
if (current_idx == previous_idx) {
1293-
WindowEvent(sender, GUI_event_t::CLICK, nullptr);
1294-
} else {
1295-
update_shown_state_after_scroll(previous_idx);
1296-
}
1290+
update_shown_state_after_scroll(previous_idx);
1291+
WindowEvent(sender, GUI_event_t::CLICK, nullptr);
12971292

12981293
return;
12991294
}
@@ -1310,13 +1305,8 @@ void ToolsMappingBody::windowEvent(EventLock /*has private ctor*/, [[maybe_unuse
13101305
// Select the appropriate item and emulate click
13111306
const auto previous_idx = current_idx;
13121307
current_idx = right_phys_pos_to_real[it - begin];
1313-
1314-
// The tool mapping buttons are small, so we require double touch - first one selects the item, second one confirms it
1315-
if (current_idx == previous_idx) {
1316-
WindowEvent(sender, GUI_event_t::CLICK, nullptr);
1317-
} else {
1318-
update_shown_state_after_scroll(previous_idx);
1319-
}
1308+
update_shown_state_after_scroll(previous_idx);
1309+
WindowEvent(sender, GUI_event_t::CLICK, nullptr);
13201310

13211311
return;
13221312
}

0 commit comments

Comments
 (0)