4

Is there any equivalent function in XWalkView for setLoadWithOverviewMode?

I am working on a Android application that load a website in a XWalkView. The view zooms in the top left corner of the website when it loaded. I couldn't find anyway to set the initial zoom level of the XWalkView. As for the android webview, i used setLoadWithOverviewMode for the job, but the xwalk 11 library does not support getSetting() method anymore.

Help would be very much appreciated.

Sorry for my bad english.

  • I'm having the exact same problem. I'm currently forced to use tags inside the loaded html to force the correct zoom level: – Tobias Strebitzer Mar 11 '15 at 08:50
  • 1
    I ended up making my site responsive so that it scales to fit the device's screen to fix the problem. But i think a Overview Mode for XWalkView would be very useful still :) – Việt KHoa NGuyễn Mar 12 '15 at 09:52

1 Answers1

0

In latest versions (I'm on 20.50.529) you can use this to get an initial zoom of 100%

XWalkView webView=new XWalkView(this);
webView.getSettings().setInitialPageScale(100);
deviato
  • 2,027
  • 1
  • 15
  • 9