?? actionsetlinkend.java
字號:
package com.zhtelecom.common.topograph.example.menuaction;
import java.awt.event.ActionEvent;
import javax.swing.AbstractAction;
import com.zhtelecom.common.topograph.TopoGraphView;
import com.zhtelecom.common.topograph.TopoLink;
import com.zhtelecom.common.topograph.example.NMSExample;
public class ActionSetLinkEnd extends AbstractAction
{
public void actionPerformed(ActionEvent e)
{
TopoGraphView topoView = (TopoGraphView) getValue("topoGraphView");
topoView.setLinkTarget(topoView.getSelectedNode());
if (topoView.getLinkSource() != null && topoView.getLinkTarget() != null)
{
TopoLink link = new TopoLink(new StringBuffer("link+" +
NMSExample.getNum()), topoView.getLinkSource(),
topoView.getLinkTarget());
topoView.getTopoDataSource().addTopoData(link,
topoView.getCurrentNetwork());
topoView.clearLinkMarked();
}
}
public ActionSetLinkEnd()
{
super("設置連接終點");
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -