What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » WLM Plus! Help » Two problems irking me

Two problems irking me
Author: Message:
TheGuruSupremacy
Full Member
***

Avatar

Posts: 367
Reputation: 19
34 / Male / Flag
Joined: Nov 2006
RE: Two problems irking me
quote:
Originally posted by MeEtc
i would, but i'm using a different version. can you just post what you edited, so that I can change it?

to main.js at the bottom put:

var aSent = new Array();

then:

code:
function OnEvent_ChatWndSendMessage(wnd,message){
    aSent[wnd.Handle] = message;
    if(message.match(/\(!WAT\)/gi)){
        return message.replace(/\(!WAT\)/gi,sendCurrentSong('Winamp',prefs.get('wat')));
    }else if(message.match(/\(!IWAT\)/gi)){
        return message.replace(/\(!IWAT\)/gi,sendCurrentSong('iTunes',prefs.get('wat')));
    }else if(message.match(/\(!WWAT\)/gi)){
        return message.replace(/\(!WWAT\)/gi,sendCurrentSong('WMP',prefs.get('wat')));
    }else if(message.match(/\(!JWAT\)/gi)){
        return message.replace(/\(!JWAT\)/gi,sendCurrentSong('jetAudio',prefs.get('wat')));
    }else if(message.match(/\(!MWAT\)/gi)){
        return message.replace(/\(!MWAT\)/gi,sendCurrentSong('MusicMonkey',prefs.get('wat')));
    }
   
    ob = {"text" : false}
    triggerEvent("OnEvent_ChatWndSendMessage", wnd, message, ob);
    if(ob.text){
        return ob.text;
    }
   
    switch(message){
        case "/pause" : getPlayer().Pause();return '';
        case "/play" : getPlayer().Play();return '';
        case "/stop" : getPlayer().Stop();return '';
        case "/next" : getPlayer().Next();return '';
        case "/prev" : getPlayer().Prev();return '';
        case "/sendsong" : transferSong(wnd);return '';
        case "/lyrics" : openLyricWnd();return'';
    }
   
}




function OnEvent_ChatWndReceiveMessage(wnd, origin, message){


  if (aSent[wnd.Handle] === message) {
        delete aSent[wnd.Handle];
    } else {
        var remoteSong = prefs.get('remote/song');
        var remoteSend = prefs.get('remote/send');
        var remoteShare = prefs.get('remote/shared');
       
        remoteSong = (remoteSong == -1 ) ?  "!np" : remoteSong;
        remoteSend= (remoteSend == -1 ) ?  "!sendsong" : remoteSend;
        remoteShare = (remoteShare == -1 ) ?  "!addtoshared" : remoteShare;
   

   
        if(remoteSong != "" && prefs.get('remote/enabled/song')){
            if(message.match(new RegExp("^" + remoteSong.preg_quote() + "$","i"))){
                wnd.SendMessage(sendCurrentSong());
            }
        }
        if(remoteSend != "" && prefs.get('remote/enabled/send')){
            if(message.match(new RegExp("^" + remoteSend.preg_quote() + "$","i"))){
               
                if(!transferSong(wnd,1)){
                    wnd.SendMessage(prefs.get('notrunning').replace('{player}',"unknown"));
                }
               
            }
        }
       
        if(remoteShare != "" && prefs.get('remote/enabled/shared')){
            if(message.match(new RegExp("^" + remoteShare.preg_quote() + "$","i"))){
                copyToShareingFolder(wnd.Contacts, wnd);
            }
        }
       
    }
}


04-30-2007 08:47 PM
Profile PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
Two problems irking me - by MeEtc on 04-30-2007 at 05:57 PM
RE: Two problems irking me - by TheGuruSupremacy on 04-30-2007 at 07:17 PM
RE: Two problems irking me - by MeEtc on 04-30-2007 at 07:33 PM
RE: Two problems irking me - by TheGuruSupremacy on 04-30-2007 at 07:38 PM
RE: Two problems irking me - by MeEtc on 04-30-2007 at 08:06 PM
RE: RE: Two problems irking me - by TheGuruSupremacy on 04-30-2007 at 08:28 PM
RE: Two problems irking me - by MeEtc on 04-30-2007 at 08:35 PM
RE: Two problems irking me - by TheGuruSupremacy on 04-30-2007 at 08:47 PM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On