| 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/browser/gpu/compositor_util.h" | 5 #include "content/browser/gpu/compositor_util.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/metrics/field_trial.h" | 9 #include "base/metrics/field_trial.h" |
| 10 #include "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
| (...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 189 | 189 |
| 190 // Flags override. | 190 // Flags override. |
| 191 enabled |= command_line.HasSwitch(switches::kEnableDelegatedRenderer); | 191 enabled |= command_line.HasSwitch(switches::kEnableDelegatedRenderer); |
| 192 enabled &= !command_line.HasSwitch(switches::kDisableDelegatedRenderer); | 192 enabled &= !command_line.HasSwitch(switches::kDisableDelegatedRenderer); |
| 193 return enabled; | 193 return enabled; |
| 194 } | 194 } |
| 195 | 195 |
| 196 bool IsImplSidePaintingEnabled() { | 196 bool IsImplSidePaintingEnabled() { |
| 197 const base::CommandLine& command_line = | 197 const base::CommandLine& command_line = |
| 198 *base::CommandLine::ForCurrentProcess(); | 198 *base::CommandLine::ForCurrentProcess(); |
| 199 if (command_line.HasSwitch(switches::kDisableImplSidePainting)) | 199 |
| 200 if (command_line.HasSwitch(switches::kEnableImplSidePainting)) |
| 201 return true; |
| 202 else if (command_line.HasSwitch(switches::kDisableImplSidePainting)) |
| 200 return false; | 203 return false; |
| 204 |
| 201 return true; | 205 return true; |
| 202 } | 206 } |
| 203 | 207 |
| 204 int NumberOfRendererRasterThreads() { | 208 int NumberOfRendererRasterThreads() { |
| 205 const base::CommandLine& command_line = | 209 const base::CommandLine& command_line = |
| 206 *base::CommandLine::ForCurrentProcess(); | 210 *base::CommandLine::ForCurrentProcess(); |
| 207 | 211 |
| 208 int num_raster_threads = 1; | 212 int num_raster_threads = 1; |
| 209 | 213 |
| 210 // TODO(danakj): Don't do this when using async uploads. Add methods to this | 214 // TODO(danakj): Don't do this when using async uploads. Add methods to this |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 382 } | 386 } |
| 383 } | 387 } |
| 384 return problem_list; | 388 return problem_list; |
| 385 } | 389 } |
| 386 | 390 |
| 387 std::vector<std::string> GetDriverBugWorkarounds() { | 391 std::vector<std::string> GetDriverBugWorkarounds() { |
| 388 return GpuDataManagerImpl::GetInstance()->GetDriverBugWorkarounds(); | 392 return GpuDataManagerImpl::GetInstance()->GetDriverBugWorkarounds(); |
| 389 } | 393 } |
| 390 | 394 |
| 391 } // namespace content | 395 } // namespace content |
| OLD | NEW |