mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Aug 2003
Posts: 319
P
Pan-dimensional mouse
OP Offline
Pan-dimensional mouse
P
Joined: Aug 2003
Posts: 319
When you try to activate a tab with "/did -f" inside the dialog INIT event it fails (but doing it via a timer works):
Code:
dialog TestTabActivate {
  title TestTabActivate
  size -1 -1 100 100
  option dbu
  tab "Tab 1", 1, 2 2 96 96
  tab "Tab 2", 2
  tab "Tab 3", 3
}

on *:dialog:TestTabActivate:init:0: {
  did -f $dname 2
}

alias TestTab dialog -mdh TestTabActivate TestTabActivate

vs.
Code:
dialog TestTabActivate {
  title TestTabActivate
  size -1 -1 100 100
  option dbu
  tab "Tab 1", 1, 2 2 96 96
  tab "Tab 2", 2
  tab "Tab 3", 3
}

on *:dialog:TestTabActivate:init:0: {
  .timer 1 0 did -f $dname 2
}

alias TestTab dialog -mdh TestTabActivate TestTabActivate

Joined: Dec 2002
Posts: 5,420
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,420
Thanks for your bug report. That is because the initdialog event takes place before the dialog is visible, so it may not be possible to activate some types of dialog items. As you have discovered, you will need to use the timer in this case.


Link Copied to Clipboard