forked from organicmaps/organicmaps
[iOS] fix PP action bar when searching on map
https://jira.mail.ru/browse/MAPSME-11711
This commit is contained in:
parent
8b6cab1958
commit
12460ddd09
3 changed files with 9 additions and 5 deletions
|
@ -113,7 +113,7 @@ void RegisterEventIfPossible(eye::MapObject::Event::Type const type, place_page:
|
|||
|
||||
if (!self.layout)
|
||||
{
|
||||
self.layout = [[MWMPlacePageLayout alloc] initWithOwnerView:self.ownerViewController.controlsView
|
||||
self.layout = [[MWMPlacePageLayout alloc] initWithOwnerView:self.ownerViewController.view
|
||||
delegate:self
|
||||
dataSource:self];
|
||||
}
|
||||
|
|
|
@ -144,9 +144,7 @@ typedef NS_ENUM(NSUInteger, MWMScrollDirection) {
|
|||
- (CGFloat)openContentOffset {
|
||||
CGSize size = self.ownerView.size;
|
||||
CGFloat offset = self.isPortrait ? MAX(size.width, size.height) : MIN(size.width, size.height);
|
||||
CGFloat actionBarHeight = self.actionBar.height;
|
||||
offset -= actionBarHeight;
|
||||
return offset * kTopPlacePageStopValue + actionBarHeight;
|
||||
return offset * kTopPlacePageStopValue;
|
||||
}
|
||||
|
||||
- (CGFloat)topContentOffset {
|
||||
|
|
|
@ -387,7 +387,13 @@ std::array<Class, 9> const kPreviewCells = {{[_MWMPPPTitle class],
|
|||
? [MWMAdBanner detailedBannerExcessHeight]
|
||||
: 0;
|
||||
|
||||
return height + gapBannerHeight - excessHeight;
|
||||
CGFloat safeArea = 0.0;
|
||||
if (@available(iOS 11.0, *)) {
|
||||
UIWindow *window = UIApplication.sharedApplication.keyWindow;
|
||||
safeArea = window.safeAreaInsets.bottom;
|
||||
}
|
||||
|
||||
return height + gapBannerHeight - excessHeight + safeArea;
|
||||
}
|
||||
|
||||
- (void)layoutInOpenState:(BOOL)isOpen
|
||||
|
|
Loading…
Add table
Reference in a new issue