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


Java GwtEvent类代码示例

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


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

示例1: onKeyDown

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
@Override
public void onKeyDown(final KeyDownEvent event) {

	if (event.getNativeKeyCode() == keyCode) {				
		actionButton.fireEvent( new GwtEvent<ClickHandler>() {
	        @Override
	        public com.google.gwt.event.shared.GwtEvent.Type<ClickHandler> getAssociatedType() {
	        	return ClickEvent.getType();
	        }
	        @Override
	        protected void dispatch(final ClickHandler handler) {
	            handler.onClick(null);
	        }
	   });
	}
}
 
开发者ID:geowe,项目名称:sig-seguimiento-vehiculos,代码行数:17,代码来源:KeyShortcutHandler.java

示例2: testSelectionEvent

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
public void testSelectionEvent() {
    MaterialNavSection widget = new MaterialNavSection();

    final boolean[] isSelectionEventFired = {false};
    widget.addSelectionHandler(selectionEvent -> isSelectionEventFired[0] = true);
    widget.fireEvent(new GwtEvent<SelectionHandler<?>>() {
        @Override
        public Type<SelectionHandler<?>> getAssociatedType() {
            return SelectionEvent.getType();
        }

        @Override
        protected void dispatch(SelectionHandler eventHandler) {
            eventHandler.onSelection(null);
        }
    });

    assertTrue(isSelectionEventFired[0]);
}
 
开发者ID:GwtMaterialDesign,项目名称:gwt-material,代码行数:20,代码来源:MaterialNavSectionTest.java

示例3: itemStateChanged

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
public void itemStateChanged(GwtEvent e) {
    Object src = e.getSource();
    int i;
    boolean changed = false;
    for (i = 0; i != einfocount; i++) {
	EditInfo ei = einfos[i];
	if (ei.choice == src || ei.checkbox == src || ei.button == src) {
	    
	    // if we're pressing a button, make sure to apply changes first
	    if (ei.button == src)
		apply();
	    
	    elm.setEditValue(i, ei);
	    if (ei.newDialog)
		changed = true;
	    cframe.needAnalyze();
	}
    }
    if (changed) {
	clearDialog();
	buildDialog();
    }
}
 
开发者ID:sharpie7,项目名称:circuitjs1,代码行数:24,代码来源:EditDialog.java

示例4: fireEvent

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
public void fireEvent(GwtEvent<?> event) {
    if (event.getAssociatedType().equals(RowCountChangeEvent.getType())) {
        rowCountHandlers.forEach((h) -> h.onRowCountChange((RowCountChangeEvent) event));
    } else if (event.getAssociatedType().equals(RangeChangeEvent.getType())) {
        rangeHandlers.forEach((h) -> h.onRangeChange((RangeChangeEvent) event));
    }
}
 
开发者ID:kiegroup,项目名称:optashift-employee-rostering,代码行数:8,代码来源:TwoDayViewPager.java

示例5: getType

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
public static GwtEvent.Type<Handler> getType()
{
  return TYPE;
}
 
开发者ID:realityforge,项目名称:gwt-keycloak,代码行数:5,代码来源:AuthRefreshSuccessEvent.java

示例6: getAssociatedType

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
@Override
public GwtEvent.Type<Handler> getAssociatedType()
{
  return AuthRefreshSuccessEvent.getType();
}
 
开发者ID:realityforge,项目名称:gwt-keycloak,代码行数:6,代码来源:AuthRefreshSuccessEvent.java

示例7: getAssociatedType

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
@Override
public GwtEvent.Type<Handler> getAssociatedType()
{
  return AuthErrorEvent.getType();
}
 
开发者ID:realityforge,项目名称:gwt-keycloak,代码行数:6,代码来源:AuthErrorEvent.java

示例8: getAssociatedType

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
@Override
public GwtEvent.Type<Handler> getAssociatedType()
{
  return BeforeAuthLogoutEvent.getType();
}
 
开发者ID:realityforge,项目名称:gwt-keycloak,代码行数:6,代码来源:BeforeAuthLogoutEvent.java

示例9: getAssociatedType

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
@Override
public GwtEvent.Type<Handler> getAssociatedType()
{
  return AuthSuccessEvent.getType();
}
 
开发者ID:realityforge,项目名称:gwt-keycloak,代码行数:6,代码来源:AuthSuccessEvent.java

示例10: getAssociatedType

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
@Override
public GwtEvent.Type<Handler> getAssociatedType()
{
  return AuthRefreshErrorEvent.getType();
}
 
开发者ID:realityforge,项目名称:gwt-keycloak,代码行数:6,代码来源:AuthRefreshErrorEvent.java

示例11: getAssociatedType

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
@Override
public GwtEvent.Type<Handler> getAssociatedType()
{
  return TokenExpiredEvent.getType();
}
 
开发者ID:realityforge,项目名称:gwt-keycloak,代码行数:6,代码来源:TokenExpiredEvent.java

示例12: getAssociatedType

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
@Override
public com.google.gwt.event.shared.GwtEvent.Type<CommandSendHandler> getAssociatedType() {
	return TYPE;
}
 
开发者ID:openremote,项目名称:WebConsole,代码行数:5,代码来源:CommandSendEvent.java

示例13: removeStaleEvents

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
private void removeStaleEvents(List<GwtEvent> pendingRPCEvents, Type type) {
    List<GwtEvent> remove = new ArrayList<GwtEvent>();
    for (Iterator eIt = pendingRPCEvents.iterator(); eIt.hasNext();) {
        GwtEvent gwtEvent = (GwtEvent) eIt.next();
        if ( gwtEvent.getAssociatedType().equals(type) ) {
            remove.add(gwtEvent);
        }
    }
    pendingRPCEvents.removeAll(remove);
}
 
开发者ID:NOAA-PMEL,项目名称:LAS,代码行数:11,代码来源:RPCManager.java

示例14: removeGetCategoriesEvent

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
private void removeGetCategoriesEvent(String catid, String dsid) {
    List<GwtEvent> remove = new ArrayList<GwtEvent>();
    for (Iterator eIt = pendingRPCEvents.iterator(); eIt.hasNext();) {
        GwtEvent gwtEvent = (GwtEvent) eIt.next();
        if ( gwtEvent.getAssociatedType().equals(GetCategoriesEvent.TYPE) ) {
            GetCategoriesEvent e = (GetCategoriesEvent) gwtEvent;
            if ( e.getCatid().equals(catid) && e.getDsid().equals(dsid) ) {
                remove.add(gwtEvent);
            }
        }
        pendingRPCEvents.remove(remove);
    }
}
 
开发者ID:NOAA-PMEL,项目名称:LAS,代码行数:14,代码来源:RPCManager.java

示例15: removeConfigSerialableEvent

import com.google.gwt.event.shared.GwtEvent; //导入依赖的package包/类
private void removeConfigSerialableEvent(String dsid, String varid) {
    List<GwtEvent> remove = new ArrayList<GwtEvent>();
    for (Iterator eIt = pendingRPCEvents.iterator(); eIt.hasNext();) {
        GwtEvent gwtEvent = (GwtEvent) eIt.next();
        if ( gwtEvent.getAssociatedType().equals(GetConfigEvent.TYPE) ) {
            GetConfigEvent e = (GetConfigEvent) gwtEvent;
            if ( e.getDsid().equals(dsid) && e.getVarid().equals(varid) ) {
                remove.add(gwtEvent);
            }
        }
    }
    pendingRPCEvents.remove(remove);
}
 
开发者ID:NOAA-PMEL,项目名称:LAS,代码行数:14,代码来源:RPCManager.java


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