Package net.sf.jabref.undo

Examples of net.sf.jabref.undo.UndoableStringChange


                     +"is already in use.");
    }

    if (string != null) {
      string.setName(disk);
      undoEdit.addEdit(new UndoableStringChange(panel, string, true, mem,
                                                disk));
    } else {
      // The string was removed or renamed locally. We guess that it was removed.
  String newId = Util.createNeutralId();
  BibtexString bs = new BibtexString(newId, disk, content);
View Full Code Here


  }

  public boolean makeChange(BasePanel panel, BibtexDatabase secondary, NamedCompound undoEdit) {
    if (string != null) {
      string.setContent(disk);
      undoEdit.addEdit(new UndoableStringChange(panel, string, false, mem, disk));
        // Update tmp databse:

    } else {
      // The string was removed or renamed locally. We guess that it was removed.
  String newId = Util.createNeutralId();
View Full Code Here

        }
        else {
      // Store undo information.
      BibtexString subject = (BibtexString)strings[row];
      panel.undoManager.addEdit
          (new UndoableStringChange
           (panel, subject, true,
            subject.getName(), (String)value));
      subject.setName((String)value);
      panel.markBaseChanged();
      refreshTable();
        }
    }
      } else {
    // Change content of string.
    BibtexString subject = (BibtexString)strings[row];

    if (!((String)value).equals(subject.getContent())) {
                    try {
                        (new LatexFieldFormatter()).format((String)value, "__dummy");
                    } catch (IllegalArgumentException ex) {
                        return;
                    }
        // Store undo information.
        panel.undoManager.addEdit
      (new UndoableStringChange
       (panel, subject, false,
        subject.getContent(), (String)value));

        subject.setContent((String)value);
        panel.markBaseChanged();
View Full Code Here

TOP

Related Classes of net.sf.jabref.undo.UndoableStringChange

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.