Coder Social home page Coder Social logo

Comments (3)

amrbashir avatar amrbashir commented on May 27, 2024

I think this is because the GlobalHotKeyManager::register is waiting for the result of whether it was registered successfully or not from another thread. One way to solve this, would be to add another non-blocking API but you won't know if the hotkey was registered successfully or not.

Also may I ask Why do you need to register 30 hotkeys every time you hide/show the window, sounds unnecessary work? hotkeys are usually registered at the beginning of the application so even the currently slow API won't matter. Can you explain your use-case a bit more?

from global-hotkey.

0-don avatar 0-don commented on May 27, 2024

I built a clipboard manager which has a lot of hotkeys based on if its displayed or not.

Since the hotkeys are blocking the actual keys I have to unregister them everytime

from global-hotkey.

amrbashir avatar amrbashir commented on May 27, 2024

This is now fixed and released in 4.1 and the performance of register_all and unregister_all should now match the performance of other platforms and is now 2711x times faster than 4.0

from global-hotkey.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.