Skip to content

Commit

Permalink
spelling things
Browse files Browse the repository at this point in the history
  • Loading branch information
PankajBhojwani committed Apr 30, 2024
1 parent e725f1e commit db00b90
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
8 changes: 4 additions & 4 deletions src/cascadia/TerminalSettingsModel/ActionMap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -488,7 +488,7 @@ namespace winrt::Microsoft::Terminal::Settings::Model::implementation
// the user might have { "command": null, "id": "someID", "keys": "ctrl+c" }
// i.e. they provided an ID for a null command (which they really shouldn't, there's no purpose)
// in this case, we do _not_ want to use the id they provided, we want to use an empty id
// (empty id in the _KeyMap indicates the the keychord was explicitly unbound)
// (empty id in the _KeyMap indicates the keychord was explicitly unbound)
if (cmd.ActionAndArgs().Action() == ShortcutAction::Invalid)
{
_KeyMap.insert_or_assign(keys, L"");
Expand Down Expand Up @@ -537,7 +537,7 @@ namespace winrt::Microsoft::Terminal::Settings::Model::implementation
// - the command ID with the given key chord
// - an empty string if the key chord is explicitly unbound
// - nullopt if it is not bound
std::optional<winrt::hstring> ActionMap::_GetActionIDByKeyChordInternal(const Control::KeyChord& keys) const
std::optional<winrt::hstring> ActionMap::_GetActionIdByKeyChordInternal(const Control::KeyChord& keys) const
{
if (const auto keyIDPair = _KeyMap.find(keys); keyIDPair != _KeyMap.end())
{
Expand All @@ -555,7 +555,7 @@ namespace winrt::Microsoft::Terminal::Settings::Model::implementation
// search through our parents
for (const auto& parent : _parents)
{
if (const auto foundCmdID = parent->_GetActionIDByKeyChordInternal(keys))
if (const auto foundCmdID = parent->_GetActionIdByKeyChordInternal(keys))
{
return foundCmdID;
}
Expand All @@ -576,7 +576,7 @@ namespace winrt::Microsoft::Terminal::Settings::Model::implementation
// - nullopt if it is not bound
std::optional<Model::Command> ActionMap::_GetActionByKeyChordInternal(const Control::KeyChord& keys) const
{
if (const auto actionIDOptional = _GetActionIDByKeyChordInternal(keys))
if (const auto actionIDOptional = _GetActionIdByKeyChordInternal(keys))
{
if (!(*actionIDOptional).empty())
{
Expand Down
2 changes: 1 addition & 1 deletion src/cascadia/TerminalSettingsModel/ActionMap.h
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ namespace winrt::Microsoft::Terminal::Settings::Model::implementation

private:
Model::Command _GetActionByID(const winrt::hstring actionID) const;
std::optional<winrt::hstring> _GetActionIDByKeyChordInternal(const Control::KeyChord& keys) const;
std::optional<winrt::hstring> _GetActionIdByKeyChordInternal(const Control::KeyChord& keys) const;
std::optional<Model::Command> _GetActionByKeyChordInternal(const Control::KeyChord& keys) const;

void _RefreshKeyBindingCaches();
Expand Down
4 changes: 2 additions & 2 deletions src/cascadia/TerminalSettingsModel/ActionMapSerialization.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,8 @@ namespace winrt::Microsoft::Terminal::Settings::Model::implementation
// TODO GH#17160
// if the command with this id is only going to appear later during settings load
// then this will return null, meaning that the command created later on will not register this keybinding
// the keybinding will still work fine within the app, its just that the Command object itself won't know about this keymapping
// we are going to move away from Command needing to know its keymappings in a followup, so this shouldn't matter for very long
// the keybinding will still work fine within the app, its just that the Command object itself won't know about this key mapping
// we are going to move away from Command needing to know its key mappings in a followup, so this shouldn't matter for very long
if (const auto cmd = _GetActionByID(idJson))
{
cmd.RegisterKey(keys);
Expand Down

0 comments on commit db00b90

Please sign in to comment.