Skycoder42 / QHotkey

A global shortcut/hotkey for Desktop Qt-Applications
BSD 3-Clause "New" or "Revised" License
548 stars 161 forks source link

Add argument for activated/released signals #67

Closed fameowner99 closed 2 years ago

fameowner99 commented 2 years ago

It will be usefull when you need QHotkey in slot

Shatur commented 2 years ago

But you can use QObject::sender() for it.

fameowner99 commented 2 years ago

But you can use QObject::sender() for it. I tried this way with QObject::sender but this doesnt work image So I did some changes to receive hotkey as an argument.

Shatur commented 2 years ago

Right, it's because you can call it only inside a QObject. Just move your code into an class that derives QObject.

fameowner99 commented 2 years ago

Ok, thank you