Method: Color.const_missing
- Defined in:
- lib/color.rb
.const_missing(name) ⇒ Object
:nodoc:
141 142 143 144 145 146 147 148 149 150 151 152 153 154 |
# File 'lib/color.rb', line 141 def const_missing(name) #:nodoc: case name when "VERSION", :VERSION, "COLOR_TOOLS_VERSION", :COLOR_TOOLS_VERSION warn "Color::#{name} has been deprecated. Use Color::COLOR_VERSION instead." Color::COLOR_VERSION else if Color::RGB.const_defined?(name) warn "Color::#{name} has been deprecated. Use Color::RGB::#{name} instead." Color::RGB.const_get(name) else super end end end |