title: Split View Controller with a sliding master view , swipe gesture
body: <p>I am working on an iPad application, It has the split view and i want to allow the master view to be displayed/hidden with a swipe gesture similar to the way the mail app from Apple now works. I have created the split view. Could anyone please tell me how to hide/show the master view. I also want to place a button in the detail view so if user clicks that button if master view is open it will hide it, if its already hidden by pressing the same button it will show the master view. </p>
  
  <p>Help appreciated </p>
  
  <p>Thanks</p>
  
  <pre><code>MasterViewController *masterViewController = [[MasterViewController alloc] init];
  UINavigationController *masterNavigationController = [[UINavigationController alloc] initWithRootViewController:masterViewController];
  
  DetailViewController *detailViewController = [[DetailViewController alloc] init];
  UINavigationController *detailNavigationController = [[UINavigationController alloc] initWithRootViewController:detailViewController];
  
  self.splitViewController = [[UISplitViewController alloc] init];
  self.splitViewController.viewControllers = [[NSArray alloc] initWithObjects:masterNavigationController,detailNavigationController, nil];
  self.window.rootViewController = self.splitViewController;
  
  [self.window addSubview:self.splitViewController.view];
  </code></pre>