From 0ff92c0c42d3250eda8e8808bfcc416f102892bc Mon Sep 17 00:00:00 2001 From: Gant Date: Sun, 14 Sep 2014 17:16:17 -0500 Subject: [PATCH 1/2] Added alpha styler for UIViews --- motion/ruby_motion_query/stylers/ui_view_styler.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/motion/ruby_motion_query/stylers/ui_view_styler.rb b/motion/ruby_motion_query/stylers/ui_view_styler.rb index 8d21936..cf16477 100644 --- a/motion/ruby_motion_query/stylers/ui_view_styler.rb +++ b/motion/ruby_motion_query/stylers/ui_view_styler.rb @@ -387,6 +387,9 @@ module RubyMotionQuery @view.rmq_data.validation_errors = values end + def alpha ; view.alpha ; end + def alpha=(v) ; view.alpha = v ; end + end end end From 7da65a76c7bf4dd2ec6ec67acc13585c0aa83337 Mon Sep 17 00:00:00 2001 From: Gant Date: Sun, 14 Sep 2014 17:22:34 -0500 Subject: [PATCH 2/2] added test for UIView alpha kitchen sink --- spec/stylers/_ui_view_styler.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/spec/stylers/_ui_view_styler.rb b/spec/stylers/_ui_view_styler.rb index 63de522..7aefbb7 100644 --- a/spec/stylers/_ui_view_styler.rb +++ b/spec/stylers/_ui_view_styler.rb @@ -57,6 +57,7 @@ class SyleSheetForUIViewStylerTests < RubyMotionQuery::Stylesheet st.rotation = 45 st.tint_color = color.blue st.layer.cornerRadius = 5 + st.alpha = 1.0 end end