Merge pull request #64071 from Calinou/3d-editor-remove-alt-fov-adjustment-3.x
This commit is contained in:
commit
5b4e7a0693
1 changed files with 6 additions and 14 deletions
|
@ -1172,27 +1172,19 @@ void SpatialEditorViewport::_sinput(const Ref<InputEvent> &p_event) {
|
||||||
float zoom_factor = 1 + (ZOOM_FREELOOK_MULTIPLIER - 1) * b->get_factor();
|
float zoom_factor = 1 + (ZOOM_FREELOOK_MULTIPLIER - 1) * b->get_factor();
|
||||||
switch (b->get_button_index()) {
|
switch (b->get_button_index()) {
|
||||||
case BUTTON_WHEEL_UP: {
|
case BUTTON_WHEEL_UP: {
|
||||||
if (b->get_alt()) {
|
|
||||||
scale_fov(-0.05);
|
|
||||||
} else {
|
|
||||||
if (is_freelook_active()) {
|
if (is_freelook_active()) {
|
||||||
scale_freelook_speed(zoom_factor);
|
scale_freelook_speed(zoom_factor);
|
||||||
} else {
|
} else {
|
||||||
scale_cursor_distance(1.0 / zoom_factor);
|
scale_cursor_distance(1.0 / zoom_factor);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
} break;
|
} break;
|
||||||
|
|
||||||
case BUTTON_WHEEL_DOWN: {
|
case BUTTON_WHEEL_DOWN: {
|
||||||
if (b->get_alt()) {
|
|
||||||
scale_fov(0.05);
|
|
||||||
} else {
|
|
||||||
if (is_freelook_active()) {
|
if (is_freelook_active()) {
|
||||||
scale_freelook_speed(1.0 / zoom_factor);
|
scale_freelook_speed(1.0 / zoom_factor);
|
||||||
} else {
|
} else {
|
||||||
scale_cursor_distance(zoom_factor);
|
scale_cursor_distance(zoom_factor);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
} break;
|
} break;
|
||||||
|
|
||||||
case BUTTON_RIGHT: {
|
case BUTTON_RIGHT: {
|
||||||
|
|
Loading…
Reference in a new issue