diff --git a/Leanote/Settings.bundle/Root.plist b/Leanote/Settings.bundle/Root.plist index 7971ffc..f39fce9 100755 --- a/Leanote/Settings.bundle/Root.plist +++ b/Leanote/Settings.bundle/Root.plist @@ -18,7 +18,7 @@ AutocorrectionType No DefaultValue - 1.0 (961) + 1.3 (1090) IsSecure Key diff --git a/Leanote/controller/BaseViewController.m b/Leanote/controller/BaseViewController.m index 9ebc095..4d58a9c 100644 --- a/Leanote/controller/BaseViewController.m +++ b/Leanote/controller/BaseViewController.m @@ -191,6 +191,7 @@ NSString const *key = @"isSelectOnSearchKey"; } // 为了解决分隔线左侧少15px的情况, iphone, ipad都会存在 + -(void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath { if ([cell respondsToSelector:@selector(setSeparatorInset:)]) { diff --git a/Leanote/controller/me/MeController.m b/Leanote/controller/me/MeController.m index 2d28bf7..547529f 100755 --- a/Leanote/controller/me/MeController.m +++ b/Leanote/controller/me/MeController.m @@ -69,6 +69,15 @@ NSArray *users; [super didReceiveMemoryWarning]; } +- (void) addUserSync +{ + [Common showProgressWithStatus:NSLocalizedString(@"Add account successful and Synchronizing...", nil)]; + // 同步 + [SyncService incrSync:^(BOOL ok) { + [Common hideProgress]; + } progress:nil]; +} + - (void) notifyChangeUser:(BOOL) isAdd { // 取得ios系统唯一的全局的广播站 通知中心 @@ -97,11 +106,9 @@ NSArray *users; // UITableViewRowAnimationBottom if(isAdd) { - [Common showProgressWithStatus:NSLocalizedString(@"Add account successful and Synchronizing...", nil)]; - // 同步 - [SyncService incrSync:^(BOOL ok) { - [Common hideProgress]; - } progress:nil]; + [self addUserSync]; + // 1s后同步 +// [self performSelector:@selector(addUserSync) withObject:nil afterDelay:1.0f]; } else { [self showSuccessMsg:NSLocalizedString(@"Toggle account successful", nil)]; diff --git a/Leanote/controller/note/NoteController.m b/Leanote/controller/note/NoteController.m index c06da04..62d4863 100755 --- a/Leanote/controller/note/NoteController.m +++ b/Leanote/controller/note/NoteController.m @@ -23,7 +23,7 @@ #import -@interface NoteController () +@interface NoteController() @property (strong, nonatomic) NSIndexPath *indexPathToBeDeleted; @property (strong, nonatomic) NSFetchedResultsController *searchedResultsController; @@ -157,7 +157,7 @@ // table的样式, 包括search table view [self setTableStyle:self.tableView]; - [self setTableStyle:self.searchDisplayController.searchResultsTableView]; +// [self setTableStyle:self.searchDisplayController.searchResultsTableView]; // isBlog ? if(self.isBlog) { @@ -420,9 +420,6 @@ // configure the cell Note *note = [fetched objectAtIndexPath:indexPath]; - [self.searchDisplayController.searchResultsTableView setSeparatorInset:UIEdgeInsetsZero]; - [self.searchDisplayController.searchResultsTableView setLayoutMargins:UIEdgeInsetsZero]; - static NSString *cellIdentifier2 = @"NoteCell2"; NoteCell *cell2 = [tableView dequeueReusableCellWithIdentifier:cellIdentifier2]; if (cell2 == nil) { @@ -730,9 +727,6 @@ [tableView deleteSections:[NSIndexSet indexSetWithIndex:sectionIndex] withRowAnimation:UITableViewRowAnimationFade]; break; - case NSFetchedResultsChangeUpdate: - case NSFetchedResultsChangeMove: - break; } } diff --git a/Leanote/controller/notebook/NotebookController.m b/Leanote/controller/notebook/NotebookController.m index a1b85f9..9a526c9 100755 --- a/Leanote/controller/notebook/NotebookController.m +++ b/Leanote/controller/notebook/NotebookController.m @@ -112,7 +112,7 @@ // table的样式 [self setTableStyle:self.tableView]; - [self setTableStyle:self.searchDisplayController.searchResultsTableView]; +// [self setTableStyle:self.searchDisplayController.searchResultsTableView]; // cate if(self.delegate) { @@ -695,9 +695,6 @@ [tableView deleteSections:[NSIndexSet indexSetWithIndex:sectionIndex] withRowAnimation:UITableViewRowAnimationFade]; break; - case NSFetchedResultsChangeMove: - case NSFetchedResultsChangeUpdate: - break; } } diff --git a/Leanote/controller/tag/TagController.m b/Leanote/controller/tag/TagController.m index 1da0769..d1a71a1 100755 --- a/Leanote/controller/tag/TagController.m +++ b/Leanote/controller/tag/TagController.m @@ -17,7 +17,7 @@ #import "Leas.h" #import "NoteController.h" -@interface TagController () +@interface TagController () // 从setting过来要用 @property (nonatomic, strong) Note *note; @@ -108,7 +108,7 @@ // table的样式 [self setTableStyle:self.tableView]; - [self setTableStyle:self.searchDisplayController.searchResultsTableView]; +// [self setTableStyle:self.searchDisplayController.searchResultsTableView]; // cate if(self.delegate) { @@ -575,9 +575,6 @@ [tableView deleteSections:[NSIndexSet indexSetWithIndex:sectionIndex] withRowAnimation:UITableViewRowAnimationFade]; break; - case NSFetchedResultsChangeMove: - case NSFetchedResultsChangeUpdate: - break; } }