📄 htmlradiobuttonmenuitem.java
字号:
package com.exp.web.html.menu;
/**
* <p>
* Title: jstrd 基础技术平台
* </p>
* <p>
* Descrijstrd 基础技术平台: exp平台
* </p>
* <p>
* Copyright: Copyright (c) jstrd 2004-2008
* </p>
* <p>
* Company: jstrd
* </p>
*
* @author zhanghf
* @version 3.0.0.0
*/
public class HtmlRadioButtonMenuItem extends HtmlMenuItem {
protected boolean checked = false;
protected String radioGroupName;
public HtmlRadioButtonMenuItem(String name, String caption,
boolean checked, String groupName) {
super(name, caption);
this.checked = checked;
this.radioGroupName = groupName;
}
protected void generateSelfScript(StringBuffer buf, String subMenu) {
buf.append("var " + this.name + "=new RadioButtonMenuItem(\""
+ this.caption + "\",");
if (this.checked) {
buf.append("true,");
} else {
buf.append("false,");
}
buf.append("\"" + this.radioGroupName + "\",");
if ("".equals(this.action)) {
buf.append("null");
} else {
buf.append("\"" + this.action + "\"");
}
if (!"".equals(subMenu)) {
buf.append("," + subMenu);
}
buf.append(");\n");
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -