feat(wm): impl drag to move in append mode

This commit ensures that when a window is dragged over another window container while
WindowContainerBehaviour::Append is set, the window will be removed from its current
container and appended to the target container instead of swapping the positions of the two
containers, as would be the case for WindowContainerBehaviour::Create.

re #72
This commit is contained in:
LGUG2Z
2021-11-15 12:38:08 -08:00
parent 676b643faf
commit 4a19edaab2
6 changed files with 55 additions and 33 deletions

View File

@@ -51,7 +51,7 @@ pub enum SocketMessage {
ToggleFloat,
ToggleMonocle,
ToggleMaximize,
ToggleNewWindowBehaviour,
ToggleWindowContainerBehaviour,
// Current Workspace Commands
ManageFocusedWindow,
UnmanageFocusedWindow,
@@ -142,9 +142,9 @@ pub enum FocusFollowsMouseImplementation {
#[derive(Clone, Copy, Debug, Serialize, Deserialize, Display, EnumString, ArgEnum)]
#[strum(serialize_all = "snake_case")]
pub enum NewWindowBehaviour {
CreateNewContainer,
AppendToFocusedContainer,
pub enum WindowContainerBehaviour {
Create,
Append,
}
#[derive(Clone, Copy, Debug, Serialize, Deserialize, Display, EnumString, ArgEnum)]