menu menubar {
  Музыка:/start_musik
}
alias start_musik { dialog -m start_musik start_musik | st.musik.z }
dialog start_musik {
  title "Музыка При старте..."
  size -1 -1 352 124
  option pixels
  box "Выберите файл:", 1, 10 10 332 50,
  edit "", 2, 20 30 265 20,
  button "...", 3, 295 28 35 23,
  check "Включить", 4, 10 70 85 14,
  button "ОК", 5, 180 90 75 23, ok
  button "Отмена", 6, 270 90 75 23, cancel
  text "Copyright © 2006 by ToMMu", 7, 10 100 155 14,  disable
}
on *:DIALOG:start_musik:sclick:3:set %musik.patch $$file="Выберите Файл" $mircdir\*.mp3 | did -r $dname 2 | did -a $dname 2 %musik.patch
on *:DIALOG:start_musik:sclick:5:{ set %musik.patch $did(start_musik,2,text) | if ($did(start_musik,4).state == 1) { set %on.start.musik 1 }
if ($did(start_musik,4).state == 0) { set %on.start.musik 0 } }
on *:START:{
  if (%on.start.musik == 1) { splay -w %musik.patch }
}
alias st.musik.z {
  if (%musik.patch != $null) { did -r start_musik 2 | did -a start_musik 2 %musik.patch }
  if (%on.start.musik == 1) { did -c start_musik 4 } 
  if (%on.start.musik == 0) { did -u start_musik 4 } 
}