
class Window

  def updateWindow(object)
    print "Window: #{object.class}-#{object} has changed -> refresh Window \n"
    refresh
  end

  def refresh
    print "Window: refreshed \n"
  end
end

class Button
  attr :name

  def initialize(name)
    @name = name
  end
  
  def pressed
    print "Button: #{to_s} was pressed\n"
  end

  def to_s
    return "\"#{@name}\""
  end
end
  
