class Hasu::Window

Public Class Methods

inherited(other) click to toggle source
# File lib/hasu/window.rb, line 6
def self.inherited(other)
  includer = caller.first.split(":").first
  Hasu.reloads[includer] = File.mtime(includer)
  if other.respond_to?(:prepend, true)
    other.send(:prepend, Hasu::Guard)
  else
    warn "Most of Hasu's nifty features (e.g. error catching, file reloading) are only available on Ruby >= 2.0."
  end
end
new(*) click to toggle source
Calls superclass method
# File lib/hasu/window.rb, line 16
def initialize(*)
  super
  reset  unless Hasu.error
end
run(*args) click to toggle source
# File lib/hasu/window.rb, line 21
def self.run(*args)
  unless @running
    @running = true
    new(*args).show
  end
end