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

Side by Side Diff: content/browser/presentation/presentation_service_impl.cc

Issue 935083002: [PresentationAPI] Implementing start/joinSession from WebPresentationClient to PresentationService. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 #include "content/browser/presentation/presentation_service_impl.h" 5 #include "content/browser/presentation/presentation_service_impl.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "content/public/browser/content_browser_client.h" 8 #include "content/public/browser/content_browser_client.h"
9 #include "content/public/browser/navigation_details.h" 9 #include "content/public/browser/navigation_details.h"
10 #include "content/public/browser/render_frame_host.h" 10 #include "content/public/browser/render_frame_host.h"
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 std::make_pair(presentation_url_str, context)).first; 92 std::make_pair(presentation_url_str, context)).first;
93 } 93 }
94 94
95 it->second->CallbackReceived(callback); 95 it->second->CallbackReceived(callback);
96 } 96 }
97 97
98 void PresentationServiceImpl::OnScreenAvailabilityListenerRemoved() { 98 void PresentationServiceImpl::OnScreenAvailabilityListenerRemoved() {
99 NOTIMPLEMENTED(); 99 NOTIMPLEMENTED();
100 } 100 }
101 101
102 void PresentationServiceImpl::StartSession(
103 const mojo::String& presentation_url,
104 const mojo::String& presentation_id,
105 const NewSessionMojoCallback& callback) {
106 NOTIMPLEMENTED();
107 }
108
109 void PresentationServiceImpl::JoinSession(
110 const mojo::String& presentation_url,
111 const mojo::String& presentation_id,
112 const NewSessionMojoCallback& callback) {
113 NOTIMPLEMENTED();
114 }
115
102 void PresentationServiceImpl::DidNavigateAnyFrame( 116 void PresentationServiceImpl::DidNavigateAnyFrame(
103 content::RenderFrameHost* render_frame_host, 117 content::RenderFrameHost* render_frame_host,
104 const content::LoadCommittedDetails& details, 118 const content::LoadCommittedDetails& details,
105 const content::FrameNavigateParams& params) { 119 const content::FrameNavigateParams& params) {
106 VLOG(2) << "PresentationServiceImpl::DidNavigateAnyFrame"; 120 VLOG(2) << "PresentationServiceImpl::DidNavigateAnyFrame";
107 if (render_frame_host_ != render_frame_host) 121 if (render_frame_host_ != render_frame_host)
108 return; 122 return;
109 123
110 std::string prev_url_host = details.previous_url.host(); 124 std::string prev_url_host = details.previous_url.host();
111 std::string curr_url_host = params.url.host(); 125 std::string curr_url_host = params.url.host();
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 } else { 209 } else {
196 // Invoke callback and erase it. 210 // Invoke callback and erase it.
197 // There shouldn't be any result stored in this scenario. 211 // There shouldn't be any result stored in this scenario.
198 DCHECK(!available_ptr_); 212 DCHECK(!available_ptr_);
199 callback_ptr_->Run(available); 213 callback_ptr_->Run(available);
200 Reset(); 214 Reset();
201 } 215 }
202 } 216 }
203 217
204 } // namespace content 218 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698