summaryrefslogtreecommitdiffstats
path: root/ajde
diff options
context:
space:
mode:
authormkersten <mkersten>2003-08-08 14:30:56 +0000
committermkersten <mkersten>2003-08-08 14:30:56 +0000
commit07ec8f62517b23d08ae060875db3d86ae94d009d (patch)
tree1dc6a6e79e00cebab78f29980b5f8c298ce97aae /ajde
parentbf887f651e34b7e25a4a82d18267efaf57e0ffb6 (diff)
downloadaspectj-07ec8f62517b23d08ae060875db3d86ae94d009d.tar.gz
aspectj-07ec8f62517b23d08ae060875db3d86ae94d009d.zip
Fixed bad cast.
Diffstat (limited to 'ajde')
-rw-r--r--ajde/src/org/aspectj/ajde/ui/internal/TreeStructureViewBuilder.java33
-rw-r--r--ajde/src/org/aspectj/ajde/ui/swing/SwingTreeViewNodeRenderer.java10
2 files changed, 22 insertions, 21 deletions
diff --git a/ajde/src/org/aspectj/ajde/ui/internal/TreeStructureViewBuilder.java b/ajde/src/org/aspectj/ajde/ui/internal/TreeStructureViewBuilder.java
index 4473dc1e9..35417834a 100644
--- a/ajde/src/org/aspectj/ajde/ui/internal/TreeStructureViewBuilder.java
+++ b/ajde/src/org/aspectj/ajde/ui/internal/TreeStructureViewBuilder.java
@@ -113,14 +113,15 @@ public class TreeStructureViewBuilder {
node.setRunnable(false);
}
}
-// if (node.getChildren() != null) {
-// for (Iterator it = node.getChildren().iterator(); it.hasNext(); ) {
-// IProgramElement IProgramElement = (IProgramElement)it.next();
-// if (acceptNode(IProgramElement, properties)) {
-// children.add(createViewNode(IProgramElement, properties));
-// }
-// }
-// }
+ if (node.getChildren() != null) {
+ for (Iterator it = node.getChildren().iterator(); it.hasNext(); ) {
+ IProgramElement IProgramElement = (IProgramElement)it.next();
+ if (acceptNode(IProgramElement, properties)) {
+ children.add(createViewNode(IProgramElement, properties));
+ }
+ }
+ }
+
StructureViewNode viewNode = nodeFactory.createNode(node, children);//new TreeViewNode(root, null, children);
return viewNode;
}
@@ -178,9 +179,9 @@ public class TreeStructureViewBuilder {
}
}
}
- } else if (node instanceof IRelationship) {
- IRelationship relation = (IRelationship)node;
- return properties.getRelations().contains(relation);
+// } else if (node instanceof IRelationship) {
+// IRelationship relation = (IRelationship)node;
+// return properties.getRelations().contains(relation);
} else {
return true;
}
@@ -355,11 +356,11 @@ public class TreeStructureViewBuilder {
private StructureViewNode getRelations(IRelationship node) {
//StructureViewNode treeNode = new StructureViewNode(node);
StructureViewNode treeNode = nodeFactory.createNode(node);
- for (Iterator it = node.getTargets().iterator(); it.hasNext(); ) {
- treeNode.add(
- nodeFactory.createNode((IProgramElement)it.next())
- );
- }
+// for (Iterator it = node.getTargets().iterator(); it.hasNext(); ) {
+// treeNode.add(
+// nodeFactory.createNode((IProgramElement)it.next())
+// );
+// }
return treeNode;
}
diff --git a/ajde/src/org/aspectj/ajde/ui/swing/SwingTreeViewNodeRenderer.java b/ajde/src/org/aspectj/ajde/ui/swing/SwingTreeViewNodeRenderer.java
index 9f19770b4..907843544 100644
--- a/ajde/src/org/aspectj/ajde/ui/swing/SwingTreeViewNodeRenderer.java
+++ b/ajde/src/org/aspectj/ajde/ui/swing/SwingTreeViewNodeRenderer.java
@@ -58,7 +58,7 @@ class SwingTreeViewNodeRenderer extends DefaultTreeCellRenderer {
} else {
setIcon(null);
}
-
+
if (node instanceof IProgramElement) {
// if (pNode.isRunnable()) {
// //setIcon(AjdeUIManager.getDefault().getIconRegistry().getExecuteIcon());
@@ -79,10 +79,10 @@ class SwingTreeViewNodeRenderer extends DefaultTreeCellRenderer {
}
}
- } else if (node instanceof IRelationship) {
- this.setFont(new Font(this.getFont().getName(), Font.ITALIC, this.getFont().getSize()));
- }
-
+ }
+// else if (node instanceof IRelationship) {
+// this.setFont(new Font(this.getFont().getName(), Font.ITALIC, this.getFont().getSize()));
+// }
return this;
}
}