[iOS] setting table style for root view controller of a navigation controller
[iOS] setting table style for root view controller of a navigation controller
- Subject: [iOS] setting table style for root view controller of a navigation controller
- From: Donald Hall <email@hidden>
- Date: Wed, 1 Dec 2010 00:02:00 -0600
Hi all,
I have a tab bar based iOS application. The controllers for each tab
bar item are UINavigationControllers, and the root view controllers
for each navigation controller are custom UITableViewControllers.
What is the best way to set the style of the table views? I want at
least one of my table views to have a grouped style, but I can see no
easy way of specifying this.
Here is what I have come up with so far. It seems rather convoluted.
1. In my app delegate in "didFinishLaunchingWithOptions" create an
instance of the custom table view controller using "initWithStyle"
and the Grouped style.
2. Create an instance of UINavigationController using
initWithRootViewController, specifying the controller created in step
1 as the root view controller.
3. Alter the viewControllers property of my UITabBarController (the
root controller of the app) to include the navigation controller
created in step 2.
Is there a simpler way that I am missing? I pored over the docs, but
could not find anything easier that the above.
Thanks in advance for any assistance.
Don
--
Donald S. Hall, Ph.D.
Apps & More Software Design, Inc.
email@hidden
http://www.appsandmore.com
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden