Skip to content

Commit 157c760

Browse files
committed
[GEF] Remove duplicate removeChild(EditPart) method
The `removeChild(EditPart)` method defined in the WindowBuilder edit-part is functionally identical to the one defined by the GEF edit-part and can be removed.
1 parent fa65bfe commit 157c760

File tree

1 file changed

+0
-25
lines changed

1 file changed

+0
-25
lines changed

org.eclipse.wb.core/src-gef/org/eclipse/wb/gef/core/EditPart.java

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -174,31 +174,6 @@ protected void refreshChildren() {
174174
}
175175
}
176176

177-
/**
178-
* Removes a child <code>{@link EditPart}</code>. This method is called from
179-
* {@link #refreshChildren()}. The following events occur in the order listed:
180-
* <OL>
181-
* <LI><code>deactivate()</code> is called if the child is active
182-
* <LI>{@link EditPart#removeNotify()} is called on the child.
183-
* <LI>The child's parent is set to <code>null</code>
184-
* </OL>
185-
* <P>
186-
*/
187-
protected final void removeChild(EditPart childPart) {
188-
int index = getChildren().indexOf(childPart);
189-
if (index == -1) {
190-
return;
191-
}
192-
fireRemovingChild(childPart, index);
193-
if (isActive()) {
194-
childPart.deactivate();
195-
}
196-
childPart.removeNotify();
197-
removeChildVisual(childPart);
198-
getChildren().remove(childPart);
199-
childPart.setParent(null);
200-
}
201-
202177
/**
203178
* Convenience method for returning the <code>{@link IEditPartViewer}</code> for this part.
204179
*/

0 commit comments

Comments
 (0)