summaryrefslogtreecommitdiff
path: root/src/dotwm.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/dotwm.rs')
-rw-r--r--src/dotwm.rs9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/dotwm.rs b/src/dotwm.rs
index 666deff..fd28765 100644
--- a/src/dotwm.rs
+++ b/src/dotwm.rs
@@ -51,6 +51,7 @@ pub enum WmAtom {
}
#[derive(Hash,Eq,PartialEq)]
+#[allow(enum_variant_names)]
pub enum NetAtom {
NetSupported,
NetFullscreen,
@@ -74,7 +75,7 @@ pub struct DotWM {
pub desktops: Vec<Desktop>,
}
-/// DotWM state.
+/// `DotWM` state.
impl DotWM {
/// Create a state of the Dot Window Manager
pub fn new() -> DotWM {
@@ -218,6 +219,12 @@ impl DotWM {
}
}
+impl Default for DotWM {
+ fn default() -> Self {
+ DotWM::new()
+ }
+}
+
impl Drop for DotWM {
fn drop(&mut self) {
close_display(self.display);