matty
Scripting Guru
Posts: 8336 Reputation: 109
39 / /
Joined: Dec 2002
Status: Away
|
RE: Enter Vs Ctrl-Enter etc to send a message
js code: function OnEvent_ChatWndEditKeyDown( pChatWnd, vkKey, bCtrl, bShift ) {
if ( vkKey === 0xD /* VK_RETURN */ ) {
if ( bCtrl === true ) {
pChatWnd.SendMessage( pChatWnd.EditText ); // I don't think this property perserves emoticons
return true;
} else {
/*
too lazy to write code to insert a new line at the current character
position and overwrite any highlighted text... DIY
*/
return true;
}
}
return false;
}
|
|