OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 // A struct for managing data being dropped on a WebContents. This represents | 5 // A struct for managing data being dropped on a WebContents. This represents |
6 // a union of all the types of data that can be dropped in a platform neutral | 6 // a union of all the types of data that can be dropped in a platform neutral |
7 // way. | 7 // way. |
8 | 8 |
9 #ifndef CONTENT_PUBLIC_COMMON_DROP_DATA_H_ | 9 #ifndef CONTENT_PUBLIC_COMMON_DROP_DATA_H_ |
10 #define CONTENT_PUBLIC_COMMON_DROP_DATA_H_ | 10 #define CONTENT_PUBLIC_COMMON_DROP_DATA_H_ |
11 | 11 |
12 #include <stdint.h> | 12 #include <stdint.h> |
13 | 13 |
14 #include <map> | 14 #include <map> |
15 #include <string> | 15 #include <string> |
16 #include <vector> | 16 #include <vector> |
17 | 17 |
18 #include "base/strings/nullable_string16.h" | 18 #include "base/strings/nullable_string16.h" |
19 #include "content/common/content_export.h" | 19 #include "content/common/content_export.h" |
20 #include "third_party/WebKit/public/platform/WebReferrerPolicy.h" | 20 #include "third_party/WebKit/public/platform/WebReferrerPolicy.h" |
21 #include "ui/base/dragdrop/file_info.h" | 21 #include "ui/base/dragdrop/file_info.h" |
22 #include "url/gurl.h" | 22 #include "url/gurl.h" |
23 | 23 |
24 namespace content { | 24 namespace content { |
25 | 25 |
| 26 typedef std::pair<base::string16, base::string16> MimeTypeKindPair; |
| 27 |
26 struct CONTENT_EXPORT DropData { | 28 struct CONTENT_EXPORT DropData { |
27 struct FileSystemFileInfo { | 29 struct FileSystemFileInfo { |
28 FileSystemFileInfo() : size(0) {} | 30 FileSystemFileInfo() : size(0) {} |
29 ~FileSystemFileInfo() {} | 31 ~FileSystemFileInfo() {} |
30 | 32 |
31 GURL url; | 33 GURL url; |
32 int64_t size; | 34 int64_t size; |
33 }; | 35 }; |
34 | 36 |
35 DropData(); | 37 DropData(); |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 // User is dragging data from the webview (e.g., an image). | 75 // User is dragging data from the webview (e.g., an image). |
74 base::string16 file_description_filename; | 76 base::string16 file_description_filename; |
75 std::string file_contents; | 77 std::string file_contents; |
76 | 78 |
77 std::map<base::string16, base::string16> custom_data; | 79 std::map<base::string16, base::string16> custom_data; |
78 }; | 80 }; |
79 | 81 |
80 } // namespace content | 82 } // namespace content |
81 | 83 |
82 #endif // CONTENT_PUBLIC_COMMON_DROP_DATA_H_ | 84 #endif // CONTENT_PUBLIC_COMMON_DROP_DATA_H_ |
OLD | NEW |