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

Unified Diff: ui/ozone/platform/dri/dri_gpu_platform_support.cc

Issue 883783002: [Ozone-DRI] Assume window IPC arrives before surface IPC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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 | « no previous file | ui/ozone/platform/dri/dri_window.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/dri/dri_gpu_platform_support.cc
diff --git a/ui/ozone/platform/dri/dri_gpu_platform_support.cc b/ui/ozone/platform/dri/dri_gpu_platform_support.cc
index fccb54447a1708eea5e1de5277aad1915bd3837d..fa0923f7aea1028911634600708aa384b44428ae 100644
--- a/ui/ozone/platform/dri/dri_gpu_platform_support.cc
+++ b/ui/ozone/platform/dri/dri_gpu_platform_support.cc
@@ -229,16 +229,10 @@ bool DriGpuPlatformSupport::OnMessageReceived(const IPC::Message& message) {
void DriGpuPlatformSupport::OnCreateWindowDelegate(
gfx::AcceleratedWidget widget) {
- // Due to how the GPU process starts up this IPC call may happen after the IPC
- // to create a surface. Since a surface wants to know the window associated
- // with it, we create it ahead of time. So when this call happens we do not
- // create a delegate if it already exists.
- if (!window_manager_->HasWindowDelegate(widget)) {
- scoped_ptr<DriWindowDelegate> delegate(new DriWindowDelegateImpl(
- widget, drm_, window_manager_, screen_manager_));
- delegate->Initialize();
- window_manager_->AddWindowDelegate(widget, delegate.Pass());
- }
+ scoped_ptr<DriWindowDelegate> delegate(new DriWindowDelegateImpl(
+ widget, drm_, window_manager_, screen_manager_));
+ delegate->Initialize();
+ window_manager_->AddWindowDelegate(widget, delegate.Pass());
}
void DriGpuPlatformSupport::OnDestroyWindowDelegate(
« no previous file with comments | « no previous file | ui/ozone/platform/dri/dri_window.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698