Skip to content

Commit

Permalink
Replaces Done button with Cancel button
Browse files Browse the repository at this point in the history
  • Loading branch information
EddyLB committed Aug 5, 2019
1 parent cc238aa commit bdb69aa
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions piwigo/Albums/Album Move/MoveCategoryViewController.m
Expand Up @@ -22,7 +22,7 @@ @interface MoveCategoryViewController () <UITableViewDataSource, UITableViewDele
@property (nonatomic, strong) NSMutableArray *categories;
@property (nonatomic, strong) NSMutableArray *categoriesThatShowSubCategories;
@property (nonatomic, strong) UIViewController *hudViewController;
@property (nonatomic, strong) UIBarButtonItem *doneBarButton;
@property (nonatomic, strong) UIBarButtonItem *cancelBarButton;

@end

Expand Down Expand Up @@ -53,7 +53,7 @@ -(instancetype)initWithSelectedCategory:(PiwigoAlbumData*)category
[self.view addConstraints:[NSLayoutConstraint constraintFillSize:self.categoriesTableView]];

// Button for returning to albums/images
self.doneBarButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemDone target:self action:@selector(quitMoveCategory)];
self.cancelBarButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemCancel target:self action:@selector(quitMoveCategory)];

// Register palette changes
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(paletteChanged) name:kPiwigoNotificationPaletteChanged object:nil];
Expand Down Expand Up @@ -100,7 +100,7 @@ -(void)viewWillAppear:(BOOL)animated
[self paletteChanged];

// Add Done button
[self.navigationItem setRightBarButtonItems:@[self.doneBarButton] animated:YES];
[self.navigationItem setRightBarButtonItems:@[self.cancelBarButton] animated:YES];
}

-(void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id<UIViewControllerTransitionCoordinator>)coordinator{
Expand Down

0 comments on commit bdb69aa

Please sign in to comment.