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


Java EventSourceWeakSupport类代码示例

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


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

示例1: clone

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
@Override
public CanvasObject clone() {
	try {
		AbstractCanvasObject ret = (AbstractCanvasObject) super.clone();
		ret.listeners = new EventSourceWeakSupport<AttributeListener>();
		return ret;
	} catch (CloneNotSupportedException e) {
		return null;
	}
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:11,代码来源:AbstractCanvasObject.java

示例2: clone

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
@Override
public Object clone() {
	try {
		DrawingAttributeSet ret = (DrawingAttributeSet) super.clone();
		ret.listeners = new EventSourceWeakSupport<AttributeListener>();
		ret.values = new ArrayList<Object>(this.values);
		return ret;
	} catch (CloneNotSupportedException e) {
		return null;
	}
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:12,代码来源:DrawingAttributeSet.java

示例3: addComponentListener

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
@Override
public void addComponentListener(ComponentListener l) {
	EventSourceWeakSupport<ComponentListener> ls = listeners;
	if (ls == null) {
		ls = new EventSourceWeakSupport<ComponentListener>();
		ls.add(l);
		listeners = ls;
	} else {
		ls.add(l);
	}
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:12,代码来源:InstanceComponent.java

示例4: LoadedLibrary

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
LoadedLibrary(Library base) {
	dirty = false;
	myListener = new MyListener();
	listeners = new EventSourceWeakSupport<LibraryListener>();

	while (base instanceof LoadedLibrary)
		base = ((LoadedLibrary) base).base;
	this.base = base;
	if (base instanceof LibraryEventSource) {
		((LibraryEventSource) base).addLibraryListener(myListener);
	}
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:13,代码来源:LoadedLibrary.java

示例5: CircuitAppearance

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
public CircuitAppearance(Circuit circuit) {
	this.circuit = circuit;
	listeners = new EventSourceWeakSupport<CircuitAppearanceListener>();
	portManager = new PortManager(this);
	circuitPins = new CircuitPins(portManager);
	myListener = new MyListener();
	suppressRecompute = false;
	addCanvasModelListener(myListener);
	setDefaultAppearance(true);
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:11,代码来源:CircuitAppearance.java

示例6: addHdlModelListener

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
@Override
public void addHdlModelListener(HdlModelListener l) {
	if (listeners == null) {
		listeners = new EventSourceWeakSupport<HdlModelListener>();
	}
	listeners.add(l);
}
 
开发者ID:reds-heig,项目名称:logisim-evolution,代码行数:8,代码来源:HdlContent.java

示例7: addComponentListener

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
public void addComponentListener(ComponentListener l) {
	EventSourceWeakSupport<ComponentListener> ls = listeners;
	if (ls == null) {
		ls = new EventSourceWeakSupport<ComponentListener>();
		ls.add(l);
		listeners = ls;
	} else {
		ls.add(l);
	}
}
 
开发者ID:reds-heig,项目名称:logisim-evolution,代码行数:11,代码来源:InstanceComponent.java

示例8: LoadedLibrary

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
LoadedLibrary(Library base) {
	dirty = false;
	myListener = new MyListener();
	listeners = new EventSourceWeakSupport<LibraryListener>();
	
	while (base instanceof LoadedLibrary) base = ((LoadedLibrary) base).base;
	this.base = base;
	if (base instanceof LibraryEventSource) {
		((LibraryEventSource) base).addLibraryListener(myListener);
	}
}
 
开发者ID:franciscaconcha,项目名称:ProyectoLogisim,代码行数:12,代码来源:LoadedLibrary.java

示例9: UndoLog

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
public UndoLog() {
	this.listeners = new EventSourceWeakSupport<UndoLogListener>();
	this.undoLog = new LinkedList<Action>();
	this.redoLog = new LinkedList<Action>();
	this.modCount = 0;
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:7,代码来源:UndoLog.java

示例10: Drawing

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
public Drawing() {
	listeners = new EventSourceWeakSupport<CanvasModelListener>();
	canvasObjects = new ArrayList<CanvasObject>();
	overlaps = new DrawingOverlaps();
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:6,代码来源:Drawing.java

示例11: AbstractCanvasObject

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
public AbstractCanvasObject() {
	listeners = new EventSourceWeakSupport<AttributeListener>();
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:4,代码来源:AbstractCanvasObject.java

示例12: DrawingAttributeSet

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
public DrawingAttributeSet() {
	listeners = new EventSourceWeakSupport<AttributeListener>();
	attrs = ATTRS_ALL;
	values = DEFAULTS_ALL;
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:6,代码来源:DrawingAttributeSet.java

示例13: addHexModelListener

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
@Override
public void addHexModelListener(HexModelListener l) {
	if (listeners == null)
		listeners = new EventSourceWeakSupport<HexModelListener>();
	listeners.add(l);
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:7,代码来源:MemContents.java

示例14: ToolbarData

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
public ToolbarData() {
	listeners = new EventSourceWeakSupport<ToolbarListener>();
	toolListeners = new EventSourceWeakSupport<AttributeListener>();
	contents = new ArrayList<Tool>();
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:6,代码来源:ToolbarData.java

示例15: Model

import com.cburch.logisim.util.EventSourceWeakSupport; //导入依赖的package包/类
public Model(CircuitState circuitState) {
	listeners = new EventSourceWeakSupport<ModelListener>();
	selection = new Selection(circuitState, this);
	log = new HashMap<SelectionItem, ValueLog>();
}
 
开发者ID:LogisimIt,项目名称:Logisim,代码行数:6,代码来源:Model.java


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