Skip to content

Commit

Permalink
#1247 (Mac Catalyst edition)
Browse files Browse the repository at this point in the history
- Added Manage Account on the Web to Help menu.
  • Loading branch information
Dejal committed Oct 17, 2024
1 parent 8f6635d commit 87dbd4e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
1 change: 1 addition & 0 deletions clients/ios/Classes/BaseViewController.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
- (IBAction)showFindFriends:(id)sender;
- (IBAction)showPremium:(id)sender;
- (IBAction)showSupportForum:(id)sender;
- (IBAction)showManageAccount:(id)sender;
- (IBAction)showLogout:(id)sender;

- (IBAction)findInFeeds:(id)sender;
Expand Down
5 changes: 5 additions & 0 deletions clients/ios/Classes/BaseViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,11 @@ - (IBAction)showSupportForum:(id)sender {
[[UIApplication sharedApplication] openURL:url options:@{} completionHandler:nil];
}

- (IBAction)showManageAccount:(id)sender {
NSURL *url = [NSURL URLWithString:@"https://www.newsblur.com/?next=account"];
[[UIApplication sharedApplication] openURL:url options:@{} completionHandler:nil];
}

- (IBAction)showLogout:(id)sender {
[self.appDelegate confirmLogout];
}
Expand Down
16 changes: 8 additions & 8 deletions clients/ios/Classes/NewsBlurAppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -1932,14 +1932,14 @@ - (void)confirmLogout {
[alertController dismissViewControllerAnimated:YES completion:nil];
[self actuallyLogout];
}]];
#if TARGET_OS_MACCATALYST
[alertController addAction:[UIAlertAction actionWithTitle: @"Delete Account" style:UIAlertActionStyleDestructive handler:^(UIAlertAction * action) {
[alertController dismissViewControllerAnimated:YES completion:nil];
[self actuallyLogout];
NSURL *url = [NSURL URLWithString:@"https://www.newsblur.com/profile/delete_account"];
[[UIApplication sharedApplication] openURL:url options:@{} completionHandler:nil];
}]];
#endif
//#if TARGET_OS_MACCATALYST
// [alertController addAction:[UIAlertAction actionWithTitle: @"Delete Account" style:UIAlertActionStyleDestructive handler:^(UIAlertAction * action) {
// [alertController dismissViewControllerAnimated:YES completion:nil];
// [self actuallyLogout];
// NSURL *url = [NSURL URLWithString:@"https://www.newsblur.com/profile/delete_account"];
// [[UIApplication sharedApplication] openURL:url options:@{} completionHandler:nil];
// }]];
//#endif
[alertController addAction:[UIAlertAction actionWithTitle:@"Cancel"
style:UIAlertActionStyleCancel handler:nil]];
[self.feedsViewController presentViewController:alertController animated:YES completion:nil];
Expand Down

0 comments on commit 87dbd4e

Please sign in to comment.