title: Appcelerator. Using swipe to open window
body: <p>I am developing an iOS app in Appcelerator and I want to switch between windows with the use of a swipe event listener. How can I do this? The below code does not work. The current window that I "start" from contains a table.</p>
  
  <pre><code>var window = Ti.UI.currentWindow;
  
  window.addEventListener('swipe', function() {
  
      // Create the new window
  
      var win = Titanium.UI.createWindow({
  
          title: 'Contacts',  
          url:'contacts_simple.js'
  
      });
  
      // Animate the page turn
  
      Titanium.UI.currentTab.open(win, {animated:false});
  
  });
  </code></pre>