blob: 6b81f98df2fcd06a969371d33de5c921e5ac01f4 [file] [log] [blame]
/*******************************************************************************
* Copyright (c) 2000, 2017 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
* which accompanies this distribution, and is available at
* https://www.eclipse.org/legal/epl-2.0/
*
* SPDX-License-Identifier: EPL-2.0
*
* Contributors:
* IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.team.ui;
import org.eclipse.compare.CompareEditorInput;
import org.eclipse.compare.CompareUI;
import org.eclipse.ui.IPropertyListener;
import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.IWorkbenchPartSite;
/**
* This adapter provides default implementations for methods on {@link ISaveableWorkbenchPart} and
* {@link IWorkbenchPart}.
* <p>
* Classes that want to implement a saveable part can simply implement the methods that
* they need while accepting the provided defaults for most of the methods.
* </p>
* @see SaveablePartDialog
* @since 3.0
* @deprecated Clients should use a subclass of {@link CompareEditorInput}
* and {@link CompareUI#openCompareDialog(org.eclipse.compare.CompareEditorInput)}
*/
@Deprecated
public abstract class SaveablePartAdapter implements ISaveableWorkbenchPart {
@Override
public void doSaveAs() {
}
@Override
public boolean isSaveAsAllowed() {
return false;
}
@Override
public boolean isSaveOnCloseNeeded() {
return false;
}
@Override
public void addPropertyListener(IPropertyListener listener) {
}
@Override
public void dispose() {
}
@Override
public IWorkbenchPartSite getSite() {
return null;
}
@Override
public String getTitleToolTip() {
return null;
}
@Override
public void removePropertyListener(IPropertyListener listener) {
}
@Override
public void setFocus() {
}
@Override
public <T> T getAdapter(Class<T> adapter) {
return null;
}
}