lib/teacup/layout.rb in teacup-2.1.2 vs lib/teacup/layout.rb in teacup-2.1.3
- old
+ new
@@ -253,10 +253,11 @@
# horizontal "|-margin-[bottom]-margin-|"
# end
def auto(layout_view=top_level_view, layout_subviews={}, &layout_block)
raise "gem install 'motion-layout'" unless defined? Motion::Layout
- Teacup.get_styled_subviews(top_level_view).each do |view|
+ styled_subviews = top_level_view.subviews.select { |v| v.stylename }
+ styled_subviews.each do |view|
if ! layout_subviews[view.stylename.to_s]
layout_subviews[view.stylename.to_s] = view
end
end