Katsuyoshi MATSUMOTO, 2011-11-24 20:54
Module.new do
if command_exist? "afplay"
Plugin::create(:mac_sound).add_event(:play_sound){ |filename, &stop|
SerialThread.new {
bg_system("afplay", filename) if FileTest.exist?(filename) }
stop.call
}
end