Resize windy to fit Android WebView height

  • Hello

    (I am an Android programmer, not html/javascript programmer, so my apologies if the answer is really straightforward.)

    Currently I am using the Windy Hello World example to set the height of Windy in Android WebView.

    #windy {
    width: 100%;
    height: 400px;

    I arbitrarily chose 400px above for the height to get started.

    But Android devices (and desktops and laptops) have different device heights, and also the area allocated for displaying the Windy map in the Webview may vary in height on the screen. Is there a way to dynamically set the height parm either at initialization or at some later point so that Windy properly fills the allocated screen area?

    I have tried a number of 'solutions', mainly from StackOverflow related to leaflet but with no luck.

    Any ideas?



  • i think if you put
    it will fit itself into all allocated area

  • Developers

    this is correct. however, it needs to be full screen. if you have some other android views in the ui and the windy webview gets resized in height, the animation stops and the layers become gray.

    the height: 100% will work well if it is ensured that only a webview is in the user screen.

  • Administrator

    @droidgox Hello, using in a WebView is restricted. Please let us know the purpose of your project.

  • Developers

    @Korina hi . yes i am aware it is restricted. i am only sharing my experience when i tried to test it in a webview.

Windyty, S.E. - all rights reserved. Powered by excellent NodeBB
NodeBB & contributors, OSM & contributors, HERE maps
Terms and Conditions     Privacy Policy