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

Side by Side Diff: chrome/browser/ui/webui/media_router/cast_modes_with_media_sources.h

Issue 2264153002: [Presentation API] Add support for multiple URLs in PresentationRequest on Media Router UI side (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Create CastModesWithMediaSources Created 4 years, 3 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 2016 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 #ifndef CHROME_BROWSER_UI_WEBUI_MEDIA_ROUTER_CAST_MODES_WITH_MEDIA_SOURCES_H_
6 #define CHROME_BROWSER_UI_WEBUI_MEDIA_ROUTER_CAST_MODES_WITH_MEDIA_SOURCES_H_
7
8 #include <map>
9 #include <unordered_set>
10
11 #include "chrome/browser/media/router/media_source.h"
12 #include "chrome/browser/ui/webui/media_router/media_cast_mode.h"
13
14 namespace media_router {
15
16 //
mark a. foltz 2016/08/31 05:18:55 Finish class level comment
takumif 2016/09/01 21:09:25 Oops. Done.
17 class CastModesWithMediaSources {
18 public:
19 CastModesWithMediaSources();
20 CastModesWithMediaSources(const CastModesWithMediaSources& other);
21 ~CastModesWithMediaSources();
22
23 void AddSource(const MediaSource& source, MediaCastMode cast_mode);
24 void RemoveSource(const MediaSource& source, MediaCastMode cast_mode);
25 bool HasSource(const MediaSource& source, MediaCastMode cast_mode) const;
26
27 void RemoveCastMode(MediaCastMode cast_mode);
28
29 CastModeSet GetCastModes() const;
30
31 bool IsEmpty() const;
mark a. foltz 2016/08/31 05:18:54 Does this mean the cast mode set is empty? Please
takumif 2016/09/01 21:09:25 Done.
32
33 private:
34 std::map<MediaCastMode, std::unordered_set<MediaSource, MediaSource::Hash>>
35 cast_modes_;
36 };
37
38 } // namespace media_router
39
40 #endif // CHROME_BROWSER_UI_WEBUI_MEDIA_ROUTER_CAST_MODES_WITH_MEDIA_SOURCES_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698