config: add xwayland client criteria
This commit is contained in:
parent
a952e658da
commit
bdabb7bbdd
13 changed files with 47 additions and 1 deletions
|
|
@ -234,6 +234,7 @@ pub struct ClientMatch {
|
|||
pub sandboxed: Option<bool>,
|
||||
pub uid: Option<i32>,
|
||||
pub pid: Option<i32>,
|
||||
pub is_xwayland: Option<bool>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ impl Parser for ClientMatchParser<'_> {
|
|||
sandbox_app_id,
|
||||
sandbox_app_id_regex,
|
||||
),
|
||||
(sandbox_instance_id, sandbox_instance_id_regex, uid, pid),
|
||||
(sandbox_instance_id, sandbox_instance_id_regex, uid, pid, is_xwayland),
|
||||
) = ext.extract((
|
||||
(
|
||||
opt(str("name")),
|
||||
|
|
@ -68,6 +68,7 @@ impl Parser for ClientMatchParser<'_> {
|
|||
opt(str("sandbox-instance-id-regex")),
|
||||
opt(s32("uid")),
|
||||
opt(s32("pid")),
|
||||
opt(bol("is-xwayland")),
|
||||
),
|
||||
))?;
|
||||
let mut not = None;
|
||||
|
|
@ -110,6 +111,7 @@ impl Parser for ClientMatchParser<'_> {
|
|||
sandboxed: sandboxed.despan(),
|
||||
uid: uid.despan(),
|
||||
pid: pid.despan(),
|
||||
is_xwayland: is_xwayland.despan(),
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -123,6 +123,7 @@ impl Rule for ClientRule {
|
|||
value!(Uid, uid);
|
||||
value!(Pid, pid);
|
||||
bool!(Sandboxed, sandboxed);
|
||||
bool!(IsXwayland, is_xwayland);
|
||||
Some(())
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue