Removing the WebView shadow in Titanium
The Q&A-post was written for 1.8.2, but it should work with newer versions of the SDK as well. In short, open the SDK-folder, go to iphone/Classes and open TiUIWebView.m in your favorite editor. Then add the following after #pragma mark Public APIs
:
-(void)setHideShadow_:(id)arg
{
for(UIView *wview in [[[webview subviews] objectAtIndex:0] subviews])
{
if([wview isKindOfClass:[UIImageView class]])
{
wview.hidden = [TiUtils boolValue:arg];
}
}
}
Clean and rebuild your project, and you’ll be able to use the hideShadow-property.
var webview = Ti.UI.createWebView({
hideShadow: true
});