Bug 1286482 - use gdk_display_get_default() instead of mIsX11Display attribute, r=karlt
authorMartin Stransky <stransky@redhat.com>
Mon, 01 Aug 2016 01:52:00 +0200
changeset 308267 d2c3da5ac021138cc92099d2c10b6a591929b6c4
parent 308266 4ec3149b367b152e77ee4c0d24bb5c6ca6ce5f3a
child 308268 6e875e1462fc68ee5deef2ce1923d4e351982d03
push id31092
push usercbook@mozilla.com
push dateFri, 05 Aug 2016 10:16:59 +0000
treeherderautoland@b97dd7dd3cb9 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskarlt
bugs1286482
milestone51.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 1286482 - use gdk_display_get_default() instead of mIsX11Display attribute, r=karlt
widget/gtk/nsWindow.cpp
--- a/widget/gtk/nsWindow.cpp
+++ b/widget/gtk/nsWindow.cpp
@@ -1344,17 +1344,17 @@ SetUserTimeAndStartupIDForActivatedWindo
             gdk_window_focus(gtk_widget_get_window(aWindow), timestamp);
             GTKToolkit->SetFocusTimestamp(0);
         }
         return;
     }
 
 #if defined(MOZ_ENABLE_STARTUP_NOTIFICATION)
     // TODO - Implement for non-X11 Gtk backends (Bug 726479)
-    if (mIsX11Display) {
+    if (GDK_IS_X11_DISPLAY(gdk_display_get_default())) {
         GdkWindow* gdkWindow = gtk_widget_get_window(aWindow);
 
         GdkScreen* screen = gdk_window_get_screen(gdkWindow);
         SnDisplay* snd =
             sn_display_new(gdk_x11_display_get_xdisplay(gdk_window_get_display(gdkWindow)),
                            nullptr, nullptr);
         if (!snd)
             return;