OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/web_resource/gpu_blacklist_updater.h" | 5 #include "chrome/browser/web_resource/gpu_blacklist_updater.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/values.h" | 10 #include "base/values.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 default: | 57 default: |
58 cr_version += " unknown"; | 58 cr_version += " unknown"; |
59 break; | 59 break; |
60 } | 60 } |
61 return cr_version; | 61 return cr_version; |
62 } | 62 } |
63 | 63 |
64 } // namespace anonymous | 64 } // namespace anonymous |
65 | 65 |
66 const char* GpuBlacklistUpdater::kDefaultGpuBlacklistURL = | 66 const char* GpuBlacklistUpdater::kDefaultGpuBlacklistURL = |
67 "https://dl.google.com/dl/edgedl/chrome/gpu/software_rendering_list.json"; | 67 "https://ssl.gstatic.com/chrome/config/software_rendering_list.json"; |
68 | 68 |
69 GpuBlacklistUpdater::GpuBlacklistUpdater() | 69 GpuBlacklistUpdater::GpuBlacklistUpdater() |
70 : WebResourceService(g_browser_process->local_state(), | 70 : WebResourceService(g_browser_process->local_state(), |
71 GpuBlacklistUpdater::kDefaultGpuBlacklistURL, | 71 GpuBlacklistUpdater::kDefaultGpuBlacklistURL, |
72 false, // don't append locale to URL | 72 false, // don't append locale to URL |
73 chrome::NOTIFICATION_CHROME_END, | 73 chrome::NOTIFICATION_CHROME_END, |
74 prefs::kGpuBlacklistUpdate, | 74 prefs::kGpuBlacklistUpdate, |
75 kStartGpuBlacklistFetchDelay, | 75 kStartGpuBlacklistFetchDelay, |
76 kCacheUpdateDelay) { | 76 kCacheUpdateDelay) { |
77 prefs_->RegisterDictionaryPref(prefs::kGpuBlacklist); | 77 prefs_->RegisterDictionaryPref(prefs::kGpuBlacklist); |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
149 | 149 |
150 scoped_ptr<GpuBlacklist> gpu_blacklist( | 150 scoped_ptr<GpuBlacklist> gpu_blacklist( |
151 new GpuBlacklist(GetChromeVersionString())); | 151 new GpuBlacklist(GetChromeVersionString())); |
152 bool success = gpu_blacklist->LoadGpuBlacklist( | 152 bool success = gpu_blacklist->LoadGpuBlacklist( |
153 gpu_blacklist_cache, GpuBlacklist::kCurrentOsOnly); | 153 gpu_blacklist_cache, GpuBlacklist::kCurrentOsOnly); |
154 if (success) { | 154 if (success) { |
155 GpuDataManager::GetInstance()->UpdateGpuBlacklist( | 155 GpuDataManager::GetInstance()->UpdateGpuBlacklist( |
156 gpu_blacklist.release(), preliminary); | 156 gpu_blacklist.release(), preliminary); |
157 } | 157 } |
158 } | 158 } |
OLD | NEW |