From: Jay Freeman (saurik) Date: Wed, 23 Feb 2011 02:11:25 +0000 (-0800) Subject: Export CydiaProgressEvent to JavaScript. X-Git-Tag: v1.1.0%b1~257 X-Git-Url: https://git.saurik.com/cydia.git/commitdiff_plain/4ede7a3fbf5146f4eff4e7eb5293ca5696d4d1c7 Export CydiaProgressEvent to JavaScript. --- diff --git a/MobileCydia.mm b/MobileCydia.mm index 88efb14f..67c87148 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -1366,6 +1366,23 @@ typedef std::map< unsigned long, _H > SourceMap; return event; } ++ (NSArray *) _attributeKeys { + return [NSArray arrayWithObjects: + @"message", + @"package", + @"type", + @"uri", + nil]; +} + +- (NSArray *) attributeKeys { + return [[self class] _attributeKeys]; +} + ++ (BOOL) isKeyExcludedFromWebScript:(const char *)name { + return ![[self _attributeKeys] containsObject:[NSString stringWithUTF8String:name]] && [super isKeyExcludedFromWebScript:name]; +} + - (id) initWithMessage:(NSString *)message ofType:(NSString *)type { if ((self = [super init]) != nil) { message_ = message;