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

Unified Diff: android_webview/browser/test/fake_window.cc

Issue 2480373002: Refactor context creation parameters into a struct. (Closed)
Patch Set: Created 4 years, 1 month 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: android_webview/browser/test/fake_window.cc
diff --git a/android_webview/browser/test/fake_window.cc b/android_webview/browser/test/fake_window.cc
index cd47a3c93e4beef8ec747100e7afcf5b04688a0c..4c95285b2f2f4cfeb8e080b87a0d044f6c4bc1aa 100644
--- a/android_webview/browser/test/fake_window.cc
+++ b/android_webview/browser/test/fake_window.cc
@@ -189,8 +189,10 @@ void FakeWindow::InitializeOnRT(base::WaitableEvent* sync) {
surface_ = gl::init::CreateOffscreenGLSurface(surface_size_);
DCHECK(surface_);
DCHECK(surface_->GetHandle());
+ gl::GLContextAttribs context_attribs;
+ context_attribs.gpu_preference = gl::PreferDiscreteGpu;
piman 2016/11/07 21:01:01 nit: ditto.
Geoff Lang 2016/11/07 21:36:20 Done.
context_ =
- gl::init::CreateGLContext(nullptr, surface_.get(), gl::PreferDiscreteGpu);
+ gl::init::CreateGLContext(nullptr, surface_.get(), context_attribs);
DCHECK(context_);
sync->Signal();
}

Powered by Google App Engine
This is Rietveld 408576698