From 29a643cfae48661a282ef72131644c62f532b06d Mon Sep 17 00:00:00 2001 From: "yuzo@chromium.org" Date: Fri, 18 Feb 2011 07:06:16 +0000 Subject: For webkit_glue::MockWebFrame, define setScrollOffset() that will be soon introduced. (by https://bugs.webkit.org/show_bug.cgi?id=54632). Otherwise, landing the WebKit patch results in Chromium build breakage. Example: .\glue\media\buffered_resource_loader_unittest.cc(87) : error C2259: 'testing::NiceMock' : cannot instantiate abstract class with [ MockClass=webkit_glue::MockWebFrame ] due to following members: 'void WebKit::WebFrame::setScrollOffset(const WebKit::WebSize &)' : is abstract c:\b\build\slave\webkit-win-latest-rel\build\src\third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h(146) : see declaration of 'WebKit::WebFrame::setScrollOffset' BUG=none TEST=none Review URL: http://codereview.chromium.org/6538049 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@75367 0039d316-1c4b-4281-b951-d872f2087c98 --- webkit/mocks/mock_webframe.cc | 2 ++ webkit/mocks/mock_webframe.h | 1 + 2 files changed, 3 insertions(+) (limited to 'webkit/mocks') diff --git a/webkit/mocks/mock_webframe.cc b/webkit/mocks/mock_webframe.cc index cf382c3..8a36e8d 100644 --- a/webkit/mocks/mock_webframe.cc +++ b/webkit/mocks/mock_webframe.cc @@ -44,6 +44,8 @@ WebSize MockWebFrame::scrollOffset() const { return WebSize(0,0); } +void MockWebFrame::setScrollOffset(const WebSize&) {} + WebSize MockWebFrame::contentsSize() const { return WebSize(); } diff --git a/webkit/mocks/mock_webframe.h b/webkit/mocks/mock_webframe.h index e49029d..cabd3c5 100644 --- a/webkit/mocks/mock_webframe.h +++ b/webkit/mocks/mock_webframe.h @@ -71,6 +71,7 @@ class MockWebFrame : public WebKit::WebFrame { virtual WebString encoding() const; virtual void setCanHaveScrollbars(bool); virtual WebSize scrollOffset() const; + virtual void setScrollOffset(const WebSize&); virtual WebSize contentsSize() const; virtual int contentsPreferredWidth() const; virtual int documentElementScrollHeight() const; -- cgit v1.1