I have an application where I'm working on making a cover with press the menu button, IBAction ( Add a subview). This subview should hold the button which should be accessible. I started a mistake by adding additional buttons in the first scene, so when I press the menu button, the new overlay will not be pop out with extra buttons. Is there any suggestion? Im a newbie for iOS programming. Thanks
- (IBAction) btnMoveTo: (ID) this {UIButton * button = (UIButton *) this; [Self overlay check]; [MovingButton setHidden: false]; [MovingButton2 setHidden: false]; [MovingButton3 setHidden: false]; [MovingButton moveTo: CGPointMake (125,250) Duration: 0.8 Option: curveValues [selectedCurveIndex]]; [MovingButton2 moveTo: CGPointMake (25,250) Duration: 0.8 Option: curveValues [selectedCurveIndex]]; [MovingButton3 moveTo: CGPointMake (225,250) Duration: 0.8 Option: curveValues [selectedCurveIndex]]; } - (zero) overlay check {CGRect frame = [home button frame]; UIView * view = [[UIView alloc] initWithFrame: CGRectMake (frame.origin.x - FrameSizeIncreaseAmount, frame.origin.y - FrameSizeIncreaseAmount, frame.size.width + FrameSizeIncreaseAmount * 2, frame.size.height + FrameSizeIncreaseAmount * 2)] ; View.backgroundColor = [UIColor blackColor]; [Self.view addSubview: view]; [UIView Start Permissions: @ "Fade In" Reference: Zero]; [UIView Set Animation Duration: 0.2]; [View setback color: [[UIColor grayColor] Painted Alfa Component: Maxelfa]]; [UIView commitAnimations]; } Moving buttons, moving buttons and moving button buttons are considered on the new scene. The overlay does not use the button.
Not sure if I understand you correctly, but you should see your overlay you overlayCheck method Add your buttons to create:
- (zero) overlayCheck {CGRect frame = [homeButton frame]; UIView * view = [[UIView alloc] initWithFrame: Sijiaraktmek (Fremkkorin. X - Fremsijh Inket amount, frames. Etc.. - Fremsijh Inket amount, Frame. Size.width + Fremsijh Inksmount * 2 frame. Size.height + Fremsijinsaresmount * 2)] ; View.backgroundColor = [UIColor blackColor]; // --------------------------------------------- // careful If you use the // initWithFame on your movable button then set the frame XY coordinates for your button // how to set CGRectMake (X, Y, width, height); // // X, Y are relative to original viewing / / that you add moving buttons ------------------------- ----- --------------- [see the visual view: moving button 1]; [View AdSense view: moving button]; [View AdSense view: moving button 3]; [Self.view addSubview: view]; [UIView Start Permissions: @ "Fade In" Reference: Zero]; [UIView Set Animation Duration: 0.2]; [View setback color: [[UIColor grayColor] Painted Alfa Component: Maxelfa]]; [UIView commitAnimations]; }
Comments
Post a Comment