Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setting the Picker to allow picking a date before Epoch doesn't work #3871

Closed
shai-almog opened this issue Feb 8, 2025 · 0 comments · Fixed by #3873
Closed

Setting the Picker to allow picking a date before Epoch doesn't work #3871

shai-almog opened this issue Feb 8, 2025 · 0 comments · Fixed by #3873
Assignees

Comments

@shai-almog
Copy link
Collaborator

See following test case:

try {
    Form hi = new Form("Picker", BoxLayout.y());
    Picker p = new Picker();
    p.setType(Display.PICKER_TYPE_DATE);
    SimpleDateFormat simpleDateFormat = new SimpleDateFormat("dd/MM/yyyy");
    Date d = simpleDateFormat.parse("01/01/1960");
    Log.p("Date is: " + d);
    p.setStartDate(d);
    hi.add(p);
    hi.show();
} catch (ParseException e) {
    throw new RuntimeException(e);
}

It correctly prints:
[EDT] 0:0:0,102 - Date is: Fri Jan 01 04:00:00 IST 1960

Despite setting the picker to 1960 the picker shows 1970 as the start date.

Image
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants