X-Git-Url: http://git.ithinksw.org/ITKit.git/blobdiff_plain/475a1064c9d3637e7fae211d7a18d411c1178af0..a8daf8ac0972b8b5b582a97b50889fec447f45a4:/ITCategory-NSView.m diff --git a/ITCategory-NSView.m b/ITCategory-NSView.m index b2c8c0c..8c6ed90 100755 --- a/ITCategory-NSView.m +++ b/ITCategory-NSView.m @@ -7,4 +7,10 @@ [[self subviews] makeObjectsPerformSelector:@selector(removeFromSuperview)]; } +- (void)removeSubview:(NSView *)subview { + if ([subview superview] == self) { + [subview removeFromSuperview]; + } +} + @end