[ios] Fixed crash on PP more button at iPad.

This commit is contained in:
Ilya Grechuhin 2016-06-14 15:19:07 +03:00 committed by Vladimir Byko-Ianko
parent a8d7c8e12c
commit bdd0c80db6

View file

@ -158,7 +158,7 @@ NSString * const kPlacePageActionBarNibName = @"PlacePageActionBar";
auto const size = self.buttons.count;
for (UIView * v in self.buttons)
{
if (v.tag == size + 1)
if (v.tag == size)
last = v;
}
return last;
@ -254,6 +254,7 @@ NSString * const kPlacePageActionBarNibName = @"PlacePageActionBar";
{
UIPopoverPresentationController * popPresenter = [alertController popoverPresentationController];
popPresenter.sourceView = self.shareAnchor;
popPresenter.sourceRect = self.shareAnchor.bounds;
}
[vc presentViewController:alertController animated:YES completion:nil];
}