diff options
-rwxr-xr-x | Cydia.app/Cydia | 5 | ||||
-rw-r--r-- | Cydia.app/English.lproj/Localizable.strings | 1 | ||||
-rw-r--r-- | Cydia.app/Modes/DOWNGRADE.png (renamed from Cydia.app/Modes/Downgrade.png) | bin | 1176 -> 1176 bytes | |||
-rw-r--r-- | Cydia.app/Modes/INSTALL.png (renamed from Cydia.app/Modes/Install.png) | bin | 2135 -> 2135 bytes | |||
l--------- | Cydia.app/Modes/NEW_INSTALL.png | 1 | ||||
l--------- | Cydia.app/Modes/New Install.png | 1 | ||||
-rw-r--r-- | Cydia.app/Modes/PURGE.png (renamed from Cydia.app/Modes/Purge.png) | bin | 2443 -> 2443 bytes | |||
-rw-r--r-- | Cydia.app/Modes/REINSTALL.png (renamed from Cydia.app/Modes/Reinstall.png) | bin | 2013 -> 2013 bytes | |||
-rw-r--r-- | Cydia.app/Modes/REMOVE.png (renamed from Cydia.app/Modes/Remove.png) | bin | 2552 -> 2552 bytes | |||
-rw-r--r-- | Cydia.app/Modes/UPGRADE.png (renamed from Cydia.app/Modes/Upgrade.png) | bin | 1635 -> 1635 bytes | |||
-rw-r--r-- | Cydia.app/Sources/apt.bigboss.us.com.png | bin | 6405 -> 0 bytes | |||
-rw-r--r-- | Cydia.app/Sources/apt.modmyi.com.png | bin | 5186 -> 0 bytes | |||
-rw-r--r-- | Cydia.app/Sources/apt.saurik.com.png | bin | 1952 -> 0 bytes | |||
-rw-r--r-- | Cydia.app/Sources/repo.smxy.org.png | bin | 737 -> 0 bytes | |||
-rw-r--r-- | Cydia.mm | 156 | ||||
-rwxr-xr-x | Library/free.sh | 1 | ||||
-rwxr-xr-x | Library/move.sh | 2 | ||||
-rw-r--r-- | UICaboodle/BrowserView.m | 3 | ||||
-rw-r--r-- | control | 4 | ||||
-rwxr-xr-x | make.sh | 2 |
20 files changed, 111 insertions, 65 deletions
diff --git a/Cydia.app/Cydia b/Cydia.app/Cydia index 8356734..3c72315 100755 --- a/Cydia.app/Cydia +++ b/Cydia.app/Cydia @@ -1,5 +1,6 @@ #!/bin/bash -Cydia=$(dirname "$0") +C=/${0} +C=${C%/*} declare -a flags [[ :${DYLD_INSERT_LIBRARIES}: == */MobileSubstrate.dylib: ]] && flags[${#flags[@]}]=--substrate -exec "${Cydia}"/Cydia_ "${flags[@]}" -- "$@" 2>>/tmp/cydia.log +exec "${C:-.}"/Cydia_ "${flags[@]}" -- "$@" 2>>/tmp/cydia.log diff --git a/Cydia.app/English.lproj/Localizable.strings b/Cydia.app/English.lproj/Localizable.strings index 01b1a77..3ccfa62 100644 --- a/Cydia.app/English.lproj/Localizable.strings +++ b/Cydia.app/English.lproj/Localizable.strings @@ -95,6 +95,7 @@ "LOGIN" = "Login"; "MAINTAINER" = "Contact"; "MANAGE" = "Manage"; +"MODIFICATIONS" = "Modifications"; "MODIFY" = "Modify"; "MORE_INFORMATION" = "More Information"; "MORE_PACKAGE_SOURCES" = "More Package Sources"; diff --git a/Cydia.app/Modes/Downgrade.png b/Cydia.app/Modes/DOWNGRADE.png Binary files differindex 41c0d70..41c0d70 100644 --- a/Cydia.app/Modes/Downgrade.png +++ b/Cydia.app/Modes/DOWNGRADE.png diff --git a/Cydia.app/Modes/Install.png b/Cydia.app/Modes/INSTALL.png Binary files differindex a83f354..a83f354 100644 --- a/Cydia.app/Modes/Install.png +++ b/Cydia.app/Modes/INSTALL.png diff --git a/Cydia.app/Modes/NEW_INSTALL.png b/Cydia.app/Modes/NEW_INSTALL.png new file mode 120000 index 0000000..475bda6 --- /dev/null +++ b/Cydia.app/Modes/NEW_INSTALL.png @@ -0,0 +1 @@ +INSTALL.png
\ No newline at end of file diff --git a/Cydia.app/Modes/New Install.png b/Cydia.app/Modes/New Install.png deleted file mode 120000 index 3330a1b..0000000 --- a/Cydia.app/Modes/New Install.png +++ /dev/null @@ -1 +0,0 @@ -Install.png
\ No newline at end of file diff --git a/Cydia.app/Modes/Purge.png b/Cydia.app/Modes/PURGE.png Binary files differindex 795fa19..795fa19 100644 --- a/Cydia.app/Modes/Purge.png +++ b/Cydia.app/Modes/PURGE.png diff --git a/Cydia.app/Modes/Reinstall.png b/Cydia.app/Modes/REINSTALL.png Binary files differindex 0b7754c..0b7754c 100644 --- a/Cydia.app/Modes/Reinstall.png +++ b/Cydia.app/Modes/REINSTALL.png diff --git a/Cydia.app/Modes/Remove.png b/Cydia.app/Modes/REMOVE.png Binary files differindex 1b2e691..1b2e691 100644 --- a/Cydia.app/Modes/Remove.png +++ b/Cydia.app/Modes/REMOVE.png diff --git a/Cydia.app/Modes/Upgrade.png b/Cydia.app/Modes/UPGRADE.png Binary files differindex 631b7ef..631b7ef 100644 --- a/Cydia.app/Modes/Upgrade.png +++ b/Cydia.app/Modes/UPGRADE.png diff --git a/Cydia.app/Sources/apt.bigboss.us.com.png b/Cydia.app/Sources/apt.bigboss.us.com.png Binary files differdeleted file mode 100644 index 8c79a38..0000000 --- a/Cydia.app/Sources/apt.bigboss.us.com.png +++ /dev/null diff --git a/Cydia.app/Sources/apt.modmyi.com.png b/Cydia.app/Sources/apt.modmyi.com.png Binary files differdeleted file mode 100644 index 18885ea..0000000 --- a/Cydia.app/Sources/apt.modmyi.com.png +++ /dev/null diff --git a/Cydia.app/Sources/apt.saurik.com.png b/Cydia.app/Sources/apt.saurik.com.png Binary files differdeleted file mode 100644 index f2bfcab..0000000 --- a/Cydia.app/Sources/apt.saurik.com.png +++ /dev/null diff --git a/Cydia.app/Sources/repo.smxy.org.png b/Cydia.app/Sources/repo.smxy.org.png Binary files differdeleted file mode 100644 index 26c9655..0000000 --- a/Cydia.app/Sources/repo.smxy.org.png +++ /dev/null @@ -1423,6 +1423,7 @@ typedef std::map< unsigned long, _H<Source> > SourceMap; /* Source Class {{{ */ @interface Source : NSObject { + CYString depiction_; CYString description_; CYString label_; CYString origin_; @@ -1445,6 +1446,7 @@ typedef std::map< unsigned long, _H<Source> > SourceMap; - (NSComparisonResult) compareByNameAndType:(Source *)source; +- (NSString *) depictionForPackage:(NSString *)package; - (NSString *) supportForPackage:(NSString *)package; - (NSDictionary *) record; @@ -1476,6 +1478,7 @@ typedef std::map< unsigned long, _H<Source> > SourceMap; description_.clear(); label_.clear(); origin_.clear(); + depiction_.clear(); support_.clear(); version_.clear(); defaultIcon_.clear(); @@ -1533,6 +1536,7 @@ typedef std::map< unsigned long, _H<Source> > SourceMap; CYString *value_; } names[] = { {"default-icon", &defaultIcon_}, + {"depiction", &depiction_}, {"description", &description_}, {"label", &label_}, {"origin", &origin_}, @@ -1587,6 +1591,10 @@ typedef std::map< unsigned long, _H<Source> > SourceMap; return [lhs compare:rhs options:LaxCompareOptions_]; } +- (NSString *) depictionForPackage:(NSString *)package { + return depiction_.empty() ? nil : [depiction_ stringByReplacingOccurrencesOfString:@"*" withString:package]; +} + - (NSString *) supportForPackage:(NSString *)package { return support_.empty() ? nil : [support_ stringByReplacingOccurrencesOfString:@"*" withString:package]; } @@ -2094,6 +2102,8 @@ struct PackageNameOrdering : _end } + visible_ = true; + _profile(Package$initWithVersion$Tags) pkgCache::TagIterator tag(iterator_.TagList()); if (!tag.end()) { @@ -2101,8 +2111,12 @@ struct PackageNameOrdering : do { const char *name(tag.Name()); [tags_ addObject:(NSString *)CFCString(name)]; - if (role_ == nil && strncmp(name, "role::", 6) == 0) + if (role_ == nil && strncmp(name, "role::", 6) == 0 && strcmp(name, "role::leaper") != 0) role_ = (NSString *) CFCString(name + 6); + if (visible_ && strncmp(name, "require::", 9) == 0 && ( + true + )) + visible_ = false; ++tag; } while (!tag.end()); } @@ -2162,7 +2176,7 @@ struct PackageNameOrdering : _end essential_ = ((iterator_->Flags & pkgCache::Flag::Essential) == 0 ? NO : YES) || [self hasTag:@"cydia::essential"]; - visible_ = [self hasSupportingRole] && [self unfiltered]; + visible_ &&= [self hasSupportingRole] && [self unfiltered]; } _end } return self; } @@ -2428,7 +2442,7 @@ struct PackageNameOrdering : } - (NSString *) depiction { - return depiction_; + return !depiction_.empty() ? depiction_ : [[self source] depictionForPackage:id_]; } - (Address *) sponsor { @@ -3331,6 +3345,8 @@ static NSArray *Finishes_; for (pkgAcquire::ItemIterator item = fetcher_->ItemsBegin(); item != fetcher_->ItemsEnd(); item++) { if ((*item)->Status == pkgAcquire::Item::StatDone && (*item)->Complete) continue; + if ((*item)->Status == pkgAcquire::Item::StatIdle) + continue; std::string uri = (*item)->DescURI(); std::string error = (*item)->ErrorText; @@ -3991,64 +4007,25 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { [transition_ transition:6 toView:view_]; } -- (void) alertSheet:(UIActionSheet *)sheet buttonClicked:(int)button { - NSString *context([sheet context]); - - if ([context isEqualToString:@"error"]) - [sheet dismiss]; - else if ([context isEqualToString:@"conffile"]) { - FILE *input = [database_ input]; - - switch (button) { - case 1: - fprintf(input, "N\n"); - fflush(input); - break; - case 2: - fprintf(input, "Y\n"); - fflush(input); - break; - default: - _assert(false); - } - - [sheet dismiss]; - } -} - -- (void) closeButtonPushed { - running_ = NO; - - switch (Finish_) { - case 0: - [self resetView]; - break; - - case 1: - [delegate_ suspendWithAnimation:YES]; - break; +- (void) _checkError { + if (_error->PendingError()) { + std::string error; + if (!_error->PopMessage(error)) + _assert(false); - case 2: - system("launchctl stop com.apple.SpringBoard"); - break; + UIActionSheet *sheet = [[[UIActionSheet alloc] + initWithTitle:CYLocalize("ERROR") + buttons:[NSArray arrayWithObjects:CYLocalize("OKAY"), nil] + defaultButtonIndex:0 + delegate:self + context:@"_error" + ] autorelease]; - case 3: - system("launchctl unload "SpringBoard_"; launchctl load "SpringBoard_); - break; + [sheet setBodyText:[NSString stringWithUTF8String:error.c_str()]]; + [sheet popupAlertAnimated:YES]; - case 4: - system("reboot"); - break; + return; } -} - -- (void) _retachThread { - UINavigationItem *item = [navbar_ topItem]; - [item setTitle:CYLocalize("COMPLETE")]; - - [overlay_ addSubview:close_]; - [progress_ removeFromSuperview]; - [status_ removeFromSuperview]; [delegate_ progressViewIsComplete:self]; @@ -4137,6 +4114,71 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { [delegate_ setStatusBarShowsProgress:NO]; } +- (void) alertSheet:(UIActionSheet *)sheet buttonClicked:(int)button { + NSString *context([sheet context]); + + if ([context isEqualToString:@"error"]) + [sheet dismiss]; + else if ([context isEqualToString:@"_error"]) { + [sheet dismiss]; + [self _checkError]; + } else if ([context isEqualToString:@"conffile"]) { + FILE *input = [database_ input]; + + switch (button) { + case 1: + fprintf(input, "N\n"); + fflush(input); + break; + case 2: + fprintf(input, "Y\n"); + fflush(input); + break; + default: + _assert(false); + } + + [sheet dismiss]; + } +} + +- (void) closeButtonPushed { + running_ = NO; + + switch (Finish_) { + case 0: + [self resetView]; + break; + + case 1: + [delegate_ suspendWithAnimation:YES]; + break; + + case 2: + system("launchctl stop com.apple.SpringBoard"); + break; + + case 3: + system("launchctl unload "SpringBoard_"; launchctl load "SpringBoard_); + break; + + case 4: + system("reboot"); + break; + } +} + +- (void) _retachThread { + UINavigationItem *item = [navbar_ topItem]; + [item setTitle:CYLocalize("COMPLETE")]; + + [overlay_ addSubview:close_]; + [progress_ removeFromSuperview]; + [status_ removeFromSuperview]; + + [self _checkError]; +} + - (void) _detachNewThreadData:(ProgressData *)data { _pooled [[data target] performSelector:[data selector] withObject:[data object]]; [data release]; diff --git a/Library/free.sh b/Library/free.sh index 703d302..c38b269 100755 --- a/Library/free.sh +++ b/Library/free.sh @@ -5,6 +5,7 @@ for dir in \ /Library/Wallpaper \ /Library/Ringtones \ /usr/include \ + /usr/lib/pam \ /usr/libexec \ /usr/share \ ; do diff --git a/Library/move.sh b/Library/move.sh index abfe2ed..4a15ca7 100755 --- a/Library/move.sh +++ b/Library/move.sh @@ -45,7 +45,7 @@ function shift_() { dir=${1%/} if [[ -d ${dir} && ! -h ${dir} ]]; then - used=$(du -bs "${dir}") + used=$(/usr/libexec/cydia/du -bs "${dir}") used=${used%%$'\t'*} free=$(df_ /var) diff --git a/UICaboodle/BrowserView.m b/UICaboodle/BrowserView.m index 10cc193..fbec7b7 100644 --- a/UICaboodle/BrowserView.m +++ b/UICaboodle/BrowserView.m @@ -240,7 +240,8 @@ _assert(dup2(fds[1], 1) != -1); _assert(close(fds[0]) != -1); _assert(close(fds[1]) != -1); - execlp("du", "du", "-s", [path UTF8String], NULL); + /* XXX: this should probably not use du */ + execl("/usr/libexec/cydia/du", "du", "-s", [path UTF8String], NULL); exit(1); _assert(false); } @@ -3,9 +3,9 @@ Priority: required Section: Packaging Maintainer: Jay Freeman (saurik) <saurik@saurik.com> Architecture: iphoneos-arm -Version: 1.0.2847-1 +Version: 1.0.2881-1 Replaces: com.sosiphone.addcydia -Depends: apr, apt7, darwintools, pcre, shell-cmds, system-cmds +Depends: apr-lib, apt7-lib, darwintools, pcre, shell-cmds, system-cmds Pre-Depends: dpkg (>= 1.14.25-8) Conflicts: com.sosiphone.addcydia Description: graphical iPhone front-end for APT @@ -1,2 +1,2 @@ #!/bin/bash -/apl/tel/exec.sh :apr:apr-lib:apt7:pcre make package +/apl/tel/exec.sh :apr:apr-lib:apt7:apt7-lib:pcre make package |