OLD | NEW |
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 "content/renderer/render_thread_impl.h" | 5 #include "content/renderer/render_thread_impl.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <limits> | 8 #include <limits> |
9 #include <map> | 9 #include <map> |
10 #include <vector> | 10 #include <vector> |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
173 DISALLOW_COPY_AND_ASSIGN(RenderViewZoomer); | 173 DISALLOW_COPY_AND_ASSIGN(RenderViewZoomer); |
174 }; | 174 }; |
175 | 175 |
176 std::string HostToCustomHistogramSuffix(const std::string& host) { | 176 std::string HostToCustomHistogramSuffix(const std::string& host) { |
177 if (host == "mail.google.com") | 177 if (host == "mail.google.com") |
178 return ".gmail"; | 178 return ".gmail"; |
179 if (host == "docs.google.com" || host == "drive.google.com") | 179 if (host == "docs.google.com" || host == "drive.google.com") |
180 return ".docs"; | 180 return ".docs"; |
181 if (host == "plus.google.com") | 181 if (host == "plus.google.com") |
182 return ".plus"; | 182 return ".plus"; |
183 return ""; | 183 return std::string(); |
184 } | 184 } |
185 | 185 |
186 void* CreateHistogram( | 186 void* CreateHistogram( |
187 const char *name, int min, int max, size_t buckets) { | 187 const char *name, int min, int max, size_t buckets) { |
188 if (min <= 0) | 188 if (min <= 0) |
189 min = 1; | 189 min = 1; |
190 std::string histogram_name; | 190 std::string histogram_name; |
191 RenderThreadImpl* render_thread_impl = RenderThreadImpl::current(); | 191 RenderThreadImpl* render_thread_impl = RenderThreadImpl::current(); |
192 if (render_thread_impl) { // Can be null in tests. | 192 if (render_thread_impl) { // Can be null in tests. |
193 histogram_name = render_thread_impl-> | 193 histogram_name = render_thread_impl-> |
(...skipping 1095 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1289 | 1289 |
1290 void RenderThreadImpl::SetFlingCurveParameters( | 1290 void RenderThreadImpl::SetFlingCurveParameters( |
1291 const std::vector<float>& new_touchpad, | 1291 const std::vector<float>& new_touchpad, |
1292 const std::vector<float>& new_touchscreen) { | 1292 const std::vector<float>& new_touchscreen) { |
1293 webkit_platform_support_->SetFlingCurveParameters(new_touchpad, | 1293 webkit_platform_support_->SetFlingCurveParameters(new_touchpad, |
1294 new_touchscreen); | 1294 new_touchscreen); |
1295 | 1295 |
1296 } | 1296 } |
1297 | 1297 |
1298 } // namespace content | 1298 } // namespace content |
OLD | NEW |