2022-05-28 20:46:20 +02:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "IHyprWindowDecoration.hpp"
|
|
|
|
#include <deque>
|
2023-05-22 21:40:32 +02:00
|
|
|
#include "../Texture.hpp"
|
|
|
|
#include <string>
|
|
|
|
|
|
|
|
class CTitleTex {
|
|
|
|
public:
|
|
|
|
CTitleTex(CWindow* pWindow, const Vector2D& bufferSize);
|
|
|
|
~CTitleTex();
|
|
|
|
|
|
|
|
CTexture tex;
|
|
|
|
std::string szContent;
|
|
|
|
CWindow* pWindowOwner = nullptr;
|
|
|
|
};
|
2022-05-28 20:46:20 +02:00
|
|
|
|
|
|
|
class CHyprGroupBarDecoration : public IHyprWindowDecoration {
|
2022-12-16 18:17:31 +01:00
|
|
|
public:
|
2022-05-28 20:46:20 +02:00
|
|
|
CHyprGroupBarDecoration(CWindow*);
|
|
|
|
virtual ~CHyprGroupBarDecoration();
|
|
|
|
|
|
|
|
virtual SWindowDecorationExtents getWindowDecorationExtents();
|
|
|
|
|
2022-12-16 18:17:31 +01:00
|
|
|
virtual void draw(CMonitor*, float a, const Vector2D& offset);
|
2022-05-28 20:46:20 +02:00
|
|
|
|
2022-12-16 18:17:31 +01:00
|
|
|
virtual eDecorationType getDecorationType();
|
2022-05-28 20:46:20 +02:00
|
|
|
|
2022-12-16 18:17:31 +01:00
|
|
|
virtual void updateWindow(CWindow*);
|
2022-05-28 20:46:20 +02:00
|
|
|
|
2022-12-16 18:17:31 +01:00
|
|
|
virtual void damageEntire();
|
2022-05-28 20:46:20 +02:00
|
|
|
|
2023-05-22 20:52:41 +02:00
|
|
|
virtual SWindowDecorationExtents getWindowDecorationReservedArea();
|
|
|
|
|
2022-12-16 18:17:31 +01:00
|
|
|
private:
|
2023-05-22 22:06:40 +02:00
|
|
|
SWindowDecorationExtents m_seExtents;
|
2023-05-22 21:40:32 +02:00
|
|
|
|
2023-05-22 22:06:40 +02:00
|
|
|
CWindow* m_pWindow = nullptr;
|
2023-05-22 21:40:32 +02:00
|
|
|
|
2023-05-22 22:06:40 +02:00
|
|
|
Vector2D m_vLastWindowPos;
|
|
|
|
Vector2D m_vLastWindowSize;
|
2022-05-28 20:46:20 +02:00
|
|
|
|
2023-05-22 22:06:40 +02:00
|
|
|
std::deque<CWindow*> m_dwGroupMembers;
|
2022-05-28 20:46:20 +02:00
|
|
|
|
2023-05-22 22:06:40 +02:00
|
|
|
CTitleTex* textureFromTitle(const std::string&);
|
|
|
|
void clearUnusedTextures();
|
|
|
|
void invalidateTextures();
|
2022-05-28 20:46:20 +02:00
|
|
|
|
2023-05-22 22:06:40 +02:00
|
|
|
void refreshGradients();
|
2022-05-28 20:46:20 +02:00
|
|
|
};
|