2022-03-18 20:03:39 +01:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "../defines.hpp"
|
2023-06-23 21:14:04 +02:00
|
|
|
#include <optional>
|
2022-03-18 20:03:39 +01:00
|
|
|
|
2023-09-20 15:25:03 +00:00
|
|
|
class CWindow; // because clangd
|
2024-04-27 12:43:12 +01:00
|
|
|
typedef SP<CWindow> PHLWINDOW;
|
2024-06-08 10:07:59 +02:00
|
|
|
class CWLSurfaceResource;
|
2023-09-20 15:25:03 +00:00
|
|
|
|
2022-03-18 20:03:39 +01:00
|
|
|
class CHyprXWaylandManager {
|
2022-12-16 17:17:31 +00:00
|
|
|
public:
|
2022-03-18 20:03:39 +01:00
|
|
|
CHyprXWaylandManager();
|
|
|
|
|
~CHyprXWaylandManager();
|
|
|
|
|
|
2024-06-08 10:07:59 +02:00
|
|
|
SP<CWLSurfaceResource> getWindowSurface(PHLWINDOW);
|
|
|
|
|
void activateSurface(SP<CWLSurfaceResource>, bool);
|
|
|
|
|
void activateWindow(PHLWINDOW, bool);
|
2025-01-26 15:05:34 +00:00
|
|
|
CBox getGeometryForWindow(PHLWINDOW);
|
2024-06-08 10:07:59 +02:00
|
|
|
void sendCloseWindow(PHLWINDOW);
|
|
|
|
|
void setWindowFullscreen(PHLWINDOW, bool);
|
|
|
|
|
bool shouldBeFloated(PHLWINDOW, bool pending = false);
|
|
|
|
|
void checkBorders(PHLWINDOW);
|
|
|
|
|
Vector2D xwaylandToWaylandCoords(const Vector2D&);
|
2024-12-15 00:37:17 +01:00
|
|
|
Vector2D waylandToXWaylandCoords(const Vector2D&);
|
2022-03-18 20:03:39 +01:00
|
|
|
};
|
|
|
|
|
|
2025-01-23 21:55:41 +01:00
|
|
|
inline UP<CHyprXWaylandManager> g_pXWaylandManager;
|