Skip to content

Commit f00b542

Browse files
committed
[update] CI/CD.
1 parent 1898566 commit f00b542

File tree

2 files changed

+1
-13
lines changed

2 files changed

+1
-13
lines changed

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ After opening swhkd, you can control the program through signals:
4141
- `sudo pkill -USR1 swhkd` - Pause key checking
4242
- `sudo pkill -USR2 swhkd` - Resume key checking
4343
- `sudo pkill -HUP swhkd` - Reload config file
44-
- `sudo pkill -INT swhkd` - Pause key checking temporarily (resume by pressing `super+shift+escape`)
4544

4645
## Configuration
4746

src/daemon.rs

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -157,8 +157,6 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
157157
SIGSYS, SIGTERM, SIGTRAP, SIGTSTP, SIGVTALRM, SIGXCPU, SIGXFSZ,
158158
])?;
159159
let mut paused = false;
160-
let mut temp_paused = false;
161-
162160
let mut last_hotkey: Option<config::Hotkey> = None;
163161
let mut keyboard_states: Vec<KeyboardState> = Vec::new();
164162
let mut keyboard_stream_map = StreamMap::new();
@@ -201,7 +199,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
201199
hotkeys = load_config();
202200
}
203201
SIGINT => {
204-
temp_paused = true;
202+
exit(1);
205203
}
206204
_ => {
207205
let keyboard_devices = evdev::enumerate().filter(check_keyboard);
@@ -273,15 +271,6 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
273271
log::debug!("state_modifiers: {:#?}", keyboard_state.state_modifiers);
274272
log::debug!("state_keysyms: {:#?}", keyboard_state.state_keysyms);
275273
log::debug!("hotkey: {:#?}", possible_hotkeys);
276-
if temp_paused {
277-
if keyboard_state.state_modifiers.iter().all(|x| {
278-
vec![config::Modifier::Shift, config::Modifier::Super].contains(x)
279-
}) && keyboard_state.state_keysyms.contains(evdev::Key::KEY_ESC)
280-
{
281-
temp_paused = false;
282-
}
283-
continue;
284-
}
285274

286275
for hotkey in possible_hotkeys {
287276
// this should check if state_modifiers and hotkey.modifiers have the same elements

0 commit comments

Comments
 (0)