summaryrefslogtreecommitdiffstats
path: root/chrome/common
diff options
context:
space:
mode:
authortommycli@chromium.org <tommycli@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-13 22:38:42 +0000
committertommycli@chromium.org <tommycli@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-13 22:38:42 +0000
commitc5e85fce6e861f2291ea7462990461aa606152c9 (patch)
tree431f0817a448cd8eb50e6e6a402e69733ace99b9 /chrome/common
parent7beed4b304055ace4da0fac82a0f88135100fc9b (diff)
downloadchromium_src-c5e85fce6e861f2291ea7462990461aa606152c9.zip
chromium_src-c5e85fce6e861f2291ea7462990461aa606152c9.tar.gz
chromium_src-c5e85fce6e861f2291ea7462990461aa606152c9.tar.bz2
Media Galleries API: Audio/Video attached pictures. IPC portion only.
This is a subset of Patchset 13 of https://codereview.chromium.org/250143002/. Intent is to try to get the less controversial portions of patch reviewed and committed so we can focus on the 'hard' part. Depends on https://codereview.chromium.org/270873003/ landing. BUG=304290 Review URL: https://codereview.chromium.org/278933003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@270228 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common')
-rw-r--r--chrome/common/chrome_utility_messages.h21
-rw-r--r--chrome/common/media_galleries/metadata_types.h19
2 files changed, 35 insertions, 5 deletions
diff --git a/chrome/common/chrome_utility_messages.h b/chrome/common/chrome_utility_messages.h
index c375565..c6da23b 100644
--- a/chrome/common/chrome_utility_messages.h
+++ b/chrome/common/chrome_utility_messages.h
@@ -16,6 +16,7 @@
#include "chrome/common/extensions/update_manifest.h"
#include "chrome/common/media_galleries/iphoto_library.h"
#include "chrome/common/media_galleries/itunes_library.h"
+#include "chrome/common/media_galleries/metadata_types.h"
#include "chrome/common/media_galleries/picasa_types.h"
#include "chrome/common/safe_browsing/zip_analyzer.h"
#include "ipc/ipc_message_macros.h"
@@ -147,6 +148,13 @@ IPC_STRUCT_TRAITS_BEGIN(picasa::FolderINIContents)
IPC_STRUCT_TRAITS_END()
#endif // defined(OS_WIN) || defined(OS_MACOSX)
+#if !defined(OS_ANDROID) && !defined(OS_IOS)
+IPC_STRUCT_TRAITS_BEGIN(metadata::AttachedImage)
+ IPC_STRUCT_TRAITS_MEMBER(type)
+ IPC_STRUCT_TRAITS_MEMBER(data)
+IPC_STRUCT_TRAITS_END()
+#endif // !defined(OS_ANDROID) && !defined(OS_IOS)
+
//------------------------------------------------------------------------------
// Utility process messages:
// These are messages from the browser to the utility process.
@@ -291,9 +299,10 @@ IPC_MESSAGE_CONTROL2(ChromeUtilityMsg_CheckMediaFile,
int64 /* milliseconds_of_decoding */,
IPC::PlatformFileForTransit /* Media file to parse */)
-IPC_MESSAGE_CONTROL2(ChromeUtilityMsg_ParseMediaMetadata,
+IPC_MESSAGE_CONTROL3(ChromeUtilityMsg_ParseMediaMetadata,
std::string /* mime_type */,
- int64 /* total_size */)
+ int64 /* total_size */,
+ bool /* get_attached_images */)
IPC_MESSAGE_CONTROL2(ChromeUtilityMsg_RequestBlobBytes_Finished,
int64 /* request_id */,
@@ -481,9 +490,11 @@ IPC_MESSAGE_CONTROL1(ChromeUtilityHostMsg_IndexPicasaAlbumsContents_Finished,
IPC_MESSAGE_CONTROL1(ChromeUtilityHostMsg_CheckMediaFile_Finished,
bool /* passed_checks */)
-IPC_MESSAGE_CONTROL2(ChromeUtilityHostMsg_ParseMediaMetadata_Finished,
- bool /* parse_success */,
- base::DictionaryValue /* metadata */)
+IPC_MESSAGE_CONTROL3(
+ ChromeUtilityHostMsg_ParseMediaMetadata_Finished,
+ bool /* parse_success */,
+ base::DictionaryValue /* metadata */,
+ std::vector<metadata::AttachedImage> /* attached_images */)
IPC_MESSAGE_CONTROL3(ChromeUtilityHostMsg_RequestBlobBytes,
int64 /* request_id */,
diff --git a/chrome/common/media_galleries/metadata_types.h b/chrome/common/media_galleries/metadata_types.h
new file mode 100644
index 0000000..d9aa515
--- /dev/null
+++ b/chrome/common/media_galleries/metadata_types.h
@@ -0,0 +1,19 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_COMMON_MEDIA_GALLERIES_METADATA_TYPES_H_
+#define CHROME_COMMON_MEDIA_GALLERIES_METADATA_TYPES_H_
+
+#include <string>
+
+namespace metadata {
+
+struct AttachedImage {
+ std::string type;
+ std::string data;
+};
+
+} // namespace metadata
+
+#endif // CHROME_COMMON_MEDIA_GALLERIES_METADATA_TYPES_H_