Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
<copyright> Copyright (c) 2005, 2007 IBM Corporation and others. All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html Contributors: IBM - Initial API and implementation </copyright> $Id: UndoActionWrapper.java,v 1.4 2007/11/14 18:14:04 cdamus Exp $
 
 
 package org.eclipse.emf.workspace.ui.actions;
 
 import  org.eclipse.swt.widgets.Event;
Extension of the EMF UndoAction class that delegates undo behaviour to the undoable operation framework's UndoActionHandler.

Author(s):
Christian W. Damus (cdamus)
 
 public class UndoActionWrapper extends UndoAction {
Initializes me.
 
 	public UndoActionWrapper() {
 		
 			public void firePropertyChange(String propertyObject oldValue,
 					Object newValue) {
 				firePropertyChange0(propertyoldValuenewValue);
 			}
 		
 					IWorkbenchPartSite siteIUndoContext context) {
 				return new UndoActionHandler(sitecontext);
 			}});
 	}
 
 	// method defined to give the inner listener class access to inherited protected method
 	void firePropertyChange0(String propertyObject oldValueObject newValue) {
 		firePropertyChange(propertyoldValuenewValue);
 	}

Extends the superclass implementation to update the operation history undo action handler to which I delegate.
 
 	public void setActiveWorkbenchPart(IWorkbenchPart workbenchPart) {
 		super.setActiveWorkbenchPart(workbenchPart);
 	}

Delegates to the operation framework action handler.
 
 	public void update() {
 		if ( != null) {
 		}
 	}

Delegates to the operation framework action handler.
 
 	public String getDescription() {
 		if ( != null) {
 		} else {
 			return null;
 		}
 	}

Delegates to the operation framework action handler.
 
 	public String getText() {
 		if ( != null) {
 			return .getText();
 		} else {
 			return null;
		}
	}

Delegates to the operation framework action handler.
	public String getToolTipText() {
		if ( != null) {
else {
			return null;
		}
	}

Delegates to the operation framework action handler.
	public boolean isEnabled() {
		if ( != null) {
else {
			return false;
		}
	}

Delegates to the operation framework action handler.
	public boolean isHandled() {
		if ( != null) {
else {
			return false;
		}
	}

Delegates to the operation framework action handler.
	public void run() {
		if ( != null) {
		}
	}

Delegates to the operation framework action handler.
	public void runWithEvent(Event event) {
		if ( != null) {
		}
	}

Delegates to the operation framework action handler.
	public void setChecked(boolean checked) {
		if ( != null) {
		}
	}

Delegates to the operation framework action handler.
	public void setDescription(String text) {
		if ( != null) {
		}
	}

Delegates to the operation framework action handler.
	public void setEnabled(boolean enabled) {
		if ( != null) {
		}
	}

Delegates to the operation framework action handler.
	public void setText(String text) {
		if ( != null) {
		}
	}

Delegates to the operation framework action handler.
	public void setToolTipText(String toolTipText) {
		if ( != null) {
		}
	}
New to GrepCode? Check out our FAQ X