19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
# File 'lib/magnesium/support/factory.rb', line 19
def self.creator(element)
if element == 'textField'
return TextField.new
elsif element == 'button'
return Button.new
elsif element == 'link'
return Link.new
elsif element == 'selectList'
return SelectList.new
elsif element == 'radio'
return Radio.new
elsif element == 'checkBox'
return CheckBox.new
elsif element == 'frame'
return Frame.new
elsif element == 'div'
return Div.new
elsif element == 'span'
return Span.new
elsif element == 'table'
return Table.new
end
end
|