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 "content/browser/navigator_connect/service_port_service_impl.h" | 5 #include "content/browser/navigator_connect/service_port_service_impl.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "content/browser/message_port_message_filter.h" | 9 #include "content/browser/message_port_message_filter.h" |
10 #include "content/browser/message_port_service.h" | 10 #include "content/browser/message_port_service.h" |
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
117 transferred_ports); | 117 transferred_ports); |
118 } | 118 } |
119 | 119 |
120 void ServicePortServiceImpl::ClosePort(int32_t port_id) { | 120 void ServicePortServiceImpl::ClosePort(int32_t port_id) { |
121 MessagePortService::GetInstance()->Destroy(port_id); | 121 MessagePortService::GetInstance()->Destroy(port_id); |
122 } | 122 } |
123 | 123 |
124 void ServicePortServiceImpl::OnConnectResult(const ConnectCallback& callback, | 124 void ServicePortServiceImpl::OnConnectResult(const ConnectCallback& callback, |
125 int message_port_id, | 125 int message_port_id, |
126 bool success) { | 126 bool success) { |
127 callback.Run(success ? SERVICE_PORT_CONNECT_RESULT_ACCEPT | 127 callback.Run(success ? ServicePortConnectResult::ACCEPT |
128 : SERVICE_PORT_CONNECT_RESULT_REJECT, | 128 : ServicePortConnectResult::REJECT, |
129 message_port_id); | 129 message_port_id); |
130 } | 130 } |
131 | 131 |
132 } // namespace content | 132 } // namespace content |
OLD | NEW |