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

Side by Side Diff: chromeos/network/network_sms_handler.cc

Issue 10834004: Correct const accessors in base/values.(h|cc) (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: One more, Windows-only Created 8 years, 5 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/network/network_sms_handler.h" 5 #include "chromeos/network/network_sms_handler.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <deque> 8 #include <deque>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 FOR_EACH_OBSERVER(Observer, observers_, MessageReceived(message)); 364 FOR_EACH_OBSERVER(Observer, observers_, MessageReceived(message));
365 } 365 }
366 366
367 void NetworkSmsHandler::ManagerPropertiesCallback( 367 void NetworkSmsHandler::ManagerPropertiesCallback(
368 DBusMethodCallStatus call_status, 368 DBusMethodCallStatus call_status,
369 const base::DictionaryValue& properties) { 369 const base::DictionaryValue& properties) {
370 if (call_status != DBUS_METHOD_CALL_SUCCESS) { 370 if (call_status != DBUS_METHOD_CALL_SUCCESS) {
371 LOG(ERROR) << "NetworkSmsHandler: Failed to get manager properties."; 371 LOG(ERROR) << "NetworkSmsHandler: Failed to get manager properties.";
372 return; 372 return;
373 } 373 }
374 base::Value* value; 374 const base::Value* value;
375 if (!properties.GetWithoutPathExpansion(flimflam::kDevicesProperty, &value) || 375 if (!properties.GetWithoutPathExpansion(flimflam::kDevicesProperty, &value) ||
376 value->GetType() != base::Value::TYPE_LIST) { 376 value->GetType() != base::Value::TYPE_LIST) {
377 LOG(ERROR) << "NetworkSmsHandler: No list value for: " 377 LOG(ERROR) << "NetworkSmsHandler: No list value for: "
378 << flimflam::kDevicesProperty; 378 << flimflam::kDevicesProperty;
379 return; 379 return;
380 } 380 }
381 const base::ListValue* devices = static_cast<const base::ListValue*>(value); 381 const base::ListValue* devices = static_cast<const base::ListValue*>(value);
382 for (base::ListValue::const_iterator iter = devices->begin(); 382 for (base::ListValue::const_iterator iter = devices->begin();
383 iter != devices->end(); ++iter) { 383 iter != devices->end(); ++iter) {
384 std::string device_path; 384 std::string device_path;
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
435 this, dbus_connection, object_path)); 435 this, dbus_connection, object_path));
436 } else { 436 } else {
437 device_handlers_.push_back( 437 device_handlers_.push_back(
438 new ModemManagerNetworkSmsDeviceHandler( 438 new ModemManagerNetworkSmsDeviceHandler(
439 this, dbus_connection, object_path)); 439 this, dbus_connection, object_path));
440 } 440 }
441 } 441 }
442 442
443 443
444 } // namespace chromeos 444 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698