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

Unified Diff: content/browser/browser_main_loop.cc

Issue 2820463002: gpu: Completely remove GpuProcessHostUIShim. (Closed)
Patch Set: fix device crash Created 3 years, 8 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
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/browser/gpu/gpu_process_host.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/browser_main_loop.cc
diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc
index 0dc52fcaf88e98e2dcf3b4a4858b357f8210f0ad..a98d473909cd25dc15d6e3ac7cdc5bda2f40d8e2 100644
--- a/content/browser/browser_main_loop.cc
+++ b/content/browser/browser_main_loop.cc
@@ -61,7 +61,6 @@
#include "content/browser/gpu/compositor_util.h"
#include "content/browser/gpu/gpu_data_manager_impl.h"
#include "content/browser/gpu/gpu_process_host.h"
-#include "content/browser/gpu/gpu_process_host_ui_shim.h"
#include "content/browser/gpu/shader_cache_factory.h"
#include "content/browser/histogram_synchronizer.h"
#include "content/browser/leveldb_wrapper_impl.h"
@@ -119,6 +118,11 @@
#include "ui/aura/env.h"
#endif
+#if defined(USE_OZONE)
+#include "ui/ozone/public/gpu_platform_support_host.h"
+#include "ui/ozone/public/ozone_platform.h"
+#endif
+
#if defined(OS_ANDROID)
#include "base/android/jni_android.h"
#include "components/tracing/common/graphics_memory_dump_provider_android.h"
@@ -646,6 +650,15 @@ void BrowserMainLoop::MainMessageLoopStart() {
main_message_loop_.reset(new base::MessageLoopForUI);
InitializeMainThread();
+#if defined(USE_OZONE)
+ DCHECK(env_);
+ if (env_->mode() == aura::Env::Mode::LOCAL) {
+ DCHECK(ui::OzonePlatform::GetInstance());
+ ui::OzonePlatform::GetInstance()
+ ->GetGpuPlatformSupportHost()
+ ->BindToCurrentThread();
jam 2017/04/20 00:22:20 why not just pass in the UI thread's task runner i
sadrul 2017/04/20 03:10:31 Yep, that also works. Done.
+ }
+#endif
}
void BrowserMainLoop::PostMainMessageLoopStart() {
« no previous file with comments | « content/browser/BUILD.gn ('k') | content/browser/gpu/gpu_process_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698