Merge pull request #4914 from igrechuhin/MAPSME-3174

[MAPSME-3174] [ios] Fixed search manager states handling.
This commit is contained in:
Vlad Mihaylenko 2016-12-08 15:35:48 +03:00 committed by GitHub
commit a9a1cd929b

View file

@ -279,7 +279,6 @@ typedef NS_ENUM(NSUInteger, MWMSearchManagerActionBarState) {
- (void)changeToDefaultState
{
[self updateTopController];
[self.navigationController popToRootViewControllerAnimated:NO];
self.actionBarState = MWMSearchManagerActionBarStateTabBar;
@ -294,7 +293,6 @@ typedef NS_ENUM(NSUInteger, MWMSearchManagerActionBarState) {
- (void)changeToTableSearchState
{
[self updateTopController];
[self.navigationController popToRootViewControllerAnimated:NO];
self.actionBarState = MWMSearchManagerActionBarStateHidden;
@ -311,7 +309,6 @@ typedef NS_ENUM(NSUInteger, MWMSearchManagerActionBarState) {
- (void)changeToMapSearchState
{
[self updateTopController];
[self.navigationController popToRootViewControllerAnimated:NO];
self.actionBarState = MWMSearchManagerActionBarStateModeFilter;
@ -452,6 +449,7 @@ typedef NS_ENUM(NSUInteger, MWMSearchManagerActionBarState) {
kSearchStateKey : @(state)
}];
_state = state;
[self updateTopController];
switch (state)
{
case MWMSearchManagerStateHidden: