Opened 7 years ago

Closed 7 years ago

#16880 closed defect (fixed)

SpinWheelDatePicker not working when view it is in is not selected initially

Reported by: jman100 Owned by: Eric Durocher
Priority: undecided Milestone: 1.9
Component: DojoX Mobile Version: 1.8.3
Keywords: Cc:
Blocked By: Blocking:

Description

When SpinWheelDatePicker? is used in code either outside of a specific view or within a view that is "selected" ie the view shown at load, it works fine. (see example1.html). However if the view it is in is not the main selected view (see example2.html) it does not work, throws the following error: Uncaught TypeError?: Cannot call method 'getMonth' of null in date.js

Attachments (3)

example1.html (2.5 KB) - added by jman100 7 years ago.
Example 1 - Works when view is selected
example2.html (2.5 KB) - added by jman100 7 years ago.
Example 2 - Does not work when the view the picker is in is not selected
patch16880.patch (7.6 KB) - added by Adrian Vasiliu 7 years ago.
Now sets this.containerNode such that getChildren() works. This impacts the startup() execution order and fixes broken spinwheels when inside Tooltip / Overlay / Opener in a view initially invisible. - Adrian Vasiliu (IBM, CCLA)

Download all attachments as: .zip

Change History (7)

Changed 7 years ago by jman100

Attachment: example1.html added

Example 1 - Works when view is selected

Changed 7 years ago by jman100

Attachment: example2.html added

Example 2 - Does not work when the view the picker is in is not selected

comment:1 Changed 7 years ago by Adrian Vasiliu

Reproduced with Dojo 1.8.0, 1.8.3 and 1.9b2.

Waiting for a fix, the following workaround makes it work: just specify lazy:true for the Opener.

Changed 7 years ago by Adrian Vasiliu

Attachment: patch16880.patch added

Now sets this.containerNode such that getChildren() works. This impacts the startup() execution order and fixes broken spinwheels when inside Tooltip / Overlay / Opener in a view initially invisible. - Adrian Vasiliu (IBM, CCLA)

comment:2 Changed 7 years ago by Adrian Vasiliu

(For Dojo 2.0 we will also consider adding dijit/_Container to Tooltip's and Overlay's inheritance chain.)

comment:3 Changed 7 years ago by Adrian Vasiliu

In [31204]:

fixes #16880. Now sets this.containerNode such that getChildren() works. This impacts the startup() execution order and fixes broken spinwheels when used inside Tooltip or Overlay or Opener in a view initially invisible.

comment:4 Changed 7 years ago by Eric Durocher

Milestone: tbd1.9
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.