• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
reloading IKImageBrowserView in an IBAction
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

reloading IKImageBrowserView in an IBAction


  • Subject: reloading IKImageBrowserView in an IBAction
  • From: Claus Guttesen <email@hidden>
  • Date: Mon, 23 Feb 2009 22:02:14 +0100

Hi.

I followed the excellent article 'Image Kit Programming Guide' at
http://developer.apple.com/documentation/graphicsimaging/Conceptual/ImageKitProgrammingGuide/Introduction/chapter_1_section_1.html#//apple_ref/doc/uid/TP40004907-CH1-SW1
and have my ImageBrowser working. I want to use it as the basis of an
image-uploader and would like to visualize the upload-progress by
removing the first image. I have connected a button to an IBAction and
can remove the images one by one.

- (IBAction)listImagesButtonClicked:(id)sender {
	NSUInteger n;
	NSArray *myArray;

	if ( [mImages count] > 0 ) {
		myArray = [mImages objectAtIndex:0];
		NSLog(@"%@", [myArray description]);
		[mImages removeObjectAtIndex:0];
		[mImageBrowser reloadData];
		n = [mImages count];
		[numberOfImagesOutputField setIntValue:n];
//		sleep(1);
	}
}

[mImages removeObjectAtIndex:0] removes the first image and
[mImageBrowser reloadData] animates it.

I changed the 'if' to a 'while' but it doesn't animate removals one by
one but is waiting with [mImageBrowser reloadData] until all images
are removed (perhaps IBAction blocks it?) and remove all images at
once.

How can I make the [mImageBrowser reloadData] refresh within the while-loop?

--
regards
Claus

When lenity and cruelty play for a kingdom,
the gentler gamester is the soonest winner.

Shakespeare
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: RE: Question on threads running in my Foundation tool
  • Next by Date: Re: Simple way to traverse 2D array?
  • Previous by thread: (Almost)Newbie Question: Implementing / use a free available source code editor
  • Next by thread: Disabled, auto-disappearing placeholder in search field like Safari, Console.app
  • Index(es):
    • Date
    • Thread