Answer the question
In order to leave comments, you need to log in
How to use UICollectionView with other elements?
Good afternoon, I apologize in advance for the noob question, but I honestly searched for the answer myself, it does not work.
It is necessary to make an application for the site ttlip.ru
Now there is a problem with the fact that the banner inserted in front of the UICollectionView appears to be transparent.
But I need it to just show at the top, hide when scrolling.
How to do it?
There is an option - to do it using the header, but I'm not sure that this method is correct, because there may be complex elements.
Answer the question
In order to leave comments, you need to log in
You need to use your banner as a SupplementaryElement
The dataSource method is responsible for this
- (UICollectionReusableView *)collectionView:(UICollectionView *)collectionView viewForSupplementaryElementOfKind:(NSString *)kind atIndexPath:(NSIndexPath *)indexPath
This will be the most correct solution
If you need some kind of complex animation - then work with uiscrollview will already be needed, but this is not even discussed
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question