当前位置: 首页>>代码示例>>Java>>正文


Java HasSelectionHandlers类代码示例

本文整理汇总了Java中com.google.gwt.event.logical.shared.HasSelectionHandlers的典型用法代码示例。如果您正苦于以下问题:Java HasSelectionHandlers类的具体用法?Java HasSelectionHandlers怎么用?Java HasSelectionHandlers使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


HasSelectionHandlers类属于com.google.gwt.event.logical.shared包,在下文中一共展示了HasSelectionHandlers类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setItemSelected

import com.google.gwt.event.logical.shared.HasSelectionHandlers; //导入依赖的package包/类
public void setItemSelected(JavaScriptObject aValue) {
	if (itemSelected != aValue) {
		if (selectedItemReg != null) {
			selectedItemReg.removeHandler();
			selectedItemReg = null;
		}
		itemSelected = aValue;
		if (component instanceof HasSelectionHandlers<?>) {
			selectedItemReg = ((HasSelectionHandlers<Object>) component).addSelectionHandler(new SelectionHandler<Object>() {

				@Override
				public void onSelection(SelectionEvent<Object> event) {
					JavaScriptObject published = ((HasPublished) event.getSource()).getPublished();
					Object oItem = event.getSelectedItem();
					if (oItem instanceof HasPublished)
						oItem = ((HasPublished) oItem).getPublished();
					executeEvent(itemSelected, EventsPublisher.publishItemEvent(published, oItem instanceof JavaScriptObject ? (JavaScriptObject) oItem : null));
				}

			});
		}
	}
}
 
开发者ID:marat-gainullin,项目名称:platypus-js,代码行数:24,代码来源:EventsExecutor.java

示例2: addSelectionHandler

import com.google.gwt.event.logical.shared.HasSelectionHandlers; //导入依赖的package包/类
protected void addSelectionHandler(HasSelectionHandlers<PartDefinition> widget) {
    widget.addSelectionHandler(new SelectionHandler<PartDefinition>() {
        @Override
        public void onSelection(final SelectionEvent<PartDefinition> event) {
            panelManager.onPartLostFocus();
            panelManager.onPartFocus(event.getSelectedItem());
        }
    });
}
 
开发者ID:kiegroup,项目名称:appformer,代码行数:10,代码来源:AbstractWorkbenchPanelView.java

示例3: getTabPanelSelector

import com.google.gwt.event.logical.shared.HasSelectionHandlers; //导入依赖的package包/类
public HasSelectionHandlers<Integer> getTabPanelSelector() {
    return tab_panel;
}
 
开发者ID:jhu-digital-manuscripts,项目名称:rosa,代码行数:4,代码来源:SequenceView.java

示例4: getTabPanelSelector

import com.google.gwt.event.logical.shared.HasSelectionHandlers; //导入依赖的package包/类
HasSelectionHandlers<Integer> getTabPanelSelector(); 
开发者ID:jhu-digital-manuscripts,项目名称:rosa,代码行数:2,代码来源:SequencePanelPresenter.java


注:本文中的com.google.gwt.event.logical.shared.HasSelectionHandlers类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。