From: Jay Freeman (saurik) Date: Sun, 24 Feb 2008 01:43:54 +0000 (+0000) Subject: Adding Pamphlet for Brian. X-Git-Url: https://git.saurik.com/cydia.git/commitdiff_plain/63a1e4b893d8e63bc4b0d25185cb4f3d21d0072d?hp=7e9862118c3704fba34866f54fb8b2f6ea0afe23 Adding Pamphlet for Brian. --- diff --git a/Cydia.app/reload.png b/Cydia.app/reload.png index 71dc424c..8d06eb49 100644 Binary files a/Cydia.app/reload.png and b/Cydia.app/reload.png differ diff --git a/Cydia.mm b/Cydia.mm index a8474b1f..04c0dbe9 100644 --- a/Cydia.mm +++ b/Cydia.mm @@ -501,6 +501,7 @@ inline float interpolate(float begin, float end, float fraction) { - (void) dealloc; - (void) navigationBar:(UINavigationBar *)navbar poppedItem:(UINavigationItem *)item; +- (void) alertSheet:(UIAlertSheet *)sheet buttonClicked:(int)button; - (id) initWithFrame:(CGRect)frame; - (void) setDelegate:(id)delegate; @@ -537,6 +538,10 @@ inline float interpolate(float begin, float end, float fraction) { } } +- (void) alertSheet:(UIAlertSheet *)sheet buttonClicked:(int)button { + [sheet dismiss]; +} + - (id) initWithFrame:(CGRect)frame { if ((self = [super initWithFrame:frame]) != nil) { views_ = [[NSMutableArray arrayWithCapacity:4] retain]; @@ -579,6 +584,16 @@ inline float interpolate(float begin, float end, float fraction) { } - (void) configurePushed { + UIAlertSheet *sheet = [[[UIAlertSheet alloc] + initWithTitle:@"Sources Unimplemented" + buttons:[NSArray arrayWithObjects:@"Okay", nil] + defaultButtonIndex:0 + delegate:self + context:self + ] autorelease]; + + [sheet setBodyText:@"This feature will be implemented soon. In the mean time, you may add sources by adding .list files to '/etc/apt/sources.list.d' or modifying '/etc/apt/sources.list'."]; + [sheet popupAlertAnimated:YES]; } - (void) reloadPushed { @@ -1135,7 +1150,7 @@ NSString *Scour(const char *field, const char *begin, const char *end) { } - (NSComparisonResult) compareBySectionAndName:(Package *)package { - NSComparisonResult result = [[self section] caseInsensitiveCompare:[package section]]; + NSComparisonResult result = [[self section] compare:[package section]]; if (result != NSOrderedSame) return result; return [self compareByName:package]; @@ -3180,11 +3195,13 @@ NSString *Scour(const char *field, const char *begin, const char *end) { if (size_t count = [changes_ count]) { NSString *badge([[NSNumber numberWithInt:count] stringValue]); [buttonbar_ setBadgeValue:badge forButton:3]; - [buttonbar_ setBadgeAnimated:YES forButton:3]; + if ([buttonbar_ respondsToSelector:@selector(setBadgeAnimated:forButton:)]) + [buttonbar_ setBadgeAnimated:YES forButton:3]; [self setApplicationBadge:badge]; } else { [buttonbar_ setBadgeValue:nil forButton:3]; - [buttonbar_ setBadgeAnimated:NO forButton:3]; + if ([buttonbar_ respondsToSelector:@selector(setBadgeAnimated:forButton:)]) + [buttonbar_ setBadgeAnimated:NO forButton:3]; [self removeApplicationBadge]; } @@ -3658,6 +3675,8 @@ int main(int argc, char *argv[]) { else Packages_ = [Metadata_ objectForKey:@"Packages"]; + system("dpkg --configure -a"); + UIApplicationMain(argc, argv, [Cydia class]); [pool release]; return 0;