From: Jay Freeman (saurik) Date: Mon, 1 Sep 2008 01:24:46 +0000 (+0000) Subject: Workaround for display:none issue. X-Git-Tag: v0.9.3900~75 X-Git-Url: https://git.saurik.com/winterboard.git/commitdiff_plain/7ff778ee50f21188ad0510eb953b2950e3f02344 Workaround for display:none issue. --- diff --git a/Library.mm b/Library.mm index 3dfd303..34efd27 100644 --- a/Library.mm +++ b/Library.mm @@ -129,6 +129,8 @@ void WBInject(const char *classname, const char *oldname, IMP newimp, const char /* }}} */ @protocol WinterBoard +- (CGSize) wb_renderedSizeOfNode:(id)node constrainedToWidth:(float)width; +- (void *) _node; - (void) wb_updateDesktopImage:(UIImage *)image; - (UIImage *) wb_defaultDesktopImage; - (NSString *) wb_bundlePath; @@ -786,6 +788,16 @@ static void SBIconLabel$setInDock$(SBIconLabel *self, SEL sel, BOOL return [self wb_setInDock:docked]; } +@class WebCoreFrameBridge; +static CGSize WebCoreFrameBridge$renderedSizeOfNode$constrainedToWidth$(WebCoreFrameBridge *self, SEL sel, id node, float width) { + if (node == nil) + return CGSizeZero; + void **core(reinterpret_cast([node _node])); + if (core == NULL || core[6] == NULL) + return CGSizeZero; + return [self wb_renderedSizeOfNode:node constrainedToWidth:width]; +} + static void SBIconLabel$drawRect$(SBIconLabel *self, SEL sel, CGRect rect) { CGRect bounds = [self bounds]; @@ -1019,6 +1031,8 @@ extern "C" void WBInitialize() { WBRename(true, "UINavigationBar", @selector(setBarStyle:), (IMP) &UINavigationBar$setBarStyle$); WBRename(true, "UIToolbar", @selector(setBarStyle:), (IMP) &UIToolbar$setBarStyle$); + WBRename(true, "WebCoreFrameBridge", @selector(renderedSizeOfNode:constrainedToWidth:), (IMP) &WebCoreFrameBridge$renderedSizeOfNode$constrainedToWidth$); + WBRename(true, "SBApplication", @selector(pathForIcon), (IMP) &SBApplication$pathForIcon); WBRename(true, "SBApplicationIcon", @selector(icon), (IMP) &SBApplicationIcon$icon); WBRename(true, "SBBookmarkIcon", @selector(icon), (IMP) &SBBookmarkIcon$icon); diff --git a/control b/control index 6b9cc14..abc93ad 100644 --- a/control +++ b/control @@ -3,7 +3,7 @@ Priority: optional Section: System Maintainer: Jay Freeman (saurik) Architecture: iphoneos-arm -Version: 0.9.2563-1 +Version: 0.9.2564-1 Description: more powerful, open-source SummerBoard Name: WinterBoard Depends: mobilesubstrate (>= 0.9.2560-1)