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

Side by Side Diff: chrome/browser/chromeos/mobile/mobile_activator.cc

Issue 1658793002: Update chrome for new prefs location. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 "chrome/browser/chromeos/mobile/mobile_activator.h" 5 #include "chrome/browser/chromeos/mobile/mobile_activator.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 10
11 #include "base/bind.h" 11 #include "base/bind.h"
12 #include "base/bind_helpers.h" 12 #include "base/bind_helpers.h"
13 #include "base/files/file_util.h" 13 #include "base/files/file_util.h"
14 #include "base/json/json_reader.h" 14 #include "base/json/json_reader.h"
15 #include "base/location.h" 15 #include "base/location.h"
16 #include "base/logging.h" 16 #include "base/logging.h"
17 #include "base/memory/ref_counted_memory.h" 17 #include "base/memory/ref_counted_memory.h"
18 #include "base/message_loop/message_loop.h" 18 #include "base/message_loop/message_loop.h"
19 #include "base/metrics/histogram.h" 19 #include "base/metrics/histogram.h"
20 #include "base/observer_list_threadsafe.h" 20 #include "base/observer_list_threadsafe.h"
21 #include "base/prefs/pref_service.h"
22 #include "base/strings/string_piece.h" 21 #include "base/strings/string_piece.h"
23 #include "base/strings/string_util.h" 22 #include "base/strings/string_util.h"
24 #include "base/strings/utf_string_conversions.h" 23 #include "base/strings/utf_string_conversions.h"
25 #include "base/timer/timer.h" 24 #include "base/timer/timer.h"
26 #include "base/values.h" 25 #include "base/values.h"
27 #include "chrome/browser/browser_process.h" 26 #include "chrome/browser/browser_process.h"
28 #include "chrome/common/pref_names.h" 27 #include "chrome/common/pref_names.h"
29 #include "chromeos/network/device_state.h" 28 #include "chromeos/network/device_state.h"
30 #include "chromeos/network/network_activation_handler.h" 29 #include "chromeos/network/network_activation_handler.h"
31 #include "chromeos/network/network_configuration_handler.h" 30 #include "chromeos/network/network_configuration_handler.h"
32 #include "chromeos/network/network_connection_handler.h" 31 #include "chromeos/network/network_connection_handler.h"
33 #include "chromeos/network/network_event_log.h" 32 #include "chromeos/network/network_event_log.h"
34 #include "chromeos/network/network_handler_callbacks.h" 33 #include "chromeos/network/network_handler_callbacks.h"
35 #include "chromeos/network/network_state.h" 34 #include "chromeos/network/network_state.h"
36 #include "chromeos/network/network_state_handler.h" 35 #include "chromeos/network/network_state_handler.h"
36 #include "components/prefs/pref_service.h"
37 #include "components/ssl_config/ssl_config_prefs.h" 37 #include "components/ssl_config/ssl_config_prefs.h"
38 #include "content/public/browser/browser_thread.h" 38 #include "content/public/browser/browser_thread.h"
39 #include "third_party/cros_system_api/dbus/service_constants.h" 39 #include "third_party/cros_system_api/dbus/service_constants.h"
40 #include "ui/chromeos/network/network_connect.h" 40 #include "ui/chromeos/network/network_connect.h"
41 41
42 using content::BrowserThread; 42 using content::BrowserThread;
43 43
44 namespace { 44 namespace {
45 45
46 // Cellular configuration file path. 46 // Cellular configuration file path.
(...skipping 1115 matching lines...) Expand 10 before | Expand all | Expand 10 after
1162 cellular_plan_payment_time_ = base::Time::Now(); 1162 cellular_plan_payment_time_ = base::Time::Now();
1163 } 1163 }
1164 1164
1165 bool MobileActivator::HasRecentCellularPlanPayment() const { 1165 bool MobileActivator::HasRecentCellularPlanPayment() const {
1166 const int kRecentPlanPaymentHours = 6; 1166 const int kRecentPlanPaymentHours = 6;
1167 return (base::Time::Now() - 1167 return (base::Time::Now() -
1168 cellular_plan_payment_time_).InHours() < kRecentPlanPaymentHours; 1168 cellular_plan_payment_time_).InHours() < kRecentPlanPaymentHours;
1169 } 1169 }
1170 1170
1171 } // namespace chromeos 1171 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698