1

I have a webview inside a tabacitivity and have enabled the zoomcontrols. However, whenever I got back to the non-webview tab, the +/- zoomcontrols is still displaying.

Is there anyway to get rid of them or not make this happen? I have read a lot of articles related to this problem, but could not find any solutions. Thanks in advance.

mooongcle
  • 3,987
  • 5
  • 33
  • 42

1 Answers1

0

I think the easiest solution would be to disable zoom controls when the other tab is selected, and enable them when the WebView tab is selected.

Check if the WebView activity go through onResume() and onPause() when selected/unselected its tab, and if so, enable/disable the zoom controls here. Otherwise, they maybe some events on the TabHost which may allow the do the same thing.

Anasthase
  • 491
  • 2
  • 7
  • I have checked, yes onResume and onPause event happened, but even I set the visibility of zoomcontrols as View.GONE, it is still displaying... It is not working... Thanks.. do you have any others?? – mooongcle Dec 08 '11 at 13:42
  • I should have been more specific, what i was suggesting was completely disabling/enabling zoom controls, with WebSettings.setBuiltInZoomControls(true/false), not just hiding them. – Anasthase Dec 08 '11 at 14:45
  • I have also tried that, but it was the same... Hmm... Is there any solution for it??? Nobody knows... Shame.. – mooongcle Dec 09 '11 at 14:12