Created
July 21, 2014 20:47
-
-
Save pocketkk/909abd3ae4ba4b5f8352 to your computer and use it in GitHub Desktop.
Swift - Move UIScrollView to Position
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func buttonTapped(sender: UIButton!) { | |
let scroll : UIScrollView? = findScroller(self.view) | |
let scrollPoint = CGPointMake(0.0, 0.0) | |
println("Button Tapped") | |
if scroll { | |
scroll!.setContentOffset(scrollPoint, animated: true) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment