Skip to content

Commit cde14ae

Browse files
authored
Merge pull request #1176 from myk002/myk_confirm
[confirm] fix message display for hotkey zoom confirm spec
2 parents d207453 + 9144671 commit cde14ae

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

changelog.txt

+1
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ Template for new versions:
5151
- `gui/sandbox`: created undead now have a purple shade (after save and reload)
5252
- `caravan`: fix errors in trade dialog if all fort items are traded away while the trade dialog is showing fort items and the `confirm` trade confirmation is shown
5353
- `control-panel`: restore non-default values of per-save enabled/disabled settings for repeat-based commands
54+
- `confirm`: fix confirmation prompt for overwriting a hotkey zoom location
5455

5556
## Misc Improvements
5657
- `gui/launcher`: "space space to toggle pause" behavior is skipped if the game was paused when `gui/launcher` came up to prevent accidental unpausing

confirm.lua

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ local dialogs = require('gui.dialogs')
44
local gui = require('gui')
55
local overlay = require('plugins.overlay')
66
local specs = reqscript('internal/confirm/specs')
7+
local utils = require('utils')
78
local widgets = require("gui.widgets")
89

910
------------------------
@@ -129,7 +130,7 @@ function ConfirmOverlay:onInput(keys)
129130
gui.simulateInput(scr, keys)
130131
self.simulating = false
131132
end
132-
dialogs.showYesNoPrompt(conf.title, conf.message:wrap(45), COLOR_YELLOW,
133+
dialogs.showYesNoPrompt(conf.title, utils.getval(conf.message):wrap(45), COLOR_YELLOW,
133134
propagate_fn, nil, curry(propagate_fn, true), curry(dfhack.run_script, 'gui/confirm', tostring(conf.id)))
134135
return true
135136
end

0 commit comments

Comments
 (0)