MCPcopy Create free account
hub / github.com/Alexays/Waybar / doUpdate

Method doUpdate

src/modules/hyprland/workspaces.cpp:126–140  ·  view source on GitHub ↗

* Workspaces::doUpdate - update workspaces in UI thread. * * Note: some memberfields are modified by both UI thread and event listener thread, use m_mutex to * protect these member fields, and lock should released before calling AModule::update(). */

Source from the content-addressed store, hash-verified

124 * protect these member fields, and lock should released before calling AModule::update().
125 */
126void Workspaces::doUpdate() {
127 std::unique_lock lock(m_mutex);
128
129 removeWorkspacesToRemove();
130 createWorkspacesToCreate();
131 updateWorkspaceStates();
132 updateWindowCount();
133 sortWorkspaces();
134
135 bool anyWindowCreated = updateWindowsToCreate();
136
137 if (anyWindowCreated) {
138 dp.emit();
139 }
140}
141
142void Workspaces::extendOrphans(int workspaceId, Json::Value const& clientsJson) {
143 spdlog::trace("Extending orphans with workspace {}", workspaceId);

Callers

nothing calls this directly

Calls 1

emitMethod · 0.45

Tested by

no test coverage detected