Opening a new window/ document in PhoneGap
===

With the following code, I am able to open a new window on a Desktop browser:

                var thisWin = window;
                var oauthWin = thisWin.open(data, 'twitter-oauth-window', 'location=0,status=0,width=800,height=400');
                var lastUrl = oauthWin.location.href;
                var meh = true;
                var oauthInt = thisWin.setInterval(
                  function()
                  {
                    if (meh)
                    {
                      alert(
                        '\noauthWin.closed: ' + oauthWin.closed +
                        '\noauthWin.location: ' + oauthWin.location +
                        '\nthisWin.closed: ' + thisWin.closed +
                        '\nthisWin.location: ' + thisWin.location +
                        '\noauthWin===thisWin: ' + (oauthWin === thisWin));
                      meh = false;
                    }
					// do more stuff here
				  }
				);
				

In the debug output within the alert:

     oauthWin===thisWin: false

Which is what it should be. However, when the same code is run within PhoneGap, I get the following:

     oauthWin===thisWin: true

Which indicates that PhoneGap has opened the new URL in the same window, replacing the current HTML document.

I wish to open the new URL separately, and to be able to close it upon a certain condition being met, and revert to the old one.

Can this be achieved in PhoneGap, and how?

Thanks!
