class Shul::Main
Public Class Methods
new(shoes, source)
click to toggle source
# File lib/shul.rb, line 296 def initialize(shoes, source) if source.is_a? Shule then doc = source else xml, type = RXFHelper.read(source) # is the first line an XML processing instruction? begin doc = Shule.new(xml) rescue puts 'Shule: something went wrong' puts '->' + ($!).inspect end end attr = {width: 300, height: 200}.merge doc.root.attributes.to_h bflag = if attr.has_key? :width and attr.has_key? :height then attr[:width] = attr[:width].to_i attr[:height] = attr[:height].to_i false else true end shoes.app(attr) do def reload() puts 'not yet implemented' end #button 'test' do # alert('fun') #end shul = Shul::App.new self, doc, refresh: bflag, \ attributes: {title: 'Shul'} Thread.new do # The following file is generated by Shoes and needs to be # removed to avoid file locks in a thin client server setup. if File.exists? '/tmp/__green_shoes_temporary_file__' then FileUtils.rm '/tmp/__green_shoes_temporary_file__' end end end end
Public Instance Methods
reload()
click to toggle source
# File lib/shul.rb, line 330 def reload() puts 'not yet implemented' end