Skip to content

Instantly share code, notes, and snippets.

@doskoi
Created November 6, 2012 05:38
Show Gist options
  • Select an option

  • Save doskoi/4022798 to your computer and use it in GitHub Desktop.

Select an option

Save doskoi/4022798 to your computer and use it in GitHub Desktop.
UIWebview remove shadow
-(UIScrollView *)defaultScrollView
{
if (_defaultScrollView == nil) {
UIScrollView *scrollView = nil;
for (UIView *subview in [self subviews]) {
if ([subview isKindOfClass:[UIScrollView class]]) {
scrollView = (UIScrollView *)subview;
}
}
if (scrollView == nil) {
NSLog(@"Couldn’t get webview default scrollview!");
}
_defaultScrollView = scrollView;
_defaultScrollView.decelerationRate = UIScrollViewDecelerationRateNormal;
}
return _defaultScrollView;
}
-(void)removeShadows
{
for (UIView *subview in self.defaultScrollView.subviews) {
if ([subview isKindOfClass:[UIImageView class]]) {
[subview setHidden:YES];
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment