fix(detect): fix wrong default feature and improve context information

This commit is contained in:
Federico Terzi 2021-07-30 19:37:18 +02:00
parent 33b9012802
commit bee79eb4a4
2 changed files with 4 additions and 4 deletions

View File

@ -6,8 +6,6 @@ edition = "2018"
build="build.rs" build="build.rs"
[features] [features]
# TODO: REMOVE!!!
default = ["wayland"]
# If the wayland feature is enabled, all X11 dependencies will be dropped # If the wayland feature is enabled, all X11 dependencies will be dropped
# and only EVDEV-based methods will be supported. # and only EVDEV-based methods will be supported.
wayland = ["sctk"] wayland = ["sctk"]

View File

@ -31,7 +31,7 @@ mod sync;
use std::cell::RefCell; use std::cell::RefCell;
use std::collections::HashMap; use std::collections::HashMap;
use anyhow::Result; use anyhow::{Context as AnyhowContext, Result};
use context::Context; use context::Context;
use device::{get_devices, Device}; use device::{get_devices, Device};
use keymap::Keymap; use keymap::Keymap;
@ -131,7 +131,9 @@ impl Source for EVDEVSource {
let state = State::new(&keymap)?; let state = State::new(&keymap)?;
info!("Querying modifier status..."); info!("Querying modifier status...");
if let Some(modifiers_state) = sync::get_modifiers_state()? { if let Some(modifiers_state) =
sync::get_modifiers_state().context("EVDEV modifier context state synchronization")?
{
debug!("Updating device modifier state: {:?}", modifiers_state); debug!("Updating device modifier state: {:?}", modifiers_state);
for device in &mut self.devices { for device in &mut self.devices {