Bug 1466775 - [Wayland] Configure WebRender on X11, r=jhorak
authorMartin Stransky <stransky@redhat.com>
Tue, 05 Jun 2018 11:35:45 +0200
changeset 422341 3447515d62c9727f15b2d83325dd44a394b4729a
parent 422340 671bf6da80a5ab0836feacee2100aa81614833a7
child 422342 b4d2c51e12560616d1c6125df9773e5676cac0de
push id34129
push userrgurzau@mozilla.com
push dateTue, 12 Jun 2018 21:49:48 +0000
treeherdermozilla-central@5ba3ea055cc3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjhorak
bugs1466775
milestone62.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1466775 - [Wayland] Configure WebRender on X11, r=jhorak MozReview-Commit-ID: ChXp7m5XeOI
widget/gtk/nsWindow.cpp
--- a/widget/gtk/nsWindow.cpp
+++ b/widget/gtk/nsWindow.cpp
@@ -3708,17 +3708,17 @@ nsWindow::Create(nsIWidget* aParent,
         bool useAlphaVisual = (mWindowType == eWindowType_popup &&
                                aInitData->mSupportTranslucency);
 
         // mozilla.widget.use-argb-visuals is a hidden pref defaulting to false
         // to allow experimentation
         if (Preferences::GetBool("mozilla.widget.use-argb-visuals", false))
             useAlphaVisual = true;
 
-#ifdef GL_PROVIDER_GLX
+#ifdef MOZ_X11
         // Ensure gfxPlatform is initialized, since that is what initializes
         // gfxVars, used below.
         Unused << gfxPlatform::GetPlatform();
 
         bool useWebRender = gfx::gfxVars::UseWebRender() &&
             AllowWebRenderForThisWindow();
 
         // If using WebRender on X11, we need to select a visual with a depth buffer,
@@ -3735,17 +3735,17 @@ nsWindow::Create(nsIWidget* aParent,
                                          &visualId)) {
                 // If we're using CSD, rendering will go through mContainer, but
                 // it will inherit this visual as it is a child of mShell.
                 gtk_widget_set_visual(mShell,
                                       gdk_x11_screen_lookup_visual(screen,
                                                                    visualId));
             }
         } else
-#endif // GL_PROVIDER_GLX
+#endif // MOZ_X11
         {
             if (useAlphaVisual) {
                 GdkScreen *screen = gtk_widget_get_screen(mShell);
                 if (gdk_screen_is_composited(screen)) {
                     GdkVisual *visual = gdk_screen_get_rgba_visual(screen);
                     gtk_widget_set_visual(mShell, visual);
                 }
             }