Skip to content

Commit

Permalink
#705 expose window manager name via "xpra info" to make it easier to …
Browse files Browse the repository at this point in the history
…verify that we are applying the java workaround

git-svn-id: https://xpra.org/svn/Xpra/trunk@8065 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Nov 7, 2014
1 parent 6ce3bfe commit 5b81d7a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/xpra/x11/gtk_x11/wm.py
Original file line number Diff line number Diff line change
Expand Up @@ -438,4 +438,10 @@ def _setup_ewmh_window(self):
self.root_set("_NET_SUPPORTING_WM_CHECK",
"window", self._ewmh_window)

def get_net_wm_name(self):
try:
return prop_get(self._ewmh_window, "_NET_WM_NAME", "utf8", ignore_errors=False, raise_xerrors=False)
except Exception as e:
log.error("error querying _NET_WM_NAME: %s", e)

gobject.type_register(Wm)
2 changes: 2 additions & 0 deletions src/xpra/x11/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,8 @@ def do_get_info(self, proto, server_sources, window_ids):

def get_ui_info(self, proto, wids, *args):
info = X11ServerBase.get_ui_info(self, proto, wids, *args)
#_NET_WM_NAME:
info["window-manager-name"] = self._wm.get_net_wm_name()
#now cursor size info:
display = gtk.gdk.display_get_default()
for prop, size in {"default" : display.get_default_cursor_size(),
Expand Down

0 comments on commit 5b81d7a

Please sign in to comment.