| OLD | NEW | 
|---|
| 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 // Due to restrictions of most operating systems, we don't directly map each | 5 // Due to restrictions of most operating systems, we don't directly map each | 
| 6 // type of custom data to a native data transfer type. Instead, we serialize | 6 // type of custom data to a native data transfer type. Instead, we serialize | 
| 7 // each key-value pair into the pickle as a pair of string objects, and then | 7 // each key-value pair into the pickle as a pair of string objects, and then | 
| 8 // write the binary data in the pickle to the native data transfer object. | 8 // write the binary data in the pickle to the native data transfer object. | 
| 9 | 9 | 
| 10 #ifndef UI_BASE_CLIPBOARD_CUSTOM_DATA_HELPER_H_ | 10 #ifndef UI_BASE_CLIPBOARD_CUSTOM_DATA_HELPER_H_ | 
| (...skipping 18 matching lines...) Expand all  Loading... | 
| 29 namespace ui { | 29 namespace ui { | 
| 30 | 30 | 
| 31 #if defined(OS_MACOSX) | 31 #if defined(OS_MACOSX) | 
| 32 UI_EXPORT extern NSString* const kWebCustomDataPboardType; | 32 UI_EXPORT extern NSString* const kWebCustomDataPboardType; | 
| 33 #elif (!defined(OS_WIN) && defined(USE_AURA)) || defined(TOOLKIT_GTK) | 33 #elif (!defined(OS_WIN) && defined(USE_AURA)) || defined(TOOLKIT_GTK) | 
| 34 UI_EXPORT extern const char kMimeTypeWebCustomData[]; | 34 UI_EXPORT extern const char kMimeTypeWebCustomData[]; | 
| 35 #endif | 35 #endif | 
| 36 | 36 | 
| 37 UI_EXPORT void ReadCustomDataTypes(const void* data, | 37 UI_EXPORT void ReadCustomDataTypes(const void* data, | 
| 38                                    size_t data_length, | 38                                    size_t data_length, | 
| 39                                    std::vector<string16>* types); | 39                                    std::vector<base::string16>* types); | 
| 40 UI_EXPORT void ReadCustomDataForType(const void* data, | 40 UI_EXPORT void ReadCustomDataForType(const void* data, | 
| 41                                      size_t data_length, | 41                                      size_t data_length, | 
| 42                                      const string16& type, | 42                                      const base::string16& type, | 
| 43                                      string16* result); | 43                                      base::string16* result); | 
| 44 UI_EXPORT void ReadCustomDataIntoMap(const void* data, | 44 UI_EXPORT void ReadCustomDataIntoMap( | 
| 45                                      size_t data_length, | 45     const void* data, | 
| 46                                      std::map<string16, string16>* result); | 46     size_t data_length, | 
|  | 47     std::map<base::string16, base::string16>* result); | 
| 47 | 48 | 
| 48 UI_EXPORT void WriteCustomDataToPickle(const std::map<string16, string16>& data, | 49 UI_EXPORT void WriteCustomDataToPickle( | 
| 49                                        Pickle* pickle); | 50     const std::map<base::string16, base::string16>& data, | 
|  | 51     Pickle* pickle); | 
| 50 | 52 | 
| 51 }  // namespace ui | 53 }  // namespace ui | 
| 52 | 54 | 
| 53 #endif  // UI_BASE_CLIPBOARD_CLIPBOARD_H_ | 55 #endif  // UI_BASE_CLIPBOARD_CLIPBOARD_H_ | 
| OLD | NEW | 
|---|