Skip to content

livesplit-hotkey crate: no hooks being called #341

@MartB

Description

@MartB

Hey im a rust beginner and im wondering why the following code does not work:
(Using windows)

        use livesplit_hotkey::{Hook, KeyCode};
        pub use livesplit_hotkey::{Error, Result};

        let hook = Hook::new().unwrap();
        hook.register(KeyCode::MediaNextTrack, move || {
            println!("captured MediaNextTrack")
        }).unwrap();
        hook.register(KeyCode::MediaPrevTrack, move  || {
            println!("captured MediaPrevTrack")
        }).unwrap();

However nothing triggers here, am i missing something?
I tried to capture more common hotkeys like Numpad0 but that also does not work.

Metadata

Metadata

Assignees

No one assigned

    Labels

    hotkeyThis is about the hotkey implementation.supportThis is a support request.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions