cc: Use base::Callback approach instead of using WebKit interface.
Instead of having cc/ talk directly to the WebKit::WebLayerScrollClient, we
define a callback in cc/ that it can talk to.
In the compositor_bindings, we pass this callback down to cc, so it can call us back later.
BUG=None
TEST=cc_unittests, webkit_compositor_bindings_unittests
[email protected]
Review URL: https://chromiumcodereview.appspot.com/18139004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@209386 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/cc/layers/layer.h b/cc/layers/layer.h
index 73123b9..ec0c7dc 100644
--- a/cc/layers/layer.h
+++ b/cc/layers/layer.h
@@ -30,10 +30,6 @@
#include "ui/gfx/rect_f.h"
#include "ui/gfx/transform.h"
-namespace WebKit {
-class WebLayerScrollClient;
-}
-
namespace cc {
class Animation;
@@ -233,8 +229,8 @@
return touch_event_handler_region_;
}
- void set_layer_scroll_client(WebKit::WebLayerScrollClient* client) {
- layer_scroll_client_ = client;
+ void set_did_scroll_callback(const base::Closure& callback) {
+ did_scroll_callback_ = callback;
}
void SetDrawCheckerboardForMissingTiles(bool checkerboard);
@@ -486,7 +482,7 @@
ScopedPtrVector<CopyOutputRequest> copy_requests_;
- WebKit::WebLayerScrollClient* layer_scroll_client_;
+ base::Closure did_scroll_callback_;
DrawProperties<Layer, RenderSurface> draw_properties_;