# HG changeset patch # User reimar # Date 1322939179 0 # Node ID e60d8bdb47952bdeb08661d85d90561f224b4a1e # Parent e61a652e9cf15f44b420dd74a411c5509c831d7f X11: update title only on reconfigure instead of at least once per frame. At least currently such frequent updates are not necessary and they are a bit of a performance issue, at least when used with X forwarding. diff -r e61a652e9cf1 -r e60d8bdb4795 libvo/x11_common.c --- a/libvo/x11_common.c Sat Dec 03 18:43:54 2011 +0000 +++ b/libvo/x11_common.c Sat Dec 03 19:06:19 2011 +0000 @@ -1079,6 +1079,8 @@ Colormap col_map, const char *classname, const char *title) { + if (vo_wintitle) + title = vo_wintitle; if (WinID >= 0) { vo_fs = flags & VOFLAG_FULLSCREEN; vo_window = WinID ? (Window)WinID : mRootWin; @@ -1117,12 +1119,12 @@ } if (flags & VOFLAG_HIDDEN) goto final; + XStoreName(mDisplay, vo_window, title); if (window_state & VOFLAG_HIDDEN) { XSizeHints hint; XEvent xev; window_state &= ~VOFLAG_HIDDEN; vo_x11_classhint(mDisplay, vo_window, classname); - XStoreName(mDisplay, vo_window, title); vo_hidecursor(mDisplay, vo_window); XSelectInput(mDisplay, vo_window, StructureNotifyMask); hint.x = x; hint.y = y; @@ -1351,8 +1353,6 @@ if (w <= INT_MAX && h <= INT_MAX) { vo_dwidth = w; vo_dheight = h; } XTranslateCoordinates(mDisplay, vo_window, mRootWin, 0, 0, &vo_dx, &vo_dy, &dummy_win); - if (vo_wintitle) - XStoreName(mDisplay, vo_window, vo_wintitle); return depth <= INT_MAX ? depth : 0; }