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

Side by Side Diff: chrome/browser/gpu_process_host.cc

Issue 6568009: Merge r75130:... (Closed) Base URL: svn://svn.chromium.org/chrome/branches/597/src/
Patch Set: Created 9 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/resources/gpu_blacklist.json » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/gpu_process_host.h" 5 #include "chrome/browser/gpu_process_host.h"
6 6
7 #include "app/app_switches.h" 7 #include "app/app_switches.h"
8 #include "app/gfx/gl/gl_implementation.h"
8 #include "app/resource_bundle.h" 9 #include "app/resource_bundle.h"
9 #include "base/command_line.h" 10 #include "base/command_line.h"
10 #include "base/metrics/histogram.h" 11 #include "base/metrics/histogram.h"
11 #include "base/string_piece.h" 12 #include "base/string_piece.h"
12 #include "base/thread.h" 13 #include "base/thread.h"
13 #include "chrome/browser/browser_process.h" 14 #include "chrome/browser/browser_process.h"
14 #include "chrome/browser/browser_thread.h" 15 #include "chrome/browser/browser_thread.h"
15 #include "chrome/browser/gpu_blacklist.h" 16 #include "chrome/browser/gpu_blacklist.h"
16 #include "chrome/browser/gpu_process_host_ui_shim.h" 17 #include "chrome/browser/gpu_process_host_ui_shim.h"
17 #include "chrome/browser/renderer_host/render_view_host.h" 18 #include "chrome/browser/renderer_host/render_view_host.h"
(...skipping 551 matching lines...) Expand 10 before | Expand all | Expand 10 after
569 570
570 bool GpuProcessHost::LoadGpuBlacklist() { 571 bool GpuProcessHost::LoadGpuBlacklist() {
571 if (gpu_blacklist_.get() != NULL) 572 if (gpu_blacklist_.get() != NULL)
572 return true; 573 return true;
573 static const base::StringPiece gpu_blacklist_json( 574 static const base::StringPiece gpu_blacklist_json(
574 ResourceBundle::GetSharedInstance().GetRawDataResource( 575 ResourceBundle::GetSharedInstance().GetRawDataResource(
575 IDR_GPU_BLACKLIST)); 576 IDR_GPU_BLACKLIST));
576 GpuBlacklist* blacklist = new GpuBlacklist(); 577 GpuBlacklist* blacklist = new GpuBlacklist();
577 const CommandLine& browser_command_line = *CommandLine::ForCurrentProcess(); 578 const CommandLine& browser_command_line = *CommandLine::ForCurrentProcess();
578 if (browser_command_line.HasSwitch(switches::kIgnoreGpuBlacklist) || 579 if (browser_command_line.HasSwitch(switches::kIgnoreGpuBlacklist) ||
580 browser_command_line.GetSwitchValueASCII(
581 switches::kUseGL) == gfx::kGLImplementationOSMesaName ||
579 blacklist->LoadGpuBlacklist(gpu_blacklist_json.as_string(), true)) { 582 blacklist->LoadGpuBlacklist(gpu_blacklist_json.as_string(), true)) {
580 gpu_blacklist_.reset(blacklist); 583 gpu_blacklist_.reset(blacklist);
581 return true; 584 return true;
582 } 585 }
583 delete blacklist; 586 delete blacklist;
584 return false; 587 return false;
585 } 588 }
586 589
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/resources/gpu_blacklist.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698