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

Side by Side Diff: chrome/browser/media/router/media_router.h

Issue 2731043002: [Media Router] Add a presentation id to MediaRoute mapping in the MR (Closed)
Patch Set: resolve code review comments from Mark Created 3 years, 9 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 #ifndef CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_H_ 5 #ifndef CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_H_
6 #define CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_H_ 6 #define CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 const content::PresentationConnectionStateChangedCallback& callback) = 0; 182 const content::PresentationConnectionStateChangedCallback& callback) = 0;
183 183
184 // Called when the incognito profile for this instance is being shut down. 184 // Called when the incognito profile for this instance is being shut down.
185 // This will terminate all incognito media routes. 185 // This will terminate all incognito media routes.
186 virtual void OnIncognitoProfileShutdown() = 0; 186 virtual void OnIncognitoProfileShutdown() = 0;
187 187
188 // Returns the media routes that currently exist. To get notified whenever 188 // Returns the media routes that currently exist. To get notified whenever
189 // there is a change to the media routes, subclass MediaRoutesObserver. 189 // there is a change to the media routes, subclass MediaRoutesObserver.
190 virtual std::vector<MediaRoute> GetCurrentRoutes() const = 0; 190 virtual std::vector<MediaRoute> GetCurrentRoutes() const = 0;
191 191
192 // Returns the MediaRoute associated with |presentation_id|. Returns nullptr
193 // if no such media route exists.
194 virtual const MediaRoute* GetPresentationRoute(
195 const std::string& presentation_id) const = 0;
196
192 private: 197 private:
193 friend class IssuesObserver; 198 friend class IssuesObserver;
194 friend class MediaSinksObserver; 199 friend class MediaSinksObserver;
195 friend class MediaRoutesObserver; 200 friend class MediaRoutesObserver;
196 friend class PresentationConnectionStateObserver; 201 friend class PresentationConnectionStateObserver;
197 friend class RouteMessageObserver; 202 friend class RouteMessageObserver;
198 203
199 // The following functions are called by friend Observer classes above. 204 // The following functions are called by friend Observer classes above.
200 205
201 // Registers |observer| with this MediaRouter. |observer| specifies a media 206 // Registers |observer| with this MediaRouter. |observer| specifies a media
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 250
246 // Unregisters a previously registered RouteMessagesObserver. |observer| will 251 // Unregisters a previously registered RouteMessagesObserver. |observer| will
247 // stop receiving further updates. 252 // stop receiving further updates.
248 virtual void UnregisterRouteMessageObserver( 253 virtual void UnregisterRouteMessageObserver(
249 RouteMessageObserver* observer) = 0; 254 RouteMessageObserver* observer) = 0;
250 }; 255 };
251 256
252 } // namespace media_router 257 } // namespace media_router
253 258
254 #endif // CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_H_ 259 #endif // CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698