Global Media Controller
Core API Hook: Windows.Media.Control (SMTC) / SendMessage (WM_APPCOMMAND)
Send play, pause, stop, track seeking, and volume adjustment triggers to active Windows media sessions.
Configuration Parameters
| Parameter | Type | Description |
|---|---|---|
| Arguments | string | Target multimedia command action (e.g. 'Play', 'Pause', 'Next', 'Previous', 'Mute', 'VolumeUp', 'VolumeDown'). |
config.json Mapping
{
"Type": "MediaControl",
"Name": "Mute Master Audio",
"Arguments": "Mute"
}
Save inside database layout actions configuration map.
Native Execution Hook
// MediaControl execution logic
int appCommand = action.Arguments switch {
"Play" => 14,
"Pause" => 47,
"Next" => 11,
"Previous" => 12,
"Mute" => 8,
"VolumeUp" => 10,
"VolumeDown" => 9,
_ => 0
};
if (appCommand > 0)
{
var hwnd = Win32.GetForegroundWindow();
Win32.SendMessageW(hwnd, Win32.WM_APPCOMMAND, hwnd, (IntPtr)((appCommand << 16) | 1));
}
Executed within IsoCore remapping runtime loop.
← Back to Actions Directory
IsoKey Module: MediaControl