OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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/doodle/doodle_service_factory.h" | 5 #include "chrome/browser/doodle/doodle_service_factory.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 | 52 |
53 bool use_gray_background = false; | 53 bool use_gray_background = false; |
54 #if defined(OS_ANDROID) | 54 #if defined(OS_ANDROID) |
55 use_gray_background = | 55 use_gray_background = |
56 !base::FeatureList::IsEnabled(chrome::android::kChromeHomeFeature); | 56 !base::FeatureList::IsEnabled(chrome::android::kChromeHomeFeature); |
57 #endif | 57 #endif |
58 auto fetcher = base::MakeUnique<doodle::DoodleFetcherImpl>( | 58 auto fetcher = base::MakeUnique<doodle::DoodleFetcherImpl>( |
59 profile->GetRequestContext(), | 59 profile->GetRequestContext(), |
60 GoogleURLTrackerFactory::GetForProfile(profile), | 60 GoogleURLTrackerFactory::GetForProfile(profile), |
61 base::Bind(&safe_json::SafeJsonParser::Parse), use_gray_background); | 61 base::Bind(&safe_json::SafeJsonParser::Parse), use_gray_background); |
62 return new doodle::DoodleService(profile->GetPrefs(), std::move(fetcher), | 62 return new doodle::DoodleService( |
63 base::MakeUnique<base::OneShotTimer>(), | 63 profile->GetPrefs(), std::move(fetcher), |
64 base::MakeUnique<base::DefaultClock>(), | 64 base::MakeUnique<base::OneShotTimer>(), |
65 base::MakeUnique<base::DefaultTickClock>()); | 65 base::MakeUnique<base::DefaultClock>(), |
| 66 base::MakeUnique<base::DefaultTickClock>(), |
| 67 /*override_min_refresh_interval=*/base::nullopt); |
66 } | 68 } |
OLD | NEW |