Opened 13 years ago

Last modified 8 years ago

#7567 closed defect

dojox.html._ContentSetter should evaluate scripts prior to the call of the super class method — at Version 1

Reported by: Achim Klotz Owned by: Sam Foster
Priority: high Milestone: future
Component: Dojox Version:
Keywords: Cc:
Blocked By: Blocking:

Description (last modified by bill)

in the current version the method "onBegin" first calls the method of the super class and then does the adaptions of styles and script.

But I think a least the script should be done prior to the call of the super class method (only of the type "text/javascript" are relevant here).

Otherwise it's not possible to declare function in inline script tags or external script file which than can be used in "dojo/method" script blocks.


<script type="text/javascript">
function doSomething() { alert('foo');}

<button dojoType="dijit.form.Button" label="Test Button">
    <script type="dojo/method">
        this.onClick = doSomething;

If you are placing the code example above into a dojox.layout.ContentPane? you'll get an error because during the evaluation of the dojo/method script block the method "doSomething" is unknown

Change History (1)

comment:1 Changed 13 years ago by bill

Description: modified (diff)
Owner: changed from Adam Peller to Sam Foster
Note: See TracTickets for help on using tickets.