forked from X547/wayland-server
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathHaikuXdgShell.h
37 lines (27 loc) · 1.03 KB
/
HaikuXdgShell.h
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
#pragma once
#include "XdgShell.h"
#include "WlGlobal.h"
#include <util/DoublyLinkedList.h>
struct HaikuXdgShell;
class HaikuXdgWmBase: public XdgWmBase {
private:
HaikuXdgShell *fShell;
DoublyLinkedListLink<HaikuXdgWmBase> fLink;
public:
typedef DoublyLinkedList<HaikuXdgWmBase, DoublyLinkedListMemberGetLink<HaikuXdgWmBase, &HaikuXdgWmBase::fLink>> List;
HaikuXdgWmBase(HaikuXdgShell *shell): fShell(shell) {}
virtual ~HaikuXdgWmBase();
static HaikuXdgWmBase *FromResource(struct wl_resource *resource) {return (HaikuXdgWmBase*)WlResource::FromResource(resource);}
void HandleCreatePositioner(uint32_t id) override;
void HandleGetXdgSurface(uint32_t id, struct wl_resource *surface) override;
void HandlePong(uint32_t serial) override;
};
class HaikuXdgShell: public WlGlocal {
private:
friend class HaikuXdgWmBase;
HaikuXdgWmBase::List fClients;
public:
static HaikuXdgShell *Create(struct wl_display *display);
virtual ~HaikuXdgShell() = default;
void Bind(struct wl_client *wl_client, uint32_t version, uint32_t id) override;
};