Skip to content

Commit 42e5c5b

Browse files
committed
Allow horizontal scrolling in Tree using Shift
1 parent 3b3d622 commit 42e5c5b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

scene/gui/tree.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3957,25 +3957,25 @@ void Tree::gui_input(const Ref<InputEvent> &p_event) {
39573957

39583958
} break;
39593959
case MouseButton::WHEEL_UP: {
3960-
if (_scroll(false, -mb->get_factor() / 8)) {
3960+
if (_scroll(mb->is_shift_pressed(), -mb->get_factor() / 8)) {
39613961
accept_event();
39623962
}
39633963

39643964
} break;
39653965
case MouseButton::WHEEL_DOWN: {
3966-
if (_scroll(false, mb->get_factor() / 8)) {
3966+
if (_scroll(mb->is_shift_pressed(), mb->get_factor() / 8)) {
39673967
accept_event();
39683968
}
39693969

39703970
} break;
39713971
case MouseButton::WHEEL_LEFT: {
3972-
if (_scroll(true, -mb->get_factor() / 8)) {
3972+
if (_scroll(!mb->is_shift_pressed(), -mb->get_factor() / 8)) {
39733973
accept_event();
39743974
}
39753975

39763976
} break;
39773977
case MouseButton::WHEEL_RIGHT: {
3978-
if (_scroll(true, mb->get_factor() / 8)) {
3978+
if (_scroll(!mb->is_shift_pressed(), mb->get_factor() / 8)) {
39793979
accept_event();
39803980
}
39813981

0 commit comments

Comments
 (0)