| 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..b235d030364c4e86b96266ebd830ce7921a4bf5e 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);
|
| }
|
| }
|
|
|
| @@ -388,7 +385,7 @@ void PresentationServiceImpl::SendConnectionMessage(
|
| blink::mojom::ConnectionMessagePtr connection_message,
|
| const SendConnectionMessageCallback& callback) {
|
| DVLOG(2) << "SendConnectionMessage"
|
| - << " [id]: " << session->id;
|
| + << " [presentation id]: " << session->id;
|
| DCHECK(!connection_message.is_null());
|
| // send_message_callback_ should be null by now, otherwise resetting of
|
| // send_message_callback_ with new callback will drop the old callback.
|
| @@ -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));
|
| @@ -503,7 +500,7 @@ void PresentationServiceImpl::OnConnectionMessages(
|
| DCHECK(client_);
|
|
|
| DVLOG(2) << "OnConnectionMessages"
|
| - << " [id]: " << session.presentation_id;
|
| + << " [presentation_id]: " << session.presentation_id;
|
| std::vector<blink::mojom::ConnectionMessagePtr> mojo_messages(
|
| messages.size());
|
| std::transform(
|
| @@ -614,7 +611,7 @@ void PresentationServiceImpl::OnDefaultPresentationStarted(
|
| DCHECK(client_.get());
|
| client_->OnDefaultSessionStarted(
|
| blink::mojom::PresentationSessionInfo::From(connection));
|
| - ListenForConnectionStateChangeAndChangeState(connection);
|
| + ListenForConnectionStateChange(connection);
|
| }
|
|
|
| PresentationServiceImpl::ScreenAvailabilityListenerImpl::
|
|
|