mIRC Home    About    Download    Register    News    Help

Print Thread
#126009 24/07/05 01:23 PM
A
Anonymous
Unregistered
Anonymous
Unregistered
A
hello
does anybody know how do i modify the menu that appears when you rightclick a entry in the channel list?
thank you.

i'm referring to this menu: (see the image)


#126010 24/07/05 04:41 PM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
I don't believe there is away to change the menu in the actual Channel List window itself, could be done with the help of a DLL but I don't know if one has been made.

What you could do is re-create a /LIST alias to list the windows. Creating a @Window to show all the channels etc. And changing the menu can be done with:

Code:
menu @List {
  Some:stuff to do
}


Etc.

I've attempted it for you, you're very welcome to change/modify to suit your needs, and this should give you a good understanding of how Raw events work too.

Code:
;Creates a menu in our new List window (@List).
menu @List {
  ;In a normal Raw event $2 would be the channel but in our window it shows as: 10 users in #Channel.
;So we know we want the 4th token/word.
  Join Channel: join $gettok($sline(@List,1),4,32)
  Show Users:names $gettok($sline(@List,1),4,32)
  -
  More Stuff:here
  -
  And more: stuff
}

;This stores the size of our List window in vars so we don't have one long line.
alias list {
  var %x = $window(Channels List).x 
  var %y = $window(Channels List).y 
  var %w = $window(Channels List).w
  var %h = $window(Channels List).h
  window -lk0C @List %x %y %w %h
  ;The ! before list means we want to use the default /LIST command and not our own.
  !list
}

;Raw 322 is the channel trapping Raw event, $2 is the channel, $3 is the users, and $4- is the channels topic.
Raw 322:*: {
;This hides the default channel list.
  window -h "Channels List"
  ;If our @List window is opened show results otherwise do nothing.
  if ($window(@List)) {
   ;Increases the number of chans there is for titlebar later on.
    inc %chans
   ;Appears like List 100/100 on jingo.ix.us.dal.net Sun Jul 24 10:37:07 2005
    titlebar @List $+(%chans,/,%chans) on $server $asctime
    ;Adds our results in our window.
    aline @List $3 users in $2  - $4-
  }
}

;When channels are done listing we unset the number of channels found.
Raw 323:*: { unset %chans }


I hope this helps.

All the best,

-Andy

#126011 26/07/05 10:01 AM
A
Anonymous
Unregistered
Anonymous
Unregistered
A
Yes, unfortunatly that windows is pretty simple, no rearanging, no header, no space between the columns. Isn't there a easyer way?
smile
thanks for the answer.. momentarly i'm using it as it is.. i have no choice smile
but i hope someone will come up with a better solution.


Link Copied to Clipboard