Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[GTK] GTK2 paint code path does not render AC layers
https://bugs.webkit.org/show_bug.cgi?id=124967

Patch by Gustavo Noronha Silva <gustavo.noronha@collabora.com> on 2013-12-02
Reviewed by Carlos Garcia Campos.

* webkit/webkitwebview.cpp:
(webkit_web_view_expose_event): also paint AC layers when painting the widget,
when AC is on.

Canonical link: https://commits.webkit.org/143170@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@159926 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
Gustavo Noronha Silva authored and kov committed Dec 2, 2013
1 parent f23d98b commit a5657c7
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Source/WebKit/gtk/ChangeLog
@@ -1,3 +1,14 @@
2013-12-02 Gustavo Noronha Silva <gustavo.noronha@collabora.com>

[GTK] GTK2 paint code path does not render AC layers
https://bugs.webkit.org/show_bug.cgi?id=124967

Reviewed by Carlos Garcia Campos.

* webkit/webkitwebview.cpp:
(webkit_web_view_expose_event): also paint AC layers when painting the widget,
when AC is on.

2013-11-28 Gustavo Noronha Silva <gustavo.noronha@collabora.com>

REGRESSION(r154658): webkit_web_view_get_view_source_mode always returns false
Expand Down
11 changes: 11 additions & 0 deletions Source/WebKit/gtk/webkit/webkitwebview.cpp
Expand Up @@ -671,6 +671,17 @@ static gboolean webkit_web_view_expose_event(GtkWidget* widget, GdkEventExpose*
gdk_region_get_rectangles(event->region, &rects.outPtr(), &rectCount);

RefPtr<cairo_t> cr = adoptRef(gdk_cairo_create(event->window));

WebKitWebViewPrivate* priv = WEBKIT_WEB_VIEW(widget)->priv;
#if USE(TEXTURE_MAPPER)
GdkRectangle clipRect;
gdk_region_get_clipbox(event->region, &clipRect);
if (priv->acceleratedCompositingContext->renderLayersToWindow(cr.get(), clipRect)) {
GTK_WIDGET_CLASS(webkit_web_view_parent_class)->expose_event(widget, event);
return FALSE;
}
#endif

for (int i = 0; i < rectCount; i++) {
copyRectFromCairoSurfaceToContext(WEBKIT_WEB_VIEW(widget)->priv->backingStore->cairoSurface(),
cr.get(), IntSize(), IntRect(rects.get()[i]));
Expand Down

0 comments on commit a5657c7

Please sign in to comment.