Package org.eclipse.core.commands.operations

Examples of org.eclipse.core.commands.operations.ObjectUndoContext


   * @return the workbench operation context.
   * @since 3.1
   */
  public IUndoContext getUndoContext() {
    if (undoContext == null) {
      undoContext = new ObjectUndoContext(PlatformUI.getWorkbench(),
          "Workbench Context"); //$NON-NLS-1$
    }
    return undoContext;
  }
View Full Code Here


    locked = false;
  }

  public VisualDesigner(VisualSwingEditor editor, Composite parent) {
    this.editor = editor;
    this.undoContext = new ObjectUndoContext(editor);
    this.parent = parent;

    this.clipboard = new ArrayList<WidgetAdapter>();
    this.selected = new ArrayList<WidgetAdapter>();
View Full Code Here

  private IUndoContext undoContext;
 
  private ArrayList<ISelectionChangedListener> listeners;
 
  public ShapeEditor() {
    undoContext = new ObjectUndoContext(this);
    listeners = new ArrayList<ISelectionChangedListener>();
    editControllers = new ArrayList<ControllerBase>();
   
    cursorCrosshair = new Cursor(getDisplay(), SWT.CURSOR_SIZEALL);
    cursorNormal = new Cursor(getDisplay(), SWT.CURSOR_ARROW);
View Full Code Here

   */
  public void connect(ITextViewer textViewer) {
    if (!isConnected() && textViewer != null) {
      fTextViewer= textViewer;
        if (fUndoContext == null)
            fUndoContext= new ObjectUndoContext(this);

        fHistory.setLimit(fUndoContext, fUndoLevel);

      initializeCommandStack();

View Full Code Here

  }

  public static IUndoContext getUndoContext(Object obj) {
    EOModel model = EOModelUtils.getRelatedModel(obj);
    String label = model == null ? "No Model" : model.getName();
    return new ObjectUndoContext(model, label);
  }
View Full Code Here

  public DocumentUndoManager(IDocument document) {
    super();
    Assert.isNotNull(document);
    fDocument= document;
    fHistory= OperationHistoryFactory.getOperationHistory();
    fUndoContext= new ObjectUndoContext(fDocument);
    fConnected= new ArrayList();
    fDocumentUndoListeners= new ListenerList(ListenerList.IDENTITY);
  }
View Full Code Here

    if (!isConnected() && textViewer != null) {
      fTextViewer= textViewer;
      fTextBuffer= new StringBuffer();
      fPreservedTextBuffer= new StringBuffer();
        if (fUndoContext == null)
            fUndoContext= new ObjectUndoContext(this);

        fHistory.setLimit(fUndoContext, fUndoLevel);

      initializeCommandStack();
View Full Code Here

TOP

Related Classes of org.eclipse.core.commands.operations.ObjectUndoContext

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.