Created
July 25, 2012 05:39
-
-
Save satococoa/3174607 to your computer and use it in GitHub Desktop.
UIWebView#scrollView
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
| class UIWebView | |
| alias_method :original_init, :init | |
| def initWithScrollView | |
| original_init | |
| unless self.respond_to?(:scrollView) | |
| def scrollView | |
| self.subviews.each do |view| | |
| return view if view.kind_of?(UIScrollView) | |
| end | |
| end | |
| end | |
| self | |
| end | |
| alias_method :init, :initWithScrollView | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment