Re: Best way to put a fixed view in a UITableViewController scene?
Re: Best way to put a fixed view in a UITableViewController scene?
- Subject: Re: Best way to put a fixed view in a UITableViewController scene?
- From: Luther Baker <email@hidden>
- Date: Mon, 25 Nov 2013 20:40:31 -0600
Dropping a UITableView inside of a UIViewController that conforms to the tableview's delegate and datasource is literally as easy as it sounds ... and immensely more flexible.
UITableViewController is convenient but at all necessary.
On Nov 25, 2013, at 8:16 PM, Kyle Sluder <email@hidden> wrote:
>> On Nov 25, 2013, at 6:08 PM, Rick Mann <email@hidden> wrote:
>>
>> Dynamically at runtime, I'd like to put a fixed banner across the top of a UITableViewController scene with some status information. I want this banner to remain fixed at the top, and for the UITableView to live in a frame below it.
>>
>> IB doesn't let you construct this. I wrote this as a bug/enhancement request, and it came back that I should embed a sub view controller in it. But this is incredibly cumbersome, as it forces me to create another view controller to contain it.
>
> Except that’s precisely what UIViewController expects.
>
> Let’s say you have a navigation controller. It is in charge of positioning its child view controllers’ views. You can’t intervene and say “sorry nav controller, but that table view should be 40pt below where you want to put it.” That’s not how view controller containment works.
>
>>
>> What do you guys suggest?
>
> Use an custom container view controller, and watch the WWDC videos on view controller containment to learn why this is the right thing to do.
>
> --Kyle Sluder
> _______________________________________________
>
> 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
_______________________________________________
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