Skip to content

Commit

Permalink
#774: detect changes to the number of desktops or their name
Browse files Browse the repository at this point in the history
git-svn-id: https://xpra.org/svn/Xpra/trunk@8362 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Jan 3, 2015
1 parent 4515d60 commit d4bc669
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/xpra/client/ui_client_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -639,6 +639,11 @@ def tray_exit(*args):
tray_widget.show()
return ClientTray(client, wid, w, h, tray_widget, self.mmap_enabled, self.mmap)


def desktops_changed(self, *args):
workspacelog("desktops_changed%s", args)
self.screen_size_changed(*args)

def workspace_changed(self, *args):
workspacelog("workspace_changed%s", args)
for win in self._id_to_window.values():
Expand Down
2 changes: 2 additions & 0 deletions src/xpra/platform/xposix/gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -428,5 +428,7 @@ def _handle_root_prop_changed(self, obj, prop):
self.client.screen_size_changed("from %s event" % self._root_props_watcher)
elif prop=="_NET_CURRENT_DESKTOP":
self.client.workspace_changed("from %s event" % self._root_props_watcher)
elif prop in ("_NET_DESKTOP_NAMES", "_NET_NUMBER_OF_DESKTOPS"):
self.client.desktops_changed("from %s event" % self._root_props_watcher)
else:
log.error("unknown property %s", prop)

0 comments on commit d4bc669

Please sign in to comment.