| OLD | NEW |
| 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 "chrome/browser/media/router/create_presentation_connection_request.h" | 5 #include "chrome/browser/media/router/create_presentation_connection_request.h" |
| 6 | 6 |
| 7 #include "chrome/browser/media/router/media_source_helper.h" | 7 #include "chrome/common/media_router/media_source_helper.h" |
| 8 #include "chrome/browser/media/router/route_request_result.h" | 8 #include "chrome/common/media_router/route_request_result.h" |
| 9 #include "url/origin.h" | 9 #include "url/origin.h" |
| 10 | 10 |
| 11 using content::PresentationInfo; | 11 using content::PresentationInfo; |
| 12 using content::PresentationError; | 12 using content::PresentationError; |
| 13 | 13 |
| 14 namespace media_router { | 14 namespace media_router { |
| 15 | 15 |
| 16 CreatePresentationConnectionRequest::CreatePresentationConnectionRequest( | 16 CreatePresentationConnectionRequest::CreatePresentationConnectionRequest( |
| 17 const RenderFrameHostId& render_frame_host_id, | 17 const RenderFrameHostId& render_frame_host_id, |
| 18 const std::vector<GURL>& presentation_urls, | 18 const std::vector<GURL>& presentation_urls, |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 if (!result.route()) { | 64 if (!result.route()) { |
| 65 presentation_request->InvokeErrorCallback(content::PresentationError( | 65 presentation_request->InvokeErrorCallback(content::PresentationError( |
| 66 content::PRESENTATION_ERROR_UNKNOWN, result.error())); | 66 content::PRESENTATION_ERROR_UNKNOWN, result.error())); |
| 67 } else { | 67 } else { |
| 68 presentation_request->InvokeSuccessCallback( | 68 presentation_request->InvokeSuccessCallback( |
| 69 result.presentation_id(), result.presentation_url(), *result.route()); | 69 result.presentation_id(), result.presentation_url(), *result.route()); |
| 70 } | 70 } |
| 71 } | 71 } |
| 72 | 72 |
| 73 } // namespace media_router | 73 } // namespace media_router |
| OLD | NEW |