コード例 #1
0
  public void actionPerformed(ActionEvent ae) {
    ProjectBrowser pb = ProjectBrowser.TheInstance;
    Project p = pb.getProject();
    Object target = pb.getDetailsTarget();
    if (!(target instanceof MClassifier)) return;
    MClassifier cls = (MClassifier) target;

    MAttribute attr = MMUtil.SINGLETON.buildAttribute(cls);
    super.actionPerformed(ae);
  }
コード例 #2
0
    public CopyAction(UMLDeploymentDiagram d) {

      super(MComponentInstanceImpl.class, d.getName());
      diagram = d;
      ProjectBrowser pb = ProjectBrowser.TheInstance;
      Object target = pb.getDetailsTarget();
      if (target instanceof MClass) {
        orig = (MClass) target;

        System.err.println("--------------------------------" + target.getClass());
      }
    }
コード例 #3
0
 public boolean shouldBeEnabled() {
   ProjectBrowser pb = ProjectBrowser.TheInstance;
   Object target = pb.getDetailsTarget();
   return super.shouldBeEnabled() && target instanceof MClassifier;
 }
コード例 #4
0
 public void doIt() {
   ProjectBrowser pb = ProjectBrowser.TheInstance;
   pb.setTarget(diagram);
   super.doIt();
 }