uicollectionview

UICollectionView - Zoom Transition like iOS7 Calendar

本小妞迷上赌 提交于 2019-12-20 10:47:23
问题 I'm trying to replicate the zoom-to-detail transitions of the iOS7 calendar (and photos) apps in my app with UICollectionView. I have a UICollectionView grid with flowlayout, and I set a new layout with much larger cell size to get the zoom-in transition. My problem is the content of the cell. In the calendar app, when you tap on the month in the year-view, the content from the month cell expands as well to the month-view. How to I get that? I researched solutions since this zoom-to-detail

CollectionView background clearColor not working

ⅰ亾dé卋堺 提交于 2019-12-20 10:18:46
问题 I'm developing a small collectionview 'framework' to behave like a browser tab bar (think chrome) on the iPad. The code is all done, custom flow layout, reordering, and so on and is organized as so : • TabBarCollectionViewController .h/.m/.xib contains the high logic of the collection view (delegates + datasource methods). I have the xib to configure the collectionView settings and set the custom flow layout (I could do this programmatically, but oh well it's easier that way). •

CollectionView move to next cell automatically swift

夙愿已清 提交于 2019-12-20 10:13:32
问题 I am trying to create horizontal slider like Flipkart. I am using collectionView with Horizontal scrolling and paging. Cell contains imageView. I am succeed in scrolling items horizontally manually, but I want all these items to move automatic and manually both. I am not getting how to scroll items of collectionView automatically. Please guide me to do this. I have use this code in viewDidAppear: let visibleIndexPath: NSIndexPath = self.collectionView.indexPathForCell(cell)! self

UICollectionView horizontal scrolling, deleting last item, animation not working

血红的双手。 提交于 2019-12-20 09:39:59
问题 I have a UICollectionView. It scrolls horizontally, has only a single row of items, and behaves like a paging UIScrollView. I'm making something along the lines of the Safari tab picker, so you can still see the edge of each item. I only have one section. If I delete an item that is not the last item, everything works as expected and a new item slides in from the right. If I delete the last item, then the collection view's scroll position jumps to the N-1th item (doesn't smoothly animate),

How to center a UICollectionView when it is tapped?

拟墨画扇 提交于 2019-12-20 09:38:02
问题 I have a UICollectionView and it has quite a lot of UICollectionViewCells on it. I want to scroll the cell to the centre of the UICollectionView when it is tapped. My concern is that even if I tap the last or the top cell it should move to the centre of the collection view. I have tried setting the contentInsets and offsets but they don't seem to work. I think I will have to change the content size on selection and change it back to original when the scrolling begins. 回答1: Setting

UICollectionView Decoration and Supplementary views can not be moved

ぃ、小莉子 提交于 2019-12-20 09:31:48
问题 In UICollectionView decoration and supplementary views seem to be a big mystery. There seems to be next to no example code at the moment. I managed to get both types working in a custom layout (see this post for some details). As long as they remain in the same position everything is fine (i.e. if their layoutAttributes.frame does not change). However as soon as I re-layout with changed layoutAttributes for either decoration or supplementary views they get visually duplicated - i.e. there is

UICollectionReusableView method not being called

↘锁芯ラ 提交于 2019-12-20 09:08:35
问题 I want my sections in the UICollectionView to have a header with an image. I have followed these steps: at the storyboard, assigned a header as an accessory for my UICollectionView gave it an identifier created a subclass of UICollectionReusableView for it assigned the custom class to the class at the storyboard. put an ImageView at the header accessory made an outlet for the ImageView at the custom class in the .h file Implemented the following at viewDidLoad : [self.collectionView

UICollectionViewCell - contents do not animate alongside cell's contentView

血红的双手。 提交于 2019-12-20 09:03:06
问题 Problem looks like this: http://i.imgur.com/5iaAiGQ.mp4 (red is a color of cell.contentView) Here is the code: https://github.com/nezhyborets/UICollectionViewContentsAnimationProblem Current status: The content of UICollectionViewCell's contentView does not animate alongside contentView frame change. It gets the size immediately without animation. Other issues faced when doing the task: The contentView was not animating alongside cell's frame change either, until i did this in

Animate cell when pressed using Swift 3

白昼怎懂夜的黑 提交于 2019-12-20 08:39:23
问题 My problem is really simple. I would like to animate a cell within a collectionView. Indeed, I would like to show a grey background behind the cell and scale down the image inside. It would be (almost) the same effect than Pinterest: I used to code that animation on buttons, but I never did that on a cell. How can link a cell to a touchUpInside or TouchDown action for example ? 回答1: If you want to start animation when you touch on the cell, you can implement didHighlightItemAt . You probably

Getting the screen location of a cell from a UICollectionView

 ̄綄美尐妖づ 提交于 2019-12-20 08:27:20
问题 This isn't so much a question as an explanation of how to solve this problem. The first thing to realize is that the UICollectionView does inherit from a UIScrollView - so doing a standard lookup with a scroll view's content is the best solution. Here's the problem I was addressing: I had a UICollectionView that had differing items in each cell - along with differing types of cells. I need the selection of a cell to cause an effect of the image in the cell to appear to expand and take over