gnome-settings-daemon r504 - in branches/gnome-2-22: . plugins/media-keys
- From: jensg svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-settings-daemon r504 - in branches/gnome-2-22: . plugins/media-keys
- Date: Thu, 11 Sep 2008 17:29:58 +0000 (UTC)
Author: jensg
Date: Thu Sep 11 17:29:58 2008
New Revision: 504
URL: http://svn.gnome.org/viewvc/gnome-settings-daemon?rev=504&view=rev
Log:
2008-09-11 Jens Granseuer <jensgr gmx net>
Backported from trunk.
Make the volume popup not crash when invoking it on any screen but the
first when using a compositing manager (bug #551677)
* plugins/media-keys/gsd-media-keys-manager.c: (dialog_show):
* plugins/media-keys/gsd-media-keys-window.c:
(gsd_media_keys_window_init):
do not set the window colormap at init time where we'll only use the
colormap of the default screen. Instead, whenever moving the window to
a new screen, also update the colormap.
Modified:
branches/gnome-2-22/ChangeLog
branches/gnome-2-22/plugins/media-keys/gsd-media-keys-manager.c
branches/gnome-2-22/plugins/media-keys/gsd-media-keys-window.c
Modified: branches/gnome-2-22/plugins/media-keys/gsd-media-keys-manager.c
==============================================================================
--- branches/gnome-2-22/plugins/media-keys/gsd-media-keys-manager.c (original)
+++ branches/gnome-2-22/plugins/media-keys/gsd-media-keys-manager.c Thu Sep 11 17:29:58 2008
@@ -486,10 +486,16 @@
GdkScreen *pointer_screen;
GdkRectangle geometry;
int monitor;
+ GdkColormap *colormap;
gtk_window_set_screen (GTK_WINDOW (manager->priv->dialog),
manager->priv->current_screen);
+ colormap = gdk_screen_get_rgba_colormap (manager->priv->current_screen);
+ if (colormap != NULL) {
+ gtk_widget_set_colormap (manager->priv->dialog, colormap);
+ }
+
/*
* get the window size
* if the window hasn't been mapped, it doesn't necessarily
Modified: branches/gnome-2-22/plugins/media-keys/gsd-media-keys-window.c
==============================================================================
--- branches/gnome-2-22/plugins/media-keys/gsd-media-keys-window.c (original)
+++ branches/gnome-2-22/plugins/media-keys/gsd-media-keys-window.c Thu Sep 11 17:29:58 2008
@@ -846,23 +846,6 @@
}
static void
-initialize_alpha_mode (GsdMediaKeysWindow *window, GdkScreen *screen)
-{
- GdkColormap *colormap = NULL;
-
- if (gdk_screen_is_composited (screen)) {
- colormap = gdk_screen_get_rgba_colormap (screen);
- }
-
- if (colormap != NULL) {
- gtk_widget_set_colormap (GTK_WIDGET (window), colormap);
- window->priv->is_composited = TRUE;
- } else {
- window->priv->is_composited = FALSE;
- }
-}
-
-static void
gsd_media_keys_window_init (GsdMediaKeysWindow *window)
{
GdkScreen *screen;
@@ -871,7 +854,7 @@
screen = gtk_widget_get_screen (GTK_WIDGET (window));
- initialize_alpha_mode (window, screen);
+ window->priv->is_composited = gdk_screen_is_composited (screen);
if (window->priv->is_composited) {
gdouble scalew, scaleh, scale;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]