[gnome-shell/gnome-3-34] appDisplay: Ensure we don't recreate existing AppIcons for folders



commit 7800bd21586d03a1da9a2917cccc2717cf7ce31e
Author: Jonas Dreßler <verdre v0yd nl>
Date:   Sat Nov 23 21:44:55 2019 +0100

    appDisplay: Ensure we don't recreate existing AppIcons for folders
    
    This was missed in 910037f014355ee9680c45f82a4aac2891c4074f, make sure
    we do the same thing for AppIcons that are created when reloading
    folders.
    
    https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/851

 js/ui/appDisplay.js | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
---
diff --git a/js/ui/appDisplay.js b/js/ui/appDisplay.js
index fb7cb5f4dc..6967deadbe 100644
--- a/js/ui/appDisplay.js
+++ b/js/ui/appDisplay.js
@@ -1362,7 +1362,10 @@ var FolderView = class FolderView extends BaseAppView {
             if (apps.some(appIcon => appIcon.id == appId))
                 return;
 
-            let icon = new AppIcon(app);
+            let icon = this._items[appId];
+            if (!icon)
+                icon = new AppIcon(app);
+
             apps.push(icon);
         };
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]