Question

I've just recently updated my personal phone to Android 4.0.4. Doing so, I've noticed that the DatePickerDialog which I display in my application is no longer showing the long date format in the title bar like it would in previous versions :

enter image description here

Instead it simply says : 'Set date'.

So, is there a quick way to make it so that this particular DatePickerDialog always display the long date in the title bar ? Or is this a version limitation which I'll have to overcome by creating my own custom Dialog?

Was it helpful?

Solution

So, is there a quick way to make it so that this particular DatePickerDialog always display the long date in the title bar ?

The former update-the-title logic is completely removed from the current DatePickerDialog source code. You should be able to extend DatePickerDialog and override onDateChanged() (and the six-parameter constructor) to restore this functionality, at least in theory -- I have never tried this.

FWIW, here is a link to an older version of DatePickerDialog that had the update-the-title logic.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top