Merge branch 'main' into next

timeout_old
Tassilo Horn 3 years ago
commit 20f040cc4f
  1. 6
      Cargo.lock
  2. 2
      Cargo.toml
  3. 11
      src/tree.rs

6
Cargo.lock generated

@ -150,9 +150,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646"
[[package]] [[package]]
name = "libc" name = "libc"
version = "0.2.107" version = "0.2.108"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fbe5e23404da5b4f555ef85ebed98fb4083e55a00c317800bc2a50ede9f3d219" checksum = "8521a1b57e76b1ec69af7599e75e38e7b7fad6610f037db8c79b127201b5d119"
[[package]] [[package]]
name = "memchr" name = "memchr"
@ -360,7 +360,7 @@ dependencies = [
[[package]] [[package]]
name = "swayr" name = "swayr"
version = "0.10.0" version = "0.10.1"
dependencies = [ dependencies = [
"clap", "clap",
"directories", "directories",

@ -1,6 +1,6 @@
[package] [package]
name = "swayr" name = "swayr"
version = "0.10.0" version = "0.10.1"
description = "A LRU window-switcher (and more) for the sway window manager" description = "A LRU window-switcher (and more) for the sway window manager"
homepage = "https://sr.ht/~tsdh/swayr/" homepage = "https://sr.ht/~tsdh/swayr/"
repository = "https://git.sr.ht/~tsdh/swayr" repository = "https://git.sr.ht/~tsdh/swayr"

@ -93,19 +93,24 @@ impl NodeMethods for s::Node {
if self.node_type == s::NodeType::Con if self.node_type == s::NodeType::Con
&& self.name.is_none() && self.name.is_none()
&& self.app_id.is_none() && self.app_id.is_none()
&& self.pid.is_none()
&& self.shell.is_none()
&& self.window_properties.is_none() && self.window_properties.is_none()
&& self.layout != s::NodeLayout::None && self.layout != s::NodeLayout::None
{ {
Type::Container Type::Container
} else if (self.node_type == s::NodeType::Con } else if (self.node_type == s::NodeType::Con
|| self.node_type == s::NodeType::FloatingCon) || self.node_type == s::NodeType::FloatingCon)
&& self.name.is_some() // Apparently there can be windows without app_id, name,
// and window_properties.class, e.g., dolphin-emu-nogui.
&& self.pid.is_some()
&& self.shell.is_some()
{ {
Type::Window Type::Window
} else { } else {
panic!( panic!(
"Don't know type of node with id {} and node_type {:?}", "Don't know type of node with id {} and node_type {:?}\n{:?}",
self.id, self.node_type self.id, self.node_type, self
) )
} }
} }

Loading…
Cancel
Save