From 03ba3bc616dd140f18659fcf204e9a16cdfa5b45 Mon Sep 17 00:00:00 2001 From: Marco Allegretti Date: Sun, 12 Apr 2026 09:36:23 +0200 Subject: [PATCH] Fix Pin to Dock not reappearing after unpin The visible binding on the Pin to Dock menu item called the imperative containsApplication() without any reactive dependency, so QML never re-evaluated it after model changes. Add repeater.count to the binding to force re-evaluation when favourites change. --- containments/homescreens/folio/qml/FavouritesBar.qml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/containments/homescreens/folio/qml/FavouritesBar.qml b/containments/homescreens/folio/qml/FavouritesBar.qml index fe74dbca..97601bb5 100644 --- a/containments/homescreens/folio/qml/FavouritesBar.qml +++ b/containments/homescreens/folio/qml/FavouritesBar.qml @@ -747,7 +747,8 @@ MouseArea { PC3.MenuItem { icon.name: "window-pin" text: i18n("Pin to Dock") - visible: taskContextMenu.taskStorageId !== "" && !folio.FavouritesModel.containsApplication(taskContextMenu.taskStorageId) + // repeater.count dependency forces re-evaluation when favourites change + visible: taskContextMenu.taskStorageId !== "" && repeater.count >= 0 && !folio.FavouritesModel.containsApplication(taskContextMenu.taskStorageId) enabled: !folio.FolioSettings.lockLayout onClicked: folio.FavouritesModel.addApplication(taskContextMenu.taskStorageId) }