blob: b6c4573d1b3e25d82a3e3c29cbde8f251d2fc3c3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
// Copyright 2016 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_PLATFORM_WINDOW_X11_X11_WINDOW_OZONE_H_
#define UI_PLATFORM_WINDOW_X11_X11_WINDOW_OZONE_H_
#include "base/macros.h"
#include "ui/events/platform/platform_event_dispatcher.h"
#include "ui/events/platform/x11/x11_event_source_libevent.h"
#include "ui/platform_window/x11/x11_window_base.h"
namespace ui {
// PlatformWindow implementation for X11 Ozone. PlatformEvents are ui::Events.
class X11_WINDOW_EXPORT X11WindowOzone : public X11WindowBase,
public PlatformEventDispatcher,
public XEventDispatcher {
public:
X11WindowOzone(X11EventSourceLibevent* event_source,
PlatformWindowDelegate* delegate);
~X11WindowOzone() override;
// PlatformWindow:
void SetCursor(PlatformCursor cursor) override;
// XEventDispatcher:
bool DispatchXEvent(XEvent* event) override;
private:
// PlatformEventDispatcher:
bool CanDispatchEvent(const PlatformEvent& event) override;
uint32_t DispatchEvent(const PlatformEvent& event) override;
X11EventSourceLibevent* event_source_;
DISALLOW_COPY_AND_ASSIGN(X11WindowOzone);
};
} // namespace ui
#endif // UI_PLATFORM_WINDOW_X11_X11_WINDOW_OZONE_H_
|