cursor: move to a hyprland impl
This moves wlr_cursor to a completely new impl mostly under CPointerManager Also adds beginSimple to OpenGL for simple render passes (e.g. cursor)
This commit is contained in:
parent
e4e84064f2
commit
ed411f53bd
51 changed files with 1550 additions and 496 deletions
|
|
@ -9,6 +9,7 @@
|
|||
struct wlr_buffer;
|
||||
struct wlr_xcursor_manager;
|
||||
struct wlr_xwayland;
|
||||
class CWLSurface;
|
||||
|
||||
class CCursorManager {
|
||||
public:
|
||||
|
|
@ -18,7 +19,8 @@ class CCursorManager {
|
|||
wlr_buffer* getCursorBuffer();
|
||||
|
||||
void setCursorFromName(const std::string& name);
|
||||
void setCursorSurface(wlr_surface* surf, const Vector2D& hotspot);
|
||||
void setCursorSurface(CWLSurface* surf, const Vector2D& hotspot);
|
||||
void setXCursor(const std::string& name);
|
||||
|
||||
void changeTheme(const std::string& name, const int size);
|
||||
void updateTheme();
|
||||
|
|
@ -30,13 +32,16 @@ class CCursorManager {
|
|||
class CCursorBuffer {
|
||||
public:
|
||||
CCursorBuffer(cairo_surface_t* surf, const Vector2D& size, const Vector2D& hotspot);
|
||||
CCursorBuffer(uint8_t* pixelData, const Vector2D& size, const Vector2D& hotspot);
|
||||
~CCursorBuffer();
|
||||
|
||||
struct SCursorWlrBuffer {
|
||||
wlr_buffer base;
|
||||
cairo_surface_t* surface = nullptr;
|
||||
bool dropped = false;
|
||||
CCursorBuffer* parent = nullptr;
|
||||
cairo_surface_t* surface = nullptr;
|
||||
bool dropped = false;
|
||||
CCursorBuffer* parent = nullptr;
|
||||
uint8_t* pixelData = nullptr;
|
||||
size_t stride = 0;
|
||||
} wlrBuffer;
|
||||
|
||||
private:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue