From 9ccbe1667f40297ea11069cf394c8e6bc33d343a Mon Sep 17 00:00:00 2001 From: YuigaWada Date: Sun, 1 Sep 2019 03:57:42 +0900 Subject: [PATCH] Fixed translucent searchBar Bug. --- PolioPager.podspec | 2 +- PolioPager/PageViewController.swift | 4 +++ PolioPager/PolioPagerViewController.swift | 2 ++ PolioPager/PolioPagerViewController.xib | 30 +++++++++++------------ 4 files changed, 22 insertions(+), 16 deletions(-) diff --git a/PolioPager.podspec b/PolioPager.podspec index 9cb8d8c..7ce4687 100644 --- a/PolioPager.podspec +++ b/PolioPager.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = "PolioPager" -s.version = "2.0" +s.version = "2.0.1" s.summary = "PolioPager enables us to use PagerTabStrip like SNKRS." s.license = { :type => 'MIT', :file => 'LICENSE' } s.homepage = "https://github.com/yuigawada/PolioPager" diff --git a/PolioPager/PageViewController.swift b/PolioPager/PageViewController.swift index 0af70c8..56be85a 100644 --- a/PolioPager/PageViewController.swift +++ b/PolioPager/PageViewController.swift @@ -100,6 +100,10 @@ public class PageViewController: UIPageViewController, UIScrollViewDelegate { collectionViewはUserInteractionを認識しません。 したがって、searchBarとcollectionViewのisUserInteractionEnabledを入れ替える必要があります。 (正直な話、UIViewPropertyAnimatorの適切な使い方がわからないだけです) + + + (追記) + SearchBarとcollectionViewの重なり順を逆転させました。 */ diff --git a/PolioPager/PolioPagerViewController.swift b/PolioPager/PolioPagerViewController.swift index 49635fd..e109ae2 100644 --- a/PolioPager/PolioPagerViewController.swift +++ b/PolioPager/PolioPagerViewController.swift @@ -328,6 +328,8 @@ open class PolioPagerViewController: UIViewController, TabCellDelegate, PolioPag }.forEach{$0.alpha = alpha} + self.collectionView.backgroundColor = alpha == 1 ? .white : .clear + self.selectedBar.alpha = alpha } diff --git a/PolioPager/PolioPagerViewController.xib b/PolioPager/PolioPagerViewController.xib index d845845..bc2d721 100644 --- a/PolioPager/PolioPagerViewController.xib +++ b/PolioPager/PolioPagerViewController.xib @@ -29,21 +29,6 @@ - - - - - - - - - - - - - - - @@ -74,6 +59,21 @@ + + + + + + + + + + + + + + +