Kitchen Sink Date Picker Slow

134 views
Skip to first unread message

phil...@gmail.com

unread,
Nov 22, 2013, 3:26:57 AM11/22/13
to codenameone...@googlegroups.com
I sent the KitchenSink demo to my Android (Galaxy S4) as-is, but I notice that the Date picker does not provide a smooth scrolling experience.
Any insight into this?

Thanks!

Shai Almog

unread,
Nov 22, 2013, 2:32:56 PM11/22/13
to codenameone...@googlegroups.com, phil...@gmail.com
It has some issues for some cases that we aren't really clear about.
I would use the Picker component for newer code, it uses the native picking functionality on Android/iOS.

dgoyet...@gmail.com

unread,
Nov 27, 2013, 3:45:29 PM11/27/13
to codenameone...@googlegroups.com, phil...@gmail.com
Shai,

What control are you referring to, the DateSpinner?   Is there a component that uses the native IOS or Android date picker controls, if so, what is the component called?

Dave

Shai Almog

unread,
Nov 28, 2013, 12:10:50 AM11/28/13
to codenameone...@googlegroups.com, phil...@gmail.com, dgoyet...@gmail.com
If you would have followed the mailing list/blog you would have known: http://www.codenameone.com/3/post/2013/11/spinning-natively-and-windows-bug.html

David Goyette

unread,
Nov 28, 2013, 9:11:32 AM11/28/13
to Shai Almog, codenameone...@googlegroups.com, phil...@gmail.com
Shai, I've seen this article in the past, but when I look at the kitchen sink, all I see is a DateSpinner being instantiated in the components section?   Is this the "picker" that you are referring to?  I didn't think so, because the article mentions something that looks like a text field that you need to click on.  The article doesn't mention the name of the picker class.

My understanding from this article is that I instantiate a date "picker" class, and if a native picker is available, it uses that, otherwise, it uses your implementation of the DateSpinner?

Sorry if I'm being dense.  I looked through the docs and didn't see any reference to picker classes, but again, I may be looking in the wrong place.

Dave  

Philip Iyobose Eki

unread,
Nov 28, 2013, 12:29:31 PM11/28/13
to David Goyette, Shai Almog, codenameone...@googlegroups.com

It was a spinner I saw.

Shai Almog

unread,
Nov 28, 2013, 2:51:06 PM11/28/13
to codenameone...@googlegroups.com, David Goyette, Shai Almog, phil...@gmail.com
The Picker class will create a text field like entry, when its clicked a native dialog/popup will come up containing the native spinner or one of our dialogs/spinners depending on platform availability.
Its the Picker class within the Spinner package.

David Goyette

unread,
Nov 28, 2013, 2:57:25 PM11/28/13
to Shai Almog, codenameone...@googlegroups.com, Philip Iyobose Eki
Sorry Shai, but I don't see the Picker class in the javadoc, or in the KitchenSink that I have.  Is it in the current released software?  Is there an example of its use (again, I don't see it in the source of the latest kitchen sink that I've downloaded).

Dave

Shai Almog

unread,
Nov 29, 2013, 12:14:44 AM11/29/13
to codenameone...@googlegroups.com, Shai Almog, Philip Iyobose Eki, dgoyet...@gmail.com
Its not in the Kitchen Sink its in the current API.

dgoyet...@gmail.com

unread,
Dec 13, 2013, 11:21:06 AM12/13/13
to codenameone...@googlegroups.com, Shai Almog, Philip Iyobose Eki, dgoyet...@gmail.com
I went back and implemented this finally, but have a couple of questions:

- This currently brings up a spinner on IOS 7.  Is there any way to get it to bring up a standard calendar type control?

- How do I know when a new date has been selected and the picker has been closed?  In the case of the user selecting the current date, I would like to override and set the text to "Today".  I guess I could derive the class and intercept the "setDate" method I guess.

Dave 

Shai Almog

unread,
Dec 13, 2013, 2:27:38 PM12/13/13
to codenameone...@googlegroups.com, Shai Almog, Philip Iyobose Eki, dgoyet...@gmail.com
The iOS 7 calendar uses a Spinner. I'm not exactly sure what you are talking about?

The method is blocking so it will return when the dialog is dismissed.
Reply all
Reply to author
Forward
0 new messages