The method shown in Listing 20 can further be modified as shown in Listing 21, so that the selected nodes keep their style when clicking on a disabled node after an enabled node was already selected.
清单20中所示的方法可以进一步修改,以使这些选中的节点能在一个启用了的节点被选中后单击某个被禁用的节点时仍保持其样式,如清单21所示。
If, however, you're in a static method, you have to get the root node and provide the package yourself, as shown in Listing 2.
但是,如果您使用的是静态方法,您就必须得到根节点并自己提供包,如清单2所示。
The code snippet shown in Listing 2 specifies that any element (Dojo widget) that needs to be rendered is created in this method and added to the DOM node of the container div.
清单2中显示的代码片段规定:要呈现的任何元素(Dojowidget)都在此方法中创建,并且添加到容器div的DOM节点上。
The method shown in Listing 20 can be used to ignore the onClick event by simply returning if a disabled node was clicked on.
清单20 中所示的方法可用来忽略onClick事件,只返回某个被禁用了的节点是否被单击。
In the code in Listing 7, the callback method of the controller first generates the HTML fragment using the XSLProcessor module and then injects it into the targeted node.
在清单7所示的代码中,控制器的回调方法首先使用XSLProcessor模块生成HTML片段,然后将其注入到目标节点中。
The program in Listing 4 shows a generic method for right-clicking the tree node.
列表4中的程序显示了右击树节点的通用方法。
For retrieving the files in each activity, use another method in the TreeParent object to get the URL of the activity (first-level node) and do a get request on the activity URL as shown in listing 3.
为了获取每个活动中的文件,使用TreeParent对象中的另一个方法获取活动(第一级节点)的URL,并对活动url执行一个GET请求,见清单3。
To get specific behavior depending on which node is right-clicked, you could connect to the _openmyself method of the menu as shown in Listing 35.
要想根据右键单击的具体节点来获得特定的行为,可以连接到此菜单的_openmyself方法,如清单35所示。
To get specific behavior depending on which node is right-clicked, you could connect to the _openmyself method of the menu as shown in Listing 35.
要想根据右键单击的具体节点来获得特定的行为,可以连接到此菜单的_openmyself方法,如清单35所示。
应用推荐