From d409b0868ed2f6be5c36565a1098437fe1557334 Mon Sep 17 00:00:00 2001 From: Philip Kristoffersen Date: Thu, 28 Apr 2022 21:57:31 +0200 Subject: [PATCH] Sort the list of shortcuts in images --- src/ui/ui_image_download.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/ui/ui_image_download.rs b/src/ui/ui_image_download.rs index a49501e..b02b46d 100644 --- a/src/ui/ui_image_download.rs +++ b/src/ui/ui_image_download.rs @@ -303,7 +303,9 @@ impl MyEguiApp { fn handle_user_selected(&mut self, user: SteamUsersInfo) { let state = &mut self.image_selected_state; - state.user_shortcuts = Some(crate::steam::get_shortcuts_for_user(&user).shortcuts); + let mut shortcuts = crate::steam::get_shortcuts_for_user(&user).shortcuts; + shortcuts.sort_by_key(|s| s.app_name.clone()); + state.user_shortcuts = Some(shortcuts); state.steam_user = Some(user); }