Sha256: 2854d1cb702bc8e703cc1a492c205c7d8abd11d6bd80030fd365300e826d4e93
Contents?: true
Size: 893 Bytes
Versions: 1
Compression:
Stored size: 893 Bytes
Contents
module Animoto module Support module Visual # Setter for spotlighting, which instructs the director to give special attention # to this visual when directing. # # @param [Boolean] bool true if this visual should receive special attention def spotlit= bool @spotlit = bool end # Returns true if this visual is spotlit. # # @return [Boolean] whether or not this visual is spotlit def spotlit? @spotlit end # Returns a representation of this Visual as a Hash # # @return [Hash{String=>Object}] this Visual as a Hash def to_hash hash = super rescue {} hash['spotlit'] = spotlit? unless @spotlit.nil? hash['type'] = self.class.name.split('::').last.gsub(/(^)?([A-Z])/) { "#{'_' unless $1}#{$2.downcase}" } hash end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
animoto-1.0.0 | ./lib/animoto/support/visual.rb |