| Index: ui/ozone/platform/dri/native_window_delegate.h
|
| diff --git a/ui/ozone/platform/dri/native_window_delegate.h b/ui/ozone/platform/dri/native_window_delegate.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..5ae8ac22bca5ab862172266709e18f3e97942800
|
| --- /dev/null
|
| +++ b/ui/ozone/platform/dri/native_window_delegate.h
|
| @@ -0,0 +1,39 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef UI_OZONE_PLATFORM_DRI_NATIVE_WINDOW_DELEGATE_H_
|
| +#define UI_OZONE_PLATFORM_DRI_NATIVE_WINDOW_DELEGATE_H_
|
| +
|
| +#include "ui/gfx/native_widget_types.h"
|
| +
|
| +namespace gfx {
|
| +class Rect;
|
| +} // namespace gfx
|
| +
|
| +namespace ui {
|
| +
|
| +class HardwareDisplayController;
|
| +
|
| +// This is a bridge between the browser process and the GPU process for a native
|
| +// window. Since display configuration is done on the GPU process, it needs to
|
| +// know where the native windows are located such that it can map them to a
|
| +// hardware display controller.
|
| +class NativeWindowDelegate {
|
| + public:
|
| + virtual ~NativeWindowDelegate() {}
|
| +
|
| + // Returns the accelerated widget associated with the delegate.
|
| + virtual gfx::AcceleratedWidget GetWidget() = 0;
|
| +
|
| + // Returns the current controller the window is displaying on. Callers should
|
| + // not cache the result as the controller may change as the window is moved.
|
| + virtual HardwareDisplayController* GetController() = 0;
|
| +
|
| + // Called when the window is resized/moved.
|
| + virtual void OnBoundsChanged(const gfx::Rect& bounds) = 0;
|
| +};
|
| +
|
| +} // namespace ui
|
| +
|
| +#endif // UI_OZONE_PLATFORM_DRI_NATIVE_WINDOW_DELEGATE_H_
|
|
|