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

Windows: Setting undefined should clear layout value

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Medium
    • Resolution: Fixed
    • Affects Version/s: Release 7.5.0
    • Fix Version/s: Release 8.0.0
    • Component/s: Windows
    • Labels:
    • Story Points:
      5
    • Sprint:
      2018 Sprint 22, 2018 Sprint 24

      Description

      Setting undefined to layout property should "clear" layout value. For instance, Setting both left and top disables center property (TIMOB-26507) but we should be able to enable center property again by setting undefined for left and top properties.

      var win = Ti.UI.createWindow();
       
      var view1 = Ti.UI.createView({
          width: 100, height: 100,
          top: 100, left: 100,
          backgroundColor: 'blue',
      });
       
      win.addEventListener('click', function (e) {
          view1.top  = undefined;
          view1.left = undefined;
          view1.center = { x: e.x, y:e.y };
      });
       
      win.add(view1);
      win.open();
      

      Expected: The blue view should move to where you click.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                kiguchi Kota Iguchi
                Reporter:
                kiguchi Kota Iguchi
                Reviewer:
                Gary Mathews
                Tester:
                Samir Mohammed
              • Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

                  • Backbone Issue Sync is enabled for your project, but we do not have any synchronization info for this issue.

                    Git Source Code