开发者

iPhone UIToolbar with UIActionSheet style buttons

I have an main window containing a UIToolBarController. In my first tab, I load a UIViewController, where I have an MKMapView. Above the map, I would like a toolbar like on the screenshot below (basically, instead of their UITableView I have an MKMapView...):

iPhone UIToolbar with UIActionSheet style buttons

I'd like to know how I can make this big toolbar on top, and would like to add just une UIActionSheet sty开发者_Python百科le button ("Start" in green, and when clicked switch to red "Stop").

Thanks!

PS: The app from the screenshot is Clock if you want to try.


I don't think it is a toolbar or an action sheet. Your picture shows a UIView with two UILabel objects and two UIButton objects. The UIButton objects have pretty png files as their background images.
The UITableView is simply made not to take the whole screen. In IB a UITableView will normally try to take the whole screen, but you can always resize it.

So, if I was going to try to make this interface in IB I would start with a UIViewController and I would add a UIView (if it wasn't already there). I would resize the UIView to take up half of the screen. Then I would add a UITableView and resize it to take up the other half of the screen. Then I would add the two UILabels and the two UIButtons.
I would wire all of those things to my UIViewController's file. The UIViewController file would have 1 @property that was a UIView, 1 @property that was a UITableView, 2 @properties that were UILabels and 2 @properties that were UIButtons.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜