diff options
author | Jim Grandy <jgrandy@authentic8.com> | 2013-07-06 08:17:20 -0700 |
---|---|---|
committer | Jim Grandy <jgrandy@authentic8.com> | 2013-07-26 12:25:02 -0700 |
commit | 9db0cb13d06492415b66a244c5c06a113dd07c10 (patch) | |
tree | 1db9770d3083e80960be35a64448e8bdcea12d60 /sesman/chansrv | |
parent | 8c176482ba2da3a8a3538618e855879711f0de1d (diff) | |
download | xrdp-proprietary-9db0cb13d06492415b66a244c5c06a113dd07c10.tar.gz xrdp-proprietary-9db0cb13d06492415b66a244c5c06a113dd07c10.zip |
Hand-apply patch (chansrv: handle ReparentNotify) from Authentic8: 68cdc07
Diffstat (limited to 'sesman/chansrv')
-rw-r--r-- | sesman/chansrv/rail.c | 26 |
1 files changed, 23 insertions, 3 deletions
diff --git a/sesman/chansrv/rail.c b/sesman/chansrv/rail.c index c2137fb7..a0964914 100644 --- a/sesman/chansrv/rail.c +++ b/sesman/chansrv/rail.c @@ -1663,7 +1663,8 @@ rail_xevent(void *xevent) break; case CreateNotify: - LOG(10, (" got CreateNotify 0x%8.8x", lxevent->xcreatewindow.window)); + LOG(10, (" got CreateNotify window 0x%8.8x parent 0x%8.8x", + lxevent->xcreatewindow.window, lxevent->xcreatewindow.parent)); break; case DestroyNotify: @@ -1678,14 +1679,15 @@ rail_xevent(void *xevent) break; case MapRequest: - LOG(10, (" got MapRequest 0x%8.8x", lxevent->xmaprequest.window)); + LOG(10, (" got MapRequest window 0x%8.8x", lxevent->xmaprequest.window)); XSelectInput(g_display, lxevent->xmaprequest.window, PropertyChangeMask | StructureNotifyMask); XMapWindow(g_display, lxevent->xmaprequest.window); break; case MapNotify: - LOG(10, (" got MapNotify 0x%8.8x", lxevent->xmap.event)); + LOG(10, (" got MapNotify window 0x%8.8x event 0x%8.8x", + lxevent->xmap.window, lxevent->xmap.event)); if (lxevent->xmap.window != lxevent->xmap.event) { XGetWindowAttributes(g_display, lxevent->xmap.window, &wnd_attributes); @@ -1769,6 +1771,24 @@ rail_xevent(void *xevent) LOG(10, (" got LeaveNotify")); break; + case ReparentNotify: + LOG(10, (" got ReparentNotify window 0x%8.8x parent 0x%8.8x " + "event 0x%8.8x x %d y %d overrider redirect %d", + lxevent->xreparent.window, lxevent->xreparent.parent, + lxevent->xreparent.event, lxevent->xreparent.x, + lxevent->xreparent.y, lxevent->xreparent.override_redirect)); + + if (lxevent->xreparent.parent != g_root_window) + { + index = list_index_of(g_window_list, lxevent->xreparent.window); + if (index >= 0) + { + rail_destroy_window(lxevent->xreparent.window); + list_remove_item(g_window_list, index); + } + } + rv = 0; + break; } return rv; |