プロジェクト

全般

プロフィール

機能 #380 » mac_sound.rb

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
end
(2-2/2)