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

Android: Parity: Child view with fill behavior should recursively look at parents for width/height constraint when direct parent has size behavior

    Details

      Description

      When there is a parent with SIZE and a child with FILL, android will follow the size behavior for both the parent and child. We should follow the iOS behavior and let the child look for the parent's parent for width/height constraints.

      Run the following code:

      var win = Ti.UI.createWindow({backgroundColor:'white'});
       
      var parent = Ti.UI.createView({
      	height: Ti.UI.SIZE,
      	backgroundColor: 'green'
      });
       
      var child = Ti.UI.createView({
      	backgroundColor: 'blue'
      });
       
      parent.add(child);
      win.add(parent);
       
      win.open();
      

      Expected result:
      The blue view should cover the screen. (The child fills to the window, and the parent's size behavior will constrain to the child, which is the whole view)

      Actual result:
      The app shows a white view.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                ayeung Allen Yeung
                Reporter:
                ayeung Allen Yeung
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

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

                    Git Integration