开发者

Webview behaviour with Galaxy S loading webpage takes ages

Can anyone help or has had the same problem with webviews and Galaxy S:

Opening a simple webpage (html, css, images) in a webview takes very, very long (40-50 seconds). Opening the same webpage within the browser take a tenth of a second.

The same app wi开发者_JAVA百科th the same webview and webpage on the same wlan works perfectly on any other given device - even on the Galaxy Tab it works great.

Just on the Galaxy S the webview takes ages to load the webpage. We have no idea what's going on here and we would appreciate any help.

Thanks a lot ...


I have a Galaxy S and the only real "bug" with it I know of is the RFS filesystem that slows anything doing storage I/O down to a crawl.

How are you loading the HTML? Do you just pass an http:// URL to the webview? If so, what URL? For a 100 bounty I'll be happy to help debug if you give this information... :)

In the meantime, try seeing if webView.getSettings().setCacheMode(LOAD_NO_CACHE); makes a difference. That will force it to not use the storage-based cache, which on a Galaxy S could indeed be mightily slow.


I have the same issue here with a Galaxy S. In LogCat I can't see anything suspicious. I've tried pages without JavaScript, and:

webview.getSettings().setRenderPriority( RenderPriority.HIGH );

and:

webview.getSettings().setJavaScriptEnabled(false);

and different URLs - it's always slow. The more and the larger the images on a web page, the worse it gets. Everything takes around 10 times as long as in the browser on the same device, same network, same everything.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜