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

Side by Side Diff: ui/base/dragdrop/os_exchange_data_provider_win.h

Issue 211383007: Use FilePaths in content::DropData to avoid redundant conversions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: clang-format Created 6 years, 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_DRAGDROP_OS_EXCHANGE_DATA_PROVIDER_WIN_H_ 5 #ifndef UI_BASE_DRAGDROP_OS_EXCHANGE_DATA_PROVIDER_WIN_H_
6 #define UI_BASE_DRAGDROP_OS_EXCHANGE_DATA_PROVIDER_WIN_H_ 6 #define UI_BASE_DRAGDROP_OS_EXCHANGE_DATA_PROVIDER_WIN_H_
7 7
8 #include <objidl.h> 8 #include <objidl.h>
9 #include <shlobj.h> 9 #include <shlobj.h>
10 #include <string> 10 #include <string>
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 IDataObject* data_object() const { return data_.get(); } 147 IDataObject* data_object() const { return data_.get(); }
148 IDataObjectAsyncCapability* async_operation() const { return data_.get(); } 148 IDataObjectAsyncCapability* async_operation() const { return data_.get(); }
149 149
150 // OSExchangeData::Provider methods. 150 // OSExchangeData::Provider methods.
151 virtual Provider* Clone() const; 151 virtual Provider* Clone() const;
152 virtual void MarkOriginatedFromRenderer(); 152 virtual void MarkOriginatedFromRenderer();
153 virtual bool DidOriginateFromRenderer() const; 153 virtual bool DidOriginateFromRenderer() const;
154 virtual void SetString(const base::string16& data); 154 virtual void SetString(const base::string16& data);
155 virtual void SetURL(const GURL& url, const base::string16& title); 155 virtual void SetURL(const GURL& url, const base::string16& title);
156 virtual void SetFilename(const base::FilePath& path); 156 virtual void SetFilename(const base::FilePath& path);
157 virtual void SetFilenames( 157 virtual void SetFilenames(const std::vector<FileInfo>& filenames);
158 const std::vector<OSExchangeData::FileInfo>& filenames);
159 virtual void SetPickledData(const OSExchangeData::CustomFormat& format, 158 virtual void SetPickledData(const OSExchangeData::CustomFormat& format,
160 const Pickle& data); 159 const Pickle& data);
161 virtual void SetFileContents(const base::FilePath& filename, 160 virtual void SetFileContents(const base::FilePath& filename,
162 const std::string& file_contents); 161 const std::string& file_contents);
163 virtual void SetHtml(const base::string16& html, const GURL& base_url); 162 virtual void SetHtml(const base::string16& html, const GURL& base_url);
164 163
165 virtual bool GetString(base::string16* data) const; 164 virtual bool GetString(base::string16* data) const;
166 virtual bool GetURLAndTitle(OSExchangeData::FilenameToURLPolicy policy, 165 virtual bool GetURLAndTitle(OSExchangeData::FilenameToURLPolicy policy,
167 GURL* url, 166 GURL* url,
168 base::string16* title) const; 167 base::string16* title) const;
169 virtual bool GetFilename(base::FilePath* path) const; 168 virtual bool GetFilename(base::FilePath* path) const;
170 virtual bool GetFilenames( 169 virtual bool GetFilenames(std::vector<FileInfo>* filenames) const;
171 std::vector<OSExchangeData::FileInfo>* filenames) const;
172 virtual bool GetPickledData(const OSExchangeData::CustomFormat& format, 170 virtual bool GetPickledData(const OSExchangeData::CustomFormat& format,
173 Pickle* data) const; 171 Pickle* data) const;
174 virtual bool GetFileContents(base::FilePath* filename, 172 virtual bool GetFileContents(base::FilePath* filename,
175 std::string* file_contents) const; 173 std::string* file_contents) const;
176 virtual bool GetHtml(base::string16* html, GURL* base_url) const; 174 virtual bool GetHtml(base::string16* html, GURL* base_url) const;
177 virtual bool HasString() const; 175 virtual bool HasString() const;
178 virtual bool HasURL(OSExchangeData::FilenameToURLPolicy policy) const; 176 virtual bool HasURL(OSExchangeData::FilenameToURLPolicy policy) const;
179 virtual bool HasFile() const; 177 virtual bool HasFile() const;
180 virtual bool HasFileContents() const; 178 virtual bool HasFileContents() const;
181 virtual bool HasHtml() const; 179 virtual bool HasHtml() const;
(...skipping 17 matching lines...) Expand all
199 gfx::ImageSkia drag_image_; 197 gfx::ImageSkia drag_image_;
200 gfx::Vector2d drag_image_offset_; 198 gfx::Vector2d drag_image_offset_;
201 #endif 199 #endif
202 200
203 DISALLOW_COPY_AND_ASSIGN(OSExchangeDataProviderWin); 201 DISALLOW_COPY_AND_ASSIGN(OSExchangeDataProviderWin);
204 }; 202 };
205 203
206 } // namespace ui 204 } // namespace ui
207 205
208 #endif // UI_BASE_DRAGDROP_OS_EXCHANGE_DATA_PROVIDER_WIN_H_ 206 #endif // UI_BASE_DRAGDROP_OS_EXCHANGE_DATA_PROVIDER_WIN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698