How can I slide a view in and out of a window in a Cocoa program

后端 未结 4 689
慢半拍i
慢半拍i 2020-12-28 21:40

I want to have a view on a window and in response to a message (button click or menu) I want to have another view slide down above it, and have the first view resize.

<
4条回答
  •  爱一瞬间的悲伤
    2020-12-28 22:01

    I have never tried, but I think that CoreAnimation has interesting features for this. You have to animate height of view1 from full height to half height and position of view2 from outside its superview to top half of it.

提交回复
热议问题