iphone: rotating flipped view when rotating visible view -


I have a view controller when the view controller rotates, which has two views which I switch between the use of flip animation Are there. The problem appears if I follow these steps:

  1. Rotate the device when viewing the table view.
  2. Click the info button.
  3. Rotate the device (InfoView appears to be spreading).
  4. Click the info button (the table view appears to be spread)

It looks like the view has not been added in the supervision, because it is part of composite ideas Was not there when the device was rotated. Is this view changed automatically?

Below is a code sample

  - (zero) viewDidoadload {[Super Viewedload]; // Background image background image = [[UIImageView alloc] initWithImage: [UIImage imageNamed: @ "bg-app.png"]]; BackgroundIMAGE Autorsmings = (UIViewAutoresizingFlexibleWidth | UIVuatorisingFluxibilite); [Self.view addSubview: backgroundImageView]; [See background image release]; // infoView aboutImageView = [[UIImageView alloc] initWithImage: [UIImage imageNamed: @ "About."]]; AboutImageView.autoresizingMask = (UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight); // tableView self.tableView = [[[UITableView alloc] initWithFrame: [[UIScreen main screen] border] Style: UITableViewStylePlain] autorelease]; // Set the line height once for display reasons Self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone; Self.tableView.rowHeight = 75; Self.tableView.backgroundColor = [UIColor clear collar]; Self.tableView.autoresizingMask = (UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHyight); Self.tableView.delegate = self; Self.tableView.dataSource = self; Self.tableView.autoresizesSubviews = Yes; // Set line height for display reasons [Self.view addSubview: tableView]; // [TableView release]; [Self.view setAutoresizingMask: UIViewAutoresizingFlexibleHyight | UIViewAutoresizingFlexibleWidth]; // Change the shape on rotation // Info button UIButton * InfoDarkButtonType = [Maintaining UIButtonTypeInfoLight] with [[UIButton Button]; InfoDarkButtonType.frame = CGRectMake (0.0, 0.0, 25.0, 25.0); InfoDarkButtonType.backgroundColor = [UIColor clear collar]; [InfoDarkButtonType addTarget: self action: @ selector (Sucnapratikriya: Control Event: UIControlEventTouchUpInside]; UIBarButtonItem * buttonInfo = [[UIBarButtonItem alloc] initWithCustomView: infoDarkButtonType]; Self.navigationItem.rightBarButtonItem = buttonInfo; [InfoDarkButtonType release]; Self.navigationItem .rightBarButtonItem = buttonInfo; [Btnanfo release];} // override to allow orientations other than the default portrait orientation - (BOOL) Chahiaayutrotettointrfesorenteshn: (Uaianprfesoriynteshn) Intrfesorianteshn {// writ N Yes, supported orientation returns to yes;} - Sucnaakshn (zero): (id) sender clicked on {Anselog (@ "Button"); [UIView Shuruanumtiya zero reference: zero]; [UIView Setanimeshnkrn period: 0.75]; / * sub term here * / UIView * supervision; if ((observed = [table visual supervision])) {[UIView Setanimeshn translation: UIViewAnimationTransitionFlipFromRightView: supervision cache: Yes] [table view Nikalenprospaviwu]; [Add Supervisorviewview: About imageview]; } Else if ((observed = [About Image visual supervision])) {[UIView Setanimeshn Tronsishn: UIViewAnimationTransitionFlipFromLeft forView: Supervision cache: Yes]; [About Removing AmmrospaveView]; [Add Supervision Feature: Table View]; } [UIView commitAnimations]; }  

thanks

Try to see the code: Willapière: Animated Your view will appear every time. See load is called once.


Comments

Popular posts from this blog

asp.net - Javascript/DOM Why is does my form not support submit()? -

sockets - Delphi: TTcpServer, connection reset when reading -

javascript - Classic ASP "ExecuteGlobal" statement acting differently on two servers -