Skip to content

Commit

Permalink
* Fixed: post button isn't disabled while post controller is sending
Browse files Browse the repository at this point in the history
  • Loading branch information
joehewitt committed Aug 11, 2009
1 parent dd27ba5 commit 203f5af
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions src/TTPostController.m
Original file line number Diff line number Diff line change
Expand Up @@ -60,16 +60,11 @@ - (void)showActivity:(NSString*)activityText {
_activityView.frame = CGRectOffset(CGRectInset(_textEditor.frame, 13, 13), 2, 0);
_activityView.hidden = NO;
_textEditor.textView.hidden = YES;
self.navigationItem.rightBarButtonItem.enabled = NO;
} else {
_activityView.hidden = YES;
_textEditor.textView.hidden = NO;
}
}

- (void)enableButtons:(BOOL)enabled {
for (int i = 1; i < _navigationBar.items.count; ++i) {
UIBarButtonItem* item = [_navigationBar.items objectAtIndex:i];
item.enabled = enabled;
self.navigationItem.rightBarButtonItem.enabled = YES;
}
}

Expand Down Expand Up @@ -349,7 +344,6 @@ - (void)post {
if (shouldDismiss) {
[self dismissWithResult:nil animated:YES];
} else {
[self enableButtons:NO];
[self showActivity:[self titleForActivity]];
}
}
Expand Down Expand Up @@ -414,7 +408,6 @@ - (void)dismissWithResult:(id)result animated:(BOOL)animated {
}

- (void)failWithError:(NSError*)error {
[self enableButtons:YES];
[self showActivity:nil];

NSString* title = [self titleForError:error];
Expand Down
Binary file modified src/Three20.bundle/de.lproj/Localizable.strings
Binary file not shown.

0 comments on commit 203f5af

Please sign in to comment.