diff options
author | Jay Freeman (saurik) <saurik@saurik.com> | 2011-02-23 18:13:36 -0800 |
---|---|---|
committer | Jay Freeman (saurik) <saurik@saurik.com> | 2011-03-07 02:41:12 -0800 |
commit | b8a5d89d89d8662536b2f651fae0598f21ea17bd (patch) | |
tree | 81a39779fc54b30381a54fa70aa174f5ecbfc092 | |
parent | 59befad5fa491ab8e084f7d1e81a2a7430f0f179 (diff) |
Added cydia.setHidesBackButton().
-rw-r--r-- | MobileCydia.mm | 6 | ||||
-rw-r--r-- | UICaboodle/BrowserView.mm | 8 |
2 files changed, 14 insertions, 0 deletions
diff --git a/MobileCydia.mm b/MobileCydia.mm index 4430dc7..d99a0e8 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -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; diff --git a/UICaboodle/BrowserView.mm b/UICaboodle/BrowserView.mm index d5116cf..2a05005 100644 --- a/UICaboodle/BrowserView.mm +++ b/UICaboodle/BrowserView.mm @@ -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; |