WebCore:
Fix a recent regression that made JavaScript window closing
crash. Window closing was counting on delayed dealloc/destruction
of things associated with the window, but now that we have made
deallocs more synchronous, we need to add an explicit delay in
this case.
Also, change some fprintf diagnostics of things that should never
happen into assertions, since I actually ran into one.
* kwq/KWQKHTMLPartImpl.h:
* kwq/KWQKHTMLPartImpl.mm:
(KWQKHTMLPartImpl::slotData): Change fprintf diagnostic to assertion,
remove comment that the diagnostic should be removed.
(KWQKHTMLPartImpl::end): Change fprintf diagnostic to assertion,
remove comment that the diagnostic should be removed.
(KWQKHTMLPartImpl::scheduleClose): Renamed from close, changed to schedule
window closing from the run loop rather than doing it immediately.
* khtml/ecma/kjs_window.cpp:
(Window::scheduleClose): Adjusted for above rename.
WebKit:
Fix a regression in my recent refactoring that broke JavaScript
window opening, by doing some trickery to make a frame's initial
dummy data source committed.
* WebView.subproj/WebFrame.m:
(-[WebFrame initWithName:webView:provisionalDataSource:controller:]):
Create dummy data source as committed, not provisional.
* WebView.subproj/WebFramePrivate.m:
(-[WebFrame _transitionToCommitted]): Allow the documentView to be nil
if there is no webView either; this is temporarily needed to handle
the special initial dummy data source, which will be going away soon.
* WebView.subproj/WebDataSourcePrivate.m:
(-[WebDataSource _receivedData:]): Add temporary special case to
avoid sending empty NSData to the representation, to avoid
triggering WebCore assertions.
* WebCoreSupport.subproj/WebBridge.m:
(-[WebBridge openNewWindowWithURL:]): Get the committed data
source, not the provisional one.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@1622 268f45cc-cd09-0410-ab3c-d52691b4dbfc
14 files changed