本文整理汇总了Java中com.google.gwt.user.client.ui.ToggleButton.addClickHandler方法的典型用法代码示例。如果您正苦于以下问题:Java ToggleButton.addClickHandler方法的具体用法?Java ToggleButton.addClickHandler怎么用?Java ToggleButton.addClickHandler使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.google.gwt.user.client.ui.ToggleButton
的用法示例。
在下文中一共展示了ToggleButton.addClickHandler方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: addComponentListeners
import com.google.gwt.user.client.ui.ToggleButton; //导入方法依赖的package包/类
/**
* {@inheritDoc}
*/
@Override
protected void addComponentListeners() {
ComboBoxSelectItem value = getSelectedValue();
ToggleButton button = getChoiceButton();
getListPanel().addChangeHandler(getDelegateHandler());
//value.addChangeHandler(getDelegateHandler());
button.addFocusHandler(getDelegateHandler());
value.addFocusHandler(getDelegateHandler());
button.addBlurHandler(getDelegateHandler());
value.addBlurHandler(getDelegateHandler());
value.addClickHandler(getDelegateHandler());
button.addClickHandler(getDelegateHandler());
value.addKeyUpHandler(getDelegateHandler());
value.addKeyDownHandler(getDelegateHandler());
value.addKeyPressHandler(getDelegateHandler());
}
示例2: createToggleButton
import com.google.gwt.user.client.ui.ToggleButton; //导入方法依赖的package包/类
/** Method to create a Toggle button for the toolbar **/
private ToggleButton createToggleButton(String url, Integer top, Integer left, Integer width, Integer height, String tip) {
Image extract = new Image(url, left, top, width, height);
ToggleButton tb = new ToggleButton(extract);
tb.setHeight(height+"px");
tb.setWidth(width+"px");
tb.addClickHandler(evHandler);
if (tip != null) {
tb.setTitle(tip);
}
return tb;
}
示例3: createToggleButton
import com.google.gwt.user.client.ui.ToggleButton; //导入方法依赖的package包/类
private ToggleButton createToggleButton(AbstractImagePrototype img, String tip) {
ToggleButton tb = new ToggleButton(img.createImage());
tb.addClickHandler(handler);
tb.setTitle(tip);
return tb;
}
示例4: createToggleButton
import com.google.gwt.user.client.ui.ToggleButton; //导入方法依赖的package包/类
private ToggleButton createToggleButton(ImageResource img, String tip) {
ToggleButton tb = new ToggleButton(new Image(img));
tb.addClickHandler(handler);
tb.setTitle(tip);
return tb;
}
示例5: createToggleButton
import com.google.gwt.user.client.ui.ToggleButton; //导入方法依赖的package包/类
private ToggleButton createToggleButton(ImageResource img, String tip) {
ToggleButton tb = new ToggleButton(new Image(img));
tb.addClickHandler(handler);
tb.setTitle(tip);
return tb;
}
示例6: createToggleButton
import com.google.gwt.user.client.ui.ToggleButton; //导入方法依赖的package包/类
private ToggleButton createToggleButton(ImageResource img, String tip) {
ToggleButton tb = new ToggleButton(new Image(img));
tb.addClickHandler(handler);
tb.setTitle(tip);
return tb;
}