[vlc-commits] GTK: Actually destroy our X window when we are told to

Cheng Sun git at videolan.org
Thu Jan 5 03:03:06 CET 2012


npapi-vlc | branch: master | Cheng Sun <chengsun9 at gmail.com> | Tue Jan  3 21:12:37 2012 +0000| [95b526ce86fa316180d4e6309d4e2e9a199f5da8] | committer: Jean-Baptiste Kempf

GTK: Actually destroy our X window when we are told to

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/npapi-vlc.git/?a=commit;h=95b526ce86fa316180d4e6309d4e2e9a199f5da8
---

 npapi/vlcplugin_gtk.cpp |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/npapi/vlcplugin_gtk.cpp b/npapi/vlcplugin_gtk.cpp
index c781468..37d2412 100644
--- a/npapi/vlcplugin_gtk.cpp
+++ b/npapi/vlcplugin_gtk.cpp
@@ -441,6 +441,11 @@ bool VlcPluginGtk::resize_windows()
 bool VlcPluginGtk::destroy_windows()
 {
     Display *display = get_display();
+
+    /* destroy x window */
+    XDestroyWindow(display, video_xwindow);
+
+    /* free colors */
     Colormap colormap = DefaultColormap(display, DefaultScreen(display));
     XFreeColors(display, colormap, &bg_color.pixel, 1, 0);
 }



More information about the vlc-commits mailing list