| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 "chromeos/dbus/shill_service_client_stub.h" | 5 #include "chromeos/dbus/shill_service_client_stub.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
| 9 #include "base/stl_util.h" | 9 #include "base/stl_util.h" |
| 10 #include "base/values.h" | 10 #include "base/values.h" |
| (...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 void ShillServiceClientStub::ActivateCellularModem( | 214 void ShillServiceClientStub::ActivateCellularModem( |
| 215 const dbus::ObjectPath& service_path, | 215 const dbus::ObjectPath& service_path, |
| 216 const std::string& carrier, | 216 const std::string& carrier, |
| 217 const base::Closure& callback, | 217 const base::Closure& callback, |
| 218 const ErrorCallback& error_callback) { | 218 const ErrorCallback& error_callback) { |
| 219 if (callback.is_null()) | 219 if (callback.is_null()) |
| 220 return; | 220 return; |
| 221 MessageLoop::current()->PostTask(FROM_HERE, callback); | 221 MessageLoop::current()->PostTask(FROM_HERE, callback); |
| 222 } | 222 } |
| 223 | 223 |
| 224 void ShillServiceClientStub::CompleteCellularActivation( |
| 225 const dbus::ObjectPath& service_path, |
| 226 const base::Closure& callback, |
| 227 const ErrorCallback& error_callback) { |
| 228 if (callback.is_null()) |
| 229 return; |
| 230 MessageLoop::current()->PostTask(FROM_HERE, callback); |
| 231 } |
| 232 |
| 224 bool ShillServiceClientStub::CallActivateCellularModemAndBlock( | 233 bool ShillServiceClientStub::CallActivateCellularModemAndBlock( |
| 225 const dbus::ObjectPath& service_path, | 234 const dbus::ObjectPath& service_path, |
| 226 const std::string& carrier) { | 235 const std::string& carrier) { |
| 227 return true; | 236 return true; |
| 228 } | 237 } |
| 229 | 238 |
| 230 ShillServiceClient::TestInterface* ShillServiceClientStub::GetTestInterface() { | 239 ShillServiceClient::TestInterface* ShillServiceClientStub::GetTestInterface() { |
| 231 return this; | 240 return this; |
| 232 } | 241 } |
| 233 | 242 |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 348 std::map<dbus::ObjectPath, PropertyObserverList*>::iterator iter = | 357 std::map<dbus::ObjectPath, PropertyObserverList*>::iterator iter = |
| 349 observer_list_.find(device_path); | 358 observer_list_.find(device_path); |
| 350 if (iter != observer_list_.end()) | 359 if (iter != observer_list_.end()) |
| 351 return *(iter->second); | 360 return *(iter->second); |
| 352 PropertyObserverList* observer_list = new PropertyObserverList(); | 361 PropertyObserverList* observer_list = new PropertyObserverList(); |
| 353 observer_list_[device_path] = observer_list; | 362 observer_list_[device_path] = observer_list; |
| 354 return *observer_list; | 363 return *observer_list; |
| 355 } | 364 } |
| 356 | 365 |
| 357 } // namespace chromeos | 366 } // namespace chromeos |
| OLD | NEW |