Relative Content

Tag Archive for iosswiftuikit

Sync scrolling of several UIScrollview in separate ViewControllers

I’m tryinig to have the same offset between several viewcontrollers (all of the are the same class). I have a OffsetSyncManager to handle this, but the only sync that is already working is when moving vc3 and vc1 gets updated, but should work in either direction for all of them.

Weird jumps in UICollectionViewController with Interactive Keyboard Dismiss

I’m still quite new to UIKit and I’m working on a chat application, similar to Messages, for learning purpose. I’ve faced an issue when the content of UICollectionView jumps around the top while trying to dismiss the keyboard with the swipe. It happens only when the content is scrolled down from the very top of UICollectionView so that there’s a gap between the content and the top of the view.

Protocol delegate from custom UI button has unwanted effect

I have been trying to create a protocol and delegate between custom UI button and parent-child view controller. Briefly, I have a parent view controller, a child view controller, and a custom UI button. Custom UI button and child VC are under parent VC. I created a protocol delegate for custom UI button and conformed it by parent VC. I want to change child VC’s view frame origin with a tap on custom UI button. I also want to change the image of custom UI button when I tapped. However, when I try to change the image of custom UI button and also call delegate function, child VC view has some unwanted effect. Here is the sample code: