Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

gbf.sara

macrumors newbie
Original poster
May 30, 2010
5
0
I need to delete/remove an item in my Iphone application. For that i should make tat item wiggle(shake) when i give long press. And then it should ask for an alert to delete or not???

Can anyone guide me plz??? It ll be more helpful if u help me with a source code

Tanx in advance
 
?It ll be more helpful if u help me with a source code

It would be more helpful to us if you spelt correctly and not like 12 year old texting.

There is no single-function to do this. You will need to use core animation to rotate the view containing the item you want to delete. When that animation completes rotate back. To give the impression of wiggling also animate the position a little bit and randomise the amounts of all movements.

And before you ask again, I don't give source code. I expect people to be able to read the documentation and work things out. Copy-and-paste is not programming and you learn nothing from it.
 
It would be more helpful to us if you spelt correctly and not like 12 year old texting.

There is no single-function to do this. You will need to use core animation to rotate the view containing the item you want to delete. When that animation completes rotate back. To give the impression of wiggling also animate the position a little bit and randomise the amounts of all movements.

And before you ask again, I don't give source code. I expect people to be able to read the documentation and work things out. Copy-and-paste is not programming and you learn nothing from it.

Tanx a lot brother
 
You will need to use core animation to rotate the view containing the item you want to delete. When that animation completes rotate back. To give the impression of wiggling also animate the position a little bit and randomise the amounts of all movements.

Are there random elements in the wiggle-to-delete that Apple does (when you press and hold an app icon)? I've never tried to do this in an app view, it's an interesting question. It looks like each icon rotates about its center about 10 degrees, then reverses course. However each icon does not appear in phase with its neighbors - possibly there's a random delay in starting the back-and-forth rotation.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.