Some adjustments to last change
* src/gtkutil.c (xg_set_undecorated): Only set ARGB visual on Cairo builds wtihout PGTK. * src/xfns.c (select_visual): Likewise.
This commit is contained in:
parent
b944841173
commit
391c1289e2
2 changed files with 4 additions and 2 deletions
|
@ -1593,12 +1593,14 @@ xg_create_frame_widgets (struct frame *f)
|
|||
|
||||
GdkScreen *screen = gtk_widget_get_screen (wtop);
|
||||
|
||||
#if !defined HAVE_PGTK && defined USE_CAIRO
|
||||
if (FRAME_DISPLAY_INFO (f)->n_planes == 32)
|
||||
{
|
||||
GdkVisual *visual = gdk_screen_get_rgba_visual (screen);
|
||||
gtk_widget_set_visual (wtop, visual);
|
||||
gtk_widget_set_visual (wfixed, visual);
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifndef HAVE_PGTK
|
||||
/* Must realize the windows so the X window gets created. It is used
|
||||
|
|
|
@ -6375,7 +6375,7 @@ select_visual (struct x_display_info *dpyinfo)
|
|||
|
||||
vinfo_template.screen = XScreenNumberOfScreen (screen);
|
||||
|
||||
#if defined (USE_GTK)
|
||||
#if defined (USE_GTK) && defined (USE_CAIRO)
|
||||
/* First attempt to use 32-bit visual if available */
|
||||
|
||||
vinfo_template.depth = 32;
|
||||
|
@ -6391,7 +6391,7 @@ select_visual (struct x_display_info *dpyinfo)
|
|||
return;
|
||||
}
|
||||
|
||||
#endif /* defined (USE_GTK) */
|
||||
#endif /* USE_GTK && USE_CAIRO */
|
||||
|
||||
/* 32-bit visual not available, fallback to default visual */
|
||||
dpyinfo->visual = DefaultVisualOfScreen (screen);
|
||||
|
|
Loading…
Add table
Reference in a new issue