| Index: ui/views/widget/desktop_aura/x11_capture_window.h
|
| diff --git a/ui/views/widget/desktop_aura/x11_capture_window.h b/ui/views/widget/desktop_aura/x11_capture_window.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..6fa7366c5ec2c52aad9593089fa7b87430c151bb
|
| --- /dev/null
|
| +++ b/ui/views/widget/desktop_aura/x11_capture_window.h
|
| @@ -0,0 +1,37 @@
|
| +// Copyright 2013 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_VIEWS_WIDGET_DESKTOP_AURA_X11_CAPTURE_WINDOW_H_
|
| +#define UI_VIEWS_WIDGET_DESKTOP_AURA_X11_CAPTURE_WINDOW_H_
|
| +
|
| +#include "base/basictypes.h"
|
| +#include "ui/events/platform/platform_event_types.h"
|
| +#include "ui/gfx/x/x11_types.h"
|
| +
|
| +namespace views {
|
| +
|
| +// Wrapper for an X11 window which grabs mouse events whenever a
|
| +// DesktopWindowTreeHostX11 gains capture.
|
| +class X11CaptureWindow {
|
| + public:
|
| + X11CaptureWindow();
|
| + ~X11CaptureWindow();
|
| +
|
| + XID xwindow() {
|
| + return xwindow_;
|
| + }
|
| +
|
| + // Whether |event| should be dispatched to the X11CaptureWindow's owner.
|
| + bool CanDispatchEventToOwner(const ui::PlatformEvent& event);
|
| +
|
| + private:
|
| + bool captured_;
|
| + XID xwindow_;
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(X11CaptureWindow);
|
| +};
|
| +
|
| +} // namespace views
|
| +
|
| +#endif // UI_VIEWS_WIDGET_DESKTOP_AURA_X11_CAPTURE_WINDOW_H_
|
|
|