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

Unified Diff: ui/ozone/platform/dri/dri_window_delegate_proxy.h

Issue 522463005: [Ozone-GBM] Handle GPU crashes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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: ui/ozone/platform/dri/dri_window_delegate_proxy.h
diff --git a/ui/ozone/platform/dri/dri_window_delegate_proxy.h b/ui/ozone/platform/dri/dri_window_delegate_proxy.h
index 9ed90951df1c9738d4d71afbc7c2c8cc53d0d355..9e0b1068b6c1c4acbbed44770f5bc7cfb1a61ce6 100644
--- a/ui/ozone/platform/dri/dri_window_delegate_proxy.h
+++ b/ui/ozone/platform/dri/dri_window_delegate_proxy.h
@@ -5,6 +5,8 @@
#ifndef UI_OZONE_PLATFORM_DRI_DRI_WINDOW_DELEGATE_PROXY_H_
#define UI_OZONE_PLATFORM_DRI_DRI_WINDOW_DELEGATE_PROXY_H_
+#include "ui/gfx/geometry/rect.h"
+#include "ui/ozone/platform/dri/channel_observer.h"
#include "ui/ozone/platform/dri/dri_window_delegate.h"
namespace ui {
@@ -13,7 +15,8 @@ class GpuPlatformSupportHostGbm;
// This is used when running with a GPU process (or with the in-process GPU) to
// IPC the native window configuration from the browser to the GPU.
-class DriWindowDelegateProxy : public DriWindowDelegate {
+class DriWindowDelegateProxy : public DriWindowDelegate,
+ public ChannelObserver {
public:
DriWindowDelegateProxy(gfx::AcceleratedWidget widget,
GpuPlatformSupportHostGbm* sender);
@@ -26,9 +29,16 @@ class DriWindowDelegateProxy : public DriWindowDelegate {
virtual HardwareDisplayController* GetController() OVERRIDE;
virtual void OnBoundsChanged(const gfx::Rect& bounds) OVERRIDE;
+ // ChannelObserver:
+ virtual void OnChannelEstablished() OVERRIDE;
+ virtual void OnChannelDestroyed() OVERRIDE;
+
private:
gfx::AcceleratedWidget widget_;
GpuPlatformSupportHostGbm* sender_;
+ gfx::Rect bounds_;
+ // Tracks if the connection is established or not.
+ bool has_connection_;
DISALLOW_COPY_AND_ASSIGN(DriWindowDelegateProxy);
};

Powered by Google App Engine
This is Rietveld 408576698