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

Unified Diff: content/browser/browser_main_loop.cc

Issue 2347383002: X11: Use better visuals for OpenGL (Closed)
Patch Set: Fix various tests Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/browser_main_loop.cc
diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc
index 1653f807f9e31fae43e845026731c9dd72933754..fc2e4a4c2da221582204fe86ddb2ad24c3b53ea2 100644
--- a/content/browser/browser_main_loop.cc
+++ b/content/browser/browser_main_loop.cc
@@ -184,7 +184,6 @@
#include "gpu/config/gpu_driver_bug_workaround_type.h"
#include "ui/base/x/x11_util_internal.h" // nogncheck
#include "ui/gfx/x/x11_connection.h" // nogncheck
-#include "ui/gfx/x/x11_switches.h" // nogncheck
#include "ui/gfx/x/x11_types.h" // nogncheck
#endif
@@ -748,30 +747,6 @@ int BrowserMainLoop::PreCreateThreads() {
// 2) Must be after parts_->PreCreateThreads to pick up chrome://flags.
GpuDataManagerImpl::GetInstance()->Initialize();
-#if defined(USE_X11) && !defined(OS_CHROMEOS)
- // PreCreateThreads is called before CreateStartupTasks which starts the gpu
- // process.
- bool enable_transparent_visuals =
- !GpuDataManagerImpl::GetInstance()->IsDriverBugWorkaroundActive(
- gpu::DISABLE_TRANSPARENT_VISUALS);
-
- // Prevent this flag to be turned off later since it is only used here.
- if (!enable_transparent_visuals &&
- !GpuDataManagerImpl::GetInstance()->IsCompleteGpuInfoAvailable()) {
- base::CommandLine::ForCurrentProcess()->AppendSwitch(
- "disable_transparent_visuals");
- }
-
- Visual* visual = NULL;
- int depth = 0;
- ui::ChooseVisualForWindow(enable_transparent_visuals, &visual, &depth);
- DCHECK(depth > 0);
- base::CommandLine::ForCurrentProcess()->AppendSwitchASCII(
- switches::kWindowDepth, base::IntToString(depth));
- base::CommandLine::ForCurrentProcess()->AppendSwitchASCII(
- switches::kX11VisualID, base::UintToString(visual->visualid));
-#endif
-
#if !defined(GOOGLE_CHROME_BUILD) || defined(OS_ANDROID)
// Single-process is an unsupported and not fully tested mode, so
// don't enable it for official Chrome builds (except on Android).

Powered by Google App Engine
This is Rietveld 408576698