cocoa touch - How do I change the background image of my iPhone app? -


I've looked around and I've got some code that chooses an image from an array of image objects , But an explanation can not be found.

I would like to make my app a background image and the user can select the next and previous buttons to scroll through some full screen images, such as the background image of them when scrolling Is set in.

I know how to do this in Java, but this app can not do this app.

How to capture the next image in the array or by which code is added back to the next code?

Then it needs to be clearly displayed.

I have used a layered architecture with an MVC style approach, but it has to be kept with no objective purpose.

Do the buttons call the appropriate methods of the so-called delegates, who attract the representatives and bring the images back?

Will the buttons use the returned pictures and really want to handle the reconstruction?

I appreciate the help.

Regards

Forward

Raise the answer by syoleen.

  NSArray * names = [NSArray array specialist: @ "file 1.png" @ "file 2 page", @ "file 3 page", zero]; Int r = rand ()% ([NSArray count]); Self.view.backgroundColor = [UIColor colorWithPatternImage: [UIImage imageNamed: [name objectAtIndex: r]]];  

(This is from memory so there may be some typo in it)


Comments

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -