From: Peter Åstrand Date: Thu, 15 Jan 2009 13:26:01 +0000 (+0000) Subject: When updating X11 window title, update WM_ICON_NAME and WM_CLASS as X-Git-Tag: v0.0.90~196 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=be690321c42f5234bee0aa47fd4c3e5497124ee5;p=tigervnc.git When updating X11 window title, update WM_ICON_NAME and WM_CLASS as well. Tested in ThinLinc since 2008-01-10. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3550 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- diff --git a/unix/tx/TXWindow.cxx b/unix/tx/TXWindow.cxx index 4bab2d9b..2b535df8 100644 --- a/unix/tx/TXWindow.cxx +++ b/unix/tx/TXWindow.cxx @@ -288,7 +288,14 @@ void TXWindow::toplevel(const char* name, TXDeleteWindowCallback* dwc_, void TXWindow::setName(const char* name) { - XStoreName(dpy, win(), name); + XClassHint classHint; + XGetClassHint(dpy, win(), &classHint); + XFree(classHint.res_name); + classHint.res_name = (char*)name; + XSetClassHint(dpy, win(), &classHint); + XFree(classHint.res_class); + XStoreName(dpy, win(), name); + XSetIconName(dpy, win(), name); } void TXWindow::setMaxSize(int w, int h)