ios - How can we create slider menu with submenu in swift? -
i working on swift , trying create slider menu, in advance want show submenu menus, trying keep things simple, right done slider menu using tablview show menus facing difficulty create submenu, there more clean way solve problem?
you trying create multilevel tableview. simple solution dynamically update number of rows when cell tapped.
you need create array of n+1 rows each section:
- (section 1), row 1
-- (section 1), row 2
-- (section 1), row 3
- (section 2), row 1
-- (section 2), row 2
-- (section 2), row 3
first row of each section represents top level rows (send money, status checker, etc) , others represent sub-section (personal information, etc).
need implement uitableviewdatasource
methods display first row of each section. create property contain optional nsindexpath
represents selected section
. in datasource
methods check if there's value in property , return rows correspond appropriate section.
Comments
Post a Comment