Sha256: 37203fce75fb2a34dec9599da579f9483e06017fda151d610224a7a768190401
Contents?: true
Size: 495 Bytes
Versions: 1
Compression:
Stored size: 495 Bytes
Contents
# frozen_string_literal: true module Doomfire # Same output as the Terminal class, but this runs in a separate thread, # so the main process can continue with its work class Spinner < Terminal def run @thread = Thread.start { fire_loop } end def stop @exit_requested = true @thread.join end private def prepare_output @fire_width = Doomfire::WindowSize.new.terminal_width Paint.mode = 0xFFFFFF clear_screen end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
doomfire-0.2 | lib/doomfire/spinner.rb |