Dock: Add option to filter by output.

This commit is contained in:
Leopold Luley
2025-09-30 23:01:46 +02:00
parent 32712c7052
commit fdc61acfe4
4 changed files with 24 additions and 6 deletions
+7 -1
View File
@@ -51,6 +51,9 @@ Variants {
function onPinnedAppsChanged() {
updateDockApps()
}
function onOnlySameOutputChanged() {
updateDockApps()
}
}
// Initial update when component is ready
@@ -108,7 +111,10 @@ Variants {
// Strategy: Maintain app positions as much as possible
// 1. First pass: Add all running apps (both pinned and non-pinned) in their current order
runningApps.forEach(toplevel => {
if (toplevel && toplevel.appId) {
if (
toplevel && toplevel.appId
&& !(Settings.data.dock.onlySameOutput && toplevel.screens && !toplevel.screens.includes(modelData))
) {
const isPinned = pinnedApps.includes(toplevel.appId)
const appType = isPinned ? "pinned-running" : "running"