#9655 closed defect (fixed)
DropDownSelect: cannot be created programmatically without a source node
Reported by: | Bryan Forbes | Owned by: | Nathan Toone |
---|---|---|---|
Priority: | high | Milestone: | 1.4 |
Component: | Dijit - Form | Version: | 1.3.2 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
Every other widget in Dijit can be created by doing this:
var widget = new dijit.some.Widget({ /* properties here */ });
When you do that with dijit.form.DropDownSelect?, it throws an error:
node is undefined
It stems from the postCreate function doing this:
if(dojo.attr(this.srcNodeRef, "disabled")){ this.attr("disabled", true); }
To me, this seems unnecessary since the attributes of the node should be taken care of by _Widget if they are declared on the prototype (and "disabled" is declared on the prototype of dijit.form._FormWidget). I'm attaching a modified test which adds three DropDownSelects? to the test: two programmatic (of which, one is disabled), and one disabled from markup.
Attachments (1)
Change History (5)
Changed 12 years ago by
Attachment: | test_DropDownSelect.html added |
---|
comment:1 Changed 12 years ago by
Owner: | set to Nathan Toone |
---|---|
Summary: | dijit.form.DropDownSelect cannot be created programmatically without a source node → DropDownSelect: cannot be created programmatically without a source node |
comment:2 Changed 12 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:3 Changed 12 years ago by
comment:4 Changed 10 years ago by
Component: | Dijit → Dijit - Form |
---|
Note: See
TracTickets for help on using
tickets.
Assigning to Nathan although of course if you have a fix Bryan feel free to check in.