Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(200)

Side by Side Diff: chrome/common/extensions/media_parser.mojom

Issue 2639503002: Convert utility process CheckMediaFile IPC to mojo (Closed)
Patch Set: Build fix: IPC::Send is now used on #ifdef WIN and OSX only. Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 // Media parsing interface provided by the utility process and exposed by 5 // Media parsing interface provided by the utility process and exposed by
6 // mojo policy control to the chrome browser process. 6 // mojo policy control to the chrome browser process.
7 7
8 module extensions.mojom; 8 module extensions.mojom;
9 9
10 import "mojo/common/file.mojom";
10 import "mojo/common/values.mojom"; 11 import "mojo/common/values.mojom";
11 12
12 struct AttachedImage { 13 struct AttachedImage {
13 string type; 14 string type;
14 array<uint8> data; 15 array<uint8> data;
15 }; 16 };
16 17
17 interface MediaParser { 18 interface MediaParser {
18 ParseMediaMetadata(string mime_type, 19 ParseMediaMetadata(string mime_type,
19 int64 total_size, 20 int64 total_size,
20 bool get_attached_images) 21 bool get_attached_images)
21 => (bool parse_success, 22 => (bool parse_success,
22 mojo.common.mojom.DictionaryValue metadata, 23 mojo.common.mojom.DictionaryValue metadata,
23 array<AttachedImage> attached_images); 24 array<AttachedImage> attached_images);
25
26 // Validate the passed media file with sanity checks, and file decoding
27 // for up to |decode_time_ms| wall clock time. Return |success| true if
28 // |file| appears to be a well-formed media file. Note: it is still not
29 // safe to decode the file in the browser process based on the returned
30 // |success|.
31 CheckMediaFile(int64 decode_time_ms, mojo.common.mojom.File file)
Sam McNally 2017/01/18 07:09:09 Use a mojo.common.mojom.TimeDelta for |decode_time
Noel Gordon 2017/01/19 06:33:11 Done (and done).
32 => (bool success);
24 }; 33 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698