-
mrobinson@webkit.org authored
https://bugs.webkit.org/show_bug.cgi?id=90085 Reviewed by Alejandro G. Castro. .: * configure.ac: Parse xcomposite pkg-config file during configuration. Source/WebCore: No new tests. This will be covered by pixel test for accelerated compositing when they are activated. * GNUmakefile.am: Add XComposite libraries to the linker list. * GNUmakefile.list.am: Add RedirectedXCompositeWindow files to the source list. Make a new section for GLX specific files. * platform/graphics/glx/GLContextGLX.cpp: (WebCore::GLContextGLX::sharedDisplay): Expose sharedDisplay as a static method so that it can be called by other X11 specific code. * platform/graphics/glx/GLContextGLX.h: Ditto. * platform/gtk/RedirectedXCompositeWindow.cpp: Added. An implementation of a GL surface that renders to an X-window which redirects to a pixmap. * platform/gtk/RedirectedXCompositeWindow.h: Added. Source/WebKit/gtk: Rewrite AcceleratedCompositingContext for TextureMapperGL to be more similar to the WebKit2 LayerTreeHost and switch from rendering directly to the widget window to a window redirected to a pixmap via XComposite. The AcceleratedCompositingContext now handles painting the non-composited content itself and no longer relies on the ChromeClient backing store. This fixes issues with using GtkOverlay WebKitWebView as well as making it possible to run pixel tests with accelerated compositing turned on. * WebCoreSupport/AcceleratedCompositingContext.h: (AcceleratedCompositingContext): * WebCoreSupport/AcceleratedCompositingContextGL.cpp: Rename some methods to make them more similar to LayerTreeHost. Now we wait to render the OpenGL context to the window until the widget's draw signal. Escape out of all methods early if accelerated compositing is disabled. * WebCoreSupport/ChromeClientGtk.cpp: Always check if accelerated compositing is on before calling into AcceleratedCompositingContext methods. When AC is on, never paint the backing store, deferring immediately to the AcceleratedCompositingContext. When AC is turned on the backing store now shrinks to a small size to save memory. * webkit/webkitwebview.cpp: (resizeWebViewFromAllocation): ChromeClient is now responsible for talking to the AcceleratedCompositingContext directly. (webkit_web_view_size_allocate): Exit early if the allocation is not a resize. This makes some deeper logic a bit simpler and avoids accidentally doing too much work for widget movement. (webkit_web_view_realize): We no longer need a native window. Source/WebKit2: Add XComposite libraries to the linker list for WebKit2. * GNUmakefile.am: Add XComposite git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126182 268f45cc-cd09-0410-ab3c-d52691b4dbfc
9632d032