diff options
| author | Tom Englund <tomenglund26@gmail.com> | 2024-08-02 23:16:20 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-08-02 23:16:20 +0200 |
| commit | 4141e6755022edc19cd37cd7ad077a93b3bae5bd (patch) | |
| tree | 84805951a685359207bebb3d22cc92d998ffdaa1 /src/managers/CursorManager.hpp | |
| parent | be2dfa36ef635add2d55c96f7616ec61b96e7bb1 (diff) | |
xcursor: rework bootleg xcursor (#7140)
there were a bunch of missing cursors, rework the shape loading add a
function to get legacyname from new wayland names. also bootleg add a
cursor if no theme can be found and no shape. to atleast show
something.
Diffstat (limited to 'src/managers/CursorManager.hpp')
| -rw-r--r-- | src/managers/CursorManager.hpp | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/managers/CursorManager.hpp b/src/managers/CursorManager.hpp index 4324dfb4..44ab2e7b 100644 --- a/src/managers/CursorManager.hpp +++ b/src/managers/CursorManager.hpp @@ -83,14 +83,15 @@ class CCursorManager { }; struct SXCursorManager { - void loadTheme(const std::string& name, int size); - - int lastLoadSize = 0; - - bool themeLoaded = false; - std::string themeName = ""; - SP<SXCursor> defaultCursor; - std::unordered_map<std::string, SP<SXCursor>> cursors; + void loadTheme(const std::string& name, int size); + std::string getLegacyShapeName(std::string const& shape); + SP<SXCursor> createDefaultCursor(); + + int lastLoadSize = 0; + bool themeLoaded = false; + std::string themeName = ""; + SP<SXCursor> defaultCursor; + std::vector<std::pair<std::string, SP<SXCursor>>> cursors; } xcursor; }; |
