Saturngod

What's on my mind

How to indicate long running activity in an iPhone app | tapadoo

<div class="posterous_bookmarklet_entry">
  > <div>
                        <span>[Jump to Comments](http://tapadoo.com/2009/iphone-how-to-do-full-screen-activity-status/#comments)</span>

I’ve seen questions about how feed back to a user that something is pending, where you don’t want any input from the user. An example may be making an XML request for data from your iPhone app back to your server. While it is pending you want to show that your app is busy, but don’t want the user to interact with it.

The iPhone SDK has an activity indicator control that is used for such a purpose, but you may want to essentially make the fact that it is pending to be “modal”

Doing it is quite simple. Here’s how:

  1. Create a new view (this can be done in Interface builder) – Lets call it ProgressView. Make it full size, and stick an activity monitor in the middle of it.
  2. Set the view’s background to black, with its alpha set to 0.5. Create an outlet for the activity indicator in the ProgressView’s controller (call it myActivityIndicator)
  3. In the ProgressView’s controller, add the following code:`

    • (void)viewDidLoad

    {

    [myActivityIndicator startAnimating];

    }`

`- (void)viewWillDisappear: (BOOL)animated

{

[myActivityIndicator stopAnimating];

}

`
  1. Now. Say we are going to do something that’s going to take some time in our main view controller. Just as we are starting it, we do this:`

    [self.view addSubview:progressViewController.view];`

  2. When we have completed our long running task, we do this:`

    [progressViewController.view removeFromSuperview];`

Voila – You have a nice progress indicator “modal dialog” (in old speak).

Of course, there are a number of ways of indicating progress, and you may not wish to disable interaction – Then you just use an activity indicator somewhere obvious in your UI.

Here’s how it looks in my app:

activity

Any other ideas? Please comment.

Digg del.icio.us Facebook Google Bookmarks Technorati LinkedIn * TwitThis
                        <div>

9 Comments

Filed under iphone, iphonedev

                        </div>
                    </div><div class="posterous_quote_citation">via [tapadoo.com](http://tapadoo.com/2009/iphone-how-to-do-full-screen-activity-status/)</div>

Very useful for me. So, share on posterous.

How are iPhone emoji apps made? - Stack Overflow

<div class="posterous_bookmarklet_entry">
  > <div>

The language settings are stored in /User/Library/Preferences/com.apple.Preferences.plist which is on the user partition and isn’t sandboxed off from third-party applications. Enabling Emoji everywhere is a simple matter of adding the KeyboardEmojiEverywhere key to this file and giving it a value of true.

via stackoverflow.com

iPhone SDK instead of Phone Gap

Today, I wrote with iPhone SDK for RSS reading. It's so nice and very happy to write with iPhone SDK. In the previous, I wrote with phone gap. However, Phone Gap is hungry resource framework. I don't want to use that. Of course, we can write one time, just run in 3 phone platform. I don't want it. I want to do only in iPhone. So, I decided to learn again iPhone SDK.<!--more-->

I learn from Stanford University via iTuneU. It’s awesome online learning. Now, I tried new app after 3 vidoes.

.app to .ipa

Create a folder called Payload and place the .app folder inside of that. Zip up the Payload folder using normal compression, then rename the file with a .ipa extension.

One thing to note is that if you want the app’s artwork to appear in iTunes (rather than a generic app icon), you need to place a file called iTunesArtwork (with no extension) into the zip file on the same level as the Payload folder (not in it). This is actually a jpeg file of a 512x512 image and this will appear in iTunes for the app. When I was converting folders, I didn’t have the original images so I just left them off, the app works fine you just get the generic icon.

 

from: http://forums.macrumors.com/showthread.php?t=538622