[totem] Set BaconVideoWidget's colormap to the system colormap.



commit e8930fc439386304c392272cf3b7b038d8899376
Author: Cody Russell <bratsche gnome org>
Date:   Fri May 14 12:39:46 2010 +0200

    Set BaconVideoWidget's colormap to the system colormap.
    
    In the future, GTK+ will use an RGBA colormap by default,
    so we set BVW's colormap to the system colormap to be
    forward-compatible with this.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=618597

 src/backend/bacon-video-widget-gst-0.10.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/backend/bacon-video-widget-gst-0.10.c b/src/backend/bacon-video-widget-gst-0.10.c
index 85a1d11..4845844 100644
--- a/src/backend/bacon-video-widget-gst-0.10.c
+++ b/src/backend/bacon-video-widget-gst-0.10.c
@@ -573,6 +573,7 @@ bacon_video_widget_realize (GtkWidget * widget)
   attributes.x = 0;
   attributes.y = 0;
   gtk_widget_get_allocation (widget, &allocation);
+  attributes.colormap = gdk_screen_get_system_colormap (gtk_widget_get_screen (widget));
   attributes.width = allocation.width;
   attributes.height = allocation.height;
   attributes.wclass = GDK_INPUT_OUTPUT;
@@ -581,7 +582,7 @@ bacon_video_widget_realize (GtkWidget * widget)
                            GDK_POINTER_MOTION_MASK |
                            GDK_BUTTON_PRESS_MASK |
                            GDK_KEY_PRESS_MASK;
-  attributes_mask = GDK_WA_X | GDK_WA_Y;
+  attributes_mask = GDK_WA_X | GDK_WA_Y | GDK_WA_COLORMAP;
 
   bvw->priv->video_window = gdk_window_new (window,
       &attributes, attributes_mask);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]