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

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

Issue 2938173004: [Media Router] Add a supports_web_ui_controller attribute to MediaRoute (Closed)
Patch Set: Rebase Created 3 years, 6 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 // Any strings used here will already be localized. Values such as 5 // Any strings used here will already be localized. Values such as
6 // CastMode.type or IDs will be defined elsewhere and determined later. 6 // CastMode.type or IDs will be defined elsewhere and determined later.
7 7
8 cr.exportPath('media_router'); 8 cr.exportPath('media_router');
9 9
10 /** 10 /**
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 /** @type {?string} */ 175 /** @type {?string} */
176 this.routeId = routeId; 176 this.routeId = routeId;
177 177
178 /** @type {boolean} */ 178 /** @type {boolean} */
179 this.isBlocking = isBlocking; 179 this.isBlocking = isBlocking;
180 180
181 /** @type {?number} */ 181 /** @type {?number} */
182 this.helpPageId = helpPageId; 182 this.helpPageId = helpPageId;
183 }; 183 };
184 184
185
186 /** 185 /**
187 * @param {string} id The media route ID. 186 * @param {string} id The media route ID.
188 * @param {string} sinkId The ID of the media sink running this route. 187 * @param {string} sinkId The ID of the media sink running this route.
189 * @param {string} description The short description of this route. 188 * @param {string} description The short description of this route.
190 * @param {?number} tabId The ID of the tab in which web app is running and 189 * @param {?number} tabId The ID of the tab in which web app is running and
191 * accessing the route. 190 * accessing the route.
192 * @param {boolean} isLocal True if this is a locally created route. 191 * @param {boolean} isLocal True if this is a locally created route.
193 * @param {boolean} canJoin True if this route can be joined. 192 * @param {boolean} canJoin True if this route can be joined.
194 * @param {?string} customControllerPath non-empty if this route has custom 193 * @param {?string} customControllerPath non-empty if this route has custom
195 * controller. 194 * controller.
(...skipping 18 matching lines...) Expand all
214 this.isLocal = isLocal; 213 this.isLocal = isLocal;
215 214
216 /** @type {boolean} */ 215 /** @type {boolean} */
217 this.canJoin = canJoin; 216 this.canJoin = canJoin;
218 217
219 /** @type {number|undefined} */ 218 /** @type {number|undefined} */
220 this.currentCastMode = undefined; 219 this.currentCastMode = undefined;
221 220
222 /** @type {?string} */ 221 /** @type {?string} */
223 this.customControllerPath = customControllerPath; 222 this.customControllerPath = customControllerPath;
223
224 /** @type {boolean} */
225 this.supportsWebUiController = false;
224 }; 226 };
225 227
226 /** 228 /**
227 * @param {string} title The title of the route. 229 * @param {string} title The title of the route.
228 * @param {string} description A description for the route. 230 * @param {string} description A description for the route.
229 * @param {boolean} canPlayPause Whether the route can be played/paused. 231 * @param {boolean} canPlayPause Whether the route can be played/paused.
230 * @param {boolean} canMute Whether the route can be muted/unmuted. 232 * @param {boolean} canMute Whether the route can be muted/unmuted.
231 * @param {boolean} canSetVolume Whether the route volume can be changed. 233 * @param {boolean} canSetVolume Whether the route volume can be changed.
232 * @param {boolean} canSeek Whether the route's playback position can be 234 * @param {boolean} canSeek Whether the route's playback position can be
233 * changed. 235 * changed.
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
271 /** @type {number} */ 273 /** @type {number} */
272 this.volume = volume; 274 this.volume = volume;
273 275
274 /** @type {number} */ 276 /** @type {number} */
275 this.duration = duration; 277 this.duration = duration;
276 278
277 /** @type {number} */ 279 /** @type {number} */
278 this.currentTime = currentTime; 280 this.currentTime = currentTime;
279 }; 281 };
280 282
281
282 /** 283 /**
283 * @param {string} id The ID of the media sink. 284 * @param {string} id The ID of the media sink.
284 * @param {string} name The name of the sink. 285 * @param {string} name The name of the sink.
285 * @param {?string} description Optional description of the sink. 286 * @param {?string} description Optional description of the sink.
286 * @param {?string} domain Optional domain of the sink. 287 * @param {?string} domain Optional domain of the sink.
287 * @param {media_router.SinkIconType} iconType the type of icon for the sink. 288 * @param {media_router.SinkIconType} iconType the type of icon for the sink.
288 * @param {media_router.SinkStatus} status The readiness state of the sink. 289 * @param {media_router.SinkStatus} status The readiness state of the sink.
289 * @param {number} castModes Bitset of cast modes compatible with the sink. 290 * @param {number} castModes Bitset of cast modes compatible with the sink.
290 * @constructor 291 * @constructor
291 * @struct 292 * @struct
(...skipping 18 matching lines...) Expand all
310 /** @type {!media_router.SinkStatus} */ 311 /** @type {!media_router.SinkStatus} */
311 this.status = status; 312 this.status = status;
312 313
313 /** @type {number} */ 314 /** @type {number} */
314 this.castModes = castModes; 315 this.castModes = castModes;
315 316
316 /** @type {boolean} */ 317 /** @type {boolean} */
317 this.isPseudoSink = false; 318 this.isPseudoSink = false;
318 }; 319 };
319 320
320
321 /** 321 /**
322 * @param {number} tabId The current tab ID. 322 * @param {number} tabId The current tab ID.
323 * @param {string} domain The domain of the current tab. 323 * @param {string} domain The domain of the current tab.
324 * @constructor 324 * @constructor
325 * @struct 325 * @struct
326 */ 326 */
327 var TabInfo = function(tabId, domain) { 327 var TabInfo = function(tabId, domain) {
328 /** @type {number} */ 328 /** @type {number} */
329 this.tabId = tabId; 329 this.tabId = tabId;
330 330
331 /** @type {string} */ 331 /** @type {string} */
332 this.domain = domain; 332 this.domain = domain;
333 }; 333 };
334 334
335 return { 335 return {
336 AUTO_CAST_MODE: AUTO_CAST_MODE, 336 AUTO_CAST_MODE: AUTO_CAST_MODE,
337 CastMode: CastMode, 337 CastMode: CastMode,
338 Issue: Issue, 338 Issue: Issue,
339 Route: Route, 339 Route: Route,
340 RouteStatus: RouteStatus, 340 RouteStatus: RouteStatus,
341 Sink: Sink, 341 Sink: Sink,
342 TabInfo: TabInfo, 342 TabInfo: TabInfo,
343 }; 343 };
344 }); 344 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698