Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/CVSHistoryPage.java')
-rw-r--r--bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/CVSHistoryPage.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/CVSHistoryPage.java b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/CVSHistoryPage.java
index 7808d2645..55d7b0535 100644
--- a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/CVSHistoryPage.java
+++ b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/CVSHistoryPage.java
@@ -318,11 +318,11 @@ public class CVSHistoryPage extends HistoryPage implements IAdaptable, IHistoryC
protected Map getHyperlinkDetectorTargets(ISourceViewer sourceViewer) {
return Collections.singletonMap("org.eclipse.ui.DefaultTextEditor", //$NON-NLS-1$
new IAdaptable() {
- public Object getAdapter(Class adapter) {
+ public <T> T getAdapter(Class<T> adapter) {
if(adapter==IFile.class && getInput() instanceof IFile) {
- return getInput();
+ return adapter.cast(getInput());
} else if(adapter==IFileHistory.class && getInput() instanceof IFileHistory) {
- return getInput();
+ return adapter.cast(getInput());
}
return Platform.getAdapterManager().getAdapter(CVSHistoryPage.this, adapter);
}
@@ -1825,9 +1825,9 @@ public class CVSHistoryPage extends HistoryPage implements IAdaptable, IHistoryC
return null;
}
- public Object getAdapter(Class adapter) {
+ public <T> T getAdapter(Class<T> adapter) {
if(adapter == IHistoryCompareAdapter.class) {
- return this;
+ return adapter.cast(this);
}
return null;
}

Back to the top