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

Side by Side Diff: chrome/browser/media/router/mojo/media_router_mojo_impl.h

Issue 2679893002: [Media Router] Add ProvideSinks() Mojo API (Closed)
Patch Set: fix android compile error Created 3 years, 8 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_MOJO_MEDIA_ROUTER_MOJO_IMPL_H_ 5 #ifndef CHROME_BROWSER_MEDIA_ROUTER_MOJO_MEDIA_ROUTER_MOJO_IMPL_H_
6 #define CHROME_BROWSER_MEDIA_ROUTER_MOJO_MEDIA_ROUTER_MOJO_IMPL_H_ 6 #define CHROME_BROWSER_MEDIA_ROUTER_MOJO_MEDIA_ROUTER_MOJO_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <deque> 10 #include <deque>
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 const SendRouteMessageCallback& callback) override; 102 const SendRouteMessageCallback& callback) override;
103 void AddIssue(const IssueInfo& issue_info) override; 103 void AddIssue(const IssueInfo& issue_info) override;
104 void ClearIssue(const Issue::Id& issue_id) override; 104 void ClearIssue(const Issue::Id& issue_id) override;
105 void OnUserGesture() override; 105 void OnUserGesture() override;
106 void SearchSinks( 106 void SearchSinks(
107 const MediaSink::Id& sink_id, 107 const MediaSink::Id& sink_id,
108 const MediaSource::Id& source_id, 108 const MediaSource::Id& source_id,
109 const std::string& search_input, 109 const std::string& search_input,
110 const std::string& domain, 110 const std::string& domain,
111 const MediaSinkSearchResponseCallback& sink_callback) override; 111 const MediaSinkSearchResponseCallback& sink_callback) override;
112 void ProvideSinks(const std::string& provider_name,
113 const std::vector<MediaSinkInternal>& sinks) override;
112 114
113 const std::string& media_route_provider_extension_id() const { 115 const std::string& media_route_provider_extension_id() const {
114 return media_route_provider_extension_id_; 116 return media_route_provider_extension_id_;
115 } 117 }
116 118
117 void set_instance_id_for_test(const std::string& instance_id) { 119 void set_instance_id_for_test(const std::string& instance_id) {
118 instance_id_ = instance_id; 120 instance_id_ = instance_id;
119 } 121 }
120 122
121 private: 123 private:
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
277 void DoStopObservingMediaSinks(const MediaSource::Id& source_id); 279 void DoStopObservingMediaSinks(const MediaSource::Id& source_id);
278 void DoStartObservingMediaRoutes(const MediaSource::Id& source_id); 280 void DoStartObservingMediaRoutes(const MediaSource::Id& source_id);
279 void DoStopObservingMediaRoutes(const MediaSource::Id& source_id); 281 void DoStopObservingMediaRoutes(const MediaSource::Id& source_id);
280 void DoSearchSinks( 282 void DoSearchSinks(
281 const MediaSink::Id& sink_id, 283 const MediaSink::Id& sink_id,
282 const MediaSource::Id& source_id, 284 const MediaSource::Id& source_id,
283 const std::string& search_input, 285 const std::string& search_input,
284 const std::string& domain, 286 const std::string& domain,
285 const MediaSinkSearchResponseCallback& sink_callback); 287 const MediaSinkSearchResponseCallback& sink_callback);
286 288
289 void DoProvideSinks(const std::string& provider_name,
290 const std::vector<MediaSinkInternal>& sinks);
291
287 // Error handler callback for |binding_| and |media_route_provider_|. 292 // Error handler callback for |binding_| and |media_route_provider_|.
288 void OnConnectionError(); 293 void OnConnectionError();
289 294
290 // mojom::MediaRouter implementation. 295 // mojom::MediaRouter implementation.
291 void RegisterMediaRouteProvider( 296 void RegisterMediaRouteProvider(
292 mojom::MediaRouteProviderPtr media_route_provider_ptr, 297 mojom::MediaRouteProviderPtr media_route_provider_ptr,
293 const mojom::MediaRouter::RegisterMediaRouteProviderCallback& 298 const mojom::MediaRouter::RegisterMediaRouteProviderCallback&
294 callback) override; 299 callback) override;
295 void OnIssue(const IssueInfo& issue) override; 300 void OnIssue(const IssueInfo& issue) override;
296 void OnSinksReceived(const std::string& media_source, 301 void OnSinksReceived(const std::string& media_source,
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 #endif 443 #endif
439 444
440 base::WeakPtrFactory<MediaRouterMojoImpl> weak_factory_; 445 base::WeakPtrFactory<MediaRouterMojoImpl> weak_factory_;
441 446
442 DISALLOW_COPY_AND_ASSIGN(MediaRouterMojoImpl); 447 DISALLOW_COPY_AND_ASSIGN(MediaRouterMojoImpl);
443 }; 448 };
444 449
445 } // namespace media_router 450 } // namespace media_router
446 451
447 #endif // CHROME_BROWSER_MEDIA_ROUTER_MOJO_MEDIA_ROUTER_MOJO_IMPL_H_ 452 #endif // CHROME_BROWSER_MEDIA_ROUTER_MOJO_MEDIA_ROUTER_MOJO_IMPL_H_
OLDNEW
« no previous file with comments | « chrome/browser/media/router/mojo/media_router.mojom ('k') | chrome/browser/media/router/mojo/media_router_mojo_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698