Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-20587

IOS9: Ti.UI.SIZE is not working well for WebView inside a ScrollView

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Medium
    • Resolution: Won't Fix
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: iOS
    • Environment:

      iOS 9.2
      TI SDK 5.2.0
      iPhone 6puls

    • Story Points:
      1

      Description

      Reproduce Step

      1. Simply run the example following

      Titanium.UI.setBackgroundColor('#000');
       
      var window = Titanium.UI.createWindow({
      	backgroundColor : "white"
      });
       
      //Create WebView
      var webview = Titanium.UI.createWebView({
      	height: Ti.UI.SIZE,
      	borderColor: "orange"
      });
      webview.setHtml("<html><head></head><body style=\'background-color:#FFFFFF\'><div style=\'margin: 0 3% 0 3%; padding: 2%; background-color: #FFFFFF\'><h3>What you get</h3><p>Two tickets to the National Home Show and Canada Blooms Garden Festival on March 11-20, 2016 at the Enercare Centre at Exhibition Place.<br><br></p><br/>Today\'s WagJag: $20 for two tickets to the <a href=\"http://www.nationalhomeshow.com\" target=\"_blank\">National Home Show</a> and Canada Blooms Garden Festival on March 11-20, 2016 at the Enercare Centre (a $40 value).<br><br>The National Home Show presented by RE/MAX &amp; co-located Canada Blooms bring you the largest North American display of innovative products, new ideas, &amp; great deals for all things home &amp; garden with over 700 retailers &amp; industry experts. Tour the FutureDreamHome built by Probuilt and presented by Toronto Star, and explore the Best Buy Smart Home for a taste of what tomorrow has in store for us. Plus, be inspired by our line-up of celebrity guests and experts on the Unilock Celebrity Stage including, Debbie Travis, Paul Lafrance, Carson Arthur, Damon Bennett, Annie Sloan and more! One ticket, two events. Admission to Canada Blooms in included when you attend the National Home Show. Whether you need inspiration for your next project, are looking some practical advice or need some face to face time with experts from a variety of trades, make sure don\'t miss the largest home and garden event in North America!<br/></div></body></html>");
       
      webview.addEventListener('load', function (e){
      	console.info('e.source.height: ' + e.source.evalJS("document.height;"));
      });
       
      //Create scrollView
      var scrollView = Ti.UI.createScrollView({
      	top : 50,
      });
      scrollView.add(webview);
      window.add(scrollView);
       
      window.open();
      

      Expect Result

      The webView should display well inside scrollView.

      Actual Result

      There will be a large while blank space on the bottom of the page

      N.B.

      1. If you comment out the "height: Ti.UI.SIZE" from webview properties, everthing will work well.
      2. If you ONLY display the webview in screen, NO any scrollView, it will work well too.

      Also customer mentioned that it was not happening on iOS 8.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                sliang Shuo Liang
              • Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

                  • Titanium SDK/CLI <> Titanium Mobile
                    Synced with:
                    TIMOB-7063
                    Sync status:
                    ERROR
                    Last received:
                    Last sent:

                    Git Source Code