diff options
author | kobewi <kobewi4e@gmail.com> | 2022-10-07 21:52:25 +0200 |
---|---|---|
committer | kobewi <kobewi4e@gmail.com> | 2022-10-07 21:52:25 +0200 |
commit | d8663b1a702086728d012194ab6dd50cfdffe85a (patch) | |
tree | 421da892887b195da407e287d80f177960b69ab9 | |
parent | 1baefceababe8a0d63434a231c3799555a45d8e3 (diff) |
Sort unused palette commands alphabetically
-rw-r--r-- | editor/editor_command_palette.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/editor/editor_command_palette.h b/editor/editor_command_palette.h index b3e84771d0..15200552b4 100644 --- a/editor/editor_command_palette.h +++ b/editor/editor_command_palette.h @@ -66,7 +66,11 @@ class EditorCommandPalette : public ConfirmationDialog { struct CommandHistoryComparator { _FORCE_INLINE_ bool operator()(const CommandEntry &A, const CommandEntry &B) const { - return A.last_used > B.last_used; + if (A.last_used == B.last_used) { + return A.display_name < B.display_name; + } else { + return A.last_used > B.last_used; + } } }; |