/src/main/java/org/htmlunit/html/HtmlPage.java
executeEventHandlersIfNeeded( Event.TYPE_DOM_DOCUMENT_LOADED) ;executeEventHandlersIfNeeded( Event.TYPE_READY_STATE_CHANGE) ;
executeEventHandlersIfNeeded ( Event.TYPE_READY_STATE_CHANGE ) ;
if (!isAboutBlank) { if (hasFeature(FOCUS_BODY_ELEMENT_AT_START)) { setElementWithFocus(getBody()); } setReadyState(READY_STATE_COMPLETE); getDocumentElement().setReadyState(READY_STATE_COMPLETE); <extra_id_0> } boolean isFrameWindow = enclosingWindow instanceof FrameWindow; boolean isFirstPageInFrameWindow = false; if (isFrameWindow) { isFrameWindow = ((FrameWindow) enclosingWindow).getFrameElement() instanceof HtmlFrame; final History hist = enclosingWindow.getHistory();