| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "ui/views/mus/os_exchange_data_provider_mus.h" |
| 6 |
| 7 namespace views { |
| 8 |
| 9 OSExchangeDataProviderMus::OSExchangeDataProviderMus() {} |
| 10 |
| 11 OSExchangeDataProviderMus::~OSExchangeDataProviderMus() {} |
| 12 |
| 13 std::unique_ptr<ui::OSExchangeData::Provider> |
| 14 OSExchangeDataProviderMus::Clone() const { |
| 15 return std::unique_ptr<ui::OSExchangeData::Provider>(); |
| 16 } |
| 17 |
| 18 void OSExchangeDataProviderMus::MarkOriginatedFromRenderer() { |
| 19 } |
| 20 |
| 21 bool OSExchangeDataProviderMus::DidOriginateFromRenderer() const { |
| 22 return false; |
| 23 } |
| 24 |
| 25 void OSExchangeDataProviderMus::SetString(const base::string16& data) { |
| 26 } |
| 27 |
| 28 void OSExchangeDataProviderMus::SetURL(const GURL& url, |
| 29 const base::string16& title) { |
| 30 } |
| 31 |
| 32 void OSExchangeDataProviderMus::SetFilename(const base::FilePath& path) { |
| 33 } |
| 34 |
| 35 void OSExchangeDataProviderMus::SetFilenames( |
| 36 const std::vector<ui::FileInfo>& file_names) { |
| 37 } |
| 38 |
| 39 void OSExchangeDataProviderMus::SetPickledData( |
| 40 const ui::Clipboard::FormatType& format, |
| 41 const base::Pickle& data) { |
| 42 } |
| 43 |
| 44 bool OSExchangeDataProviderMus::GetString(base::string16* data) const { |
| 45 return false; |
| 46 } |
| 47 |
| 48 bool OSExchangeDataProviderMus::GetURLAndTitle( |
| 49 ui::OSExchangeData::FilenameToURLPolicy policy, |
| 50 GURL* url, |
| 51 base::string16* title) const { |
| 52 return false; |
| 53 } |
| 54 |
| 55 bool OSExchangeDataProviderMus::GetFilename(base::FilePath* path) const { |
| 56 return false; |
| 57 } |
| 58 |
| 59 bool OSExchangeDataProviderMus::GetFilenames( |
| 60 std::vector<ui::FileInfo>* file_names) const { |
| 61 return false; |
| 62 } |
| 63 |
| 64 bool OSExchangeDataProviderMus::GetPickledData( |
| 65 const ui::Clipboard::FormatType& format, |
| 66 base::Pickle* data) const { |
| 67 return false; |
| 68 } |
| 69 |
| 70 bool OSExchangeDataProviderMus::HasString() const { |
| 71 return false; |
| 72 } |
| 73 |
| 74 bool OSExchangeDataProviderMus::HasURL( |
| 75 ui::OSExchangeData::FilenameToURLPolicy policy) const { |
| 76 return false; |
| 77 } |
| 78 |
| 79 bool OSExchangeDataProviderMus::HasFile() const { |
| 80 return false; |
| 81 } |
| 82 |
| 83 bool OSExchangeDataProviderMus::HasCustomFormat( |
| 84 const ui::Clipboard::FormatType& format) const { |
| 85 return false; |
| 86 } |
| 87 |
| 88 // These methods were added in an ad-hoc way to different operating |
| 89 // systems. We need to support them until they get cleaned up. |
| 90 #if (!defined(OS_CHROMEOS) && defined(USE_X11)) || defined(OS_WIN) |
| 91 void OSExchangeDataProviderMus::SetFileContents( |
| 92 const base::FilePath& filename, |
| 93 const std::string& file_contents) { |
| 94 |
| 95 } |
| 96 #endif |
| 97 |
| 98 #if defined(OS_WIN) |
| 99 bool OSExchangeDataProviderMus::GetFileContents( |
| 100 base::FilePath* filename, |
| 101 std::string* file_contents) const { |
| 102 return false; |
| 103 } |
| 104 |
| 105 bool OSExchangeDataProviderMus::HasFileContents() const { |
| 106 return false; |
| 107 } |
| 108 |
| 109 void OSExchangeDataProviderMus::SetDownloadFileInfo( |
| 110 const ui::OSExchangeData::DownloadFileInfo& download) { |
| 111 } |
| 112 #endif |
| 113 |
| 114 #if defined(USE_AURA) |
| 115 void OSExchangeDataProviderMus::SetHtml(const base::string16& html, |
| 116 const GURL& base_url) { |
| 117 |
| 118 } |
| 119 |
| 120 bool OSExchangeDataProviderMus::GetHtml(base::string16* html, |
| 121 GURL* base_url) const { |
| 122 return false; |
| 123 } |
| 124 |
| 125 bool OSExchangeDataProviderMus::HasHtml() const { |
| 126 return false; |
| 127 } |
| 128 #endif |
| 129 |
| 130 #if defined(USE_AURA) || defined(OS_MACOSX) |
| 131 void OSExchangeDataProviderMus::SetDragImage( |
| 132 const gfx::ImageSkia& image, |
| 133 const gfx::Vector2d& cursor_offset) { |
| 134 drag_image_ = image; |
| 135 drag_image_offset_ = cursor_offset; |
| 136 } |
| 137 |
| 138 const gfx::ImageSkia& OSExchangeDataProviderMus::GetDragImage() const { |
| 139 return drag_image_; |
| 140 } |
| 141 |
| 142 const gfx::Vector2d& OSExchangeDataProviderMus::GetDragImageOffset() const { |
| 143 return drag_image_offset_; |
| 144 } |
| 145 #endif |
| 146 |
| 147 } // namespace views |
| OLD | NEW |