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

Side by Side Diff: components/arc/net/arc_net_host_impl.cc

Issue 1925183004: arc_bridge: Add more logging, plus cleanup (Closed) Base URL: https://chromium.googlesource.com/a/chromium/src.git@master
Patch Set: Fixed unit tests Created 4 years, 7 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
« no previous file with comments | « components/arc/arc_bridge_service_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "components/arc/net/arc_net_host_impl.h" 5 #include "components/arc/net/arc_net_host_impl.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 chromeos::network_handler::ErrorCallback()); 170 chromeos::network_handler::ErrorCallback());
171 callback.Run(true); 171 callback.Run(true);
172 } 172 }
173 } 173 }
174 174
175 void ArcNetHostImpl::StartScan() { 175 void ArcNetHostImpl::StartScan() {
176 GetStateHandler()->RequestScan(); 176 GetStateHandler()->RequestScan();
177 } 177 }
178 178
179 void ArcNetHostImpl::ScanCompleted(const chromeos::DeviceState* /*unused*/) { 179 void ArcNetHostImpl::ScanCompleted(const chromeos::DeviceState* /*unused*/) {
180 if (!arc_bridge_service()->net_instance()) {
181 VLOG(2) << "NetInstance not ready yet";
182 return;
183 }
180 if (arc_bridge_service()->net_version() < 1) { 184 if (arc_bridge_service()->net_version() < 1) {
181 VLOG(1) << "ArcBridgeService does not support ScanCompleted."; 185 VLOG(1) << "NetInstance does not support ScanCompleted.";
182 return; 186 return;
183 } 187 }
184 188
185 arc_bridge_service()->net_instance()->ScanCompleted(); 189 arc_bridge_service()->net_instance()->ScanCompleted();
186 } 190 }
187 191
188 void ArcNetHostImpl::OnShuttingDown() { 192 void ArcNetHostImpl::OnShuttingDown() {
189 GetStateHandler()->RemoveObserver(this, FROM_HERE); 193 GetStateHandler()->RemoveObserver(this, FROM_HERE);
190 } 194 }
191 195
192 } // namespace arc 196 } // namespace arc
OLDNEW
« no previous file with comments | « components/arc/arc_bridge_service_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698