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

Side by Side Diff: ui/base/clipboard/clipboard_win.h

Issue 720373003: Add FakeClipboard implementation for unit tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: One more fix... Created 6 years, 1 month 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef UI_BASE_CLIPBOARD_CLIPBOARD_WIN_H_ 5 #ifndef UI_BASE_CLIPBOARD_CLIPBOARD_WIN_H_
6 #define UI_BASE_CLIPBOARD_CLIPBOARD_WIN_H_ 6 #define UI_BASE_CLIPBOARD_CLIPBOARD_WIN_H_
7 7
8 #include "ui/base/clipboard/clipboard.h" 8 #include "ui/base/clipboard/clipboard.h"
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 11
12 namespace ui { 12 namespace ui {
13 13
14 class ClipboardWin : public Clipboard { 14 class ClipboardWin : public Clipboard {
15 private: 15 private:
16 friend class Clipboard; 16 friend class Clipboard;
17 17
18 ClipboardWin(); 18 ClipboardWin();
19 ~ClipboardWin() override; 19 ~ClipboardWin() override;
20 20
21 // Clipboard overrides: 21 // Clipboard overrides:
22 uint64 GetSequenceNumber(ClipboardType type) override; 22 uint64 GetSequenceNumber(ClipboardType type) const override;
23 bool IsFormatAvailable(const FormatType& format, 23 bool IsFormatAvailable(const FormatType& format,
24 ClipboardType type) const override; 24 ClipboardType type) const override;
25 void Clear(ClipboardType type) override; 25 void Clear(ClipboardType type) override;
26 void ReadAvailableTypes(ClipboardType type, 26 void ReadAvailableTypes(ClipboardType type,
27 std::vector<base::string16>* types, 27 std::vector<base::string16>* types,
28 bool* contains_filenames) const override; 28 bool* contains_filenames) const override;
29 void ReadText(ClipboardType type, base::string16* result) const override; 29 void ReadText(ClipboardType type, base::string16* result) const override;
30 void ReadAsciiText(ClipboardType type, std::string* result) const override; 30 void ReadAsciiText(ClipboardType type, std::string* result) const override;
31 void ReadHTML(ClipboardType type, 31 void ReadHTML(ClipboardType type,
32 base::string16* markup, 32 base::string16* markup,
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 68
69 // Mark this as mutable so const methods can still do lazy initialization. 69 // Mark this as mutable so const methods can still do lazy initialization.
70 mutable scoped_ptr<base::win::MessageWindow> clipboard_owner_; 70 mutable scoped_ptr<base::win::MessageWindow> clipboard_owner_;
71 71
72 DISALLOW_COPY_AND_ASSIGN(ClipboardWin); 72 DISALLOW_COPY_AND_ASSIGN(ClipboardWin);
73 }; 73 };
74 74
75 } // namespace ui 75 } // namespace ui
76 76
77 #endif // UI_BASE_CLIPBOARD_CLIPBOARD_WIN_H_ 77 #endif // UI_BASE_CLIPBOARD_CLIPBOARD_WIN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698