ladybird/Kernel/GUIEventDevice.h
Andreas Kling 4f98a35beb WindowServer: Begin refactoring towards a fully asynchronous protocol.
In order to move the WindowServer to userspace, I have to eliminate its
dependence on system call facilities. The communication channel with each
client needs to be message-based in both directions.
2019-02-13 17:54:30 +01:00

18 lines
610 B
C++

#pragma once
#include <Kernel/CharacterDevice.h>
#include <Kernel/DoubleBuffer.h>
class GUIEventDevice final : public CharacterDevice {
public:
GUIEventDevice();
virtual ~GUIEventDevice() override;
private:
// ^CharacterDevice
virtual ssize_t read(Process&, byte* buffer, size_t bufferSize) override;
virtual ssize_t write(Process&, const byte* buffer, size_t bufferSize) override;
virtual bool can_read(Process&) const override;
virtual bool can_write(Process&) const override { return true; }
virtual const char* class_name() const override { return "GUIEventDevice"; }
};