Skip to content

Commit 7441557

Browse files
author
Joey Lorich
committed
Make search bar private, change reference on controll to its own property
1 parent 50353a9 commit 7441557

3 files changed

Lines changed: 3 additions & 4 deletions

File tree

EasyReader/Application/Controllers/Menu/EZRMenuSearchController.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,6 @@ extern NSString * const kEZRFeedSearchStateChangedNotification;
2727
@interface EZRMenuSearchController : NSObject <UISearchBarDelegate>
2828

2929

30-
/// The search bar this delegate is for
31-
@property (nonatomic, weak) IBOutlet EZRSearchBar *searchBar;
32-
3330
/**
3431
* Cancels a search, clears the search text, hides the keyboard
3532
*/

EasyReader/Application/Controllers/Menu/EZRMenuSearchController.m

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ @interface EZRMenuSearchController ()
2020
///// The feed search results data source
2121
@property (nonatomic, weak) IBOutlet EZRMenuSearchFeedDataSource *feedSearchDataSource;
2222

23+
/// The search bar this delegate is for
24+
@property (nonatomic, weak) IBOutlet EZRSearchBar *searchBar;
2325

2426
@end
2527

EasyReader/Application/Controllers/Menu/EZRMenuViewController.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ - (void)searchStateChanged:(NSNotification *)notification {
104104

105105
newLeftController.view.frame = CGRectMake(oldFrame.origin.x, oldFrame.origin.y, oldFrame.size.width, 361.0);
106106
self.menuContainerViewController.leftMenuViewController = newLeftController;
107-
[[(EZRMenuSearchController *)newLeftController searchBar] becomeFirstResponder];
107+
[self.searchBar becomeFirstResponder];
108108

109109
break;
110110
}

0 commit comments

Comments
 (0)