Skip to content

Commit

Permalink
WIP workspace pin and move requests
Browse files Browse the repository at this point in the history
  • Loading branch information
ids1024 committed Feb 4, 2025
1 parent 29ab323 commit 8d46a2a
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 2 deletions.
2 changes: 1 addition & 1 deletion client-toolkit/src/workspace.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ impl WorkspaceState {
{
Self {
workspace_groups: Vec::new(),
manager: GlobalProxy::from(registry.bind_one(qh, 1..=2, GlobalData)),
manager: GlobalProxy::from(registry.bind_one(qh, 1..=3, GlobalData)),
}
}

Expand Down
31 changes: 30 additions & 1 deletion unstable/cosmic-workspace-unstable-v1.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
THIS SOFTWARE.
</copyright>

<interface name="zcosmic_workspace_manager_v1" version="2">
<interface name="zcosmic_workspace_manager_v1" version="3">
<description summary="list and control workspaces">
Workspaces, also called virtual desktops, are groups of surfaces. A
compositor with a concept of workspaces may only show some such groups of
Expand Down Expand Up @@ -285,6 +285,7 @@
display such workspaces.
</description>
</entry>
<entry name="pinned" value="3" since="3" summary="the workspace is pinned"/>
</enum>

<enum name="zcosmic_workspace_capabilities_v1">
Expand All @@ -293,6 +294,8 @@
<entry name="remove" value="3" summary="remove request is available"/>
<entry name="rename" value="4" since="2" summary="rename request is available"/>
<entry name="set_tiling_state" value="5" since="2" summary="set_tiling_state request is available"/>
<entry name="pin" value="6" since="3" summary="pin and unpin requests are available"/>
<entry name="move" value="7" since="3" summary="move_before and move_after requests are available"/>
</enum>

<event name="capabilities">
Expand Down Expand Up @@ -363,6 +366,32 @@
</description>
</request>

<request name="move_before">
<arg name="other_workspace" type="object" interface="zcosmic_workspace_handle_v1"/>
<arg name="axis", type="uint"/>
</request>

<request name="move_after">
<arg name="other_workspace" type="object" interface="zcosmic_workspace_handle_v1"/>
<arg name="axis", type="uint"/>
</request>

<request name="pin", since="3">
<description summary="pin the workspace">
Request that this workspace be removed.

There is no guarantee the workspace will be actually removed.
</description>
</request>

<request name="unpin", since="3">
<description summary="pin the workspace">
Request that this workspace be removed.

There is no guarantee the workspace will be actually removed.
</description>
</request>

<event name="tiling_state" since="2">
<description summary="indicates if tiling behavior is enabled for this workspace">
This event is emitted immediately after the zcosmic_workspace_handle_v1 is created
Expand Down

0 comments on commit 8d46a2a

Please sign in to comment.