HI all:
       on webkit gtk 2.20.2, the createplatformdisplay class,  can the 
"gdk_wayland_display_get_wl_display(display)" be replaced by 
"wl_display_connect(nullptr)"


and i tested it works fine. is they identical by default display?


75 std::unique_ptr<PlatformDisplay> PlatformDisplay::createPlatformDisplay()
   76 {      
   77 #if PLATFORM(GTK)
   78 #if defined(GTK_API_VERSION_2)
   79     return 
PlatformDisplayX11::create(GDK_DISPLAY_XDISPLAY(gdk_display_get_default()));
   80 #else  
   81     GdkDisplay* display = 
gdk_display_manager_get_default_display(gdk_display_manager_get());
   82 #if PLATFORM(X11)
   83     if (GDK_IS_X11_DISPLAY(display))
   84     ¦   return PlatformDisplayX11::create(wl_display_connect(nullptr));
   85 #endif
   86 #if PLATFORM(WAYLAND)                                                     
                                                                                
                                                    
   87     if (GDK_IS_WAYLAND_DISPLAY(display))
   88     {
                //return 
PlatformDisplayWayland::create(gdk_wayland_display_get_wl_display(display));
   90     ¦   return 
PlatformDisplayWayland::create(wl_display_connect(nullptr));
   91     }  
   92 #endif 
   93 #endif
_______________________________________________
webkit-gtk mailing list
webkit-gtk@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-gtk

Reply via email to