From d42450aaa28376aa477d501da5148239e1fdecd9 Mon Sep 17 00:00:00 2001 From: Ilya Grechuhin Date: Wed, 10 Jan 2018 16:37:54 +0300 Subject: [PATCH] [iphonex] [ios] Fixed place page gallery layout. --- .../Content/Gallery/GalleryViewController.swift | 3 +++ .../Content/Gallery/GalleryViewController.xib | 8 +++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/Gallery/GalleryViewController.swift b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/Gallery/GalleryViewController.swift index 69e444f064..1a678f2ff3 100644 --- a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/Gallery/GalleryViewController.swift +++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/Gallery/GalleryViewController.swift @@ -41,6 +41,9 @@ final class GalleryViewController: MWMCollectionViewController { layout.minimumLineSpacing = spacing layout.minimumInteritemSpacing = spacing layout.itemSize = CGSize(width: itemWidth, height: itemHeight) + if #available(iOS 11.0, *) { + layout.sectionInsetReference = .fromSafeArea + } } override func viewWillTransition(to size: CGSize, with coordinator: UIViewControllerTransitionCoordinator) { diff --git a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/Gallery/GalleryViewController.xib b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/Gallery/GalleryViewController.xib index 183b1059c5..6baa8ae348 100644 --- a/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/Gallery/GalleryViewController.xib +++ b/iphone/Maps/UI/PlacePage/PlacePageLayout/Content/Gallery/GalleryViewController.xib @@ -1,15 +1,16 @@ - + - + + - + @@ -18,6 +19,7 @@ +