Fluss-Editor: Tastenkürzel fehlten (Enter, Esc, Delete, Backspace)

RiverEditorState nutzt dieselben SharedInput-Flags wie der Wasserfall-Editor
(finalizeWaterfallRequested, cancelZoneDrawing, deleteWaterfallRequested,
undoWaterfallPointRequested), aber LAYER_RIVER fehlte in allen vier
Key-Handler-Zweigen in EditorApp.handleKeyPress.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-10-06 13:38:12 +02:00
parent 02196aa438
commit f2cb866cd5

View File

@@ -962,7 +962,8 @@ public class EditorApp extends Application {
case CONTROL -> input.ctrlHeld = pressed;
case ALT -> input.altHeld = pressed;
case ENTER -> {
if (pressed && input.activeLayer == SharedInput.LAYER_WATERFALL)
if (pressed && (input.activeLayer == SharedInput.LAYER_WATERFALL
|| input.activeLayer == SharedInput.LAYER_RIVER))
input.finalizeWaterfallRequested = true;
if (pressed && input.activeLayer == SharedInput.LAYER_VOXEL_CLIFF) {
input.generateCliffVoxelsRequested = true;
@@ -976,7 +977,8 @@ public class EditorApp extends Application {
|| input.activeLayer == SharedInput.LAYER_ZONEN
|| input.activeLayer == SharedInput.LAYER_WATER
|| input.activeLayer == SharedInput.LAYER_WATERFALL
|| input.activeLayer == SharedInput.LAYER_VOXEL_CLIFF))
|| input.activeLayer == SharedInput.LAYER_VOXEL_CLIFF
|| input.activeLayer == SharedInput.LAYER_RIVER))
input.cancelZoneDrawing = true;
else if (pressed && input.activeLayer == SharedInput.LAYER_OBJECTS
&& "objecteditor".equals(registry.activeToolId()))
@@ -1020,6 +1022,9 @@ public class EditorApp extends Application {
input.deleteVoxelCliffZoneRequested = true;
else if (input.activeLayer == SharedInput.LAYER_WATER)
input.deleteWaterRequested = true;
else if (input.activeLayer == SharedInput.LAYER_RIVER
&& input.selectedWaterfallInfo != null)
input.deleteWaterfallRequested = true;
else if (input.activeLayer == SharedInput.LAYER_WATERFALL
&& input.selectedWaterfallInfo != null) {
Platform.runLater(() -> {
@@ -1042,7 +1047,8 @@ public class EditorApp extends Application {
}
}
case BACK_SPACE -> {
if (pressed && input.activeLayer == SharedInput.LAYER_WATERFALL)
if (pressed && (input.activeLayer == SharedInput.LAYER_WATERFALL
|| input.activeLayer == SharedInput.LAYER_RIVER))
input.undoWaterfallPointRequested = true;
}
case SPACE -> {