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

Side by Side Diff: chrome/browser/resources/media_router/media_router_ui_interface.js

Issue 1415103006: Non-Local Join for Media Router and Presentation API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing ChromeOS System Tray Test Created 4 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 2015 The Chromium Authors. All rights reserved. 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 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 // API invoked by the browser MediaRouterWebUIMessageHandler to communicate 5 // API invoked by the browser MediaRouterWebUIMessageHandler to communicate
6 // with this UI. 6 // with this UI.
7 cr.define('media_router.ui', function() { 7 cr.define('media_router.ui', function() {
8 'use strict'; 8 'use strict';
9 9
10 // The media-router-container element. 10 // The media-router-container element.
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 /** 135 /**
136 * Closes the given route. 136 * Closes the given route.
137 * 137 *
138 * @param {!media_router.Route} route 138 * @param {!media_router.Route} route
139 */ 139 */
140 function closeRoute(route) { 140 function closeRoute(route) {
141 chrome.send('closeRoute', [{routeId: route.id, isLocal: route.isLocal}]); 141 chrome.send('closeRoute', [{routeId: route.id, isLocal: route.isLocal}]);
142 } 142 }
143 143
144 /** 144 /**
145 * Joins the given route.
146 *
147 * @param {!media_router.Route} route
148 */
149 function joinRoute(route) {
150 chrome.send('joinRoute', [{sinkId: route.sinkId, routeId: route.id}]);
151 }
152
153 /**
145 * Indicates that the initial data has been received. 154 * Indicates that the initial data has been received.
146 */ 155 */
147 function onInitialDataReceived() { 156 function onInitialDataReceived() {
148 chrome.send('onInitialDataReceived'); 157 chrome.send('onInitialDataReceived');
149 } 158 }
150 159
151 /** 160 /**
152 * Reports the index of the selected sink. 161 * Reports the index of the selected sink.
153 * 162 *
154 * @param {number} sinkIndex 163 * @param {number} sinkIndex
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 */ 210 */
202 function requestRoute(sinkId, selectedCastMode) { 211 function requestRoute(sinkId, selectedCastMode) {
203 chrome.send('requestRoute', 212 chrome.send('requestRoute',
204 [{sinkId: sinkId, selectedCastMode: selectedCastMode}]); 213 [{sinkId: sinkId, selectedCastMode: selectedCastMode}]);
205 } 214 }
206 215
207 return { 216 return {
208 actOnIssue: actOnIssue, 217 actOnIssue: actOnIssue,
209 closeDialog: closeDialog, 218 closeDialog: closeDialog,
210 closeRoute: closeRoute, 219 closeRoute: closeRoute,
220 joinRoute: joinRoute,
211 onInitialDataReceived: onInitialDataReceived, 221 onInitialDataReceived: onInitialDataReceived,
212 reportClickedSinkIndex: reportClickedSinkIndex, 222 reportClickedSinkIndex: reportClickedSinkIndex,
213 reportNavigateToView: reportNavigateToView, 223 reportNavigateToView: reportNavigateToView,
214 reportSelectedCastMode: reportSelectedCastMode, 224 reportSelectedCastMode: reportSelectedCastMode,
215 reportSinkCount: reportSinkCount, 225 reportSinkCount: reportSinkCount,
216 requestInitialData: requestInitialData, 226 requestInitialData: requestInitialData,
217 requestRoute: requestRoute, 227 requestRoute: requestRoute,
218 }; 228 };
219 }); 229 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/media_router/media_router_data.js ('k') | chrome/browser/ui/ash/cast_config_delegate_media_router.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698