本文整理汇总了Java中com.google.gwt.event.logical.shared.AttachEvent.Handler类的典型用法代码示例。如果您正苦于以下问题:Java Handler类的具体用法?Java Handler怎么用?Java Handler使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Handler类属于com.google.gwt.event.logical.shared.AttachEvent包,在下文中一共展示了Handler类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: OwnerJobTrend
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
public OwnerJobTrend(){
date=new DateField();
date.setEditable(false);
date.setAllowBlank(false);
date.setValue(new Date());
HorizontalLayoutContainer form=new HorizontalLayoutContainer();
form.add(new FieldLabel(date,"日期"),new HorizontalLayoutData());
form.add(submit,new HorizontalLayoutData());
container.add(form,new VerticalLayoutData(1,30));
container.addAttachHandler(new Handler() {
public void onAttachOrDetach(AttachEvent event) {
submit.fireEvent(new SelectEvent());
}
});
}
开发者ID:ctripcorp,项目名称:dataworks-zeus,代码行数:18,代码来源:OwnerJobTrend.java
示例2: RunningJobTrend
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
public RunningJobTrend(){
start=new DateField();
start.setEditable(false);
start.setValue(new Date(new Date().getTime()-7*24*60*60*1000L));
end=new DateField();
end.setEditable(false);
end.setValue(new Date());
HorizontalLayoutContainer form=new HorizontalLayoutContainer();
form.add(new FieldLabel(start, "起始日期"),new HorizontalLayoutData(0.3,1));
form.add(new FieldLabel(end,"截止日期"),new HorizontalLayoutData(0.3, 1));
form.add(submit,new HorizontalLayoutData(-1,-1));
container.add(form,new VerticalLayoutData(1, 30));
container.addAttachHandler(new Handler() {
public void onAttachOrDetach(AttachEvent event) {
submit.fireEvent(new SelectEvent());
}
});
}
开发者ID:ctripcorp,项目名称:dataworks-zeus,代码行数:21,代码来源:RunningJobTrend.java
示例3: ArchiveEntryImagePanel
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
public ArchiveEntryImagePanel(ArchiveEntryCollectionRef arc,
ArchiveEntry entry) {
_arc = arc;
_entry = entry;
_ap = new AbsolutePanel();
_ap.fitToParent();
_ap.setOverflow(Overflow.HIDDEN);
initWidget(_ap);
addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (event.isAttached()) {
loadImage();
}
}
});
}
开发者ID:uom-daris,项目名称:daris,代码行数:23,代码来源:ArchiveEntryImagePanel.java
示例4: postConstruct
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Called after construction.
*/
@PostConstruct
protected void postConstruct() {
addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (event.isAttached()) {
cid = generateUniqueCid();
getElement().addClassName(cid);
initPicker(cid,DEFAULT_DATE_TIME_FORMAT);
} else {
removePicker(cid);
}
}
});
}
开发者ID:Governance,项目名称:rtgov-ui,代码行数:19,代码来源:DateTimePicker.java
示例5: postConstruct
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Called after construction.
*/
@PostConstruct
protected void postConstruct() {
addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (event.isAttached()) {
cid = generateUniqueCid();
getElement().addClassName(cid);
init(cid);
} else {
remove(cid);
}
}
});
}
开发者ID:Governance,项目名称:rtgov-ui,代码行数:19,代码来源:ToggleSwitch.java
示例6: createFieldWidget
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
@Override
protected boolean createFieldWidget() {
initWidget(uiBinder.createAndBindUi(this));
field = textArea;
toolbar.initToolBar(textArea);
textArea.addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
AtomTools.log(Level.FINE, "textArea.onAttachOrDetach - " + event.toDebugString(), this);
fixIFrameDefaultFont(true);
}
});
fixIFrameDefaultFont(true);
return false;
}
开发者ID:fhcampuswien,项目名称:atom,代码行数:20,代码来源:StringFormattedLobView.java
示例7: updateVerticalScrollGridDelegation
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
private void updateVerticalScrollGridDelegation() {
// register scroll handler to Gantt widget
ganttScrollHandlerRegistration = getWidget().addDomHandler(ganttScrollHandler, ScrollEvent.getType());
scrollDelegateHandlerRegistration = delegateScrollGridTarget.addScrollHandler(gridScrollDelegateTargetHandler);
// add detach listener to unregister scroll handler when its
// detached.
delegateScrollGridTarget.addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (!event.isAttached() && scrollDelegateHandlerRegistration != null) {
scrollDelegateHandlerRegistration.removeHandler();
}
}
});
}
开发者ID:tltv,项目名称:gantt,代码行数:19,代码来源:GanttConnector.java
示例8: updateVerticalScrollTableDelegation
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
private void updateVerticalScrollTableDelegation() {
// register scroll handler to Gantt widget
ganttScrollHandlerRegistration = getWidget().addDomHandler(ganttScrollHandler, ScrollEvent.getType());
// register a scroll handler to 'delegation' scroll panel.
scrollDelegateHandlerRegistration = delegateScrollPanelTarget.addScrollHandler(scrollDelegateTargetHandler);
// add detach listener to unregister scroll handler when its
// detached.
delegateScrollPanelTarget.addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (!event.isAttached() && scrollDelegateHandlerRegistration != null) {
scrollDelegateHandlerRegistration.removeHandler();
}
}
});
}
开发者ID:tltv,项目名称:gantt,代码行数:20,代码来源:GanttConnector.java
示例9: postConstruct
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Called after construction.
*/
@PostConstruct
protected void postConstruct() {
addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (event.isAttached()) {
cid = generateUniqueCid();
getElement().addClassName(cid);
initPicker(cid);
} else {
removePicker(cid);
}
}
});
}
开发者ID:Governance,项目名称:overlord-commons,代码行数:19,代码来源:DateBox.java
示例10: TimeSlider
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Creates a new TimeSlider object.
*
* @param params - Parameters for the time slider object.
* @param loadHandler - handler to fire when dijit is created. All method calls will fail untill this
* event fires.
*/
public TimeSlider(Parameters params, DijitLoadHandler handler) {
if( !assertLoaded() ) return;
loadHandler = handler;
parameters = params;
initWidget(panel);
addAttachHandler(new Handler(){
@Override
public void onAttachOrDetach(AttachEvent event) {
if( event.isAttached() && jso == null ) {
jso = _create(parameters, panel.getElement());
if( loadHandler != null ) loadHandler.onLoad();
}
}
});
}
开发者ID:CSTARS,项目名称:gwt-esri,代码行数:28,代码来源:TimeSlider.java
示例11: AttributeInspector
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Creates a new Attribute Inspector object.
*
* @param params - input parameters
*/
public AttributeInspector(Parameters params) {
if( !assertLoaded() ) return;
parameters = params;
initWidget(panel);
addAttachHandler(new Handler(){
@Override
public void onAttachOrDetach(AttachEvent event) {
if(jso == null ) jso = create(parameters);
}
});
}
开发者ID:CSTARS,项目名称:gwt-esri,代码行数:22,代码来源:AttributeInspector.java
示例12: Editor
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Creates a new Editor object.
*
* @param params - Parameters that define the functionality of the editor widget. Create a
* new settings object to pass to the widget
*/
public Editor(Parameters params) {
if( !assertLoaded() ) return;
parameters = params;
initWidget(panel);
addAttachHandler(new Handler(){
@Override
public void onAttachOrDetach(AttachEvent event) {
if( jso == null ) jso = create(parameters);
}
});
}
开发者ID:CSTARS,项目名称:gwt-esri,代码行数:23,代码来源:Editor.java
示例13: Legend
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Creates a new Legend dijit. Should be called after all the layers have been loaded in the map,
* typically in the map's onLayerAddResult event.
*
* @param params - Parameters used to configure the dijit. See the list below for details.
*/
public Legend(Parameters params) {
if( !assertLoaded() ) return;
parameters = params;
initWidget(panel);
addAttachHandler(new Handler(){
@Override
public void onAttachOrDetach(AttachEvent event) {
if( jso == null ) jso = create(parameters);
}
});
}
开发者ID:CSTARS,项目名称:gwt-esri,代码行数:23,代码来源:Legend.java
示例14: TemplatePicker
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Creates a new TemplatePicker object that displays a gallery of templates
* from the input feature layers or items. A symbol and label is displayed
* for each template. The symbol is defined by the template's feature type.
* The label is the template's name.
*
* @param params - FeatureLayers or items are required all other parameters
* are optional. See options list.
*/
public TemplatePicker(Parameters params) {
if( !assertLoaded() ) return;
parameters = params;
initWidget(panel);
addAttachHandler(new Handler(){
@Override
public void onAttachOrDetach(AttachEvent event) {
if( jso == null ) jso = create(parameters);
}
});
}
开发者ID:CSTARS,项目名称:gwt-esri,代码行数:26,代码来源:TemplatePicker.java
示例15: BasemapGallery
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Creates a new BasemapGallery dijit.
*
* @param params - Parameters used to configure the widgit. See the list below for details.
*/
public BasemapGallery(Parameters params) {
if( !assertLoaded() ) return;
initWidget(panel);
parameters = params;
addAttachHandler(new Handler(){
@Override
public void onAttachOrDetach(AttachEvent event) {
if( jso == null ) jso = create(parameters);
}
});
}
开发者ID:CSTARS,项目名称:gwt-esri,代码行数:22,代码来源:BasemapGallery.java
示例16: CodeMirror
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
public CodeMirror(final CodeMirrorConfig config){
setElement(DOM.createDiv());
addAttachHandler(new Handler() {
public void onAttachOrDetach(AttachEvent event) {
if(event.isAttached()){
cm=create(getElement(), config.toJsObject(CodeMirror.this));
}
}
});
sinkEvents(Event.MOUSEEVENTS|Event.ONCLICK);
}
开发者ID:ctripcorp,项目名称:dataworks-zeus,代码行数:12,代码来源:CodeMirror.java
示例17: createInfoPanel
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Creates the action buttons.
* @param situationSummaryBean
*/
private Widget createInfoPanel(SituationSummaryBean situationSummaryBean) {
FlowPanel infoPanel = new FlowPanel();
infoPanel.getElement().setClassName(""); //$NON-NLS-1$
if (!situationSummaryBean.getProperties().isEmpty()) {
final Anchor properties = new Anchor();
properties.setHref("#"); //$NON-NLS-1$
properties.getElement().setAttribute("data-toggle", "popover"); //$NON-NLS-1$ //$NON-NLS-2$
properties.getElement().setAttribute("data-placement", "left"); //$NON-NLS-1$ //$NON-NLS-2$
properties.getElement().setAttribute("data-html", "true"); //$NON-NLS-1$ //$NON-NLS-2$
properties.getElement().setAttribute("data-original-title", i18n.format("situation-table.properties")); //$NON-NLS-1$ //$NON-NLS-2$
properties.getElement().setAttribute("data-trigger", "hover"); //$NON-NLS-1$ //$NON-NLS-2$
properties.getElement().setAttribute("data-content", createPropertiesTableHtml(situationSummaryBean.getProperties())); //$NON-NLS-1$
properties.setHTML("<div class=\"icon icon-properties\"></div>"); //$NON-NLS-1$
properties.addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (event.isAttached()) {
Element element2 = properties.getElement();
activatePopover(element2);
}
}
});
infoPanel.add(properties);
}
// infoPanel.add(downloadInitialActionButton);
// infoPanel.add(retryActionButton);
return infoPanel;
}
开发者ID:Governance,项目名称:rtgov-ui,代码行数:35,代码来源:SituationTable.java
示例18: SourceEditor
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Constructor.
*/
public SourceEditor() {
setElement(Document.get().createDivElement());
addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (event.isAttached()) {
initEditor();
} else {
destroyEditor();
}
}
});
}
开发者ID:Governance,项目名称:rtgov-ui,代码行数:17,代码来源:SourceEditor.java
示例19: initMouseInOutWidget
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Initializes the given widget by hooking up mouse-in/mouse-out
* handlers.
* @param widget
*/
public static void initMouseInOutWidget(final IMouseInOutWidget widget) {
widget.addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (event.isAttached()) {
addMouseHandlers(widget);
} else {
removeMouseHandlers(widget);
}
}
});
}
开发者ID:Governance,项目名称:rtgov-ui,代码行数:18,代码来源:WidgetUtil.java
示例20: postContruct
import com.google.gwt.event.logical.shared.AttachEvent.Handler; //导入依赖的package包/类
/**
* Called after construction.
*/
@PostConstruct
protected void postContruct() {
addAttachHandler(new Handler() {
@Override
public void onAttachOrDetach(AttachEvent event) {
if (event.isAttached()) {
doAttachInit();
}
}
});
}
开发者ID:Governance,项目名称:overlord-commons,代码行数:15,代码来源:TemplatedWidgetTable.java
注:本文中的com.google.gwt.event.logical.shared.AttachEvent.Handler类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论