Open prezessikora opened 6 years ago
How do I get carousel current card frame in superview coordinates.
I save current card:
func carouselCurrentItemIndexDidChange(_ carousel: iCarousel) { currentCard = carousel.currentItemView! as! CardArtistView }
and when clicked on card I want to know the exact position (frame) yet as I get proper width and height the origin is useless:
let currentCardFrame = currentCard.convert(currentCard.frame, to: self.view)
or
let currentCardFrame = currentCard.convert(currentCard.frame, to: carousel.contentView)
return x= 0 and y=-150 or y=-170 which is strange as the card of timemachine courses sits somewhere in the middle of screen.
Thanks!
How do I get carousel current card frame in superview coordinates.
I save current card:
and when clicked on card I want to know the exact position (frame) yet as I get proper width and height the origin is useless:
or
return x= 0 and y=-150 or y=-170 which is strange as the card of timemachine courses sits somewhere in the middle of screen.
Thanks!