Examples of canRedo()


Examples of javax.swing.undo.UndoableEdit.canRedo()

        assertEquals(undoName, undoable.getUndoPresentationName());
        assertTrue(undoable.isSignificant());
        assertFalse(undoable.canRedo());
        assertTrue(undoable.canUndo());
        undoable.undo();
        assertTrue(undoable.canRedo());
        assertFalse(undoable.canUndo());
        undoable.redo();
        assertFalse(undoable.canRedo());
        assertTrue(undoable.canUndo());
        assertFalse(undoable.addEdit(null));
View Full Code Here

Examples of javax.swing.undo.UndoableEdit.canRedo()

        assertTrue(undoable.canUndo());
        undoable.undo();
        assertTrue(undoable.canRedo());
        assertFalse(undoable.canUndo());
        undoable.redo();
        assertFalse(undoable.canRedo());
        assertTrue(undoable.canUndo());
        assertFalse(undoable.addEdit(null));
        assertFalse(undoable.addEdit(undoable));
    }
View Full Code Here

Examples of javax.swing.undo.UndoableEdit.canRedo()

   * operation would be successful now for the given view, false otherwise
   */
  public synchronized boolean canRedo(Object source) {
    if (isInProgress()) {
      UndoableEdit edit = editToBeRedone(source);
      return edit != null && edit.canRedo();
    } else {
      return super.canRedo();
    }
  }

View Full Code Here

Examples of org.eclipse.core.commands.operations.IUndoableOperation.canRedo()

    for (final Iterator it = _stepOperations.iterator(); it.hasNext();)
    {
      IUndoableOperation op = (IUndoableOperation) it.next();
     
      // fail fast
      if (!op.canRedo())
      {
        return false;
      }
    }
   
View Full Code Here

Examples of org.eclipse.core.commands.operations.IUndoableOperation.canRedo()

    for (final Iterator it = _stepOperations.iterator(); it.hasNext();)
    {
      IUndoableOperation op = (IUndoableOperation) it.next();
     
      // fail fast
      if (!op.canRedo())
      {
        return false;
      }
    }
   
View Full Code Here

Examples of org.eclipse.emf.common.command.CommandStack.canRedo()

  ContactsManager contactsManager;

  @CanExecute
  public boolean canUndo() {
    CommandStack commandStack = contactsManager.getEditingDomain().getCommandStack();
    return commandStack.canRedo();
  }

  @Execute
  public void undo() {
    CommandStack commandStack = contactsManager.getEditingDomain().getCommandStack();
View Full Code Here

Examples of org.enhydra.jawe.UndoHistoryManager.canRedo()

    }

    public void enableDisableAction() {
        JaWEController jc = JaWEManager.getInstance().getJaWEController();
        UndoHistoryManager um = jc.getUndoHistoryManager();
        setEnabled(um.canRedo());
    }

    public void actionPerformed(ActionEvent e) {
        JaWEController jc = JaWEManager.getInstance().getJaWEController();
        jc.redo();
View Full Code Here

Examples of org.evolizer.daforjava.commands.CommandController.canRedo()

        commandController.undoCommand();
        Assert.assertEquals("Graph must not contain nodes after undo", 0, fGraphPanel.getGraph().nodeCount());
        Assert.assertEquals("Graph must not contain edges after undo", 0, fGraphPanel.getGraph().edgeCount());
        Assert.assertEquals("There should be no more command to be undone", false, commandController.canUndo());
       
        Assert.assertEquals("Command controller must be able to redo the last command ", true, commandController.canRedo());
        commandController.redoCommand();
        Assert.assertEquals("There should be no more command to be redone", false, commandController.canRedo());
       
        checkClassPlanet();
    }
View Full Code Here

Examples of org.evolizer.daforjava.commands.CommandController.canRedo()

        Assert.assertEquals("Graph must not contain edges after undo", 0, fGraphPanel.getGraph().edgeCount());
        Assert.assertEquals("There should be no more command to be undone", false, commandController.canUndo());
       
        Assert.assertEquals("Command controller must be able to redo the last command ", true, commandController.canRedo());
        commandController.redoCommand();
        Assert.assertEquals("There should be no more command to be redone", false, commandController.canRedo());
       
        checkClassPlanet();
    }
   
    @Test
View Full Code Here

Examples of org.evolizer.daforjava.commands.CommandController.canRedo()

        if (evt.getPropertyName().equals(CommandController.COMMAND_EXECUTED)
                || evt.getPropertyName().equals(CommandController.COMMAND_UNDONE)
                || evt.getPropertyName().equals(CommandController.COMMAND_REDONE)) {

            CommandController controller = (CommandController) evt.getSource();
            if (!controller.canRedo()) {
                fRedoButton.setEnabled(false);
            } else {
                fRedoButton.setEnabled(true);
            }
            if (!controller.canUndo()) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.