简体   繁体   English

Facebook iPhone应用程序:根视图动画样式

[英]Facebook iPhone application: root view animation style

I'm working on an application that has the same layout as Facebook. 我正在开发一个与Facebook布局相同的应用程序。 I have several icons on the home screen and would like to to make my viewController appear like when one of the icons are tapped. 我在主屏幕上有几个图标,并希望使我的viewController出现在点击其中一个图标时的样子。

Any idea on how it works? 关于它如何工作的任何想法?

Are you asking how to make a view appear in the standard way when the icon is tapped? 您是否在问如何在点击图标时使视图以标准方式显示? ie how to make a button which is an image 即如何制作一个按钮,它是一个图像

Or 要么

are you asking how to make the view expand out like they do in the facebook app? 您是否在问如何使视图像在Facebook应用程序中那样展开?

If your are asking the first one, you need to drag on a button in interface builder, then select it, in the button attributes window, in the first tab, in the 'type' drop-down (which is default to rounded rect), choose custom. 如果您要询问第一个,则需要在界面生成器中拖动一个按钮,然后在按钮属性窗口的第一个选项卡的“类型”下拉列表中将其选中(默认为四舍五入) ,选择自定义。 then set either the image or background to your image (see whatever looks better). 然后将图片或背景设置为您的图片(查看效果更好的图片)。 You can then link it up like a normal button with an IBAction. 然后,您可以将其像普通按钮一样与IBAction链接起来。

If you are asking the second question, how do you make the views expand out and shrink back, then check out my tutorial: 如果您要问第二个问题,如何使视图扩展和缩小,然后查看我的教程:

How to make expanding/shrinking views on iPhone SDK 如何在iPhone SDK上进行放大/缩小视图

Adam 亚当

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM