[gtk+] Pick the first rgba visual, not the last
- From: Alexander Larsson <alexl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] Pick the first rgba visual, not the last
- Date: Tue, 28 Oct 2014 17:30:59 +0000 (UTC)
commit 3406bbd1281260013e86f45e03e1dc0c3b1e97cb
Author: Alexander Larsson <alexl redhat com>
Date: Tue Oct 28 18:27:41 2014 +0100
Pick the first rgba visual, not the last
The visuals are typically sorted by some sort of "most useful first"
order. And picking the last one is likely to give us the weirdest
matching glx visual.
gdk/x11/gdkvisual-x11.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/gdk/x11/gdkvisual-x11.c b/gdk/x11/gdkvisual-x11.c
index a88882f..429b7a0 100644
--- a/gdk/x11/gdkvisual-x11.c
+++ b/gdk/x11/gdkvisual-x11.c
@@ -276,7 +276,8 @@ _gdk_x11_screen_init_visuals (GdkScreen *screen)
* Additional formats (like ABGR) could be added later if they
* turn up.
*/
- if (visuals[i]->depth == 32 &&
+ if (x11_screen->rgba_visual == NULL &&
+ visuals[i]->depth == 32 &&
(visuals[i]->red_mask == 0xff0000 &&
visuals[i]->green_mask == 0x00ff00 &&
visuals[i]->blue_mask == 0x0000ff))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]