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


Java ActionEvent.getWhen方法代码示例

本文整理汇总了Java中java.awt.event.ActionEvent.getWhen方法的典型用法代码示例。如果您正苦于以下问题:Java ActionEvent.getWhen方法的具体用法?Java ActionEvent.getWhen怎么用?Java ActionEvent.getWhen使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在java.awt.event.ActionEvent的用法示例。


在下文中一共展示了ActionEvent.getWhen方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: actionPerformed

import java.awt.event.ActionEvent; //导入方法依赖的package包/类
@Override
public void actionPerformed( ActionEvent e ) {
    nd.setValue(option);

    if (buttonListener != null) {
        // #34485: some listeners expect that the action source is the option, not the button
        ActionEvent e2 = new ActionEvent(
                option, e.getID(), e.getActionCommand(), e.getWhen(), e.getModifiers()
            );
        buttonListener.actionPerformed(e2);
    }

    if ((closingOptions == null) || Arrays.asList(closingOptions).contains(option)) {
        haveFinalValue = true;
        setVisible(false);
    }
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:18,代码来源:DialogDisplayer.java

示例2: actionPerformed

import java.awt.event.ActionEvent; //导入方法依赖的package包/类
@Override final public void actionPerformed(ActionEvent objPactionEvent) {

		Tools.debug("FiltersJDialog.actionPerformed()");
		if (super.isActionPerformed(objPactionEvent)) {
			this.setAble();
			this.objGactivateJButton.setToolTipText();
			this.objGdeactivateJButton.setToolTipText();
			this.objGclearJButton.setToolTipText();
			this.objGcloseJButton.setToolTipText();
		} else {

			final long lngLtimeStamp = objPactionEvent.getWhen();
			if (lngLtimeStamp > this.lngGlastActionTimestamp) {
				this.lngGlastActionTimestamp = lngLtimeStamp;

				// Update combobox values :
				this.objGpatternsJComboBox.doAddCurrentItem();
				if (super.getSequenceAble(true) == Boolean.TRUE) {
					this.objGsynchroSequencesJComboBox.doAddCurrentItem();
				}
				if (super.getSequenceAble(false) == Boolean.TRUE) {
					this.objGasynchroSequencesJComboBox.doAddCurrentItem();
				}
				this.objGstylesJComboBox.doAddCurrentItem();

				final Object objLsource = objPactionEvent.getSource();
				if (objLsource == this.objGactivateJButton) {
					this.doFilter();
				} else if (objLsource == this.objGdeactivateJButton) {
					this.doUnfilter();
				} else if (objLsource == this.objGclearJButton) {
					this.doClearFields();
				} else if (objLsource == this.objGcloseJButton) {
					this.setVisible(false);
				}
			}
		}
	}
 
开发者ID:jugglemaster,项目名称:JuggleMasterPro,代码行数:39,代码来源:FiltersJDialog.java

示例3: actionPerformed

import java.awt.event.ActionEvent; //导入方法依赖的package包/类
@Override
public void actionPerformed(ActionEvent event) {
	if (!listeners.isEmpty()) {
		ActionEvent e = new ActionEvent(menuItem, event.getID(), event.getActionCommand(), event.getWhen(),
				event.getModifiers());
		for (ActionListener l : listeners) {
			l.actionPerformed(e);
		}
	}
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:11,代码来源:MenuItemHelper.java

示例4: actionPerformed

import java.awt.event.ActionEvent; //导入方法依赖的package包/类
public void actionPerformed(ActionEvent e) {
    ActionEvent event = new ActionEvent(source, e.getID(), e.getActionCommand(), e.getWhen(), e.getModifiers());
    scrollAction.actionPerformed(event);
}
 
开发者ID:apache,项目名称:incubator-netbeans,代码行数:5,代码来源:SourceTranslatorAction.java

示例5: actionPerformed

import java.awt.event.ActionEvent; //导入方法依赖的package包/类
@Override final public void actionPerformed(ActionEvent objPactionEvent) {

		Tools.debug("FindJDialog.actionPerformed()");
		if (super.isActionPerformed(objPactionEvent)) {
			this.setAble();
			this.objGpreviousJButton.setToolTipText();
			this.objGnextJButton.setToolTipText();
		} else {
			final long lngLtimeStamp = objPactionEvent.getWhen();
			if (lngLtimeStamp > this.lngGlastActionTimestamp) {
				this.lngGlastActionTimestamp = lngLtimeStamp;
				final Object objLsource = objPactionEvent.getSource();
				if (objLsource == this.objGcancelJButton) {
					super.objGpatternsJComboBox.setSelectedIndex(Constants.bytS_UNCLASS_NO_VALUE);
					super.objGasynchroSequencesJComboBox.setSelectedIndex(Constants.bytS_UNCLASS_NO_VALUE);
					super.objGsynchroSequencesJComboBox.setSelectedIndex(Constants.bytS_UNCLASS_NO_VALUE);
					super.objGstylesJComboBox.setSelectedIndex(Constants.bytS_UNCLASS_NO_VALUE);
					this.setVisible(false);
					return;
				}

				// Update combobox values :
				this.objGpatternsJComboBox.doAddCurrentItem();
				if (super.getSequenceAble(true) == Boolean.TRUE) {
					super.objGsynchroSequencesJComboBox.doAddCurrentItem();
				}
				if (super.getSequenceAble(false) == Boolean.TRUE) {
					super.objGasynchroSequencesJComboBox.doAddCurrentItem();
				}
				super.objGstylesJComboBox.doAddCurrentItem();

				Tools.out("Informations de FindJDialog :");
				Tools.out(this.getInfo());
				if (objLsource == this.objGnextJButton || objLsource == this.objGpreviousJButton) {
					this.doFind(objLsource == this.objGnextJButton);
				}

				if (objLsource == this.objGcloseJButton) {
					this.setVisible(false);
				}
			}
		}
	}
 
开发者ID:jugglemaster,项目名称:JuggleMasterPro,代码行数:44,代码来源:FindJDialog.java


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