mirror of
https://github.com/TimeCrafters/timecrafters_configuration_tool_desktop.git
synced 2025-12-15 21:32:35 +00:00
Remove no longer needed clipboard and ffi gems, use new CyberarmEngine::GuiState#needs_repaint? method to only paint when needed- should avoid wasting CPU/GPU time (gain a bit more battery life?), make TACNET connection error visually change UI and also trigger a TACNET dialog when not on the TACNET page
This commit is contained in:
@@ -11,6 +11,8 @@ module TAC
|
||||
|
||||
if ARGV.join.include?("--game-clock-remote-display")
|
||||
push_state(PracticeGameClock::View, remote_control_mode: true)
|
||||
elsif ARGV.join.include?("--intro")
|
||||
push_state(CyberarmEngine::IntroState, forward: TAC::States::Boot)
|
||||
else
|
||||
push_state(TAC::States::Boot)
|
||||
end
|
||||
@@ -29,6 +31,14 @@ module TAC
|
||||
@notification_manager.update
|
||||
end
|
||||
|
||||
def needs_redraw?
|
||||
if current_state.is_a?(Editor)
|
||||
current_state.needs_repaint? || @notification_manager.instance_variable_get(:@drivers).size.positive?
|
||||
else
|
||||
true
|
||||
end
|
||||
end
|
||||
|
||||
def toast(title, message = nil)
|
||||
@notification_manager.create_notification(
|
||||
priority: GosuNotifications::Notification::PRIORITY_HIGH,
|
||||
|
||||
Reference in New Issue
Block a user