| 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 // Multiply-included message file, so no include guard. | 5 // Multiply-included message file, so no include guard. |
| 6 | 6 |
| 7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
| 8 #include <Windows.h> | 8 #include <Windows.h> |
| 9 #endif // defined(OS_WIN) | 9 #endif // defined(OS_WIN) |
| 10 | 10 |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 typedef std::vector<Tuple2<SkBitmap, base::FilePath> > DecodedImages; | 29 typedef std::vector<Tuple2<SkBitmap, base::FilePath> > DecodedImages; |
| 30 | 30 |
| 31 #endif // CHROME_COMMON_CHROME_UTILITY_MESSAGES_H_ | 31 #endif // CHROME_COMMON_CHROME_UTILITY_MESSAGES_H_ |
| 32 | 32 |
| 33 IPC_STRUCT_TRAITS_BEGIN(safe_browsing::zip_analyzer::Results) | 33 IPC_STRUCT_TRAITS_BEGIN(safe_browsing::zip_analyzer::Results) |
| 34 IPC_STRUCT_TRAITS_MEMBER(success) | 34 IPC_STRUCT_TRAITS_MEMBER(success) |
| 35 IPC_STRUCT_TRAITS_MEMBER(has_executable) | 35 IPC_STRUCT_TRAITS_MEMBER(has_executable) |
| 36 IPC_STRUCT_TRAITS_MEMBER(has_archive) | 36 IPC_STRUCT_TRAITS_MEMBER(has_archive) |
| 37 IPC_STRUCT_TRAITS_END() | 37 IPC_STRUCT_TRAITS_END() |
| 38 | 38 |
| 39 #if defined(OS_WIN) |
| 40 |
| 41 // A vector of filters, each being a Tuple2 containing a display string (i.e. |
| 42 // "Text Files") and a filter pattern (i.e. "*.txt"). |
| 43 typedef std::vector<Tuple2<base::string16, base::string16> > |
| 44 GetOpenFileNameFilter; |
| 45 |
| 46 IPC_STRUCT_BEGIN(ChromeUtilityMsg_GetSaveFileName_Params) |
| 47 IPC_STRUCT_MEMBER(HWND, owner) |
| 48 IPC_STRUCT_MEMBER(DWORD, flags) |
| 49 IPC_STRUCT_MEMBER(GetOpenFileNameFilter, filters) |
| 50 IPC_STRUCT_MEMBER(int, one_based_filter_index) |
| 51 IPC_STRUCT_MEMBER(base::FilePath, suggested_filename) |
| 52 IPC_STRUCT_MEMBER(base::FilePath, initial_directory) |
| 53 IPC_STRUCT_MEMBER(base::string16, default_extension) |
| 54 IPC_STRUCT_END() |
| 55 |
| 56 #endif // OS_WIN |
| 57 |
| 39 //------------------------------------------------------------------------------ | 58 //------------------------------------------------------------------------------ |
| 40 // Utility process messages: | 59 // Utility process messages: |
| 41 // These are messages from the browser to the utility process. | 60 // These are messages from the browser to the utility process. |
| 42 | 61 |
| 43 // Tell the utility process to parse the given JSON data and verify its | 62 // Tell the utility process to parse the given JSON data and verify its |
| 44 // validity. | 63 // validity. |
| 45 IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_UnpackWebResource, | 64 IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_UnpackWebResource, |
| 46 std::string /* JSON data */) | 65 std::string /* JSON data */) |
| 47 | 66 |
| 48 // Tell the utility process to decode the given image data. | 67 // Tell the utility process to decode the given image data. |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 87 // Tells the utility process to analyze a zip file for malicious download | 106 // Tells the utility process to analyze a zip file for malicious download |
| 88 // protection. | 107 // protection. |
| 89 IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_AnalyzeZipFileForDownloadProtection, | 108 IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_AnalyzeZipFileForDownloadProtection, |
| 90 IPC::PlatformFileForTransit /* zip_file */) | 109 IPC::PlatformFileForTransit /* zip_file */) |
| 91 #endif | 110 #endif |
| 92 | 111 |
| 93 #if defined(OS_WIN) | 112 #if defined(OS_WIN) |
| 94 IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_OpenItemViaShell, | 113 IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_OpenItemViaShell, |
| 95 base::FilePath /* full_path */) | 114 base::FilePath /* full_path */) |
| 96 | 115 |
| 97 // A vector of filters, each being a Tuple2a display string (i.e. "Text Files") | |
| 98 // and a filter pattern (i.e. "*.txt").. | |
| 99 typedef std::vector<Tuple2<base::string16, base::string16> > | |
| 100 GetOpenFileNameFilter; | |
| 101 | |
| 102 // Instructs the utility process to invoke GetOpenFileName. |owner| is the | 116 // Instructs the utility process to invoke GetOpenFileName. |owner| is the |
| 103 // parent of the modal dialog, |flags| are OFN_* flags. |filter| constrains the | 117 // parent of the modal dialog, |flags| are OFN_* flags. |filter| constrains the |
| 104 // user's file choices. |initial_directory| and |filename| select the directory | 118 // user's file choices. |initial_directory| and |filename| select the directory |
| 105 // to be displayed and the file to be initially selected. | 119 // to be displayed and the file to be initially selected. |
| 106 // | 120 // |
| 107 // Either ChromeUtilityHostMsg_GetOpenFileName_Failed or | 121 // Either ChromeUtilityHostMsg_GetOpenFileName_Failed or |
| 108 // ChromeUtilityHostMsg_GetOpenFileName_Result will be returned when the | 122 // ChromeUtilityHostMsg_GetOpenFileName_Result will be returned when the |
| 109 // operation completes whether due to error or user action. | 123 // operation completes whether due to error or user action. |
| 110 IPC_MESSAGE_CONTROL5(ChromeUtilityMsg_GetOpenFileName, | 124 IPC_MESSAGE_CONTROL5(ChromeUtilityMsg_GetOpenFileName, |
| 111 HWND /* owner */, | 125 HWND /* owner */, |
| 112 DWORD /* flags */, | 126 DWORD /* flags */, |
| 113 GetOpenFileNameFilter /* filter */, | 127 GetOpenFileNameFilter /* filter */, |
| 114 base::FilePath /* initial_directory */, | 128 base::FilePath /* initial_directory */, |
| 115 base::FilePath /* filename */) | 129 base::FilePath /* filename */) |
| 130 IPC_MESSAGE_CONTROL1(ChromeUtilityMsg_GetSaveFileName, |
| 131 ChromeUtilityMsg_GetSaveFileName_Params /* params */) |
| 116 #endif // defined(OS_WIN) | 132 #endif // defined(OS_WIN) |
| 117 | 133 |
| 118 //------------------------------------------------------------------------------ | 134 //------------------------------------------------------------------------------ |
| 119 // Utility process host messages: | 135 // Utility process host messages: |
| 120 // These are messages from the utility process to the browser. | 136 // These are messages from the utility process to the browser. |
| 121 | 137 |
| 122 // Reply when the utility process is done unpacking and parsing JSON data | 138 // Reply when the utility process is done unpacking and parsing JSON data |
| 123 // from a web resource. | 139 // from a web resource. |
| 124 IPC_MESSAGE_CONTROL1(ChromeUtilityHostMsg_UnpackWebResource_Succeeded, | 140 IPC_MESSAGE_CONTROL1(ChromeUtilityHostMsg_UnpackWebResource_Succeeded, |
| 125 base::DictionaryValue /* json data */) | 141 base::DictionaryValue /* json data */) |
| (...skipping 30 matching lines...) Expand all Loading... |
| 156 IPC_MESSAGE_CONTROL1( | 172 IPC_MESSAGE_CONTROL1( |
| 157 ChromeUtilityHostMsg_AnalyzeZipFileForDownloadProtection_Finished, | 173 ChromeUtilityHostMsg_AnalyzeZipFileForDownloadProtection_Finished, |
| 158 safe_browsing::zip_analyzer::Results) | 174 safe_browsing::zip_analyzer::Results) |
| 159 #endif | 175 #endif |
| 160 | 176 |
| 161 #if defined(OS_WIN) | 177 #if defined(OS_WIN) |
| 162 IPC_MESSAGE_CONTROL0(ChromeUtilityHostMsg_GetOpenFileName_Failed) | 178 IPC_MESSAGE_CONTROL0(ChromeUtilityHostMsg_GetOpenFileName_Failed) |
| 163 IPC_MESSAGE_CONTROL2(ChromeUtilityHostMsg_GetOpenFileName_Result, | 179 IPC_MESSAGE_CONTROL2(ChromeUtilityHostMsg_GetOpenFileName_Result, |
| 164 base::FilePath /* directory */, | 180 base::FilePath /* directory */, |
| 165 std::vector<base::FilePath> /* filenames */) | 181 std::vector<base::FilePath> /* filenames */) |
| 182 IPC_MESSAGE_CONTROL0(ChromeUtilityHostMsg_GetSaveFileName_Failed) |
| 183 IPC_MESSAGE_CONTROL2(ChromeUtilityHostMsg_GetSaveFileName_Result, |
| 184 base::FilePath /* path */, |
| 185 int /* one_based_filter_index */) |
| 166 #endif // defined(OS_WIN) | 186 #endif // defined(OS_WIN) |
| OLD | NEW |