Closed GoogleCodeExporter closed 9 years ago
I'll check the destroy issue...
But for your scenario I would initialize mobiscroll with option 'showOnFocus'
option set to false (Ooops, not in the doc...). And on your icon click call
$('.mobiscroll').scroller('show');
Original comment by diosla...@gmail.com
on 19 Sep 2011 at 2:49
Thank you for your fast response!
There where two little issues left. For others interested in the
'Image'-solution:
1. 'showOnFocus' only disables the onClick-Handler. The input-field is still
readOnly.
TODO: Make input editable after initializing mobiscroll.
mobiInput.scroller(defaults);
mobiInput.removeAttr('readonly');
mobiInput.attr('contentEditable',true);
2. The field is readOnly and 'show' doesn't get the new input.
TODO: Set the new Date in the onClick-Handler of the image.
function showScroller() {
var value = mobiInput.val();
var date = $.scroller.parseDate('dd.mm.y',value,defaults);
mobiInput.scroller('setDate', date);
mobiInput.scroller('show');
}
With these changes it works like a charm.
regards
Andreas
Original comment by andreas....@googlemail.com
on 20 Sep 2011 at 8:13
Thanks for the insights. We'll try to make this easier in a next release.
Original comment by diosla...@gmail.com
on 20 Sep 2011 at 8:25
Fixed in 1.5.1. Now it should work with only showOnFocus false, and call show
on button click. Parse date, setDate, and modifying the readonly property is
not necessary.
Original comment by diosla...@gmail.com
on 21 Sep 2011 at 9:48
Original issue reported on code.google.com by
andreas....@googlemail.com
on 19 Sep 2011 at 1:49