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

Side by Side Diff: chrome/common/extensions/api/cast_devices_private.idl

Issue 1291113002: Cast extension private API for ChromeOS system tray. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Address change requests Created 5 years, 4 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
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // The <code>chrome.cast.devicesPrivate</code> API manages starting and stopping
6 // casts based on receiver names. It also provides a list of available
7 // receivers.
8 namespace cast.devicesPrivate {
9 // A cast receiver is an actual cast device. It has a unique |id| and a
10 // non-unique |name| which is how people identify it.
11 dictionary Receiver {
12 // The unique id of a receiver.
13 DOMString id;
14
15 // The human-readable name of the receiver.
16 DOMString name;
17 };
18
19 // An activity represents what a receiver is currently doing.
20 dictionary Activity {
21 // The unique id for the activity.
22 DOMString id;
23
24 // The human-readable title of the activity.
25 DOMString title;
26
27 // Where did this activity originate from? For >=0 values, then this is the
28 // tab identifier. For <0 values, each value has a special meaning.
29 long tabId;
30 };
31
32 // A receiver with its associated activity. This is a 1-1 mapping.
33 dictionary ReceiverActivity {
34 // The current receiver.
35 Receiver receiver;
36
37 // Its associated activity, if any.
38 Activity? activity;
39 };
40
41 interface Functions {
42 // Update the state of all of the cast devices and their associated
43 // activities.
44 //
45 // |devices|: Every single receivers with its associated activities, if any.
46 static void updateDevices(ReceiverActivity[] devices);
47 };
48
49 interface Events {
50 // Request a refresh of the device states.
51 [maxListeners=1] static void updateDevicesRequested();
52
53 // Stops a cast. This should always be a user-initiated stop.
54 static void stopCast(DOMString reason);
55
56 // Starts a new cast.
57 //
58 // |receiverId|: The receiver ID to initiate a cast on. The implementation
59 // will handle selecting an appropriate activity.
60 static void startCast(DOMString receiverId);
61 };
62 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698