mirror of
https://github.com/TimeCrafters/timecrafters_configuration_tool_desktop.git
synced 2025-12-15 13:32:33 +00:00
25 lines
638 B
Ruby
25 lines
638 B
Ruby
module TAC
|
|
class Dialog
|
|
class TACNETDialog < Dialog
|
|
def build
|
|
@dialog_root.style.border_color = [ Palette::TACNET_PRIMARY, Palette::TACNET_SECONDARY ]
|
|
@titlebar.style.background = [ Palette::TACNET_PRIMARY, Palette::TACNET_SECONDARY ]
|
|
|
|
background Gosu::Color::GRAY
|
|
label @options[:message], width: 1.0
|
|
|
|
@sound = Gosu::Sample.new("#{TAC::ROOT_PATH}/media/error_alarm.ogg").play(1, 1, true)
|
|
|
|
button "Close", width: 1.0, margin_top: THEME_DIALOG_BUTTON_PADDING do
|
|
close
|
|
end
|
|
end
|
|
|
|
def close
|
|
super
|
|
|
|
@sound.stop
|
|
end
|
|
end
|
|
end
|
|
end |