diff options
author | Jay Freeman (saurik) <saurik@saurik.com> | 2010-11-02 05:59:38 -0700 |
---|---|---|
committer | Jay Freeman (saurik) <saurik@saurik.com> | 2010-11-04 05:30:54 -0700 |
commit | 526ea480654d3ffbcc1bd9561a73dedcd13d8186 (patch) | |
tree | 5e08fc99cb1c207402dd453bb7748d731a9bd59f | |
parent | e17a8c4f2ae16f8daab460936a9b130d024173dd (diff) |
Minor code cleanups to HomeController.
-rw-r--r-- | MobileCydia.mm | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/MobileCydia.mm b/MobileCydia.mm index a9c4ada..1a8f588 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -6321,6 +6321,7 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { - (void) _setMoreHeaders:(NSMutableURLRequest *)request { [super _setMoreHeaders:request]; + if (ChipID_ != nil) [request setValue:ChipID_ forHTTPHeaderField:@"X-Chip-ID"]; if (UniqueID_ != nil) @@ -6328,7 +6329,8 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { } - (void) aboutButtonClicked { - UIAlertView *alert = [[[UIAlertView alloc] init] autorelease]; + UIAlertView *alert([[[UIAlertView alloc] init] autorelease]); + [alert setTitle:UCLocalize("ABOUT_CYDIA")]; [alert addButtonWithTitle:UCLocalize("CLOSE")]; [alert setCancelButtonIndex:0]; @@ -6355,14 +6357,12 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { - (id) init { if ((self = [super init]) != nil) { - UIBarButtonItem *aboutItem = [[UIBarButtonItem alloc] + [[self navigationItem] setLeftBarButtonItem:[[[UIBarButtonItem alloc] initWithTitle:UCLocalize("ABOUT") style:UIBarButtonItemStylePlain target:self action:@selector(aboutButtonClicked) - ]; - [[self navigationItem] setLeftBarButtonItem:aboutItem]; - [aboutItem release]; + ] autorelease]]; } return self; } |