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


Java OpenEvent类代码示例

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


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

示例1: addDocDisplayItemsAndHandlers

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
/**
 * @param docBean
 * @param docTitleLabel
 * @param docType
 * @param icon
 * @param docItem
 */
private void addDocDisplayItemsAndHandlers(final Document docBean, Label docTitleLabel, Label docType, Label icon,
		final TreeItem docItem) {
	String docDisplayProperty = getDocDisplayProperty(docBean, presenter.batchDTO.getDocDisplayName());
	DocumentTreeItem documentTreeItem = new DocumentTreeItem(docItem, docBean, icon, docDisplayProperty);
	addDocTreeItem(documentTreeItem);

	docItem.setTitle(documentTreeItem.documentTitle);
	docTitleLabel.setText(documentTreeItem.documentTitle);
	docType.setText(documentTreeItem.displayName);
	docTitleLabel.addClickHandler(new ClickHandler() {

		@Override
		public void onClick(ClickEvent arg0) {
			if (docItem.getState()) {
				docItem.setState(Boolean.FALSE);
			} else {
				OpenEvent.fire(docTree, docItem);
			}
		}
	});
}
 
开发者ID:kuzavas,项目名称:ephesoft,代码行数:29,代码来源:DocumentTree.java

示例2: onOpen

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
@Override
public void onOpen(final OpenEvent<Appointment> event) {
    showLoadingView();
    final Appointment appt = event.getTarget();
    final String imageId = appt.getId();
    dockerService.getImage(imageId, new AsyncCallback<KieImage>() {
        @Override
        public void onFailure(final Throwable caught) {
            showError(caught);
        }

        @Override
        public void onSuccess(final KieImage result) {
            if (result != null) {
                final List<KieImage> list = new ArrayList<KieImage>(1);
                list.add(result);
                imagesProvider.setList(list);
                redrawTable();
                showAllImagesPanel();
            } else {
                showError(Constants.INSTANCE.notAvailable());
            }
            hideLoadingView();
        }
    });
}
 
开发者ID:kiegroup,项目名称:kie-docker-ci,代码行数:27,代码来源:ImagesView.java

示例3: show

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
/**
    * Overrides show to call {@link #adjustGlassSize()} if the dialog
    * is already showing and fires an {@link OpenEvent} after the
    * normal show.
    */
   @Override
   public void show() {
boolean fireOpen = !isShowing();
super.show();

// adjust the size of the glass
if (isShowing()) {
    adjustGlassSize();
}

// fire the open event
if (fireOpen) {
    OpenEvent.fire(this, this);
}
   }
 
开发者ID:tractionsoftware,项目名称:gwt-traction,代码行数:21,代码来源:TractionDialogBox.java

示例4: onSuccess

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
public void onSuccess(List<PacketBbsThread> result) {
	for (final PacketBbsThread thread : result) {
		final LazyPanel lazyPanel = new LazyPanel() {
			@Override
			protected Widget createWidget() {
				DecoratorPanel decoratorPanel = new DecoratorPanel();
				decoratorPanel.setWidget(new PanelThread((int) thread.id, thread.title));
				return decoratorPanel;
			}
		};

		OpenHandler<DisclosurePanel> openHandler = new OpenHandler<DisclosurePanel>() {
			@Override
			public void onOpen(OpenEvent<DisclosurePanel> event) {
				lazyPanel.ensureWidget();
			}
		};

		DisclosurePanel disclosurePanel = new DisclosurePanel(thread.title);
		disclosurePanel.setContent(lazyPanel);
		disclosurePanel.addOpenHandler(openHandler);
		add(disclosurePanel);
	}
}
 
开发者ID:nodchip,项目名称:QMAClone,代码行数:25,代码来源:PanelThreadList.java

示例5: addBlankLine

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
public void addBlankLine() {
	List<Widget> line = new ArrayList<Widget>();

	HorizontalPanel hp = new HorizontalPanel();
	line.add(hp);

	CurriculaCourseSelectionBox cx = new CurriculaCourseSelectionBox();
	cx.setWidth("130px");
	cx.addCourseSelectionHandler(iCourseChangedHandler);
	if (cx.getCourseFinder() instanceof HasOpenHandlers)
		((HasOpenHandlers<PopupPanel>)cx.getCourseFinder()).addOpenHandler(new OpenHandler<PopupPanel>() {
			@Override
			public void onOpen(OpenEvent<PopupPanel> event) {
				iTable.clearHover();
			}
		});
	if (!iEditable) cx.setEnabled(false);
	line.add(cx);
	
	for (int col = 0; col < iClassifications.getClassifications().size(); col++) {
		ShareTextBox ex = new ShareTextBox(col, null, null);
		if (!iEditable) ex.setReadOnly(true);
		line.add(ex);
		EnrollmentLabel note = new EnrollmentLabel(col, null, null, null, null, null, null);
		line.add(note);
	}
	
	int row = iTable.addRow("", line);
	iTable.getRowFormatter().addStyleName(row, "unitime-NoPrint");
	if (iVisibleCourses != null) iTable.getRowFormatter().setVisible(row, false);
	for (int col = 0; col < line.size(); col++)
		if (!iTable.getCellFormatter().isVisible(0, col))
			iTable.getCellFormatter().setVisible(row, col, false);
}
 
开发者ID:Jenner4S,项目名称:unitimes,代码行数:35,代码来源:CurriculaCourses.java

示例6: show

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
@Override
public void show() {
    boolean fireOpen = !isShowing();
    super.show();
    if (fireOpen) {
        OpenEvent.fire(this, this);
    }
}
 
开发者ID:Jenner4S,项目名称:unitimes,代码行数:9,代码来源:UniTimeDialogBox.java

示例7: show

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
@Override
public void show() {
	boolean fireOpen = !isShowing();
	super.show();
	if (fireOpen) {
		OpenEvent.fire(this, this);
	}
}
 
开发者ID:NOAA-PMEL,项目名称:LAS,代码行数:9,代码来源:WindowBox.java

示例8: onOpen

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
@Override
public void onOpen(OpenEvent<TreeItem> event) {
    TreeItem item = event.getTarget();
    currentlySelected = item;
    if ( item.getChild(0).getText().equals(DatasetWidget.LOADING) ) {
        CategorySerializable cat = (CategorySerializable) item.getUserObject();
        Util.getRPCService().getCategories(cat.getID(), null, categoryCallback);
    }
}
 
开发者ID:NOAA-PMEL,项目名称:LAS,代码行数:10,代码来源:DatasetWidget.java

示例9: onOpen

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
@Override
public void onOpen(OpenEvent<DisclosurePanel> event) {

    for (Iterator panelIt = xPanels.iterator(); panelIt.hasNext();) {
        OutputPanel panel = (OutputPanel) panelIt.next();
        panel.setAnnotationsOpen(true);
    }

}
 
开发者ID:NOAA-PMEL,项目名称:LAS,代码行数:10,代码来源:UI.java

示例10: addDocTreeOpenHandler

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
/**
 * 
 */
private void addDocTreeOpenHandler() {
	docTree.addOpenHandler(new OpenHandler<TreeItem>() {

		@Override
		public void onOpen(OpenEvent<TreeItem> arg0) {
			TreeItem target = arg0.getTarget();
			String title = target.getTitle();
			String text = target.getText();
			presenter.document = getdocTreeItemByTitle(arg0.getTarget().getTitle()).document;
			boolean isAlreadySelected = setDocumentSelected(arg0.getTarget());

			List<Page> pageList = presenter.document.getPages().getPage();
			for (Page page : pageList) {
				String identifier = page.getIdentifier();
				PageImage pageImage = pageImageMap.get(identifier);
				RotatableImage image = pageImage.getImage();
				if (!page.isIsRotated()) {
					image.setUrl(presenter.batchDTO.getAbsoluteURLFor(page.getThumbnailFileName()), page.getDirection());
				} else {
					image.setUrl(presenter.batchDTO.getAbsoluteURLForRotatedImage(page.getThumbnailFileName(), page.getDirection()
							.toString()), page.getDirection());
				}
			}

			presenter.page = presenter.document.getPages().getPage().get(0);

			setPageSelected(getPageImageById(presenter.page.getIdentifier()).image, false);
			int itemCount = presenter.getView().getRvPanel().getReviewPanel().documentTypes.getItemCount();
			if (target.getChildCount() > 0 && !(title.isEmpty() && text.isEmpty())) {
				scrollIntoView(target.getElement());
			}
			if (!isAlreadySelected || itemCount == 0) {
				DocumentTree.this.fireEvent(new DocExpandEvent(presenter.document));
			} else {
				DocumentTree.this.fireEvent(new DocExpandEvent(presenter.document, false));
			}
		}
	});
}
 
开发者ID:kuzavas,项目名称:ephesoft,代码行数:43,代码来源:DocumentTree.java

示例11: _fireExpandOrCollapseEvent

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
void _fireExpandOrCollapseEvent(final boolean expand) {
	if (_tree != null) {
		if (expand) {
			OpenEvent.fire(_tree,this);
			TreeViewItemExpandEvent.fire(_tree,this);
		} else {
			CloseEvent.fire(_tree,this);
			TreeViewItemCollapseEvent.fire(_tree,this);
		}
	}
}
 
开发者ID:opendata-euskadi,项目名称:r01fb,代码行数:12,代码来源:TreeViewItem.java

示例12: fireStateChanged

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
void fireStateChanged(final T item,
                      final T.State state) {
    if (state.equals(T.State.OPEN)) {
        OpenEvent.fire(this,
                       item);
    } else {
        CloseEvent.fire(this,
                        item);
    }
    onSelection(item,
                true);
}
 
开发者ID:kiegroup,项目名称:appformer,代码行数:13,代码来源:Tree.java

示例13: onTitleClicked

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
private void onTitleClicked() {
    if (expanded) {
        CloseEvent.fire(this,
                        this);
    } else {
        OpenEvent.fire(this,
                       this);
    }
}
 
开发者ID:kiegroup,项目名称:appformer,代码行数:10,代码来源:LazyStackPanelHeader.java

示例14: onTreeOpen

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
@UiHandler("tree")
void onTreeOpen(OpenEvent<TreeItem> event) {
	TreeItem item = event.getTarget();
	if(item.getText().length() > 1) return; // search field hack
	String first = item.getText();
	presenter.loadUsers(first, item);
}
 
开发者ID:jkonert,项目名称:socom,代码行数:8,代码来源:UserAdministrationView.java

示例15: addOpenHandler

import com.google.gwt.event.logical.shared.OpenEvent; //导入依赖的package包/类
public HandlerRegistration addOpenHandler(OpenHandler<UniTimeDialogBox> handler) {
    return addHandler(handler, OpenEvent.getType());
}
 
开发者ID:Jenner4S,项目名称:unitimes,代码行数:4,代码来源:UniTimeDialogBox.java


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