Package com.cburch.logisim.proj

Examples of com.cburch.logisim.proj.Project


    proj.doAction(SelectionActions.copy(sel));
  }
 
  @Override
  public void paste() {
    Project proj = frame.getProject();
    Selection sel = frame.getCanvas().getSelection();
    selectSelectTool(proj);
    Action action = SelectionActions.pasteMaybe(proj, sel);
    if (action != null) {
      proj.doAction(action);
    }
  }
View Full Code Here


    }
  }
 
  @Override
  public void delete() {
    Project proj = frame.getProject();
    Selection sel = frame.getCanvas().getSelection();
    proj.doAction(SelectionActions.clear(sel));
  }
View Full Code Here

    proj.doAction(SelectionActions.clear(sel));
  }
 
  @Override
  public void duplicate() {
    Project proj = frame.getProject();
    Selection sel = frame.getCanvas().getSelection();
    proj.doAction(SelectionActions.duplicate(sel));
  }
View Full Code Here

    proj.doAction(SelectionActions.duplicate(sel));
  }

  @Override
  public void selectAll() {
    Project proj = frame.getProject();
    Selection sel = frame.getCanvas().getSelection();
    selectSelectTool(proj);
    Circuit circ = proj.getCurrentCircuit();
    sel.addAll(circ.getWires());
    sel.addAll(circ.getNonWires());
    proj.repaintCanvas();
  }
View Full Code Here

    int x = e.getX();
    int y = e.getY();
    Location pt = Location.create(x, y);

    JPopupMenu menu;
    Project proj = canvas.getProject();
    Selection sel = proj.getSelection();
    Collection<Component> in_sel = sel.getComponentsContaining(pt, g);
    if (!in_sel.isEmpty()) {
      Component comp = in_sel.iterator().next();
      if (sel.getComponents().size() > 1) {
        menu = new MenuSelection(proj);
View Full Code Here

    }

    @Override
    public java.awt.Component getCellEditor(Window source, MemContents value) {
      if (source instanceof Frame) {
        Project proj = ((Frame) source).getProject();
        RomAttributes.register(value, proj);
      }
      ContentsCell ret = new ContentsCell(source, value);
      ret.mouseClicked(null);
      return ret;
View Full Code Here

      addMouseListener(this);
    }

    public void mouseClicked(MouseEvent e) {
      if (contents == null) return;
      Project proj = source instanceof Frame ? ((Frame) source).getProject() : null;
      HexFrame frame = RomAttributes.getHexFrame(contents, proj);
      frame.setVisible(true);
      frame.toFront();
    }
View Full Code Here

      initValue = data.getContents().get(data.getCursor());
      curValue = initValue;
     
      Object attrs = state.getInstance().getAttributeSet();
      if (attrs instanceof RomAttributes) {
        Project proj = state.getProject();
        if (proj != null) {
          ((RomAttributes) attrs).setProject(proj);
        }
      }
    }
View Full Code Here

    }
  }
 
  @Override
  public boolean isReadOnly(Attribute<?> attr) {
    Project proj = canvas.getProject();
    Circuit circ = canvas.getCircuit();
    if (!proj.getLogisimFile().contains(circ)) {
      return true;
    } else if (selected.isEmpty() && circ != null) {
      return circ.getStaticAttributes().isReadOnly(attr);
    } else {
      int i = findIndex(attr);
View Full Code Here

      menubar.addActionListener(LogisimMenuBar.PRINT, this);
    }
   
    public void actionPerformed(ActionEvent event) {
      Object src = event.getSource();
      Project proj = frame.getProject();
      if (src == LogisimMenuBar.EXPORT_IMAGE) {
        ExportImage.doExport(proj);
      } else if (src == LogisimMenuBar.PRINT) {
        Print.doPrint(proj);
      }
View Full Code Here

TOP

Related Classes of com.cburch.logisim.proj.Project

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.