views:

676

answers:

2

Hi, I'm using UIWebView for show a simple HTML page. When I scroll the page (over the top or over the bottom) a shadow gray appears behind!! Can I remove or avoid this bad effect?

Thx

P.S. UIWebView, View container, are all background clear and opaque NO!!

A: 

It is not possible! Over the web there are some solution that using private apple methods (undocumented api & functions). So, apple could refuse your app.

Undolog
Did you try my code? I don't see why Apple would deny it or have a way to detect it since it's not calling any private apis.
Adolfo
Your solution is good! I try it early. I referer to other solutions founded on Web.. :)
Undolog
+4  A: 

It may be possible...

The shadows appear to be of class UIImageView. You can loop through the views of the first subview of UIWebView and just hide any views that match UIImageView.

id scroller = [webView.subviews objectAtIndex:0];

for (UIView *subView in [scroller subviews])
    if ([[[subView class] description] isEqualToString:@"UIImageView"])
        subView.hidden = YES;

Disclaimer: the view hierarchy could change in the future and this would not work causing the shadows to come back.

Adolfo
i put your code on the viewDidLoad , and doesn't work .
Momeks