Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Gvozdev2011-03-15 18:24:14 -0400
committerAndrew Gvozdev2011-03-15 18:24:14 -0400
commit74d6ab99d96bae9c6e674216a6342180080c438e (patch)
tree2c983cd3dde13eb252155cccd65453cfa1405f5e
parentff5997789df7fc72590cdd5138b62901e597e170 (diff)
downloadorg.eclipse.cdt-74d6ab99d96bae9c6e674216a6342180080c438e.tar.gz
org.eclipse.cdt-74d6ab99d96bae9c6e674216a6342180080c438e.tar.xz
org.eclipse.cdt-74d6ab99d96bae9c6e674216a6342180080c438e.zip
compilation warnings
-rw-r--r--build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/MakefileContentOutlinePage.java8
-rw-r--r--build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/OpenIncludeAction.java9
2 files changed, 8 insertions, 9 deletions
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/MakefileContentOutlinePage.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/MakefileContentOutlinePage.java
index 77b943976c..020677b4b4 100644
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/MakefileContentOutlinePage.java
+++ b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/MakefileContentOutlinePage.java
@@ -37,7 +37,6 @@ import org.eclipse.jface.action.MenuManager;
import org.eclipse.jface.action.Separator;
import org.eclipse.jface.viewers.DoubleClickEvent;
import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.ITreeContentProvider;
import org.eclipse.jface.viewers.LabelProvider;
import org.eclipse.jface.viewers.TreeViewer;
@@ -51,12 +50,11 @@ import org.eclipse.ui.IEditorInput;
import org.eclipse.ui.IWorkbenchActionConstants;
import org.eclipse.ui.part.IPageSite;
import org.eclipse.ui.views.contentoutline.ContentOutlinePage;
-import org.eclipse.ui.views.contentoutline.IContentOutlinePage;
/**
* MakefileContentOutlinePage
*/
-public class MakefileContentOutlinePage extends ContentOutlinePage implements IContentOutlinePage {
+public class MakefileContentOutlinePage extends ContentOutlinePage {
private class MakefileContentProvider implements ITreeContentProvider {
@@ -126,7 +124,7 @@ public class MakefileContentOutlinePage extends ContentOutlinePage implements IC
} else {
directives = new IDirective[0];
}
- List list = new ArrayList(directives.length);
+ List<IDirective> list = new ArrayList<IDirective>(directives.length);
for (int i = 0; i < directives.length; i++) {
if (showMacroDefinition && directives[i] instanceof IMacroDefinition) {
list.add(directives[i]);
@@ -171,7 +169,7 @@ public class MakefileContentOutlinePage extends ContentOutlinePage implements IC
}
- private class MakefileLabelProvider extends LabelProvider implements ILabelProvider {
+ private class MakefileLabelProvider extends LabelProvider {
/* (non-Javadoc)
* @see org.eclipse.jface.viewers.ILabelProvider#getImage(java.lang.Object)
diff --git a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/OpenIncludeAction.java b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/OpenIncludeAction.java
index 91842c0981..fd2ad619d6 100644
--- a/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/OpenIncludeAction.java
+++ b/build/org.eclipse.cdt.make.ui/src/org/eclipse/cdt/make/internal/ui/editor/OpenIncludeAction.java
@@ -107,16 +107,17 @@ public class OpenIncludeAction extends Action {
IInclude[] getIncludeDirective(ISelection sel) {
if (!sel.isEmpty() && sel instanceof IStructuredSelection) {
- List list= ((IStructuredSelection)sel).toList();
+ @SuppressWarnings("unchecked")
+ List<Object> list= ((IStructuredSelection)sel).toList();
if (list.size() > 0) {
- List includes = new ArrayList(list.size());
+ List<IInclude> includes = new ArrayList<IInclude>(list.size());
for (int i = 0; i < list.size(); ++i) {
Object element= list.get(i);
if (element instanceof IInclude) {
- includes.add(element);
+ includes.add((IInclude) element);
}
}
- return (IInclude[]) includes.toArray(new IInclude[includes.size()]);
+ return includes.toArray(new IInclude[includes.size()]);
}
}
return null;

Back to the top