Enumeration openBuffers = BufferManager.getDefaultBufferManager()
.getOpenBuffers();
while (openBuffers.hasMoreElements()) {
Object nextElement = openBuffers.nextElement();
if (nextElement instanceof DocumentAdapter) {
DocumentAdapter adapt = (DocumentAdapter) nextElement;
if (adapt.getDocument().equals(region.getParentDocument())
&& adapt.getOwner() instanceof ISourceModule) {
sourceModule = (ISourceModule) adapt.getOwner();
break;
}
}
}