Code: Select all
Repeat
Event = WaitWindowEvent()
Select Event
Case #PB_Event_Timer
If State = #playing
CocoaMessage(@time, NSSound, "currentTime")
SetGadgetState(ProgressBar_0, PeekD(@time))
SetGadgetText(Text_2, FormatDate("%ii:%ss", time))
EndIf
Case #PB_Event_GadgetDrop
Files = EventDropFiles()
FileCount = CountString(files, #LF$) + 1
For i = 1 To FileCount
AddAudio(PlayList(), StringField(Files, i, #LF$), #False)
Next
RefreshList()
EndSelect
Untill quit