mIRC Homepage
Posted By: Tranks Dialog items overshadowed by group boxes - 19/06/03 09:14 AM
like alot of posts here, this really isnt a 'bug' per say, but the thing is, it makes me mad. i am gonna paste some small code with a dialog and some outputs.
Code:
dialog test {
  title "Test"
  size -1 -1 127 58
  option dbu
  box "Group Box", 1, 2 1 122 45
  text "", 2, 3 48 120 8
  button "Close", 3, 6 10 37 12
  check "Check Box", 4, 6 24 50 10
  radio "Radio Button", 5, 6 34 50 10
}
on *:dialog:test:mouse:*:{ did -ra $dname 2 $did }
alias open_ts_dg { dialog -md test test }

so, the thing is, when passing over the text area (id 2 at the bottom of the dialog), the number 2 will appear in the text field. when you pass over the background, you get 0. when you pass over the group box, you get 1. but, when passing over the button, the check box, and the radio button, you get the id of the group box. so, is it just that the script sees that you are in the group box, and nothing more? am i missing something...?
ANY input will help.
I know this is quite late, but why not try something like.

Code:
on *:dialog:test:mouse:*:{ 
  if ($did == 1) { did -ra test 2 1 }
}

on *:dialog:test:sclick:*: {
  if ($did == 3) { did -ra $dname 2 $did }
  if ($did == 4) { did -ra $dname 2 $did }
  if ($did == 5) { did -ra $dname 2 $did } 
}
to clean it up...

Code:
on *:dialog:test:mouse:1:{
  did -ra test 2 1
}
on *:dialog:test:sclick:3,4,5: {
  did -ra $dname 2 $did
}


(sorry, kinda a neat freak) grin -- you understand
Posted By: Tranks Re: Dialog items overshadowed by group boxes - 19/06/03 07:27 PM
Well, sure i could do an on click, but i was looking for mouse over events, because in some of the dialogs i make a small status bar (of sorts). so, if you roll over a button, or a check, i can have alot more info show on the item. thus keeping some of the button/check lengths small, and still having enough info that the person knows what will happen. so, what i do is write to the dialog's .ini file under a new section. then, just put something like n1=...info... and when someone's mouse goes over ID 1, the info is read from the script. and the on click events would WORK, but i would rather they not click the button (and say erase something) just to get the info. all i am hoping for is that when a mouse is over a button in a group box, that the button's ID is shown.
© mIRC Discussion Forums