Sha256: 57b4a937c49c95cfa2a57d5d4d9f61e3e419e4bae28ea59ba2fb27812c220ee8

Contents?: true

Size: 340 Bytes

Versions: 5

Compression:

Stored size: 340 Bytes

Contents

# @provides MotionKit::CAGradientLayerLayout
# @requires MotionKit::CALayerLayout
# @requires MotionKit::ViewLayout
module MotionKit
  class CAGradientLayerLayout < CALayerLayout
    targets CAGradientLayer

    def colors(values)
      target.colors = values.map { |color| color.is_a?(UIColor) ? color.CGColor : color }
    end

  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
motion-kit-0.9.4 lib/motion-kit-cocoa/layouts/cagradientlayer_layout.rb
motion-kit-0.9.3 lib/motion-kit-cocoa/layouts/cagradientlayer_layout.rb
motion-kit-0.9.2 lib/motion-kit-cocoa/layouts/cagradientlayer_layout.rb
motion-kit-0.9.1 lib/motion-kit-cocoa/layouts/cagradientlayer_layout.rb
motion-kit-0.9.0 lib/motion-kit-cocoa/layouts/cagradientlayer_layout.rb