2011-02-15 3 views
1

안녕하세요 저는 많은 데이터를 다운로드하는 응용 프로그램을 만들었으며 왜 애니메이션을 추가하여 화면이로드되고 화면이 멈추는 지 알고 싶습니다. 이미 작동하는 기능을 발견했지만 그것은 단지 버튼을 기능 정지 :이 같아야 이미 animation.the 이미지의이 종류를 사용하는 일부 응용 프로그램 봤어요Objective-C : 화면을 멈추고 애니메이션을로드하는 방법은 무엇입니까?

[super setEditing:(BOOL)editing animated:(BOOL)animated]; 
    self.navigationItem.rightBarButtonItem.enabled = !editing; 

을 : enter image description here 감사

답변

2

비동기 다운로드에는 NSURLDownload를 사용할 수 있습니다. 진행 상황을 결정하는 데 사용할 수있는 대리자 방법이 있습니다.

http://developer.apple.com/library/mac/#documentation/Cocoa/Reference/Foundation/Classes/NSURLDownload_Class/Reference/Reference.html

그런 다음 당신이 진행에게 당신의 이미지가하는 같은 방법으로 표시 할 수있는 NSProgressIndicator를 사용.

+0

발견하지만 사용 \t theRequest = [[[NSMutableURLRequest ALLOC] INIT] 오토 릴리즈]; \t [theRequest setURL : [NSURL URLWithString : @ "URL"]]]; \t [theRequest setHTTPMethod : @ "POST"]; \t [theRequest setValue : postLength forHTTPHeaderField : @ "Content-Length"]; \t [theRequest setValue : @ "application/x-www-form-urlencoded"forHTTPHeaderField : @ "Content-Type"]; \t [theRequest setHTTPBody : postData]; \t \t [theRequest setHTTPShouldHandleCookies : YES]; \t \t theConnection = [[NSURLConnection alloc] initWithRequest : theRequest delegate : self]; \t \t xmlFile = [[NSMutableData data] retain]; – Csabi

+0

간단히 애니메이션을 만들 수 있습니까? – Csabi

+0

@Csabi thats NSProgressIndicator : –

관련 문제