]> git.saurik.com Git - cydia.git/commitdiff
Added cydia.setHidesBackButton().
authorJay Freeman (saurik) <saurik@saurik.com>
Thu, 24 Feb 2011 02:13:36 +0000 (18:13 -0800)
committerJay Freeman (saurik) <saurik@saurik.com>
Mon, 7 Mar 2011 10:41:12 +0000 (02:41 -0800)
MobileCydia.mm
UICaboodle/BrowserView.mm

index 4430dc7c56eade321e517b306134e9ccf6745c51..d99a0e868073edb305d5540ba14a5489e3c460db 100644 (file)
@@ -4114,6 +4114,8 @@ static NSString *Warning_;
         return @"setButtonImage";
     else if (selector == @selector(setButtonTitle:withStyle:toFunction:))
         return @"setButtonTitle";
+    else if (selector == @selector(setHidesBackButton:))
+        return @"setHidesBackButton";
     else if (selector == @selector(setPopupHook:))
         return @"setPopupHook";
     else if (selector == @selector(setToken:))
@@ -4278,6 +4280,10 @@ static NSString *Warning_;
     [indirect_ setButtonTitle:button withStyle:style toFunction:function];
 }
 
+- (void) setHidesBackButton:(NSString *)value {
+    [indirect_ performSelectorOnMainThread:@selector(setHidesBackButtonByNumber:) withObject:value waitUntilDone:NO];
+}
+
 - (void) _setToken:(NSString *)token {
     Token_ = token;
 
index d5116cfdb7bdb2a54f66ba55086f83ca6b7ac41a..2a05005a46bfe440b5c71e31a7f9a305708b8d60 100644 (file)
@@ -1170,6 +1170,14 @@ static void $UIWebViewWebViewDelegate$webViewClose$(UIWebViewWebViewDelegate *se
     return 980;
 }
 
+- (void) setHidesBackButton:(bool)value {
+    [[self navigationItem] setHidesBackButton:value];
+}
+
+- (void) setHidesBackButtonByNumber:(NSNumber *)value {
+    [self setHidesBackButton:[value boolValue]];
+}
+
 - (void) dispatchEvent:(NSString *)event {
     WebThreadLocked lock;