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

Windows: backgroundGradient.colors should accept an array of just colour values

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Medium
    • Resolution: Fixed
    • Affects Version/s: Release 6.1.2, Release 7.0.0, Release 6.2.0
    • Fix Version/s: Release 7.5.0
    • Component/s: Windows
    • Labels:
      None
    • Environment:

      Ti SDK: 6.1.2.GA, 6.2.0.v20170906064110, 7.0.0.v20170906135653

    • Story Points:
      8
    • Sprint:
      2016 Sprint 17 SDK, 2018 Sprint 18 SDK, 2018 Sprint 19 SDK

      Description

      Description

      backgroundGradient.colors property should accept an array containing just strings representing color values, as opposed to an array of objects with color values and offset value

      var _window = Ti.UI.createWindow();
      var buttonAddFav = Titanium.UI.createButton({
          title: 'add2favs',
          backgroundGradient:  {
              type: 'linear',
              startPoint: {x: 0.0, y: 0.0},
              endPoint: {x: 0.0, y: "100%"},
              // colors: ['#aaa', '#f00']
              colors: [{ color: '#aaa', offset: 0.0 }, { color: '#f00', offset: 1.0 }]
          }
      });
      _window.add(buttonAddFav);
      _window.open()
      

      Steps to reproduce
      1. Add the above to an existing app.js and build for Windows
      2. Comment out the array of objects and uncomment the array of color strings
      Actual

      backgroundGradient disappears after step 2

      Expected

      backgroundGradient should stay

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                kiguchi Kota Iguchi
                Reporter:
                eharris Ewan Harris
                Reviewer:
                Gary Mathews
                Tester:
                Samir Mohammed
              • Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

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

                    Git Source Code