Skip to content

Commit

Permalink
fix: Se chequea ventana al cerrar
Browse files Browse the repository at this point in the history
  • Loading branch information
JoaquinDecima committed Mar 11, 2024
1 parent 4e1470b commit 937bca4
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/x11/X11WindowStatusManager.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,17 @@ def __init__(self, window):
# Connect the screen to the default event loop
self.screen.connect("window-opened", self.windowOpened)
self.screen.connect('window-closed', self.windowClosed)
self.emitSignal()

def windowOpened(self, screen, window):
windowType = window.get_window_type()
if windowType == Wnck.WindowType.NORMAL:
self.all_windows.append(window)
self.emitSignal()

self.emitSignal()

def windowClosed(self, screen, window):
self.all_windows.remove(window)
self.emitSignal()
if window in self.all_windows:
self.all_windows.remove(window)
self.emitSignal()

def emitSignal(self):
windows = []
Expand Down

0 comments on commit 937bca4

Please sign in to comment.