Sha256: d9e47956875702674083d3b2e036b30cb484dc4bf730fc5420ef6db9535539fe
Contents?: true
Size: 892 Bytes
Versions: 3
Compression:
Stored size: 892 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
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
animoto-0.1.1.beta1 | ./lib/animoto/support/visual.rb |
animoto-0.1.0.beta1 | ./lib/animoto/support/visual.rb |
animoto-0.1.0.beta0 | ./lib/animoto/support/visual.rb |