]> git.saurik.com Git - cydia.git/commitdiff
Fixed _blank behavior for cydia:// due to prophylactic swapping.
authorJay Freeman (saurik) <saurik@saurk.com>
Sat, 28 Feb 2009 09:24:13 +0000 (09:24 +0000)
committerJay Freeman (saurik) <saurik@saurik.com>
Thu, 30 Sep 2010 07:09:50 +0000 (07:09 +0000)
UICaboodle/BrowserView.m

index 68427d254e5c126aaa445f5e5241b018d60bd237..ed6ddbe1f8ff2684aff1ccd8a9e00ff4cf51abe0 100644 (file)
         [book_ pushPage:page];
 }
 
-- (BOOL) getSpecial:(NSURL *)url {
+- (BOOL) getSpecial:(NSURL *)url swap:(BOOL)swap {
 #if ForSaurik
     NSLog(@"getSpecial:%@", url);
 #endif
         return false;
 
     if (page != nil)
-        [self swapPage:page];
+        if (swap)
+            [self swapPage:page];
+        else
+            [self pushPage:page];
     return true;
 }
 
 
     if (NSURL *url = [request URL]) {
         if (name == nil) unknown: {
-            if (![self getSpecial:url]) {
+            if (![self getSpecial:url swap:NO]) {
                 NSString *scheme([[url scheme] lowercaseString]);
                 if ([scheme isEqualToString:@"mailto"])
                     [delegate_ openMailToURL:url];
         goto ignore;
     }
 
-    if ([self getSpecial:url])
+    if ([self getSpecial:url swap:YES])
         goto ignore;
     else if ([WebView _canHandleRequest:request])
         goto use;