mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-11-18 06:38:38 +01:00
refactor(kde): converge animation/prefix.rs to the shared AnimationPrefix
KDE's AnimationPrefix gains the Transparency and Workspace variants, so that all three trees share the union {movement, transparency, workspace} (D15/D16). KDE only ever uses Movement; the new variants are accepted in the configuration and on the command line and ignored by the KDE daemon, as macOS ignores Transparency today.
Intentional schema change, regenerated with komorebic static-config-schema: in komorebi-for-kde/schema.json the per-prefix animation settings (enabled, duration, style) change from properties {movement} with additionalProperties false to additionalProperties of the value type (the same shape as the Windows schema). The animation CLI docs list the three values.
Verified: cargo test -p komorebi --lib --test schemas --test animation in komorebi-for-kde: 305 + 5 + 1 passed, 0 failed.
This commit is contained in:
1 parent
14a011c537
commit
ad2281de19
5 files changed
+17
-23
No files matched your search
@@ -11,7 +11,7 @@ Options:
|
||||
-a, --animation-type <ANIMATION_TYPE>
|
||||
Animation type to apply the duration to. If not specified, sets global duration
|
||||
|
||||
[possible values: movement]
|
||||
[possible values: movement, transparency, workspace]
|
||||
|
||||
-h, --help
|
||||
Print help
|
||||
|
||||
@@ -45,7 +45,7 @@ Options:
|
||||
-a, --animation-type <ANIMATION_TYPE>
|
||||
Animation type to apply the style to. If not specified, sets global style
|
||||
|
||||
[possible values: movement]
|
||||
[possible values: movement, transparency, workspace]
|
||||
|
||||
-h, --help
|
||||
Print help (see a summary with '-h')
|
||||
|
||||
@@ -11,7 +11,7 @@ Options:
|
||||
-a, --animation-type <ANIMATION_TYPE>
|
||||
Animation type to apply the state to. If not specified, sets global state
|
||||
|
||||
[possible values: movement]
|
||||
[possible values: movement, transparency, workspace]
|
||||
|
||||
-h, --help
|
||||
Print help
|
||||
|
||||
@@ -15,6 +15,9 @@ use strum::EnumString;
|
||||
#[serde(rename_all = "snake_case")]
|
||||
pub enum AnimationPrefix {
|
||||
Movement,
|
||||
Transparency,
|
||||
/// A workspace sliding in and out of a monitor when it is switched to
|
||||
Workspace,
|
||||
}
|
||||
|
||||
pub fn new_animation_key(prefix: AnimationPrefix, key: String) -> String {
|
||||
|
||||
@@ -3316,12 +3316,9 @@
|
||||
{
|
||||
"description": "Animation configuration prefixed for a specific animation kind",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"movement": {
|
||||
"type": "boolean"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
"additionalProperties": {
|
||||
"type": "boolean"
|
||||
}
|
||||
},
|
||||
{
|
||||
"description": "Animation configuration for all animation kinds",
|
||||
@@ -3335,14 +3332,11 @@
|
||||
{
|
||||
"description": "Animation configuration prefixed for a specific animation kind",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"movement": {
|
||||
"type": "integer",
|
||||
"format": "uint64",
|
||||
"minimum": 0
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
"additionalProperties": {
|
||||
"type": "integer",
|
||||
"format": "uint64",
|
||||
"minimum": 0
|
||||
}
|
||||
},
|
||||
{
|
||||
"description": "Animation configuration for all animation kinds",
|
||||
@@ -3358,12 +3352,9 @@
|
||||
{
|
||||
"description": "Animation configuration prefixed for a specific animation kind",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"movement": {
|
||||
"$ref": "#/$defs/AnimationStyle"
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
"additionalProperties": {
|
||||
"$ref": "#/$defs/AnimationStyle"
|
||||
}
|
||||
},
|
||||
{
|
||||
"description": "Animation configuration for all animation kinds",
|
||||
|
||||
Reference in new issue
Block a user