lib/vedeu/null/geometry.rb in vedeu-0.4.54 vs lib/vedeu/null/geometry.rb in vedeu-0.4.55
- old
+ new
@@ -33,14 +33,16 @@
# @return [String|NilClass]
attr_reader :name
# Returns a new instance of Vedeu::Null::Geometry.
#
- # @param name [String|NilClass]
+ # @param attributes [Hash<Symbol => void>]
+ # @option attributes name [String|NilClass]
# @return [Vedeu::Null::Geometry]
- def initialize(name = nil)
- @name = name
- @maximised = false
+ def initialize(attributes = {})
+ @attributes = attributes
+ @name = @attributes[:name]
+ @maximised = @attributes.fetch(:maximised, false)
end
# @return [FalseClass]
def centred
false