Index: content/browser/presentation/presentation_service_impl.cc |
diff --git a/content/browser/presentation/presentation_service_impl.cc b/content/browser/presentation/presentation_service_impl.cc |
index 9d870e3adf4c717129a36ad5d51f12538394c494..30940a052fb328194f4677bb39f6e7e47c103ad7 100644 |
--- a/content/browser/presentation/presentation_service_impl.cc |
+++ b/content/browser/presentation/presentation_service_impl.cc |
@@ -293,16 +293,13 @@ int PresentationServiceImpl::RegisterJoinSessionCallback( |
return request_id; |
} |
-void PresentationServiceImpl::ListenForConnectionStateChangeAndChangeState( |
+void PresentationServiceImpl::ListenForConnectionStateChange( |
const PresentationSessionInfo& connection) { |
if (controller_delegate_) { |
controller_delegate_->ListenForConnectionStateChange( |
render_process_id_, render_frame_id_, connection, |
base::Bind(&PresentationServiceImpl::OnConnectionStateChanged, |
weak_factory_.GetWeakPtr(), connection)); |
- OnConnectionStateChanged(connection, |
- PresentationConnectionStateChangeInfo( |
- PRESENTATION_CONNECTION_STATE_CONNECTED)); |
} |
} |
@@ -316,7 +313,7 @@ void PresentationServiceImpl::OnStartSessionSucceeded( |
pending_start_session_cb_->Run( |
blink::mojom::PresentationSessionInfo::From(session_info), |
blink::mojom::PresentationErrorPtr()); |
- ListenForConnectionStateChangeAndChangeState(session_info); |
+ ListenForConnectionStateChange(session_info); |
pending_start_session_cb_.reset(); |
start_session_request_id_ = kInvalidRequestSessionId; |
} |
@@ -341,7 +338,7 @@ void PresentationServiceImpl::OnJoinSessionSucceeded( |
request_session_id, |
blink::mojom::PresentationSessionInfo::From(session_info), |
blink::mojom::PresentationErrorPtr())) { |
- ListenForConnectionStateChangeAndChangeState(session_info); |
+ ListenForConnectionStateChange(session_info); |
} |
} |
@@ -490,7 +487,7 @@ void PresentationServiceImpl::SetPresentationConnection( |
return; |
PresentationSessionInfo session_info(session.To<PresentationSessionInfo>()); |
- controller_delegate_->ConnectToOffscreenPresentation( |
+ controller_delegate_->ConnectToPresentation( |
render_process_id_, render_frame_id_, session_info, |
std::move(controller_connection_ptr), |
std::move(receiver_connection_request)); |
@@ -614,7 +611,7 @@ void PresentationServiceImpl::OnDefaultPresentationStarted( |
DCHECK(client_.get()); |
client_->OnDefaultSessionStarted( |
blink::mojom::PresentationSessionInfo::From(connection)); |
- ListenForConnectionStateChangeAndChangeState(connection); |
+ ListenForConnectionStateChange(connection); |
} |
PresentationServiceImpl::ScreenAvailabilityListenerImpl:: |