| Index: remoting/ios/app/host_collection_view_controller.mm
|
| diff --git a/remoting/ios/app/host_collection_view_controller.mm b/remoting/ios/app/host_collection_view_controller.mm
|
| index 72945970e7d85dd75db9bc7faf86a5aebd876b62..ed3a02ae523173739d21c52fd7584247e1b679b7 100644
|
| --- a/remoting/ios/app/host_collection_view_controller.mm
|
| +++ b/remoting/ios/app/host_collection_view_controller.mm
|
| @@ -23,8 +23,7 @@ static CGFloat kHostCollectionHeaderViewHeight = 25.f;
|
| @implementation HostCollectionViewController
|
|
|
| @synthesize delegate = _delegate;
|
| -@synthesize flexHeaderContainerViewController =
|
| - _flexHeaderContainerViewController;
|
| +@synthesize scrollViewDelegate = _scrollViewDelegate;
|
|
|
| - (instancetype)initWithCollectionViewLayout:(UICollectionViewLayout*)layout {
|
| self = [super initWithCollectionViewLayout:layout];
|
| @@ -115,8 +114,7 @@ static CGFloat kHostCollectionHeaderViewHeight = 25.f;
|
| #pragma mark - UIScrollViewDelegate
|
|
|
| - (void)scrollViewDidScroll:(UIScrollView*)scrollView {
|
| - [self.flexHeaderContainerViewController.headerViewController
|
| - scrollViewDidScroll:scrollView];
|
| + [_scrollViewDelegate scrollViewDidScroll:scrollView];
|
| }
|
|
|
| #pragma mark - UICollectionViewDelegateFlowLayout
|
| @@ -129,24 +127,4 @@ static CGFloat kHostCollectionHeaderViewHeight = 25.f;
|
| kHostCollectionHeaderViewHeight);
|
| }
|
|
|
| -#pragma mark - Private
|
| -
|
| -- (void)setFlexHeaderContainerViewController:
|
| - (MDCFlexibleHeaderContainerViewController*)
|
| - flexHeaderContainerViewController {
|
| - _flexHeaderContainerViewController = flexHeaderContainerViewController;
|
| - MDCFlexibleHeaderView* headerView =
|
| - _flexHeaderContainerViewController.headerViewController.headerView;
|
| - headerView.trackingScrollView = self.collectionView;
|
| - headerView.backgroundColor = [UIColor clearColor];
|
| -
|
| - // Use a custom shadow under the flexible header.
|
| - MDCShadowLayer* shadowLayer = [MDCShadowLayer layer];
|
| - [headerView setShadowLayer:shadowLayer
|
| - intensityDidChangeBlock:^(CALayer* layer, CGFloat intensity) {
|
| - CGFloat elevation = MDCShadowElevationAppBar * intensity;
|
| - [(MDCShadowLayer*)layer setElevation:elevation];
|
| - }];
|
| -}
|
| -
|
| @end
|
|
|