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

chhoda

macrumors 6502
Original poster
Oct 25, 2008
285
1
Hi all,

I wanted to do a flash animation for my custom dialog as in UIAlertView

I tried the following code

MyAlertView *flashView = [[MyAlertView alloc] initWithFrame:[window frame] withSerialisedData:msg];
[flashView setFrame:CGRectMake(160, 240, 1, 1)];
flashView.center = window.center;
[window addSubview:flashView];

[UIView beginAnimations:mad:"myAnimationID" context:nil];
[UIView setAnimationDuration:2.0];

[flashView setFrame:[window frame]];
// do it!
[UIView commitAnimations];

but it creates a view which starts from center of the screen [width and height not zero, is it because i create a subview of screen width inside this view and add subview to this aert view ? but even in that case should the subviews also not shrink or expand as per their parent view ?] and scrolls towards 0, 0

any help is appreciated

also i saw a mirror image animation of any screen in down part of the screen in an app. How is that done ? [like the dock in mac system]. Also how dificult is to do a glass cracking animation of a certain screen ?

--ch
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.