#1607 (widget is slow to reload)

- Tweaks for iPad.
This commit is contained in:
David Sinclair 2022-03-09 20:06:14 -07:00
parent 09ac81ecce
commit 4b0f469af5
3 changed files with 14 additions and 16 deletions

View file

@ -123,6 +123,8 @@ UIGestureRecognizerDelegate, UISearchBarDelegate> {
- (void)fadeFeed:(NSString *)feedId; - (void)fadeFeed:(NSString *)feedId;
- (IBAction)tapAddSite:(id)sender; - (IBAction)tapAddSite:(id)sender;
- (void)selectWidgetStories;
- (void)resetToolbar; - (void)resetToolbar;
- (void)layoutHeaderCounts:(UIInterfaceOrientation)orientation; - (void)layoutHeaderCounts:(UIInterfaceOrientation)orientation;
- (void)refreshHeaderCounts; - (void)refreshHeaderCounts;

View file

@ -1798,6 +1798,14 @@ heightForHeaderInSection:(NSInteger)section {
[self didSelectSectionHeaderWithTag:NewsBlurTopSectionAllStories]; [self didSelectSectionHeaderWithTag:NewsBlurTopSectionAllStories];
} }
- (void)selectWidgetStories {
NSInteger tag = [appDelegate.dictFoldersArray indexOfObject:@"widget_stories"];
if (tag != NSNotFound) {
[self didSelectSectionHeaderWithTag:tag];
}
}
#pragma mark - MCSwipeTableViewCellDelegate #pragma mark - MCSwipeTableViewCellDelegate
// When the user starts swiping the cell this method is called // When the user starts swiping the cell this method is called

View file

@ -1699,24 +1699,12 @@
- (void)backgroundLoadNotificationStory { - (void)backgroundLoadNotificationStory {
if (self.inFindingStoryMode) { if (self.inFindingStoryMode) {
if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad) { if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad && [storiesCollection.activeFolder isEqualToString:@"widget_stories"]) {
[self loadFeedDetailView]; [self.feedsViewController selectWidgetStories];
} else if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) { } else {
[self loadRiverFeedDetailView:self.feedDetailViewController withFolder:storiesCollection.activeFolder]; [self loadRiverFeedDetailView:self.feedDetailViewController withFolder:storiesCollection.activeFolder];
// [self showFeedsListAnimated:NO];
// [self hidePopoverAnimated:NO completion:^{
// if (self.feedsNavigationController.presentedViewController) {
// [self.feedsNavigationController dismissViewControllerAnimated:NO completion:^{
// [self loadFeedDetailView];
// }];
// } else {
// [self loadFeedDetailView];
// }
// }];
} }
} } else if (self.tryFeedFeedId && !self.isTryFeedView) {
if (self.tryFeedFeedId && !self.isTryFeedView) {
[self loadFeed:self.tryFeedFeedId withStory:self.tryFeedStoryId animated:NO]; [self loadFeed:self.tryFeedFeedId withStory:self.tryFeedStoryId animated:NO];
} else if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad && !self.isCompactWidth && self.storiesCollection == nil) { } else if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad && !self.isCompactWidth && self.storiesCollection == nil) {
[self loadRiverFeedDetailView:self.feedDetailViewController withFolder:storiesCollection.activeFolder]; [self loadRiverFeedDetailView:self.feedDetailViewController withFolder:storiesCollection.activeFolder];