Witam,
podpowiem Ci jak to zrobić używając frameworka C++ Qt. Prawdopodobnie wartość Qt::Key_F32 , która reprezentuje fn. Możesz jeszcze przeszukać wartości i sprawdzić czy Ci odpowiadają : http://doc.qt.io/qt-5/qt.html#Key-enum
Są tam takie wartości jak:
Qt::Key_MediaPlay |
0x01000080 |
A key setting the state of the media player to play |
Qt::Key_MediaStop |
0x01000081 |
A key setting the state of the media player to stop |
Qt::Key_MediaPrevious |
0x01000082 |
|
Qt::Key_MediaNext |
0x01000083 |
|
Qt::Key_MediaRecord |
0x01000084 |
|
Qt::Key_MediaPause |
0x1000085 |
A key setting the state of the media player to pause (Note: not the pause/break key) |
Qt::Key_MediaTogglePlayPause |
0x1000086 |
A key to toggle the play/pause state in the media player (rather than setting an absolute state) |
Te powyższe wartości mogą odpowiadać za kliknięcie pauza muzyki. Należy to sprawdzić. Przykłady kod
void MyClass::keyPressEvent(QKeyEvent *event)
{
if(event ->key() == Qt::MediaPlay)
{
//klawisz odpowiedzialny za MediaPlay
}
}