Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(525)

Unified Diff: webkit/tools/test_shell/webwidget_host_gtk.cc

Issue 43058: Reverting 11396. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/tools/test_shell/webwidget_host.h ('k') | webkit/tools/test_shell/webwidget_host_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/tools/test_shell/webwidget_host_gtk.cc
===================================================================
--- webkit/tools/test_shell/webwidget_host_gtk.cc (revision 11408)
+++ webkit/tools/test_shell/webwidget_host_gtk.cc (working copy)
@@ -285,11 +285,6 @@
}
void WebWidgetHost::Paint() {
- PaintToCanvas();
- PaintCanvasToView();
-}
-
-void WebWidgetHost::PaintToCanvas() {
int width = view_->allocation.width;
int height = view_->allocation.height;
gfx::Rect client_rect(width, height);
@@ -328,17 +323,14 @@
}
DCHECK(paint_rect_.IsEmpty());
-}
-
-void WebWidgetHost::PaintCanvasToView() {
// Invalidate the paint region on the widget's underlying gdk window. Note
// that gdk_window_invalidate_* will generate extra expose events, which
// we wish to avoid. So instead we use calls to begin_paint/end_paint.
GdkRectangle grect = {
- 0,
- 0,
- canvas_->getDevice()->width(),
- canvas_->getDevice()->height(),
+ total_paint.x(),
+ total_paint.y(),
+ total_paint.width(),
+ total_paint.height(),
};
GdkWindow* window = view_->window;
gdk_window_begin_paint_rect(window, &grect);
@@ -355,16 +347,6 @@
gdk_window_end_paint(window);
}
-void WebWidgetHost::DisplayForRepaint() {
- PaintToCanvas();
-
- // Paint a gray mask over everything for the repaint Layout tests.
- const SkColor kMaskColor = SkColorSetARGB(168, 0, 0, 0); // alpha=0.66
- canvas_->drawColor(kMaskColor, SkPorterDuff::kSrcOver_Mode);
-
- PaintCanvasToView();
-}
-
void WebWidgetHost::ResetScrollRect() {
// This method is only needed for optimized scroll painting, which we don't
// care about in the test shell, yet.
« no previous file with comments | « webkit/tools/test_shell/webwidget_host.h ('k') | webkit/tools/test_shell/webwidget_host_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698