mirror of
https://github.com/zhigang1992/rmq.git
synced 2026-01-12 17:52:17 +08:00
Adds styler for separatorInset
This commit is contained in:
@@ -14,6 +14,10 @@ module RubyMotionQuery
|
||||
def allows_selection=(value) ; @view.allowsSelection = value ; end
|
||||
def allows_selection ; @view.allowsSelection ; end
|
||||
|
||||
def separator_inset=(value)
|
||||
@view.separatorInset = value
|
||||
end
|
||||
|
||||
SEPARATOR_STYLES = {
|
||||
none: UITableViewCellSeparatorStyleNone,
|
||||
single: UITableViewCellSeparatorStyleSingleLine,
|
||||
@@ -21,6 +25,5 @@ module RubyMotionQuery
|
||||
}
|
||||
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
@@ -7,6 +7,8 @@ class SyleSheetForUIViewStylerTests < RubyMotionQuery::Stylesheet
|
||||
st.separator_color = st.separator_color
|
||||
st.separator_color = UIColor.redColor
|
||||
|
||||
st.separator_inset = [0, 46, 0, 0]
|
||||
|
||||
st.allows_selection = st.allows_selection
|
||||
st.allows_selection = false
|
||||
end
|
||||
@@ -29,6 +31,7 @@ describe 'stylers/ui_table_view' do
|
||||
v.separatorStyle.should == UITableViewCellSeparatorStyleNone
|
||||
v.separatorColor.should == UIColor.redColor
|
||||
v.allowsSelection.should == false
|
||||
v.separatorInset.should == UIEdgeInsetsMake(0, 46, 0, 0)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user