core: fix workspace persistence tracking (#11239)

This commit is contained in:
Vaxry 2025-07-27 18:46:23 +02:00 committed by GitHub
parent 5d4b4ecbfb
commit c63d0003a1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 140 additions and 10 deletions

View file

@ -58,8 +58,6 @@ class CWorkspace {
bool m_wasCreatedEmpty = true;
bool m_persistent = false;
// Inert: destroyed and invalid. If this is true, release the ptr you have.
bool inert();
void startAnim(bool in, bool left, bool instant = false);
@ -83,6 +81,8 @@ class CWorkspace {
void rename(const std::string& name = "");
void forceReportSizesToWindows();
void updateWindows();
void setPersistent(bool persistent);
bool isPersistent();
struct {
CSignalT<> destroy;
@ -99,6 +99,9 @@ class CWorkspace {
SP<HOOK_CALLBACK_FN> m_focusedWindowHook;
bool m_inert = true;
SP<CWorkspace> m_selfPersistent; // for persistent workspaces.
bool m_persistent = false;
};
inline bool valid(const PHLWORKSPACE& ref) {