Skip to content

Commit

Permalink
fix some issues with exclude parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
fdev31 committed Dec 1, 2023
1 parent 86748d8 commit 1bd8847
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions pyprland/plugins/scratchpads.py
Original file line number Diff line number Diff line change
Expand Up @@ -720,7 +720,10 @@ async def run_show(self, uid) -> None:
]
for tbh_scratch in excluded:
self.log.info("hidding %s", tbh_scratch)
await self.run_hide(tbh_scratch, autohide=True)

scratch = self.scratches.get(uid)
if scratch.visible:
await self.run_hide(tbh_scratch, autohide=True)
await item.updateClientInfo()
await item.initialize()

Expand Down Expand Up @@ -790,7 +793,7 @@ async def run_hide(self, uid: str, force=False, autohide=False) -> None:
)
self.log.warning("%s is not configured", uid)
return
if not scratch.visible and not force:
if not scratch.visible and not force and not autohide:
await notify_error(f"Scratchpad '{uid}' is not visible, will not hide.")
self.log.warning("%s is already hidden", uid)
return
Expand Down

0 comments on commit 1bd8847

Please sign in to comment.