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

Unified Diff: ui/views/mus/clipboard_mus.h

Issue 2504403004: Mojo C++ bindings: switch the generated code of clipboard.mojom to use STL types. (Closed)
Patch Set: . Created 4 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 side-by-side diff with in-line comments
Download patch
Index: ui/views/mus/clipboard_mus.h
diff --git a/ui/views/mus/clipboard_mus.h b/ui/views/mus/clipboard_mus.h
index 9ba378b59d6a6092a27819793e53d658b91b8244..e3d016cf26bb8cda74700c2a27fb11139831aed8 100644
--- a/ui/views/mus/clipboard_mus.h
+++ b/ui/views/mus/clipboard_mus.h
@@ -25,7 +25,7 @@ class VIEWS_MUS_EXPORT ClipboardMus : public ui::Clipboard {
void Init(service_manager::Connector* connector);
private:
- bool HasMimeType(const mojo::Array<mojo::String>& available_types,
+ bool HasMimeType(const std::vector<std::string>& available_types,
const std::string& type) const;
// Clipboard overrides:
@@ -68,7 +68,7 @@ class VIEWS_MUS_EXPORT ClipboardMus : public ui::Clipboard {
const char* data_data,
size_t data_len) override;
- static mojo::String GetMimeTypeFor(const FormatType& format);
+ static std::string GetMimeTypeFor(const FormatType& format);
ui::mojom::ClipboardPtr clipboard_;
@@ -76,7 +76,7 @@ class VIEWS_MUS_EXPORT ClipboardMus : public ui::Clipboard {
// WriteObjects(), which then calls our base class DispatchObject() which
// then calls into each data type specific Write() function. Once we've
// collected all the data types, we then pass this to the mus server.
- std::unique_ptr<mojo::Map<mojo::String, mojo::Array<uint8_t>>>
+ base::Optional<std::unordered_map<std::string, std::vector<uint8_t>>>
current_clipboard_;
DISALLOW_COPY_AND_ASSIGN(ClipboardMus);

Powered by Google App Engine
This is Rietveld 408576698