Chromium Code Reviews| 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 #ifndef CHROME_UTILITY_CHROME_CONTENT_UTILITY_CLIENT_H_ | 5 #ifndef CHROME_UTILITY_CHROME_CONTENT_UTILITY_CLIENT_H_ |
| 6 #define CHROME_UTILITY_CHROME_CONTENT_UTILITY_CLIENT_H_ | 6 #define CHROME_UTILITY_CHROME_CONTENT_UTILITY_CLIENT_H_ |
| 7 | 7 |
| 8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
| 9 #include "base/memory/scoped_ptr.h" | |
| 9 #include "base/memory/scoped_vector.h" | 10 #include "base/memory/scoped_vector.h" |
| 10 #include "base/platform_file.h" | 11 #include "base/platform_file.h" |
| 11 #include "chrome/common/media_galleries/picasa_types.h" | 12 #include "chrome/common/media_galleries/picasa_types.h" |
| 12 #include "content/public/utility/content_utility_client.h" | 13 #include "content/public/utility/content_utility_client.h" |
| 13 #include "ipc/ipc_platform_file.h" | 14 #include "ipc/ipc_platform_file.h" |
| 14 | 15 |
| 15 namespace base { | 16 namespace base { |
| 16 class FilePath; | 17 class FilePath; |
| 17 struct FileDescriptor; | 18 struct FileDescriptor; |
| 18 } | 19 } |
| 19 | 20 |
| 20 namespace gfx { | 21 namespace gfx { |
| 21 class Rect; | 22 class Rect; |
| 22 } | 23 } |
| 23 | 24 |
| 25 namespace metadata { | |
| 26 class IPCTunnelDataReader; | |
| 27 class MediaMetadataParser; | |
| 28 } | |
| 29 | |
| 24 namespace printing { | 30 namespace printing { |
| 25 class PdfRenderSettings; | 31 class PdfRenderSettings; |
| 26 struct PageRange; | 32 struct PageRange; |
| 27 } | 33 } |
| 28 | 34 |
| 29 namespace chrome { | 35 namespace chrome { |
| 30 | 36 |
| 31 class UtilityMessageHandler; | 37 class UtilityMessageHandler; |
| 32 | 38 |
| 33 class ChromeContentUtilityClient : public content::ContentUtilityClient { | 39 class ChromeContentUtilityClient : public content::ContentUtilityClient { |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 85 const printing::PdfRenderSettings& settings, | 91 const printing::PdfRenderSettings& settings, |
| 86 base::PlatformFile bitmap_file); | 92 base::PlatformFile bitmap_file); |
| 87 | 93 |
| 88 void OnGetPrinterCapsAndDefaults(const std::string& printer_name); | 94 void OnGetPrinterCapsAndDefaults(const std::string& printer_name); |
| 89 void OnStartupPing(); | 95 void OnStartupPing(); |
| 90 void OnAnalyzeZipFileForDownloadProtection( | 96 void OnAnalyzeZipFileForDownloadProtection( |
| 91 const IPC::PlatformFileForTransit& zip_file); | 97 const IPC::PlatformFileForTransit& zip_file); |
| 92 #if !defined(OS_ANDROID) && !defined(OS_IOS) | 98 #if !defined(OS_ANDROID) && !defined(OS_IOS) |
| 93 void OnCheckMediaFile(int64 milliseconds_of_decoding, | 99 void OnCheckMediaFile(int64 milliseconds_of_decoding, |
| 94 const IPC::PlatformFileForTransit& media_file); | 100 const IPC::PlatformFileForTransit& media_file); |
| 101 void OnParseMediaMetadata(const std::string& mime_type); | |
| 102 void OnParseMediaMetadataRequestBlobBytesFinished(int64 request_id, | |
| 103 const std::string& bytes); | |
| 95 #endif // !defined(OS_ANDROID) && !defined(OS_IOS) | 104 #endif // !defined(OS_ANDROID) && !defined(OS_IOS) |
| 96 | 105 |
| 97 #if defined(OS_WIN) | 106 #if defined(OS_WIN) |
| 98 void OnParseITunesPrefXml(const std::string& itunes_xml_data); | 107 void OnParseITunesPrefXml(const std::string& itunes_xml_data); |
| 99 #endif // defined(OS_WIN) | 108 #endif // defined(OS_WIN) |
| 100 | 109 |
| 101 #if defined(OS_MACOSX) | 110 #if defined(OS_MACOSX) |
| 102 void OnParseIPhotoLibraryXmlFile( | 111 void OnParseIPhotoLibraryXmlFile( |
| 103 const IPC::PlatformFileForTransit& iphoto_library_file); | 112 const IPC::PlatformFileForTransit& iphoto_library_file); |
| 104 #endif // defined(OS_MACOSX) | 113 #endif // defined(OS_MACOSX) |
| 105 | 114 |
| 106 #if defined(OS_WIN) || defined(OS_MACOSX) | 115 #if defined(OS_WIN) || defined(OS_MACOSX) |
| 107 void OnParseITunesLibraryXmlFile( | 116 void OnParseITunesLibraryXmlFile( |
| 108 const IPC::PlatformFileForTransit& itunes_library_file); | 117 const IPC::PlatformFileForTransit& itunes_library_file); |
| 109 | 118 |
| 110 void OnParsePicasaPMPDatabase( | 119 void OnParsePicasaPMPDatabase( |
| 111 const picasa::AlbumTableFilesForTransit& album_table_files); | 120 const picasa::AlbumTableFilesForTransit& album_table_files); |
| 112 | 121 |
| 113 void OnIndexPicasaAlbumsContents( | 122 void OnIndexPicasaAlbumsContents( |
| 114 const picasa::AlbumUIDSet& album_uids, | 123 const picasa::AlbumUIDSet& album_uids, |
| 115 const std::vector<picasa::FolderINIContents>& folders_inis); | 124 const std::vector<picasa::FolderINIContents>& folders_inis); |
| 116 #endif // defined(OS_WIN) || defined(OS_MACOSX) | 125 #endif // defined(OS_WIN) || defined(OS_MACOSX) |
| 117 | 126 |
| 118 typedef ScopedVector<UtilityMessageHandler> Handlers; | 127 typedef ScopedVector<UtilityMessageHandler> Handlers; |
| 119 Handlers handlers_; | 128 Handlers handlers_; |
| 120 | 129 |
| 130 #if !defined(OS_ANDROID) && !defined(OS_IOS) | |
| 131 scoped_ptr<metadata::MediaMetadataParser> media_metadata_parser_; | |
| 132 | |
| 133 // Owned by |media_metadata_parser_|. A reference only. | |
| 134 metadata::IPCTunnelDataReader* ipc_tunnel_data_reader_; | |
|
tommycli
2013/12/04 01:30:38
This is kind of janky. It's here because ChromeCon
tommycli
2014/01/06 20:25:11
Done.
| |
| 135 #endif // !defined(OS_ANDROID) && !defined(OS_IOS) | |
| 136 | |
| 121 DISALLOW_COPY_AND_ASSIGN(ChromeContentUtilityClient); | 137 DISALLOW_COPY_AND_ASSIGN(ChromeContentUtilityClient); |
| 122 }; | 138 }; |
| 123 | 139 |
| 124 } // namespace chrome | 140 } // namespace chrome |
| 125 | 141 |
| 126 #endif // CHROME_UTILITY_CHROME_CONTENT_UTILITY_CLIENT_H_ | 142 #endif // CHROME_UTILITY_CHROME_CONTENT_UTILITY_CLIENT_H_ |
| OLD | NEW |