diff options
author | Sam Bingner <sam@bingner.com> | 2019-10-25 14:03:20 -1000 |
---|---|---|
committer | Sam Bingner <sam@bingner.com> | 2019-10-25 14:03:20 -1000 |
commit | 464dbc1dfa75123c4cf3fa1bff535d4c1d9cb480 (patch) | |
tree | da79c468572382e7f03e9e1b4df57ce7eec4f12c | |
parent | 4dca52c281a4a4162766762c5bb8f184596025cc (diff) |
Temporary hack to make buttons workv1.1.32%b22
-rw-r--r-- | CyteKit/WebViewController.mm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/CyteKit/WebViewController.mm b/CyteKit/WebViewController.mm index 0394834..e32dfb5 100644 --- a/CyteKit/WebViewController.mm +++ b/CyteKit/WebViewController.mm @@ -798,6 +798,9 @@ static _H<NSMutableSet> Diversions_; } - (NSURLRequest *) webView:(WebView *)view resource:(id)identifier willSendRequest:(NSURLRequest *)request redirectResponse:(NSURLResponse *)response fromDataSource:(WebDataSource *)source { + if ([request.URL.absoluteString isEqualToString:@"https://cydia.saurik.com/fastclick/lib/fastclick.js"]) { + ((NSMutableURLRequest*)request).URL = [NSURL URLWithString:@"file:///var/null"]; + } #if LogBrowser NSLog(@"resource:%@ willSendRequest:%@ redirectResponse:%@ fromDataSource:%@", identifier, request, response, source); #endif @@ -806,6 +809,9 @@ static _H<NSMutableSet> Diversions_; } - (NSURLRequest *) webThreadWebView:(WebView *)view resource:(id)identifier willSendRequest:(NSURLRequest *)request redirectResponse:(NSURLResponse *)response fromDataSource:(WebDataSource *)source { + if ([request.URL.absoluteString isEqualToString:@"https://cydia.saurik.com/fastclick/lib/fastclick.js"]) { + ((NSMutableURLRequest*)request).URL = [NSURL URLWithString:@"file:///var/null"]; + } #if LogBrowser NSLog(@"resource:%@ willSendRequest:%@ redirectResponse:%@ fromDataSource:%@", identifier, request, response, source); #endif |