gpt4 book ai didi

button - 道场 : how to set to disable new button

转载 作者:行者123 更新时间:2023-12-04 01:38:11 25 4
gpt4 key购买 nike

嗨,我无法将新按钮设置为禁用。
我正在使用 Dojo 1.8

请参阅下面的代码:-

require(["dojo/parser", "dijit/layout/BorderContainer",
"dijit/form/Button","dojo/on","dijit/form/Select",
"dojo/store/Memory", "dojo/request","dojo/domReady!"
],
function(parser, BorderContainer, Button, on, Select, Memory, request)
{

var btn4 = new Button // Button, not button
({
label: "Number of cards",
this.set("disabled", false) // This code that disables the button
},"btn4");
btn4.startup();
})

我在 Dojo 或谷歌上找不到帮助。

最佳答案

在 Dojo 中,许多事情与您所期望的不同。

按钮有方法setDisabled :

btn4.setDisabled(true) // disable
btn4.setDisabled(false) // enable

关于button - 道场 : how to set to disable new button,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17737811/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com