我的输入文本框有这个类:
class InputTextBox extends FlowPanel {
public InputTextBox(String labelText) {
super();
Label label = new Label(labelText);
TextBox input = new TextBox();
this.add(label);
this.add(input);
this.addStyleName("myBox");
}
}
Run Code Online (Sandbox Code Playgroud)
如何将焦点设置在该文本框上,以便在调用onmoduleload时,光标出现在文本框中?添加成员函数似乎会抛出许多错误.
public void setFocus(boolean b) {
this.setFocus(b);
}
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
7072 次 |
最近记录: |