2010-01-13 Mark Rowe Merge r53195. 2010-01-13 Kevin Decker Reviewed by Mark Rowe. https://bugs.webkit.org/show_bug.cgi?id=33610 Silverlight full screen performance problem seen on Snow Leopard. * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView _workaroundSilverlightFullScreenBug:]): Added. Work around Silverlight full screen performance issue by maintaining an accelerated GL pixel format. We can safely remove this at some point in the future when both Microsoft releases a genuine fix for 7288546 and enough Silverlight users update to the new Silverlight. For now, we'll distinguish older broken versions of Silverlight by asking the plug-in if it resolved its full screen badness. (-[WebNetscapePluginView _createPlugin]): Call _workaroundSilverlightFullScreenBug:YES if this is Silverlight. (-[WebNetscapePluginView _destroyPlugin]): Call _workaroundSilverlightFullScreenBug:NO if this is Silverlight. 2009-10-16 Mark Rowe Merge r48683. 2009-09-22 Timothy Hatcher Prevent scrolling multiple frames during latched wheel events. Reviewed by Anders Carlsson. * WebView/WebDynamicScrollBarsView.h: * WebView/WebDynamicScrollBarsView.mm: (-[WebDynamicScrollBarsView scrollWheel:]): 2009-10-13 Mark Rowe Merge r48689. 2009-09-23 Darin Adler Reviewed by Dan Bernstein. Speed up access to history items by caching date computation. * History/WebHistory.mm: (getDayBoundaries): Refactored from timeIntervalForBeginningOfDay. Returns the beginning of the day that the passed time is within and the beginning of the next day. (beginningOfDay): Added. Uses getDayBoundaries so it can be fast for multiple dates within the same day, which is the common case. (dateKey): Added. Calls beginningOfDay and converts to an integer. (-[WebHistoryPrivate findKey:forDay:]): Changed to call dateKey insetad of timeIntervalForBeginningOfDay. 2009-10-13 Mark Rowe Merge r46645. 2009-07-31 Simon Fraser Reviewed by Anders Carlsson. Accelerated animations stutter on pages with lots of animations and 3d transforms https://bugs.webkit.org/show_bug.cgi?id=27884 This patch changes the strategy for synchronizing painting view the view, and compositing layer updates. Previously the strategy was to disable screen updates between the time we updated the layer tree, and painted the view. That left screen updates disabled for too long (hundreds of milliseconds) in some cases, causing animation stutter. The new strategy is to batch up changes to the CA layer tree, and commit them all at once just before painting happens (referred to as a "sync" in the code). GraphicsLayerCA now keeps a bitmask of changed properties, and then migrates the values stored in GraphicsLayer into the CA layer tree at commit time. Compositing layers are then synced in FrameView::paintContents(). However, not all style/layout changes will result in painting; to deal with style changes that touch only compositing properties, we set up a runloop observer that takes care of comitting layer changes when no painting happens. * WebCoreSupport/WebChromeClient.h: * WebCoreSupport/WebChromeClient.mm: (WebChromeClient::scheduleCompositingLayerSync): scheduleViewUpdate() renamed to syncCompositingStateRecursive() * WebView/WebView.mm: (-[WebView _close]): (-[WebView _clearLayerSyncLoopObserver]): "viewUpdateRunLoopObserver" is now "layerSyncLoopObserver". (-[WebView _syncCompositingChanges]): Helper method that calls syncCompositingStateRecursive() on the FrameView. (layerSyncRunLoopObserverCallBack): (-[WebView _scheduleCompositingLayerSync]): This is all about layer sycning now. Also, the run loop observer is repeating, because it has to keep firing until syncCompositingStateRecursive() says that it has completed. * WebView/WebViewData.h: "viewUpdateRunLoopObserver" is now "layerSyncLoopObserver". * WebView/WebViewInternal.h: _scheduleViewUpdate is now _scheduleCompositingLayerSync 2009-10-13 Mark Rowe Merge r49111. 2009-10-02 Chris Marrin Reviewed by Adele Peterson. Add functionality to pause/throttle CSS transitions/animations in a WebView https://bugs.webkit.org/show_bug.cgi?id=29942 Added both a setter and getter function * WebView/WebView.mm: (-[WebView cssAnimationsSuspended]): (-[WebView setCSSAnimationsSuspended:]): * WebView/WebViewData.h: * WebView/WebViewData.mm: (-[WebViewPrivate init]): * WebView/WebViewPrivate.h: 2009-10-13 Mark Rowe Merge r49133. 2009-10-05 Anders Carlsson Reviewed by Kevin Decker. WebKit side of * Plugins/Hosted/NetscapePluginInstanceProxy.h: Add an m_pluginIsWaitingForDraw member variable. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy): Initialize m_pluginIsWaitingForDraw. (WebKit::NetscapePluginInstanceProxy::invalidateRect): Set m_pluginIsWaitingForDraw to true. (WebKit::NetscapePluginInstanceProxy::didDraw): If m_pluginIsWaitingForDraw is true, call _WKPHPluginInstanceDidDraw. * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView drawRect:]): Call didDraw. * Plugins/Hosted/WebKitPluginHost.defs: Add PHPluginInstanceDidDraw. 2009-10-13 Mark Rowe Merge r49433. 2009-10-11 Dan Bernstein Reviewed by Darin Adler. REGRESSION (r48492): Gmail voice and video chat doesn’t work https://bugs.webkit.org/show_bug.cgi?id=30295 Test: plugins/setProperty.html * Plugins/Hosted/ProxyInstance.mm: (WebKit::ProxyInstance::setFieldValue): Fixed a typo. The function should return early if m_instanceProxy is null. 2009-10-13 Mark Rowe Merge r48492. 2009-09-17 Anders Carlsson Reviewed by Oliver Hunt. CrashTracer: 4800+ crashes in Safari at com.apple.WebKit • WTF::HashTableIterator... Add null checks for m_instanceProxy (It will be null when a plug-in has crashed). * Plugins/Hosted/ProxyInstance.mm: (WebKit::ProxyInstance::invoke): (WebKit::ProxyInstance::supportsInvokeDefaultMethod): (WebKit::ProxyInstance::supportsConstruct): (WebKit::ProxyInstance::getPropertyNames): (WebKit::ProxyInstance::methodsNamed): (WebKit::ProxyInstance::fieldNamed): (WebKit::ProxyInstance::fieldValue): (WebKit::ProxyInstance::setFieldValue): (WebKit::ProxyInstance::invalidate): 2009-10-12 Mark Rowe Merge r48946. 2009-09-30 Sam Weinig Reviewed by Dan Bernstein. Fix for Need WebKit API or SPI on Mac and Windows to test whether it's safe to load a page in a new tab/window * WebView/WebFrame.mm: (-[WebFrame _allowsFollowingLink:]): * WebView/WebFramePrivate.h: 2009-10-12 Mark Rowe Merge r47551. 2009-08-19 Mark Rowe Reviewed by Dan Bernstein. Fix Plug-in-related leaks seen on the build bot When the plug-in data is being loaded manually there is a reference cycle between the NetscapePluginInstanceProxy and the HostedNetscapePluginStream. We need to explicitly break the reference cycle in NetscapePluginInstanceProxy::cleanup so that both objects will be destroyed. Take the opportunity to add RefCountedLeakCounter support to HostedNetscapePluginStream and NetscapePluginInstanceProxy to simplify tracking down leaks of these objects in the future. * Plugins/Hosted/HostedNetscapePluginStream.h: * Plugins/Hosted/HostedNetscapePluginStream.mm: (WebKit::HostedNetscapePluginStream::HostedNetscapePluginStream): (WebKit::HostedNetscapePluginStream::~HostedNetscapePluginStream): * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy): (WebKit::NetscapePluginInstanceProxy::~NetscapePluginInstanceProxy): (WebKit::NetscapePluginInstanceProxy::cleanup): Clear m_manualStream to break the reference cycle. 2009-10-12 Mark Rowe Merge r47300. 2009-08-14 Mark Rowe Reviewed by Anders Carlsson. Fix leaks of HostedNetscapePluginStream and NetscapePlugInStreamLoader objects seen during layout tests. * Plugins/Hosted/HostedNetscapePluginStream.mm: (WebKit::HostedNetscapePluginStream::didFail): Disconnect the stream from the plug-in instance proxy when the load fails. 2009-10-12 Mark Rowe Merge r47657. 2009-08-21 Anders Carlsson Reviewed by Darin Adler. Sometimes WebKit does not layout correctly when a WebView is embedded in an HICocoaView Add a null check for the current context when reflectScrolledClipView: is called from outside a draw operation. * WebView/WebDynamicScrollBarsView.mm: (-[WebDynamicScrollBarsView reflectScrolledClipView:]): 2009-10-08 Mark Rowe Merge r48394. 2009-09-15 Mark Rowe Reviewed by Anders Carlsson. REGRESSION(r48360): Dragging a tab with a plug-in out of a window, the plug-in gets slow and confused In r48360, the fix for , I neglected to consider the case where the plug-in had already been started and -start would do an early-return rather than calling -restartTimers and -addWindowObservers itself. * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView viewDidMoveToWindow]): Reinstate the call to -restartTimers and -addWindowObservers, but guard them with a check that the view is still in the window. 2009-10-08 Mark Rowe Merge r48360. 2009-09-12 Mark Rowe Reviewed by Anders Carlsson. Fix Crashes in-[WebBaseNetscapePluginView stop] handling NSWindowWillCloseNotification. It's not valid to call -addWindowObservers when the view is not in a window, but this can happen when -start initializes a plug-in and the plug-in removes itself from the document during initialization. -viewDidMoveToWindow calls -start and then calls -addWindowObservers without ensuring that the view is still in a window. If -[WebBaseNetscapePluginView addWindowObservers] is incorrectly called when the view is not in a window, it will observe NSWindowWillCloseNotification on all windows. This unexpected observer registration is not balanced by an unregistration so the notification can be delivered after the view is deallocated, causing the crash seen in . * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView start]): Only call -updateAndSetWindow if we still have a current window. (-[WebBaseNetscapePluginView viewDidMoveToWindow]): Remove unnecessary calls to -restartTimers and -addWindowObservers from -[WebBaseNetscapePluginView viewDidMoveToWindow]. They are already called from within -start with the extra benefit of ensuring that the view is still in a window when they are called. 2009-07-27 Mark Rowe Merge r46449. Reviewed by Darin Adler. REGRESSION: Microsoft Messenger crashes during file send/receive due to use of WebKit on non-main thread In some situations Microsoft Messenger can attempt to manipulate the DOM from a secondary thread while updating its file transfer progress bar. This results in corruption of WebCore data structures that is quickly followed by a crash. We can work around this by having -[WebFrame DOMDocument] return nil when called from a secondary thread by Microsoft Messenger, which has the effect of turning its attempts at DOM manipulation in to no-ops. * WebView/WebFrame.mm: (needsMicrosoftMessengerDOMDocumentWorkaround): (-[WebFrame DOMDocument]): 2009-07-14 Mark Rowe Merge r45834. 2009-07-13 Anders Carlsson Reviewed by Darin Adler and Kevin Decker. Core Animation plug-ins continue to grow larger and larger when opening new tabs (32 bit-only) * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView setLayer:]): Add a FIXME. * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView setLayer:]): Make sure to set the size of the layer before changing the autoresizing mask so it won't grow everytime it's inserted into the layer tree. 2009-07-12 Mark Rowe Merge r45745. 2009-07-10 Simon Fraser Reviewed by John Sullivan. Flashing as hardware layers are created and destroyed in some content There's a window of time between the end of one runloop cycle, after CA layers changes have been committed, and the window display at the start of the next cycle when CA may push updates to the screen before AppKit has drawn the view contents. If we know that we need to do drawing synchronization (which we do when content moves between a layer and the view), then we need to call -disableScreenUpdatesUntilFlush from the existing runloop observer that is set up when layers need repainting to ensure that layer updates don't reach the screen before view-based painting does. * WebView/WebHTMLView.mm: (-[WebHTMLView drawRect:]): Tweak the comments * WebView/WebView.mm: (viewUpdateRunLoopObserverCallBack): (-[WebView _scheduleViewUpdate]): Add a big comment to explain the timing of things. Call -disableScreenUpdatesUntilFlush when the view _needsOneShotDrawingSynchronization. 2009-07-09 Brian Weinstein Reviewed by Tim Hatcher. 2009-07-11 Mark Rowe Disable channel messaging * Configurations/FeatureDefines.xcconfig: 2009-07-11 Mark Rowe Disable datagrid * Configurations/FeatureDefines.xcconfig: 2009-07-09 Drew Wilson Reviewed by Alexey Proskuryakov. https://bugs.webkit.org/show_bug.cgi?id=26903 Turned on CHANNEL_MESSAGING by default because the MessageChannel API can now be implemented for Web Workers and is reasonably stable. * Configurations/FeatureDefines.xcconfig: 2009-07-09 Darin Adler Reviewed by Adele Peterson and Dan Bernstein. Cannot set font to Helvetica Neue Light in Mail compose window No regression test because this only affects the font panel. * WebView/WebHTMLView.mm: (-[WebHTMLView _addToStyle:fontA:fontB:]): Fix code that detects whether the font would survive a round trip by using the weight corresponding to "bold" or "normal" rather than the actual weight number. 2009-07-09 Beth Dakin and Jon Honeycutt Reviewed by Dave Hyatt. Make Widget RefCounted to fix: REGRESSION (TOT): In Mail, a crash occurs at WebCore::Widget::afterMouseDown() after clicking To Do's close box WER #16: Repro Access Violation in WebCore::PluginView::bindingInstance (1310178023) -and- WER #13: Crash in WebKit! WebCore::PluginView::performRequest+203 (1311461169) * WebCoreSupport/WebFrameLoaderClient.h: * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::createPlugin): 2009-07-09 Sam Weinig Reviewed by Steve Falkenburg. Roll out r43848. The quirk is no longer necessary. * WebView/WebView.mm: (-[WebView WebCore::_userAgentForURL:WebCore::]): 2009-07-09 Alexey Proskuryakov Reviewed by Geoff Garen. Visit count shouldn't be incremented by redirects. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::updateGlobalHistory): Do not increase visit count if there is a redirect source. As a result, only pages that were explicitly visited by the user (by typing a URL, choosing one from bookmarks, or clicking a link) will be counted. * History/WebHistory.mm: (-[WebHistoryPrivate visitedURL:withTitle:increaseVisitCount:]): (-[WebHistory _visitedURL:withTitle:method:wasFailure:increaseVisitCount:]): * History/WebHistoryInternal.h: * History/WebHistoryItem.mm: (-[WebHistoryItem _visitedWithTitle:increaseVisitCount:]): * History/WebHistoryItemInternal.h: Marshal this new argument all the way down to WebCore. 2009-07-08 Greg Bolsinga Reviewed by Darin Adler. Add -[WebView _isProcessingUserGesture] https://bugs.webkit.org/show_bug.cgi?id=27084 Add -_isProcessingUserGesture that calls into WebCore::FrameLoader::isProcessingUserGesture() so that WebView code can determine if a user gesture is in progress. * WebView/WebView.mm: (-[WebView _isProcessingUserGesture]): * WebView/WebViewPrivate.h: 2009-07-07 Anders Carlsson Reviewed by Sam Weinig. - Fix . For Flash, don't cache which methods or fields in an object are missing, since they can be added at any time. * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::hostForPackage): * Plugins/Hosted/NetscapePluginHostProxy.h: (WebKit::NetscapePluginHostProxy::shouldCacheMissingPropertiesAndMethods): * Plugins/Hosted/NetscapePluginHostProxy.mm: (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy): * Plugins/Hosted/ProxyInstance.mm: (WebKit::ProxyInstance::methodsNamed): (WebKit::ProxyInstance::fieldNamed): 2009-07-06 David Kilzer Bug 27006: Build fix when MAC_JAVA_BRIDGE is disabled Reviewed by Darin Adler. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::createJavaAppletWidget): Wrap contents of the method in #if ENABLE(MAC_JAVA_BRIDGE)/#endif and return 0 when this feature is disabled. 2009-07-06 David Kilzer Bug 27005: Build fixes when NETSCAPE_PLUGIN_API is disabled Reviewed by Geoff Garen. * Plugins/WebPluginController.mm: (-[WebPluginController destroyPlugin:]): Wrap call to ScriptController::cleanupScriptObjectsForPlugin() in #if ENABLE(NETSCAPE_PLUGIN_API)/#endif macro. (-[WebPluginController destroyAllPlugins]): Ditto. * Plugins/WebPluginDatabase.mm: (-[WebPluginDatabase removePluginInstanceViewsFor:]): Wrap WebBaseNetscapePluginView class checks in #if ENABLE(NETSCAPE_PLUGIN_API)/#endif macro. (-[WebPluginDatabase destroyAllPluginInstanceViews]): Ditto. 2009-07-06 David Kilzer BUILD FIX: Use ENABLE(NETSCAPE_PLUGIN_API) instead of USE(PLUGIN_HOST_PROCESS) In r45579, #if/#endif macros for USE(PLUGIN_HOST_PROCESS) were used, but ENABLE(NETSCAPE_PLUGIN_API) should have been used instead. * Plugins/WebNetscapeContainerCheckContextInfo.h: * Plugins/WebNetscapeContainerCheckContextInfo.mm: * Plugins/WebNetscapeContainerCheckPrivate.mm: 2009-07-06 David Kilzer Bug 27004: Build fix for ENABLE(PLUGIN_PROXY_FOR_VIDEO) after r42618 Reviewed by Geoff Garen. * Plugins/WebPluginController.mm: (mediaProxyClient): Use core() method to convert from DOMElement to WebCore::Element. 2009-07-06 David Kilzer Bug 27003: Build fix when USE(PLUGIN_HOST_PROCESS) is disabled Reviewed by Geoff Garen. * Plugins/WebNetscapeContainerCheckContextInfo.h: Added #if USE(PLUGIN_HOST_PROCESS)/#endif guards. * Plugins/WebNetscapeContainerCheckContextInfo.mm: Ditto. * Plugins/WebNetscapeContainerCheckPrivate.mm: Ditto. 2009-07-06 Anders Carlsson Reviewed by Adele Peterson. Initialize wkIsLatchingWheelEvent. * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): 2009-07-03 Dan Bernstein Reviewed by Simon Fraser. - fix REGRESSION (r42118): Scrolling redraw problem in FileMaker Pro * WebView/WebHTMLView.mm: (-[WebHTMLView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]): Perform layout if needed, even on Mac OS X versions that have -viewWillDraw. This prevents attempts to draw without layout in case -viewWillDraw was not called due to NSView issues or the client did something during the display operation that re-invalidated the layout. 2009-07-02 Anders Carlsson Reviewed by Dan Bernstein. Software-rendered plug-in does not update correctly when inside a hardware layer Replace calls to setNeedsDisplay: and setNeedsDisplayInRect: with a call to the new method invalidatePluginContentRect:. This new method will ask WebCore to do the repainting, taking transforms into account. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::invalidateRect): * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView pluginHostDied]): * Plugins/WebBaseNetscapePluginView.h: * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView windowBecameKey:]): (-[WebBaseNetscapePluginView windowResignedKey:]): (-[WebBaseNetscapePluginView preferencesHaveChanged:]): (-[WebBaseNetscapePluginView invalidatePluginContentRect:]): * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView invalidateRect:]): (-[WebNetscapePluginView invalidateRegion:]): (-[WebNetscapePluginView forceRedraw]): 2009-07-02 Adam Roben Fix warnings from update-webkit-localizable-strings Rubber-stamped by Eric Carlson. * WebCoreSupport/WebViewFactory.mm: (-[WebViewFactory mediaElementLoadingStateText]): (-[WebViewFactory mediaElementLiveBroadcastStateText]): Changed the localization comments to match the comments in the Windows version of this file, to avoid warnings about different comments for the same localized string. 2009-07-02 Simon Fraser Reviewed by Dan Bernstein. Compositing-related preference methods are not public API; should move to WebPreferencesPrivate.h Move accelerated-compositing pref to WebPreferencesPrivate.h * WebView/WebPreferences.h: * WebView/WebPreferences.mm: (-[WebPreferences acceleratedCompositingEnabled]): (-[WebPreferences setAcceleratedCompositingEnabled:]): * WebView/WebPreferencesPrivate.h: 2009-07-02 Pierre d'Herbemont Reviewed by Simon Fraser. Add localized strings for media controller status messages. * WebCoreSupport/WebViewFactory.mm: Add new localized text. (-[WebViewFactory mediaElementLoadingStateText]): (-[WebViewFactory mediaElementLiveBroadcastStateText]): 2009-07-01 Brady Eidson Reviewed by Sam Weinig. Add a preference/setting to toggle whether content sniffing is enabled for file URLs. * WebView/WebPreferenceKeysPrivate.h: * WebView/WebPreferences.mm: (+[WebPreferences initialize]): (-[WebPreferences localFileContentSniffingEnabled]): (-[WebPreferences setLocalFileContentSniffingEnabled:]): * WebView/WebPreferencesPrivate.h: * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): 2009-07-01 David Hyatt Reviewed by Tim Hatcher. REGRESSION (r44474): Form text field has focus ring, looks focused, even though the field is not actually focused for keyboard input Add the concept of whether or not the Page is focused by adding a boolean to the focusController. This allows the focused frame and focused node to both be cached and changed programmatically without causing errors when the Page doesn't have focus. * WebView/WebHTMLView.mm: (-[WebHTMLView becomeFirstResponder]): (-[WebHTMLView resignFirstResponder]): 2009-06-30 Adele Peterson Reviewed by Dan Bernstein. Fix for REGRESSION(4-TOT): Hyperlinks have no tooltips in Mail unless you first click in the message body Updated these new methods (added as part of the viewless WebKit effort) that call through to WebHTMLView to use _selectedOrMainFrame, instead of just selectedFrame. When the selection changes, I don't think there is a situation where there's no selected frame, but it seems better to keep these two uses the same, since if there is a case, this will be more like the old behavior, before there was a version of _selectionChanged in WebView. * WebView/WebView.mm: (-[WebView _setToolTip:]): (-[WebView _selectionChanged]): 2009-06-30 Mark Rowe Reviewed by Timothy Hatcher. 'Save as…’ does not work in Mail * WebView/WebFrameView.mm: (-[WebFrameView initWithFrame:]): Call _needMailThreadWorkaroundIfCalledOffMainThread rather than needMailThreadWorkaround, as the latter is intended to be used at the point which a workaround would be applied and thus contains a main thread check. Since -initWithFrame: is called on the main thread, this was causing us to not switch from exception-throwing to logging for the thread violation behavior. 2009-06-30 Dan Bernstein Reviewed by Dave Hyatt. - fix REGRESSION (r30673): Shade10:" D_Snap to Grid" window is clipping * Misc/WebKitVersionChecks.h: Added WEBKIT_FIRST_VERSION_WITHOUT_SHADE10_QUIRK * WebView/WebView.mm: (-[WebView _needsLinkElementTextCSSQuirk]): Added. Returns YES if the client app is a version of Shade 10 earlier than 10.6 and it was linked against a version of WebKit earlier than 531.2. (-[WebView _preferencesChangedNotification:]): Added a call to Settings::setTreatsAnyTextCSSLinkAsStylesheet(). 2009-06-29 Eric Carlson Reviewed by Simon Fraser. Ask media engine if a movie is streamed or downloaded. * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Add QTMovieGetType. 2009-06-29 David Hyatt Reviewed by Adam Roben. Put datagrid behind an #ifdef. * Configurations/FeatureDefines.xcconfig: 2009-06-26 John Sullivan Added support for disabling Stop Speaking when there is no speaking to stop. Also fixed Stop Speaking so that it works (formerly it would throw an exception, and selecting it from the menu would perform a web search instead (!)). Reviewed by Tim Hatcher. * WebCoreSupport/WebContextMenuClient.h: declare isSpeaking() * WebCoreSupport/WebContextMenuClient.mm: (WebContextMenuClient::isSpeaking): implement by calling through to NSApplication (WebContextMenuClient::stopSpeaking): fixed implementation by correcting the signature of the NSApplication method 2009-06-26 Chris Marrin Reviewed by Simon Fraser . Additional fix for https://bugs.webkit.org/show_bug.cgi?id=26651 The flag should always default to true to avoid it getting set to false in a build with accelerated compositing turned off and then disabling accelerated compositing when subsequently running a build with it turned on. * WebView/WebPreferences.mm: (+[WebPreferences initialize]): 2009-06-26 Brady Eidson Fix SnowLeopard build. * Plugins/Hosted/HostedNetscapePluginStream.mm: (WebKit::HostedNetscapePluginStream::didReceiveResponse): 2009-06-26 Brady Eidson Reviewed by Sam Weinig REGRESSION (r43511): Opening .fdf files from Acrobat Professional fails Replace all usage of the now obsolete [NSURLResponse _webcore_MIMEType]. * Plugins/WebBaseNetscapePluginStream.mm: (WebNetscapePluginStream::didReceiveResponse): * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView pluginView:receivedData:]): * Plugins/WebPluginController.mm: (-[WebPluginController pluginView:receivedResponse:]): * WebView/WebDataSource.mm: (-[WebDataSource _responseMIMEType]): * WebView/WebResource.mm: (-[WebResource _initWithData:URL:response:]): 2009-06-26 Alexey Proskuryakov Reviewed by Sam Weinig. Update lookalike character list. * Misc/WebNSURLExtras.mm: (isLookalikeCharacter): Added more characters to the list. 2009-06-25 Anders Carlsson Reviewed by Oliver Hunt. REGRESSION (SnowLeopard): RealPlayer content replays when opening a new tab or switching back to the RealPlayer tab If a plug-in fails in NPP_New, we would try to recreate it whenever the preferences for a web view would change. Fix this by setting a flag when we fail to instantiate the plug-in, so we only try once. * Plugins/WebBaseNetscapePluginView.h: * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView start]): 2009-06-25 Chris Marrin Reviewed by Simon Fraser . https://bugs.webkit.org/show_bug.cgi?id=26651 Preference is named "WebKitAcceleratedCompositingEnabled" and is a boolean value. When false, prevents compositing layers from being created, which prevents hardware animation from running. Also forces video to do software rendering. Added a cache for the flag in RenderLayerCompositing and made it all work on-the-fly when the flag is changed while a page is loaded. * WebView/WebPreferenceKeysPrivate.h: * WebView/WebPreferences.h: * WebView/WebPreferences.mm: (+[WebPreferences initialize]): (-[WebPreferences acceleratedCompositingEnabled]): (-[WebPreferences setAcceleratedCompositingEnabled:]): * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): 2009-06-24 Dan Bernstein Reviewed by Anders Carlsson. Fix the most recently seen kind of crash in * WebView/WebHTMLView.mm: (-[WebHTMLView adjustPageHeightNew:top:bottom:limit:]): Null-check the Frame. 2009-06-24 Jeff Johnson Reviewed by Darin Adler. https://bugs.webkit.org/show_bug.cgi?id=26638 WebKitErrors.m: _initWithPluginErrorCode: does not set localizedDescription Add localized descriptions for plugin errors. The localized strings already existed but were unused; now NSLocalizedDescriptionKey is added to the NSError userInfo. * Misc/WebKitErrors.m: (-[NSError _initWithPluginErrorCode:contentURL:pluginPageURL:pluginName:MIMEType:]): 2009-06-23 Brady Eidson Reviewed by Darin Adler. REGRESSION: iSale 5.5.3 crashes after I click a template to load Due to some subtle WebKit changes - presumably some delegate callback behavior - a latent bug in iSale was uncovered where they aren't properly retaining their FrameLoadDelegate, and we ended up calling back to a dealloc'ed object. * WebView/WebView.mm: (-[WebView _needsAdobeFrameReloadingQuirk]): Use more intelligent C++-style initialization. (-[WebView _needsKeyboardEventDisambiguationQuirks]): Ditto. (-[WebView _needsFrameLoadDelegateRetainQuirk]): YES for iSale versions under 5.6 (-[WebView dealloc]): Release the delegate if the quirk is in effect. (-[WebView setFrameLoadDelegate:]): Retain the new delegate if the quirk is in effect. 2009-06-23 Anders Carlsson Reviewed by Darin Adler. - Fix Defer calls to WKPCInvalidateRect, so we don't try to invalidate while waiting for a reply, since that is too early. * Plugins/Hosted/NetscapePluginHostProxy.h: (WebKit::NetscapePluginHostProxy::isProcessingRequests): * Plugins/Hosted/NetscapePluginHostProxy.mm: (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy): (WebKit::NetscapePluginHostProxy::processRequests): (WKPCInvalidateRect): 2009-06-22 Timothy Hatcher Add Mail on Tiger and Leopard to the list of applications that need the WebView init thread workaround. Console shows WebKit Threading Violations from Mail Reviewed by Anders Carlsson. * WebView/WebView.mm: (clientNeedsWebViewInitThreadWorkaround): Return true for com.apple.Mail. 2009-06-22 Dan Bernstein Reviewed by Anders Carlsson. - speculative fix for Crash at -[WebHTMLView(WebPrivate) _updateMouseoverWithEvent:] The crash seems to happen because lastHitView points to a deleted object. Since -close calls -_clearLastHitViewIfSelf, I speculate that lastHitView has been set to an already-closed view. * WebView/WebHTMLView.mm: (-[WebHTMLView hitTest:]): Return nil if the view is closed. 2009-06-22 Alexey Proskuryakov Reviewed by John Sullivan. REGRESSION (S4Beta -> Final): After the password is input, Japanese can't be input. * WebView/WebHTMLView.mm: (-[WebHTMLView _updateSelectionForInputManager]): Removed an unnecessary check - the function has an early return for null frame. 2009-06-22 Dan Bernstein Reviewed by Dave Hyatt. - fix REGRESSION (r42787): After showing and hiding the Find banner, the WebHTMLView's height is not restored * WebView/WebFrameView.mm: (-[WebFrameView setFrameSize:]): Mark the FrameView for layout when the WebFrameView's size changes. * WebView/WebView.mm: (-[WebView setFrameSize:]): Left the resize logic here, but only for the single view model. 2009-06-20 Darin Adler Reviewed by Sam Weinig. Need more processing of pluginspage. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::createPlugin): Check protocolInHTTPFamily. 2009-06-18 Adam Barth Reviewed by Sam Weinig. https://bugs.webkit.org/show_bug.cgi?id=26199 Added preference to enable the XSSAuditor. * WebView/WebPreferenceKeysPrivate.h: * WebView/WebPreferences.mm: (+[WebPreferences initialize]): (-[WebPreferences isXSSAuditorEnabled]): (-[WebPreferences setXSSAuditorEnabled:]): * WebView/WebPreferencesPrivate.h: * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): 2009-06-18 Anders Carlsson Reviewed by Sam Weinig. NPN_ConvertPoint doesn't give the right value when converting to/from NPCoordinateSpaceFlippedScreen When inverting Y, use the height of the first screen instead of the screen the window is on. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::windowFrameChanged): (WebKit::NetscapePluginInstanceProxy::mouseEvent): * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView convertFromX:andY:space:toX:andY:space:]): 2009-06-16 Simon Fraser Reviewed by Dan Bernstein Control-click on pages with accelerated compositing content does not work. Part deux. #ifdef the use of _private->layerHostingView with USE(ACCELERATED_COMPOSITING) * WebView/WebHTMLView.mm: (-[WebHTMLView hitTest:]): 2009-06-16 Simon Fraser Reviewed by Dan Bernstein Control-click on pages with accelerated compositing content does not work. Remove the WebLayerHostingView subclass of NSView, with its attempts to forward events to the WebHTMLView, and just fix -[WebHTMLView hitTest:] to ignore the layerHostingView. * WebView/WebHTMLView.mm: (-[WebHTMLView hitTest:]): (-[WebHTMLView attachRootLayer:]): 2009-06-15 Simon Fraser Reviewed by Mark Rowe. Define ENABLE_3D_RENDERING when building on 10.6, and move ENABLE_3D_RENDERING switch from config.h to wtf/Platform.h. * Configurations/FeatureDefines.xcconfig: * WebKitPrefix.h: 2009-06-15 Anders Carlsson Reviewed by Dan Bernstein. CrashTracer: 15 crashes in Safari at com.apple.WebKit • WebKit::NetscapePluginHostManager::didCreateWindow + 85 Make sure to remove the entry from the plug-in host map so we won't end up with an entry that has a null value. * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::hostForPackage): 2009-06-15 Dan Bernstein Reviewed by Tim Hatcher. - make the source code font in the Web Inspector match Mac defaults * WebCoreSupport/WebInspectorClient.mm: (-[WebInspectorWindowController init]): Set the default monospace font to 11px Menlo, except on Leopard and Tiger where it is 10px Monaco. 2009-06-09 Justin Garcia Reviewed by Eric Seidel. Landed by Adam Barth. https://bugs.webkit.org/show_bug.cgi?id=26281 REGRESSION: Copying from TextEdit/OmniGraffle and pasting into editable region loses images Prefer RTFD (RTF with inline images) over RTF. In http://trac.webkit.org/changeset/19745 I accidently reversed their order. * WebView/WebHTMLView.mm: (-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:]): 2009-06-13 Adam Barth Reviewed by Darin Fisher. https://bugs.webkit.org/show_bug.cgi?id=24492 Move registerURLSchemeAsLocal from FrameLoader to SecurityOrigin * WebView/WebView.mm: (+[WebView registerURLSchemeAsLocal:]): 2009-06-12 Peter Kasting Reviewed by Eric Seidel. * ChangeLog-2007-10-14: Change pseudonym "Don Gibson" to me (was used while Google Chrome was not public); update my email address. 2009-06-08 Dan Bernstein Rubber-stamped by Mark Rowe. - gave Objective-C++ files the .mm extension * Carbon/HIWebView.m: Removed. * Carbon/HIWebView.mm: Copied from WebKit/mac/Carbon/HIWebView.m. * Misc/WebKitNSStringExtras.m: Removed. * Misc/WebKitNSStringExtras.mm: Copied from WebKit/mac/Misc/WebKitNSStringExtras.m. * Misc/WebStringTruncator.m: Removed. * Misc/WebStringTruncator.mm: Copied from WebKit/mac/Misc/WebStringTruncator.m. * WebInspector/WebNodeHighlight.m: Removed. * WebInspector/WebNodeHighlight.mm: Copied from WebKit/mac/WebInspector/WebNodeHighlight.m. * WebInspector/WebNodeHighlightView.m: Removed. * WebInspector/WebNodeHighlightView.mm: Copied from WebKit/mac/WebInspector/WebNodeHighlightView.m. * WebView/WebDynamicScrollBarsView.m: Removed. * WebView/WebDynamicScrollBarsView.mm: Copied from WebKit/mac/WebView/WebDynamicScrollBarsView.m. 2009-06-05 David Hyatt Reviewed by Mark Rowe. https://bugs.webkit.org/show_bug.cgi?id=26220 Update a WebView's active state when it moves to a different window. * WebView/WebView.mm: (-[WebView viewDidMoveToWindow]): 2009-06-04 Sam Weinig Reviewed by Alice Liu. Move WebView internal data into WebViewData.h/mm. * WebView/WebDelegateImplementationCaching.mm: * WebView/WebView.mm: * WebView/WebViewData.h: Copied from mac/WebView/WebViewInternal.h. * WebView/WebViewData.mm: Copied from mac/WebView/WebViewInternal.mm. * WebView/WebViewInternal.h: * WebView/WebViewInternal.mm: Removed. 2009-06-04 David Hyatt Reviewed by Sam Weinig. Remove _updateFocusedStateForFrame, since it's actually not even necessary now that I made setFocusedFrame get called explicitly from become/ResignFirstResponder. setFocusedFrame does the work of focusing the selection already. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::transitionToCommittedForNewPage): * WebView/WebHTMLView.mm: (-[WebHTMLView becomeFirstResponder]): (-[WebHTMLView resignFirstResponder]): * WebView/WebView.mm: * WebView/WebViewInternal.h: 2009-06-04 Dan Bernstein - build fix * WebView/WebViewInternal.mm: 2009-06-03 David Hyatt Reviewed by Sam Weinig. Reworking of focus and active state updating for WebHTMLViews so that it actually works instead of reporting wrong answers. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::transitionToCommittedForNewPage): WebHTMLViews become first responders before they are able to reach their Frames/Pages. This happens because the NSClipView becomes first responder when the WebHTMLView gets destroyed, and then we transfer the responder state back to the new WebHTMLView when it is first connected. Once we have transitioned to a new page and have the Frame/Page available, go ahead and explicitly focus the frame in WebCore and update our focused state. This change allows us to remove the updateFocusedActive timer and the code from viewDidMoveToWindow. * WebView/WebHTMLView.mm: (-[WebHTMLView close]): (-[WebHTMLView addWindowObservers]): (-[WebHTMLView viewWillMoveToWindow:]): (-[WebHTMLView viewDidMoveToWindow]): (-[WebHTMLView _removeWindowObservers]): Remove all the updateFocusedActiveState timer code, since it no longer exists. (-[WebHTMLView windowDidBecomeKey:]): (-[WebHTMLView windowDidResignKey:]): Active state updating is no longer done by WebHTMLViews. It is handled by the WebView instead. (-[WebHTMLView becomeFirstResponder]): (-[WebHTMLView resignFirstResponder]): Reworking of WebHTMLView's code for gaining/losing responder status. No longer update active state here, since the active state can never change just because of responder changes. Make sure that the focused frame gets updated properly (and most importantly actually cleared when a WebHTMLView resigns responder status). * WebView/WebHTMLViewInternal.h: * WebView/WebHTMLViewPrivate.h: State updating for focused and active states has been made independent. * WebView/WebView.mm: (-[WebView _updateActiveState]): WebView now handles updating of active state in _updateActiveState. It is now purely based off whether the window is key and nothing else. (-[WebView addWindowObserversForWindow:]): (-[WebView removeWindowObservers]): Start listening for the window becoming/losing key even in the usesDocumentViews case. (-[WebView _updateFocusedStateForFrame:]): Focused state updating is split into its own method now and called when WebHTMLViews gain and lose responder status. (-[WebView _windowDidBecomeKey:]): (-[WebView _windowDidResignKey:]): Make sure to call _updateActiveState as the window gains/loses key. (-[WebView _windowWillOrderOnScreen:]): Run this code now that WebHTMLView no longer does it. * WebView/WebViewInternal.h: * WebView/WebViewPrivate.h: Updating for the split of focused and active state updating into separate methods. 2009-06-04 Mark Rowe Speculative Tiger build fix. * WebView/WebDelegateImplementationCaching.h: 2009-06-03 Sam Weinig Reviewed by Mark Rowe. Move delegate implementation caching logic into its own files. * WebView/WebDelegateImplementationCaching.h: Copied from mac/WebView/WebViewInternal.h. * WebView/WebDelegateImplementationCaching.mm: Copied from mac/WebView/WebView.mm. (WebViewGetResourceLoadDelegateImplementations): (WebViewGetFrameLoadDelegateImplementations): (WebViewGetScriptDebugDelegateImplementations): * WebView/WebView.mm: * WebView/WebViewInternal.h: 2009-06-03 Sam Weinig Reviewed by Mark Rowe. Move WebViewPrivate structure to WebViewInternal.h/mm. * WebView/WebView.mm: * WebView/WebViewInternal.h: * WebView/WebViewInternal.mm: Added. (+[WebViewPrivate initialize]): (-[WebViewPrivate init]): (-[WebViewPrivate dealloc]): (-[WebViewPrivate finalize]): 2009-06-03 Sam Weinig Reviewed by Darin Adler. Small cleanup in WebView. - Move global data initialization to WebView's initialization method. - Move _clearViewUpdateRunLoopObserver from WebViewPrivate to WebView (FileInternal) * WebView/WebView.mm: (-[WebViewPrivate init]): Remove global initializers. (-[WebViewPrivate dealloc]): Cleanup whitespace. (-[WebViewPrivate finalize]): Ditto. (-[WebView _close]): Call [self _clearViewUpdateRunLoopObserver] instead of [_private _clearViewUpdateRunLoopObserver] (+[WebView initialize]): Move global initializers here. (-[WebView _clearViewUpdateRunLoopObserver]): Moved from WebViewPrivate. (viewUpdateRunLoopObserverCallBack): Call [self _clearViewUpdateRunLoopObserver] instead of [_private _clearViewUpdateRunLoopObserver] 2009-06-03 Dan Bernstein Reviewed by Anders Carlsson. - WebKit part of eliminating WebCoreTextRenderer * Misc/WebKitNSStringExtras.m: (webkit_CGCeiling): Added. (-[NSString _web_drawAtPoint:font:textColor:]): Replaced the malloc()ed string buffer with a Vector. Moved code from WebCoreDrawTextAtPoint() to here. (-[NSString _web_drawDoubledAtPoint:withTopColor:bottomColor:font:]): (-[NSString _web_widthWithFont:]): Replaced the malloc()ed string buffer with a Vector. Moved code from WebCoreTextFloatWidth() to here. * WebView/WebHTMLView.mm: (-[WebHTMLView _addToStyle:fontA:fontB:]): Replaced call to WebCoreFindFont() with use of +[WebFontCache fontWithFamily:traits:weight:size:]. * WebView/WebView.mm: (+[WebView _setAlwaysUsesComplexTextCodePath:]): Changed to call Font::setCodePath() directly. (+[WebView _setShouldUseFontSmoothing:]): Changed to call Font::setShouldUseSmoothing(). (+[WebView _shouldUseFontSmoothing]): Changed to call Font::shouldUseSmoothing(). 2009-06-03 Dan Bernstein Rubber-stamped by Mark Rowe. - remove a private method that was used only by Safari 3.0. * WebView/WebView.mm: Removed +_minimumRequiredSafariBuildNumber. * WebView/WebViewPrivate.h: Ditto. 2009-06-03 Dan Bernstein - build fix * WebView/WebHTMLView.mm: 2009-06-03 Dan Bernstein Reviewed by Anders Carlsson. - build fix * WebView/WebHTMLView.mm: * WebView/WebView.mm: 2009-06-02 Darin Adler Reviewed by David Hyatt. Bug 26112: viewless WebKit -- make events work https://bugs.webkit.org/show_bug.cgi?id=26112 One change here is to make the -[WebFrame frameView] function assert if ever called in viewless mode, and fix many callers that would trip that assertion. A major change is to put some methods and data in WebView that are currently in WebHTMLView, used only in viewless mode. A next step will be to use the WebView methods whenever possible, even when not in the viewless mode. Also fix FrameView to do normal reference counting instead of a strange model with an explicit deref near creation time. * WebCoreSupport/WebChromeClient.mm: (WebChromeClient::scrollRectIntoView): Add code to start in the appropriate place when dealing with viewless mode. This gets triggered when visiting the Google home page. (WebChromeClient::setToolTip): Changed to call WebView instead of WebHTMLView. (WebChromeClient::print): Changed to use a new selector that doesn't require a WebFrameView if present. Also don't even try to use the old selector in viewless mode. * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::respondToChangedSelection): Changed to call WebView instead of WebHTMLView. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::transitionToCommittedForNewPage): Added more code paths for viewless mode to skip things we can't do in that mode, with appropriate FIXME. Use Frame::create and RefPtr and eliminate the strange reference counting of FrameView. * WebView/WebDataSource.mm: (-[WebDataSource _receivedData:]): Added a _usesDocumentViews guard around code that's specific to document views. * WebView/WebFrame.mm: (-[WebFrame _updateBackgroundAndUpdatesWhileOffscreen]): Added a _usesDocumentViews guard around code that's specific to document views. (-[WebFrame _hasSelection]): Added an implementation for viewless mode. (-[WebFrame _clearSelection]): Assert we're not in viewless mode; it doesn't really make sense to clear the selection in only one frame in viewless mode. Later we can decide what to do. (-[WebFrame _dragSourceMovedTo:]): Assert we're not in viewless mode; the dragging code for viewless mode shouldn't have to involve the WebFrame object at all. (-[WebFrame _dragSourceEndedAt:operation:]): Ditto. (-[WebFrame frameView]): Assert we're not in viewless mode. This assertion fires often, but it's a great pointer to code that needs to be changed. * WebView/WebHTMLView.mm: (-[WebHTMLView hitTest:]): Tweaked a comment. (-[WebHTMLView _updateMouseoverWithEvent:]): Fixed a bug where the fake event for moving the mouse out of the old view ended up overwriting the event for moving the mouse within the new view. (-[WebHTMLView mouseDown:]): Got rid of explicit conversion of event to PlatformMouseEvent in call to sendContextMenuEvent; that's no longer possible without passing another argument, and it's now handled in EventHandler. * WebView/WebTextCompletionController.h: Copied from WebKit/mac/WebView/WebHTMLView.mm. Removed everything except for the WebTextCompletionController class. * WebView/WebTextCompletionController.mm: Copied from WebKit/mac/WebView/WebHTMLView.mm. Ditto. * WebView/WebUIDelegatePrivate.h: Added webView:printFrame: method. * WebView/WebView.mm: Moved includes and fields in from WebHTMLView. (-[WebView _usesDocumentViews]): Updated for name change from useDocumentViews to usesDocumentViews. (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]): Ditto. (-[WebView drawSingleRect:]): Ditto. (-[WebView isFlipped]): Ditto. (-[WebView setFrameSize:]): Ditto. Also changed to use _mainCoreFrame method. (-[WebView _viewWillDrawInternal]): Ditto. (-[WebView viewWillDraw]): Ditto. (-[WebView drawRect:]): Ditto. (-[WebView _close]): Added code to nil out the lastMouseoverView global. (-[WebView _dashboardRegions]): Use _mainCoreFrame. (-[WebView setProhibitsMainFrameScrolling:]): Ditto. (-[WebView _setInViewSourceMode:]): Ditto. (-[WebView _inViewSourceMode]): Ditto. (-[WebView _attachScriptDebuggerToAllFrames]): Ditto. (-[WebView _detachScriptDebuggerFromAllFrames]): Ditto. (-[WebView textIteratorForRect:]): Ditto. (-[WebView _executeCoreCommandByName:value:]): Ditto. (-[WebView addWindowObserversForWindow:]): Ditto. (-[WebView removeWindowObservers]): Ditto. (-[WebView _updateFocusedAndActiveState]): Ditto. (-[WebView _updateFocusedAndActiveStateForFrame:]): Turned into a class method. Added code to handle the viewless case without calling frameView. (-[WebView _windowDidBecomeKey:]): Updated for name change from useDocumentViews to usesDocumentViews. (-[WebView _windowDidResignKey:]): Ditto. (-[WebView _windowWillOrderOnScreen:]): Ditto. (-[WebView mainFrame]): Tweaked. (-[WebView selectedFrame]): Added a conditional to avoid trying to get at the frame view in viewless case. (-[WebView _setZoomMultiplier:isTextOnly:]): Use _mainCoreFrame. (-[WebView setCustomTextEncodingName:]): Ditto. (-[WebView windowScriptObject]): Ditto. (-[WebView setHostWindow:]): Ditto. Also put some code that's needed only for document views inside _private->usesDocumentViews. (-[WebView _hitTest:dragTypes:]): Tweaked. (-[WebView acceptsFirstResponder]): Added case for viewless mode along with a FIXME, since it's not complete. (-[WebView becomeFirstResponder]): Ditto. (-[WebView _webcore_effectiveFirstResponder]): Put the body of this inside a usesDocumentView check, because we don't need the first responder forwarding in viewless mode. (-[WebView setNextKeyView:]): Ditto. (-[WebView mouseDown:]): Added. Copied from WebHTMLView. FIXME in here suggests that we make WebHTMLView share this one soon, which I think is practical. (-[WebView mouseUp:]): Ditto. (-[WebView setHoverFeedbackSuspended:]): Added a code path for viewless mode. (-[WebView shouldClose]): Use _mainCoreFrame. (-[WebView aeDescByEvaluatingJavaScriptFromString:]): Ditto. (-[WebView setEditable:]): Ditto. (-[WebView _frameViewAtWindowPoint:]): Added an assertion that we're not in viewless mode since this method makes no sense in that mode. (-[WebView _setMouseDownEvent:]): Added. Copied from WebHTMLView. I plan to eliminate the one in WebHTMLView soon. (-[WebView _cancelUpdateMouseoverTimer]): Ditto. (-[WebView _stopAutoscrollTimer]): Ditto. (+[WebView _updateMouseoverWithEvent:]): Ditto. (-[WebView _updateMouseoverWithFakeEvent]): Ditto. (-[WebView _setToolTip:]): Added. Calls through to the WebHTMLView version. (-[WebView _selectionChanged]): Ditto. (-[WebView _mainCoreFrame]): Added. (-[WebView _needsOneShotDrawingSynchronization]): Moved into the WebInternal category. (-[WebView _setNeedsOneShotDrawingSynchronization:]): Ditto. (-[WebView _startedAcceleratedCompositingForFrame:]): Ditto. (-[WebView _stoppedAcceleratedCompositingForFrame:]): Ditto. (viewUpdateRunLoopObserverCallBack): Ditto. (-[WebView _scheduleViewUpdate]): Ditto. * WebView/WebViewInternal.h: Made most of the file not compile at all when included from non-C++ source files, elminating some excess declarations and typedefs. Moved more methods into the real internal category. Added new methods _setMouseDownEvent, _cancelUpdateMouseoverTimer, _stopAutoscrollTimer, _updateMouseoverWithFakeEvent, _selectionChanged, and _setToolTip:. 2009-06-02 Mark Rowe Reviewed by Anders Carlsson. Remove workaround that was added to address as it no longer affects our Tiger builds. * Configurations/Base.xcconfig: 2009-06-01 Darin Adler * WebView/WebTextCompletionController.mm: Fix Tiger build by adding import of WebTypesInternal.h. 2009-06-01 Darin Adler Reviewed by Maciej Stachowiak. Bug 26113: break WebTextCompletionController out into its own source file https://bugs.webkit.org/show_bug.cgi?id=26113 * WebView/WebHTMLView.mm: (-[WebHTMLViewPrivate dealloc]): Updated for new name. (-[WebHTMLViewPrivate clear]): Ditto. (-[WebHTMLView _frameOrBoundsChanged]): Ditto. (-[WebHTMLView menuForEvent:]): Ditto. (-[WebHTMLView windowDidResignKey:]): Ditto. (-[WebHTMLView windowWillClose:]): Ditto. (-[WebHTMLView mouseDown:]): Ditto. (-[WebHTMLView resignFirstResponder]): Ditto. (-[WebHTMLView keyDown:]): Ditto. (-[WebHTMLView complete:]): Ditto. Also pass WebView to init method. (-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]): Ditto. * WebView/WebTextCompletionController.h: Copied from mac/WebView/WebHTMLView.mm. * WebView/WebTextCompletionController.mm: Copied from mac/WebView/WebHTMLView.mm. Changed initializer to pass in a spearate WebView and WebHTMLView, to smooth the way for handling viewless mode properly in the future. 2009-05-30 David Kilzer Add JSLock to -[WebScriptCallFrame scopeChain] Reviewed by Darin Adler. In Debug builds of WebKit, Dashcode launching MobileSafari could cause the ASSERT(JSLock::lockCount() > 0) assertion to fire in JSC::Heap::heapAllocate() because the JSLock wasn't taken. * WebView/WebScriptDebugDelegate.mm: (-[WebScriptCallFrame scopeChain]): Take JSLock before calling into JavaScriptCore. 2009-05-28 Mark Rowe Rubber-stamped by Dan Bernstein. Build fix. Move off a deprecated NSFileManager method. * Misc/WebNSFileManagerExtras.h: * Misc/WebNSFileManagerExtras.m: (-[NSFileManager destinationOfSymbolicLinkAtPath:error:]): Implement a new-in-Leopard method for Tiger to use. (-[NSFileManager attributesOfItemAtPath:error:]): Ditto. * Plugins/WebNetscapePluginPackage.mm: (-[WebNetscapePluginPackage _initWithPath:]): Use the new non-deprecated methods. 2009-05-28 Dirk Schulze Reviewed by Nikolas Zimmermann. Added new build flag --filters. More details in WebCore/ChangeLog. * Configurations/FeatureDefines.xcconfig: 2009-05-27 Alexey Proskuryakov Reviewed by Darin Adler. https://bugs.webkit.org/show_bug.cgi?id=26009 REGRESSION (r43973): Problems While Working With OpenVanilla * WebView/WebHTMLView.mm: (-[WebHTMLView _updateSelectionForInputManager]): Don't call updateWindows if the selection is None. This routinely happens during editing, and it doesn't mean that we left an editable area (in which case the selection changes to a non-editable one). 2009-05-26 Sam Weinig Reviewed by Brady Eidson. Fix for iWeb 'Announce' button does nothing after publishing to MobileMe Add linked-on-or-after check to allow older WebKit apps to use the old behavior of sniffing everything (including file: urls) * Misc/WebKitVersionChecks.h: * WebView/WebView.mm: (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]): 2009-05-26 Stephanie Lewis Reviewed by Ada Chan and Oliver Hunt. Remove WebView observers in during fast teardown. REGRESSION (Tiger-only?): After restoring windows from the previous session, a crash occurs while attempting to quit Safari * WebView/WebView.mm: (-[WebView _closeWithFastTeardown]): 2009-05-26 Anders Carlsson Reviewed by Dan Bernstein. REGRESSION (r35515): Tiger crash painting the selection on registration page of car2go.com Remove WKCGContextIsSafeToClip. * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): 2009-05-26 Dan Bernstein Reviewed by Darin Adler. - fix REGRESSION (r43973): Can't type first character with an umlaut, circumflex, or accent in Mail or in a wiki * WebView/WebHTMLView.mm: (isTextInput): Moved here. (isInPasswordField): Moved here. (-[WebHTMLView becomeFirstResponder]): Update the exposeInputContext flag and let NSApplication update the input manager with the new input context if necessary. (-[WebHTMLView _updateSelectionForInputManager]): Changed to use the NSApp global instead of +[NSApplication sharedApplication]. 2009-05-26 Mark Rowe Fix the Tiger build. * Misc/WebNSObjectExtras.mm: (-[NSInvocation _webkit_invokeAndHandleException:]): Rename the local variable so that it doesn't conflict with a member variable on Tiger. 2009-05-26 Darin Adler Reviewed by Mark Rowe. REGRESSION (r44115): Crash in Leopard Mail viewing message Fix case where we autorelease an object on the main thread that we are returning to another thread when using our _webkit_invokeOnMainThread method. * Misc/WebNSObjectExtras.mm: (returnTypeIsObject): Added. (-[WebMainThreadInvoker forwardInvocation:]): Autorelease the object on the calling thread, balancing a retain done on the main thread. (-[NSInvocation _webkit_invokeAndHandleException:]): Retain the object on the main thread. 2009-05-26 David Hyatt Back out the workaround for Mail crashing. Darin is working on the real fix. * Misc/WebNSObjectExtras.mm: (-[WebMainThreadInvoker forwardInvocation:]): 2009-05-26 David Hyatt Reviewed by Darin Adler. Fix for https://bugs.webkit.org/show_bug.cgi?id=25969. Stop using notifications for boundsChanged, since the notifications are being sent too late. Since subviews get resized before parents do, the notification comes in telling the WebHTMLView that its size has changed *before* we've done setNeedsLayout in the WebView size change callback. Become more like the Windows platform and just do the bounds changed immediately as our size is being altered by subclassing setFrameSize in WebView. Also patch WebDynamicScrollbarsView to detect the case where neither axis is really spilling out past the viewport, so that in shrinking situations we figure out that we don't need scrollbars any more. * WebView/WebDynamicScrollBarsView.m: (-[WebDynamicScrollBarsView updateScrollers]): * WebView/WebView.mm: (-[WebView _boundsChangedToNewSize:]): (-[WebView setFrameSize:]): (-[WebView viewWillMoveToWindow:]): (-[WebView viewDidMoveToWindow]): 2009-05-25 Anders Carlsson Reviewed by Sam Weinig. - WebKit side of . * Plugins/Hosted/NetscapePluginHostManager.h: * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::didCreateWindow): Iterate over all plug-in hosts. If one is in full-screen mode, make sure to activate the WebKit app instead. * Plugins/Hosted/NetscapePluginHostProxy.h: (WebKit::NetscapePluginHostProxy::isMenuBarVisible): Add getter. * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCEvaluate): Add allowPopups flag. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::PluginRequest::PluginRequest): (WebKit::NetscapePluginInstanceProxy::PluginRequest::allowPopups): (WebKit::NetscapePluginInstanceProxy::loadURL): (WebKit::NetscapePluginInstanceProxy::evaluateJavaScript): (WebKit::NetscapePluginInstanceProxy::loadRequest): (WebKit::NetscapePluginInstanceProxy::evaluate): Use "allowPopups" instead of "userGesture". * Plugins/Hosted/WebKitPluginClient.defs: Add allowPopups argument to Evaluate. * Plugins/Hosted/WebKitPluginHostTypes.h: Use "allowPopups" instead of "userGesture". * WebCoreSupport/WebChromeClient.mm: (WebChromeClient::createWindow): Call didCreateWindow here. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::dispatchCreatePage): Ditto. 2009-05-25 Anders Carlsson Reviewed by Sam Weinig. - Fix . Release the placeholder window after -[NSApplication runModalForWindow] returns. * Plugins/Hosted/NetscapePluginHostProxy.mm: (WebKit::NetscapePluginHostProxy::beginModal): (WebKit::NetscapePluginHostProxy::endModal): 2009-05-24 Dan Bernstein - revert an accidental change from r43964. * WebView/WebView.mm: (+[WebView _setShouldUseFontSmoothing:]): 2009-05-24 Darin Adler Reviewed by Dan Bernstein and Tim Hatcher. New console message spewed by automator CLI after installing JetstreamLeo40B21a * Misc/WebNSObjectExtras.mm: (-[WebMainThreadInvoker initWithTarget:]): Tweaked argument name. (-[WebMainThreadInvoker forwardInvocation:]): Removed call to retainArguments. This was unneeded and in the case of a newly created but not yet fully initialized NSView object it caused the abovementioned bug. (-[WebMainThreadInvoker handleException:]): Tweaked argument name. Added assertion. (-[NSInvocation _webkit_invokeAndHandleException:]): Tweaked name of local variable that holds the exception. 2009-05-23 David Kilzer Part 2 of 2: Bug 25495: Implement PassOwnPtr and replace uses of std::auto_ptr Reviewed by Oliver Hunt. * History/WebHistory.mm: (-[WebHistory _visitedURL:withTitle:method:wasFailure:]): Return 0 instead of an empty auto_ptr<>. * History/WebHistoryItem.mm: (-[WebHistoryItem initFromDictionaryRepresentation:]): Use OwnPtr<> instead of auto_ptr<> for stack variable. * WebCoreSupport/WebChromeClient.h: (WebChromeClient::createHTMLParserQuirks): Return a PassOwnPtr<> instead of a raw HTMLParserQuirks pointer. 2009-05-23 David Kilzer Part 1 of 2: Bug 25495: Implement PassOwnPtr and replace uses of std::auto_ptr Reviewed by Oliver Hunt. * ForwardingHeaders/wtf/OwnPtrCommon.h: Added. * ForwardingHeaders/wtf/PassOwnPtr.h: Added. 2009-05-22 Darin Adler Reviewed by Dan Bernstein. - Fix REGRESSION (r42331-r42334): Extra scroll bars appearing on Welcome panels of iLife '09 apps * WebView/WebView.mm: (needsUnwantedScrollBarWorkaround): Added. Checks if this is a panel where scroll bars are unwanted. For safety, limited to only Apple applications. (-[WebView viewDidMoveToWindow]): If the workaround is needed, disallow scrolling the main frame. This prevents scroll bars from appearing. 2009-05-22 Adam Barth Reviewed by Maciej Stachowiak. https://bugs.webkit.org/show_bug.cgi?id=25955 Remove the policyBaseURL parameter from setCookie. This parameter is redudant with the document parameter. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::setCookies): * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView setVariable:forURL:value:length:]): 2009-05-21 Darin Fisher Fix-up coding style. * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::getAutoCorrectSuggestionForMisspelledWord): 2009-05-20 Siddhartha Chattopadhyaya Reviewed by Justin Garcia. Add automatic spell correction support in WebKit https://bugs.webkit.org/show_bug.cgi?id=24953 * WebCoreSupport/WebEditorClient.h: * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::getAutoCorrectSuggestionForMisspelledWord): 2009-05-21 Alexey Proskuryakov Reviewed by Darin Adler. REGRESSION (r43143): Hang in RenderLineBoxList::dirtyLinesFromChangedChild when clicking link to load Flash animation (http://www.roambi.com) * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::respondToChangedSelection): Don't call -[NSApplication updateWindows] here, WebHTMLView can take care of this. * WebView/WebHTMLView.mm: (-[WebHTMLView inputContext]): Use a precomputed boolean stored in WebHTMLViewPrivate, as calling isTextInput() is not always safe. (-[WebHTMLView textStorage]): Ditto. (-[WebHTMLView _updateSelectionForInputManager]): Update _private->exposeInputContext when selection changes, and let AppKit update its cache if necessary. 2009-05-21 Alexey Proskuryakov Reviewed by Darin Adler. REGRESSION (2-3): "Default default" encoding for Korean changed from Korean (Windows, DOS) to Korean (ISO 2022-KR), which breaks some sites * WebView/WebPreferences.mm: (+[WebPreferences _setInitialDefaultTextEncodingToSystemEncoding]): Update the existing fix for the changed result of CFStringConvertEncodingToIANACharSetName(). 2009-05-21 Alexey Proskuryakov Reviewed by Darin Adler. REGRESSION (r43143): First character typed with input method does not go into inline hole (seen with Chinese & Kotoeri on top Chinese website www.baidu.com) * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::respondToChangedSelection): Call -[NSApplication updateWindows] to make AppKit re-fetch the input context when selection changes. Since we use SelectionController to check whether the view is editable, it is important not to re-fetch the context too early, e.g. from a focus changed notification. 2009-05-21 Eric Seidel Reviewed by Alexey Proskuryakov. Rename DragController::dragOperation() to sourceDragOperation() for clarity * WebView/WebHTMLView.mm: (-[WebHTMLView draggingSourceOperationMaskForLocal:]): 2009-05-21 Dan Bernstein Reviewed by Anders Carlsson. - WebKit part of REGRESSION (r35515): Tiger crash painting the selection on registration page of car2go.com * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Added CGContextIsSafeToClip. 2009-05-20 Stephanie Lewis Update the order files. Generate new order files. * WebKit.order: 2009-05-20 Brady Eidson Reviewed by Darin Adler. REGRESSION: "Clear History" does not save empty history to disk * History/WebHistory.mm: (-[WebHistoryPrivate data]): If there are no entries, return an empty NSData instead of nil. 2009-05-20 Anders Carlsson Reviewed by Darin Adler and Kevin Decker. WebKit side of Pass the localization as a launch property. * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::spawnPluginHost): 2009-05-20 Dan Bernstein - fix the build after r43918 * WebCoreSupport/WebChromeClient.h: (WebChromeClient::setCursor): 2009-05-20 Darin Adler Reviewed by John Sullivan. Shift-Tab skips key views in toolbar in Safari, although Tab iterates through them properly * WebView/WebView.mm: (-[WebView previousValidKeyView]): Work around a bug in -[NSView previousValidKeyView]. 2009-05-19 Timothy Hatcher Add a new private API method that will dispatch pending loads that have been scheduled because of recent DOM additions or style changes. REGRESSION: Some iChat transcript resources are not loaded because willSendRequest doesn't happen immediately Reviewed by Antti Koivisto. * WebView/WebView.mm: (-[WebView _dispatchPendingLoadRequests]): Call Loader::servePendingRequests(). * WebView/WebViewPrivate.h: Added _dispatchPendingLoadRequests. 2009-05-18 Sam Weinig Can't see Apple ad on nytimes.com unless I spoof the user agent Add user agent hack for pointroll.com. Reviewed by Steve Falkenburg. * WebView/WebView.mm: (-[WebView WebCore::_userAgentForURL:WebCore::]): 2009-05-16 Anders Carlsson Reviewed by Sam Weinig and Dan Bernstein. Fix * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::spawnPluginHost): 2009-05-16 Dan Bernstein - revert an accidental change from r43802. * WebInspector/WebInspector.mm: 2009-05-16 Anders Carlsson Reviewed by Dan Bernstein. Mouse wheeling in the QuickTime plug-in (incorrectly) scrolls the page Fix logic. The plug-in returns true if it handled the event. * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView sendEvent:isDrawRect:]): 2009-05-16 Dan Bernstein Reviewed by Alexey Proskuryakov. - fix Two distinct characters are not displayed correctly with 2 of the font selections from the stickies widget * WebView/WebHTMLView.mm: (-[WebHTMLView _plainTextFromPasteboard:]): Return precomposed text. This is consistent with -_documentFragmentFromPasteboard:forType:inContext:subresources:. 2009-05-15 Anders Carlsson Reviewed by Dan Bernstein. Fix . * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::instantiatePlugin): If we failed to instantiate the plug-in, call cleanup() so that any streams created by the plug-in from its NPP_New callback are destroyed. * Plugins/Hosted/NetscapePluginInstanceProxy.h: Make cleanup() public. 2009-05-15 Darin Adler Reviewed by Anders Carlsson. hash table iterator used after hash table modified in ProxyInstance::fieldNamed() when viewing movie trailer * Plugins/Hosted/ProxyInstance.mm: (WebKit::ProxyInstance::methodsNamed): Move add call after the waitForReply call. Anders says that by the time we return someone else might have done the same add for us. (WebKit::ProxyInstance::fieldNamed): Ditto. 2009-05-15 Anders Carlsson Reviewed by Darin Adler. Replace WKN_GetLocation with WKN_ResolveURL (WKN_GetLocation was confusing and did not take the base URL into account) * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCResolveURL): New MIG callback. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::resolveURL): Use FrameLoader::complete URL here. * Plugins/Hosted/WebKitPluginClient.defs: Add new MIG definition. * Plugins/WebBaseNetscapePluginView.h: * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView resolvedURLStringForURL:target:]): * Plugins/WebNetscapeContainerCheckPrivate.h: * Plugins/WebNetscapeContainerCheckPrivate.mm: (browserContainerCheckFuncs): * Plugins/WebNetscapePluginView.h: * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView resolveURL:forTarget:]): * Plugins/npapi.mm: (WKN_ResolveURL): 2009-05-15 Dan Bernstein Reviewed by Darin Adler. - fix WebTextIterator should not “emit characters between all visible positions” * WebView/WebTextIterator.mm: (-[WebTextIterator initWithRange:]): Changed to construct a TextIterator with emitCharactersBetweenAllVisiblePositions set to false. 2009-05-15 Mark Rowe Reviewed by Dave Kilzer. Look for libWebKitSystemInterface.a in a more reasonable location. * Configurations/DebugRelease.xcconfig: 2009-05-14 David Hyatt Reviewed by Tim Hatcher. Fix for REGRESSION (S4 beta-ToT): Adium chat window contents no longer resize. Technically this is a bug in Adium. It appears that Adium has subclassed the WebView and implemented viewDidMoveToWindow in its subclass improperly. It doesn't call up to the base class WebView like it should and so our boundsChanged notification never gets added. Reduce the dependence on viewDidMoveToWindow by moving the registration of observers into viewWillMoveToWindow instead. * WebView/WebView.mm: (-[WebView addSizeObserversForWindow:]): (-[WebView removeWindowObservers]): (-[WebView addWindowObserversForWindow:]): (-[WebView viewWillMoveToWindow:]): (-[WebView viewDidMoveToWindow]): (-[WebView viewDidMoveToSuperview]): 2009-05-14 David Levin Reviewed by Eric Seidel. https://bugs.webkit.org/show_bug.cgi?id=24704 Allow the local cache directory to be set using a defaults key. * Misc/WebKitNSStringExtras.h: * Misc/WebKitNSStringExtras.m: (+[NSString _webkit_localCacheDirectoryWithBundleIdentifier:]): * WebKit.exp: 2009-05-14 Darin Adler Reviewed by Adam Roben. Automator actions that use WebKit on a background thread fail when run outside of Automator * WebView/WebView.mm: (clientNeedsWebViewInitThreadWorkaround): Added. Contains new broader rule. (needsWebViewInitThreadWorkaround): Changed to call clientNeedsWebViewInitThreadWorkaround. 2009-05-14 Darin Adler Reviewed by John Sullivan. Bug 24049: Second right-click crashes safari when alert invoked https://bugs.webkit.org/show_bug.cgi?id=24049 rdar://problem/6878977 * WebView/WebHTMLView.mm: (-[WebHTMLView rightMouseUp:]): Added a retain/autorelease of the event. (-[WebHTMLView menuForEvent:]): Ditto. Also cleaned up the logic here and eliminated some use of pointers that might be invalid after calling through to WebCore. (-[WebHTMLView scrollWheel:]): Ditto. (-[WebHTMLView acceptsFirstMouse:]): Ditto. (-[WebHTMLView shouldDelayWindowOrderingForEvent:]): Ditto. (-[WebHTMLView mouseDown:]): Ditto. (-[WebHTMLView mouseDragged:]): Ditto. (-[WebHTMLView mouseUp:]): Ditto. (-[WebHTMLView keyDown:]): Ditto. (-[WebHTMLView keyUp:]): Ditto. (-[WebHTMLView flagsChanged:]): Ditto. (-[WebHTMLView performKeyEquivalent:]): Ditto. 2009-05-14 Mark Rowe Rubber-stamped by Darin Adler. When building with Xcode 3.1.3 should be using gcc 4.2 The meaning of XCODE_VERSION_ACTUAL is more sensible in newer versions of Xcode. Update our logic to select the compiler version to use the more appropriate XCODE_VERSION_MINOR if the version of Xcode supports it, and fall back to XCODE_VERSION_ACTUAL if not. * Configurations/Base.xcconfig: 2009-05-13 Anders Carlsson Reviewed by Sam Weinig. WebKit side of . * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCGetLocation): Forward this to the plug-in instance proxy. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::getLocation): Ask the plug-in view for the location. * Plugins/Hosted/WebKitPluginClient.defs: Add MIG definition. * Plugins/WebBaseNetscapePluginView.h: * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView locationStringForTarget:]): Return the URL for a given frame. * Plugins/WebNetscapeContainerCheckPrivate.h: Bump version. Add new declaration to the vtable. * Plugins/WebNetscapeContainerCheckPrivate.mm: (browserContainerCheckFuncs): Add new declaration to the vtable. * Plugins/WebNetscapePluginView.h: * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView locationForTarget:]): Call the base class method. * Plugins/npapi.mm: (WKN_GetLocation): Forward this to the plug-in view. 2009-05-13 Douglas R. Davidson Reviewed by Darin Adler. Smart Copy/Paste setting should persist as continuous spell checking setting does * WebView/WebPreferenceKeysPrivate.h: Added WebSmartInsertDeleteEnabled. * WebView/WebView.mm: (-[WebViewPrivate init]): Initialize based on WebSmartInsertDeleteEnabled default. (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]): Removed code that initialized here. (-[WebView setSmartInsertDeleteEnabled:]): Set default here was with continuous spell checking setting. 2009-05-13 Darin Adler Revert the parser arena change. It was a slowdown, not a speedup. Better luck next time (I'll break it up into pieces). 2009-05-13 Darin Adler Reviewed by Cameron Zwarich. Bug 25674: syntax tree nodes should use arena allocation https://bugs.webkit.org/show_bug.cgi?id=25674 * Plugins/Hosted/NetscapePluginInstanceProxy.mm: Updated includes. New ones needed due to reducing includes of JSDOMBinding.h. * WebView/WebScriptDebugger.mm: Ditto. 2009-05-13 Douglas R. Davidson Reviewed by Darin Adler. Generate a contextual menu item allowing autocorrections to easily be changed back. Refrain from re-correcting items that have already been autocorrected once. * WebCoreSupport/WebViewFactory.mm: (-[WebViewFactory contextMenuItemTagChangeBack:]): * WebView/WebUIDelegatePrivate.h: 2009-05-12 Anders Carlsson Reviewed by Dan Bernstein. Fix . When instantiating the QT plug-in under Dashboard, force "kiosk mode". * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:element:WebCore::]): 2009-05-12 Dan Bernstein Reviewed by Darin Adler. - declare a forgotten method * DOM/WebDOMOperationsPrivate.h: Declare -[DOMNode markupString] in the WebDOMNodeOperationsPendingPublic category. 2009-05-10 Alexey Proskuryakov Reviewed by Dan Bernstein. Have to enter credentials twice when downloading from a protected page * Misc/WebDownload.m: Removed. * Misc/WebDownload.mm: Copied from WebKit/mac/Misc/WebDownload.m. (-[WebDownloadInternal download:didReceiveAuthenticationChallenge:]): Try to use credentials from WebCore storage. 2009-05-08 Nikolas Zimmermann Not reviewed. Fix clean builds, forgot to land name() -> formControlName() rename patch in WebKit. Only landed the WebCore side. * WebView/WebHTMLRepresentation.mm: (-[WebHTMLRepresentation elementWithName:inForm:]): 2009-05-08 Anders Carlsson Reviewed by Kevin Decker. - Fix . Instead of just caching whether a plug-in object _has_ a field or method, also add an entry to the cache if it _doesn't_ have a certain field or method. This way we have to make fewer calls to the plug-in host. * Plugins/Hosted/ProxyInstance.mm: (WebKit::ProxyInstance::methodsNamed): (WebKit::ProxyInstance::fieldNamed): 2009-05-08 Douglas R. Davidson Reviewed by Darin Adler. Fixes for . Disable text checking menu items if view is not editable. * WebView/WebHTMLView.mm: (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]): (-[WebHTMLView smartInsertDeleteEnabled]): (-[WebHTMLView setSmartInsertDeleteEnabled:]): (-[WebHTMLView toggleSmartInsertDelete:]): * WebView/WebHTMLViewInternal.h: 2009-05-08 Alexey Proskuryakov Reviewed by Maciej Stachowiak. NPN_GetAuthenticationInfo does not work with non-permanent credentials * Plugins/WebBaseNetscapePluginView.mm: (WebKit::getAuthenticationInfo): Ask WebCore for credentials first (but also ask NSURLCredentialStorage, because WebCore won't know about permanent credentials). 2009-05-05 Ben Murdoch Reviewed by Eric Seidel. Add #if ENABLE(DATABASE) guards around database code so toggling ENABLE_DATABASE off does not break builds. https://bugs.webkit.org/show_bug.cgi?id=24776 * Storage/WebDatabaseManager.mm: * Storage/WebDatabaseManagerInternal.h: * Storage/WebDatabaseManagerPrivate.h: * Storage/WebDatabaseTrackerClient.h: * Storage/WebDatabaseTrackerClient.mm: * Storage/WebSecurityOrigin.mm: (-[WebSecurityOrigin usage]): (-[WebSecurityOrigin quota]): (-[WebSecurityOrigin setQuota:]): * Storage/WebSecurityOriginPrivate.h: * WebCoreSupport/WebChromeClient.h: * WebCoreSupport/WebChromeClient.mm: * WebView/WebView.mm: (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]): 2009-05-04 Anders Carlsson Reviewed by Kevin Decker. Fix . Make sure to send a reply even when an instance proxy can't be found. * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCEvaluate): (WKPCInvoke): (WKPCInvokeDefault): (WKPCGetProperty): (WKPCHasProperty): (WKPCHasMethod): (WKPCEnumerate): 2009-05-04 Darin Adler Reviewed by Eric Seidel. Bug 24924: remove Document.h include of Attr.h and HTMLCollection.h, and NamedMappedAttrMap.h include of MappedAttribute.h https://bugs.webkit.org/show_bug.cgi?id=24924 * WebView/WebFrame.mm: Added include of CSSMutableStyleDeclaration.h and ScriptValue.h. 2009-05-02 Geoffrey Garen Reviewed by Sam Weinig. Simplified null-ish JSValues. Replaced calls to noValue() with calls to JSValue() (which is what noValue() returned). Removed noValue(). Removed "JSValue()" initialiazers, since default construction happens... by default. * WebView/WebScriptDebugDelegate.mm: (-[WebScriptCallFrame evaluateWebScript:]): 2009-05-02 Alexey Proskuryakov Reviewed by Dan Bernstein. REGRESSION (r38629): Shortcut "Flag/Junk" in MobileMe does not work when Kotoeri is used. * WebView/WebHTMLView.mm: (-[WebHTMLView inputContext]): Return a nil input context when focus is not in editable content. 2009-05-01 Geoffrey Garen Rubber Stamped by Sam Weinig. Renamed JSValuePtr => JSValue. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::evaluate): (WebKit::NetscapePluginInstanceProxy::invoke): (WebKit::NetscapePluginInstanceProxy::invokeDefault): (WebKit::NetscapePluginInstanceProxy::construct): (WebKit::NetscapePluginInstanceProxy::getProperty): (WebKit::NetscapePluginInstanceProxy::setProperty): (WebKit::NetscapePluginInstanceProxy::hasMethod): (WebKit::NetscapePluginInstanceProxy::addValueToArray): (WebKit::NetscapePluginInstanceProxy::marshalValue): (WebKit::NetscapePluginInstanceProxy::demarshalValueFromArray): (WebKit::NetscapePluginInstanceProxy::demarshalValue): (WebKit::NetscapePluginInstanceProxy::demarshalValues): * Plugins/Hosted/ProxyInstance.h: * Plugins/Hosted/ProxyInstance.mm: (WebKit::ProxyField::valueFromInstance): (WebKit::ProxyField::setValueToInstance): (WebKit::ProxyInstance::invoke): (WebKit::ProxyInstance::invokeMethod): (WebKit::ProxyInstance::invokeDefaultMethod): (WebKit::ProxyInstance::invokeConstruct): (WebKit::ProxyInstance::defaultValue): (WebKit::ProxyInstance::stringValue): (WebKit::ProxyInstance::numberValue): (WebKit::ProxyInstance::booleanValue): (WebKit::ProxyInstance::valueOf): (WebKit::ProxyInstance::fieldValue): (WebKit::ProxyInstance::setFieldValue): * WebView/WebFrame.mm: (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]): * WebView/WebScriptDebugDelegate.mm: (-[WebScriptCallFrame _convertValueToObjcValue:]): (-[WebScriptCallFrame exception]): (-[WebScriptCallFrame evaluateWebScript:]): * WebView/WebView.mm: (aeDescFromJSValue): (-[WebView aeDescByEvaluatingJavaScriptFromString:]): 2009-05-01 Pavel Feldman Reviewed by Timothy Hatcher. Add a FrameLoaderClient callback for the ResourceRetrievedByXMLHttpRequest. https://bugs.webkit.org/show_bug.cgi?id=25347 * WebCoreSupport/WebFrameLoaderClient.h: * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::dispatchDidLoadResourceByXMLHttpRequest): 2009-04-30 David Kilzer Provide a mechanism to create a quirks delegate for HTMLParser Reviewed by David Hyatt. * WebCoreSupport/WebChromeClient.h: (WebChromeClient::createHTMLParserQuirks): Added. The default implementation of this factory method returns 0. 2009-04-30 Dimitri Glazkov Reviewed by Timothy Hatcher. https://bugs.webkit.org/show_bug.cgi?id=25470 Extend the cover of ENABLE_JAVASCRIPT_DEBUGGER to profiler. * Configurations/FeatureDefines.xcconfig: Added ENABLE_JAVASCRIPT_DEBUGGER define. 2009-04-30 Kevin Decker Reviewed by Anders Carlson. Fix an issue where some plug-ins would cause the application icon to constantly bounce up and down in the Dock. * Plugins/Hosted/NetscapePluginHostProxy.h: Change m_placeholderWindow ivar to be a subclass of NSWindow, WebPlaceholderModalWindow. * Plugins/Hosted/NetscapePluginHostProxy.mm: Added WebPlaceholderModalWindow NSWindow subclass. (-[WebPlaceholderModalWindow _wantsUserAttention]): Prevent NSApp from calling requestUserAttention: when the window is shown modally, even if the app is inactive. (WebKit::NetscapePluginHostProxy::beginModal): NSWindow -> WebPlaceholderModalWindow. 2009-04-30 Pavel Feldman Reviewed by Dimitri Glazkov. https://bugs.webkit.org/show_bug.cgi?id=25342 Add MessageSource and MessageLevel parameters to the ChromeClient::addMessageToConsole. * WebCoreSupport/WebChromeClient.h: * WebCoreSupport/WebChromeClient.mm: (WebChromeClient::addMessageToConsole): 2009-04-29 Mark Rowe More build fixing after r43037. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::invoke): (WebKit::NetscapePluginInstanceProxy::invokeDefault): (WebKit::NetscapePluginInstanceProxy::construct): (WebKit::NetscapePluginInstanceProxy::demarshalValues): 2009-04-29 Dan Bernstein Reviewed by Simon Fraser. - WebKit part of Select All and then Delete should put Mail editing back into the same state as a new message * WebView/WebView.mm: (-[WebView _selectionIsCaret]): Added. (-[WebView _selectionIsAll]): Added. Returns whether the selection encompasses the entire document. * WebView/WebViewPrivate.h: 2009-04-29 Douglas Davidson Reviewed by Justin Garcia. Mail exhibits issues with text checking, e.g. menu items not always validated correctly * WebView/WebHTMLView.mm: (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]): (-[WebHTMLView orderFrontSubstitutionsPanel:]): * WebView/WebView.mm: (-[WebView validateUserInterfaceItemWithoutDelegate:]): 2009-04-29 David Hyatt Reviewed by Dan Bernstein. Fix a bug in the bounds checking for setNeedsLayout dirtying when a WebView's size changes. The superview of the WebView was being incorrectly checked instead of the WebView itself. * WebView/WebView.mm: (-[WebView _boundsChanged]): 2009-04-29 Kevin Decker Reviewed by Anders Carlson. Allow WKN_CheckIfAllowedToLoadURL() to take an optional void* context parameter. * Plugins/WebNetscapeContainerCheckContextInfo.h: * Plugins/WebNetscapeContainerCheckContextInfo.mm: (-[WebNetscapeContainerCheckContextInfo initWithCheckRequestID:callbackFunc:context:]): (-[WebNetscapeContainerCheckContextInfo callback]): (-[WebNetscapeContainerCheckContextInfo context]): * Plugins/WebNetscapeContainerCheckPrivate.h: * Plugins/WebNetscapeContainerCheckPrivate.mm: (browserContainerCheckFuncs): * Plugins/WebNetscapePluginView.h: * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView checkIfAllowedToLoadURL:frame:callbackFunc:context:]): (-[WebNetscapePluginView _containerCheckResult:contextInfo:]): * Plugins/npapi.mm: (WKN_CheckIfAllowedToLoadURL): 2009-04-29 David Hyatt Reviewed by John Sullivan. Fix for , Find Banner turns invisible when WebView is resized. Make sure not to resize the interior views of a WebView in response to its bounds changing when not using viewless WebKit. Auto-resizing rules were already in place to handle size adjustments for us. Just mark as needing layout and do nothing else. This does mean viewless WebKit is broken with the Find Banner, and that will likely require a Safari change (using a new API that will enable clients to define the edges of the content area as offsets from the sides of the WebView). * WebView/WebView.mm: (-[WebView _boundsChanged]): 2009-04-28 Geoffrey Garen Rubber stamped by Beth Dakin. Removed scaffolding supporting dynamically converting between 32bit and 64bit value representations. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::marshalValues): 2009-04-28 Anders Carlsson Reviewed by Kevin Decker and Darin Adler. Fix . * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCCheckIfAllowedToLoadURL): Call the instance proxy. (WKPCCancelCheckIfAllowedToLoadURL): Ditto. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy): Initialize the check ID counter. (WebKit::NetscapePluginInstanceProxy::checkIfAllowedToLoadURL): Create a WebPluginContainerCheck, add it to the map, and start it. (WebKit::NetscapePluginInstanceProxy::cancelCheckIfAllowedToLoadURL): Remove the check from the map. (WebKit::NetscapePluginInstanceProxy::checkIfAllowedToLoadURLResult): Call the WKPH MIG callback. * Plugins/Hosted/WebHostedNetscapePluginView.h: * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView _webPluginContainerCancelCheckIfAllowedToLoadRequest:]): Call the instance proxy. (-[WebHostedNetscapePluginView _containerCheckResult:contextInfo:]): Ditto. * Plugins/Hosted/WebKitPluginClient.defs: * Plugins/Hosted/WebKitPluginHost.defs: Add MIG declarations. 2009-04-28 Dan Bernstein Reviewed by John Sullivan. - fix Make PDF an insertable pasteboard type * WebCoreSupport/WebPasteboardHelper.mm: (WebPasteboardHelper::insertablePasteboardTypes): * WebView/WebHTMLView.mm: (-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:]): (+[WebHTMLView _insertablePasteboardTypes]): (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]): 2009-04-27 Douglas R. Davidson Add the various switches and context menu items needed for WebViews need to implement text checking and adopt updatePanels in place of old SPI _updateGrammar. Reviewed by Justin Garcia. * WebCoreSupport/WebContextMenuClient.mm: (fixMenusReceivedFromOldClients): * WebCoreSupport/WebEditorClient.h: * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::uppercaseWord): (WebEditorClient::lowercaseWord): (WebEditorClient::capitalizeWord): (WebEditorClient::showSubstitutionsPanel): (WebEditorClient::substitutionsPanelIsShowing): (WebEditorClient::toggleSmartInsertDelete): (WebEditorClient::isAutomaticQuoteSubstitutionEnabled): (WebEditorClient::toggleAutomaticQuoteSubstitution): (WebEditorClient::isAutomaticLinkDetectionEnabled): (WebEditorClient::toggleAutomaticLinkDetection): (WebEditorClient::isAutomaticDashSubstitutionEnabled): (WebEditorClient::toggleAutomaticDashSubstitution): (WebEditorClient::isAutomaticTextReplacementEnabled): (WebEditorClient::toggleAutomaticTextReplacement): (WebEditorClient::isAutomaticSpellingCorrectionEnabled): (WebEditorClient::toggleAutomaticSpellingCorrection): (WebEditorClient::checkTextOfParagraph): * WebCoreSupport/WebViewFactory.mm: (-[WebViewFactory contextMenuItemTagShowColors]): (-[WebViewFactory contextMenuItemTagCorrectSpellingAutomatically]): (-[WebViewFactory contextMenuItemTagSubstitutionsMenu]): (-[WebViewFactory contextMenuItemTagShowSubstitutions:]): (-[WebViewFactory contextMenuItemTagSmartCopyPaste]): (-[WebViewFactory contextMenuItemTagSmartQuotes]): (-[WebViewFactory contextMenuItemTagSmartDashes]): (-[WebViewFactory contextMenuItemTagSmartLinks]): (-[WebViewFactory contextMenuItemTagTextReplacement]): (-[WebViewFactory contextMenuItemTagTransformationsMenu]): (-[WebViewFactory contextMenuItemTagMakeUpperCase]): (-[WebViewFactory contextMenuItemTagMakeLowerCase]): (-[WebViewFactory contextMenuItemTagCapitalize]): * WebView/WebHTMLView.mm: (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]): (-[WebHTMLView isAutomaticQuoteSubstitutionEnabled]): (-[WebHTMLView setAutomaticQuoteSubstitutionEnabled:]): (-[WebHTMLView toggleAutomaticQuoteSubstitution:]): (-[WebHTMLView isAutomaticLinkDetectionEnabled]): (-[WebHTMLView setAutomaticLinkDetectionEnabled:]): (-[WebHTMLView toggleAutomaticLinkDetection:]): (-[WebHTMLView isAutomaticDashSubstitutionEnabled]): (-[WebHTMLView setAutomaticDashSubstitutionEnabled:]): (-[WebHTMLView toggleAutomaticDashSubstitution:]): (-[WebHTMLView isAutomaticTextReplacementEnabled]): (-[WebHTMLView setAutomaticTextReplacementEnabled:]): (-[WebHTMLView toggleAutomaticTextReplacement:]): (-[WebHTMLView isAutomaticSpellingCorrectionEnabled]): (-[WebHTMLView setAutomaticSpellingCorrectionEnabled:]): (-[WebHTMLView toggleAutomaticSpellingCorrection:]): * WebView/WebHTMLViewInternal.h: * WebView/WebPreferenceKeysPrivate.h: * WebView/WebUIDelegatePrivate.h: * WebView/WebView.mm: (-[WebViewPrivate init]): (-[WebView validateUserInterfaceItemWithoutDelegate:]): (-[WebView setGrammarCheckingEnabled:]): (-[WebView isAutomaticQuoteSubstitutionEnabled]): (-[WebView isAutomaticLinkDetectionEnabled]): (-[WebView isAutomaticDashSubstitutionEnabled]): (-[WebView isAutomaticTextReplacementEnabled]): (-[WebView isAutomaticSpellingCorrectionEnabled]): (-[WebView setAutomaticQuoteSubstitutionEnabled:]): (-[WebView toggleAutomaticQuoteSubstitution:]): (-[WebView setAutomaticLinkDetectionEnabled:]): (-[WebView toggleAutomaticLinkDetection:]): (-[WebView setAutomaticDashSubstitutionEnabled:]): (-[WebView toggleAutomaticDashSubstitution:]): (-[WebView setAutomaticTextReplacementEnabled:]): (-[WebView toggleAutomaticTextReplacement:]): (-[WebView setAutomaticSpellingCorrectionEnabled:]): (-[WebView toggleAutomaticSpellingCorrection:]): * WebView/WebViewPrivate.h: 2009-04-27 David Kilzer Consolidate runtime application checks for Apple Mail and Safari Reviewed by Mark Rowe and Darin Adler. * WebCoreSupport/WebContextMenuClient.mm: (isAppleMail): Removed. (fixMenusToSendToOldClients): Switched to use applicationIsAppleMail(). * WebView/WebFrame.mm: (-[WebFrame reload]): Switched to use applicationIsSafari(). * WebView/WebPDFView.mm: (-[WebPDFView menuForEvent:]): Ditto. * WebView/WebResource.mm: (+[WebResource _needMailThreadWorkaroundIfCalledOffMainThread]): Switched to use applicationIsAppleMail(). * WebView/WebView.mm: (runningLeopardMail): Ditto. (runningTigerMail): Ditto. (-[WebView _needsKeyboardEventDisambiguationQuirks]): Switched to use applicationIsSafari(). 2009-04-27 Kevin Decker Fix the Tiger build. * Plugins/WebNetscapePluginView.mm: The base class of WebNetscapePluginView.mm, WebBaseNetscapePluginView, already implemented the two methods below. But the Tiger compiler didn't know that. (-[WebNetscapePluginView webView]): (-[WebNetscapePluginView webFrame]): 2009-04-27 Kevin Decker Reviewed by Anders Carlsson. * Plugins/WebBaseNetscapePluginView.mm: Removed checkIfAllowedToLoadURL:frame:callbackFunc, cancelCheckIfAllowedToLoadURL, and _webPluginContainerCancelCheckIfAllowedToLoadRequest from the base class. These methods now exist in the subclass WebNetscapePluginView. Added WebNetscapeContainerCheckContextInfo, which is used as a "contextInfo" object in -[WebNetscapePluginView checkIfAllowedToLoadURL:frame:callbackFunc:] * Plugins/WebNetscapeContainerCheckContextInfo.h: Added. * Plugins/WebNetscapeContainerCheckContextInfo.mm: Added. (-[WebNetscapeContainerCheckContextInfo initWithCheckRequestID:callbackFunc:]): Added desiginated initializer. (-[WebNetscapeContainerCheckContextInfo checkRequestID]): Added. Returns the checkRequestID. (-[WebNetscapeContainerCheckContextInfo callback]): Added. Returns the callback. * Plugins/WebNetscapePluginView.h: Added two new ivars: _containerChecksInProgress and _currentContainerCheckRequestID. * Plugins/WebNetscapePluginView.mm: #import both WebPluginContainerCheck.h and WebNetscapeContainerCheckContextInfo.h (-[WebNetscapePluginView checkIfAllowedToLoadURL:frame:callbackFunc:]): Added. This is the implementation of WKN_CheckIfAllowedToLoadURL. Here, we increment the request ID and start the container check. (-[WebNetscapePluginView _containerCheckResult:contextInfo:]): Added. This is a callback method for WebPluginContainerCheck. It's where we actually call into the plug-in and provide the allow-or-deny result. (-[WebNetscapePluginView cancelCheckIfAllowedToLoadURL:]): Added. This is the implementation of WKN_CancelCheckIfAllowedToLoadURL. Here we lookup the check, cancel it, and remove it from _containerChecksInProgress. (-[WebNetscapePluginView _webPluginContainerCancelCheckIfAllowedToLoadRequest:]): Added. WebPluginContainerCheck automatically calls this method after invoking our _containerCheckResult: selector. It works this way because calling -[WebPluginContainerCheck cancel] allows it to do it's teardown process. (-[WebNetscapePluginView fini]): Release _containerChecksInProgress ivar. * Plugins/WebPluginContainerCheck.h: Removed initWithRequest: method from header; no client was using this method directly. * Plugins/WebPluginContainerCheck.mm: (+[WebPluginContainerCheck checkWithRequest:target:resultObject:selector:controller:contextInfo:]): Added optional contextInfo parameter. (-[WebPluginContainerCheck _continueWithPolicy:]): If there's a contextInfo object, pass it as a parameter to resultSelector. (-[WebPluginContainerCheck cancel]): Release _contextInfo ivar. (-[WebPluginContainerCheck contextInfo]): Added new method. Returns the contextInfo object, if one so exists. * Plugins/WebPluginController.mm: (-[WebPluginController _webPluginContainerCheckIfAllowedToLoadRequest:inFrame:resultObject:selector:]): Pass nil for contextInfo. WebKit-style plug-ins do not need additional context information. 2009-04-25 Brady Eidson Reviewed by Sam Weinig Some *obvious* style cleanup in my last patch. * History/WebBackForwardList.mm: (bumperCarBackForwardHackNeeded): 2009-04-25 Brady Eidson Reviewed by Oliver Hunt BumperCar 2.2 crashes going back (invalid WebHistoryItem) BumperCar was holding a pointer to a WebHistoryItem they never retain, then later tried to go to it. In some cases it would be dealloc'ed first. When WebHistoryItems were pure Objective-C they probably got away with this more often. With the WebCore/Obj-C mixed WebHistoryItems it's more likely to crash. * History/WebBackForwardList.mm: (bumperCarBackForwardHackNeeded): (-[WebBackForwardList backListWithLimit:]): If this is BumperCar, hang on to the NSArray of WebHistoryItems until the next time this method is called. (-[WebBackForwardList forwardListWithLimit:]): Ditto. * Misc/WebKitVersionChecks.h: Added WEBKIT_FIRST_VERSION_WITHOUT_BUMPERCAR_BACK_FORWARD_QUIRK. 2009-04-24 Anders Carlsson Reviewed by Darin Adler. Fix . Make sure to keep an extra reference to the instance proxy in case the plug-in host crashes while we're waiting for a reply. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::destroy): 2009-04-24 Brady Eidson Reviewed by Dan Bernstein Currently working on a bug where a WebHistoryItem was being used after being dealloc'ed. I added this assertion to help catch the case as soon as it happens instead of random issues downstream. Figured it's worth checking in by itself. * History/WebHistoryItem.mm: (core): ASSERT that the WebCore::HistoryItem inside this WebHistoryItem is supposed to have this WebHistoryItem as a wrapper. 2009-04-23 Beth Dakin Reviewed by Darin Adler. Fix for REGRESSION (r36864-r36869): Dragging stocks widget scrollbar drags the whole widget Look for our new WebCore scrollbars in the WebHTMLView and add proper Dashboard regions for them. * WebView/WebView.mm: (-[WebView _addScrollerDashboardRegionsForFrameView:dashboardRegions:]): (-[WebView _addScrollerDashboardRegions:from:]): 2009-04-23 John Sullivan fixed Assertion failure after Reset Safari in new history-writing code Reviewed by Oliver Hunt * History/WebHistory.mm: (-[WebHistoryPrivate data]): Return nil immediately if there are no entries; this matches a recent Windows-platform fix. 2009-04-23 Dimitri Glazkov Reviewed by Darin Adler. https://bugs.webkit.org/show_bug.cgi?id=25313 Missing scroll bars in GMail. * WebView/WebDynamicScrollBarsView.m: (-[WebDynamicScrollBarsView updateScrollers]): Added check for the ScrollbarAlwaysOn scroll mode. 2009-04-23 Kevin Decker * Plugins/WebPluginContainerCheck.h: Fix the Tiger build. 2009-04-23 Anders Carlsson Reviewed by Geoffrey Garen. Fix Add a new m_inDestroy member variable. Set it to true when in destroy, and have all NPRuntime functions return false when m_inDestroy is true. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy): (WebKit::NetscapePluginInstanceProxy::destroy): (WebKit::NetscapePluginInstanceProxy::invoke): (WebKit::NetscapePluginInstanceProxy::invokeDefault): (WebKit::NetscapePluginInstanceProxy::construct): (WebKit::NetscapePluginInstanceProxy::getProperty): (WebKit::NetscapePluginInstanceProxy::setProperty): (WebKit::NetscapePluginInstanceProxy::removeProperty): (WebKit::NetscapePluginInstanceProxy::hasProperty): (WebKit::NetscapePluginInstanceProxy::hasMethod): (WebKit::NetscapePluginInstanceProxy::enumerate): 2009-04-23 David Hyatt Reviewed by Maciej. Fix for REGRESSION (42464): Hitting assertion when loading message in Mail + TOT WebKit Make the Mac platform the same as all the other platforms. Instead of (incorrectly) marking a FrameView for layout when its underlying document view changes, just mark the outermost frame view for layout when the WebView's size changes. * WebView/WebHTMLView.mm: (-[WebHTMLView _frameOrBoundsChanged]): (-[WebHTMLView addSuperviewObservers]): * WebView/WebView.mm: (-[WebView _boundsChanged]): (-[WebView removeSizeObservers]): (-[WebView addSizeObservers]): 2009-04-23 Kevin Decker Reviewed by Tim Hatcher. Second part of the fix for * Plugins/WebBaseNetscapePluginView.h: Make this class conform to WebPluginContainerCheckController * Plugins/WebBaseNetscapePluginView.mm: Likewise. (-[WebBaseNetscapePluginView _webPluginContainerCancelCheckIfAllowedToLoadRequest:]): Added skeleton method. * Plugins/WebPluginContainerCheck.h: Added protocol for * Plugins/WebPluginContainerCheck.mm: (-[WebPluginContainerCheck initWithRequest:target:resultObject:selector:controller:]): * Plugins/WebPluginController.h: Make this class conform to WebPluginContainerCheckController 2009-04-23 Kevin Decker Reviewed by Anders Carlsson. First part of * Plugins/WebBaseNetscapePluginView.h: Imported #WebNetscapeContainerCheckPrivate.h; Added two new method: checkIfAllowedToLoadURL:url:frame:callbackFunc: and cancelCheckIfAllowedToLoadURL: * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView checkIfAllowedToLoadURL:frame:callbackFunc:]): Added skeleton method, does nothing interesting yet. (-[WebBaseNetscapePluginView cancelCheckIfAllowedToLoadURL:]): Likewise. * Plugins/WebNetscapeContainerCheckPrivate.h: Added. * Plugins/WebNetscapeContainerCheckPrivate.mm: Added. (browserContainerCheckFuncs): Added. * Plugins/WebNetscapePluginView.h: Imported #WebNetscapeContainerCheckPrivate.h; * Plugins/WebNetscapePluginView.mm: Imported #WebNetscapeContainerCheckPrivate.h; added WKN_CheckIfAllowedToLoadURL and WKN_CancelCheckIfAllowedToLoadURL functions. (-[WebNetscapePluginView getVariable:value:]): Return vtable for container check functions. * Plugins/npapi.mm: (WKN_CheckIfAllowedToLoadURL): Added new private function. (WKN_CancelCheckIfAllowedToLoadURL): Ditto. 2009-04-22 Oliver Hunt Reviewed by Darin Adler. SAP: Prevent default on mouseDown does not stop iframe from capturing subsequent mouse moves Make mouseUP forward to the root view as we do for mouseMoves and mouseDragged:. * WebView/WebHTMLView.mm: (-[WebHTMLView mouseUp:]): 2009-04-22 Oliver Hunt Reviewed by Darin Adler. SAP: Prevent default on mouseDown does not stop iframe from capturing subsequent mouse moves Make mouseDragged forward to the root view as we do for mouseMoves. * WebView/WebHTMLView.mm: (-[WebHTMLView mouseDragged:]): 2009-04-22 Anders Carlsson Reviewed by Oliver Hunt. Fix When we're trying to instantiate a plug-in and the plug-in host has died, we need to invalidate the instance so that it doesn't stick around and do bad things. * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::instantiatePlugin): 2009-04-22 Sam Weinig Rubber-stamped by Darin Adler. Fix for Turn off Geolocation by default * Configurations/FeatureDefines.xcconfig: 2009-04-21 Dan Bernstein Reviewed by Jon Honeycutt. - Mac part of fixing for Action dictionary for policy decision is missing keys when full-page zoom is used * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::actionDictionary): Use absoluteLocation() instead of pageX() and pageY(), which are adjusted for zoom. 2009-04-21 Anders Carlsson Reviewed by Darin Adler and Kevin Decker. WebKit side of . When we call resize with an actual changed size, block until the plug-in host is done. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::resize): * Plugins/Hosted/WebHostedNetscapePluginView.h: * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView updateAndSetWindow]): * Plugins/Hosted/WebKitPluginHost.defs: 2009-04-17 Timothy Hatcher Change how sudden termination works with WebView teardown. Reviewed by Darin Adler. * WebCoreSupport/WebChromeClient.h: Remove disableSuddenTermination/enableSuddenTermination. * WebCoreSupport/WebChromeClient.mm: Ditto. * WebView/WebFrame.mm: (-[WebFrame _pendingFrameUnloadEventCount]): Ask the DOMWindow. * WebView/WebView.mm: (+[WebView canCloseAllWebViews]): Call DOMWindow::dispatchAllPendingBeforeUnloadEvents. (+[WebView closeAllWebViews]): Call DOMWindow::dispatchAllPendingUnloadEvents and call close on all the WebViews. (-[WebView _closeWithFastTeardown]): Remove code for unload event dispatch. (-[WebView _close]): Correct a comment. (+[WebView _applicationWillTerminate]): Call closeAllWebViews. * WebView/WebViewPrivate.h: Add canCloseAllWebViews and closeAllWebViews. 2009-04-21 Geoffrey Garen Reviewed by Mark Rowe. Tiger crash fix: Put VM tags in their own header file, and fixed up the #ifdefs so they're not used on Tiger. * ForwardingHeaders/wtf/VMTags.h: Copied from ForwardingHeaders/wtf/HashTraits.h. 2009-04-17 Anders Carlsson Reviewed by Sam Weinig. In the Cocoa event model, NPWindow's window field should be null * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCConvertPoint): Get the instance proxy and call it's convertPoint function. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::convertPoint): Call convertPoint on the plug-in view. * Plugins/Hosted/WebKitPluginClient.defs: Add PCConvertPoint. * Plugins/WebBaseNetscapePluginView.h: Add a declaration for convertFromX:andY:space:toX:andY:space:. * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView convertFromX:andY:space:toX:andY:space:]): Convert a point from one coordinate system to another. * Plugins/WebNetscapePluginEventHandler.h: * Plugins/WebNetscapePluginEventHandlerCarbon.h: * Plugins/WebNetscapePluginEventHandlerCarbon.mm: (WebNetscapePluginEventHandlerCarbon::drawRect): * Plugins/WebNetscapePluginEventHandlerCocoa.h: Add CGContextRef to drawRect. * Plugins/WebNetscapePluginEventHandlerCocoa.mm: (WebNetscapePluginEventHandlerCocoa::drawRect): Set the passed in context. * Plugins/WebNetscapePluginPackage.mm: (-[WebNetscapePluginPackage _tryLoad]): Add NPN_ConvertPoint to the browserFuncs vtable. * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView saveAndSetNewPortStateForUpdate:]): Only set the window for the Carbon event model. (-[WebNetscapePluginView restorePortState:]): It's OK for the window context to be null. (-[WebNetscapePluginView sendDrawRectEvent:]): Pass the CGContextRef to drawRect. * Plugins/npapi.mm: (NPN_ConvertPoint): Call the plug-in view method. 2009-04-20 Sam Weinig Rubber-stamped by Tim Hatcher. Add licenses for xcconfig files. * Configurations/Base.xcconfig: * Configurations/DebugRelease.xcconfig: * Configurations/FeatureDefines.xcconfig: * Configurations/Version.xcconfig: * Configurations/WebKit.xcconfig: 2009-04-20 Anders Carlsson Reviewed by Dan Bernstein. WebKit side of * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::keyEvent): Pass the event keyChar. (WebKit::NetscapePluginInstanceProxy::syntheticKeyDownWithCommandModifier): Ditto. (WebKit::NetscapePluginInstanceProxy::flagsChanged): Pass a 0 keyChar. * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView flagsChanged:]): Call NetscapePluginInstanceProxy::flagsChanged. * Plugins/Hosted/WebKitPluginHost.defs: Add a keyChar argument. 2009-04-19 Adele Peterson Reviewed by Darin Adler. Fix for REGRESSION: In Mail, Home and End do not scroll message If no scrolling occurs, call tryToPerform on the next responder. Then our WebResponderChainSink will correctly detect if no responders handle the selector. * WebView/WebFrameView.mm: (-[WebFrameView _scrollToBeginningOfDocument]): (-[WebFrameView _scrollToEndOfDocument]): (-[WebFrameView scrollToBeginningOfDocument:]): (-[WebFrameView scrollToEndOfDocument:]): (-[WebFrameView scrollLineUp:]): (-[WebFrameView scrollLineDown:]): 2009-04-19 David Kilzer Make FEATURE_DEFINES completely dynamic Reviewed by Darin Adler. Make FEATURE_DEFINES depend on individual ENABLE_FEATURE_NAME variables for each feature, making it possible to remove all knowledge of FEATURE_DEFINES from build-webkit. * Configurations/FeatureDefines.xcconfig: Extract a variable from FEATURE_DEFINES for each feature setting. 2009-04-18 Pierre d'Herbemont Reviewed by Mark Rowe. video.buffered and video.seekable are not the same. video.buffered should return only what is buffered and not what is seekable * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Add wkQTMovieMaxTimeSeekable. 2009-04-18 Pierre d'Herbemont Reviewed by Adele Peterson. work around QTKit no longer reaching QTMovieLoadStateComplete * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Init the new WKSI exported symbol. 2009-04-17 Anders Carlsson Reviewed by Dan Bernstein. REGRESSION (Safari 3-4): Edit menu commands (cut/copy/paste/select all) do not work on Flash content * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::syntheticKeyDownWithCommandModifier): Send a keyDown event to the plug-in host. * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView sendModifierEventWithKeyCode:character:]): Call the plug-in instance proxy. * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView sendModifierEventWithKeyCode:character:]): Add this. Subclasses are required to override it. (-[WebBaseNetscapePluginView cut:]): (-[WebBaseNetscapePluginView copy:]): (-[WebBaseNetscapePluginView paste:]): (-[WebBaseNetscapePluginView selectAll:]): Call sendModifierEventWithKeyCode. * Plugins/WebNetscapePluginEventHandler.h: Add syntheticKeyDownWithCommandModifier. * Plugins/WebNetscapePluginEventHandlerCarbon.h: * Plugins/WebNetscapePluginEventHandlerCarbon.mm: (WebNetscapePluginEventHandlerCarbon::syntheticKeyDownWithCommandModifier): Send the synthetic event. * Plugins/WebNetscapePluginEventHandlerCocoa.h: * Plugins/WebNetscapePluginEventHandlerCocoa.mm: (WebNetscapePluginEventHandlerCocoa::syntheticKeyDownWithCommandModifier): Send the synthetic event. * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView sendModifierEventWithKeyCode:character:]): Call the event handler. 2009-04-17 David Kilzer Simplify FEATURE_DEFINES definition Reviewed by Darin Adler. This moves FEATURE_DEFINES and its related ENABLE_FEATURE_NAME variables to their own FeatureDefines.xcconfig file. It also extracts a new ENABLE_GEOLOCATION variable so that FEATURE_DEFINES only needs to be defined once. * Configurations/FeatureDefines.xcconfig: Added. * Configurations/WebKit.xcconfig: Removed definition of ENABLE_SVG_DOM_OBJC_BINDINGS and FEATURE_DEFINES. Added include of FeatureDefines.xcconfig. 2009-04-17 Anders Carlsson Reviewed by Darin Adler. Fix crashes seen in regression tests with hosted plug-ins. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::cancelStreamLoad): Check the stream for 0, not the stream ID. 2009-04-17 Darin Adler Reviewed by Antti Koivisto. Bug 25210: don't use ObjC methods to wrap/unwrap DOM objects with ObjC https://bugs.webkit.org/show_bug.cgi?id=25210 * DOM/WebDOMOperations.mm: (-[DOMNode markupString]): Use the core function instead of an Objective-C method. (-[DOMNode _subresourceURLs]): Ditto. (-[DOMDocument _focusableNodes]): Ditto. (-[DOMRange webArchive]): Ditto. (-[DOMRange markupString]): Ditto. * Misc/WebElementDictionary.mm: Added now-needed include since the core and kit functions now come from the internal headers from DOM bindings. * Misc/WebNSPasteboardExtras.mm: Ditto. * Plugins/WebNullPluginView.mm: Ditto. * Plugins/WebPluginController.mm: Ditto. * WebCoreSupport/WebChromeClient.mm: Ditto. * WebCoreSupport/WebInspectorClient.mm: Ditto. * WebCoreSupport/WebPasteboardHelper.mm: Ditto. * WebView/WebHTMLView.mm: Ditto. * WebCoreSupport/WebEditorClient.mm: Made kit function have internal linkage since it's only used in this file. Someone had instead added a declaration to suppress the warning you would otherwise get. Removed the core function. (WebEditorClient::textFieldDidBeginEditing): Added correct type checking. Previously the function would check only that something was an HTMLElement, but then cast it to HTMLInputElement. Also call kit instead of old wrap method. (WebEditorClient::textFieldDidEndEditing): Ditto. (WebEditorClient::textDidChangeInTextField): Ditto. (WebEditorClient::doTextFieldCommandFromEvent): Ditto. (WebEditorClient::textWillBeDeletedInTextField): Ditto. (WebEditorClient::textDidChangeInTextArea): Ditto, but for HTMLTextAreaElement. * WebView/WebFrame.mm: Removed the core and kit functions here which are no longer needed since they're automatically generated now. (-[WebFrame _nodesFromList:]): Use kit. (-[WebFrame _markupStringFromRange:nodes:]): Use core. (-[WebFrame _stringForRange:]): More of the same. (-[WebFrame _caretRectAtNode:offset:affinity:]): Ditto. (-[WebFrame _firstRectForDOMRange:]): Ditto. (-[WebFrame _scrollDOMRangeToVisible:]): Ditto. (-[WebFrame _rangeByAlteringCurrentSelection:SelectionController::direction:SelectionController::granularity:]): Ditto. (-[WebFrame _convertNSRangeToDOMRange:]): Ditto. (-[WebFrame _convertDOMRangeToNSRange:]): Ditto. (-[WebFrame _markDOMRange]): Ditto. (-[WebFrame _smartDeleteRangeForProposedRange:]): Ditto. (-[WebFrame _smartInsertForString:replacingRange:beforeString:afterString:]): Ditto. (-[WebFrame _documentFragmentWithMarkupString:baseURLString:]): Ditto. (-[WebFrame _documentFragmentWithNodesAsParagraphs:]): Ditto. (-[WebFrame _replaceSelectionWithNode:selectReplacement:smartReplace:matchStyle:]): Ditto. (-[WebFrame _characterRangeAtPoint:]): Ditto. (-[WebFrame _typingStyle]): Ditto. (-[WebFrame _setTypingStyle:withUndoAction:]): Ditto. (-[WebFrame _pauseAnimation:onNode:atTime:]): Ditto. (-[WebFrame _pauseTransitionOfProperty:onNode:atTime:]): Ditto. (-[WebFrame _replaceSelectionWithFragment:selectReplacement:smartReplace:matchStyle:]): Ditto. * WebView/WebFrameInternal.h: Removed the core and kit functions here which are no longer needed since they're automatically generated now. * WebView/WebHTMLRepresentation.mm: (-[WebHTMLRepresentation attributedStringFrom:startOffset:to:endOffset:]): Use core. (formElementFromDOMElement): Ditto. (inputElementFromDOMElement): Ditto. * WebView/WebTextIterator.mm: (-[WebTextIterator initWithRange:]): Ditto. (-[WebTextIterator currentRange]): Ditto. (-[WebTextIterator currentNode]): Ditto. * WebView/WebView.mm: (-[WebView textIteratorForRect:]): Ditto. (-[WebView setSelectedDOMRange:affinity:]): Ditto. 2009-04-17 Anders Carlsson Reviewed by Sam Weinig. WebKit side of . * Plugins/Hosted/HostedNetscapePluginStream.h: (WebKit::HostedNetscapePluginStream::create): New function that creates a stream from a frame loader. * Plugins/Hosted/HostedNetscapePluginStream.mm: (WebKit::HostedNetscapePluginStream::HostedNetscapePluginStream): Add the constructor that takes a frame loader. * Plugins/Hosted/NetscapePluginHostManager.h: * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::instantiatePlugin): Pass "fullFrame" to the plug-in host. * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCCancelLoadURL): Call NetscapePluginInstanceProxy::cancelStreamLoad. * Plugins/Hosted/NetscapePluginInstanceProxy.h: (WebKit::NetscapePluginInstanceProxy::create): Pass "fullFrame" to the constructor. (WebKit::NetscapePluginInstanceProxy::manualStream): New getter for the manual stream. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy): Take the implicit request into account if we have a full frame plug-in. (WebKit::NetscapePluginInstanceProxy::setManualStream): Setter for the manual stream. (WebKit::NetscapePluginInstanceProxy::cancelStreamLoad): Cancel the manual stream if necessary. * Plugins/Hosted/WebHostedNetscapePluginView.h: WebHostedNetscapePluginView now conforms to the WebPluginManualLoader protocol. * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView createPlugin]): Pass "fullFrame" to instantiatePlugin. (-[WebHostedNetscapePluginView pluginView:receivedResponse:]): (-[WebHostedNetscapePluginView pluginView:receivedData:]): (-[WebHostedNetscapePluginView pluginView:receivedError:]): (-[WebHostedNetscapePluginView pluginViewFinishedLoading:]): Call the equivalent manual stream functions. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::createPlugin): Use a macro for getting the plug-in view type. 2009-04-14 Simon Fraser Reviewed by Dan Bernstein https://bugs.webkit.org/show_bug.cgi?id=25157 Move the run loop observer cleanup from -close to -_close. * WebView/WebView.mm: (-[WebView _close]): (-[WebView close]): 2009-04-14 Anders Carlsson Reviewed by Sam Weinig. - Speculative fix for Protect the plug-in instance proxy in case it's deleted while waiting for a reply. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::wheelEvent): 2009-04-14 Adele Peterson Reviewed by Darin. Initialize WebKitSystemInterface in class methods that could get called before a WebView/WebFrame is set up. This was causing Mail to crash on launch. * Misc/WebCache.mm: (+[WebCache initialize]): * WebView/WebView.mm: (+[WebView initialize]): 2009-04-13 Kevin Decker Reviewed by Darin. REGRESSION: closing a tab containing a PDF causes world leaks Simplify the _trackFirstResponder method by just caching the value instead of retaining a Cocoa object. * WebView/WebPDFView.h: Eliminated trackedFirstResponder object and replaced it with a firstResponderIsPDFDocumentView boolean. * WebView/WebPDFView.mm: (-[WebPDFView dealloc]): Removed no longer necessary ASSERT. (-[WebPDFView viewWillMoveToWindow:]): Removed call to release and nil-out trackedFirstResponder, which no longer exists. In the new code all we do now is set firstResponderIsPDFDocumentView to NO. (-[WebPDFView _trackFirstResponder]): Rewrote this method to just cache the value instead of retaining an object. 2009-04-13 David Hyatt Reviewed by Sam Weinig. Fix for https://bugs.webkit.org/show_bug.cgi?id=25125. Rework scrolling so that a layout happens first when it's already needed so that the code doesn't end up making bad decisions based off invalid document sizes. This patch also eliminates WebHTMLView's separate notion of needing a layout and just consolidates it with WebCore's notion of needing layout. * WebView/WebDynamicScrollBarsView.m: (-[WebDynamicScrollBarsView updateScrollers]): * WebView/WebHTMLView.mm: (-[WebHTMLView _frameOrBoundsChanged]): (-[WebHTMLView initWithFrame:]): (-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]): (-[WebHTMLView setNeedsLayout:]): (-[WebHTMLView _layoutIfNeeded]): (-[WebHTMLView _needsLayout]): * WebView/WebHTMLViewInternal.h: 2009-04-13 Darin Adler * WebView/WebViewPrivate.h: Updated comments. 2009-04-13 Antti Koivisto Reviewed by Darin Adler. Increase the connection count per host * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): 2009-04-13 Brady Eidson Reviewed by Tim Hatcher Tweak my last check-in, moving the thread violation check up to the API-level calls so the logging is more useful to developers/users. * WebView/WebFrame.mm: (-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]): If not on the main thread, only perform the "call on main thead" workaround, as the log/exception raising is now up at the API level. (-[WebFrame loadData:MIMEType:textEncodingName:baseURL:]): Perform a thread violation check here so logging is more meaningful. (-[WebFrame loadHTMLString:baseURL:]): Ditto. (-[WebFrame loadAlternateHTMLString:baseURL:forUnreachableURL:]): Ditto. 2009-04-13 Brady Eidson Reviewed by Kevin Decker Garmin WebUpdater crashes * WebView/WebFrame.mm: (-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]): If not called on the main thread, add a ThreadViolationCheckRoundTwo() call to either log or raise an exception. In the case where it's only a log, reschedule the _loadData call to occur on the main thread. 2009-04-10 Dan Bernstein Reviewed by Jon Honeycutt. - fix Light blue-green background in content area in Mail * WebView/WebView.mm: (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]): Use device white, rather than calibrated white, as the default background color. 2009-04-10 Darin Adler Reviewed by Brady Eidson. crash in push_heap inside WebCore when printing The crash was due to manipulating a timer on a different thread than the one it was created on. * History/WebHistoryItem.mm: (-[WebWindowWatcher windowWillClose:]): Call later on main thread, if called on non-main thread. * WebView/WebHTMLView.mm: (-[WebHTMLView windowDidBecomeKey:]): Ditto. (-[WebHTMLView windowDidResignKey:]): Ditto. (-[WebHTMLView windowWillClose:]): Ditto. (-[WebHTMLView _updateControlTints]): Added. Factored out the non-thread-safe part of our override of _windowChangedKeyState. (-[WebHTMLView _windowChangedKeyState]): Call _updateControlTints later on main thread, if called on non-main thread. * WebView/WebPreferences.mm: (-[WebPreferences _postPreferencesChangesNotification]): Call later on main thread, if called on non-main thread 2009-04-10 Timothy Hatcher Remove DOMDocumentPrivate.h now that is fixed. Rubber-stamped by Mark Rowe. * Misc/DOMDocumentPrivate.h: Removed. 2009-04-10 Pierre d'Herbemont Reviewed by Adele Peterson. Avoid starting QTKitServer if possible Add the requires symbol in the WebSystemInterface. It is used by WebCore. * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Add wkQTIncludeOnlyModernMediaFileTypes. 2009-04-09 Kevin Decker Reviewed by Hyatt. tearing seen because deferred updates are disabled * WebView/WebFrameView.mm: (-[WebFrameView initWithFrame:]): Don't call WKDisableCGDeferredUpdates on post-Leopard if NSAppKitVersionNumberWithDeferredWindowDisplaySupport is defined. 2009-04-09 John Sullivan WebKit's support for SnowLeopard sudden termination for downloads is broken and should be removed Reviewed by Darin Adler * Misc/WebDownload.m: (-[WebDownloadInternal downloadDidBegin:]): remove disableSuddenTermination call (-[WebDownloadInternal downloadDidFinish:]): remove enableSuddenTermination call (-[WebDownloadInternal download:didFailWithError:]): remove enableSuddenTermination call 2009-04-09 Darin Adler Reviewed by Anders Carlsson and Sam Weinig. Part of Saving history containing 100,000 entries causes pauses of 2s while browsing Longer term solution is to change the design so Safari doesn't read and write all of history. This patch is step one: Do the serializing, which is done on the main thread, much faster. * History/WebHistory.mm: (-[WebHistoryPrivate data]): Added. Returns the NSData object containing serialized history. For creating new SPI so you can get the data in memory instead of on disk. Uses WebHistoryWriter. (-[WebHistoryPrivate saveToURL:error:]): Changed to call [self data (-[WebHistory _data]): Added. (WebHistoryWriter::WebHistoryWriter): Added. (WebHistoryWriter::writeHistoryItems): Added. * History/WebHistoryPrivate.h: Added a new _data method. 2009-04-09 Mike Thole Rubber-stamped by Mark Rowe. Fix 64-bit build * Panels/WebAuthenticationPanel.h: Declare the 'separateRealmLabel' IBOutlet as an NSTextField instead of 'id'. This fixes a duplicate method warning (setAutoresizingMask: on NSView and CALayer) 2009-04-09 Mike Thole Reviewed by Ada Chan. Basic authentication dialog spoofing vulnerability * Panels/WebAuthenticationPanel.h: Added IBOutlet for separateRealmLabel * Panels/WebAuthenticationPanel.m: (-[WebAuthenticationPanel setUpForChallenge:]): In the realm case, decide if it is a simple or complex realm name. A realm name is considered complex if it has any whitespace or newline characters. Present alternative text and layout for the complex case, where the realm name isn't inline with the rest of the sheet's text. * Panels/English.lproj/WebAuthenticationPanel.nib/designable.nib: * Panels/English.lproj/WebAuthenticationPanel.nib/keyedobjects.nib: Updated the nib with a new 'separateRealmLabel' outlet. Updated the File's Owner to correctly be WebAuthenticationPanel. Fixed springs on the sheet's icon to keep it from moving during a resize. 2009-04-09 David Kilzer Reinstating Option to turn off SVG DOM Objective-C bindings Rolled r42345 back in. The build failure was caused by an internal script which had not been updated the same way that build-webkit was updated. * Configurations/WebKit.xcconfig: * DOM/WebDOMOperations.mm: * MigrateHeaders.make: 2009-04-09 Alexey Proskuryakov Reverting Option to turn off SVG DOM Objective-C bindings. It broke Mac build, and I don't know how to fix it. * Configurations/WebKit.xcconfig: * DOM/WebDOMOperations.mm: * MigrateHeaders.make: 2009-04-08 David Kilzer Option to turn off SVG DOM Objective-C bindings Reviewed by Darin Adler and Maciej Stachowiak. Introduce the ENABLE_SVG_DOM_OBJC_BINDINGS feature define so that SVG DOM Objective-C bindings may be optionally disabled. * Configurations/WebKit.xcconfig: Added ENABLE_SVG_DOM_OBJC_BINDINGS variable and use it in FEATURE_DEFINES. * DOM/WebDOMOperations.mm: Removed unused header. * MigrateHeaders.make: Switched from using ENABLE_SVG to using ENABLE_SVG_DOM_OBJC_BINDINGS. 2009-04-08 David Hyatt Reviewed by Adam Roben and Darin Adler Fix for https://bugs.webkit.org/show_bug.cgi?id=12440, fixed positioned elements end up in inconsistent positions. Rewrite updateScrollers to improve the correctness. * WebView/WebDynamicScrollBarsView.h: * WebView/WebDynamicScrollBarsView.m: (-[WebDynamicScrollBarsView updateScrollers]): 2009-04-07 Anders Carlsson Fix Tiger build for real this time. * Plugins/WebNetscapePluginView.h: * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView getVariable:forURL:value:length:]): (-[WebNetscapePluginView setVariable:forURL:value:length:]): (-[WebNetscapePluginView getAuthenticationInfoWithProtocol:host:port:scheme:realm:username:usernameLength:password:passwordLength:]): * Plugins/npapi.mm: (NPN_GetValueForURL): (NPN_SetValueForURL): 2009-04-07 David Hyatt Reviewed by Adam Roben Mac portion of fix to make DumpRenderTree always produce accurate scrollbar results. Change updateScrollers to call minimumContentsSize when a WebHTMLView is inside the WebDynamicScrollbarsView. * WebView/WebDynamicScrollBarsView.m: (-[WebDynamicScrollBarsView updateScrollers]): 2009-04-07 Gustavo Noronha Silva Reviewed by Anders Carlsson. Trying to fix Tiger build. * Plugins/WebNetscapePluginView.h: * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView getAuthenticationInfoWithProtocol:host:port:scheme:realm:username:usernameLength:password:passwordLength:]): 2009-04-07 Anders Carlsson Try to fix the Leopard build once more. * Plugins/WebBaseNetscapePluginView.h: * Plugins/WebBaseNetscapePluginView.mm: * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView getVariable:forURL:value:length:]): 2009-04-07 Anders Carlsson ...and try to fix the Leopard build. * Plugins/npapi.mm: (NPN_GetAuthenticationInfo): 2009-04-07 Anders Carlsson Try to fix the Tiger build. * Plugins/WebBaseNetscapePluginView.mm: 2009-04-07 Anders Carlsson Reviewed by Sam Weinig. NPAPI: need NPN_Get/SetValueForURL() and NPN_GetAuthenticationInfo() * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCGetCookies): (WKPCGetProxy): (WKPCSetCookies): (WKPCGetAuthenticationInfo): New MIG functions to be used by the plug-in host. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::getCookies): (WebKit::NetscapePluginInstanceProxy::setCookies): (WebKit::NetscapePluginInstanceProxy::getProxy): (WebKit::NetscapePluginInstanceProxy::getAuthenticationInfo): Implement these. * Plugins/Hosted/WebKitPluginClient.defs: Add callbacks. * Plugins/WebBaseNetscapePluginView.h: * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView URLWithCString:]): Factor this out of URLWithCString. (-[WebBaseNetscapePluginView requestWithURLCString:]): Call URLWithCString. (WebKit::proxiesForURL): Return a string representation of proxies for a given URL. (WebKit::getAuthenticationInfo): Get the authentication info for a given host/protocol/scheme/realm/port combination. * Plugins/WebNetscapePluginPackage.mm: (-[WebNetscapePluginPackage _tryLoad]): Initialize the new vtable functions. * Plugins/WebNetscapePluginView.h: * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView getVariable:forURL:value:length:]): (-[WebNetscapePluginView setVariable:forURL:value:length:]): (-[WebNetscapePluginView getAuthenticationInfoWithProtocol:host:port:scheme:realm:username:usernameLength:password:passwordLength:]): Implement these. * Plugins/npapi.mm: (NPN_GetValueForURL): (NPN_SetValueForURL): (NPN_GetAuthenticationInfo): Call the plug-in view functions. 2009-04-03 Kevin Decker Reviewed by Anders Carlsson. * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::spawnPluginHost): Tweaked the visibleName property. 2009-04-03 John Sullivan Reviewed by Ada Chan Removing all icons can delete other items from disk. * Misc/WebIconDatabase.mm: (importToWebCoreFormat): When snooping around in various directories looking for a directory full of Safari-2-style icon database information to convert and delete, bail out without doing the delete part if we didn't actually find any Safari-2-style icon database information. 2009-04-03 John Sullivan fixed [WebView _setCacheModel:] leaks the result of _CFURLCacheCopyCacheDirectory Reviewed by Adam Roben * WebView/WebView.mm: (+[WebView _setCacheModel:]): use WebCFAutorelease rather than autorelease on result of method that returns CFStringRef 2009-04-03 Chris Marrin Reviewed by David Hyatt. Fixed https://bugs.webkit.org/show_bug.cgi?id=24941 This fix essentially does a -viewWillDraw call for layout. It adds a CFRunLoopObserver which performs layout just before drawing on the Mac platform. This makes sure layout is complete before rendering and avoids a flash. * WebCoreSupport/WebChromeClient.h: * WebCoreSupport/WebChromeClient.mm: (WebChromeClient::attachRootGraphicsLayer): (WebChromeClient::setNeedsOneShotDrawingSynchronization): (WebChromeClient::scheduleViewUpdate): * WebView/WebView.mm: (-[WebViewPrivate _clearViewUpdateRunLoopObserver]): (-[WebView _viewWillDrawInternal]): (-[WebView viewWillDraw]): (-[WebView close]): (viewUpdateRunLoopObserverCallBack): (-[WebView _scheduleViewUpdate]): * WebView/WebViewInternal.h: 2009-04-03 Anders Carlsson Reviewed by Kevin Decker. WebKit side of . Pass the clip rect to the plug-in host. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::resize): * Plugins/Hosted/WebKitPluginHost.defs: 2009-04-02 Mark Rowe Reviewed by Dan Bernstein and Timothy Hatcher. Crash in -[WebView removeSizeObservers] when loading NIB file The implementation of -[NSView initWithCoder:] can result in -viewWillMoveToSuperview:/-viewDidMoveToSuperview: being sent to our view before we've had a chance to initialize _private, so we need to ensure it is non-nil before dereferencing it in those methods. * WebView/WebView.mm: (-[WebView removeSizeObservers]): Nil-check _private before dereferencing it. (-[WebView addSizeObservers]): Ditto. 2009-04-02 Adele Peterson Reviewed by Darin Adler. Add a way to get a list of focusable nodes. * DOM/WebDOMOperations.mm: (-[DOMDocument _focusableNodes]): * DOM/WebDOMOperationsInternal.h: Added. * DOM/WebDOMOperationsPrivate.h: Make this a private header. Move old methods to WebDOMOperationsInternal.h * WebView/WebHTMLView.mm: Use methods from WebDOMOperationsInternal.h 2009-04-01 Darin Adler Reviewed by Geoff Garen. Bug 22378: Crash submitting a form when parsing an XHTML document https://bugs.webkit.org/show_bug.cgi?id=22378 rdar://problem/6388377 * History/WebHistoryItem.mm: (-[WebHistoryItem targetItem]): Call targetItem directly instead of callling isTargetItem, hasChildren, and recurseToFindTargetItem. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::dispatchWillSubmitForm): Updated for the new textFieldValues function in FormState. * WebView/WebPDFView.mm: (-[WebPDFView PDFViewWillClickOnLink:withURL:]): Updated for name and argument change of loadFrameRequest. 2009-04-01 Greg Bolsinga Reviewed by Mark Rowe. https://bugs.webkit.org/show_bug.cgi?id=24990 Put SECTORDER_FLAGS into xcconfig files. * Configurations/Base.xcconfig: * Configurations/DebugRelease.xcconfig: 2009-03-31 Anders Carlsson Reviewed by Adam Roben. WebKit side of . * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::wheelEvent): Send the event. * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView scrollWheel:]): Call NetscapePluginInstanceProxy::wheelEvent. If the plug-in processed the event, don't call super. * Plugins/Hosted/WebKitPluginHost.defs: Add definition. 2009-03-31 Darin Adler Reviewed by Adele Peterson. REGRESSION (r41793): Page Down and Page Up don’t work in Leopard Mail * WebView/WebHTMLView.mm: (-[WebResponderChainSink tryToPerform:with:]): Added. Without this we would think we had handled an event when we actually hadn't. Specifically, when -[WebFrameView scrollPageDown:] calls tryToPerform on the next responder. 2009-03-30 Greg Bolsinga Reviewed by Simon Fraser. https://bugs.webkit.org/show_bug.cgi?id=24938 Build fixes when building --no-svg DOMHTMLFrameElementPrivate.h and DOMHTMLIFrameElementPrivate.h are only available with ENABLE_SVG. * MigrateHeaders.make: 2009-03-29 Darin Adler Reviewed by Cameron Zwarich. * Plugins/WebNullPluginView.mm: Added now-needed includes. * WebView/WebHTMLRepresentation.mm: Ditto. * WebView/WebHTMLView.mm: Ditto. 2009-03-27 Timothy Hatcher * MigrateHeaders.make: Remove DOMHTMLBodyElementPrivate.h since it is not generated anymore. 2009-03-27 Adam Roben Don't include substitute data URLs in global history redirect chains Reviewed by Darin Adler. * WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::updateGlobalHistory): Don't call updateGlobalHistoryRedirectLinks. FrameLoader calls this for us now. (WebFrameLoaderClient::updateGlobalHistoryRedirectLinks): Added an assertion to help catch cases where we might be adding a substitute data URL into a redirect chain. 2009-03-27 Darin Adler Reviewed by Adam Roben. REGRESSION (r38629): Tab cycle in empty tab is broken * WebView/WebHTMLView.mm: (-[WebHTMLView _wantsKeyDownForEvent:]): Only return YES when we have a Frame. 2009-03-27 Darin Adler Reviewed by John Sullivan and Anders Carlsson. Pasteboard not exposed to WebEditingDelegate for WebViewInsertActionPasted (needed for system services) Added SPI to tell which pasteboard is currently being inserted. I chose to put it on WebView to be forward-looking since we're migrating things from WebHTMLView to WebView in the future. * WebView/WebHTMLView.mm: (-[WebHTMLView _pasteWithPasteboard:allowPlainText:]): Add calls to _setInsertionPasteboard. (-[WebHTMLView _pasteAsPlainTextWithPasteboard:]): Ditto. * WebView/WebView.mm: (-[WebViewPrivate dealloc]): Assert the pasteboard is nil. (-[WebViewPrivate finalize]): Ditto. (-[WebView _insertionPasteboard]): Return the pastebaord. (-[WebView _setInsertionPasteboard:]): Set the pasteboard. * WebView/WebViewInternal.h: Added _setInsertionPasteboard. * WebView/WebViewPrivate.h: Added _insertionPasteboard. 2009-03-25 Timothy Hatcher Expose new DOM methods as public Objective-C API. Expose new DOM classes and methods as public API (match the additions to the JavaScript DOM) Reviewed by Mark Rowe and Darin Adler. * MigrateHeaders.make: * Misc/DOMDocumentPrivate.h: Added. Forwarding header for . 2009-03-26 Jungshik Shin Reviewed by Alexey Proskuryakov. Add WebPreferences for encoding autodetection on Mac. http://bugs.webkit.org/show_bug.cgi?id=16482 * WebView/WebPreferenceKeysPrivate.h: * WebView/WebPreferences.mm: (+[WebPreferences initialize]): (-[WebPreferences usesEncodingDetector]): (-[WebPreferences setUsesEncodingDetector:]): * WebView/WebPreferencesPrivate.h: * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): 2009-03-26 Anders Carlsson Reviewed by Dan Bernstein. - Fix and . * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCInvalidateRect): Call NetscapePluginInstanceProxy::invalidateRect. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::cleanup): Stop the request timer, set m_pluginView to nil. (WebKit::NetscapePluginInstanceProxy::pluginHostDied): No need to set m_pluginView to nil here anymore, it's now done in cleanup(). (WebKit::NetscapePluginInstanceProxy::performRequest): (WebKit::NetscapePluginInstanceProxy::requestTimerFired): Assert that the plug-in view is not nil. (WebKit::NetscapePluginInstanceProxy::invalidateRect): Call setNeedsDisplayInRect here. 2009-03-25 Anders Carlsson Reviewed by Darin Adler. CrashTracer: [REGRESSION] 51 crashes in Safari at com.apple.WebKit • WebNetscapePluginStream::deliverData + 775 Don't release m_deliveryData since it's a RetainPtr. Also, use adoptNS instead of releasing newDeliveryData manually. * Plugins/WebBaseNetscapePluginStream.mm: (WebNetscapePluginStream::deliverData): 2009-03-25 Mike Thole Reviewed by Kevin Decker. call SetWindow when user creates a new tab CoreGraphics plug-ins now receive an NPP_SetWindow call when moving to a background tab. Flash is excluded from this change in behavior, as it has historical WebKit-specific code that isn't compatible with this change. * Plugins/WebNetscapePluginView.h: Added an _isFlash ivar. * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView _createPlugin]): Set the new _isFlash ivar based on the bundle identifier. (-[WebNetscapePluginView saveAndSetNewPortStateForUpdate:]): When using the CG drawing model and in a non-drawable state, set the portState to NULL and return early. (-[WebNetscapePluginView updateAndSetWindow]): When using the CG drawing model, call -setWindowIfNecessary even if the portState is NULL. Flash is an exception to this, due to its historical behavior. (-[WebNetscapePluginView setWindowIfNecessary]): Removed an assertion that was no longer true. The [NSView focus] view is no longer guaranteed to be 'self' at this point. Also modified the debug logging for CG plug-ins to include the size of the window's clipRect, which was useful in verifying the correct behavior of this patch. 2009-03-24 Dan Bernstein Reviewed by Oliver Hunt. - speculative fix for Crash at Editor::compositionRange() * WebView/WebHTMLView.mm: (-[WebHTMLView markedRange]): Null-check the Frame like most other methods in this class. 2009-03-23 Sam Weinig Reviewed by Dan Bernstein. Fix for Empty Caches does not clear the Cross-site XMLHttpRequest preflight cache * Misc/WebCache.mm: (+[WebCache empty]): 2009-03-23 Adele Peterson Reviewed by Mark Rowe & Dave Hyatt. Merge some of the individual Mail quirks into two settings that we can check for future quirks. * WebView/WebView.mm: (runningLeopardMail): (runningTigerMail): (-[WebView _preferencesChangedNotification:]): 2009-03-23 Darin Adler * WebView/WebTextIterator.h: Fixed a spelling error in a comment. 2009-03-22 Dan Bernstein Reviewed by John Sullivan. - fix Messages not displaying after the Safari 4 beta was installed Mail assumes that if -[WebArchive subresources] is not nil, then it contains at least one object. * WebView/WebArchive.mm: (-[WebArchive subresources]): Preserve the behavior of returning nil if there are no subresources. 2009-03-20 Adele Peterson Build fix. Reviewed by Darin Adler. * WebView/WebFrameView.mm: (-[WebFrameView initWithFrame:]): 2009-03-20 Timothy Hatcher Change how threading exceptions are checked so they are reported by what round they were added. That way WebKit can decided the behavior per-round based on linked-on-or-after checks. Reviewed by Darin Adler. * History/WebBackForwardList.mm: Use the new WebCoreThreadViolationCheckRoundOne macro. * History/WebHistoryItem.mm: Ditto. * Misc/WebIconDatabase.mm: Ditto. * WebView/WebArchive.mm: Use the new WebCoreThreadViolationCheckRoundTwo macro. * WebView/WebResource.mm: Ditto. (+[WebResource _needMailThreadWorkaroundIfCalledOffMainThread]): Check Mail's bundle version to truly decide if it is an old Mail client. * WebView/WebView.mm: Ditto. * Misc/WebKitVersionChecks.h: Add a new linked-on-or-after version define. * WebView/WebFrameView.mm: (-[WebFrameView initWithFrame:]): Set the default thread violation behavior per-round based on difference version checks and the Mail workaround check. 2009-03-20 Darin Adler Reviewed by Timothy Hatcher. * WebView/WebTextIterator.h: Improved comments to point out some of the pitfalls of this SPI. 2009-03-20 Darin Adler Reviewed by Adele Peterson. Use a better technique to handle finding out if something responds to a selector in WebHTMLView's doCommandBySelector method. * WebView/WebHTMLView.mm: (-[WebHTMLView doCommandBySelector:]): Removed unneeded check for 0 coreFrame; this is already handled by coreCommandBySelector: so doesn't need to be checked twice. Got rid of initial value for eventWasHandled boolean to make it more clear. Use WebResponderChainSink to find out if a command is handled rather than walking the responder chain explicitly. (-[WebResponderChainSink initWithResponderChain:]): Added. (-[WebResponderChainSink detach]): Added. (-[WebResponderChainSink receivedUnhandledCommand]): Added. (-[WebResponderChainSink noResponderFor:]): Added. (-[WebResponderChainSink doCommandBySelector:]): Added. 2009-03-19 Timothy Hatcher Remove #ifndef BUILDING_ON_TIGER around code that schedules runloop modes for Page, so the new RunLoopTimer in WebCore always gets a default mode. Fixes the layout test failures on the Tiger build bots. Reviewed by Mark Rowe. * WebView/WebView.mm: (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]): (-[WebView scheduleInRunLoop:forMode:]): (-[WebView unscheduleFromRunLoop:forMode:]): 2009-03-18 Anders Carlsson Reviewed by Oliver Hunt. WebKit side of . Try reinitializing the vendor port if it's invalid. * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::spawnPluginHost): 2009-03-18 Anders Carlsson Reviewed by Darin Adler. CrashTracer: [USER] 188 crashes in Safari at com.apple.WebCore • WTF::HashTableIterator, ... If the m_pluginView member was zeroed out as a result of making a call into the plug-in, the pluginFunctionCallDepth would be off causing the plug-in never to be stopped. Simplify the code by using a RAII object. * Plugins/WebBaseNetscapePluginStream.mm: (PluginStopDeferrer::PluginStopDeferrer): (PluginStopDeferrer::~PluginStopDeferrer): (WebNetscapePluginStream::startStream): (WebNetscapePluginStream::wantsAllStreams): (WebNetscapePluginStream::destroyStream): 2009-03-17 Darin Adler Reviewed by Adele Peterson. Need support for new move-left/right selectors. * WebView/WebHTMLView.mm: Added the four new selectors to the command-forwarding list. * WebView/WebView.mm: Ditto. 2009-03-17 Darin Adler Reviewed by Adele Peterson. Bug 24477: REGRESSION (r41467): Page Down key scrolls two pages https://bugs.webkit.org/show_bug.cgi?id=24477 rdar://problem/6674184 * WebView/WebHTMLView.mm: (responderChainRespondsToSelector): Added. (-[WebHTMLView doCommandBySelector:]): Set eventWasHandled based on whether we can find a responder that responds to this selector rather than always assuming the selector will not be handled. 2009-03-17 Mark Rowe Fix the build. * Plugins/Hosted/HostedNetscapePluginStream.mm: 2009-03-17 David Kilzer Use -[NSURLResponse(WebCoreURLResponse) _webcore_MIMEType] consistently Reviewed by Darin Adler. WebKit r30323 added -_webcore_MIMEType to fix issues with incorrect MIME types in NS[HTTP]URLResponse objects. However, uses of -[NSURLResponse MIMEType] still persist in WebKit that should be switched to use -_webcore_MIMEType. Note that -[WebDataSource _responseMIMEType] calls back into WebCore to get the MIME type from the ResourceResponse object, which has already retrieved it via -_webcore_MIMEType. * Plugins/Hosted/HostedNetscapePluginStream.mm: (WebKit::HostedNetscapePluginStream::didReceiveResponse): Use -_webcore_MIMEType. * Plugins/WebBaseNetscapePluginStream.mm: (WebNetscapePluginStream::didReceiveResponse): Ditto. * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView pluginView:receivedData:]): Ditto. * Plugins/WebPluginController.mm: (-[WebPluginController pluginView:receivedResponse:]): Ditto. * WebView/WebHTMLRepresentation.mm: (-[WebHTMLRepresentation _isDisplayingWebArchive]): Use -[WebDataSource _responseMIMEType] instead. * WebView/WebPDFRepresentation.m: (-[WebPDFRepresentation finishedLoadingWithDataSource:]): Ditto. * WebView/WebPDFView.mm: (-[WebPDFView menuForEvent:]): Ditto. 2009-03-17 Simon Fraser Reviewed by Darin Adler https://bugs.webkit.org/show_bug.cgi?id=24396 Add WTF_USE_ACCELERATED_COMPOSITING, defined to 0 for now. * WebKitPrefix.h: 2009-03-17 Kevin Ollivier Reviewed by Mark Rowe. Get BUILDING_ON_* defines from Platform.h. https://bugs.webkit.org/show_bug.cgi?id=24630 * WebKitPrefix.h: 2009-03-16 Darin Adler Reviewed by Dan Bernstein. Rename the text directionality submenus to “Paragraph Direction” and “Selection Direction” * WebCoreSupport/WebViewFactory.mm: (-[WebViewFactory contextMenuItemTagParagraphDirectionMenu]): Changed string here, but only post-Leopard, since we want this to match the Mac OS X menu on Tiger and Leopard. (-[WebViewFactory contextMenuItemTagSelectionDirectionMenu]): Changed string here. 2009-03-16 Anders Carlsson Reviewed by Oliver Hunt. Don't mig_deallocate random data in case an instance proxy method returns false. * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCEvaluate): (WKPCInvoke): (WKPCInvokeDefault): (WKPCGetProperty): (WKPCEnumerate): 2009-03-16 Anders Carlsson Reviewed by Oliver Hunt. REGRESSION (Safari 4 PB): Many crashes in Flip4Mac involving loading the plugin Defer loading while calling webPlugInInitialize since it can end up spinning the run loop. * Plugins/WebPluginController.mm: (-[WebPluginController addPlugin:]): 2009-03-16 Anders Carlsson Reviewed by Sam Weinig. Fix Make sure to update both the window frame and the plug-in frame. * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView addWindowObservers]): 2009-03-15 Dan Bernstein Reviewed by Adele Peterson. - fix WebKit should support the "Default" paragraph writing direction -- or at least validate the menu item appropriately Made WebHTMLView validate user interface items with the selector -makeBaseWritingDirectionNatural: by returning NO and, if the item is a menu item, setting its state to "off". Strictly speaking, since -makeBaseWritingDirectionNatural: is never valid for WebViews, WebHTMLView should not need to respond to it and validate it, however because other responders respond to all three -makeBaseWritingDirection*: messages and set the menu item state, having WebHTMLView do the same makes application developers' lives easier. * WebView/WebHTMLView.mm: (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]): (-[WebHTMLView makeBaseWritingDirectionNatural:]): 2009-03-13 Mark Rowe Rubber-stamped by Dan Bernstein. Take advantage of the ability of recent versions of Xcode to easily switch the active architecture. * Configurations/DebugRelease.xcconfig: 2009-03-13 Anders Carlsson Reviewed by Kevin Decker and Geoffrey Garen. REGRESSION (Safari 3-4): Tiger-only Crash occurs at WebView hostWindow () after reloading a set of tabs then quitting When we're doing fast teardown, plug-in views can be destroyed from -[WebView dealloc]'s [super dealloc] call, and thus calling -[WebView hostWindow] will crash since _private is nil. * WebView/WebView.mm: (-[WebView hostWindow]): 2009-03-13 Anders Carlsson And yet another attempt... * Plugins/WebNetscapePluginEventHandlerCocoa.h: (WebNetscapePluginEventHandlerCocoa::installKeyEventHandler): (WebNetscapePluginEventHandlerCocoa::removeKeyEventHandler): * Plugins/WebNetscapePluginEventHandlerCocoa.mm: 2009-03-13 Anders Carlsson Another attempt at fixing the build. * Plugins/WebNetscapePluginEventHandlerCocoa.mm: (WebNetscapePluginEventHandlerCocoa::WebNetscapePluginEventHandlerCocoa): 2009-03-13 Anders Carlsson Try to fix the SL build. * Plugins/WebNetscapePluginEventHandlerCocoa.h: * Plugins/WebNetscapePluginEventHandlerCocoa.mm: (WebNetscapePluginEventHandlerCocoa::keyDown): 2009-03-13 Greg Bolsinga Reviewed by Simon Fraser. Update Geolocation perimission dialogs to be asynchronous. https://bugs.webkit.org/show_bug.cgi?id=24505 WebGeolocation is a wrapper around WebCore::Geolocation. It mimics the coding style set by WebSecurityOrigin. WebChromeClient now calls the private UI delegate method -webView:frame:requestGeolocationPermission:securityOrigin: * WebCoreSupport/WebChromeClient.h: * WebCoreSupport/WebChromeClient.mm: (WebChromeClient::requestGeolocationPermissionForFrame): * WebCoreSupport/WebGeolocation.mm: Added. (WebCore::if): (-[WebGeolocation shouldClearCache]): (-[WebGeolocation setIsAllowed:]): (-[WebGeolocation dealloc]): * WebCoreSupport/WebGeolocationInternal.h: Added. * WebCoreSupport/WebGeolocationPrivate.h: Added. * WebView/WebUIDelegatePrivate.h: 2009-03-13 Anders Carlsson Reviewed by Dan Bernstein. Revise the Cocoa event model text API Replace the text input API with a simpler API that uses a separate text input window. * Plugins/WebNetscapePluginEventHandlerCocoa.h: * Plugins/WebNetscapePluginEventHandlerCocoa.mm: (WebNetscapePluginEventHandlerCocoa::WebNetscapePluginEventHandlerCocoa): Initialize m_keyEventHandler to 0. (WebNetscapePluginEventHandlerCocoa::keyDown): If the plug-in returns 0 from NPP_HandleEvent, pass the event to the TSM machinery. (WebNetscapePluginEventHandlerCocoa::focusChanged): Install/remove the key event handler as needed. (WebNetscapePluginEventHandlerCocoa::handleTSMEvent): Get the text and send a TextInput event. * Plugins/WebNetscapePluginView.h: * Plugins/WebNetscapePluginView.mm: Remove the old text input API. (-[WebNetscapePluginView inputContext]): Always return nil here. * Plugins/npapi.mm: * Plugins/nptextinput.h: Removed. 2009-03-12 Anders Carlsson Reviewed by Mike Thole and Mark Rowe. Fix . Make sure to process incoming messages for the NSEventTrackingRunLoopMode as well. * Plugins/Hosted/NetscapePluginHostProxy.mm: (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy): 2009-03-12 Anders Carlsson Reviewed by Geoffrey Garen. WebKit side of * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::destroy): Pass a requestID to _WKPCDestroyPluginInstance and wait until we get a reply back. * Plugins/Hosted/WebKitPluginHost.defs: Add requestID parameter. 2009-03-12 Kevin Decker Reviewed by Anders Carlsson. * Plugins/WebNetscapePluginPackage.mm: (-[WebNetscapePluginPackage _unloadWithShutdown:]): Simply a small SUPPORT_CFM code block. 2009-03-12 Kevin Decker Reviewed by Anders Carlsson. Fixed: Opening a subclassed NSWindow from a Safari plugin causes Safari to crash on Quit This fix addresses crashes in both Silverlight and ChemDraw. This type of crash would occur because AppKit still had a reference to open windows that the plugin created (which no longer exist). * Plugins/WebNetscapePluginPackage.mm: (-[WebNetscapePluginPackage _unloadWithShutdown:]): Do not unload the plug-in bundle on browser shutdown. 2009-03-11 David Kilzer Remove duplicate header include Rubber-stamped by Mark Rowe. * WebView/WebView.mm: Remove duplicate #include . Also realphabetized lowercase #include statements. 2009-03-11 David Kilzer Clarify comments regarding order of FEATURE_DEFINES Rubber-stamped by Mark Rowe. * Configurations/WebKit.xcconfig: Added warning about the consequences when FEATURE_DEFINES are not kept in sync. 2009-03-11 Anders Carlsson Reviewed by Sam Weinig. WebKit side of . * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::instantiatePlugin): Pass the requestID to _WKPHInstantiatePlugin. * Plugins/Hosted/NetscapePluginHostProxy.mm: Pass the requestID to setCurrentReply. * Plugins/Hosted/NetscapePluginInstanceProxy.h: (WebKit::NetscapePluginInstanceProxy::setCurrentReply): Store the reply in a map with the requestID as the key. (WebKit::NetscapePluginInstanceProxy::waitForReply): Wait for a reply that matches the given requestID. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy): Initialize member variables. (WebKit::NetscapePluginInstanceProxy::~NetscapePluginInstanceProxy): Delete all requests. (WebKit::NetscapePluginInstanceProxy::print): Pass the requestID to _WKPHPluginInstancePrint. (WebKit::NetscapePluginInstanceProxy::loadRequest): Rename m_currentRequestID to m_currentURLRequestID. (WebKit::NetscapePluginInstanceProxy::processRequestsAndWaitForReply): Process requests until we find a reply with the right requestID. (WebKit::NetscapePluginInstanceProxy::createBindingsInstance): Pass a requestID to the _WKPH function. (WebKit::NetscapePluginInstanceProxy::nextRequestID): Ditto. * Plugins/Hosted/ProxyInstance.mm: Pass a requestID to the _WKPH functions. * Plugins/Hosted/WebKitPluginClient.defs: * Plugins/Hosted/WebKitPluginHost.defs: Add requestID parameters. 2009-03-11 Anders Carlsson Reviewed by Darin Adler. Fix . * Plugins/WebPluginContainerPrivate.h: 2009-03-10 Xan Lopez Build fix, no review. * WebView/WebFrame.mm: (-[WebFrame _smartDeleteRangeForProposedRange:]): 2009-03-09 Anders Carlsson Reviewed by Kevin Decker. WebKit side of * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCEnumerate): Call NetscapePluginInstanceProxy::enumerate. * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::enumerate): Enumerate the JS object and serialize its values. * Plugins/Hosted/ProxyInstance.h: * Plugins/Hosted/ProxyInstance.mm: (WebKit::ProxyInstance::getPropertyNames): Ask the plug-in host to get the property names and deserialize them. * Plugins/Hosted/WebKitPluginClient.defs: * Plugins/Hosted/WebKitPluginHost.defs: 2009-03-09 Simon Fraser Reviewed by Oliver Hunt and Cameron Zwarich https://bugs.webkit.org/show_bug.cgi?id=24440 The sublayer added to WebHTMLView to host accelerated compositing layers needs to be a subclass of NSView which allows context menu clicks through. * WebView/WebHTMLView.mm: (-[WebLayerHostingView rightMouseDown:]): (-[WebHTMLView attachRootLayer:]): 2009-03-08 Mark Rowe Reviewed by Oliver Hunt. Split ScrollAlignment and ScrollBehavior out of RenderLayer.h so that Frame.h no longer needs to include it. This cuts the size of the symbols for a debug build by around 3%. * Plugins/WebNetscapePluginView.mm: * WebView/WebFrame.mm: (-[WebFrame _scrollDOMRangeToVisible:]): (-[WebFrame _insertParagraphSeparatorInQuotedContent]): (-[WebFrame _replaceSelectionWithFragment:selectReplacement:smartReplace:matchStyle:]): * WebView/WebHTMLView.mm: (-[WebHTMLView jumpToSelection:]): (-[WebHTMLView centerSelectionInVisibleArea:]): 2009-03-07 Dan Bernstein Reviewed by Alexey Proskuryakov. - fix a bug where debug builds were clearing the HTML5 application cache on application termination * WebView/WebView.mm: (-[WebView _close]): Call -[WebCache setDisabled:YES] instead of -[WebCache empty]. 2009-03-06 Douglas R. Davidson Reviewed by Justin Garcia. https://bugs.webkit.org/show_bug.cgi?id=24108 Update spelling and grammar checking to use the new combined text checking (with automatic language identification) on Snow Leopard. * WebCoreSupport/WebEditorClient.h: * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::checkSpellingAndGrammarOfParagraph): 2009-03-05 Adele Peterson Reviewed by Darin Adler. Fix for https://bugs.webkit.org/show_bug.cgi?id=24079 REGRESSION (r39549): Page loads cannot be interrupted with Command-. or Escape Ctrl-tab shortcut doesn't switch tabs when focus is in text field * WebView/WebHTMLView.mm: (-[WebHTMLView doCommandBySelector:]): If WebKit does not support the command, we need to pass the selector to super. In this case, we'll consider the event not to be handled. This is not perfect because in theory, [super doCommandBySelector:] can do some action that would cause WebKit to need to consider the event handled. But in practice, I've found no example of that happening and causing broken behavior. 2009-03-04 Mark Rowe Reviewed by Dan Bernstein. Adoption of new Cocoa API for dictionary contextual menu * WebView/WebHTMLView.mm: (-[WebHTMLView _lookUpInDictionaryFromMenu:]): 2009-03-04 Adam Barth Reviewed by Alexey Proskuryakov. https://bugs.webkit.org/show_bug.cgi?id=24356 Fix WebKit style for allowUniversalAccessFromFileURLs. * WebView/WebPreferenceKeysPrivate.h: * WebView/WebPreferences.mm: (+[WebPreferences initialize]): (-[WebPreferences allowUniversalAccessFromFileURLs]): (-[WebPreferences setAllowUniversalAccessFromFileURLs:]): * WebView/WebPreferencesPrivate.h: * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): 2009-03-03 David Kilzer WebCore and WebKit should install the same set of headers during installhdrs phase as build phase Reviewed by Mark Rowe. The fix is to add INSTALLHDRS_COPY_PHASE = YES and INSTALLHDRS_SCRIPT_PHASE = YES to WebKit.xcconfig, then to make sure various build phase scripts work with the installhdrs build phase. * Configurations/Base.xcconfig: Defined REAL_PLATFORM_NAME based on PLATFORM_NAME to work around the missing definition on Tiger. * Configurations/WebKit.xcconfig: Added WEBCORE_PRIVATE_HEADERS_DIR variable to remove definition of UMBRELLA_FRAMEWORKS_DIR for Debug and Release builds in the Xcode project file. Added INSTALLHDRS_COPY_PHASE = YES and INSTALLHDRS_SCRIPT_PHASE = YES. 2009-03-03 David Kilzer Remove last vestiges of JAVASCRIPTCORE_PRIVATE_HEADERS_DIR from WebKit Reviewed by Adam Roben. Use of JAVASCRIPTCORE_PRIVATE_HEADERS_DIR was removed in r37465 since NPAPI headers had migrated from JavaScriptCore to WebCore before that. * Configurations/WebKit.xcconfig: Removed definition of JAVASCRIPTCORE_PRIVATE_HEADERS_DIR used in Production builds. 2009-03-03 Anders Carlsson Reviewed by Darin Adler. Fix . * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::instantiatePlugin): Create a new plug-in instance if the plug-in host has crashed. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::invalidate): Add a null check for the plug-in host proxy. 2009-03-02 Sam Weinig Reviewed by Mark Rowe. Enable Geolocation (except on Tiger and Leopard). * Configurations/WebKit.xcconfig: 2009-03-02 Anders Carlsson Reviewed by Dan Bernstein. WebKit part of . * Plugins/Hosted/NetscapePluginHostManager.h: * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::createPropertyListFile): Spawn the plug-in host and wait for it to create the property list. * Plugins/WebBasePluginPackage.mm: (-[WebBasePluginPackage createPropertyListFile]): Factor code out into a new method. (-[WebBasePluginPackage pListForPath:createFile:]): Call the newly added createPropertyListFile method. * Plugins/WebNetscapePluginPackage.mm: (-[WebNetscapePluginPackage createPropertyListFile]): Tell the plug-in host manager to create a property list file for us. 2009-03-02 Sam Weinig Reviewed by Geoffrey Garen. Fix for Add Geolocation support. This is not yet turned on for any Mac platform. Add SPI to ask the embedding application whether to allow Geolocation for an origin. * WebCoreSupport/WebChromeClient.h: * WebCoreSupport/WebChromeClient.mm: (WebChromeClient::shouldAllowGeolocationForFrame): * WebView/WebUIDelegatePrivate.h: 2009-03-02 Anders Carlsson Fix PowerPC build. * Plugins/WebNetscapePluginPackage.mm: (-[WebNetscapePluginPackage _tryLoad]): 2009-03-02 Anders Carlsson Reviewed by John Sullivan, Ada Chan. Factor loading code out into its own method and get rid of a bunch of gotos. * Plugins/WebNetscapePluginPackage.mm: (-[WebNetscapePluginPackage _tryLoad]): (-[WebNetscapePluginPackage load]): 2009-03-02 Anders Carlsson Build fix. * Plugins/WebNetscapeDeprecatedFunctions.h: 2009-03-02 Anders Carlsson Reviewed by John Sullivan. Rename WebNetscapePluginPackage.m to WebNetscapePluginPackage.mm * Plugins/WebNetscapePluginPackage.m: Removed. * Plugins/WebNetscapePluginPackage.mm: Copied from mac/Plugins/WebNetscapePluginPackage.m. 2009-03-01 Anders Carlsson Reviewed by Sam Weinig. WebKit side of Pass the visible name to the plug-in host. * Plugins/Hosted/NetscapePluginHostManager.mm: (WebKit::NetscapePluginHostManager::spawnPluginHost): 2009-02-27 Alice Liu Fix REGRESSION (r39185): adding ".jpeg" extension to images that already have .jpg extension Reviewed by Oliver Hunt. * WebView/WebHTMLView.mm: (-[NSString matchesExtensionEquivalent:]): (-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]): Relax the check for the proper extension to allow for known equivalents, special-cased in matchesExtensionEquivalent function. 2009-02-27 Anders Carlsson Reviewed by Geoffrey Garen. CrashTracer: [USER] 1 crash in Safari at com.apple.WebKit • WebKit::NetscapePluginInstanceProxy::addValueToArray + 55 Port the NPN_Evaluate code over from WebCore instead of using the frame loader. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::evaluate): 2009-02-27 Anders Carlsson Reviewed by Geoffrey Garen. WebKit side of . * Plugins/Hosted/NetscapePluginHostProxy.mm: (WKPCInvokeDefault): Make InvokeDefault async. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::addValueToArray): Handle passing NPObjects back to the plug-in host. * Plugins/Hosted/ProxyInstance.h: (WebKit::ProxyInstance::objectID): Add objectID getter. * Plugins/Hosted/WebKitPluginClient.defs: Make InvokeDefault a simpleroutine. 2009-02-27 Timothy Hatcher Fixes an exception by null checking the WebResource before adding it to the subresources array. Bug in [WebDataSource subresources] can throw an exception Reviewed by Geoff Garen and Anders Carlsson. * WebView/WebDataSource.mm: (-[WebDataSource subresources]): Null check the WebResource before adding it. 2009-02-27 Timothy Hatcher Adds a workaround for Automator creating a WebView from a secondary thread. REGRESSION (Safari 4 Beta): Automator crash on secondary thread beneath -[WebView initWithFrame:frameName:groupName:] Reviewed by Geoff Garen. * WebView/WebView.mm: (needsWebViewInitThreadWorkaround): Check for com.apple.Automator. 2009-02-27 Adam Barth Reviewed by Eric Seidel. Add a preference to reduce the power of file:// URLs. * WebView/WebPreferenceKeysPrivate.h: * WebView/WebPreferences.mm: (+[WebPreferences initialize]): (-[WebPreferences allowUniversalAccessFromFileUrls]): (-[WebPreferences setAllowUniversalAccessFromFileUrls:]): * WebView/WebPreferencesPrivate.h: * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): 2009-02-27 Simon Fraser Reviewed by Anders Carlsson https://bugs.webkit.org/show_bug.cgi?id=24242 setCursor(), and resetCursorRects() on Tiger, were using global, not local coordinates for elementAtPoint: * WebView/WebHTMLView.mm: (resetCursorRects): (setCursor): 2009-02-27 Adam Barth Reviewed by Eric Seidel. Add a preference to reduce the power of file:// URLs. * WebView/WebPreferenceKeysPrivate.h: * WebView/WebPreferences.mm: (+[WebPreferences initialize]): (-[WebPreferences allowUniversalAccessFromFileUrls]): (-[WebPreferences setAllowUniversalAccessFromFileUrls:]): * WebView/WebPreferencesPrivate.h: * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): 2009-02-26 Adele Peterson Reviewed by Geoff Garen. Fix for https://bugs.webkit.org/show_bug.cgi?id=24216 (REGRESSION r36919) Safari 4 Beta causes MSN Messenger's text entry field to lose focus after entering a message During a series of firstResponder changes, at some point while the WebHTMLView was losing first responder status, we incorrectly marked the page as active, and then when the WebHTMLView became first responder again, setActive did nothing. This change restores behavior from before r36919 to check if the WebHTMLView is in the middle of losing first responder when calling setActive. In addition to updating editing/selection/designmode-no-caret.html results, I also made sure the test cases that were fixed in r36919 and r38570 are still fixed. * WebView/WebHTMLView.mm: (-[WebHTMLView resignFirstResponder]): Keep track if we're in the process of resigning first responder. (-[WebHTMLView _isResigningFirstResponder]): Added. * WebView/WebHTMLViewInternal.h: * WebView/WebView.mm: (-[WebView _updateFocusedAndActiveStateForFrame:]): Don't set the page to be active if the document view is currently resigning first responder. 2009-02-25 Anders Carlsson Reviewed by Kevin Decker. Fix . * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::print): Ask the plug-in host to print, create a CGImage of the returned bytes and draw the image into the passed in context. * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView drawRect:]): When printing, call NetscapePluginInstanceProxy::print. * Plugins/Hosted/WebKitPluginHost.defs: 2009-02-19 Alexey Proskuryakov Reviewed by Darin Adler. https://bugs.webkit.org/show_bug.cgi?id=24024 REGRESSION (r39845): Assertion failure in -[WebHistoryItem dictionaryRepresentation] when archiving a submission to about:blank I don't know how to make an automated test for this bug. * History/WebHistory.mm: (-[WebHistory _visitedURL:withTitle:method:wasFailure:]): Account for the fact that HTTP method may be non-empty for non-HTTP requests. 2009-02-25 Chris Fleizach Reviewed by Beth Dakin. Naming change from Bug 24143: Crash occurs at WebCore::AccessibilityTable::isTableExposableThroughAccessibility() when applying a link in GMail https://bugs.webkit.org/show_bug.cgi?id=24143 * WebView/WebFrame.mm: (-[WebFrame _accessibilityTree]): 2009-02-25 Simon Fraser Build fix with ACCELERATED_COMPOSITING turned on. I missed a spot in my last commit in renaming to _stoppedAcceleratedCompositingForFrame: * WebView/WebHTMLView.mm: (-[WebHTMLView close]): 2009-02-25 Simon Fraser Reviewed by Dan Bernstein https://bugs.webkit.org/show_bug.cgi?id=23854 Make an observable property, _isUsingAcceleratedCompositing, on WebView that DumpRenderTree can use to specialize behavior. This is implemented via a count of Frames that are using accelerated compositing. * WebView/WebHTMLView.mm: (-[WebHTMLViewPrivate clear]): (-[WebHTMLView close]): (-[WebHTMLView attachRootLayer:]): (-[WebHTMLView detachRootLayer]): * WebView/WebView.mm: (+[WebView automaticallyNotifiesObserversForKey:]): (-[WebView _startedAcceleratedCompositingForFrame:]): (-[WebView _stoppedAcceleratedCompositingForFrame:]): (-[WebView _isUsingAcceleratedCompositing]): * WebView/WebViewInternal.h: * WebView/WebViewPrivate.h: 2009-02-24 Sam Weinig Reviewed by Geoffrey Garen. Related to Allow disabling javascript: urls. * WebView/WebView.mm: (-[WebView _setJavaScriptURLsAreAllowed:]): * WebView/WebViewPrivate.h: 2009-02-24 Mark Rowe Reviewed by Oliver Hunt. Rename AVAILABLE_AFTER_WEBKIT_VERSION_3_1 (etc.) to match the other macros * Carbon/CarbonUtils.h: * Carbon/HIWebView.h: * Plugins/WebPlugin.h: * Plugins/WebPluginViewFactory.h: * WebView/WebUIDelegate.h: 2009-02-24 Peter Ammon Reviewed by Mark Rowe. Fix Services can modify non-editable content in Safari * WebView/WebHTMLView.mm: (-[WebHTMLView validRequestorForSendType:returnType:]): Return self only if we can handle both the send and return type. We should also handle a nil send or return type by ignoring the argument and returning whether we can handle the other type passed in. 2009-02-23 Anders Carlsson Reviewed by Geoffrey Garen and Darin Adler. WebKit side of . Make sure to vm_deallocate all memory we get from MIG callbacks. * Plugins/Hosted/NetscapePluginHostProxy.mm: (DataDeallocator::DataDeallocator): (DataDeallocator::~DataDeallocator): Add a simple deallocator class. (WKPCStatusText): (WKPCLoadURL): (WKPCBooleanAndDataReply): (WKPCEvaluate): (WKPCGetStringIdentifier): (WKPCInvoke): (WKPCInvokeDefault): (WKPCConstruct): (WKPCSetProperty): Use the new deallocator class. 2009-02-23 Anders Carlsson Reviewed by Darin Adler. Fix . * Plugins/Hosted/NetscapePluginInstanceProxy.h: * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::insertText): Add insert text which just calls the new WKPH function. * Plugins/Hosted/WebHostedNetscapePluginView.mm: (-[WebHostedNetscapePluginView inputContext]): Get the input context from the shared input panel. (-[WebHostedNetscapePluginView keyDown:]): Let the shared input panel have a go at the event first. * Plugins/Hosted/WebKitPluginHost.defs: Add new InsertText function. 2009-02-23 Mark Rowe Fix the build after r41126. * Plugins/Hosted/NetscapePluginInstanceProxy.mm: (WebKit::NetscapePluginInstanceProxy::invoke): (WebKit::NetscapePluginInstanceProxy::invokeDefault): (WebKit::NetscapePluginInstanceProxy::construct): 2009-02-22 Dan Bernstein Reviewed by Darin Adler. - fix REGRESSION (r30741): Generic Sun Applet loading logo appears half off screen * WebCoreSupport/WebFrameLoaderClient.mm: Correct a copy & paste error in r30741, and assign the height value, rather than the width, to the "height" parameter. 2009-02-21 Anders Carlsson Fix build. * Plugins/Hosted/WebTextInputWindowController.m: 2009-02-20 Anders Carlsson Reviewed by Dan Bernstein. Add a shared floating text input window implementation, to be used by the hosted plug-in view. * Plugins/Hosted/WebTextInputWindowController.h: Added. * Plugins/Hosted/WebTextInputWindowController.m: Added. 2009-02-20 Kevin Decker Reviewed by andersca. Safari sometimes hangs in WKSetMetadataURL for several seconds after downloading a file Spawn a background thread for WKSetMetadataURL because this function will not return until mds has journaled the data we are trying to set. Depending on what other I/O is going on, it can take some time. * Misc/WebNSFileManagerExtras.m: Import pthread.h and FoundationExtras.h (setMetaData): Added. Calls WKSetMetadataURL(). (-[NSFileManager _webkit_setMetadataURL:referrer:atPath:]): Call setMetaData on a background thread 2009-02-19 Dan Bernstein Reviewed by Sam Weinig. - WebKit part of fixing https://bugs.webkit.org/show_bug.cgi?id=24027 Do not send loader callbacks during CSS styling * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): Reverted the iChat-specific quirk added in . 2009-02-18 Dan Bernstein Reviewed by Brady Eidson. - WebKit part of fixing Crash in iChat at CSSStyleSelector::adjustRenderStyle * WebView/WebView.mm: (-[WebView _preferencesChangedNotification:]): Activate the WebCore workaround for this crash in iChat. 2009-02-18 Anders Carlsson Reviewed by Sam Weinig. Fix for There's no need to call setDefersLoading here - we already defer anything a plug-in can do that would cause a load to begin. * Plugins/WebNetscapePluginView.mm: (-[WebNetscapePluginView sendEvent:isDrawRect:]): 2009-02-18 Adam Roben Add SPI to get WebKit's custom pointing-hand cursor Reviewed by John Sullivan. * WebView/WebView.mm: (+[WebView _pointingHandCursor]): Added. Returns the custom pointing-hand cursor that WebKit uses. * WebView/WebViewPrivate.h: Added +_pointingHandCursor. 2009-02-17 Eric Carlson Reviewed by Antti Koivisto. https://bugs.webkit.org/show_bug.cgi?id=23917 Allow a WebKit plug-in to act as a proxy for the