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

Side by Side Diff: webkit/tools/test_shell/mock_webclipboard_impl.h

Issue 8305012: Remove deprecated WebClipboard::readHTML method. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: . Created 9 years, 2 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 unified diff | Download patch
« no previous file with comments | « webkit/glue/webclipboard_impl.cc ('k') | webkit/tools/test_shell/mock_webclipboard_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 // 4 //
5 // This file mocks out just enough of the WebClipboard API for running the 5 // This file mocks out just enough of the WebClipboard API for running the
6 // webkit tests. This is so we can run webkit tests without them sharing a 6 // webkit tests. This is so we can run webkit tests without them sharing a
7 // clipboard, which allows for running them in parallel and having the tests 7 // clipboard, which allows for running them in parallel and having the tests
8 // not interact with actual user actions. 8 // not interact with actual user actions.
9 9
10 #ifndef WEBKIT_TOOLS_TEST_SHELL_MOCK_WEBCLIPBOARD_IMPL_H_ 10 #ifndef WEBKIT_TOOLS_TEST_SHELL_MOCK_WEBCLIPBOARD_IMPL_H_
11 #define WEBKIT_TOOLS_TEST_SHELL_MOCK_WEBCLIPBOARD_IMPL_H_ 11 #define WEBKIT_TOOLS_TEST_SHELL_MOCK_WEBCLIPBOARD_IMPL_H_
12 12
13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebClipboard.h" 13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebClipboard.h"
14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebImage.h" 14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebImage.h"
15 15
16 class MockWebClipboardImpl : public WebKit::WebClipboard { 16 class MockWebClipboardImpl : public WebKit::WebClipboard {
17 public: 17 public:
18 MockWebClipboardImpl(); 18 MockWebClipboardImpl();
19 ~MockWebClipboardImpl(); 19 ~MockWebClipboardImpl();
20 20
21 virtual bool isFormatAvailable(WebKit::WebClipboard::Format, 21 virtual bool isFormatAvailable(WebKit::WebClipboard::Format,
22 WebKit::WebClipboard::Buffer); 22 WebKit::WebClipboard::Buffer);
23 23
24 virtual WebKit::WebString readPlainText(WebKit::WebClipboard::Buffer); 24 virtual WebKit::WebString readPlainText(WebKit::WebClipboard::Buffer);
25 virtual WebKit::WebString readHTML(WebKit::WebClipboard::Buffer, 25 virtual WebKit::WebString readHTML(WebKit::WebClipboard::Buffer,
26 WebKit::WebURL*);
27 virtual WebKit::WebString readHTML(WebKit::WebClipboard::Buffer,
28 WebKit::WebURL*, 26 WebKit::WebURL*,
29 unsigned* fragmentStart, 27 unsigned* fragmentStart,
30 unsigned* fragmentEnd); 28 unsigned* fragmentEnd);
31 virtual WebKit::WebData readImage(WebKit::WebClipboard::Buffer); 29 virtual WebKit::WebData readImage(WebKit::WebClipboard::Buffer);
32 30
33 virtual void writePlainText(const WebKit::WebString& plain_text); 31 virtual void writePlainText(const WebKit::WebString& plain_text);
34 virtual void writeHTML( 32 virtual void writeHTML(
35 const WebKit::WebString& htmlText, const WebKit::WebURL&, 33 const WebKit::WebString& htmlText, const WebKit::WebURL&,
36 const WebKit::WebString& plainText, bool writeSmartPaste); 34 const WebKit::WebString& plainText, bool writeSmartPaste);
37 virtual void writeURL( 35 virtual void writeURL(
38 const WebKit::WebURL&, const WebKit::WebString& title); 36 const WebKit::WebURL&, const WebKit::WebString& title);
39 virtual void writeImage( 37 virtual void writeImage(
40 const WebKit::WebImage&, const WebKit::WebURL&, 38 const WebKit::WebImage&, const WebKit::WebURL&,
41 const WebKit::WebString& title); 39 const WebKit::WebString& title);
42 40
43 virtual WebKit::WebVector<WebKit::WebString> readAvailableTypes( 41 virtual WebKit::WebVector<WebKit::WebString> readAvailableTypes(
44 WebKit::WebClipboard::Buffer, bool* containsFilenames); 42 WebKit::WebClipboard::Buffer, bool* containsFilenames);
45 43
46 private: 44 private:
47 WebKit::WebString m_plainText; 45 WebKit::WebString m_plainText;
48 WebKit::WebString m_htmlText; 46 WebKit::WebString m_htmlText;
49 WebKit::WebImage m_image; 47 WebKit::WebImage m_image;
50 bool m_writeSmartPaste; 48 bool m_writeSmartPaste;
51 }; 49 };
52 50
53 #endif // WEBKIT_TOOLS_TEST_SHELL_MOCK_WEBCLIPBOARD_IMPL_H_ 51 #endif // WEBKIT_TOOLS_TEST_SHELL_MOCK_WEBCLIPBOARD_IMPL_H_
OLDNEW
« no previous file with comments | « webkit/glue/webclipboard_impl.cc ('k') | webkit/tools/test_shell/mock_webclipboard_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698