Skip to content

解决UIScrollView嵌套滑动手势冲突问题,适用于复杂的首页或个人主页

License

Notifications You must be signed in to change notification settings

Unchanged-Is-Changed/HGPersonalCenterExtend

 
 

Repository files navigation

HGPersonalCenterExtend

License MIT Platform Pod version

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Requirements

  • iOS 8.0+
  • Objective-C
  • Xcode 9+

Installation

HGPersonalCenterExtend is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'HGPersonalCenterExtend', '~> 1.2.5'

Main

1.使用Masonry方式布局;
2.解决外层和内层滚动视图的上下滑动冲突问题;
3.解决segmentedPageViewControllerscrollView横向滚动和外层scrollView纵向滑动不能互斥的问题等;
4.支持全屏返回;

Plan

1.支持刷新;
2.HGCategoryView支持更多样式 ;

Show

image

Usage

Example: HGPersonalCenterExtend/Example

1.嵌套逻辑交互封装在HGNestedScrollViewController中,大家可根据自己实际业务的需求自定义;
为什么这个控制器不直接放进HGPersonalCenterExtend库中呢?
这是为了方便大家DIY,你们可以将其copy到自己的项目中,稍加改动即可使用;

2.在Example中,HGPersonalCenterViewController继承自HGNestedScrollViewController快速实现了复杂的ScrollView嵌套页面,在这里你只需要设置pageViewControllers,不会污染你正常的业务代码;

3.如果你的pageViewController下的scrollViewUICollectionView类型,需要额外进行如下设置:

// 解决categoryView在吸顶状态下,且collectionView的显示内容不满屏时,出现竖直方向滑动失效的问题
_collectionView.alwaysBounceVertical = YES;

Recommend

如果想实现头部背景视图放大的效果,可关注我另一个库:HGPersonalCenter

Blog

简书

Author

Arch, [email protected]

License

HGPersonalCenterExtend is available under the MIT license. See the LICENSE file for more info.

About

解决UIScrollView嵌套滑动手势冲突问题,适用于复杂的首页或个人主页

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Objective-C 97.7%
  • Ruby 2.3%