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

iOS: Picker does not accept percent as height/width

    Details

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

      Mac OSX El Capitan 10.11.3
      Studio: 4.5.0.201602170821
      Ti SDK: 5.2.0.GA
      Appc NPM: 4.2.3
      Appc CLI: 5.2.0.GA
      Xcode 7.2
      Node v4.2.4

    • Sprint:
      2016 Sprint 06 SDK

      Description

      Picker does not accept percent as height/width it needs pixels.

      http://docs.appcelerator.com/platform/latest/#!/api/Titanium.UI.Picker-property-height

      Steps to reproduce:
      Add a picker to a view and set the height/width as a percentage or use the app.js below

      Actual :
      The picker does not use the percentage as the height/width.

      Expected:
      The Picker should either accept height/width as a percentage or scaling the picker should use pixels

      App.js

      Ti.UI.backgroundColor = 'white';
      var win = Ti.UI.createWindow({
        exitOnClose: true,
        layout: 'vertical'
      });
       
      var picker = Ti.UI.createPicker({
        type:Ti.UI.PICKER_TYPE_DATE,
        minDate:new Date(2009,0,1),
        maxDate:new Date(2014,11,31),
        value:new Date(2014,3,12),
        top:50,
        height:"100%",
        width:"100%"
      });
       
      win.add(picker);
      win.open();
       
      picker.addEventListener('change',function(e){
        Ti.API.info("User selected date: " + e.value.toLocaleString());
      });
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                apetkov Angel Petkov
                Reporter:
                jlongton Josh Longton
                Reviewer:
                Pedro Enrique (Inactive)
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

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

                    Git Integration