Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/windowing/StarKeyBindings.cpp
diff options
context:
space:
mode:
authorKae <80987908+Novaenia@users.noreply.github.com>2023-06-27 20:23:44 +1000
committerKae <80987908+Novaenia@users.noreply.github.com>2023-06-27 20:23:44 +1000
commit332983c97b7a729c4dc5f19aa9ee4a22c420f7d8 (patch)
treefd9c441b796b522bdd5c7f8fbd32f51b8eff2a28 /source/windowing/StarKeyBindings.cpp
parent14b9689b6d4f4ad5276c88130dc6e449bedc0709 (diff)
The Formatting String Catastrophe
Diffstat (limited to 'source/windowing/StarKeyBindings.cpp')
-rw-r--r--source/windowing/StarKeyBindings.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/windowing/StarKeyBindings.cpp b/source/windowing/StarKeyBindings.cpp
index e93a1af..969a766 100644
--- a/source/windowing/StarKeyBindings.cpp
+++ b/source/windowing/StarKeyBindings.cpp
@@ -107,10 +107,10 @@ KeyChord inputDescriptorFromJson(Json const& json) {
} else if (value.canConvert(Json::Type::Int)) {
key = (Key)value.toUInt();
} else {
- throw StarException::format("Improper key value '%s'", value);
+ throw StarException::format("Improper key value '{}'", value);
}
} else {
- throw StarException::format("Improper bindings type '%s'", type);
+ throw StarException::format("Improper bindings type '{}'", type);
}
KeyMod mods = KeyMod::NoMod;
@@ -156,7 +156,7 @@ KeyBindings::KeyBindings(Json const& json) {
auto chord = inputDescriptorFromJson(input);
actions[chord.key].append({chord.mods, action});
} catch (StarException const& e) {
- Logger::warn("Could not load keybinding for %s: %s\n",
+ Logger::warn("Could not load keybinding for {}: {}\n",
InterfaceActionNames.getRight(action),
outputException(e, false));
}
@@ -165,7 +165,7 @@ KeyBindings::KeyBindings(Json const& json) {
m_actions = move(actions);
} catch (StarException const& e) {
- throw StarException(strf("Could not set keybindings from configuration. %s", outputException(e, false)));
+ throw StarException(strf("Could not set keybindings from configuration. {}", outputException(e, false)));
}
}