How to make a static image appear after 3 seconds?

后端 未结 4 1045
后悔当初
后悔当初 2021-01-26 12:50

How would I make an image appear after 3 seconds?

4条回答
  •  孤独总比滥情好
    2021-01-26 13:10

    I haven't used XCode in awhile, but I'll take a stab for ya..

    1. In your Interface Builder set the image's visibility as hidden

    2. When your app starts up, set some global variable to the current time in an init fxn

    3. In the main control loop for your UI, check if that global var contains a time that is more than 3 seconds ago, if so, change that image's visibility parameter to shown.

    Best I can really say without really taking a look, which isn't possible right now.

    Good luck!

提交回复
热议问题