Implement hotkey to delete units and buildings without confirmation dialog. Patch by Sandarac, fixes #3962.
This was SVN commit r18238.
This commit is contained in:
parent
dacecd0f33
commit
30e7b3bf25
@ -284,6 +284,7 @@ queue = Shift ; Modifier to queue unit orders instead of replacin
|
||||
batchtrain = Shift ; Modifier to train units in batches
|
||||
massbarter = Shift ; Modifier to barter bunch of resources
|
||||
masstribute = Shift ; Modifier to tribute bunch of resources
|
||||
noconfirmation = Shift ; Do not ask confirmation when deleting a building/unit
|
||||
fulltradeswap = Shift ; Modifier to put the desired trade resource to 100%
|
||||
unloadtype = Shift ; Modifier to unload all units of type
|
||||
deselectgroup = Ctrl ; Modifier to deselect units when clicking group icon, instead of selecting
|
||||
@ -292,7 +293,7 @@ rotate.ccw = LeftBracket ; Rotate building placement preview anticlockwise
|
||||
|
||||
[hotkey.session.savedgames]
|
||||
delete = Delete ; Delete the selected saved game asking confirmation
|
||||
noConfirmation = Shift ; Do not ask confirmation when deleting a game
|
||||
noconfirmation = Shift ; Do not ask confirmation when deleting a game
|
||||
|
||||
[hotkey.session.queueunit] ; > UNIT TRAINING
|
||||
1 = "Z" ; add first unit type to queue
|
||||
|
@ -161,6 +161,7 @@
|
||||
{"name": "Rolf Sievers"},
|
||||
{"nick": "s0600204", "name": "Matthew Norwood"},
|
||||
{"nick": "SafaAlfulaij"},
|
||||
{"nick": "Sandarac"},
|
||||
{"nick": "sanderd17", "name": "Sander Deryckere"},
|
||||
{"nick": "sathyam", "name": "Sathyam Vellal"},
|
||||
{"nick": "sbte", "name": "Sven Baars"},
|
||||
|
@ -133,7 +133,7 @@ function deleteReplayButtonPressed()
|
||||
if (!Engine.GetGUIObjectByName("deleteReplayButton").enabled)
|
||||
return;
|
||||
|
||||
if (Engine.HotkeyIsPressed("session.savedgames.noConfirmation"))
|
||||
if (Engine.HotkeyIsPressed("session.savedgames.noconfirmation"))
|
||||
deleteReplayWithoutConfirmation();
|
||||
else
|
||||
deleteReplay();
|
||||
|
@ -31,7 +31,7 @@
|
||||
<action on="Press">
|
||||
if (!this.enabled)
|
||||
return;
|
||||
if (Engine.HotkeyIsPressed("session.savedgames.noConfirmation"))
|
||||
if (Engine.HotkeyIsPressed("session.savedgames.noconfirmation"))
|
||||
deleteGameWithoutConfirmation();
|
||||
else
|
||||
deleteGame();
|
||||
|
@ -1022,8 +1022,13 @@ var g_EntityCommands =
|
||||
let selection = g_Selection.toList();
|
||||
if (!selection.length)
|
||||
return;
|
||||
|
||||
openDeleteDialog(selection);
|
||||
if (Engine.HotkeyIsPressed("session.noconfirmation"))
|
||||
Engine.PostNetworkCommand({
|
||||
"type": "delete-entities",
|
||||
"entities": selection
|
||||
});
|
||||
else
|
||||
openDeleteDialog(selection);
|
||||
},
|
||||
},
|
||||
"stop": {
|
||||
|
Loading…
Reference in New Issue
Block a user