2015-07-09 14:23:36 +02:00
|
|
|
|
2015-07-14 13:08:28 +02:00
|
|
|
class RegisterView
|
2015-07-09 14:23:36 +02:00
|
|
|
|
|
|
|
@@register_names = (0..8).collect {|i| "r#{i}"}
|
|
|
|
|
|
|
|
def initialize at_y
|
|
|
|
super()
|
|
|
|
@registers = {}
|
|
|
|
x = 0
|
|
|
|
@@register_names.each do |name|
|
2015-07-14 13:08:28 +02:00
|
|
|
reg = Text.new( name )
|
|
|
|
reg.position = Point.new x , at_y
|
2015-07-09 14:23:36 +02:00
|
|
|
x += reg.width + 20
|
|
|
|
@registers[name] = reg
|
|
|
|
self.add_child reg
|
|
|
|
end
|
2015-07-13 22:11:00 +02:00
|
|
|
def draw_me
|
2015-07-09 15:34:02 +02:00
|
|
|
|
|
|
|
end
|
2015-07-09 14:23:36 +02:00
|
|
|
end
|
|
|
|
end
|