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

Android: Add "datePickerStyle" support to Ti.UI.Picker


    • Story Points:


      The Ti.UI.Picker view's datePickerStyle is currently iOS only. We should add support on Android. In particular, we should add the "compact" style which shows the picker as a read-only text field, and when tapped on, show a date/time selection dialog which matches Google's design guidelines.

      The "datePickerStyle" property needs to be supported by the following types on Android:

      Style Constants:
      Copy the following constants from Ti.UI.iOS to Ti.UI. Using the old constants should cause a deprecation warning on iOS.

      If the Android only boolean properties useSpinner or nativeSpinner are defined, then they must take priority over the datePickerStyle property to maintain backward compatibility. When these boolean properties are set true, then they must do the equivalent of DATE_PICKER_STYLE_WHEELS.

      Compact/Automatic Date Style:
      Android should show a read-only text field with a drop-down arrow. When tapped on, a selection dialog should appear.

      The iOS equivalent is this...

      Compact/Automatic Time Style:
      On Android it will appear as follows...

      The iOS equivalent is this...

      Inline Date Style:
      The picker appears as a calendar view.

      Inline Time Style:
      The picker appears as a clock view on Android and a field with spinners on iOS.

      Wheels Date Style:
      Spinner picker wheels appear for selecting month, day, and year.

      Wheels Time Style:
      Spinner picker wheels appear for selecting hours, minutes, and AM/PM.


        1. DatePickerStyleTest.js
          1 kB
          Joshua Quick
        2. PickerDate-Compact-Android.png
          406 kB
          Joshua Quick
        3. PickerDate-CompactDialog-Android.png
          457 kB
          Joshua Quick
        4. PickerDate-CompactDialog-iOS.png
          962 kB
          Joshua Quick
        5. PickerDate-Compact-iOS.png
          775 kB
          Joshua Quick
        6. PickerDate-Inline-Android.png
          439 kB
          Joshua Quick
        7. PickerDate-Inline-iOS.png
          830 kB
          Joshua Quick
        8. PickerDate-Wheels-Android.png
          414 kB
          Joshua Quick
        9. PickerDate-Wheels-iOS.png
          820 kB
          Joshua Quick
        10. PickerTime-Compact-Android.png
          405 kB
          Joshua Quick
        11. PickerTime-CompactDialog-Android.png
          458 kB
          Joshua Quick
        12. PickerTime-CompactDialog-iOS.png
          891 kB
          Joshua Quick
        13. PickerTime-Compact-iOS.png
          773 kB
          Joshua Quick
        14. PickerTime-Inline-Android.png
          437 kB
          Joshua Quick
        15. PickerTime-Inline-iOS.png
          778 kB
          Joshua Quick
        16. PickerTime-Wheels-Android.png
          409 kB
          Joshua Quick
        17. PickerTime-Wheels-iOS.png
          794 kB
          Joshua Quick
        18. TimePickerStyleTest.js
          1 kB
          Joshua Quick

          Issue Links



              • Assignee:
                jquick Joshua Quick
                jquick Joshua Quick
                Gary Mathews
              • Watchers:
                2 Start watching this issue


                • Created:

                  Backbone Issue Sync

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

                    Git Integration