forum

Multimedia key compatibility

posted
Total Posts
8
This is a feature request. Feature requests can be voted up by supporters.
Current Priority: +0
Topic Starter
AlexanderPD
Usually i use Osu like a real media player, but when i wanna change a song, play, stop or pause i need to go in osu and manually click.
A compatibility with multimedia key on keyboard can be really cool ;)
Metroid
Check the # keys, they do that already.....
mattyu007
Fn keys, you mean?

Those only work on the main menu...
Jeffro
Peppy could implement using this code :)

put this keyboard hook code somewhere :)

actHook= new UserActivityHook(); // create an instance
// hang on events
actHook.KeyDown+=new KeyEventHandler(MyKeyDown);
actHook.Start();

Check it with this:

public void MyKeyDown(object sender, KeyEventArgs e)
{
String strPushedKey = e.KeyCode.ToString();
switch(strPushedKey)
{
case "MediaNextTrack":
//Command for next track in osu!
break;

case "MediaPreviousTrack":
//Command for previous track in osu!
break;

case "MediaPlayPause":
//Command for pausing track in osu!;
break;

case "MediaStop":
//Command for stopping the track in osu!
break;

default:
break;
}
}
Topic Starter
AlexanderPD
i means THAT multimedia keys:



or



or every type, every keyboard have different multimedia keys ;)
i checked on osu!.myname.cfg and i can't found any key for skip, prev or stop the song. Only a pause button binded on "escape" key.
Jeffro
Thats why peppy has to code it. Which is why I provided code :D
peppy

Jeffro wrote:

Thats why peppy has to code it. Which is why I c+p'd code :D
fixed :)
Jeffro

peppy wrote:

Jeffro wrote:

Thats why peppy has to code it. Which is why I c+p'd code :D
fixed :)
Yup c+p'd code from a class I used once in one of my projects ;o I get home tonight so I hope its in the latest build to test it :D
Please sign in to reply.

New reply