matty
Scripting Guru
Posts: 8336 Reputation: 109
39 / /
Joined: Dec 2002
Status: Away
|
RE: [Request] Minimize to tray on focus contact window with a hotkey
code: var VK_ESC = 0xA;
var WM_CLOSE = 0x10;
function OnEvent_Initialize(bMessengerStart){
MsgPlus.AddTimer('_minimize_window', 100);
}
function OnEvent_Timer(sTimerId){
if (Interop.Call('user32', 'GetForegroundWindow') === Messenger.ContactListWndHandle){
if (Interop.Call('user32', 'GetAsyncKeyState', VK_ESC) !== 0){
Interop.Call('user32', 'SendMessageW', Messenger.ContactListWndHandle, WM_CLOSE, 0, 0);
}
}
MsgPlus.AddTimer(sTimerId, 100);
}
Something like that.....
This post was edited on 04-18-2007 at 01:24 AM by matty.
|
|