blob: 3a5c4b508eec94978fa6224b7135c2eb2389c764 [file] [log] [blame]
=== Start merge of feature-branch 2007-10-12 ===
2007-10-03 Andrew Wellington <proton@wiretapped.net>
Reviewed by Mark Rowe.
Mac build fix for issue introduced in r26027
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
2007-10-01 Eric Seidel <eric@webkit.org>
Reviewed by Oliver Hunt.
SVG Subresources will not be saved when creating WebArchives
http://bugs.webkit.org/show_bug.cgi?id=15280
Implement _subresourceURLs methods for more SVGElement types
more such methods will be needed as we add support for other
external references (such as use, mpath, tref, etc.)
* DOM/WebDOMOperations.mm:
(-[DOMSVGScriptElement _subresourceURLs]): added.
(-[DOMSVGCursorElement _subresourceURLs]): added.
(-[DOMSVGFEImageElement _subresourceURLs]): added.
2007-10-01 Eric Seidel <eric@webkit.org>
Reviewed by Oliver Hunt.
WebArchives do not embed stylesheets referenced by xml-stylesheeet
http://bugs.webkit.org/show_bug.cgi?id=15320
* DOM/WebDOMOperations.mm:
(-[DOMProcessingInstruction _stylesheetURL]): needed to access [[self sheet] href]
(-[DOMProcessingInstruction _subresourceURLs]): call and return _stylesheetURL
2007-10-01 Eric Seidel <eric@webkit.org>
Reviewed by Oliver Hunt.
* DOM/WebDOMOperations.mm: added DOMSVGElementImage _subresources implementation
(-[DOMNode _URLsFromSelectors:]): now handles DOMSVGAnimatedString return values
(-[DOMSVGImageElement _subresourceURLs]): added.
* MigrateHeaders.make: copies DOMSVG* headers into WebKit/PrivateHeaders
2007-10-01 Oliver Hunt <oliver@apple.com>
Reviewed by Mark.
Enable Experimental SVG features by default when building from Xcode
* Configurations/WebKit.xcconfig:
=== End merge of feature-branch 2007-10-12 ===
2007-10-11 Mark Rowe <mrowe@apple.com>
Reviewed by Tim Hatcher.
Fix for <rdar://problem/5488678>. Disable debugging symbols in production builds for 10.4
PowerPC to prevent a huge STABS section from being generated.
* Configurations/Base.xcconfig:
2007-10-10 Alice Liu <alice.liu@apple.com>
Reviewed by Geoff Garen.
Fixed <rdar://5464402> Crash when running fast/frames/onload-remove-iframe-crash.html in DRT
createFrame() now returns a RefPtr instead of a raw Frame pointer.
Making this change improves the way we handle frames on Windows WebKit.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createFrame):
2007-10-04 Beth Dakin <bdakin@apple.com>
Reviewed by John Sullivan.
Fix for <rdar://problem/5441823> REGRESSION (r25142, Tiger only):
Vertical scroll bar not redrawn properly when going back in history
(15033)
This fix if-defs r25142 to be Leopard-only since it causes
correctness issues on Tiger and does not seem to have any
performance impact on Tiger either.
* WebView/WebDynamicScrollBarsView.m:
(-[WebDynamicScrollBarsView setScrollBarsSuppressed:repaintOnUnsuppress:]):
(-[WebDynamicScrollBarsView reflectScrolledClipView:]):
2007-10-04 Mark Rowe <mrowe@apple.com>
Reviewed by Oliver.
Switch to default level of debugging symbols to resolve <rdar://problem/5488678>.
The "full" level appears to offer no observable benefits even though the documentation
suggests it be used for dead code stripping. This should also decrease link times.
* Configurations/Base.xcconfig:
2007-10-04 Adele Peterson <adele@apple.com>
Reviewed by Darin.
WebKit part of fix for <rdar://problem/5369017> REGRESSION: Can't tab to webview that doesn't have editable content
* WebView/WebHTMLView.mm: (-[WebHTMLView becomeFirstResponder]): Pass in the FocusDirection.
2007-10-04 Darin Adler <darin@apple.com>
* WebView/WebHTMLView.mm: (-[WebHTMLView _updateActiveState]):
Removed a bogus comment.
2007-10-02 Kevin Decker <kdecker@apple.com>
Reviewed by Mark Rowe.
Re-added _minimumRequiredSafariBuildNumber. It turns out older version of Safari still rely
on this method, so we need to keep it around at least until the next major Safari release.
* StringsNotToBeLocalized.txt:
* WebView/WebView.mm:
(+[WebView _minimumRequiredSafariBuildNumber]):
* WebView/WebViewPrivate.h:
2007-10-02 Kevin Decker <kdecker@apple.com>
Reviewed by John Sullivan.
<rdar://problem/5517710>
* WebView/WebView.mm: Removed -[WebView _minimumRequiredSafariBuildNumber] because newer
versions of Safari no longer use this method. This won't break existing Safaris because
they always use a respondsToSelector check before calling this.
* WebView/WebViewPrivate.h: Ditto.
2007-09-27 John Sullivan <sullivan@apple.com>
Reviewed by Ollie
- fixed <rdar://problem/5408186> REGRESSION (5522-5523.9): Safari leaks every browser window
The leak started occurring when we removed the code to clear the delegates and the host window
from Safari as part of the fix for 5479443. But it turns out that Safari code was masking a
bug here in WebView: setHostWindow:nil needs to be called before setting _private->closed to
YES, or it will do nothing at all, causing a world leak due to a circular reference between
the window and the WebView.
I toyed with a more complex fix, but this is the simplest one that retains the fix for 5479443
while otherwise restoring the code order to be as close as possible to what it was before
5479443 was fixed.
* WebView/WebView.mm:
(-[WebView _close]):
Moved the call that sets _private->closed to YES to be after the code that clears the delegates
and the host window. Added a comment about this order.
2007-09-27 Kevin Decker <kdecker@apple.com>
Rubber stamped by Darin.
<rdar://problem/5493093>
* WebKit.order: Added.
* WebKit.xcodeproj/project.pbxproj: We're changing from using an order file built by
another team to using one we actually check into our project repository. Linker settings for
Symbol Ordering Flags have been updated accordingly.
2007-09-26 Geoffrey Garen <ggaren@apple.com>
Reviewed by Adele Peterson.
Fixed <rdar://problem/5507476> Promote cache model SPI to API
Promoted cache model SPI to API. This was just a move, with some small
edits to the documentation (changing 'application' to 'WebView' in
some cases, since the interface is now per-WebView).
* WebView/WebPreferences.h:
* WebView/WebPreferences.m:
(-[WebPreferences setCacheModel:]):
(-[WebPreferences cacheModel]):
* WebView/WebPreferencesPrivate.h:
2007-09-24 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5498016> Photoshop CS3: Adobe Help Viewer 1.1 crashes in 9A553
WebKit started calling the mouseDidMoveOverElement delegate method with a nil dictionary in r14982.
We originally intended to call this delegate method sometimes with a nil dictionary, but due to
a bug dating back to WebKit 1.0 this delegate was never called with nil! Unfortunately we can't
start calling this with nil since it will break Adobe Help Viewer, and possibly other clients.
* WebView/WebView.mm:
(-[WebView _mouseDidMoveOverElement:modifierFlags:]):
2007-09-21 Kevin Decker <kdecker@apple.com>
* Plugins/WebBaseNetscapePluginView.mm: Build fix.
The first argument of aglChoosePixelFormat() has changed from const AGLDevice *gdevs on Tiger to
const void *gdevs on Leopard.
2007-09-20 Kevin Decker <kdecker@apple.com>
Reviewed by Darin Adler.
<rdar://problem/5493093>
Reduced launch time by lazily linking both the AGL and OpenGL frameworks until they are really needed.
* Plugins/WebBaseNetscapePluginView.mm: Soft link all AGL and OpenGL functions used by
WebBaseNetscapePluginView.
* WebKit.xcodeproj/project.pbxproj: Removed AGL and OpenGL from the project.
2007-09-20 John Sullivan <sullivan@apple.com>
Build fix for stoooopid old PPC gcc compiler
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::checkSpellingOfString):
replace perfectly valid ?: syntax with if/else
2007-09-19 John Sullivan <sullivan@apple.com>
Reviewed by Darin Adler.
- WebKit part of speculative fix for <rdar://problem/5490627>, about crashes constructing a
String using the values filled in by checkSpellingOfString()
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::checkSpellingOfString):
convert NSNotFound to -1, since WebCore code expects -1 for this purpose. We already do this
in checkGrammarOfString.
2007-09-19 Kevin Decker <kdecker@apple.com>
Reviewed by Darin Adler.
<rdar://problem/5491066> soft link Accelerate.framework
* Misc/WebGraphicsExtras.c:
(WebConvertBGRAToARGB): Improve launch time performance and reduce vsize
footprint by soft linking the Accelerate.framework.
* WebKit.xcodeproj/project.pbxproj: Remove no longer needed frameworks.
2007-09-18 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Fixed <rdar://problem/5490204> In some cases, WebKit can make the
Foundation disk cache way too big or way too small
Use the actual location of the foundation disk cache, rather than
the user's home directory, when determining how big to make it.
* WebView/WebView.mm:
(+[WebView _setCacheModel:]):
2007-09-17 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Fixed a hang due to an infinite script running in the window's unload
event handler, which may be the cause of <rdar://problem/5479443>
REGRESSION: Hang due to infinite JS recursion on close @ engadget.com
(onunload-based ad)
* WebView/WebUIDelegatePrivate.h: Added FIXME.
* WebView/WebView.h: Clarified headerdoc ambiguity about when delegate
methods stop firing.
* WebView/WebView.mm:
(-[WebView _close]): The fix: don't nil out our delegates until after
detaching the FrameLoader, because the act of detaching the FrameLoader
might fire important delegate methods, like webViewShouldInterruptJavaScript:.
Don't do other tear-down either, because the unload event handler needs
to run in a fully constructed page.
This change is fairly low risk because niling out our delegates is a
very recent, never-shipped feature in WebKit, so it's unlikely that any
apps rely on it in a crazy way.
2007-09-15 Darin Adler <darin@apple.com>
Reviewed by John Sullivan.
- fix <rdar://problem/5391540> REGRESSION: Can't drag images from Safari to applications
in the dock (Tiger Preview, others in Leopard)
* Misc/WebNSPasteboardExtras.mm:
(-[NSPasteboard _web_declareAndWriteDragImageForElement:URL:title:archive:source:]):
Re-implement code here that has been missing for the last couple of years since we
did some image refactoring. Was pretty easy now that we can freely call C++ code
in WebKit.
2007-09-14 Mark Rowe <mrowe@apple.com>
Build fix for Tiger.
* WebView/WebArchive.m:
(-[WebArchive initWithCoder:]): Use @catch(id) rather than @catch(...).
* WebView/WebPreferences.m:
(-[WebPreferences initWithCoder:]): Ditto.
* WebView/WebResource.mm:
(-[WebResource initWithCoder:]): Ditto.
(-[WebResource _initWithPropertyList:]): Ditto.
2007-09-14 Darin Adler <darin@apple.com>
Reviewed by Geoff Garen and Tim Hatcher.
- fixed <rdar://problem/5482745> initFromCoder: and initWithPropertyList: functions
should guard against incorrect types
* WebView/WebArchive.m:
(isArrayOfClass): Added helper function.
(-[WebArchive _initWithPropertyList:]): Tweaked function to remove the need for a
type cast.
(-[WebArchive initWithCoder:]): Added type checking for the main resource,
subresources array, and subframe archives array. Also replaced NS_DURING with @try.
* WebView/WebPreferences.m: (-[WebPreferences initWithCoder:]): Added type checking
for the identifier and the values dictionary, including ensuring that it's a mutable
dictionary.
* WebView/WebResource.mm:
(-[WebResource initWithCoder:]): Added type checking for all the fields.
(-[WebResource _initWithPropertyList:]): Added type checking for the NSURLResponse.
* WebKit.exp: Removed accidentally exported internal symbol; I checked and it's not
used anywhere.
2007-09-13 Darin Adler <darin@apple.com>
Reviewed by Oliver.
- fix <rdar://problem/5470457> REGRESSION: Input method inline hole is mishandled in text
<input> elements with maxlength limit
* WebView/WebHTMLView.mm:
(-[WebHTMLView _selectionChanged]): Tweaked code a bit.
(-[WebHTMLView markedRange]): Simplified logic, since markedTextNSRange works when there's
no composition range.
(-[WebHTMLView hasMarkedText]): Call directly to Editor instead of bridge.
(-[WebHTMLView unmarkText]): Call new confirmComposition to make it clear that this is
confirming text, not just unmarking it to discard it.
(extractUnderlines): Added. Converts directly from an NSAttributedString to the
CompositionUnderline vector that's used by WebCore.
(-[WebHTMLView setMarkedText:selectedRange:]): Changed to use the new setComposition.
(-[WebHTMLView insertText:]): Changed to use confirmComposition when appropriate, instead
of relying on special behavior of Editor::insertText.
(-[WebHTMLView _updateSelectionForInputManager]): Rewrote to use getCompositionSelection
and confirmCompositionWithoutDisturbingSelection.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
Removed obsolete markedTextAbandoned function.
2007-09-12 David Kilzer <ddkilzer@apple.com>
Rubber-stamped by Darin and reviewed by Adam.
Removed import of unused icon database headers.
* WebCoreSupport/WebFrameBridge.mm:
2007-09-11 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Remove the unused class_getMethodImplementation function.
* Misc/WebNSObjectExtras.h:
2007-09-11 Geoffrey Garen <ggaren@apple.com>
Reviewed by Oliver Hunt.
Fixed CFNetwork version check so it actually works.
* Misc/WebKitVersionChecks.h:
* WebView/WebView.mm:
(+[WebView _setCacheModel:]): Don't use NSVersionOfLinkTimeLibrary because
we don't link against CFNetwork directly, so it returns -1. Also, use
the proper hex encoding instead of decimal numbers.
2007-09-11 Darin Adler <darin@apple.com>
- redo fix for <rdar://problem/5472899> REGRESSION (TOT): Crash in FrameLoadDelegate loading stationery
* WebView/WebView.mm:
(getMethod): Added.
(-[WebView _cacheResourceLoadDelegateImplementations]): Use getMethod.
(-[WebView _cacheFrameLoadDelegateImplementations]): Ditto.
2007-09-11 Darin Adler <darin@apple.com>
Rubber-stamped by Dave Harrison.
* WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface):
Removed wkCreateURLPasteboardFlavorTypeName and wkCreateURLNPasteboardFlavorTypeName.
2007-09-11 Darin Adler <darin@apple.com>
Reviewed by Mark Rowe.
- fix <rdar://problem/5472899> REGRESSION (TOT): Crash in FrameLoadDelegate loading stationery
* Misc/WebNSObjectExtras.h:
(class_getMethodImplementation): Added.
(method_setImplementation): Added.
* WebView/WebHTMLView.mm: (+[WebHTMLViewPrivate initialize]):
* Carbon/HIViewAdapter.m: (+[HIViewAdapter bindHIViewToNSView:nsView:]):
Remove old-ObjC code path, since WebNSObjectExtras.h now implements everything we need.
* WebView/WebView.mm:
(-[WebView _cacheResourceLoadDelegateImplementations]): Don't bother doing a separate
respondsToSelector call, since class_getMethodImplementation will return 0 for selectors
that we don't respond to. The bug fix is to actually set the cached pointer to 0.
Also get rid of the unnecessary use of a macro; instead use the functions from
WebNSObjectExtras.h on Tiger and the appropriate function directly on Leopard.
(-[WebView _cacheFrameLoadDelegateImplementations]): Ditto.
2007-09-11 Darin Adler <darin@apple.com>
Reviewed by Sam, Ollie.
* WebView/WebView.mm: (+[WebView _setCacheModel:]): A slightly cleaner 64-bit
fix for the NSURLCache capacity code in this file.
2007-09-11 Darin Adler <darin@apple.com>
Rubber-stamped by Mark Rowe.
* Misc/WebNSPasteboardExtras.mm: Fix incorrect strings in my last check-in.
The strings I checked in were wrong and were breaking layout tests too.
These new ones match what WebKitSystemInterface was returning.
2007-09-10 Geoffrey Garen <ggaren@apple.com>
Fixed 64-bit build (I think).
* WebView/WebView.mm:
(max): Added. In 64-bit land, -diskCapacity magically starts returning
unsigned long instead of unsigned, so we define a custom max() that's
willing to compare unsigned to unsigned long.
2007-09-10 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
- <rdar://problem/5471082> Removing WebURLPboardType from headers broke SPI-using applications
Rolled out my fix for bug 4582212 and fixed it in a much simpler way.
* Misc/WebNSPasteboardExtras.h:
* Misc/WebNSPasteboardExtras.mm:
* WebCoreSupport/WebPasteboardHelper.mm:
* WebKit.exp:
* WebView/WebHTMLView.mm:
* WebView/WebView.mm:
Rolled out the new PasteboardType functions and changed the PboardType globals to be initialized
with constant values.
2007-09-10 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Always animate when calling _scrollTo.
* WebView/WebFrameView.mm:
(-[WebFrameView _scrollVerticallyBy:]):
(-[WebFrameView _scrollHorizontallyBy:]):
2007-09-08 Brady Eidson <beidson@apple.com>
Reviewed by Darin
<rdar://problem/5434431> - Asynchronous Icon Database
WebKit side of things
Mainly, there are Notifications WebKit has to listen for now that tell it when to either call back into WebCore
for some purpose or to send the webView:didReceiveIcon: delegate call
Many smaller tweaks as well.
* Misc/WebIconDatabase.h:
* Misc/WebIconDatabase.mm:
(defaultClient):
(-[WebIconDatabase init]):
(+[WebIconDatabase delayDatabaseCleanup]): Accessor so clients can prevent the thread from cleaning up the database
before they've done all their necessary retaining of icons.
(+[WebIconDatabase allowDatabaseCleanup]):
(-[WebIconDatabase removeAllIcons]):
(-[WebIconDatabase _isEnabled]):
(-[WebIconDatabase _sendNotificationForURL:]):
(-[WebIconDatabase _sendDidRemoveAllIconsNotification]):
(-[WebIconDatabase _databaseDirectory]):
(-[ThreadEnabler threadEnablingSelector:]): Quick and dirty class to enabled Cocoa multithreading
(+[ThreadEnabler enableThreading]):
(importToWebCoreFormat):
* Misc/WebIconDatabaseInternal.h: Expose the internal methods of WebIconDatabase that are required by WebIconDatabaseClient
* Misc/WebNSNotificationCenterExtras.h: Added. - Great utility class whose design was borrowed from Colloquy
that allows the posting of a Cocoa notification on the main thread from *any* thread
* Misc/WebNSNotificationCenterExtras.m: Added.
(-[NSNotificationCenter postNotificationOnMainThreadWithName:object:]):
(-[NSNotificationCenter postNotificationOnMainThreadWithName:object:userInfo:]):
(-[NSNotificationCenter postNotificationOnMainThreadWithName:object:userInfo:waitUntilDone:]):
(+[NSNotificationCenter _postNotificationName:]):
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidReceiveIcon): Send the webView:didReceiveIcon: delegate call
(WebFrameLoaderClient::registerForIconNotification):
* WebCoreSupport/WebIconDatabaseClient.h: Added.
* WebCoreSupport/WebIconDatabaseClient.mm: Added.
(WebIconDatabaseClient::performImport): Perform the Safari 2 icon import
(WebIconDatabaseClient::dispatchDidRemoveAllIcons): Send the NSNotification
(WebIconDatabaseClient::dispatchDidAddIconForPageURL): Ditto
* WebView/WebView.mm:
(-[WebView _receivedIconChangedNotification:]): Check and see if this notification is for this WebView's current URL by
calling back into the IconDatabase
(-[WebView _registerForIconNotification:]): Support for WebIconDatabaseClient
(-[WebView _dispatchDidReceiveIconFromWebFrame:]): Dispatch this delegate call as well as unregister for the notification
* WebView/WebViewInternal.h:
* WebKit.xcodeproj/project.pbxproj:
2007-09-07 Geoffrey Garen <ggaren@apple.com>
Suggested by Maciej Stachowiak.
Added wKiosk Browser to the browser list. Pretty sweet app.
* WebView/WebPreferences.m:
(cacheModelForMainBundle):
2007-09-07 Geoffrey Garen <ggaren@apple.com>
Build fix.
* WebView/WebView.mm:
(+[WebView _setCacheModel:]):
2007-09-05 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler, Maciej Stachowiak, Mark Rowe, Tim Hatcher.
Fixed <rdar://problem/5326009> Make non-browser WebKit clients have no
memory cache, or a very tiny one
High level explanation:
- Added SPI for specifying a cache model on a per-WebView basis.
(Hopefully, this will become API soon.) We balance competing
cache models simply by using the largest one that pertains at a
given time.
- Added heuristic for guessing a default cache model in WebViews
that don't specify one:
1) Default to DocumentViewer for apps linked on or after this
WebKit. Default to DocumentBrowser otherwise.
2) Assign specific defaults to well-known clients based on
bundle ID.
3) Grow the default to DocumentBrowser if a navigation takes
place.
- As a part of the DocumentBrowser & PrimaryWebBrowser settings:
1) Make the Foundation disk cache much much bigger than the
default 20MB, if space allows. (This is a hedge against a small
WebCore cache in DocumentBrowser mode, but also an all-around
win for page load speed.)
2) Scaled the Foundation memory cache's capacity with physical
RAM, just like we do with other caches. This is a small win on
low memory systems.
* Misc/WebKitSystemBits.h:
* Misc/WebKitSystemBits.m:
(WebMemorySize): Renamed from "WebSystemMainMemory."
(WebHomeDirectoryFreeSize): Added function to measure the free space
on the user's home directory. We use this as a factor in determining
the disk cache's cacpacity.
* Misc/WebKitVersionChecks.h: Support for linked on or after check.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::didPerformFirstNavigation): Implementation of
heuristic rule #3.
* WebView/WebPreferenceKeysPrivate.h:
* WebView/WebPreferences.m:
(cacheModelForMainBundle): Implementation of heuristic rule #2.
(-[NSMutableDictionary _web_checkLastReferenceForIdentifier:]): Added
notification for when a WebPreferences instance becomes inert. We use
this to shrink the cache model back down if possible. Moved this code
into a WebPreferences method, since it's not really a feature of
NSDictionary.
* WebView/WebPreferencesPrivate.h: SPI declarations.
* WebView/WebView.mm: Replaced manual notification posts with calls to
the _postPreferencesChangesNotification convenience method.
(-[WebView _preferencesChangedNotification:]): Merged dispersed code
for updating preferences-related settings into this one function. This
was needed for an earlier version of the patch, even though the
current version could probably do without it.
(+[WebView _preferencesChangedNotification:]): Added a class-level
listener for WebPreferences changes. This listener takes care of
modifying the class-level global cache model setting if necessary.
(+[WebPreferences standardPreferences]): Removed call to
_postPreferencesChangesNotification because the notification already
posts when you create the WebPreferences object. (I noticed this
inefficiency because my new _preferencesChangedNotification: method was
called excessively at startup.)
Also Added explicit tracking of WebPreferences clients, so we know when
a WebPreferences instance becomes inert:
(-[WebPreferences didRemoveFromWebView]):
(-[WebPreferences willAddToWebView]):
(+[WebView _setCacheModel:]): Translates a cache model into actual
settings in various APIs. Caches that have unbounded value grow
linearly relative to available space. Caches that have bounded value
grow inverse-squaredly relative to available space.
2007-09-05 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5443883> Uncaught Objective-C exceptions in WebKit clients lead to hard-to-diagnose crashes
Changed all the direct delegate calls to use helper functions that have direct access to
WebView's delegate objects. These helper methods will catch any ObjC exceptions and call
ReportDiscardedDelegateException to log the discarded exception. WebView's that have
catchesDelegateExceptions set to NO will not pay the cost of a @try/@catch. The delegate
forwarders also have the same behavior.
* Misc/WebKitLogging.h:
* Misc/WebKitLogging.m:
(ReportDiscardedDelegateException):
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView loadPluginRequest:]):
* Plugins/WebNullPluginView.mm:
(-[WebNullPluginView viewDidMoveToWindow]):
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::createWindow):
(WebChromeClient::createModalDialog):
(WebChromeClient::runModal):
(WebChromeClient::toolbarsVisible):
(WebChromeClient::statusbarVisible):
(WebChromeClient::addMessageToConsole):
(WebChromeClient::canRunBeforeUnloadConfirmPanel):
(WebChromeClient::runBeforeUnloadConfirmPanel):
(WebChromeClient::runJavaScriptAlert):
(WebChromeClient::runJavaScriptConfirm):
(WebChromeClient::runJavaScriptPrompt):
(WebChromeClient::shouldInterruptJavaScript):
(WebChromeClient::setStatusbarText):
(WebChromeClient::print):
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::getCustomMenuFromDefaultItems):
(WebContextMenuClient::contextMenuItemSelected):
* WebCoreSupport/WebDragClient.mm:
(WebDragClient::startDrag):
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::textFieldDidBeginEditing):
(WebEditorClient::textFieldDidEndEditing):
(WebEditorClient::textDidChangeInTextField):
(WebEditorClient::doTextFieldCommandFromEvent):
(WebEditorClient::textWillBeDeletedInTextField):
(WebEditorClient::textDidChangeInTextArea):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge viewForPluginWithFrame:URL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
(WebFrameLoaderClient::assignIdentifierToInitialRequest):
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::willCacheResponse):
(WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
(WebFrameLoaderClient::dispatchDidHandleOnloadEvents):
(WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
(WebFrameLoaderClient::dispatchDidCancelClientRedirect):
(WebFrameLoaderClient::dispatchWillPerformClientRedirect):
(WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
(WebFrameLoaderClient::dispatchWillClose):
(WebFrameLoaderClient::dispatchDidReceiveIcon):
(WebFrameLoaderClient::dispatchDidStartProvisionalLoad):
(WebFrameLoaderClient::dispatchDidReceiveTitle):
(WebFrameLoaderClient::dispatchDidCommitLoad):
(WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebFrameLoaderClient::dispatchDidFailLoad):
(WebFrameLoaderClient::dispatchDidFinishDocumentLoad):
(WebFrameLoaderClient::dispatchDidFinishLoad):
(WebFrameLoaderClient::dispatchDidFirstLayout):
(WebFrameLoaderClient::dispatchCreatePage):
(WebFrameLoaderClient::dispatchUnableToImplementPolicy):
(WebFrameLoaderClient::dispatchWillSubmitForm):
(WebFrameLoaderClient::dispatchDidLoadMainResource):
* WebView/WebHTMLView.mm:
(-[WebHTMLView callDelegateDoCommandBySelectorIfNeeded:]):
(-[WebHTMLView validateUserInterfaceItem:]):
* WebView/WebPDFView.mm:
(-[WebPDFView validateUserInterfaceItem:]):
(-[WebPDFView PDFViewSavePDFToDownloadFolder:]):
* WebView/WebView.mm:
(-[WebView _openNewWindowWithRequest:]):
(-[WebView _menuForElement:defaultItems:]):
(-[WebView _mouseDidMoveOverElement:modifierFlags:]):
(-[WebView _cacheResourceLoadDelegateImplementations]):
(-[WebView _cacheFrameLoadDelegateImplementations]):
(-[WebView _policyDelegateForwarder]):
(-[WebView _UIDelegateForwarder]):
(-[WebView _editingDelegateForwarder]):
(-[WebView _scriptDebugDelegateForwarder]):
(-[WebView _setCatchesDelegateExceptions:]):
(-[WebView _catchesDelegateExceptions]):
(-[_WebSafeForwarder initWithTarget:defaultTarget:]):
(-[_WebSafeForwarder forwardInvocation:]):
(-[_WebSafeForwarder methodSignatureForSelector:]):
(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView validateUserInterfaceItem:]):
(-[WebView _headerHeight]):
(-[WebView _footerHeight]):
(-[WebView _drawHeaderInRect:]):
(-[WebView _drawFooterInRect:]):
(-[WebView _shouldChangeSelectedDOMRange:toDOMRange:affinity:stillSelecting:]):
(CallDelegate):
(CallDelegateReturningFloat):
(CallDelegateReturningBoolean):
(CallUIDelegate):
(CallUIDelegateReturningFloat):
(CallUIDelegateReturningBoolean):
(CallFrameLoadDelegate):
(CallResourceLoadDelegate):
(CallFormDelegate):
(CallFormDelegateReturningBoolean):
* WebView/WebViewInternal.h:
* WebView/WebViewPrivate.h:
2007-09-04 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5452908> NIBs saved in the Pre-10.2 format while Safari 3 installed do not work without Safari 3
This happened because we encoded a new field that the old WebKit does not know how to read.
And NSCoder throws an exception if initWithCoder finishes while there is still unread data in the archive.
The WebViewVersion is now 4 to distinguish that we do not encode/decode allowsUndo.
* WebView/WebView.mm:
(-[WebView initWithCoder:]): Only try to read allowsUndo if the version is 3.
(-[WebView encodeWithCoder:]): No longer encode allowsUndo.
2007-09-04 David Hyatt <hyatt@apple.com>
Fix for <rdar://problem/5271213>, resizing iChat window is slower than in
Tiger. This patch implements a fast scaling mode that can be used by
WebViews, e.g., during window resizing.
Reviewed by John Sullivan
* WebView/WebView.mm:
(-[WebView _setUseFastImageScalingMode:]):
(-[WebView _inFastImageScalingMode]):
* WebView/WebViewPrivate.h:
2007-09-04 Darin Adler <darin@apple.com>
Reviewed by Hyatt.
* WebView/WebView.mm:
(-[WebView _loadBackForwardListFromOtherView:]): Added missing null check.
(-[WebView _setInitiatedDrag:]): Ditto.
(-[WebView _clearUndoRedoOperations]): Ditto.
(-[WebView encodeWithCoder:]): Ditto.
(-[WebView backForwardList]): Ditto.
(-[WebView setMaintainsBackForwardList:]): Ditto.
2007-09-04 Tristan O'Tierney <tristan@apple.com>
Reviewed by John Sullivan.
<rdar://problem/5454935> Can't reply to this message in Mail -- -[DOMRange webArchive] is throwing an exception
* WebView/WebArchiver.mm:
(+[WebArchiver _archiveWithMarkupString:fromFrame:nodes:]):
Guard the creation of WebResource by ensuring that the passed in
responseURL is never nil.
2007-09-03 Mark Rowe <mrowe@apple.com>
Reviewed by Tim Hatcher.
<rdar://problem/5452164> Production build with in symbols directory has no debug info
Enable debug symbol generation on all build configurations. Production builds are stripped
of symbols by Xcode during deployment post-processing.
* Configurations/Base.xcconfig:
* WebKit.xcodeproj/project.pbxproj:
2007-09-02 Brady Eidson <beidson@apple.com>
Reviewed by John Sullivan and Mark Rowe
Groundwork for support for monitoring IconDatabase in-memory statistics
* Misc/WebCoreStatistics.h:
* Misc/WebCoreStatistics.mm:
(+[WebCoreStatistics iconPageURLMappingCount]):
(+[WebCoreStatistics iconRetainedPageURLCount]):
(+[WebCoreStatistics iconRecordCount]):
(+[WebCoreStatistics iconsWithDataCount]):
2007-09-01 Oliver Hunt <oliver@apple.com>
Reviewed by Sam.
<rdar://problem/5344848> IME is incorrectly used for key events when on non-editable regions
EditorClient::setInputMethodState stub
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::setInputMethodState):
2007-08-30 Maciej Stachowiak <mjs@apple.com>
Reviewed by Tim.
<rdar://problem/5439953> REGRESSION: Cannot load feeds in widgets in Dashcode due to change in WebKit delegate methods
* WebView/WebFrame.mm:
(-[WebFrame _attachScriptDebugger]): Don't create the debugger object if the frame has not yet
created its script interpreter, to avoid premature dispatch of windowScriptObjectAvailable/Cleared
delegate methods. The script debugger will be created in any case when the window object does appear.
2007-08-29 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
- fix <rdar://problem/4582212> WebKit inappropriately adds +initialize to
NSPasteboard via a category, prevents AppKit initialize
http://bugs.webkit.org/show_bug.cgi?id=9417
* Misc/WebNSPasteboardExtras.h: Got rid of the global data objects and replaced
them with global functions.
* Misc/WebNSPasteboardExtras.mm:
(initializePasteboardTypes): Changed the initialize method to be this function.
(WebURLPasteboardType): Added, calls the initialize function and then returns
the value of the global.
(WebURLNamePasteboardType): Ditto.
(+[NSPasteboard _web_writableTypesForURL]): Changed to call the new function instead
of getting at the global directly.
(+[NSPasteboard _web_dragTypesForURL]): Ditto.
(-[NSPasteboard _web_writeURL:andTitle:types:]): Ditto.
* WebCoreSupport/WebPasteboardHelper.mm:
(WebPasteboardHelper::urlFromPasteboard): Ditto.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]): Ditto.
* WebView/WebView.mm:
(+[WebView initialize]): Added a call to one of the functions to take advantage
of the side effect that initializes the globals; this is to help out old versions
of Safari.
(+[WebView URLTitleFromPasteboard:]): Changed to call the new function instead
of getting at the global directly.
* WebKit.exp: Add exports of the new functions.
2007-08-29 Adele Peterson <adele@apple.com>
Reviewed by Darin.
Fix for http://bugs.webkit.org/show_bug.cgi?id=15098
<rdar://problem/5440319> REGRESSION (9A530-9A534): Double scroll bar on pdfs
* WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::makeDocumentView):
Don't suppress scrollbars before the view creation if we're making the view for a non-html view
* WebView/WebFrameViewInternal.h: Make _scrollView return a WebDynamicScrollBarsView since so many clients were relying on it being that type anyway.
* WebView/WebFrameView.mm:
(-[WebFrameView _setDocumentView:]):
(-[WebFrameView _scrollView]):
(-[WebFrameView setAllowsScrolling:]):
(-[WebFrameView allowsScrolling]):
* WebView/WebView.mm:
(-[WebView setAlwaysShowVerticalScroller:]):
(-[WebView alwaysShowVerticalScroller]):
(-[WebView setAlwaysShowHorizontalScroller:]):
(-[WebView alwaysShowHorizontalScroller]):
2007-08-29 David Hyatt <hyatt@apple.com>
The method that was swizzled to fix 5441281 does not exist on Tiger.
Tiger has to do a double swizzle instead (of resetCursorRects and NSCursor's
set method) in order to roughly achieve the same effect.
Reviewed by darin
* WebView/WebHTMLView.mm:
(resetCursorRects):
(setCursor):
(+[WebHTMLViewPrivate initialize]):
2007-08-29 Anders Carlsson <andersca@apple.com>
Fix 64-bit build.
* WebCoreSupport/WebFrameBridge.mm:
2007-08-29 David Hyatt <hyatt@apple.com>
Fix for 5441281, remove our dependency on cursor rects and drag margins
in AppKit for a large performance boost on the PLT and iBench.
Reviewed by darin
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView sendNullEvent]):
(-[WebBaseNetscapePluginView mouseEntered:]):
(-[WebBaseNetscapePluginView mouseExited:]):
(-[WebBaseNetscapePluginView stop]):
Clean up cursor setting from Netscape plugins. Don't unconditionally mutate
the cursor when a plugin stops.
* WebView/WebFrameView.mm:
(-[WebFrameView _setDocumentView:]):
Suppress the resetting of drag margins while the new document view is being
added to the view hierarchy.
* WebView/WebHTMLView.mm:
(-[NSWindow _web_borderView]):
Expose the border view of the NSWindow so that it can be hit tested.
(setCursorForMouseLocation):
Apply a method swizzle to override the private AppKit method, _setCursorForMouseLocation.
We have to do this to suppress the cursor rect invalidation handling from resetting
the cursor for no reason.
The swizzle will do a hit test and allow the cursor set to occur if the mouse ends up
being over a plugin or over a view other than a WebHTMLView.
(+[WebHTMLViewPrivate initialize]):
The swizzle for setCursorForMouseLocation is set up here.
(-[WebHTMLView _frameOrBoundsChanged]):
Add a 100ms delay to the fake mouse moved event that fires when the view moves
under the mouse (without the mouse moving). This happens on iBench when the
pages get scrolled. By adding a delay we ensure that even with the mouse inside
the window, we don't experience cursor thrashing when pages are updating and
scrolling rapidly.
2007-08-28 Anders Carlsson <andersca@apple.com>
Reviewed by Darin.
<rdar://problem/5424866> Bottom portion of any Web Clip widget appears transparent
* WebCoreSupport/WebFrameBridge.mm:
Use the enum from FrameLoaderTypes.h.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::objectContentType):
Return ObjectContentNetscapePlugin and ObjectContentOtherPlugin depending on the plug-in type.
2007-08-28 Mark Rowe <mrowe@apple.com>
Reviewed by Maciej Stachowiak.
Fix fallout from the fix for <rdar://problem/5437983> (Loading history containing 100,000 entries adds 20s to Safari's startup)
in r25275. The array of entries for each day was being maintained in the reverse of the order that was expected.
* History/WebHistory.mm:
(-[WebHistoryPrivate insertItem:forDateKey:]): Maintain the array of entries in descending order.
2007-08-28 Mark Rowe <mrowe@apple.com>
Fix the buildbot build.
* History/WebHistory.mm:
(timeIntervalForBeginningOfDay): Explicitly cast to silence compiler warning.
2007-08-28 Mark Rowe <mrowe@apple.com>
Reviewed by Darin Adler.
<rdar://problem/5437983> Loading history containing 100,000 entries adds 20s to Safari's startup
Move WebHistoryItemPrivate from using a sorted array of NSCalendarDate's that map to a sorted array of arrays
of WebHistoryItem's over to using a HashMap of NSTimeIntervals and arrays of WebHistoryItems. NSTimeInterval
uses less memory and is substantially cheaper during comparisons than NSCalendarDate. The use of the HashMap
avoids the needs to repeatedly search within an array to locate the array that corresponds to the given days
history items.
The result of these changes is that loading 100,000 history items drops from around 25s to 1.6s. Loading
100 items drops from 0.003s to 0.002s.
* History/WebHistory.mm:
(-[WebHistoryPrivate init]):
(-[WebHistoryPrivate dealloc]):
(timeIntervalForBeginningOfDay): Return the NSTimeInterval representing the beginning of the specified day.
(-[WebHistoryPrivate findKey:forDay:]):
(-[WebHistoryPrivate insertItem:forDateKey:]): Perform a binary search within the day's history items rather than a linear search.
(-[WebHistoryPrivate _removeItemFromDateCaches:]):
(-[WebHistoryPrivate _addItemToDateCaches:]):
(-[WebHistoryPrivate removeAllItems]):
(-[WebHistoryPrivate orderedLastVisitedDays]): Generate and cache the sorted NSArray of NSCalendarDate's exposed in the API.
This cache is invalidated by _removeItemFromDateCaches: and _addItemToDateCaches: when needed.
(-[WebHistoryPrivate orderedItemsLastVisitedOnDay:]):
(-[WebHistoryPrivate arrayRepresentation]):
(-[WebHistoryPrivate _loadHistoryGutsFromURL:savedItemsCount:collectDiscardedItemsInto:error:]): Use an autorelease pool to keep the
number of live autoreleased objects generated to a reasonable level.
* History/WebHistoryItem.mm:
(-[WebHistoryItem initWithURLString:title:displayTitle:lastVisitedTimeInterval:]):
(-[WebHistoryItem initFromDictionaryRepresentation:]): Use the new HistoryItem constructor that accepts the alternate title
rather than setting it after construction. This prevents a modification notification from being sent for each WebHistoryItem that is loaded.
* History/WebHistoryItemInternal.h:
* History/WebHistoryPrivate.h:
* Misc/WebNSCalendarDateExtras.h: Removed as _webkit_compareDay: is no longer used.
* Misc/WebNSCalendarDateExtras.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
2007-08-28 Anders Carlsson <andersca@apple.com>
Reviewed by Darin.
<rdar://problem/5298296> XMLHttpRequest readyState 3 & responseText buffer issues
Expose WKSetNSURLRequestShouldContentSniff to WebCore.
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
2007-08-24 Kevin McCullough <kmccullough@apple.com>
Reviewed by Darin.
<rdar://problem/5437038> 1 credential object leaked for each call to credentialWithUser:password:persistence
- Use initWithUser instead of credentialWithUser because credentialWithUser leaks.
* Panels/WebAuthenticationPanel.m:
(-[WebAuthenticationPanel runAsModalDialogWithChallenge:]):
(-[WebAuthenticationPanel sheetDidEnd:returnCode:contextInfo:]):
2007-08-24 Adele Peterson <adele@apple.com>
Fix by Darin, reviewed by Adele.
Fix for <rdar://problem/5433422> Upon quitting, WebKit loads the WebPlugin shared database and immediately closes it
* Plugins/WebPluginDatabase.h: Added closeSharedDatabase, which won't create a new database if we're just trying to close it.
* Plugins/WebPluginDatabase.m: (+[WebPluginDatabase closeSharedDatabase]): Added.
* WebView/WebView.mm:
(-[WebView _close]): Call closeSharedDatabase.
(+[WebView _applicationWillTerminate]): Call closeSharedDatabase.
2007-08-24 Timothy Hatcher <timothy@apple.com>
Reviewed by John Sullivan.
<rdar://problem/5410937> HIWebView in SimpleCarbonWeb doesn't seem to be getting adequate invalidation when window is resized
This is a more localized fix for yesterday's change. Now explicitly call _web_layoutIfNeededRecursive inside the
HIWebView Draw() function. Adds a FIXME to explain that we need to do layout before Carbon has decided what regions to draw.
Doing layout in Draw() will potentially cause drawing to happen in two passes, but this has always been a problem in Carbon.
* Carbon/HIWebView.m:
(Draw): Call _web_layoutIfNeededRecursive on the main WebHTMLView.
(SetFocusPart): Fix to work in ObjC++ (now that HIWebView.m is treated as a ObjC++ file.)
* WebView/WebView.mm: Removes the 4 displayIfNeeded methods from yesterday's change.
* WebKit.xcodeproj/project.pbxproj: Force the file type of HIWebView.m to ObjC++ so WebHTMLViewInternal.h can be included.
2007-08-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Dave Hyatt.
<rdar://problem/5410937> HIWebView in SimpleCarbonWeb doesn't seem to be getting adequate invalidation when window is resized
The Carbon HIWebView was relying on layout happening when displayIfNeededInRect: was called on the WebView.
This would happen on Tiger because _recursiveDisplayRectIfNeededIgnoringOpacity: would always do a layout if needed.
Doing a layout in _recursiveDisplayRectIfNeededIgnoringOpacity was removed in Leopard in favor of viewWillDraw, and
the fact that adding new dirty rects inside _recursiveDisplayRectIfNeededIgnoringOpacity on Leopard will not
cause a drawRect in the same display loop.
So any client on Leopard calling displayIfNeeded* on the WebView would get a layout and any new dirty rects. So
_web_layoutIfNeededRecursive needs to be called on the main frame's WebHTMLView to make sure we layout and
display anything that is really needed.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _layoutIfNeeded]):
(-[WebHTMLView _web_layoutIfNeededRecursive]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebView.mm:
(-[WebView displayIfNeeded]): Call _web_layoutIfNeededRecursive on the main WebHTMLView.
(-[WebView displayIfNeededIgnoringOpacity]): Ditto.
(-[WebView displayIfNeededInRect:]): Ditto.
(-[WebView displayIfNeededInRectIgnoringOpacity:]): Ditto.
2007-08-22 Timothy Hatcher <timothy@apple.com>
Rolling out r25102 for <rdar://problem/5410937> until
<rdar://problem/5429920> is resolved.
* Carbon/CarbonUtils.m:
(WebInitForCarbon):
(PoolCleaner):
* Carbon/CarbonWindowAdapter.h:
* Carbon/CarbonWindowAdapter.m:
* Carbon/CarbonWindowContentView.h:
* Carbon/CarbonWindowContentView.m:
* Carbon/CarbonWindowFrame.h:
* Carbon/CarbonWindowFrame.m:
* Carbon/HIViewAdapter.h:
* Carbon/HIViewAdapter.m:
* Carbon/HIWebView.h:
* Carbon/HIWebView.m:
2007-08-20 John Sullivan <sullivan@apple.com>
Reviewed by Adam Roben
WebKit part of fix for:
<rdar://problem/5417777> WebKit focus ring color no longer matches system focus rings
* Misc/WebNSAttributedStringExtras.mm:
now includes <WebCore/ColorMac.h> to account for moved declaration
* WebView/WebFrame.mm:
ditto
* WebView/WebViewPrivate.h:
* WebView/WebView.mm:
(+[WebView _setUsesTestModeFocusRingColor:]):
new SPI, calls through to new WebCore function. This is used by DumpRenderTree to make sure the
focus ring color is always the same when performing layout tests, regardless of OS X version.
(+[WebView _usesTestModeFocusRingColor]):
new SPI, calls through to new WebCore function
2007-08-20 Antti Koivisto <antti@apple.com>
Reviewed by John.
Fix <rdar://problem/5378390>
Crash at Range::startContainer() when creating multiple ToDos on the same line
Null check range.
No layout test, this only happens with ObjC API.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _expandSelectionToGranularity:]):
2007-08-20 Maciej Stachowiak <mjs@apple.com>
Not reviewed, fix for crash on launch bug in last patch.
* WebView/WebHTMLView.mm:
(-[WebHTMLView setDataSource:]): Remove an assertion, fix code to work right in the
face of that condition.
2007-08-18 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- fixed <rdar://problem/5198272> REGRESSION: PLT 1.5% slower due to r21367 (change to start frames with empty documents)
There were three main cuases of extra time due to creating the initial empty document:
1) Creating an extra WebHTMLView and swapping it for a new one for each frame created.
2) Parsing the minimal markup for the initial document's contents.
3) Clearing the Window object an extra time and dispatching the corresponding delegate method.
The WebKit part of the fixes addresses 1.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::makeDocumentView): When switching from the initial
empty document to the first real document, reuse the WebHTMLView.
It might actually be a significant performance improvement to always
reuse the WebHTMLView, but that is a much riskier change and not
needed to fix the regression right now.
2007-08-17 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- WebKit part of fix to scrollbar suppression hack for Leopard
* WebView/WebDynamicScrollBarsView.m:
(-[WebDynamicScrollBarsView reflectScrolledClipView:]): Don't call the superclass method
when scrollbars are suppressed.
(-[WebDynamicScrollBarsView setScrollBarsSuppressed:repaintOnUnsuppress:]): Instead call it
here, when unsuppressing.
2007-08-17 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- fix <rdar://problem/5414518> Use root URL as origin URL when quarantining downloads
* WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::setOriginalURLForDownload):
Extract only the scheme and host name and make the originating URL from that.
* WebKit/StringsNotToBeLocalized.txt: Updated for recent changes.
2007-08-17 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5398301> Xcode threw mutation exception while enumerating subviews (GC only)
I was never able to reproduce this exception. But there can be cases where layout will
trigger JavaScript or plugin code that can modify the WebView view hierarchy during a
recursive enumeration of all the subviews.
This patch does two things:
1) Adds a check in debug builds that will LOG when any view is added or removed during layout.
Noting that added views will not recieve layout this round and might paint without first recieving layout.
2) Recursivly builds up an array of descendant WebHTMLViews before calling layout on them.
This matches the behavior of makeObjectsPerformSelector: in the non-GC case (making a copy
before enumerating.)
* WebView/WebHTMLView.mm:
(-[WebHTMLView _web_setPrintingModeRecursive]): Use _web_addDescendantWebHTMLViewsToArray to build up an array
of WebHTMLViews to enumerate.
(-[WebHTMLView _web_clearPrintingModeRecursive]): Ditto.
(-[WebHTMLView _web_setPrintingModeRecursiveAndAdjustViewSize]): Ditto.
(-[WebHTMLView _web_layoutIfNeededRecursive]): Ditto.
(-[WebHTMLView _layoutIfNeeded]): Moved to WebHTMLViewFileInternal category.
(-[WebHTMLView didAddSubview:]): LOG in debug builds.
(-[WebHTMLView willRemoveSubview:]): Ditto.
(-[NSView _web_addDescendantWebHTMLViewsToArray:]): Recursivly build an array of descendant WebHTMLViews.
* WebView/WebHTMLViewInternal.h: Added a BOOL in WebHTMLViewPrivate to track subview changes (debug only.)
2007-08-17 Anders Carlsson <andersca@apple.com>
Reviewed by Dave Hyatt.
<rdar://problem/5379040>
REGRESSION (Tiger-Leopard): ADOBE: Safari calls NPP_SetWindow with bad values sometimes
Pass the right size when creating the views.
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge viewForPluginWithFrame:URL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createPlugin):
2007-08-13 Geoffrey Garen <ggaren@apple.com>
Reviewed by Dave Hyatt.
WebKit changes to support new cache eviction model in WebCore.
* WebView/WebPreferences.m:
(+[WebPreferences initialize]): Modified to reflect new API in WebCore.
* WebView/WebView.mm:
(+[WebView _initializeCacheSizesIfNecessary]): Slightly increased cache
size on low memory systems to avoid affecting the PLT for now.
2007-08-15 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5410937> HIWebView in SimpleCarbonWeb doesn't seem to be getting adequate invalidation when window is resized
HIWebViewCreate now just returns a HIViewRef created with HICocoaViewCreate. This eliminates lots of old code and
makes HIWebView a better citizen starting with Leopard. The old code paths are still needed for Tiger, so now
most of the files in the WebKit/Carbon directory are #ifdef BUILDING_ON_TIGER.
The Tiger code is unchanged and dosen't exhibit the invalidation problem when the window resizes.
* Carbon/CarbonUtils.m:
(WebInitForCarbon): #ifdef BUILDING_ON_TIGER portions of this code that is not needed on Leopard.
* Carbon/CarbonWindowAdapter.h: #ifdef BUILDING_ON_TIGER
* Carbon/CarbonWindowAdapter.m: Ditto.
* Carbon/CarbonWindowContentView.h: Ditto.
* Carbon/CarbonWindowContentView.m: Ditto.
* Carbon/CarbonWindowFrame.h: Ditto.
* Carbon/CarbonWindowFrame.m: Ditto.
* Carbon/HIViewAdapter.h: Ditto.
* Carbon/HIViewAdapter.m: Ditto.
* Carbon/HIWebView.h: Consolidate two #ifdef __OBJC__ blocks into one.
* Carbon/HIWebView.m: Implement Leopard specific HIWebViewCreate, HIWebViewCreateWithClass and HIWebViewGetWebView.
(HIWebViewCreate): Call HIWebViewCreateWithClass passing [WebView class].
(HIWebViewCreateWithClass): Call HICocoaViewCreate with an instance of the class passed in.
(HIWebViewGetWebView): Call HICocoaViewGetView.
2007-08-14 Brady Eidson <beidson@apple.com>
Reviewed by Darin, John, Maciej, Oliver, and Tim
<rdar://problem/5394708> - Crash on launch with corrupt icon database
Expose some new SPI to help recover from this case should it happen again
* Misc/WebIconDatabase.mm:
(-[WebIconDatabase init]): Use the new _databaseDirectory to determine where to open the database on disk
(+[WebIconDatabase _checkIntegrityBeforeOpening]): Tell the icon database to check integrity when it opens
(-[WebIconDatabase _databaseDirectory]): Moved the database-directory-determining logic here as it's now used in two places
* Misc/WebIconDatabasePrivate.h: Added _checkIntegrityBeforeOpening SPI for clients to give hints about when the
integrity check should run
2007-08-12 Alexey Proskuryakov <ap@webkit.org>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=4648
Shockwave unable to load GZip'd text resources when server sends Content-Length header
* Plugins/WebBaseNetscapePluginStream.mm:
(-[WebBaseNetscapePluginStream startStreamWithResponse:]): Don't trust
-[NSURLResponse expectedContentLength] if Content-Encoding is not identity.
2007-08-10 Timothy Hatcher <timothy@apple.com>
Reviewed by Mark Rowe.
<rdar://problem/5403302> HIWebView.h should be #ifdefed out for 64-bit
* Carbon/HIWebView.h: #ifdef out the header in 64-bit. Adds a comment about 32-bit only.
* Carbon/CarbonUtils.h: Ditto.
2007-08-10 Timothy Hatcher <timothy@apple.com>
Reviewed by Adam.
<rdar://problem/5394449> Stop using some Carbon UI APIs for 64 bit
Disable NPObject use in 64-bit on Mac OS X. Also generate the 64-bit export file.
* Configurations/WebKit.xcconfig: Point to the generated 64-bit export file.
* Plugins/WebBasePluginPackage.h:
* Plugins/npfunctions.h: #ifdef out this header in 64-bit on Mac OS X.
* WebKit.LP64.exp: Removed.
* WebKit.xcodeproj/project.pbxproj: Generate the the 64-bit export file.
* WebKitPrefix.h: Define WTF_USE_NPOBJECT.
2007-08-10 Anders Carlsson <andersca@apple.com>
Reviewed by Geoff.
<rdar://problem/5390568>
REGRESSION: -[WebFrame loadHTMLString:baseURL:] leaks the data source
If the identifier is not in the map, just bail out instead of asserting. This is a better fix for
<rdar://problem/5133420> because WebCore shouldn't have to worry about the lifetime of WebKit objects.
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::decreaseLoadCount):
2007-08-10 Oliver Hunt <oliver@apple.com>
Reviewed by Darin.
Fixed <rdar://problem/5000470> REGRESSION: ATOK IM: reconvert returns incorrect symbol due to inconsistent range domains in TSM by working around <rdar://problem/5400551> [NSAttributedString(WebKitExtras) _web_attributedStringFromRange:] adds whitespace to the requested range
We truncate the returned string to the expected length.
* WebView/WebHTMLView.mm:
(-[WebHTMLView attributedSubstringFromRange:]):
2007-08-09 Mark Rowe <mrowe@apple.com>
Reviewed by Antti.
<rdar://problem/5400709> Versioning in debug and release builds should include minor and tiny version before +
* Configurations/Version.xcconfig:
* WebKit.xcodeproj/project.pbxproj: Add a shell script phase to make to dependency between
Version.xcconfig and Info.plist explicit to Xcode.
2007-08-08 Kevin Decker <kdecker@apple.com>
Reviewed by Anders Carlsson.
Fixed: <rdar://problem/5394449> Stop using some Carbon UI APIs for 64 bit
#ifdef'd out Netscape style plug-ins on 64-bit because Mac OS X doesn't support 64-bit Carbon UI.
* Plugins/WebBaseNetscapePluginStream.h:
* Plugins/WebBaseNetscapePluginStream.mm:
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.mm:
(+[WebBaseNetscapePluginView getCarbonEvent:]):
(TSMEventHandler):
* Plugins/WebBaseNetscapePluginViewInternal.h:
* Plugins/WebBaseNetscapePluginViewPrivate.h:
* Plugins/WebBasePluginPackage.m:
(+[WebBasePluginPackage pluginWithPath:]):
* Plugins/WebNetscapePluginEmbeddedView.h:
* Plugins/WebNetscapePluginEmbeddedView.mm:
* Plugins/WebNetscapePluginPackage.h:
* Plugins/WebNetscapePluginPackage.m:
* Plugins/WebNetscapePluginStream.h:
* Plugins/WebNetscapePluginStream.mm:
* Plugins/WebPluginDatabase.m:
(-[WebPluginDatabase pluginForKey:withEnumeratorSelector:]):
* Plugins/npapi.m:
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
* WebView/WebFrame.mm:
* WebView/WebFramePrivate.h:
* WebView/WebHTMLView.mm:
(-[NSArray _web_makePluginViewsPerformSelector:withObject:]):
* WebView/WebHTMLViewInternal.h:
2007-08-07 David Hyatt <hyatt@apple.com>
Fix a botched backout of the Quicktime plugin clipping fix that broke Java. The plugin view should not
be set to autosize with the parent view. Also, cleanup of script objects was removed accidentally as
well.
Reviewed by olliej
* Plugins/WebPluginController.mm:
(-[WebPluginController destroyPlugin:]):
(-[WebPluginController destroyAllPlugins]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge pluginViewWithPackage:attributeNames:attributeValues:baseURL:DOMElement:loadManually:]):
2007-08-03 Brady Eidson <beidson@apple.com>
Reviewed by Oliver
Fix for http://bugs.webkit.org/show_bug.cgi?id=14824 and <rdar://problem/5372989>
When unregistering a MIMEType, remove it from the WebCore registry unconditionally
When registrying a MIMEType whose view class is WebHTMLView, add it to the WebCore registry
* WebView/WebView.mm:
(+[WebView _unregisterViewClassAndRepresentationClassForMIMEType:]):
(+[WebView _registerViewClass:representationClass:forURLScheme:]):
(+[WebView registerViewClass:representationClass:forMIMEType:]):
2007-08-03 Timothy Hatcher <timothy@apple.com>
Reviewed by Mark Rowe.
Correct the bundle version check to work in Debug and Release builds too.
* WebKit.xcodeproj/project.pbxproj:
2007-08-02 Brady Eidson <beidson@apple.com>
Reviewed by Tim
<rdar://problem/5381463> - setMIMETypesShownAsHTML mutates while enumerating
* WebView/WebView.mm:
(+[WebView setMIMETypesShownAsHTML:]): Copy the dictionary before we work with it.
2007-08-02 Alice Liu <alice.liu@apple.com>
Reviewed by Kevin McCullough.
fixed <rdar://problem/5310312> REGRESSION: javascript is mis-escaped at http://labs.zarate.org/passwd causing bookmarklet to break
* Misc/WebNSURLExtras.mm:
(+[NSURL _web_URLWithUserTypedString:relativeToURL:]):
(-[NSURL _web_userVisibleString]):
(-[NSURL _web_URLWithLowercasedScheme]):
(-[NSURL _web_dataForURLComponentType:]):
These 4 changes are just casting changes.
(-[NSString _webkit_stringByReplacingValidPercentEscapes]):
This change replaces the call to an NSURL method with a webcore one that doesn't abort the escaping effort once an illegal character is encountered.
2007-08-01 Anders Carlsson <andersca@apple.com>
Fix build.
* Misc/WebNSURLExtras.mm:
(+[NSURL _web_URLWithUserTypedString:relativeToURL:]):
(-[NSURL _web_userVisibleString]):
(-[NSURL _web_URLWithLowercasedScheme]):
(-[NSURL _web_dataForURLComponentType:]):
2007-08-01 Alice Liu <alice.liu@apple.com>
Reviewed by .
Making WebNSURLExtras objc++
* Misc/WebNSURLExtras.m: Removed.
* Misc/WebNSURLExtras.mm: Copied from WebKit/Misc/WebNSURLExtras.m.
* WebKit.xcodeproj/project.pbxproj:
2007-08-01 Darin Adler <darin@apple.com>
Reviewed by Anders Carlsson and Kevin Decker.
- fix <rdar://problem/5377432> Removal of MakeDataExecutable from 64-bit breaks WebKit build
The trick was to ifdef out more of the code that's only needed to support CFM, which exists
only for 32-bit PowerPC.
* Plugins/WebNetscapePluginPackage.h: Define a SUPPORT_CFM symbol in this internal header when
we support CFM. We support it only on 32-bit PowerPC. Only define the isBundle, isCFM, and
connID fields when SUPPORT_CFM is on. Also use ResFileRefNum instead of SInt16.
* Plugins/WebNetscapePluginPackage.m: Only compile the function pointer and transition vector
functions when SUPPORT_CFM is on.
(-[WebNetscapePluginPackage openResourceFile]): Put the non-bundle case inside a SUPPORT_CFM
ifdef, since all non-CFM plug-ins are bundles.
(-[WebNetscapePluginPackage closeResourceFile:]): Ditto.
(-[WebNetscapePluginPackage _initWithPath:]): Use SUPPORT_CFM to compile out the code for
non-bundle and bundle-based CFM plug-ins, and code that sets isBundle and isCFM.
(-[WebNetscapePluginPackage executableType]): Put the CFM case inside SUPPORT_CFM.
(-[WebNetscapePluginPackage load]): Put the non-bundle and CFM cases inside SUPPORT_CFM.
There was a bit of dead code here.
(-[WebNetscapePluginPackage _unloadWithShutdown:]): Put the non-bundle case inside
SUPPORT_CFM.
2007-07-31 Timothy Hatcher <timothy@apple.com>
Reviewed by Oliver and Beth.
<rdar://problem/5211271> ADOBE Leopard 9A410: At the first Launching InDesign after deactivate, EULA page gets blanked.
Check for more Adobe applications that need the frame reload quirk. Also cache the answer
so the version check dosen't happen more than once.
* WebView/WebView.mm:
(-[WebView _needsAdobeFrameReloadingQuirk]):
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2007-07-30 Adele Peterson <adele@apple.com>
Reviewed by Oliver.
Fix for <rdar://problem/5308020> REGRESSION: Command-N with Dvorak-Qwerty keyboard layout stopped working inside web page text fields
* WebView/WebHTMLView.mm: (-[WebHTMLView _handleStyleKeyEquivalent:]):
The input method may have modified the character we get, so don't use charactersIgnoringModifiers to interpret the character we get.
2007-07-30 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- fixed <rdar://problem/5216176> Need WebKit SPI to allow clients using embedded WebViews to avoid
clipping ends of some printed pages
This provides Mail, and other clients that print views that embed WebViews, a way to ensure that
the HTML is laid out for printing before pagination occurs.
* WebView/WebHTMLViewPrivate.h:
new SPI method -_layoutForPrinting
* WebView/WebHTMLView.mm:
(-[WebHTMLView _web_setPrintingModeRecursiveAndAdjustViewSize]):
new method, just like existing _web_setPrintingModeRecursive except passes YES for adjustViewSize
(-[WebHTMLView _layoutForPrinting]):
new SPI method, sets printing mode temporarily to adjust the view size for printing
(-[NSView _web_setPrintingModeRecursiveAndAdjustViewSize]):
new helper method to do the recursion
2007-07-30 Adele Peterson <adele@apple.com>
Reviewed by Darin.
Fix for <rdar://problem/5367919> A crash occurs at WebCore::Frame::isFrameSet() when attempting to print a iframe before it loads at http://www.monster.com/
* WebView/WebHTMLView.mm: (-[WebHTMLView knowsPageRange:]): Nil check for frame.
2007-07-30 Anders Carlsson <andersca@apple.com>
Reviewed by Darin.
<rdar://problem/5370710>
REGRESSION: After switching from Bookmark view, the Find Banner won't appear while displaying a PDF file
Implement hasHTMLView.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::hasHTMLView):
2007-07-30 Justin Garcia <justin.garcia@apple.com>
Reviewed by Tristan.
<rdar://problem/5098931> Attachments are lost when they are moved into a ToDo after a delete
Mail needs to be asked if it is OK to do the content movement that happens
after a deleting in a situation like this one:
<div contenteditable="plaintext-only">foo</div><div>^bar</div>
so that they can prevent the move or so that they can save content that
will be stripped by the move. This could have been done with shouldInsertNode
and a new WebViewInsertAction for "moves", but WebKit clients like Mail and
DashCode think that a shouldInsert* means that the user pasted something and
perform actions only appropriate for pastes. This change is less risky because
it won't require those clients to change their code.
* DefaultDelegates/WebDefaultEditingDelegate.m:
(-[WebDefaultEditingDelegate webView:shouldMoveRangeAfterDelete:replacingRange:]):
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::shouldMoveRangeAfterDelete):
* WebView/WebEditingDelegatePrivate.h:
2007-07-29 Adele Peterson <adele@apple.com>
Reviewed by John.
WebKit part of fix for <rdar://problem/5102522> REGRESSION: Can't tab to webview that doesn't have editable content
* WebView/WebHTMLView.mm: (-[WebHTMLView becomeFirstResponder]): Call new setInitialFocus method instead of advanceFocus.
2007-07-27 Darin Adler <darin@apple.com>
- fix build
* WebKitPrefix.h: Removed the USING_WEBCORE_XXX definitions.
* WebView/WebHTMLView.mm:
(-[WebHTMLView delete:]): Fixed this to use WebCore again; I accidentally revived a dead
code path that didn't work in the last patch!
(-[WebHTMLView deleteToMark:]): Ditto.
(-[WebHTMLView copy:]): Removed the unused side of the ifdef.
(-[WebHTMLView cut:]): Ditto.
(-[WebHTMLView paste:]): Ditto.
2007-07-27 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher and Oliver Hunt.
- fix <rdar://problem/5355815> webView:doCommandBySelector: isn't getting called for copy:
Added code so that webView:doCommandBySelector: is called for every command.
* WebView/WebHTMLView.mm: Made 44 of the commands use the WEBCORE_COMMAND macro instead
of being handwritten. For all the others, added invocation of COMMAND_PROLOGUE macro at
the start of the command.
(-[WebHTMLView callDelegateDoCommandBySelectorIfNeeded:]): Added.
(-[WebHTMLView callWebCoreCommand:]): Added.
(-[WebHTMLView delete:]): Removed unused code path -- easy to bring back some day, but
we don't need it compiled in.
(-[WebHTMLView deleteBackwardByDecomposingPreviousCharacter:]): Changed so this doesn't
call deleteBackward: any more so we don't call the delegate two times.
(-[WebHTMLView deleteToMark:]): Changed so this doesn't call delete: any more so we don't
call the delegate two times.
(-[WebHTMLView selectToMark:]): Changed so this doesn't call setMark: any more so we don't
call the delegate two times.
(-[WebHTMLView doCommandBySelector:]): Added code to set the private variable
selectorForDoCommandBySelector. This allows callDelegateDoCommandBySelectorIfNeeded to
detect that we've already called the delegate and avoids calling it twice.
* WebView/WebHTMLViewInternal.h: Added the selectorForDoCommandBySelector field.
2007-07-26 Alexey Proskuryakov <ap@webkit.org>
Reviewed by Oliver.
http://bugs.webkit.org/show_bug.cgi?id=14733
Add a logging channel for text input
<rdar://problem/5364667>
* Misc/WebKitLogging.h:
* Misc/WebKitLogging.m:
(WebKitInitializeLoggingChannelsIfNecessary):
* WebView/WebHTMLView.mm:
(-[WebHTMLView validAttributesForMarkedText]):
(-[WebHTMLView textStorage]):
(-[WebHTMLView characterIndexForPoint:]):
(-[WebHTMLView firstRectForCharacterRange:]):
(-[WebHTMLView selectedRange]):
(-[WebHTMLView markedRange]):
(-[WebHTMLView attributedSubstringFromRange:]):
(-[WebHTMLView hasMarkedText]):
(-[WebHTMLView unmarkText]):
(-[WebHTMLView setMarkedText:selectedRange:]):
(-[WebHTMLView doCommandBySelector:]):
(-[WebHTMLView insertText:]):
2007-07-26 Darin Adler <darin@apple.com>
- fix Tiger build
* Misc/WebTypesInternal.h: For use inside the library, use NSInteger and
NSUInteger, just like on Leopard. WebNSInteger and WebNSUInteger are still
present, but they are used in public and private headers only.
* Carbon/CarbonWindowAdapter.m:
* Carbon/CarbonWindowFrame.m:
* DefaultDelegates/WebScriptDebugServer.m:
* History/WebBackForwardList.mm:
* Misc/WebDownload.m:
* Misc/WebSearchableTextView.m:
* Plugins/WebBaseNetscapePluginView.mm:
* WebCoreSupport/WebFrameLoaderClient.mm:
* WebView/WebHTMLView.mm:
* WebView/WebPDFView.mm:
* WebView/WebView.mm:
* WebView/WebViewInternal.h:
Update all implementation files and internal headers to use NSInteger and
NSUInteger rather than WebNSInteger and WebNSUInteger.
2007-07-26 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
- fixed <rdar://problem/5362989> Searching a pdf in some modes shows hilights for all instances
of the word, even those not on the current page
It turns out that there were three different issues here, all contributing to incorrect display
of multiple matches for PDF pages in certain display modes. (1) in non-continuous display modes,
we weren't updating the match rects when the displayed page is changed with page up/down (e.g.);
(2) the mechanism to update the match rects on scrolling was busted except for the first scroll
away from 0,0; (3) the PDFKit API returns selection bounds for non-displayed pages in non-continuous
modes just as if they were the displayed pages. This patch fixes all three issues.
* WebView/WebPDFView.h:
made ivar name even longer
* WebView/WebPDFView.mm:
(-[WebPDFView setPDFDocument:]):
updated for ivar name change
(-[WebPDFView viewDidMoveToWindow]):
observe page-change notifications as well as the others; this is necessary because in the
non-continuous modes the view can be completely updated without any scrolling involved (problem 1)
(-[WebPDFView viewWillMoveToWindow:]):
stop observing page-change notifications
(-[WebPDFView rectsForTextMatches]):
skip any pages that aren't visible; this avoids treating matches on non-displayed non-continous
modes as if they were on the displayed page (problem 3)
(-[WebPDFView _PDFDocumentViewMightHaveScrolled:]):
after checking whether scroll position has changed since we last checked it, remember the new
one (d'oh!) (problem 2)
(-[WebPDFView _scaleOrDisplayModeOrPageChanged:]):
renamed to include page changes
(-[WebPDFView _visiblePDFPages]):
new method, returns the set of pages that are at least partly visible
2007-07-24 Oliver Hunt <oliver@apple.com>
Reviewed by Adam and Justin.
<rdar://problem/5141779> WebView editableDOMRangeForPoint: & moveDragCaretToPoint: returns last position in DOMText range
editableDOMRangeForPoint:, moveDragCaretToPoint:, and removeDragCaret now call directly into
WebCore without relying on bridge look up through the now removed _bridgeAtPoint:.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebView.mm:
(-[WebView moveDragCaretToPoint:]):
(-[WebView removeDragCaret]):
(-[WebView editableDOMRangeForPoint:]):
2007-07-24 Kevin Decker <kdecker@apple.com>
Reviewed by Anders.
<rdar://problem/4699455> REGRESSION (Safari 2->Safari 3): Adobe Reader 7.0.8 plug-in doesn't work
* Plugins/WebNetscapePluginEmbeddedView.h: Added a #define that renames this class to "WebNetscapePluginDocumentView"
This is necessary because the Adobe 7.x Acrobat plug-in has a hard coded check for a view named "WebNetscapePluginDocumentView"
and will not function correctly if it doesn't find a view in the hierarchy without the old class name.
2007-07-24 Mark Rowe <mrowe@apple.com>
Reviewed by Antti.
<rdar://problem/5356666> NSMenuItem's seen leaking on buildbot
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::contextMenuItemSelected): Release platformItem as we were transferred its ownership by releasePlatformDescription.
2007-07-23 Oliver Hunt <oliver@apple.com>
Reviewed by Darin.
We have to be able to support insertText: followed by doCommandBySelector: in
order to support the 2- and 3-Set Korean and RuSwitcher IMs at least.
* WebView/WebHTMLView.mm:
(-[WebHTMLView insertText:]):
2007-07-23 Alice Liu <alice.liu@apple.com>
Reverting change 24535 now that a solution has been found that doesn't
involve exposing an interface unnecessarily.
* WebView/WebHTMLView.mm:
* WebView/WebHTMLViewPrivate.h:
2007-07-23 Alice Liu <alice.liu@apple.com>
Reviewed by Oliver Hunt.
Expose [WebHTMLView hasMarkedText] to
fix <rdar://problem/4830074> autocomplete breaks Japanese typing
* WebView/WebHTMLView.mm:
* WebView/WebHTMLViewPrivate.h:
2007-07-22 Darin Adler <darin@apple.com>
* StringsNotToBeLocalized.txt: Updated for recent changes.
2007-07-21 Adam Roben <aroben@apple.com>
Fix REGRESSION: Right-click/control-click broken
http://bugs.webkit.org/show_bug.cgi?id=14658
<rdar://problem/5346830>
Reviewed by Mitz.
* WebCoreSupport/WebContextMenuClient.mm:
(fixMenusToSendToOldClients): Update defaultItemsCount after removing
items from the defaultItems array.
2007-07-20 Oliver Hunt <oliver@apple.com>
Reviewed by Adele.
<rdar://problem/5319438> REGRESSION: Cannot paste into an active inline input area (14522)
http://bugs.webkit.org/show_bug.cgi?id=14522
AppKit sends noop: to -[WebHTMLView doCommandBySelector:] when an IM does not handle event,
we now check this as it is necessary to work around some IMs that do send messages
(such as insertText: rather than unmarkText: to confirm a composition)
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]):
(-[WebHTMLView doCommandBySelector:]):
* WebView/WebHTMLViewInternal.h:
2007-07-20 Brady Eidson <beidson@apple.com>
Reviewed by Adele and Andersca
<rdar://problem/5336105> - WebBackForwardList created from scratch is unusable (always leads to crash)
* History/WebBackForwardList.mm:
(-[WebBackForwardList init]): Have a default initializer that uses an empty BackFowardList not associated with a page.
* WebView/WebFrame.mm:
(kit): For clarity's sake, this should return nil, not 0
2007-07-20 Justin Garcia <justin.garcia@apple.com>
Reviewed by Darin.
<rdar://problem/5109817> Ctrl-click on word in non-editable text doesn't select it
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm: Removed the method
for enabling/disabling word selection on right click.
* WebView/WebView.mm: Ditto.
* WebView/WebViewPrivate.h: Removed the getter/setter entirely,
it was in a private Category for Mail, but wasn't used by Mail
on Tiger or Leopard, they apparently implement word selection on
their own.
2007-07-20 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5199812> WebView needs to adopt viewWillDraw (moving off of _propagateDirtyRectsToOpaqueAncestors)
<rdar://problem/5017301> REGRESSION: Scroller in Widget Manager splits down the middle while scrolling
On Leopard _propagateDirtyRectsToOpaqueAncestors is no longer called by AppKit. Also marking new dirty rects
underneath _recursiveDisplayRectIfNeededIgnoringOpacity will wait until the next runloop to draw them,
causing rendering to happen in two steps instead of one as WebCore expected.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _topHTMLView]): Move to the file internal category so we can use it in viewWillDraw.
(-[WebHTMLView _isTopHTMLView]): Ditto.
(-[WebHTMLView _propagateDirtyRectsToOpaqueAncestors]): #ifdef for Tiger only.
(-[WebHTMLView viewWillDraw]): Do a recursive layout if this is the top WebHTMLView.
(-[WebHTMLView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]):
Don't do layout here on Leopard since viewWillDraw handled it.
(-[WebHTMLView _recursiveDisplayAllDirtyWithLockFocus:visRect:]): Ditto.
2007-07-20 Beth Dakin <bdakin@apple.com>
Reviewed by Tim and Geoff.
Fix for <rdar://problem/5346855> Mail crashes at
WebCore::RenderTableSection:paint + 846 when attempting to display
a HTML based message
After reapplying styles, the RenderView needs layout. However,
layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize used to
return early if the WebHTMLView itself does not need layout.
Because the WebHTMLView is not necessarily in synch with the
RenderTree, returning early here can get us into a bad situation
where we paint before laying out the Render Tree. This patch checks
both the WebHTMLView and the bridge (which checks the RenderView,
etc), so that we do not return early without laying out the Render
Tree.
Some day, we should phase out WebHTMLView keeping track of
needsLayout at all. But that is a bit beyond the scope of this fix.
* WebView/WebHTMLView.mm:
(-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]):
2007-07-20 John Sullivan <sullivan@apple.com>
Reviewed by Darin Adler and David Harrison
- fixed <rdar://problem/5307075> REGRESSION: Bottom of some printed pages are truncated
The "avoid orphan" code I added a year ago was causing the page to be imaged to a larger
height (good), but not shrinking everything to compensate (bad). Bad one-year-ago me!
* WebView/WebHTMLViewInternal.h:
added avoidingPrintOrphan boolean
* WebView/WebHTMLView.mm:
(-[WebHTMLView _setPrinting:minimumPageWidth:maximumPageWidth:adjustViewSize:]):
clear _private->avoidingPrintOrphan when clearing _private->printing
(-[WebHTMLView _scaleFactorForPrintOperation:]):
take _private->avoidingPrintOrphan into account when computing the scale factor
(-[WebHTMLView knowsPageRange:]):
set _private->avoidingPrintOrphan when we're shrinking to avoid an orphan
2007-07-19 Adam Roben <aroben@apple.com>
Fix <rdar://problem/5344972> REGRESSION: A error dialog occurs when
attempting to ctrl-click in a iChat message window (webview)
Reviewed by Oliver.
* WebCoreSupport/WebContextMenuClient.mm:
(fixMenusToSendToOldClients): Don't check for the Inspect Element item
if we have fewer than 2 items.
2007-07-18 Geoffrey Garen <ggaren@apple.com>
Reviewed by Dave Hyatt.
<rdar://problem/5345099>
Reduced default WebCore cache size from 32 MB to 23 MB on systems below
512 MB RAM. This improves RPRVT usage in the Safari pageout test by
~10% on a system with 384 MB RAM.
At 23 MB, no extra resources are evicted from the cache during a PLT
run, so this is a safe change PLT-wise. 23 MB is also seems to be a
generous number in real world usage.
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
2007-07-18 Anders Carlsson <andersca@apple.com>
Reviewed by Geoff.
<rdar://problem/5341133> REGRESSION (Safari 2->Safari 3): DjVu plug-in doesn't load in Safari 3
The DjVu plug-in uses the size of the passed in NPNetscapeFuncs struct to copy it over to a NPNetscapeFuncs struct
whose size was determined when DjVu was compiled. This means that when we add extra functions to the vtable,
DjVu will segfault copying it into the (too small) destination struct.
Fix this by special-casing the DjVu plug-in and setting the NPNetscapeFuncs size to be the same size as what DjVu expects.
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage _applyDjVuWorkaround]):
(-[WebNetscapePluginPackage load]):
2007-07-18 Timothy Hatcher <timothy@apple.com>
Reviewed by Adam.
<rdar://problem/5343767> Should have a way to disable the Web Inspector
Adds a new DisableWebKitDeveloperExtras default that will force the Web Inspector to be disabled.
This overrides the WebKitDeveloperExtras and IncludeDebugMenu default. It also disables
the Web Inspector in Debug builds.
* WebView/WebView.mm:
(+[WebView _developerExtrasEnabled]): Check for the DisableWebKitDeveloperExtras default.
(-[WebView _commonInitializationWithFrameName:groupName:]): Make a new WebInspectorClient when making the Page.
2007-07-18 Anders Carlsson <andersca@apple.com>
Build fix.
* Misc/WebNSAttributedStringExtras.mm:
2007-07-18 Sam Weinig <sam@webkit.org>
Rubber-stamped by Adam Roben.
Update after renaming MimeTypeRegistry to MIMETypeRegistry.
* Misc/WebNSPasteboardExtras.mm:
(-[NSPasteboard _web_writePromisedRTFDFromArchive:containsImage:]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge determineObjectFromMIMEType:URL:]):
* WebView/WebDataSource.mm:
(-[WebDataSource _documentFragmentWithArchive:]):
* WebView/WebHTMLRepresentation.mm:
(+[WebHTMLRepresentation supportedNonImageMIMETypes]):
(+[WebHTMLRepresentation supportedImageMIMETypes]):
* WebView/WebHTMLView.mm:
(-[WebHTMLView _imageExistsAtPaths:]):
2007-07-18 Tristan O'Tierney <tristan@apple.com>
Reviewed by Maciej Stachowiak.
<rdar://problem/5341334> Alt-clicking a link in Safari does not register original URL info with gatekeeper
<rdar://problem/5342570> REGRESSION: A hang occurs when attempting to open a attached file from a .Mac web mail message
* WebCoreSupport/WebFrameLoaderClient.h:
Added a new method, setOriginalURLForDownload, for both download()
and startDownload() to share.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::download):
Moved all the gatekeeper code into setOriginalURLForDownload.
(WebFrameLoaderClient::setOriginalURLForDownload):
Same code that was in download() but moved into a single place for both
startDownload and download to use. Also returned the boolean logic
for detecting _wasUserGesture back to it's previous state, since my prior change
was incorrect. Additionally I found a loop index bug with backListCount and fixed it.
(WebFrameLoaderClient::startDownload):
Calls out to setOriginalURLForDownload after a download is created.
* WebView/WebView.mm:
(-[WebView _downloadURL:]):
Changed to return the WebDownload object created inside _downloadURL
* WebView/WebViewInternal.h:
Changed _downloadURL to return the WebDownload it creates.
2007-07-17 Timothy Hatcher <timothy@apple.com>
Reviewed by Geoff.
<rdar://problem/5336267> loadData:MIMEType:textEncodingName:baseURL: doesn't like relative URLs
Get the absoluteURL from any user supplied NSURL before we pass it down to WebCore.
* WebView/WebFrame.mm:
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]):
* WebView/WebView.mm:
(-[WebView userAgentForURL:]):
2007-07-17 Adam Roben <aroben@apple.com>
Fix Bug 14324: Cannot remove/customize the "Inspect Element" contextual menu item
http://bugs.webkit.org/show_bug.cgi?id=14324
Only clients linking against new versions of WebKit will see the item.
I've maintained our behavior for old clients of not including the
Inspect Element item in the menu items passed to the UI delegate.
Reviewed by Tim.
* Misc/WebKitVersionChecks.h: Added a new constant.
* WebCoreSupport/WebContextMenuClient.mm:
(isPreInspectElementTagClient): Added.
(fixMenusToSendToOldClients): Return an array of items that should be
appended to the menu received from the delegate.
(fixMenusReceivedFromOldClients): Append the saved items to the array.
(WebContextMenuClient::getCustomMenuFromDefaultItems): Retain/release
the saved items.
2007-07-17 Adam Roben <aroben@apple.com>
Remove WebContextMenuClient::shouldIncludeInspectElementItem
Reviewed by Tim.
* WebCoreSupport/WebContextMenuClient.h:
* WebCoreSupport/WebContextMenuClient.mm:
2007-07-17 Adam Roben <aroben@apple.com>
Initialize Settings::developerExtrasEnabled
Reviewed by Tim.
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2007-07-17 Geoffrey Garen <ggaren@apple.com>
Build fix.
* WebView/WebFrame.mm:
(-[WebFrame _loadURL:referrer:intoChild:]):
* WebView/WebFramePrivate.h:
2007-07-17 Tristan O'Tierney <tristan@apple.com>
Reviewed by Maciej Stachowiak.
<rdar://problem/5294691> Source of file is misrepresented if downloaded by typing in URL in Safari address bar
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::download):
Revised code to check the initial request's referrer before assuming it has a history to check.
2007-07-16 Brady Eidson <beidson@apple.com>
Reviewed by Adam
Begin the arduous task of localizing FTP directory listings while removing a global initializer!
* English.lproj/Localizable.strings:
* WebCoreSupport/WebViewFactory.mm:
(-[WebViewFactory unknownFileSizeText]):
2007-07-16 Adam Roben <aroben@apple.com>
Move printing from WebFrameBridge to WebChromeClient
Reviewed by Darin.
* WebCoreSupport/WebChromeClient.h: Updated for ChromeClient changes.
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::print): Moved code from WebFrameBridge.
* WebCoreSupport/WebFrameBridge.mm: Removed -print.
2007-07-16 Darin Adler <darin@apple.com>
* StringsNotToBeLocalized.txt: Update for recent changes.
2007-07-16 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker and Darin Adler
- fixed <rdar://problem/5337529> Holes in Find banner overlay on PDF pages are left in wrong place after changing scale
* WebView/WebPDFView.mm:
(-[WebPDFView _scaleOrDisplayModeChanged:]):
tell UI delegate that the entire PDF view has been redrawn
2007-07-14 Brady Eidson <beidson@apple.com>
Reviewed by Sam Weinig
Initial check-in for <rdar://problem/3154486> - Supporting FTP directory listings in the browser
* WebView/WebPreferenceKeysPrivate.h: Added preference keys for the FTP template location, as well as to force
FTP directory listings, bypassing the policy delegate. This is necessary to test the new feature until browser
policy delegate support is added.
* WebView/WebPreferences.m:
(-[WebPreferences _setFTPDirectoryTemplatePath:]):
(-[WebPreferences _ftpDirectoryTemplatePath]):
(-[WebPreferences _setForceFTPDirectoryListings:]):
(-[WebPreferences _forceFTPDirectoryListings]):
* WebView/WebPreferencesPrivate.h:
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2007-07-13 Anders Carlsson <andersca@apple.com>
Reviewed by Maciej.
<rdar://problem/5290103> Assert failure when loading page with multipart resource
Don't try to call the delegate method if the resource object doesn't exist in the
identifier map. When a multipart resource has finished loading one part, it is removed from the
web view identifier map.
This is not an ideal fix, a better fix would be to special-case multipart resources and not remove
them when the first part has finished loading. I've filed <rdar://problem/5335034> to track doing that.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::willCacheResponse):
(WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
2007-07-13 Timothy Hatcher <timothy@apple.com>
Reviewed by Oliver Hunt.
<rdar://problem/5333766> Can't include WebEditingDelegatePrivate.h
* WebView/WebEditingDelegatePrivate.h: Changed the include to be a framework include,
so other projects can use this header.
2007-07-12 Anders Carlsson <andersca@apple.com>
Reviewed by Darin and Maciej.
<rdar://problem/5271096> panic after Safari stress test, caused by port leak
Replace uses of -[NSObject performSelector:withObject:afterDelay:] with CFRunLoopTimer. performSelector
causes the target (the WebHTMLView in this case) to be retained until the timer fires. Furthermore, when
running the PLT or iBench, the timers will not fire until the main loop is entered (usually after running all tests).
This means that the timers and ports will not be released until after the test has finished running.
* WebView/WebHTMLView.mm:
(-[WebHTMLViewPrivate dealloc]):
(-[WebHTMLView _cancelUpdateMouseoverTimer]):
(-[WebHTMLView _updateMouseoverWithFakeEvent]):
(-[WebHTMLView _updateMouseoverTimerCallback:]):
(-[WebHTMLView _frameOrBoundsChanged]):
(-[WebHTMLView _updateActiveState]):
(-[WebHTMLView _updateActiveStateTimerCallback:]):
(-[WebHTMLView viewWillMoveToWindow:]):
(-[WebHTMLView viewDidMoveToWindow]):
(-[WebHTMLView mouseDown:]):
(-[WebTextCompleteController dealloc]):
* WebView/WebHTMLViewInternal.h:
2007-07-13 Mark Rowe <mrowe@apple.com>
Reviewed by Mitz.
Build fix. Stub out WebChromeClient::print.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::print):
2007-07-11 Timothy Hatcher <timothy@apple.com>
Reviewed by Oliver.
<rdar://problem/5108789> WEBVIEW: Drawing artifacts when dragging in IB
Interface Builder 3 is relying on KVO notifications for frameOrigin and frameSize,
among other standard NSView keys. Change automaticallyNotifiesObserversForKey to
return NO only for keys WebView manually fires notifications for.
* WebView/WebView.mm:
(+[WebView automaticallyNotifiesObserversForKey:]): Selectivly return NO for keys we manually fire.
(-[WebView _declaredKeys]): Code clean up.
2007-07-10 Antti Koivisto <antti@apple.com>
Reviewed by John.
Fix <rdar://problem/4570550>
Hang in layout/layoutBlock/layoutBlockChildren preparing to print certain Mail messages
When printing from Mail, WebHTMLView is a subview of the view that is actually printed and does not
receive calls that would set it to printing mode. Method adjustPageHeightNew is called repeatedly (for each page) during
printing and it enables printing mode temporarily for each call. This triggers two full style recalcs and layouts
each time making printing at least O(n^2).
Instead of enabling printing mode and resetting it back immediatly do the resetting asynchronously, after
all adjustPageHeightNew calls are done. Normal Safari printing is not affected as adjustPageHeightNew is only
called in case WebHTMLView is embedded in the view that is being printed.
No automatic test possible, requires printing and non-Safari client.
* WebView/WebHTMLView.mm:
(-[WebHTMLView adjustPageHeightNew:top:bottom:limit:]):
2007-07-10 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej Stachowiak.
- Fixed <rdar://problem/5049509> REGRESSION(10.4.9-9A377a): REAP Suite
installer shows empty modal alert window (hangs) if user cancels during
"installing shared components" phase
Added Adobe installers to the family of apps that need a data load
loading quirk.
Added a linked-on-or-after check because this code is no longer
Tiger-only.
I tested this code on Tiger and Leopard.
* Misc/WebKitVersionChecks.h:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDocumentLoaderMac.mm:
(needsDataLoadWorkaround):
(WebDocumentLoaderMac::setDataSource):
2007-07-10 Darin Adler <darin@apple.com>
- fix build
* WebView/WebHTMLView.mm: Add include of ContextMenu.h.
2007-07-10 Darin Adler <darin@apple.com>
Reviewed by John Sullivan.
- <rdar://problem/5321953> remove workaround for fixed AppKit mouse moved bug
* WebView/WebHTMLView.mm: Put the workaround for bug 3429631 inside an
ifdef BUILDING_ON_TIGER.
2007-07-09 Anders Carlsson <andersca@apple.com>
Reviewed by Oliver.
<rdar://problem/4954319>
Acrobat 7 / Safari crash: CrashTracer: 99 crashes in Safari at
com.apple.WebCore: WebCore::NetscapePlugInStreamLoader::isDone const + 0
Add a new initWithFrameLoader: method to WebNetscapePluginStream which is to be used when
the stream is a "fake" stream for full frame plug-ins.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView pluginView:receivedResponse:]):
* Plugins/WebNetscapePluginStream.h:
* Plugins/WebNetscapePluginStream.mm:
(-[WebNetscapePluginStream initWithFrameLoader:]):
(-[WebNetscapePluginStream initWithRequest:plugin:notifyData:sendNotification:]):
(-[WebNetscapePluginStream start]):
(-[WebNetscapePluginStream cancelLoadWithError:]):
(-[WebNetscapePluginStream stop]):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createFrame):
2007-07-09 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- fixed <rdar://problem/5320208> WebKit should prevent Time Machine from backing up WebKit clients' icon databases
* Misc/WebIconDatabase.mm:
(-[WebIconDatabase init]):
Re-added the code to exclude the icon database from backups. We now do this at the same time we (try to) import
the old icon database format, which happens only once per icon database's lifetime.
(-[WebIconDatabase _importToWebCoreFormat]):
Assert that we haven't imported yet rather than bailing out. It's now the caller's responsibility to check
whether we've imported yet.
2007-07-08 John Sullivan <sullivan@apple.com>
* Misc/WebIconDatabase.mm:
(-[WebIconDatabase init]):
Removed the code to exclude the icon database from backups. We still want to do this, but in a way
that only runs once ever, instead of once per launch, due to performance concerns.
2007-07-07 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- fix <rdar://problem/5124665> WebCore secondary-thread assertion should use linked-on-or-after check instead of building on Tiger check
* Misc/WebKitVersionChecks.h: Added WEBKIT_FIRST_VERSION_WITH_MAIN_THREAD_EXCEPTIONS.
* WebView/WebFrameView.mm: (-[WebFrameView initWithFrame:]): In first-time initialization block,
check for binaries linked against older versions of WebKit, and set the default thread violation
behavior to LogOnFirstThreadViolation.
* WebView/WebView.mm: (+[WebView initialize]): Improved comments.
2007-07-06 Oliver Hunt <oliver@apple.com>
Reviewed by Maciej.
<rdar://problem/5318756> Need to refactor IM/Marked text code to share logic with windows.
Moved a number of methods from WebHTMLView into WebCore.
Replaced bridge methods with calls directly into WebCore objects.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.mm:
(-[WebHTMLView setMarkedText:selectedRange:]):
Now calls WebCore object methods directly, rather than calling
via the bridge.
2007-07-06 John Sullivan <sullivan@apple.com>
Reviewed by Brady
- WebKit part of fix for:
<rdar://problem/5310739> Time Machine shouldn't back up WebKit's icon database files
* Misc/WebIconDatabase.mm:
(-[WebIconDatabase init]):
Use CSBackupSetItemExcluded to tell Time Machine not to back up the icon database file
2007-07-07 Mark Rowe <mrowe@apple.com>
Build fix. Update WebDynamicScrollBarsView.h to include methods added and used in r24060.
* WebView/WebDynamicScrollBarsView.h:
2007-07-05 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
<rdar://problem/5236277> REGRESSION-9A458: SPI for setting scroll bar behavior doesn't work
Calling setHorizontalScrollingMode: calls updateScrollers before returning, this will cause
WebCore to reset the scrolling mode based on the CSS overflow rules. So the setAlwaysShowHorizontalScroller:
and setAlwaysShowVerticalScroller: methods needed a way to lock the scrolling mode before
calling updateScrollers.
* WebView/WebDynamicScrollBarsView.m:
(-[WebDynamicScrollBarsView updateScrollers]):
(-[WebDynamicScrollBarsView setHorizontalScrollingMode:]):
(-[WebDynamicScrollBarsView setHorizontalScrollingMode:andLock:]):
(-[WebDynamicScrollBarsView setVerticalScrollingMode:]):
(-[WebDynamicScrollBarsView setVerticalScrollingMode:andLock:]):
(-[WebDynamicScrollBarsView setScrollingMode:]):
(-[WebDynamicScrollBarsView setScrollingMode:andLock:]):
* WebView/WebView.mm:
(-[WebView setAlwaysShowVerticalScroller:]):
(-[WebView setAlwaysShowHorizontalScroller:]):
2007-07-06 Mitz Pettel <mitz@webkit.org>
Reviewed by Maciej.
- fix http://bugs.webkit.org/show_bug.cgi?id=10267
Can't scroll page downwards with scroll wheel, when pointer is on top of non-scrolling iframe
* WebView/WebDynamicScrollBarsView.m:
(-[WebDynamicScrollBarsView scrollWheel:]): Override the superclass
implementation to forward the wheel event to the next responder if this view
does not allow scrolling in the event's direction.
2007-07-05 John Sullivan <sullivan@apple.com>
Reviewed by Adam
- WebKit part of fix for <rdar://problem/5315033>
* WebView/WebDocumentPrivate.h:
new selectionImageForcingBlackText: method. selectionImageForcingWhiteText: is no longer used and was never
in an official release of WebKit, so it could be removed, except that doing so would cause trouble for people
using nightly WebKit with Safari 3.0 beta. So I left it in, but made it just force black text instead of
white text, which will look different for those nightly WebKit/Safari 3.0 beta people but not break anything.
* Misc/WebSearchableTextView.m:
(-[WebSearchableTextView selectionImageForcingBlackText:]):
new unimplemented protocol method for this obsolete class
* WebView/WebHTMLView.mm:
(-[WebHTMLView selectionImageForcingBlackText:]):
calls through to WebCore the way selectionImageForcingWhiteText: used to
(-[WebHTMLView selectionImageForcingWhiteText:]):
now just calls selectionImageForcingBlackText:, thus not working as you would expect from the name
* WebView/WebPDFView.mm:
(-[WebPDFView selectionImageForcingBlackText:]):
guts of old selectionImageForcingWhiteText:, but with black substituted for white
(-[WebPDFView selectionImageForcingWhiteText:]):
now just calls selectionImageForcingBlackText:, thus not working as you would expect from the name
2007-07-05 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
<rdar://problem/5314993> Shiira 2.1 throws an exception open a new window: -[WebInspector window]: unrecognized selector
Add an empty implementation of this method to prevent Shiira from throwing an exception.
Also log that this method is obsolete and the class will be removed.
* WebInspector/WebInspector.mm:
(-[WebInspector window]):
2007-07-04 Adam Roben <aroben@apple.com>
Move tooltip logic down into WebCore so that it can be shared cross-platform
Reviewed by Sam.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::setToolTip): Added.
* WebView/WebHTMLView.mm: Removed _resetCachedWebPreferences.
(-[WebHTMLView _updateMouseoverWithEvent:]): Removed tooltip code.
(-[WebHTMLView initWithFrame:]): Removed call to
_resetCachedWebPreferences.
(-[WebHTMLView setDataSource:]): Ditto.
* WebView/WebHTMLViewInternal.h: Removed showsURLsInToolTips ivar.
* WebView/WebHTMLViewPrivate.h: Added declaration for _setTooltip so
that WebChromeClient can call it.
2007-07-04 Adam Roben <aroben@apple.com>
Initialize Settings::showsURLsInToolTips
Reviewed by Sam.
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2007-07-04 Adam Roben <aroben@apple.com>
Removed call to mouseDidMoveOverElement now that WebCore handles it
Reviewed by Sam.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _updateMouseoverWithEvent:]):
2007-07-04 Adam Roben <aroben@apple.com>
Add WebChromeClient::mouseDidMoveOverElement
This is not called yet.
Reviewed by Sam.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
2007-07-03 Darin Adler <darin@apple.com>
* StringsNotToBeLocalized.txt: Updated for recent changes.
2007-07-03 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Remove HIWebView in 64-bit.
Also disable a few calls that are now gone in 64-bit and filed these bugs:
<rdar://problem/5311653> WebKit needs to adopt HIGetMousePosition where we used GetGlobalMouse before
<rdar://problem/5311648> WebKit needs to move off of CopyEvent in WebBaseNetscapePluginView
<rdar://problem/5311640> WebKit needs a new solution for HISearchWindowShow on 64-bit
* Carbon/CarbonUtils.m:
* Carbon/CarbonWindowAdapter.m:
* Carbon/CarbonWindowContentView.m:
* Carbon/CarbonWindowFrame.m:
* Carbon/HIViewAdapter.m:
(SetViewNeedsDisplay):
* Carbon/HIWebView.m:
(Draw):
(SyncFrame):
* Configurations/WebKit.xcconfig:
* Plugins/WebBaseNetscapePluginView.mm:
(+[WebBaseNetscapePluginView getCarbonEvent:]):
(TSMEventHandler):
* WebKit.LP64.exp: Added.
* WebView/WebView.mm:
(-[WebView _searchWithSpotlightFromMenu:]):
2007-07-03 Adam Roben <aroben@apple.com>
Merge the Windows and Mac localized strings and exceptions files
Reviewed by Darin and Anders.
* English.lproj/Localizable.strings: Added Windows strings.
* StringsNotToBeLocalized.txt: Renamed from WebKit/English.lproj/StringsNotToBeLocalized.txt.
2007-07-03 Adele Peterson <adele@apple.com>
Removed printf I accidently left in.
* Misc/WebNSURLExtras.m: (mapHostNames):
2007-07-03 Adele Peterson <adele@apple.com>
Reviewed by Darin.
Fix for: <rdar://problem/5292988> domain names shouldn't contain ignorable characters
* Misc/WebNSURLExtras.m:
(isLookalikeCharacter): Renamed. Also excludes any non-printable character,
any character considered as whitespace that isn't already converted to a space by ICU, any ignorable character,
and any character excluded in Mozilla's blacklist: http://kb.mozillazine.org/Network.IDN.blacklist_chars
(allCharactersInIDNScriptWhiteList):
2007-07-03 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- fix <rdar://problem/5310848> WebDataSource lifetime problem -- may be cause of the leaks seen on the buildbot
* WebView/WebDataSource.mm:
(-[WebDataSourcePrivate dealloc]): Added a call to the new detachDataSource function.
(-[WebDataSourcePrivate finalize]): Ditto.
* WebView/WebDocumentLoaderMac.h: Added detachDataSource function to be used when the
WebDataSource is deallocated. Added retain/releaseDataSource helper functions to be
used to retain and release the data source object. Replaced the m_hasEverBeenDetached
boolean with a more primitive and hence easier to understand m_isDataSourceRetained boolean.
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::WebDocumentLoaderMac): Initialize m_isDataSourceRetained to false.
(WebDocumentLoaderMac::setDataSource): Call retainDataSource instead of calling HardRetain
on the dataSource parameter. Also updated a comment.
(WebDocumentLoaderMac::attachToFrame): Call retainDataSource unconditionally rather than
trying to use m_hasEverBeenDetached to decide if a retain is needed. Also got rid of an
assertion that m_loadingResources is empty -- not important any more.
(WebDocumentLoaderMac::detachFromFrame): Call releaseDataSource instead of using
HardRelease, but only if m_loadingResources is empty. If it's non-empty, then we'll
do the releaseDataSource later in decreaseLoadCount.
(WebDocumentLoaderMac::increaseLoadCount): Call retainDataSource unconditionally
rather than calling HardRetain only if the old set of resources was empty.
(WebDocumentLoaderMac::decreaseLoadCount): Call releaseDataSource if m_loadingResources
is empty and we're not attached to a frame. If we are attached to a frame, then
we'll do the releaseDataSource later in detachFromFrame.
(WebDocumentLoaderMac::retainDataSource): Added. Calls CFRetain, but only if the data
source is not already retained (according to the boolean).
(WebDocumentLoaderMac::releaseDataSource): Added. Calls CFRelease, but only if the data
source is currently retained (according to the boolean).
(WebDocumentLoaderMac::detachDataSource): Added. Sets m_dataSource to nil. Since this
is only called from WebDataSource's dealloc and finalize methods, it won't ever be called
when the m_isDataSourceRetained boolean is true.
2007-07-03 Darin Adler <darin@apple.com>
- forgot to check in one file in the fix for <rdar://problem/5307880>
some classes need finalize methods because of non-trivial work done in dealloc methods
* WebView/WebView.mm: (-[WebViewPrivate finalize]): Delete identifierMap so it doesn't leak.
2007-07-03 Anders Carlsson <andersca@apple.com>
Reviewed by Darin.
* WebView/WebView.mm:
(-[WebView stringByEvaluatingJavaScriptFromString:]):
ASSERT that the value returned isn't nil. It can't be nil when invoked on the main frame.
2007-07-04 Mark Rowe <mrowe@apple.com>
Unreviewed 64-bit build fixes.
* WebCoreSupport/WebInspectorClient.mm: Let the compiler know that WebFrameView is a subclass of NSView.
* WebView/WebDocumentInternal.h: Remove our preprocessor macro once we're done with it.
* WebView/WebHTMLView.mm:
(-[WebHTMLView markAllMatchesForText:caseSensitive:limit:]): Fix argument types.
2007-07-02 Darin Adler <darin@apple.com>
Reviewed by Kevin Decker and Tim Hatcher.
- fix <rdar://problem/5307880> some classes need finalize methods
because of non-trivial work done in dealloc methods
* DefaultDelegates/WebScriptDebugServer.m:
(-[WebScriptDebugServer dealloc]): Added a comment about how this probably won't
work under GC.
* WebInspector/WebNodeHighlight.m:
(-[WebNodeHighlight dealloc]): Ditto.
* WebView/WebDataSource.mm:
(+[WebDataSourcePrivate initialize]): Added. Makes finalize run on main thread.
(-[WebDataSourcePrivate finalize]): Added. Calls deref on the document loader.
* WebView/WebHTMLView.mm:
(+[WebHTMLViewPrivate initialize]): Added. Makes finalize run on main thread.
(-[WebHTMLViewPrivate finalize]): Added. Calls deref on promisedDragTIFFDataSource.
* WebKit.xcodeproj/project.pbxproj: Let Xcode be Xcode.
2007-07-02 Oliver Hunt <oliver@apple.com>
Reviewed by Justin.
Fix for
<rdar://problem/5290113> WebKit does not correctly handle replacement ranges from the IM in -[WebHTMLView insertText:]
http://bugs.webkit.org/show_bug.cgi?id=13664
We replicate the logic of -[WebHTMLView setMarkedText:selectedRange:] to handle the Input Method
feeding us a replacement string through insertText: so we can handle IMs that use insertText to
replace text.
* WebView/WebHTMLView.mm:
(-[WebHTMLView insertText:]):
2007-07-01 Oliver Hunt <oliver@apple.com>
Reviewed by Alexey.
Fix for <rdar://problem/5306210> Some events are still passed to WebCore despite being handled by the IM
http://bugs.webkit.org/show_bug.cgi?id=14457
We have to assume that the IM will consume all events, so we remove the dependency
on -[WebHTMLView hasMarkedText].
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]):
2007-06-29 John Sullivan <sullivan@apple.com>
Reviewed by Oliver Hunt.
- WebKit support for accessing the set of rectangles that encompass the selected text
* WebView/WebDocumentPrivate.h:
added -selectionTextRects to WebDocumentSelection protocol; tweaked comments
* WebView/WebHTMLView.mm:
(-[WebHTMLView _selectionDraggingRect]):
use selectionRect instead of selectionImageRect since they're the same and maybe we can get
rid of selectionImageRect someday
(-[WebHTMLView selectionTextRects]):
added implementation of new protocol method, which calls through to WebCore
* WebView/WebPDFView.mm:
(-[WebPDFView selectionTextRects]):
added simple implementation of new protocol method, which just returns the single selection rect.
PDFKit doesn't support obtaining multiple rects to describe a multi-line selection.
(-[WebPDFView selectionImageForcingWhiteText:]):
use selectionRect instead of selectionImageRect since they're the same and maybe we can get
rid of selectionImageRect someday
* Misc/WebSearchableTextView.m:
(-[WebSearchableTextView selectionTextRects]):
added no-op implementation of new protocol method to this obsolete class
2007-06-28 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5287569> WEBVIEW: Creating a webview in IB 3.0 (v2.0) NIB later crashes Interface Builder 2.5.4 on Tiger
Prevent encoding any of the WebView subviews. The subviews are ignored by -[WebView initWithCoder:] and will be recreated.
The Tiger 2.0 code crashed when the WebView released the subviews in initWithCoder:, so now there are no subviews to release.
This never happened before because the Tiger 2.0 code and IB wouldn't encode a WebView that has a WebHTMLView.
* WebView/WebView.mm:
(-[WebView encodeWithCoder:]):
2007-06-26 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- WebKit support for displaying multiple text matches in PDF views (<rdar://problem/4601967>)
* WebView/WebPDFView.h:
new ivars textMatches and lastScrollPosition; now conforms to WebMultipleTextMatches protocol
* WebView/WebPDFView.mm:
(-[WebPDFView dealloc]):
release textMatches
(-[WebPDFView viewDidMoveToWindow]):
start observing bounds changes in the PDF document's enclosing clip view, so we can notice when
scrolling takes place
(-[WebPDFView viewWillMoveToWindow:]):
stop observing bounds changes in the PDF document's enclosing clip view
(-[WebPDFView searchFor:direction:caseSensitive:wrap:startInSelection:]):
most of the code here has been moved into the new method _nextMatchFor::::, which this now calls
(-[WebPDFView setMarkedTextMatchesAreHighlighted:]):
implementation of WebMultipleTextMatches protocol method, does nothing useful here because we don't
support inline highlighting of matches in PDF documents
(-[WebPDFView markedTextMatchesAreHighlighted]):
implementation of WebMultipleTextMatches protocol method
(-[WebPDFView markAllMatchesForText:caseSensitive:limit:]):
implementation of WebMultipleTextMatches protocol method; calls _nextMatchFor:::: in a loop until
entire document is searched or limit is hit; records results by saving PDFSelections in textMatches ivar
(-[WebPDFView unmarkAllTextMatches]):
implementation of WebMultipleTextMatches protocol method; clears saved textMatches
(-[WebPDFView rectsForTextMatches]):
implementation of WebMultipleTextMatches protocol method; converts saved PDFSelections into NSValue
objects that represent NSRects
(-[WebPDFView _clipViewForPDFDocumentView]):
new helper method to find the clip view whose bounds determine the current scroll position
(-[WebPDFView _nextMatchFor:direction:caseSensitive:wrap:fromSelection:startInSelection:]):
new helper method, extracted from searchFor:::::
(-[WebPDFView _PDFDocumentViewMightHaveScrolled:]):
new notification callback; tells webView's delegate when document has scrolled
(-[WebPDFView _setTextMatches:]):
new helper method, stores value in ivar
2007-06-26 Oliver Hunt <oliver@apple.com>
Reviewed by Maciej.
Hopefully fix remainder of the IME issues on Mac.
We now assume that the IME silently consumes any event given
to it during text composition, and only override this assumption
if the NSTextInput or NSResponder callbacks are made.
This prevents us from treating those events that the IME has
consumed internally (eg. candidate window navigation) as unhandled
events that should be bubbled.
This fixes:
<rdar://problem/5107538> Major problems handling key press event with non-english Input Methods
<rdar://problem/4196249> REGRESSION: Mail: Inputting space (U+0020) with IM deletes subsequent line breaks on Mail.app
<rdar://problem/5015544> REGRESSION: Reverse conversion keyboard command does not work in Safari.
<rdar://problem/5045121> REGRESSION: Inline is confirmed after press left/right arrow keys, happens in Mail but not in TextEdit.
<rdar://problem/5076807> REGRESSION: Can't undo conversion of inline text (by hitting ESC)
<rdar://problem/5085781> REGRESSION: Active input area lost "selected" highlight
<rdar://problem/5094200> space key pressed to close the associated words candidate window gets inserted as text
<rdar://problem/5228294> Candidate item for character matrix is sometimes skipped
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.mm:
(-[WebHTMLView launchKeyEvent:]):
(-[WebHTMLView keyDown:]):
(-[WebHTMLView keyUp:]):
(-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]):
(-[WebHTMLView unmarkText]):
(-[WebHTMLView setMarkedText:selectedRange:]):
(-[WebHTMLView doCommandBySelector:]):
(-[WebHTMLView insertText:]):
2007-06-26 Jim Correia <jim.correia@pobox.com>
Reviewed by Darin.
Fix http://bugs.webkit.org/show_bug.cgi?id=14411
Bug 14411: WebNetscapePluginPackage overagressively sets CurApRefNum, which affects shipping versions of BBEdit.
<rdar://problem/5297268>
* Plugins/WebNetscapePluginPackage.m:
(+[WebNetscapePluginPackage initialize]): Force the Resource Manager to
lazy initialize, and only set CurApRefNum to the system file if
CurApRefNum is still -1 after that forced lazy initialization.
2007-06-25 Kevin Decker <kdecker@apple.com>
Reviewed by Darin.
<rdar://problem/5294036> -[WebView customTextEncodingName] API may return empty string instead of nil
* WebView/WebView.mm:
(-[WebView _mainFrameOverrideEncoding]): Addded the nsStringNilIfEmpty() inline to the data being returned because
our API says "The custom text encoding name or nil if no custom text encoding name has been set." I also verified
the standing Tiger WebKit behavior for this method and it does indeed return nil if a custom encoding wasn't set.
2007-06-25 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- WebKit part of <rdar://problem/5293820>, needed to support multiple matches in PDFs
* WebView/WebDocumentInternal.h:
Added WebMultipleTextMatches protocol, containing five methods that were formerly implemented in WebHTMLView
* WebView/WebHTMLViewPrivate.h:
Removed declarations for the methods that are now in WebMultipleTextMatches protocol
* WebView/WebHTMLView.mm:
(-[WebHTMLView markAllMatchesForText:caseSensitive:limit:]):
moved this method into the WebDocumentInternalProtocols portion of the file
(-[WebHTMLView setMarkedTextMatchesAreHighlighted:]):
ditto
(-[WebHTMLView markedTextMatchesAreHighlighted]):
ditto
(-[WebHTMLView unmarkAllTextMatches]):
ditto
(-[WebHTMLView rectsForTextMatches]):
ditto
* WebView/WebView.mm:
(-[WebView canMarkAllTextMatches]):
new method, returns YES only if the documentView of every frame implements WebMultipleTextMatches
(-[WebView markAllMatchesForText:caseSensitive:highlight:limit:]):
check for WebMultipleTextMatches protocol instead of checking for WebHTMLView class
(-[WebView unmarkAllTextMatches]):
ditto
(-[WebView rectsForTextMatches]):
ditto
* WebView/WebViewPrivate.h:
declared new method canMarkAllTextMatches
2007-06-25 John Sullivan <sullivan@apple.com>
Reviewed by Darin
Fixed <rdar://problem/5292259> Find on Page doesn't work (throws exception) on page that includes PDF in a subframe
* WebView/WebView.mm:
(-[WebView markAllMatchesForText:caseSensitive:highlight:limit:]):
We were testing whether the view was an HTMLView, but then running code that assumed it was an HTMLView outside of
that test. That's a bad idea.
2007-06-22 Adele Peterson <adele@apple.com>
Reviewed by Geoff and Darin.
Fix for: <rdar://problem/5239236> Other slash characters should not be permitted as part of a domain name
* Misc/WebNSURLExtras.m:
(isSlashOrPeriodLookalike):
(allCharactersInIDNScriptWhiteList):
2007-06-21 Sam Weinig <sam@webkit.org>
Reviewed by Antti.
Remove empty directories
* WebInspector/webInspector: directory removed.
* WebInspector/webInspector/Images: directory removed
2007-06-21 Justin Garcia <justin.garcia@apple.com>
Reviewed by Tim.
<rdar://problem/5237524>
REGRESSION: Keyboard commands don't work in a message window until you click inside the message
When you open a message in its own window, Mail creates an empty
WebView, makes that WebView firstResponder and then sets off a
load inside that WebView.
When we're asked to create the empty WebView, we put an empty
WebHTMLView inside it (in r21367 we began creating a document
for empty frames). When Mail makes the WebView first responder
we make that empty WebHTMLView firstResponder. Then when the
load finishes we create a new WebHTMLView and set it as the
document view.
Inside _setDocumentView, if the old document view or one of its
descendants was the first responder, we'd makeFirstResponder:nil
so that the window wouldn't be left with a firstResponder that
was no longer inside of it. This change fixes the bug by instead
transferring firstResponder status to the new document view.
We could also fix this by not allowing the WebHTMLView to become
firstResponder when it's in the provisional state mentioned above.
* WebView/WebFrameView.mm:
(-[WebFrameView _setDocumentView:]):
2007-06-21 John Sullivan <sullivan@apple.com>
Reviewed by Adele
- fixed <rdar://problem/5268673> REGRESSION: Context menu missing for PDF in frame when there's no selection
This was surprisingly interesting. It turns out that at least for Safari, the method [WebDefaultUIDelegate
webView:contextMenuItemsForElement:defaultMenuItems:] is only exercised from WebPDFView these days. It mimics
some of the code that was moved to WebCore as part of the Great Context Menu Refactoring of 2006, but is
independent of that code. And it was partly broken/incomplete, probably as a result of said refactoring.
* DefaultDelegates/WebDefaultContextMenuDelegate.mm:
(localizedMenuTitleFromAppKit()):
deleted this function since I removed all callers
(-[WebDefaultUIDelegate menuItemWithTag:target:representedObject:]):
Handle WebMenuItemTagOpenFrameInNewWindow tag, since code later in this file was relying on it. Added
ASSERT_NOT_REACHED to the default case, since returning nil from this method is bad.
Also, use WebKit versions of menu title strings rather than AppKit versions. We added these strings to WebKit
a while back so we don't need to sneakily find them in AppKit anymore.
(-[WebDefaultUIDelegate webView:contextMenuItemsForElement:defaultMenuItems:]):
make the WebView be the target of the Open Frame in New Window item; previously it was self, but that was
just silly (probably a leftover from some code shuffling when context menus were reimplemented)
* WebView/WebView.mm:
(-[WebView _openFrameInNewWindowFromMenu:]):
new method, used by Open Frame in New Window menu item.
* WebView/WebViewInternal.h:
Declare new method used by menu item. This isn't necessary for compilation, but could prevent the accidental
deletion of the method implementation.
2007-06-20 Mark Rowe <mrowe@apple.com>
Reviewed by Adam.
Fix http://bugs.webkit.org/show_bug.cgi?id=14255.
Bug 14255: Reproducible crash opening web inspector from debug menu
Reinstate the WebInspector class so WebKit clients that currently depend on it
will build and run correctly.
* WebInspector/WebInspector.h: Added.
* WebInspector/WebInspector.mm: Added.
(+[WebInspector webInspector]):
(-[WebInspector dealloc]):
(-[WebInspector setWebFrame:]):
(-[WebInspector showWindow:]):
* WebKit.exp:
* WebKit.xcodeproj/project.pbxproj:
2007-06-20 Adam Roben <aroben@apple.com>
Land the new Inspector.
Co-written with Tim Hatcher.
Reviewed by Anders, Adele, Hyatt, and Sam.
Implement the InspectorClient interface.
* WebCoreSupport/WebInspectorClient.h: Added.
* WebCoreSupport/WebInspectorClient.mm: Added.
(WebInspectorClient::WebInspectorClient):
(WebInspectorClient::inspectorDestroyed):
(WebInspectorClient::createPage):
(WebInspectorClient::showWindow):
(WebInspectorClient::closeWindow):
(WebInspectorClient::attachWindow):
(WebInspectorClient::detachWindow):
(WebInspectorClient::highlight):
(WebInspectorClient::hideHighlight):
(WebInspectorClient::inspectedURLChanged):
(WebInspectorClient::updateWindowTitle):
(-[WebInspectorWindowController init]):
(-[WebInspectorWindowController initWithInspectedWebView:]):
(-[WebInspectorWindowController dealloc]):
(-[WebInspectorWindowController inspectorVisible]):
(-[WebInspectorWindowController webView]):
(-[WebInspectorWindowController window]):
(-[WebInspectorWindowController windowShouldClose:]):
(-[WebInspectorWindowController close]):
(-[WebInspectorWindowController showWindow:]):
(-[WebInspectorWindowController attach]):
(-[WebInspectorWindowController detach]):
(-[WebInspectorWindowController highlightAndScrollToNode:]):
(-[WebInspectorWindowController highlightNode:]):
(-[WebInspectorWindowController hideHighlight]):
(-[WebInspectorWindowController animationDidEnd:]):
Add an easier-to-see highlight.
* Misc/WebNSViewExtras.h:
* Misc/WebNSViewExtras.m:
(-[NSView _web_convertRect:toView:]):
* WebInspector/WebNodeHighlight.h:
* WebInspector/WebNodeHighlight.m:
(-[WebNodeHighlightFadeInAnimation setCurrentProgress:]):
(-[WebNodeHighlight initWithTargetView:]):
(-[WebNodeHighlight setHighlightedNode:]):
(-[WebNodeHighlight highlightedNode]):
(-[WebNodeHighlight dealloc]):
(-[WebNodeHighlight attachHighlight]):
(-[WebNodeHighlight delegate]):
(-[WebNodeHighlight detachHighlight]):
(-[WebNodeHighlight show]):
(-[WebNodeHighlight hide]):
(-[WebNodeHighlight animationDidEnd:]):
(-[WebNodeHighlight ignoresMouseEvents]):
(-[WebNodeHighlight highlightView]):
(-[WebNodeHighlight setDelegate:]):
(-[WebNodeHighlight setHolesNeedUpdateInTargetViewRect:]):
(-[WebNodeHighlight setIgnoresMouseEvents:]):
(-[WebNodeHighlight targetView]):
(-[WebNodeHighlight _computeHighlightWindowFrame]):
(-[WebNodeHighlight _repositionHighlightWindow]):
* WebInspector/WebNodeHighlightView.h:
* WebInspector/WebNodeHighlightView.m:
(-[WebNodeHighlightView initWithWebNodeHighlight:]):
(-[WebNodeHighlightView dealloc]):
(-[WebNodeHighlightView detachFromWebNodeHighlight]):
(-[WebNodeHighlightView drawRect:]):
(-[WebNodeHighlightView webNodeHighlight]):
(-[WebNodeHighlightView fractionFadedIn]):
(-[WebNodeHighlightView setFractionFadedIn:]):
(-[WebNodeHighlightView setHolesNeedUpdateInRect:]):
(-[WebNodeHighlightView _holes]):
WebView changes needed for the new Inspector.
* WebView/WebView.mm: Remove the old _inspectElement method now that
this is handled by WebCore.
(-[WebView _isClosed]): Added.
(-[WebView initWithFrame]): Give each Page an InspectorClient to
enable the Inspector.
* WebView/WebViewPrivate.h:
Updates needed for WebCore changes.
* WebCoreSupport/WebContextMenuClient.h:
* WebCoreSupport/WebContextMenuClient.mm:
* WebCoreSupport/WebViewFactory.mm:
(-[WebViewFactory contextMenuItemTagInspectElement]):
* WebView/WebUIDelegatePrivate.h:
Remove old Inspector code.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
(WebFrameLoaderClient::assignIdentifierToInitialRequest):
(WebFrameLoaderClient::dispatchDidFinishLoading):
* WebInspector/WebInspector.m: Removed.
* WebInspector/WebInspectorPanel.h: Removed.
* WebInspector/WebInspectorPanel.m: Removed.
* WebInspector/webInspector/Images/button.png: Removed.
* WebInspector/webInspector/Images/buttonDivider.png: Removed.
* WebInspector/webInspector/Images/buttonPressed.png: Removed.
* WebInspector/webInspector/Images/close.png: Removed.
* WebInspector/webInspector/Images/closePressed.png: Removed.
* WebInspector/webInspector/Images/downTriangle.png: Removed.
* WebInspector/webInspector/Images/menu.png: Removed.
* WebInspector/webInspector/Images/menuPressed.png: Removed.
* WebInspector/webInspector/Images/popup.png: Removed.
* WebInspector/webInspector/Images/popupPressed.png: Removed.
* WebInspector/webInspector/Images/resize.png: Removed.
* WebInspector/webInspector/Images/rightTriangle.png: Removed.
* WebInspector/webInspector/Images/scrollThumbBottom.png: Removed.
* WebInspector/webInspector/Images/scrollThumbMiddle.png: Removed.
* WebInspector/webInspector/Images/scrollTrackBottom.png: Removed.
* WebInspector/webInspector/Images/upTriangle.png: Removed.
* WebInspector/webInspector/inspector.css: Removed.
* WebInspector/webInspector/inspector.html: Removed.
* WebInspector/webInspector/inspector.js: Removed.
* WebInspector/webInspector/scrollarea.js: Removed.
* WebInspector/webInspector/scrollbar.js: Removed.
* WebInspector/webInspector/utilities.js: Removed.
* WebView/WebFrame.mm:
(-[WebFramePrivate dealloc]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.mm:
(-[WebHTMLView menuForEvent:]):
Build-fu:
* WebKit.exp:
* WebKit.xcodeproj/project.pbxproj:
2007-06-20 Justin Garcia <justin.garcia@apple.com>
Reviewed by Darin.
<rdar://problem/5263541> REGRESSION (Safari 3 Beta 1): Pressing Delete doesn't delete an HTML message in Mail
Mail wasn't receiving the keyDown event because WebFrameView was blocking it.
It blocks the event and moves back/forward on Delete/Shift+Delete if the
back/forward list is enabled.
* WebView/WebFrameView.mm:
(-[WebFrameView keyDown:]): Check to see if the BackForwardList is
enabled. It always exists.
2007-06-19 Anders Carlsson <andersca@apple.com>
Reviewed by Kevin Decker.
<rdar://problem/5266289> REGRESSION (Safari 3 Beta 1): Incoming iChat messages are delayed
* WebView/WebDocumentLoaderMac.mm:
(needsAppKitWorkaround):
New function which checks if the frame load delegate belongs to AppKit.
(WebDocumentLoaderMac::setDataSource):
If the frame load delegate belongs to AppKit, set m_deferMainResourceDataLoad to false.
2007-06-19 John Sullivan <sullivan@apple.com>
Reviewed by Tim Hatcher
- fixed <rdar://problem/5272011> Hole for find-on-page match in subframe isn't clipped by frame bounds
* WebView/WebView.mm:
(-[WebView rectsForTextMatches]):
intersect the HTMLView's computed rect with the visible rect for that view
2007-06-19 Jim Correia <jim.correia@pobox.com>
Reviewed by Kevin Decker
* Carbon/HIWebView.m:
(WindowHandler): HIObjectIsOfClass requires non-NULL input on Tiger. Reworked Kevin Decker's patch to remove the conditional compilation for Tiger, yet still avoid crashing BBEdit.
2007-06-18 Sam Weinig <sam@webkit.org>
Reviewed by Beth.
Build fix.
* WebCoreSupport/WebChromeClient.mm:
2007-06-18 Kevin Decker <kdecker@apple.com>
* Carbon/HIWebView.m:
(WindowHandler): Fixed the Tiger build; ControlKind wasn't defined.
2007-06-18 Kevin Decker <kdecker@apple.com>
Reviewed by Tim Hatcher.
Fixed: <rdar://problem/5276135> With Safari 3 Tiger Beta installed, a crash occurs in BBEdit while mousing down and dragging outside of HTML preview window
* Carbon/HIWebView.m:
(WindowHandler): Because the fix for 5051616 causes Tiger to crash in HIToolbox (but not on Leopard), I reverted back to using GetControlKind
on Tiger only, instead of HIObjectIsOfClass.
2007-06-16 David Hyatt <hyatt@apple.com>
Back out fix for 13972. Quicktime will no longer clip correctly. :(
Too many regressions in Mail caused by inserting an extra view into the
hierarchy. Can revisit later.
Reviewed by olliej
* Plugins/WebPluginController.mm:
(-[WebPluginController destroyPlugin:]):
(-[WebPluginController destroyAllPlugins]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge pluginViewWithPackage:attributeNames:attributeValues:baseURL:DOMElement:loadManually:]):
* WebView/WebHTMLView.mm:
(-[WebHTMLView addSubview:]):
(-[WebHTMLView willRemoveSubview:]):
2007-06-15 Sam Weinig <sam@webkit.org>
Reviewed by Darin.
Patch for http://bugs.webkit.org/show_bug.cgi?id=14053
Autogenerate JS binding for Rect
- Fix conflicts by using ::Rect instead of Rect.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
(-[WebBaseNetscapePluginView sendEvent:]):
(-[WebBaseNetscapePluginView tellQuickTimeToChill]):
(-[WebBaseNetscapePluginView invalidateRegion:]):
(-[WebBaseNetscapePluginView _printedPluginBitmap]):
2007-06-15 Anders Carlsson <andersca@apple.com>
Reviewed by Kevin.
A better fix for <rdar://problem/5271774>. Only try to access the element if the
view has an associated window. This also works with GC. (Fix suggested by Kevin.)
* Plugins/WebKitPluginContainerView.mm:
(-[WebKitPluginContainerView dealloc]):
(-[WebKitPluginContainerView visibleRect]):
2007-06-15 Anders Carlsson <andersca@apple.com>
Reviewed by Kevin.
<rdar://problem/5271774> REGRESSION: A crash occurs when closing a window that contains a QT movie
In some cases, calling [super dealloc] might end up calling visibleRect, so make sure to
set _element to 0 so we won't send a message to a freed object and crash.
* Plugins/WebKitPluginContainerView.mm:
(-[WebKitPluginContainerView dealloc]):
(-[WebKitPluginContainerView visibleRect]):
2007-06-14 Anders Carlsson <andersca@apple.com>
Reviewed by Geoff.
Call cleanupScriptObjectsForPlugin on the frame after destroying the plug-in.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView _destroyPlugin]):
* Plugins/WebPluginController.mm:
(-[WebPluginController destroyPlugin:]):
(-[WebPluginController destroyAllPlugins]):
2007-06-13 John Sullivan <sullivan@apple.com>
Reviewed by Adele Peterson
- fixed <rdar://problem/5267607> Clicking the "Save to Downloads" button in
PDF overlay too soon results in corrupt file
* WebView/WebPDFView.mm:
(-[WebPDFView PDFViewSavePDFToDownloadFolder:]):
Just beep if the document isn't available yet, since trying to save it as a file
really isn't a good idea.
2007-06-12 Oliver Hunt <oliver@apple.com>
Reviewed by Darin.
Use correct size for BITMAPINFOHEADER -- whoops.
* win/WebIconDatabase.cpp:
(createDIB):
(WebIconDatabase::getOrCreateDefaultIconBitmap):
2007-06-10 David Hyatt <hyatt@apple.com>
Fix for bug 14037, make sure respondsToSelector does the write thing
when invoked on a WebKit plugin's container view.
Reviewed by Mark Rowe
* Plugins/WebKitPluginContainerView.mm:
(-[WebKitPluginContainerView respondsToSelector:]):
2007-06-08 John Sullivan <sullivan@apple.com>
* WebView/WebViewPrivate.h:
Added a FIXME
2007-06-07 Justin Garcia <justin.garcia@apple.com>
Reviewed by Tristan.
<rdar://problem/5250997> A crash occurs when selecting Undo Typing for a page that has been closed in tab
* WebView/WebView.mm:
(-[WebView _clearUndoRedoOperations]): Added.
* WebView/WebViewPrivate.h:
2007-06-07 Oliver Hunt <oliver@apple.com>
Reviewed by Sam "The Intern" Weinig.
Don't be overzealous with the input checks, firstRectForCharacterRange
can be determined even when there is not an active editable region.
This unbreaks editing/input/range-for-empty-document which was broken
by aforementioned overzealousness.
* WebView/WebHTMLView.mm:
(-[WebHTMLView firstRectForCharacterRange:]):
2007-06-07 Oliver Hunt <oliver@apple.com>
Reviewed by Justin.
Add checks to make sure we don't try to create, use
or return invalid ranges to TSM when it calls us despite
not currently being in an editable region.
* WebView/WebHTMLView.mm:
(isTextInput):
(-[WebHTMLView textStorage]):
(-[WebHTMLView firstRectForCharacterRange:]):
(-[WebHTMLView selectedRange]):
(-[WebHTMLView attributedSubstringFromRange:]):
2007-06-06 David Hyatt <hyatt@apple.com>
Make sure to hand back a script object for webkit plugins (the container
view forwards to its plugin child).
Reviewed by sullivan
* Plugins/WebKitPluginContainerView.h:
* Plugins/WebKitPluginContainerView.mm:
(-[WebKitPluginContainerView objectForWebScript]):
2007-06-06 David Hyatt <hyatt@apple.com>
Fix for bug 13972, quicktime doesn't respect CSS clip and overflow properties.
Make sure that calls to [NSView visibleRect] will do the right thing for both
Netscape plugins and WebKit plugins.
Reviewed by olliej
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView visibleRect]):
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
(-[WebBaseNetscapePluginView isOpaque]):
* Plugins/WebKitPluginContainerView.h: Added.
* Plugins/WebKitPluginContainerView.mm: Added.
(-[WebKitPluginContainerView initWithFrame:DOMElement:]):
(-[WebKitPluginContainerView dealloc]):
(-[WebKitPluginContainerView visibleRect]):
* Plugins/WebPluginController.mm:
(-[WebPluginController destroyAllPlugins]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge pluginViewWithPackage:attributeNames:attributeValues:baseURL:DOMElement:loadManually:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.mm:
(-[WebHTMLView addSubview:]):
(-[WebHTMLView willRemoveSubview:]):
2007-06-04 Oliver Hunt <oliver@apple.com>
Reviewed by Geoff and Justin.
Fix for <rdar://problem/5246941> Clicking URL field on
Safari causes halt for a minute when using input methods.
and <rdar://problem/5245964> Safari hangs for several
seconds when trying to select text using mouse
This is a by product of the textStorage hack used to fix
rdar://problem/5000470 -- TSM calls textStorage repeatedly
when changing focus, on certain mouse events, etc. If there
is no selection/editable region we repeatedly create an
NSAttributedString from the full document. If the document is
sufficiently long this starts consuming an inordinate amount of
time.
This check should really have been present in the original
patch.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.mm:
(-[WebHTMLView textStorage]):
2007-05-31 David Hyatt <hyatt@apple.com>
Fix for 11768, Flash plugin does not respect clips set by CSS.
Reviewed by olliej
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
2007-05-30 Mark Rowe <mrowe@apple.com>
Build fixes after r21889.
* ForwardingHeaders/kjs/function.h: Added.
2007-05-29 Mark Rowe <mrowe@apple.com>
Reviewed by Geoff.
64-bit build fix. Ensure that use of WebNSUInteger in headers is matched by WebNSUInteger in implementations.
* DefaultDelegates/WebScriptDebugServer.h:
* DefaultDelegates/WebScriptDebugServer.m:
(-[WebScriptDebugServer webView:didParseSource:baseLineNumber:fromURL:sourceId:forWebFrame:]):
(-[WebScriptDebugServer webView:failedToParseSource:baseLineNumber:fromURL:withError:forWebFrame:]):
* DefaultDelegates/WebScriptDebugServerPrivate.h:
* History/WebBackForwardList.mm:
(-[WebBackForwardList setPageCacheSize:]):
(-[WebBackForwardList pageCacheSize]):
* WebView/WebView.mm:
(-[WebView markAllMatchesForText:caseSensitive:highlight:limit:]):
2007-05-26 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
* MigrateHeaders.make: Added dependency on this makefile itself, which is
useful when you change the sed command or other aspect of this file. My build
failed until I made this fix.
2007-05-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Fixed <rdar://problem/5055182> The page cache has no global cap.
The main WebKit changes are:
1. Changed -[WebBackForwardList setPageCacheSize] and -[WebBackForwardList
pageCacheSize] to accomodate the new global page cache model, updating
their documentation.
2. Added -[WebPreferences setShouldUsePageCache] and -[WebPreferences
shouldUsePageCache] as pending public API.
3. Centralized calculation of object cache and page cache sizes inside
WebPreferences.
Cchanged our old behavior of reading a preference and applying a fudge
factor with a new behavior of just using the preference directly. The
old behavior was confusing and often inappropriate. (For example, if
you set a page cache size of 100, a 256MB machine would somewhat
arbitrarily reduce that number to 98. ???)
* WebView/WebView.mm: Added support for two flags to determine whether
to use the page cache. If either -[WebBackForwardList setPageCacheSize:0]
or -[WebPreferences setShouldUsePageCache:NO] is called, we don't use
the page cache.
2007-05-25 Timothy Hatcher <timothy@apple.com>
Reviewed by Kevin Decker.
<rdar://problem/5219089> Changes for migration of DictionaryServices
* WebView/WebHTMLView.mm:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]): look for the HIDictionaryWindowShow symbol in HIToolbox
2007-05-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Oliver Hunt.
Fixed global initializer (like you fix a dog).
I'm not sure how our script missed this. I tested, and it generally doesn't
seem to work very well.
* WebView/WebHTMLView.mm: Allocate lazily to avoid the performance hit of
a global initializer.
(promisedDataClient):
(-[WebHTMLViewPrivate dealloc]):
(-[WebHTMLViewPrivate clear]):
(-[WebHTMLView setPromisedDragTIFFDataSource:WebCore::]):
2007-05-25 Brady Eidson <beidson@apple.com>
Reviewed by Darin
<rdar://problem/5228371> - REGRESSION - Certain mail message bodies display as empty
This is due to http://trac.webkit.org/projects/webkit/changeset/21480 which unintentionally
made applewebdata urls result in check.call(false) instead of check.call(true)
Best place for a fix is to have the FrameLoaderClient::canHandleRequest() call return true, which
really is rooted in WebView
<rdar://problem/5229587> tracks adding a layout test
* WebView/WebView.mm:
(+[WebView _canHandleRequest:]): Return true for applewebdata URLs
2007-05-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler, Tim Hatcher.
"unsigned" => "WebNSUInteger" in public API.
* History/WebBackForwardList.h:
* WebView/WebScriptDebugDelegate.h:
* WebView/WebUIDelegate.h:
* WebView/WebViewPrivate.h:
2007-05-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Moved JavaScriptCore-related pending public API to public API.
* MigrateHeaders.make: Hack to prevent <JavaScriptCore/JSBase.h> from
automatically converting to <WebKit/JSBase.h>
Moved -windowObject and -globalContext
* WebView/WebFramePrivate.h: from here
* WebView/WebFrame.h: to here
* WebView/WebFrame.mm: and out of its temporary category
Moved -didClearWindowObject:forFrame:
* WebView/WebViewPrivate.h: from here
* WebView/WebFrameLoadDelegate.h: to here
2007-05-25 John Sullivan <sullivan@apple.com>
Reviewed by Anders and Tim
- fixed <rdar://problem/5226000> REGRESSION: In Gmail and Mail, a hang occurs when attempting
to grammar/spellcheck a word in a reply
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::checkGrammarOfString):
Fixed recently-introduced false assumption that NSNotFound == -1
2007-05-24 dethbakin <bdakin@apple.com>
Reviewed by Geoff.
Fix for <rdar://problem/5023545> QuickBooks Pro 2007:hang/crash
after closing QuickBooks Tutorial Center with Leopard9A377
We can hit a race condition where drawRect will be called after the
WebView has closed. Quickbooks does not properly close the WebView
and set the UIDelegate to nil, so the UIDelegate is stale and we
crash. This is a regression because the code that uses the
UIDelegate in the drawRect code path was only added recently. The
method that the UIDelegate calls into is new -- it does not exist
on Tiger -- so there is no harm in not running this code for
applications linked against older WebKits. Other applications may
run into this same bug so I am not doing a bundle
check...particularly because, as I mentioned, the new UIDelegate
call would not be implemented by older clients anyway.
* Misc/WebKitVersionChecks.h:
* WebView/WebHTMLView.mm:
(-[WebHTMLView drawSingleRect:]):
2007-05-24 Darin Adler <darin@apple.com>
* English.lproj/StringsNotToBeLocalized.txt: Update for recent changes.
2007-05-24 Oliver Hunt <oliver@apple.com>
Reviewed by Adam, Darin, and Geoff.
Fix for <rdar://problem/5000470> REGRESSION: The IM reconvert
function returns incorrect symbol due to inconsistent range
domains in TSM
Text Services Management uses ranges provided by the
NSTextInput API to index into the string return by
-[WebHTMLView string]. As a result some input methods
incorrectly get their candidate text from the beginning
of the document instead of from the input element.
TSM prefers to query -textStorage over -string so as a
workaround we provide an implementation of -textStorage that
returns the content of the current text input. TSM only ever
queries the result of textStorage as an NSAttributedString so
we do not need to implement a fake NSTextStorage class
This should not cause harm to anything else as textStorage is
actually a method on NSTextView, which we clearly are not. TSM
only queries the method because it uses respondsToSelector to
control behaviour.
* WebView/WebHTMLView.mm:
(-[WebHTMLView textStorage]):
2007-05-24 David Harrison <harrison@apple.com>
Reviewed by Tim Hatcher.
<rdar://problem/5225343> REGRESSION: With View Source window opened, navigating to a different URL in the browser window results in a crash at WebCore::FrameLoader::frameHasLoaded()
_private->loader->frameLoader() was not being nil checked.
* WebView/WebDataSource.mm:
(-[WebDataSource request]):
Add nil check for _private->loader->frameLoader()
2007-05-23 Anders Carlsson <andersca@apple.com>
Reviewed by Geoff.
<rdar://problem/3663808> Resize large images to fit in the browser window
Add new WebPreferences SPI.
* WebView/WebPreferenceKeysPrivate.h:
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
(-[WebPreferences enableAutomaticImageResizing]):
(-[WebPreferences setEnableAutomaticImageResizing:]):
* WebView/WebPreferencesPrivate.h:
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2007-05-23 Sam Weinig <sam@webkit.org>
Reviewed by Darin.
Patch for http://bugs.webkit.org/show_bug.cgi?id=13830
Auto-generate JS DOM bindings for HTMLDocument and most of the rest
of HTMLElement
* MigrateHeaders.make: add DOMHTMLDocumentPrivate.h
* WebKit.xcodeproj/project.pbxproj:
2007-05-23 Oliver Hunt <oliver@apple.com>
Reviewed by Geoff.
Fix for <rdar://problem/5223782> REGRESSION: Can't drag and drop a standalone image
The main resource for a standalone image webarchive has the same mimetype as the
underlying image.
* Misc/WebNSPasteboardExtras.mm:
(-[NSPasteboard _web_writePromisedRTFDFromArchive:containsImage:]):
2007-05-22 Sam Weinig <sam@webkit.org>
Reviewed by Adam.
Patch for http://bugs.webkit.org/show_bug.cgi?id=13833
Add ObjC DOM binding for HTMLMarqeeElement
- Also adds missing DOMHTMLFramePrivate.
* MigrateHeaders.make:
2007-05-22 Darin Adler <darin@apple.com>
Reviewed by Geoff.
* WebInspector/webInspector/treeoutline.js: Use ownerDocument instead of non-standard
document property.
2007-05-22 Adele Peterson <adele@apple.com>
Reviewed by Darin.
Adding some asserts to help detect other cases of <rdar://problem/5171145>
* WebCoreSupport/WebFrameBridge.mm: (-[WebFrameBridge makeFirstResponder:]):
2007-05-22 Brady Eidson <beidson@apple.com>
Reviewed by Kevin (Sarge)
<rdar://problem/5219885> - Crash after closing a inline popup ad at http://news.yahoo.com/
This regressed in http://trac.webkit.org/projects/webkit/changeset/21618
* WebView/WebFrame.mm:
(-[WebFrame dataSource]): Null check the frameloader
2007-05-21 Adele Peterson <adele@apple.com>
Fix by Darin, reviewed by me.
Fix for <rdar://problem/5171145> Safari crashed closing tab in NSInputContext updateInputContexts
* WebView/WebFrameView.mm: (-[WebFrameView _setDocumentView:]): If the old view is the first responder,
then set the window's first responder to nil so we don't leave the window pointing to a view that's no longer in it.
2007-05-21 Brady Eidson <beidson@apple.com>
Making the importance of my last change more clear
* WebView/WebViewPrivate.h: "Leave for Dashboard, people!"
2007-05-21 Brady Eidson <beidson@apple.com>
Reviewed by Kevin (Sarge)
<rdar://problem/5217124> - Re-add mistakenly removed SPI
* WebView/WebView.mm:
(-[WebView handleAuthenticationForResource:challenge:fromDataSource:]):
* WebView/WebViewPrivate.h:
2007-05-21 Anders Carlsson <andersca@apple.com>
Reviewed by Ada.
<rdar://problem/5200816> REGRESSION: With Shiira 1.2.2 , I can't open embedded link in flash object by clicking (http:/www.adobe.com )
Null check the request.
* WebView/WebView.mm:
(+[WebView _canHandleRequest:]):
2007-05-19 Maciej Stachowiak <mjs@apple.com>
Reviewed by Geoff.
<rdar://problem/5205358> REGRESSION (r21367): All messages appear entirely blank when running Mail off of tip of tree WebKit
The fix is to return nil from [WebFrame dataSource] when it has not loaded anything but the fake
empty initial document. However, WebKit still needs the real data source internally, so I also
added a [WebFrame _dataSource] method that skips this check, and made WebKit use it throughout.
* Misc/WebNSAttributedStringExtras.mm:
(fileWrapperForElement):
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView dataSource]):
* Plugins/WebNullPluginView.mm:
(-[WebNullPluginView viewDidMoveToWindow]):
* Plugins/WebPluginController.mm:
(-[WebPluginController URLPolicyCheckReferrer]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge dataSource]):
(-[WebFrameBridge redirectDataToPlugin:]):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::makeDocumentView):
(WebFrameLoaderClient::forceLayoutForNonHTML):
(WebFrameLoaderClient::prepareForDataSourceReplacement):
(WebFrameLoaderClient::canCachePage):
* WebCoreSupport/WebViewFactory.mm:
(-[WebViewFactory bridgeForView:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebArchiver.mm:
(+[WebArchiver archiveFrame:]):
(+[WebArchiver archiveMainResourceForFrame:]):
(+[WebArchiver _archiveWithMarkupString:fromFrame:nodes:]):
(+[WebArchiver archiveSelectionInFrame:]):
* WebView/WebFrame.mm:
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _addChild:]):
(-[WebFrame _dataSource]):
(-[WebFrame DOMDocument]):
(-[WebFrame dataSource]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.mm:
(-[WebHTMLView _setPrinting:minimumPageWidth:maximumPageWidth:adjustViewSize:]):
* WebView/WebRenderNode.mm:
(-[WebRenderNode initWithWebFrameView:]):
* WebView/WebView.mm:
(-[WebView _mainFrameOverrideEncoding]):
(-[WebView mainFrameURL]):
(-[WebView mainFrameTitle]):
(-[WebView mainFrameIcon]):
(-[WebView validateUserInterfaceItemWithoutDelegate:]):
(-[WebView replaceSelectionWithArchive:]):
(-[WebView _isLoading]):
(-[WebView _performTextSizingSelector:withObject:onTrackingDocs:selForNonTrackingDocs:newScaleFactor:]):
(-[WebView _notifyTextSizeMultiplierChanged]):
2007-05-18 Oliver Hunt <oliver@apple.com>
Reviewed by Sam.
Fix for http://bugs.webkit.org/show_bug.cgi?id=13782
REGRESSION (r21528-r21533): Failing editing/selection/drag-in-iframe in pixel mode
r21533 made used a DOMElement as the source for promise data, this meant it had to
clear the dragging pasteboard following the drag. In DRT a drag is non-blocking
so this resulted in us prematurely clearing the pasteboard.
This patch avoids this problem by referencing the source CachedImage rather than the
DOMElement, so we don't need to worry about retaining an entire document forever, so
we don't need to clear the dragging pasteboard following the drag.
* Misc/WebNSPasteboardExtras.mm:
(imageFromElement):
Extract the underlying CachedImage from a DOMElement
(-[NSPasteboard _web_writeImage:element:URL:title:archive:types:source:]):
Use a CachedImage instead of a DOMElement
* WebCoreSupport/WebDragClient.mm:
(WebDragClient::startDrag):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.mm:
(-[WebHTMLViewPrivate dealloc]):
(-[WebHTMLViewPrivate clear]):
(-[WebHTMLView pasteboardChangedOwner:]):
(-[WebHTMLView pasteboard:provideDataForType:]):
(-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
(-[WebHTMLView WebCore::]):
(-[WebHTMLView setPromisedDragTIFFDataSource:WebCore::]):
Use CachedImage rather than DOMElement as promised data source
* WebView/WebHTMLViewInternal.h:
* WebView/WebHTMLViewPrivate.h:
2007-05-18 Tristan O'Tierney <tristan@apple.com>
Reviewed by Brady E.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::download):
asked the webframeloaderclient for its webview's history and
injected the originated url into the created WebDownload
2007-05-18 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
Improvement to WebKit part of fix for 5201499 based on more modern understanding. (That is,
a couple of hours more modern.)
* WebView/WebUIDelegatePrivate.h:
add showPanel: parameter to just-introduced delegate method webView:saveFrameView:
* WebView/WebPDFView.mm:
(-[WebPDFView PDFViewSavePDFToDownloadFolder:]):
pass NO for new showPanel: parameter, and update comment
2007-05-18 Maciej Stachowiak <mjs@apple.com>
Reviewed by John.
<rdar://problem/5204792> REGRESSION (r21367): System widgets are drawn with vertical/horizontal scroll bars
No test because the bug requires calling setAllowsScrolling: to reproduce.
* WebView/WebFrameView.mm:
(-[WebFrameView setAllowsScrolling:]): Update the FrameView's scroll state as well as the one
on WebDynamicScrollBarsView, otherwise this setting won't stick if the frame has already loaded
a document.
2007-05-18 Geoffrey Garen <ggaren@apple.com>
Fixed spelling error.
* WebView/WebViewPrivate.h:
2007-05-18 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
WebKit part of fix for 5201499 (support for PDFKit UI for saving PDFs to disk)
Also, the PDFKit mechanism for notifying clients about "Open File Externally" was
changed from a notification to a delegate method. The notification was new to
Leopard, so removing it doesn't affect clients in the field.
* WebView/WebUIDelegatePrivate.h:
Declared new UI delegate method webView:saveFrameView:, analogous to the existing
webView:printFrameView:
* WebView/WebPDFView.mm:
removed declaration of _webkit_PDFKitLaunchNotification
(-[WebPDFView viewDidMoveToWindow]):
don't observe _webkit_PDFKitLaunchNotification
(-[WebPDFView viewWillMoveToWindow:]):
ditto
(-[WebPDFView PDFViewOpenPDFInNativeApplication:]):
new PDFKit delegate method, replaces our use of _webkit_PDFKitLaunchNotification
(-[WebPDFView PDFViewSavePDFToDownloadFolder:]):
new PDFKit delegate method, calls through to new WebKit UI delegate method
2007-05-17 Oliver Hunt <oliver@apple.com>
Reviewed by Justin.
Fix for <rdar://problem/4244861> Safari fails to create image file
after releasing dragged image that has changed on source page
This patch fixes this bug by manually creating an NSFileWrapper from
the TIFF promise data for a drag if it is available. This bypasses
the problem of the required resource no longer being held due to page
loads or other constraints.
We need to leave the old path in place to allow for the case where
the promised data is not available.
* WebCoreSupport/WebDragClient.mm:
(WebDragClient::declareAndWriteDragImage):
Always use the top WebHTMLView as the pasteboard owner, this is
safe as we only use the owner for resolving promised types.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _writeSelectionToPasteboard:]):
(-[WebHTMLView writeSelectionToPasteboard:types:]):
Always use the top WebHTMLView as the pasteboard owner.
(-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
Add path to create NSFileWrapper from promise data.
2007-05-17 Oliver Hunt <oliver@apple.com>
Reviewed by Adam.
Fix for <rdar://problem/4343832> Trying to drag a large 6.2MB jpeg image
out of Safari is unexpectedly slow (4 copies of image plus RTF document on pasteboard)
This patch causes the construction of the RTF and TIFF data to be delayed until requested.
We delay TIFF construction from a DOMElement as this may require generating TIFF data
from the CachedImage, which is slow. To allow the TIFF data to be created later the
it's necessary to add a reference to the source DOMElement to the view.
* Misc/WebNSPasteboardExtras.h:
* Misc/WebNSPasteboardExtras.mm:
(-[NSPasteboard _web_writePromisedRTFDFromArchive:containsImage:]):
Implements the delayed write of RTF data
(-[NSPasteboard _web_writeImage:element:URL:title:archive:types:source:]):
Set up the pasteboard to allow the data writing to be delayed
(-[NSPasteboard _web_declareAndWriteDragImageForElement:URL:title:archive:source:]):
Now we need to pass the WebHTMLView on to _web_writeImage:element:URL:title:archive:types:source:
* WebCoreSupport/WebDragClient.mm:
(WebDragClient::startDrag):
Clear the dragging pasteboard once the drag has ended to ensure we don't hold references
to anything longer than we need to.
(WebDragClient::declareAndWriteDragImage):
* WebView/WebHTMLView.mm:
(-[WebHTMLViewPrivate dealloc]):
(-[WebHTMLViewPrivate clear]):
(-[WebHTMLView pasteboardChangedOwner:]):
Make sure we clear out the DOMElement reference once it is no longer needed
(-[WebHTMLView pasteboard:provideDataForType:]):
Provide delayed data
(-[WebHTMLView _writeSelectionToPasteboard:]):
Make sure we set pasteboard ownership correctly
(-[WebHTMLView promisedDragTIFFDataSource]):
(-[WebHTMLView setPromisedDragTIFFDataSource:]):
(-[WebHTMLView writeSelectionToPasteboard:types:]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebHTMLViewPrivate.h:
* WebView/WebView.mm:
(-[WebView _writeImageForElement:withPasteboardTypes:toPasteboard:]):
2007-05-16 Anders Carlsson <andersca@apple.com>
Reviewed by Darin.
<rdar://problem/5207156> Hamachi test tool causes assertion in FormCompletionController in Safari
Update for WebCore changes.
* WebView/WebFrame.mm:
(-[WebFrame _loadURL:referrer:intoChild:]):
2007-05-15 Oliver Hunt <oliver@apple.com>
Reviewed by Sam and Geoff.
Removing dead code left behind from drag and drop refactoring.
* WebCoreSupport/WebFrameBridge.mm:
* WebView/WebHTMLView.mm:
* WebView/WebHTMLViewPrivate.h:
2007-05-15 Bruce Q Hammond <bruceq@apple.com>
Reviewed by Darin.
Correction of previous patch for http://bugs.webkit.org/show_bug.cgi?id=13578
This corrects the sign of the Y-Axis origin adjustment.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
2007-05-15 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej Stachowiak.
Patch: fixed <rdar://problem/5198890> .5% performance regression caused
by r21307
The only code r21307 added that runs during the PLT is a frame load delegate
-respondsToSelector: call inside windowObjectCleared(), so it seems like
our message dispatch overhead for the frame load delegate is significant.
This patch is a straight port of Maciej's fix for the same problem in the
resource load delegate. The solution is simple enough: don't use Objective-C.
Instead, use a special structure that caches which methods the delegate
implements, along with pointers to those methods.
I verified each frame load delegate callback in the debugger, except for
-webView:didFailLoadWithError:forFrame:, which is not implemented by Safari
or DumpRenderTree.
* WebKit/DefaultDelegates/WebDefaultFrameLoadDelegate.h: Removed.
* WebKit/DefaultDelegates/WebDefaultFrameLoadDelegate.m: Removed.
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge windowObjectCleared]): I also removed a misleading
comment here. The JS debugger caches the windowScriptObject, so you do
need to re-create the debugger every time you invalidate the old
WebScriptObject wrapper for the window object and create a new one, or
the debugger will stop working. We could fix this in a number of ways,
but <rdar://problem/4608404> is not the key issue.
2007-05-15 Maciej Stachowiak <mjs@apple.com>
Reviewed by Hyatt and Lars.
- fixed <rdar://problem/5201758> REGRESSION: Stop button enabled and other problems caused by [WebView currentURL] returning non-nil for empty window
* WebView/WebDataSource.mm:
(-[WebDataSource request]): Return nil when we are still showing the initial empty doc
2007-05-14 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Updated for WebCore move to PageCache singleton. Also removed some WebCore::
prefixes and replaced them with 'using namespace WebCore'.
* History/WebHistoryItem.mm:
(+[WebHistoryItem _releaseAllPendingPageCaches]):
(-[WebWindowWatcher windowWillClose:]):
2007-05-13 Darin Adler <darin@apple.com>
- one more retain/release for a tiny bit more robustness
* WebView/WebPDFView.mm:
(-[WebPDFView _updatePreferences:]): [prefs release]
(-[WebPDFView _updatePreferencesSoon]): [prefs retain]
2007-05-13 Darin Adler <darin@apple.com>
Reviewed by Geoff.
- fix <rdar://problem/5188400> Webkit crashes going back from PDF at perl.org site
* WebView/WebPDFView.h: Replace _updatePreferencesTimer with _willUpdatePreferencesSoon BOOL.
Also remove unneeded @public that gives other classes access to our dataSource member.
* WebView/WebPDFView.mm: Rearrange top of file a bit, remove forward declaration of the
_cancelUpdatePreferencesTimer method.
(-[WebPDFView dealloc]): Removed call to _cancelUpdatePreferencesTimer.
(-[WebPDFView _updatePreferencesNow:]): Added WebPreferences parameter. This sidesteps problems
where the dataSource is no longer present by not looking at the dataSource field at all.
Also removed the call to _cancelUpdatePreferencesTimer, added code to set _willUpdatePreferencesSoon
to NO and added a release to balance a retain I did in _updatePreferencesSoon.
(-[WebPDFView _updatePreferencesSoon]): Changed to use performSelectorAfterDelay instead of
an NSTimer. Pass in the preferences object as a parameter, since we might not be able to get to
the dataSource when the timer fires.
2007-05-10 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
"IconDatabase::sharedIconDatabase()" => "iconDatabase()" for terseness.
2007-05-10 Adele Peterson <adele@apple.com>
Reviewed by Hyatt.
WebKit part of fix for <rdar://problem/4100616> Doing a "find" in RSS doesn't scroll to result
Updated to use selectionRect instead of visibleSelectionRect. selectionRect() now returns the visible rect by default.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]):
(-[WebHTMLView selectionImageRect]):
2007-05-10 dethbakin <bdakin@apple.com>
Reviewed by Darin.
Fix for <rdar://problem/5191941> Leopard: Adobe Acrobat 8:
Distiller 8 needs same check fix as 4992521
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]): Adobe
Distiller needs the same quirk.
2007-05-10 Maciej Stachowiak <mjs@apple.com>
Reviewed by Oliver.
- WebKit part of fix for:
<rdar://problem/5063277> blank screen after login to Citibank Online (accessing document before frame starts loading cancels load)
<rdar://problem/5159541> REGRESSION (r20972): Wall Street Journal pages replaced by advertisements (13465)
The basic approach is to have Frames start out containing an empty document instead of absolutely nothing,
so there is no need to initialize them on demand. Various side effects of that cause both of these bugs.
However, this caused many regressions so I had to fix the fallout.
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::takeFocus): Avoid focus cycle problems (can happen in DumpRenderTree
with initial empty document now).
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge finishInitializingWithPage:frameName:frameView:ownerElement:]): init the frame.
(-[WebFrameBridge determineObjectFromMIMEType:URL:]): return image type when appropriate
* WebView/WebFrame.mm:
(-[WebFrame stopLoading]): use stopForUserCancel().
* WebView/WebFrameView.mm:
(-[WebFrameView _makeDocumentViewForDataSource:]): assume html when no mime type available.
* WebView/WebView.mm:
(-[WebView becomeFirstResponder]): Track whether we are becoming first responder from
outside the view.
(-[WebView _becomingFirstResponderFromOutside]): Return this value.
* WebView/WebViewInternal.h:
2007-05-09 Oliver Hunt <oliver@apple.com>
rs=Adele.
The previous patch (r21346) broke editing, rolling out
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]):
(-[WebHTMLView doCommandBySelector:]):
2007-05-09 Adele Peterson <adele@apple.com>
Reviewed by Oliver.
Re-applying fix for <rdar://problem/5107538> REGRESSION: Page scroll when selecting characters from inline input candidate window by arrow buttons
http://bugs.webkit.org/show_bug.cgi?id=13263
We don't need to call interpretKeyEvents for cmd-key events as
they events will be interpreted by performKeyEquivalent.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]):
(-[WebHTMLView doCommandBySelector:]):
2007-05-09 Mark Rowe <mrowe@apple.com>
Build fix to keep the buildbot happy.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
2007-05-08 Bruce Q Hammond <bruceq@apple.com>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=13578
Bug 13578: When QD plugins draw to an offscreen bitmap the origin is not correct
Now we have correct handling of the origin when QD plugins draw to
offscreen bitmaps.
Also the clipping code for this path was doing unnecessary work which
caused incorrect results; it has been removed.
This change should not affect Safari and in general will only affect
plugins (e.g. Flash) drawing to a CGBitmapContext.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
2007-05-08 Steve Falkenburg <sfalken@apple.com>
Reviewed by Darin.
Implemented spelling/grammar related WebEditorClient methods.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::ignoreWordInSpellDocument): Added. Call through to NSSpellChecker.
(WebEditorClient::learnWord): Added. Call through to NSSpellChecker.
(WebEditorClient::checkSpellingOfString): Added. Call through to NSSpellChecker.
(WebEditorClient::checkGrammarOfString): Added. Call through to NSSpellChecker.
(WebEditorClient::updateSpellingUIWithGrammarString): Added. Call through to NSSpellChecker.
(WebEditorClient::updateSpellingUIWithMisspelledWord): Added. Call through to NSSpellChecker.
(WebEditorClient::showSpellingUI): Added. Call through to NSSpellChecker.
(WebEditorClient::spellingUIIsShowing): Added. Call through to NSSpellChecker.
(WebEditorClient::getGuessesForWord): Added. Call through to NSSpellChecker.
2007-05-08 Steve Falkenburg <sfalken@apple.com>
Reviewed by Ada.
Slight modification to last editor method fix.
* WebCoreSupport/WebEditorClient.h:
(WebEditorClient::updateSpellingUIWithGrammarString):
2007-05-07 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej Stachowiak.
Fixed <rdar://problem/5140447> API for fetching JSGlobalContextRef from
WebView or WebFrame
Added -[WebFrame windowObject] and -[WebFrame globalContext], along with
a new frame load delegate method, - (void)webView:(WebView *)webView
didClearWindowObject:(WebScriptObject *)windowObject forFrame:(WebFrame *)frame.
This is all to support briding between the WebScriptObject and JavaScriptCore
APIs.
Also fixed more of <rdar://problem/4395622> API: WebScriptObject.h incorrectly
reports that -isSelectorExcludedFromWebScript returns NO by default, and
generally cleaned up the WebScriptObject headerdoc.
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge windowObjectCleared]):
* WebView/WebFrame.mm:
(-[WebFrame windowObject]):
(-[WebFrame globalContext]):
* WebView/WebFramePrivate.h:
* WebView/WebViewPrivate.h:
2007-05-07 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5180384> webView:validateUserInterfaceItem:defaultValidation: does not get called on WebUIDelegates
Call the delegate when the one of our views gets a validateUserInterfaceItem: call.
* WebView/WebHTMLView.mm:
(-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]): Validate without the delegate.
(-[WebHTMLView validateUserInterfaceItem:]): Call the delegate with the result of validateUserInterfaceItemWithoutDelegate:.
* WebView/WebPDFView.mm:
(-[WebPDFView validateUserInterfaceItemWithoutDelegate:]): Validate without the delegate.
(-[WebPDFView validateUserInterfaceItem:]): Call the delegate with the result of validateUserInterfaceItemWithoutDelegate:.
* WebView/WebView.mm:
(-[WebView _responderValidateUserInterfaceItem:]): Call validateUserInterfaceItemWithoutDelegate: to prevent asking the delegate twice.
(-[WebView validateUserInterfaceItemWithoutDelegate:]): Validate without the delegate.
(-[WebView validateUserInterfaceItem:]): Call the delegate with the result of validateUserInterfaceItemWithoutDelegate:.
2007-05-07 Brady Eidson <beidson@apple.com>
Actually finish the code move from my last checkin
* History/WebHistoryItem.mm:
(-[WebHistoryItem _transientPropertyForKey:]):
(-[WebHistoryItem _setTransientProperty:forKey:]):
2007-05-07 Brady Eidson <beidson@apple.com>
Rubberstamped by Kevin (Sarge)
Make _transientPropertyForKey: and _setTransientProperty:forKey: SPI
* History/WebHistoryItemInternal.h:
* History/WebHistoryItemPrivate.h:
2007-05-04 Geoffrey Garen <ggaren@apple.com>
Reviewed by Tim Hatcher.
First step in fixing <rdar://problem/5055182> The back cache has no global cap
Stop giving SnapBack infinite cache-ability. Instead, make SnapBack rely
on the underlying back cache.
I left -setAlwaysAttemptToUsePageCache: as an empty stub because we don't
want to break Safari 2.0, but I removed its header declaration so nobody
else starts using it.
* History/WebHistoryItem.mm:
(-[WebHistoryItem setAlwaysAttemptToUsePageCache:]):
* History/WebHistoryItemPrivate.h:
2007-05-04 Geoffrey Garen <ggaren@apple.com>
Reviewed by Brady Eidson.
Some cleanup in preparation for fixing <rdar://problem/5055182> The
back/forward cache has no global cap
Unified naming of WebKit/WebCore b/f lists -- instead of the potpourri
of webBackForwardList, backForwardList, list, kitList, coreList, listWrapper,
and webCoreBackForwardList, we use webBackForwardList for WebKit and
backForwardList for WebCore, matching their respective class names.
Removed "private" versions of kit() and core() -- kit() and core() are
canonically used for converting between WebKit API objects and WebCore
API objects. I think it's clearer to have only one way to do this.
Removed COMPUTE_DEFAULT_PAGE_CACHE_SIZE, since it was unused.
Removed _clearPageCache, since it was unused and it duplicated -setPageCacheSize:0.
Removed _usesPageCache, since it was unused and it duplicated -pageCacheSize.
2007-05-04 Brady Eidson <beidson@apple.com>
Reviewed by Mark Rowe
Added main thread assertion to WebHTMLView to help make sure 3rd party clients aren't trying
to draw on secondary threads
* WebView/WebHTMLView.mm:
(-[WebHTMLView drawRect:]): Added ASSERT_MAIN_THREAD()
2007-05-04 Anders Carlsson <andersca@apple.com>
Reviewed by Antti.
<rdar://problem/5179977> Use the correct URLs when dispatching delegate methods for data loads.
* WebView/WebFrame.mm:
(-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]):
If the base URL is nil, set it to "about:blank", and set the response URL to a generated applewebdata URL.
* WebView/WebView.mm:
(+[WebView _canHandleRequest:]):
No need to special-case applewebdata URLs here anymore, they're only used in responses.
2007-05-03 Steve Falkenburg <sfalken@apple.com>
Reviewed by Oliver.
Add missing user description parameter to spelling-related editor client method.
* WebCoreSupport/WebEditorClient.h:
(WebEditorClient::updateSpellingUIWithGrammarString):
2007-05-03 TImothy Hatcher <timothy@apple.com>
Reviewed by Kevin.
<rdar://problem/4975212> REGRESSION: With NetNewsWire 2.1.1, the contextual menu shows extra menu items when focus
is placed in input or textarea field
The NetNewsWire UI delegate isn't expecting calls for form controls, so we need to do a linked-on-or-after check.
If the application was linked against Tiger or earlier and the element is a text form control, just return the
default menu items and bypass the delegate call completely.
* WebCoreSupport/WebContextMenuClient.mm:
(isPreVersion3Client): Cache the result of the WebKitLinkedOnOrAfter call
(fixMenusToSendToOldClients): Call the new isPreVersion3Client()
(fixMenusReceivedFromOldClients): Ditto.
(WebContextMenuClient::getCustomMenuFromDefaultItems): Return the default menu items if the element is a text form control.
2007-05-03 Mark Rowe <mrowe@apple.com>
Reviewed by Geoff and Kevin.
<rdar://problem/5141290> WebAssertions.h is still needed by some internal clients
Second shot at fixing this error. Stub out the macros rather than forwarding to JavaScriptCore, which would
leave clients using this header trying to resolve JavaScriptCore symbols against WebKit when linking. This
should only happen in production builds when assertions should be disabled anyway as anyone building a
development configuration should be in a position to move away from using this header.
* Misc/WebAssertions.h:
2007-05-03 Timothy Hatcher <timothy@apple.com>
Reviewed by Kevin.
<rdar://problem/5067707> REGRESSION: "Open Link" contextual menu item appears twice in Mail
Remove the check for Mail in fixMenusToSendToOldClients and fixMenusReceivedFromOldClients
when linked on or after Leopard. The isAppleMail() function is still used for Tiger Mail fixups.
* WebCoreSupport/WebContextMenuClient.mm:
(fixMenusToSendToOldClients):
(fixMenusReceivedFromOldClients):
2007-05-02 Anders Carlsson <andersca@apple.com>
Reviewed by Brady.
<rdar://problem/5151113> Assertion firing in [FrameProgressEntry addChild:forDataSource:] when navigating cnn.com
The assertion fired because a plug-in was trying to load a subresource when a new load had started but not yet
committed. The check that would have prevented this was removed in order to fix <rdar://problem/5085897>.
This puts back the check but changes it to allow loads where the target is the same frame as the plugin's parent frame.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
2007-04-27 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
There were only a couple calls to ResourceLoadDelegate forwarder left,
this removes the calls and adds a new cached method for didFailLoad.
* WebKit/DefaultDelegates/WebDefaultResourceLoadDelegate.h: Removed.
* WebKit/DefaultDelegates/WebDefaultResourceLoadDelegate.m: Removed.
* WebKit/Plugins/WebNullPluginView.mm: Call the resource load delegate directly.
* WebKit/WebCoreSupport/WebFrameLoaderClient.mm: Call the cached didFailLoad delegate function.
* WebKit/WebKit.xcodeproj/project.pbxproj: Remove WebDefaultResourceLoadDelegate.
* WebKit/WebView/WebDataSource.mm: Remove the #import for WebDefaultResourceLoadDelegate.h
* WebKit/WebView/WebView.mm: Remove the ResourceLoadDelegate forwarder, and remove a method that isn't used.
* WebKit/WebView/WebViewInternal.h: Ditto.
* WebKit/WebView/WebViewPrivate.h: Remove a method that is no longer used.
2007-04-27 David Harrison <harrison@apple.com>
Reviewed by Darin.
<rdar://problem/5160627> Export JS list creation support as ObjC SPI for Mail
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.mm:
(-[WebHTMLView _selectedRange]):
(-[WebHTMLView _shouldDeleteRange:]):
(-[WebHTMLView _canEdit]):
(-[WebHTMLView _canEditRichly]):
(-[WebHTMLView _hasSelection]):
(-[WebHTMLView _hasSelectionOrInsertionPoint]):
(-[WebHTMLView _hasInsertionPoint]):
(-[WebHTMLView _isEditable]):
Condense the check for nil [self frame].
Remove canEditRichly checks and rely on the editor to do the check instead.
(-[WebHTMLView _insertOrderedList]):
(-[WebHTMLView _insertUnorderedList]):
New.
(-[WebHTMLView _canIncreaseSelectionListLevel]):
(-[WebHTMLView _canDecreaseSelectionListLevel]):
(-[WebHTMLView _increaseSelectionListLevel]):
(-[WebHTMLView _increaseSelectionListLevelOrdered]):
(-[WebHTMLView _increaseSelectionListLevelUnordered]):
(-[WebHTMLView _decreaseSelectionListLevel]):
Moved from bridge to frame editor.
* WebView/WebHTMLViewPrivate.h:
Add _insertOrderedList and _insertUnorderedList to WebHTMLView(WebPrivate)
2007-04-27 Brady Eidson <beidson@apple.com>
Rubberstamped by Mark
Remove default implementation of UIDelegate method that was removed
I have also been instructed to give Tim a hard time about this one - apparently
it was his job to clean it out and he failed... failed miserably.
:)
* DefaultDelegates/WebDefaultUIDelegate.m: Removed webViewPrint:
2007-04-27 Maciej Stachowiak <mjs@apple.com>
Reviewed by Mark.
<rdar://problem/5154113> Repro ASSERT (would be crash) in KJS::GCLock::GCLock (13462)
http://bugs.webkit.org/show_bug.cgi?id=13462
* WebInspector/WebInspector.m:
(-[WebInspectorPrivate dealloc]): Delay release of WebView to avoid GC re-entrancy.
2007-04-27 Anders Carlsson <andersca@apple.com>
Reviewed by Mitz.
<rdar://problem/5165755>
View Source is broken; empty window is shown
Return YES for applewebdata URLs.
* WebView/WebView.mm:
(+[WebView _canHandleRequest:]):
2007-04-26 Oliver Hunt <oliver@apple.com>
Reviewed by Adam.
Fix <rdar://problem/5061252> REGRESSION: In Gmail, image fails
to be inserted into message field after dragging
Don't try to create <img> tags for local image files as it results
in the potential to submit forms that look like they have an image,
when in reality they don't.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _documentFragmentWithPaths:]):
2007-04-26 Anders Carlsson <andersca@apple.com>
Reviewed by Maciej.
<rdar://problem/5049099> documents no longer have a default base URL
If the base URL is nil, then create a unique applewebdata URL to match what Tiger WebKit does.
* WebView/WebFrame.mm:
(createUniqueWebDataURL):
(-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]):
2007-04-25 Oliver Hunt <oliver@apple.com>
Rubber stamped by Adele.
Roll out WebKit changes from from r21052 to fix regression noted in
<rdar://problem/5159556> REGRESSION: In Mail, pressing option-command- ' doesn't decrease block quote in selection
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]):
(-[WebHTMLView doCommandBySelector:]):
2007-04-25 Steve Falkenburg <sfalken@apple.com>
Reviewed by Adam.
Mac callbacks for new spelling methods in WebEditorClient.
Not used yet.
* WebCoreSupport/WebEditorClient.h:
(WebEditorClient::ignoreWordInSpellDocument):
(WebEditorClient::learnWord):
(WebEditorClient::checkSpellingOfString):
(WebEditorClient::checkGrammarOfString):
(WebEditorClient::updateSpellingUIWithGrammarString):
(WebEditorClient::updateSpellingUIWithMisspelledWord):
(WebEditorClient::showSpellingUI):
(WebEditorClient::spellingUIIsShowing):
(WebEditorClient::getGuessesForWord):
2007-04-24 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler, Tim Hatcher.
Fixed a few NSAutoreleasePool issues I noticed while reviewing Brady's patch.
* Carbon/CarbonUtils.m:
(PoolCleaner): Call -drain instead of -release, since -release is a
no-op in a GC world.
* Misc/WebKitErrors.m:
(registerErrors): Condensed onto one line.
* Plugins/WebPluginDatabase.m:
(-[WebPluginDatabase refresh]): Call -drain instead of -release, since
-release is a no-op in a GC world.
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::setStatusbarText):
* WebInspector/WebNodeHighlightView.m:
(-[WebNodeHighlightView initWithHighlight:andRects:forView:]): Don't drain
and then release because drain deallocates the receiver, so the release
is an over-release.
* WebView/WebView.mm:
(-[WebView rectsForTextMatches]): Re-allocate the pool after draining it,
because drain deallocates the receiver, so the drain would leave you without
any autorelease pool, causing a leak and then an over-release at the bottom
of the loop.
2007-04-24 Brady Eidson <beidson@apple.com>
Reviewed by Beth, Hyatt, Ada, and Darin
<rdar://problem/5011477> and <rdar://problem/5011514>
Provide support for the icon.db to be moved to a different directory from the old WebKit-style
icons, and remove the old directory if that is the case
* Misc/WebIconDatabase.mm:
(-[WebIconDatabase init]):
(-[WebIconDatabase _importToWebCoreFormat]): Check "imported()" to determine if a conversion is needed
- Look for WebIconDatabaseImportDirectoryDefaultsKey for the source location for the conversion
- Set "imported" to true in the Icons.db
- If the new Icons.db isn't in the same patch as the old icons, delete the entire directory when finished
- Move old icon.db to Icons.db to reflect rename
* Misc/WebIconDatabasePrivate.h: Add WebIconDatabaseImportDirectoryDefaultsKey so a WebKit client can tell WebKit
where to look for the old icons if their location is different from the icon.db
* WebKit.exp:
2007-04-24 Mitz Pettel <mitz@webkit.org>
Reviewed by Oliver Hunt.
Changed an apostrophe (') into a right single quotation mark (U+2019).
* WebInspector/webInspector/inspector.js:
2007-04-24 Mitz Pettel <mitz@webkit.org>
Reviewed by Timothy Hatcher.
- fix http://bugs.webkit.org/show_bug.cgi?id=13459
The "mapped style" link next to an attribute doesn't work
* WebInspector/webInspector/inspector.js: Added a check that the rule is
mapped from an attribute.
2007-04-23 Adele Peterson <adele@apple.com>
Fixed and reviewed by Darin, Adele, and Oliver.
WebKit part of fix for <rdar://problem/5107538> REGRESSION: Page scroll when selecting characters from inline input candidate window by arrow buttons
http://bugs.webkit.org/show_bug.cgi?id=13263
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]): If we have no command after calling interpretKeyEvents, we assume the input method handled the key.
(-[WebHTMLView doCommandBySelector:]): Add noop: to the command vector, but then when actually performing actions, ignore it.
2007-04-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/5124364> IB3 crashes when loading a nib containing a WebView that has a WebHTMLView encoded inside
Since WebView's initWithCoder throws away all the decoded subviews, the WebHTMLView gets dealoced while it has a nil _private pointer.
Checking for a nil _private in WehHTMLView's close fixes this crash. No need to implement a full initWithCoder for WebHTMLView since
it will be thrown away by the WebView anyway.
* WebView/WebHTMLView.mm:
(-[WebHTMLView close]): Return earily if _priviate is nil.
(-[WebHTMLView initWithFrame:]): Unrelated change that removes an AppKit version check that predates Tiger.
2007-04-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Mark Rowe.
Remove the "No Selection" message after leaving search mode.
This was a regression caused by the inspector refresh.
* WebInspector/webInspector/inspector.js:
2007-04-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Bug 6658: World leak when closing inspected window
http://bugs.webkit.org/show_bug.cgi?id=6658 and <rdar://problem/4411863>
Removes over-retains of the inspector WebView, WebInspector and WebInspectorPanel.
* WebInspector/WebInspector.m:
(+[WebInspector sharedWebInspector]): Return the global sharedWebInspector variable.
(-[WebInspector window]): Release the window after calling setWindow:.
(-[WebInspector windowWillClose:]): Set the JavaScript Inspector variable to null and expire the current highlight.
Also clear the global sharedWebInspector variable and release it if self equals sharedWebInspector.
(-[WebInspector showWindow:]): Set the JavaScript Inspector variable back to self.
* WebInspector/WebInspectorInternal.h: Remove the isSharedInspector member variable.
* WebView/WebView.mm:
(-[WebView windowScriptObject]): Return nil if core([self mainFrame]) is NULL.
2007-04-23 Darin Adler <darin@apple.com>
Reviewed by Hyatt.
- rename box-sizing to -webkit-box-sizing
* WebInspector/webInspector/inspector.css: Here.
* WebInspector/webInspector/inspector.js: And here, in the expected default CSS values list.
2007-04-22 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
The fix for <rdar://problem/4976681> ASSERTION failure on quit @ talkcrunch.com in _NPN_ReleaseObject
was #ifdefed out in Production builds.
* WebView/WebView.mm:
(+[WebView initialize]): Move the #ifdef REMOVE_SAFARI_DOM_TREE_DEBUG_ITEM inside initialize around the specific code
(+[WebView _applicationWillTerminate]): Moved outside the #ifdef REMOVE_SAFARI_DOM_TREE_DEBUG_ITEM block
2007-04-22 Timothy Hatcher <timothy@apple.com>
Reviewed by Mitz.
Bug 13436: Make Option-clicking a disclosure triangle expand the entire subtree
http://bugs.webkit.org/show_bug.cgi?id=13436
Makes option-click recursively expand and collapse the sub-tree. Pressing option-left
and -right also recursively expands and collapses the sub-tree.
* WebInspector/webInspector/treeoutline.js:
2007-04-22 Timothy Hatcher <timothy@apple.com>
Reviewed by Mitz.
Bug 13437: Inspector does not update when navigating to a different page
http://bugs.webkit.org/show_bug.cgi?id=13437
* WebInspector/webInspector/inspector.js: Correctly update to a new root node
if the new focus node and the old focus node don't have a common ancestor.
2007-04-22 Darin Adler <darin@apple.com>
Reviewed by Adele.
- fix for <rdar://problem/5100240> REGRESSION: Control-O broken
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent:shouldSaveCommand:]): Update to handle a vector of
command names instead of a single command.
(-[WebHTMLView doCommandBySelector:]): Change logic so that we add the command to a vector
and also so that the interpretKeyEvents parameters are still intact for a second call to
doCommandBySelector:, since the key bindings mechanism can do more than one.
(-[WebHTMLView insertText:]): Added comment.
2007-04-21 Darin Adler <darin@apple.com>
Reviewed by Oliver.
- fix some problems I ran into using the inspector
* WebInspector/webInspector/inspector.js: Add some null checks.
2007-04-20 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Merge over the WebInspectorRefresh branch. This change removes the NSOutlineView and
is replaced with a HTML/JavaScript tree. Most of the inspector logic is now in the JavaScript.
A few bugs are fixed by these changes:
Bug 6615: Parent node drop-down list is upside-down
http://bugs.webkit.org/show_bug.cgi?id=6615
Bug 6643: REGRESSION: Tree view repaints lines without erasing them first
http://bugs.webkit.org/show_bug.cgi?id=6643
Bug 6650: Web Inspector HTML Hierarchy can't be scrolled with scrollwheel
http://bugs.webkit.org/show_bug.cgi?id=6650
Bug 6677: Can't drag inspector when tree view has focus
http://bugs.webkit.org/show_bug.cgi?id=6677
Bug 7326: Web Inspector tree scrollbar always shows up when resizing the top pane down
http://bugs.webkit.org/show_bug.cgi?id=7326
* WebInspector/WebInspector.h: Removed the searchQuery methods.
* WebInspector/WebInspector.m: Removed the DOMNode category and code for the old outline view.
* WebInspector/WebInspectorOutlineView.h: Removed.
* WebInspector/WebInspectorOutlineView.m: Removed.
* WebInspector/WebInspectorInternal.h: Remove some methods and instance variables.
* WebInspector/webInspector/Images/resize.png: Added.
* WebInspector/webInspector/inspector.css:
* WebInspector/webInspector/inspector.html: Include the new classes and remove the plugin.
* WebInspector/webInspector/inspector.js: Changes to use the new tree outline and other fixes.
* WebInspector/webInspector/scrollarea.js: Copied from the Dashboard widget resources.
* WebInspector/webInspector/scrollbar.js: Ditto.
* WebInspector/webInspector/treeoutline.js: New tree outline class.
* WebInspector/webInspector/utilities.js: DOM and String prototype additions.
* WebKit.xcodeproj/project.pbxproj: Remove WebInspectorOutlineView.
2007-04-20 Brady Eidson <beidson@apple.com>
Reviewed by Oliver (Black Sheep)
<rdar://problem/3559794>
[WebView setMaintainsBackForwardList:] doesn't actually flush out the current page caches
* WebView/WebView.mm: Remove _private->useBackForwardList
(-[WebView _setInitiatedDrag:]): Use _private->page instead of [self page]
(-[WebView initWithCoder:]): Manipulate the flag that is now in WebCore::BackForwardList
(-[WebView encodeWithCoder:]): Ditto
(-[WebView backForwardList]): Use _private->page instead of [self page]
(-[WebView setMaintainsBackForwardList:]): Manipulate the flag that is now in WebCore::BackForwardList
2007-04-20 Anders Carlsson <andersca@apple.com>
Reviewed by Maciej.
<rdar://problem/5085897> REGRESSION: Some Flash links at www.jumpskyhigh.com just reload the page
Get rid of the check that would prevent plugin requests from being loaded if a new page load was underway.
www.jumpskyhigh.com had a flash movie that was embedded inside an <a> tag and clicking on the plug-in would cause the
URL pointed to by the <a> tag to start loading and thus preventing the plug-in from loading the real URL.
This check was added by Maciej and we should be able to remove it with the loader changes that have happened now,
(mainly the fact that resource loaders are handled by the document loader instead of the frame loader).
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
2007-04-19 Oliver Hunt <oliver@apple.com>
Reviewed by Adam.
Fix for <rdar://problem/4960912> -- REGRESSION: Content-Disposition:
filename is ignored for drag-and-drop.
* WebView/WebResource.mm:
(-[WebResource _fileWrapperRepresentation]):
When creating the NSFileWrapper check the response for a preferred
filename, rather than just blindly hoping for the best.
2007-04-19 Anders Carlsson <andersca@apple.com>
Reviewed by John.
<rdar://problem/5137002>
REGRESSION (r20812): [WebFrame DOMDocument] is returning non-nil value in bookmarks view, causing trouble in Safari
Put back the MIME type check as a workaround.
* WebView/WebFrame.mm:
(-[WebFrame DOMDocument]):
2007-04-19 Mark Rowe <mrowe@apple.com>
Reviewed by Oliver and Adam.
<rdar://problem/5141290> WebAssertions.h is still needed by some internal clients.
* Misc/WebAssertions.h: Added.
* WebKit.xcodeproj/project.pbxproj:
2007-04-17 Brady Eidson <beidson@apple.com>
Reviewed by Tim
<rdar://problem/5008925>
Expose the NSURLConnection delegate willCacheResponse API to WebResourceLoadDelegate
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::willCacheResponse): Call
[WebResourceLoadDelegate webView:resource:willCacheResponse:fromDataSource:];
* WebView/WebView.mm:
(-[WebView _cacheResourceLoadDelegateImplementations]): Pull out the willCacheResponse impl
* WebView/WebViewPrivate.h: Add WebResourceLoadDelegatePrivate category for this new SPI
2007-04-18 John Sullivan <sullivan@apple.com>
Reviewed by Adam
- fixed <rdar://problem/5103009> REGRESSION: Activity window shows blank name for untitled pages
* WebView/WebHTMLRepresentation.mm:
(-[WebHTMLRepresentation title]):
return nil for empty string, to match old behavior
2007-04-17 John Sullivan <sullivan@apple.com>
Reviewed by Tim Hatcher
- fixed <rdar://problem/5138492> Safari doesn't remember some changes to the PDF scale and display mode
Some of the user interactions that could change the PDF scale and display mode were not going through
the proxy mechanism in WebPDFView that updates preferences. Now we also listen to PDFKit notifications
in order to catch the other cases.
* WebView/WebPDFView.h:
new _ignoreScaleAndDisplayModeNotifications and _updatePreferencesTimer ivars
* WebView/WebPDFView.mm:
(-[WebPDFView setPDFDocument:]):
ignore scale and display mode notifications while we're setting up a fresh document
(-[WebPDFView dealloc]):
cancel the new timer (which releases it)
(-[WebPDFView viewDidMoveToWindow]):
listen for two PDFKit notifications
(-[WebPDFView viewWillMoveToWindow:]):
stop listening to the two PDFKit notifications
(-[WebPDFView _applyPDFDefaults]):
white space change
(-[WebPDFView _cancelUpdatePreferencesTimer]):
invalidate, release, and nil out the timer
(-[WebPDFView _scaleOrDisplayModeChanged:]):
update preferences soon, unless deliberately ignoring these notifications
(-[WebPDFView _updatePreferencesNow]):
cancel timer, then save data to preferences (code for saving the data was extracted from
-[PDFPrefUpdatingProxy forwardInvocation:])
(-[WebPDFView _updatePreferencesSoon]):
use timer to consolidate multiple calls into one action; formerly we were setting preferences
multiple times for some atomic user actions
(-[PDFPrefUpdatingProxy forwardInvocation:]):
call _updatePreferencesSoon where we used to immediately set preferences
2007-04-17 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
- fixed <rdar://problem/4184640> "Look Up in Dictionary" item is always disabled for PDF pages
* WebView/WebPDFView.mm:
(-[WebPDFView validateUserInterfaceItem:]):
enable "Look Up in Dictionary" only if we're using a version of PDFKit that knows how to do so
(-[WebPDFView _canLookUpInDictionary]):
use respondsToSelector to test whether the current version of PDFKit supports this non-API feature
(-[WebPDFView _lookUpInDictionaryFromMenu:]):
implement this method, which WebKit includes in the context menu when there's selected text
(-[WebPDFView _menuItemsFromPDFKitForEvent:]):
updated comment for this change
2007-04-16 Darin Adler <darin@apple.com>
Rubber stamped by Tim Hatcher.
* WebKit.xcodeproj/project.pbxproj: Added Radar bug number to the error message
for the "version number ending in 4" check so folks from Apple can find the
original bug that motivated for this. To summarize what's in that bug, it says that
<http://my.fedex.com> was failing, that it was because of the OpenCube DHTML Menu,
and that some other affected sites were not using OpenCube (so the error is presumably
more widespread).
2007-04-16 Darin Adler <darin@apple.com>
Reviewed by John Sullivan.
- fix http://bugs.webkit.org/show_bug.cgi?id=13303
<rdar://problem/5126341> REGRESSION: controls in a background Safari window
maintain active appearance if the address bar has focus (13303)
* WebView/WebHTMLView.mm: (-[WebHTMLView _windowChangedKeyState]):
Added. Calls FrameView::updateControlTints.
2007-04-13 Oliver Hunt <oliver@apple.com>
Reviewed by Adam.
Due to rdar://problem/5133910 -- WebArchives should not be constructed
using resource from the cache -- We may try to create a potentially
incorrect WebArchive when dragging an image multiple times.
This patch retains the assertion for invalid behaviour, but adds a
branch to make sure we don't try to do anything with the WebArchive
in release builds.
* Misc/WebNSPasteboardExtras.mm:
(-[NSPasteboard _web_writeImage:element:URL:title:archive:types:]):
2007-04-13 Timothy Hatcher <timothy@apple.com>
Reviewed by Dave Harrison.
<rdar://problem/5132727> Soho Mail build fails because of renamed SPI
* WebView/WebUIDelegatePrivate.h: define WebMenuItemTagSearchInGoogle as OldWebMenuItemTagSearchWeb
2007-04-13 Mark Rowe <mrowe@apple.com>
Reviewed by Oliver.
<rdar://problem/5130686> Using WebPreferencesPrivate.h requires modifying framework search path
* WebView/WebPreferencesPrivate.h: Remove unneeded #ifdef.
2007-04-12 Deneb Meketa <dmeketa@adobe.com>
Reviewed by Darin Adler.
http://bugs.webkit.org/show_bug.cgi?id=13029
rdar://problem/4994849
Bug 13029: Permit NPAPI plug-ins to see HTTP response headers.
* Plugins/WebBaseNetscapePluginStream.h: declarations.
* Plugins/WebBaseNetscapePluginStream.mm: main implementation.
(-[WebBaseNetscapePluginStream dealloc]): cleanup.
(-[WebBaseNetscapePluginStream finalize]): cleanup.
(-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:headers:]):
Pass headers along.
(-[WebBaseNetscapePluginStream startStreamWithResponse:]):
Main work is here. Extract headers from NSHTTPURLResponse object into a byte sequence.
See comments here about how it would be nice to have low-level access to the HTTP response.
(-[WebBaseNetscapePluginStream _destroyStream]): cleanup.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]):
Conform to new startStream params. Not applicable here, pass nil.
2007-04-12 Brady Eidson <beidson@apple.com>
Build fix for case sensitive file systems
* Misc/WebNSPasteboardExtras.mm:
* WebCoreSupport/WebPasteboardHelper.mm:
2007-04-11 John Sullivan <sullivan@apple.com>
Reviewed by Anders
- WebKit part of fix for:
<rdar://problem/5128697> REGRESSION: At least one PDF context menu item isn't appearing on Leopard
* Misc/WebNSArrayExtras.h: Added.
* Misc/WebNSArrayExtras.m: Added.
(-[NSMutableArray _webkit_removeUselessMenuItemSeparators]):
New file, includes this method to strip leading, trailing, and duplicate separators from arrays
of NSMenuItems (copied from Safari)
* WebView/WebUIDelegatePrivate.h:
new MenuItemTag enum values for new PDFKit context menu items
* WebKit.xcodeproj/project.pbxproj:
updated for new files
* WebView/WebPDFView.mm:
(-[WebPDFView _anyPDFTagsFoundInMenu:]):
check for new PDFKit context menu items
(-[WebPDFView _menuItemsFromPDFKitForEvent:]):
associate new PDFKit context menu item selectors with the new tags; skip certain selectors that
correspond to menu items that WebKit already includes; remove useless menu item separators when
we're done, since we might have removed arbitrarily-placed menu items
2007-04-11 Oliver Hunt <oliver@apple.com>
Reviewed by Maciej.
Adding RetainPtr to the many global obj-c pointers we use in
C/C++ methods. This is necessary to prevent GC from collecting
globals we want to keep around.
We use RetainPtr in obj-c++ and c++ files, and CFRetain/Release in pure
obj-c.
This fixes <rdar://problem/5058731> -- Crash in
WebCore::DragData::containsCompatibleContent due to early release
of types array
* Misc/WebLocalizableStrings.m:
(WebLocalizedString):
* Misc/WebNSPasteboardExtras.mm:
(+[NSPasteboard _web_writableTypesForURL]):
(_writableTypesForImageWithoutArchive):
(_writableTypesForImageWithArchive):
* Misc/WebNSURLExtras.m:
(applyHostNameFunctionToMailToURLString):
(applyHostNameFunctionToURLString):
* Misc/WebStringTruncator.m:
(defaultMenuFont):
(fontFromNSFont):
* WebCoreSupport/WebPasteboardHelper.mm:
(WebPasteboardHelper::insertablePasteboardTypes):
2007-04-11 MorganL <morganl.webkit@yahoo.com>
Reviewed by Maciej.
Add a Frame pointer to ChromeClient methods:
http://bugs.webkit.org/show_bug.cgi?id=13127
* COM/ChromeClientWin.cpp:
(ChromeClientWin::createWindow):
(ChromeClientWin::createModalDialog):
* COM/ChromeClientWin.h:
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::createWindow):
(WebChromeClient::createModalDialog):
2007-04-10 Brady Eidson <beidson@apple.com>
Reviewed by Darin
<rdar://problem/4887095> - PageCache and PageState should be combined
WebKit side of the change to reflect the new object name of CachedPage and new Client method names
* History/WebHistoryItem.mm:
(-[WebHistoryItem setAlwaysAttemptToUsePageCache:]):
(+[WebHistoryItem _releaseAllPendingPageCaches]):
(-[WebWindowWatcher windowWillClose:]):
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::setDocumentViewFromCachedPage):
(WebFrameLoaderClient::loadedFromCachedPage):
(WebFrameLoaderClient::saveDocumentViewToCachedPage):
2007-04-09 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej Stachowiak.
Support for fixing fast/forms/textarea-paste-newline.html.
Added SPI for specifying whether a WebView should allow pasting through the
DOM API.
* ChangeLog:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebPreferenceKeysPrivate.h:
* WebView/WebPreferences.m:
(+[WebPreferences standardPreferences]):
(-[WebPreferences isDOMPasteAllowed]):
(-[WebPreferences setDOMPasteAllowed:]):
* WebView/WebPreferencesPrivate.h:
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2007-04-09 Anders Carlsson <andersca@apple.com>
Reviewed by John.
<rdar://problem/5081860>
REGRESSION: Select All for standalone image has no visible effect but does change state
<rdar://problem/5081840>
REGRESSION: context menu in white space beyond standalone image is different after Select All
Have validateUserInterface emulate the old behavior for full-frame images and plugins, which is:
- For full-frame plugins, always return false.
- For images, only return true if the selector is copy: and the image has finished loading.
* WebView/WebHTMLView.mm:
(-[WebHTMLView validateUserInterfaceItem:]):
2007-04-09 Anders Carlsson <andersca@apple.com>
Reviewed by Darin.
<rdar://problem/5026893>
REGRESSION: "Mail Contents of this Page" for standalone image in Safari results in a broken image in Mail
* WebView/WebFrame.mm:
(-[WebFrame DOMDocument]):
We can't check for _isHTMLDocument here since image and plugin documents inherit from HTMLDocument. Instead,
check for those two document types explicitly.
2007-04-09 Anders Carlsson <andersca@apple.com>
Reviewed by Geoff, Ada and John.
<rdar://problem/4600978> Would like a way to test whether a WebView is displaying a standalone image
* WebView/WebFrame.mm:
(-[WebFrame _isDisplayingStandaloneImage]):
* WebView/WebFramePrivate.h:
Add _isDisplayingStandaloneImage SPI.
2007-04-06 Timothy Hatcher <timothy@apple.com>
Reviewed by Mark Rowe.
Adds a build phase script that ensures WebKit's version dosen't end in a 4.
If our version ends in 4, some sites might think we are Netscape 4 in their
user agent checks.
* Configurations/Version.xcconfig:
* WebKit.xcodeproj/project.pbxproj:
2007-04-05 Anders Carlsson <andersca@apple.com>
Reviewed by Adam.
<rdar://problem/5083023>
REGRESSION: In Real Player (10.1.0), video continues to play after closing window
This broke in revision 18422 because now the plugin isn't stopped when the window is closed. Since the window is retained
by the plugin view for as long as it is running (so that removeTrackingRect works even though the window has been closed),
we would end up with a reference cycle (NSWindow -> WebView -> PluginView -> NSWindow) and stopping the plug-in when the window
was closed would break that cycle.
Applications that call -[WebView close] when closing aren't affected, but RealPlayer doesn't do this.
The bug that 18422 was supposed to fix was fixed by 19275, which is why it's safe to add back the check.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView addWindowObservers]):
(-[WebBaseNetscapePluginView removeWindowObservers]):
(-[WebBaseNetscapePluginView windowWillClose:]):
2007-04-05 Kevin McCullough <kmccullough@apple.com>
Reviewed by Darin.
- Moved registerURLSchemeAsLocal to the public API.
* WebView/WebView.h:
* WebView/WebView.mm:
(+[WebView registerURLSchemeAsLocal:]):
* WebView/WebViewPrivate.h:
=== Safari-5522.6 ===
2007-04-04 Anders Carlsson <andersca@apple.com>
Reviewed by John.
<rdar://problem/5107536>
http://bugs.webkit.org/show_bug.cgi?id=13264
REGRESSION: Crash when canceling about:blank in Activity viewer
* WebView/WebFrame.mm:
(-[WebFrame stopLoading]):
Add a null check for the frame loader - it can be null when the frame has been disconnected
from the web page.
2007-04-03 Anders Carlsson <andersca@apple.com>
Reviewed by Darin.
<rdar://problem/5028178>
Crash occurs at WebCore::FrameLoader::activeDocumentLoader() after loading Froggster widget
* Plugins/WebNetscapePluginStream.mm:
(-[WebNetscapePluginStream start]):
If load returns no the plugin loader has already been removed by the didFail callback.
2007-04-02 Anders Carlsson <andersca@apple.com>
Reviewed by Geoff.
Fix crash when running plugins/destroy-stream-twice.html under GuardMalloc
* Plugins/WebBaseNetscapePluginStream.h:
* Plugins/WebBaseNetscapePluginStream.mm:
(+[WebBaseNetscapePluginStream ownerForStream:]):
(-[WebBaseNetscapePluginStream initWithRequestURL:plugin:notifyData:sendNotification:]):
(-[WebBaseNetscapePluginStream dealloc]):
(-[WebBaseNetscapePluginStream finalize]):
Change the streams hash map to contain an NPStream*, and change ownerForStream to take an NPStream*.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView destroyStream:reason:]):
Check that the NPStream pointer is valid before accessing stream->ndata.
2007-04-02 Darin Adler <darin@apple.com>
Reviewed by Geoff.
- fix http://bugs.webkit.org/show_bug.cgi?id=13026
<rdar://problem/5061026> incomplete render of menu
(assertion failing in -[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:])
- fix http://bugs.webkit.org/show_bug.cgi?id=13120
<rdar://problem/5080339> Plug-ins that draw through the QuickDraw interface may crash
by hanging onto old GWorlds.
- set clip path for CoreGraphics plug-ins in the same way we do for QuickDraw plug-ins
this is a better fix for <rdar://problem/4939511> WebKit should set the the CG clip
path for plug-ins that draw using Core Graphics
Incorporates changes from a patch by Mark Ambachtsheer.
Here are the changes:
1) Don't try to use the offscreen code path if GGBitmapContextGetData returns 0.
2) Handle kCGBitmapByteOrderDefault when computing the QD pixel format, even though
we don't have any evidence that this happens in practice.
3) Keep the GWorld around until we create a new one or the plug-in is destroyed.
4) Use the GWorld pointer itself as a flag to indicate whether we are using an
offscreen GWorld.
5) Set up clipping for CoreGraphics in the same way we do for QuickDraw; remove an
earlier attempt that handled CoreGraphics differently.
* Plugins/WebBaseNetscapePluginView.h: Added a field named offscreenGWorld to hold
the GWorld until it's needed.
* Plugins/WebBaseNetscapePluginView.mm:
(getQDPixelFormatForBitmapContext): Replaced QDPixelFormatFromCGBitmapInfo. Used the
"get" prefix so we don't intrude on the QD namespace. Added code to handle the
kCGBitmapByteOrderDefault case, although I'm not sure it will really come up in
practice -- it wasn't really coming up in the buggy case.
(getNPRect): Added helper functions. Used to make the code below clearer.
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]): Use getNPRect to
streamline code. Use GetGWorld to save the port since we use SetGWorld to restore
it later. Store the GWorld we create in the offscreenGWorld field and dispose the
existing one. Don't treat the CGBitmapContext as an offscreen bitmap if it
has a data pointer of 0. Set up the clip based on the result of
-[NSView getRectsBeingDrawn:count] when setting up the port for CoreGraphics
(after saving the port state).
(-[WebBaseNetscapePluginView restorePortState:]): Remove now-unneeded code to
destroy the offscreen GWorld, and simplified the code that restores the port so we
don't need a separate case for offscreen.
(-[WebBaseNetscapePluginView fini]): Renamed from freeAttributeKeysAndValues, since
this method now does more than just the attributes. This is the shared method that
does things needed in both dealloc and finalize. Added a call to DisposeGWorld here.
(-[WebBaseNetscapePluginView dealloc]): Updated for name change.
(-[WebBaseNetscapePluginView finalize]): Ditto.
(-[WebBaseNetscapePluginView drawRect:]): Removed code to set clip. This is done in
the saveAndSetNewPortStateForUpdate: method instead.
2007-03-30 Adele Peterson <adele@apple.com>
Reviewed by Darin.
Call execCommand for deleteWordForward and deleteWordBackward instead of calling
deleteWithDirection directly.
* WebView/WebHTMLView.mm:
(-[WebHTMLView deleteWordForward:]):
(-[WebHTMLView deleteWordBackward:]):
2007-03-30 Anders Carlsson <andersca@apple.com>
Reviewed by Geoff.
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage load]):
Initialize pushpopupsenabledstate, poppopupsenabledstate and enumerate.
* Plugins/npapi.m:
(NPN_PushPopupsEnabledState):
(NPN_PopPopupsEnabledState):
Add stubs for these functions.
* Plugins/npfunctions.h:
Add new methods to NPNetscapeFuncs.
2007-03-29 Geoffrey Garen <ggaren@apple.com>
Reviewed by Beth Dakin, reviewed by Maciej Stachowiak.
Layout test for <rdar://problem/5091330> REGRESSION: Repro crash in
-[WebBaseNetscapePluginView(WebNPPCallbacks) destroyStream:reason:]
navigating away from page with DivX movie plug-in (13203)
Changed LOG_ERROR to LOG so the layout test doesn't produce console spew
every time you run it.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView destroyStream:reason:]):
2007-03-29 Beth Dakin <bdakin@apple.com>
Reviewed by Brady.
Fix for <rdar://problem/4674537> REGRESSION: Adobe Acrobat 8 - Text
blinks when mouse is moved, and is invisible otherwise
-and-
<rdar://problem/4992521> Please adjust WebKit's Acrobat-workaround
methodology
The fix for the first bug is to compare against the bundle
identifiers for Adobe Reader and the non-Pro Adobe Acrobat in
addition to Adobe Acrobat Pro. The fix for the second bug is to
check the version number of Acrobat/Reader through
WebKitSystemInterface instead of checking which version of WebKit
it has been linked against.
* English.lproj/StringsNotToBeLocalized.txt: Two new bundle
identifiers.
* Misc/WebKitVersionChecks.h: Remove Acrobat quirk constant.
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2007-03-29 Geoffrey Garen <ggaren@apple.com>
Rubber stamped by Beth Dakin.
WebBaseNetscapePluginStream.m => WebBaseNetscapePluginStream.mm, since
it's ObjC++ now.
* Plugins/WebBaseNetscapePluginStream.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
2007-03-27 Geoffrey Garen <ggaren@apple.com>
Reluctantly tolerated by Darin Adler.
Fixed <rdar://problem/5091330> REGRESSION: Repro crash in
-[WebBaseNetscapePluginView(WebNPPCallbacks) destroyStream:reason:]
navigating away from page with DivX movie plug-in (13203)
The problem was that the DivX plug-in would ask us to destroy an NPStream
that had already been destroyed, causing us to wander off into freed
memory. (I believe the reason this was a regression was that we never used
to destroy plug-in streams, period.)
The solution here is to track the NPStreams belonging to a plug-in, and
guard against plug-ins making calls with NPStreams that don't belong to
them. (It turns out that NPN_DestroyStream is the only stream-based
plug-in call we support.)
(CarbonPathFromPOSIXPath): Fixed up a cast to be C++ compatible.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView destroyStream:reason:]): The actual fix.
Use helper method to guard against a plug-in using an NPStream that doesn't
belong to it.
* WebKit.xcodeproj/project.pbxproj: Made WebBaseNetscapePluginView ObjC++
so I could use HashMap.
2007-03-28 Adele Peterson <adele@apple.com>
Reviewed by Brady.
Update to last fix.
* Misc/WebKitVersionChecks.h: Added WEBKIT_FIRST_VERSION_WITHOUT_VITALSOURCE_QUIRK.
* WebView/WebView.mm: (-[WebView stringByEvaluatingJavaScriptFromString:]):
Added check to only use the VitalSource workaround if the app is not linked on or after
the defined WEBKIT_FIRST_VERSION_WITHOUT_VITALSOURCE_QUIRK version number.
2007-03-28 Adele Peterson <adele@apple.com>
Reviewed by Kevin M.
WebKit part of fix for <rdar://problem/5095515> VitalSource Bookshelf should not pass return statements into stringByEvaluatingJavaScriptFromString
Added an app specific workaround for VitalSource Bookshelf that strips "return" from the beginning of their script strings. We used to allow this
but now we throw a JavaScript exception for return statements that aren't in functions.
Filed this evangelism bug so we can notify VitalSource of the problem:
<rdar://problem/5095515> VitalSource Bookshelf should not pass return statements into stringByEvaluatingJavaScriptFromString
* WebView/WebView.mm: (-[WebView stringByEvaluatingJavaScriptFromString:]):
2007-03-27 John Sullivan <sullivan@apple.com>
Reviewed by Tim
- fixed <rdar://problem/5092556> Default UA spoofing is always off until explicitly toggled
* WebView/WebView.mm:
(-[WebView _commonInitializationWithFrameName:groupName:]):
initialize the cached value of _private->useSiteSpecificSpoofing here; formerly it would not
be initialized correctly in the common case of WebViews that use [WebPreferences standardPreferences]
2007-03-27 Mark Rowe <mrowe@apple.com>
Reviewed by Dave Harrison.
* Configurations/WebKit.xcconfig: Include UMBRELLA_FRAMEWORKS_DIR in framework search path.
2007-03-26 Antti Koivisto <antti@apple.com>
Reviewed by Darin.
On Mac, support fine grained wheel events generated by trackpad and Mighty Mouse.
http://bugs.webkit.org/show_bug.cgi?id=13134
<rdar://problem/5076249>
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface): Expose GetWheelEventDeltas()
2007-03-26 John Sullivan <sullivan@apple.com>
Reviewed by Dave Harrison
- fixed <rdar://problem/4769772> Problem with Find on certain PDF page
* WebView/WebPDFView.mm:
(-[WebPDFView _scaledAttributedString:]):
We were hitting an exception trying to set the font attribute to nil, which was happening because
the result of -[PDFSelection attributedString] had no attributes. That PDFSelection bug is now
filed separately, but this works around the exception.
2007-03-24 David Hyatt <hyatt@apple.com>
Amend the statistics reporting for the WebCore cache to include XSL and to report live/decoded sizes.
* Misc/WebCache.mm:
(+[WebCache statistics]):
2007-03-24 Brady Eidson <beidson@apple.com>
Reviewed by Adam
RetainPtr is no longer in the WebCore namespace
* History/WebBackForwardList.mm:
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebFrameLoaderClient.h:
* WebView/WebDocumentLoaderMac.h:
2007-03-24 Brady Eidson <beidson@apple.com>
Reviewed by Adam
<rdar://problem/5086210> - Move RetainPtr to WTF
* ForwardingHeaders/wtf/RetainPtr.h: Added.
* History/WebBackForwardList.mm: Changed #import to <wtf/RetainPtr.h>
* WebCoreSupport/WebEditorClient.h: Ditto
* WebCoreSupport/WebFrameLoaderClient.h: Ditto
* WebView/WebDocumentLoaderMac.h: Ditto
2007-03-24 John Sullivan <sullivan@apple.com>
Reviewed by Adele
- fixed <rdar://problem/5084872> Need to add flickr to spoof list in WebKit
- only do site-specific spoofing if a preference is set
* WebView/WebPreferenceKeysPrivate.h:
added WebKitUseSiteSpecificSpoofingPreferenceKey
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
initialize WebKitUseSiteSpecificSpoofingPreferenceKey to false
(-[WebPreferences _useSiteSpecificSpoofing]):
get value of WebKitUseSiteSpecificSpoofingPreferenceKey
(-[WebPreferences _setUseSiteSpecificSpoofing:]):
set value of WebKitUseSiteSpecificSpoofingPreferenceKey
* WebView/WebPreferencesPrivate.h:
declare _useSiteSpecificSpoofing and _setUseSiteSpecificSpoofing
* WebView/WebView.mm:
cache the value of WebKitUseSiteSpecificSpoofingPreferenceKey in a bool in _private
(-[WebView _preferencesChangedNotification:]):
update the cached value
(-[WebView setPreferences:]):
ditto
(-[WebView WebCore::_userAgentForURL:WebCore::]):
Only spoof here if the new site-specific spoofing preference is enabled. If it is, pass
Safari 2.0.4's user agent string for flickr.com. We can remove this case when 5081617 is addressed.
2007-03-24 Mark Rowe <mrowe@apple.com>
Rubber-stamped by Darin.
* Configurations/WebKit.xcconfig: Remove unnecessary INFOPLIST_PREPROCESS.
2007-03-23 Mark Rowe <mrowe@apple.com>
Build fix for when BUILDING_ON_TIGER is not defined.
* Misc/WebTypesInternal.h:
* WebView/WebHTMLView.mm:
2007-03-22 David Kilzer <ddkilzer@apple.com>
Reviewed by Darin.
Use BUILDING_ON_TIGER from WebKitPrefix.h instead of local
MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_4 tests.
* Misc/WebTypesInternal.h:
* WebView/WebHTMLView.mm:
2007-03-22 Darin Adler <darin@apple.com>
Reviewed by Adele.
- fix <rdar://problem/5074630> detachChildren call should move from WebKit to WebCore
* WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::prepareForDataSourceReplacement):
Remove call to detachChildren. This should be a WebCore responsibility.
2007-03-19 Anders Carlsson <acarlsson@apple.com>
Reviewed by Dave Hyatt.
<rdar://problem/5067983>
iSale: Crash occurs at WebFrameLoaderClient::dispatchDecidePolicyForMIMEType() when attempting to load a HTML template
Restore old behavior (broke in r14533) where the resource load and download delegates are retained for as long as the
data source is loading.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createDocumentLoader):
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::setDataSource):
(WebDocumentLoaderMac::decreaseLoadCount):
2007-03-19 Geoffrey Garen <ggaren@apple.com>
Speculative fix for why ASSERT_MAIN_THREAD didn't work for me. (The
documentation says "non-zero," not "1."
* Misc/WebKitLogging.m:
(WebKitRunningOnMainThread):
2007-03-19 Andrew Wellington <proton@wiretapped.net>
Reviewed by Maciej.
Really set Xcode editor to use 4 space indentation (http://webkit.org/coding/coding-style.html)
* WebKit.xcodeproj/project.pbxproj:
2007-03-19 Darin Adler <darin@apple.com>
* English.lproj/StringsNotToBeLocalized.txt: Update for recent changes.
2007-03-19 John Sullivan <sullivan@apple.com>
Reviewed by Justin
- fixed <rdar://problem/5071238> REGRESSION: opt-cmd-B to show Bookmarks view does
nothing when form field has focus
* WebView/WebHTMLView.mm:
(-[WebHTMLView _handleStyleKeyEquivalent:]):
we were counting any set of modifiers plus 'b' as the standard key equivalent for
toggling Bold; now we only accept command+'b'
2007-03-19 Adam Roben <aroben@apple.com>
Reviewed by Hyatt and Maciej.
Updated WebCoreStatistics for the conversion of WebCoreJavaScript to
C++.
* Misc/WebCoreStatistics.mm:
(+[WebCoreStatistics javaScriptObjectsCount]):
(+[WebCoreStatistics javaScriptInterpretersCount]):
(+[WebCoreStatistics javaScriptProtectedObjectsCount]):
(+[WebCoreStatistics javaScriptRootObjectTypeCounts]): Moved
conversion to NSCountedSet here from WebCore.
(+[WebCoreStatistics garbageCollectJavaScriptObjects]):
(+[WebCoreStatistics garbageCollectJavaScriptObjectsOnAlternateThread:]):
(+[WebCoreStatistics shouldPrintExceptions]):
(+[WebCoreStatistics setShouldPrintExceptions:]):
(+[WebCoreStatistics javaScriptReferencedObjectsCount]):
(+[WebCoreStatistics javaScriptRootObjectClasses]):
2007-03-18 Andrew Wellington <proton@wiretapped.net>
Reviewed by Mark Rowe
Set Xcode editor to use 4 space indentation (http://webkit.org/coding/coding-style.html)
* WebKit.xcodeproj/project.pbxproj:
2007-03-19 Mark Rowe <mrowe@apple.com>
Rubber-stamped by Brady.
Update references to bugzilla.opendarwin.org with bugs.webkit.org.
* WebInspector/webInspector/inspector.css:
* WebView/WebHTMLView.mm:
(-[WebHTMLView firstRectForCharacterRange:]):
* WebView/WebView.mm:
(-[WebView initWithFrame:frameName:groupName:]):
2007-03-18 David Hyatt <hyatt@apple.com>
Move frame borders out of WebKit and into WebCore.
Reviewed by aroben, olliej
* WebCoreSupport/WebFrameBridge.mm:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrameView.mm:
(-[WebFrameView drawRect:]):
(-[WebFrameView setFrameSize:]):
* WebView/WebFrameViewInternal.h:
2007-03-17 John Sullivan <sullivan@apple.com>
Reviewed by Tim Hatcher
Discovered while working on <rdar://problem/5070334> that many WebView calls will crash if called
after -[WebView close] has executed because _private->page is deferenced after it's been set to 0.
It might be silly/wrong to call these methods after -close, but obviously it shouldn't crash. Made
each use of _private->page robust against nil-dereferencing.
* WebView/WebView.mm:
(-[WebView _loadBackForwardListFromOtherView:]):
(-[WebView _updateWebCoreSettingsFromPreferences:]):
(-[WebView _setDashboardBehavior:to:]):
(-[WebView _dashboardBehavior:]):
(-[WebView goBack]):
(-[WebView goForward]):
(-[WebView goToBackForwardItem:]):
(-[WebView canGoBack]):
(-[WebView canGoForward]):
(-[WebView setTabKeyCyclesThroughElements:]):
(-[WebView tabKeyCyclesThroughElements]):
(-[WebView setEditable:]):
2007-03-17 Timothy Hatcher <timothy@apple.com>
Reviewed by Mark Rowe.
Made Version.xcconfig smarter when building for different configurations.
Now uses the 522+ OpenSource version for Debug and Release, while using the
full 522.4 version for Production builds. The system prefix is also computed
based on the current system, so 4522.4 on Tiger and 5522.4 on Leopard.
* Configurations/Version.xcconfig:
* Configurations/WebKit.xcconfig:
2007-03-16 Oliver Hunt <oliver@apple.com>
Reviewed by Hyatt.
The old canSaveAsWebArchive call was necessary as stand alone
images used to be rendered by ImageDocument.
Fixes rdar://problem/5061252
* WebCoreSupport/WebDragClient.h:
* WebCoreSupport/WebDragClient.mm:
(WebDragClient::declareAndWriteDragImage):
* WebKit.xcodeproj/project.pbxproj:
2007-03-15 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
<rdar://problem/4429701>
Implements a port blocking black list that matches Firefox's
* English.lproj/Localizable.strings: Added localizable string for port blocked error code
* Misc/WebKitErrors.h:
* Misc/WebKitErrors.m:
(registerErrors): Add new port blocked error code to WebKitErrorDomain
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::cancelledError): Fixed coding style
(WebFrameLoaderClient::blockedError): Return a ResourceError with the new custom error code
2007-03-15 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
* Fixes: <rdar://problem/4927747> WebKit's Current Library Version number should match the Info.plist Version
* Factored out most of our common build settings into .xcconfig files. Anything that was common in
each build configuration was factored out into the shared .xcconfig file.
* Adds a Version.xcconfig file to define the current framework version, to be used in other places.
* Use the new $(BUNDLE_VERSION) (defined in Version.xcconfig) in the preprocessed Info.plist.
* Use the versions defined in Version.xcconfig to set $(DYLIB_CURRENT_VERSION).
* Make WebKit use the same warning flags as the other projects. This required two casts to be added to fix new warnings.
* Configurations/Base.xcconfig: Added.
* Configurations/DebugRelease.xcconfig: Added.
* Configurations/Version.xcconfig: Added.
* Configurations/WebKit.xcconfig: Added.
* Info.plist:
* Misc/WebKitVersionChecks.h:
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:]):
* WebKit.xcodeproj/project.pbxproj:
2007-03-15 Kevin Decker <kdecker@apple.com>
Reviewed by Anders.
Fixed: <rdar://problem/5001428> stationery background images do not display
Change 19244 fixed the method -[WebResource _shouldIgnoreWhenUnarchiving], but also broke Mail stationery.
The problem was that with archivedResourceForURL now fixed, the engine will try to decode the images. These images wouldn't decode because
Mail re-encodes and directly manipulates the image data in such a way that prevented WebKit from decoding the image. Because Mail was giving
us bad data, the images wouldn't render. This was never an issue before because archivedResourceForURL (broken) always returned nil, thus the
engine would never attempt to decode the resource, therefore the responsibility was delegated to Mail's protocol handler, which would do the
right thing and load the image.
Since Mail is relying on the fact it can store arbitrary data in WebArchives, I've introduced SPI that acts as a hint for us to ignore certain
subresources while unarchiving. This SPI is -[WebResource _shouldIgnoreWhenUnarchiving].
* WebView/WebResource.mm: Addd private ivar shouldIgnoreWhenUnarchiving.
(-[WebResource _ignoreWhenUnarchiving]): Added.
(-[WebResource _shouldIgnoreWhenUnarchiving]): Added.
* WebView/WebResourcePrivate.h: Added two methods to private header.
* WebView/WebUnarchivingState.m:
(-[WebUnarchivingState archivedResourceForURL:]): Check if we should ignore the resource.
2007-03-15 Mark Rowe <mrowe@apple.com>
Reviewed by Antti.
Fix for <rdar://problem/5065060> ASSERTION FAILURE: newUsername && newPassword
when submitting an authentication form without password.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchWillSubmitForm): Don't omit form fields with empty values from the dictionary
passed to the delegate.
2007-03-14 Anders Carlsson <acarlsson@apple.com>
Reviewed by Dave Hyatt.
Don't add the data twice, it's also done by didReceiveData.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::deliverArchivedResources):
2007-03-14 Anders Carlsson <acarlsson@apple.com>
Fix segmentation fault when running layout tests.
Remove bogus check that that I added on purpose to see how good Geoff is at spotting mistakes when reviewing code.
(Turns out he's not that good!)
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::increaseLoadCount):
2007-03-14 Anders Carlsson <acarlsson@apple.com>
Reviewed by Geoff.
http://bugs.webkit.org/show_bug.cgi?id=13076
REGRESSION: Multiple loading tabs cause assertion in WebDocumentLoaderMac::decreaseLoadCount(unsigned long)
Store the identifier set in the document loader since identifiers are per-webview and not global.
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::WebDocumentLoaderMac):
(WebDocumentLoaderMac::attachToFrame):
(WebDocumentLoaderMac::increaseLoadCount):
(WebDocumentLoaderMac::decreaseLoadCount):
2007-03-14 David Harrison <harrison@apple.com>
Reviewed by Maciej.
<rdar://problem/5009625> REGRESSION: Aperture 1.5: Can't select entire line of text after correcting a misspelled word
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::respondToChangedSelection):
* WebCoreSupport/WebFrameBridge.mm:
Provide compatibility by not sending WebViewDidChangeSelectionNotification if
the app is Aperture and is linked against WebKit 2.0.
=== Safari-5522.4 ===
2007-03-14 Anders Carlsson <acarlsson@apple.com>
Reviewed by Geoff.
<rdar://problem/5058714>
http://bugs.webkit.org/show_bug.cgi?id=13050
World leaks seen on Leopard after opening then closing tab (13050)
Add a hash set to prevent the load count to be increased twice for the same resource.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.mm:
(loadingResources):
(WebDocumentLoaderMac::increaseLoadCount):
(WebDocumentLoaderMac::decreaseLoadCount):
2007-03-14 Adele Peterson <adele@apple.com>
Reviewed by Darin.
Removed _insertTextWithEvent, _insertNewlineWithEvent, and _insertTextWithEvent.
Instead, use execCommand and insertText methods on the Editor.
* WebView/WebHTMLView.mm:
(-[WebHTMLView insertTab:]):
(-[WebHTMLView insertBacktab:]):
(-[WebHTMLView insertNewline:]):
(-[WebHTMLView insertLineBreak:]):
(-[WebHTMLView insertParagraphSeparator:]):
(-[WebHTMLView insertNewlineIgnoringFieldEditor:]):
(-[WebHTMLView insertTabIgnoringFieldEditor:]):
(-[WebHTMLView yank:]):
(-[WebHTMLView yankAndSelect:]):
(-[WebHTMLView doCommandBySelector:]):
(-[WebHTMLView insertText:]):
2007-03-14 David Hyatt <hyatt@apple.com>
Fixes to ensure that the resource loader's shared buffer can always be used.
Reviewed by olliej, mjs
* Misc/WebIconDatabase.mm:
(-[WebIconDatabase _convertToWebCoreFormat]):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::deliverArchivedResources):
2007-03-13 Oliver Hunt <oliver@apple.com>
Reviewed by Brady.
Modify subresourceForURL to take NSString argument
so we can avoid [NSURL absoluteString]
* WebView/WebDataSource.mm:
(-[WebDataSource subresourceForURL:]):
2007-03-13 Brady Eidson <beidson@apple.com>
Rubberstamped by Alice
Meant to be part of my previous checkin... pruning unused code from WebKit
* WebView/WebFrame.mm: Removed _canCachePage
* WebView/WebFrameInternal.h: Ditto
2007-03-13 Beth Dakin <bdakin@apple.com>
Reviewed by Maciej.
Fix for <rdar://problem/4277074> 8F32: Help Viewer crashed on
clicking link - KHTMLView::viewportMouseReleaseEvent (12647)
Re-set the DocumentLoader's frame when loading it from the page
cache before setting the document view.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::setDocumentViewFromPageCache):
2007-03-13 Timothy Hatcher <timothy@apple.com>
Reviewed by Geoff.
<rdar://problem/5057117> Spoof user agent on Yahoo.com with Safari and WebKit as version 4xx
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView userAgent]): Stop using the deprecated lossyCString method.
* WebCoreSupport/WebFrameBridge.mm: Removed dead code, userAgentForURL: wasn't used.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::userAgent): Call WebView's _userAgentForURL:.
* WebView/WebView.mm:
(-[WebView _cachedResponseForURL:]): Call userAgentForURL: instead of _userAgent.
(-[WebView userAgentForURL:]): Call _userAgentForURL:.
(-[WebView _userAgentWithApplicationName:andWebKitVersion:]): New method to construct a UA.
(-[WebView _computeUserAgent]): Ractored out into _userAgentWithApplicationName:andWebKitVersion:
(-[WebView _userAgentForURL:]): Tail compare for Yahoo.com, and return a UA with an older WebKit version.
* WebView/WebViewInternal.h: Declare _userAgentForURL:.
2007-03-12 David Harrison <harrison@apple.com>
Reviewed by Darin.
<rdar://problem/4743256> ctrl-y key binding (yank) should do nothing when kill ring is empty
Test updated:
* editing/pasteboard/emacs-cntl-y-001.html:
* WebView/WebHTMLView.mm:
(-[WebHTMLView yank:]):
(-[WebHTMLView yankAndSelect:]):
Do nothing if the killring is empty.
2007-03-12 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
- update for the new naming scheme for the Objective-C wrapper-creation
functions: _wrapElement: instead of _elementWith:, etc.
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::textFieldDidBeginEditing):
(WebEditorClient::textFieldDidEndEditing):
(WebEditorClient::textDidChangeInTextField):
(WebEditorClient::doTextFieldCommandFromEvent):
(WebEditorClient::textWillBeDeletedInTextField):
(WebEditorClient::textDidChangeInTextArea):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createPlugin):
(WebFrameLoaderClient::createJavaAppletWidget):
* WebView/WebFrame.mm: (kit):
Use the _wrapElement-style functions.
2007-03-12 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
<rdar://problem/5057575>
REGRESSION: Repro Crash in FrameLoader::frame loading about:blank in PLT
Always get the web view from the current web frame, since the document loader's frame can have been zeroed out
(for example when detaching the document loader).
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
(WebFrameLoaderClient::assignIdentifierToInitialRequest):
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebFrameLoaderClient::dispatchDidFinishLoading):
2007-03-11 Oliver Hunt <oliver@apple.com>
Reviewed by Adele.
Moved respondToChangedSelection from FrameBridge to EditorClient
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::respondToChangedSelection):
* WebCoreSupport/WebFrameBridge.mm:
Removed respondToChangedSelection from bridge
2007-03-11 Darin Adler <darin@apple.com>
Reviewed by Adele.
- fix http://bugs.webkit.org/show_bug.cgi?id=12964
<rdar://problem/5045717> REGRESSION: crash in -[WebBaseNetscapePluginStream _deliverData]
at simpsonsmovie.com (12964)
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:]):
At every place we call the plug-in, since it could destroy the stream, get pluginView into a local
variable; it will be set to nil if the stream is destroyed.
(-[WebBaseNetscapePluginStream _destroyStream]): Added calls to retain/release to handle the case where
one of the calls to the plug-in destroys the stream. Added a call to cancelPreviousPerformRequestsWithTarget
in case _deliverData has been scheduled but not yet delivered. Also get pluginView into a local variable
as mentioned above, and check at strategic points and exit if the stream was already destroyed to avoid
multiple calls to NPP_DestroyStream or NPP_URLNotify.
(-[WebBaseNetscapePluginStream _deliverData]): Ditto.
2007-03-10 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Fixed <rdar://problem/4587763> PAC file: lock inversion between QT and
JSCore causes a hang @ www.panoramas.dk
See JavaScriptCore ChangeLog for details.
Drop the JSLock before making calls through the plug-in API from functions
that may have been called by JavaScript.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView sendEvent:]):
(-[WebBaseNetscapePluginView setWindowIfNecessary]):
(-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:DOMElement:]):
(-[WebBaseNetscapePluginView createPluginScriptableObject]):
(-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]):
(-[WebBaseNetscapePluginView webFrame:didFinishLoadWithReason:]):
(-[WebBaseNetscapePluginView loadPluginRequest:]):
(-[WebBaseNetscapePluginView _printedPluginBitmap]):
* Plugins/WebPluginController.mm:
(+[WebPluginController plugInViewWithArguments:fromPluginPackage:]):
(-[WebPluginController startAllPlugins]):
(-[WebPluginController stopAllPlugins]):
(-[WebPluginController addPlugin:]):
(-[WebPluginController destroyPlugin:]):
(-[WebPluginController destroyAllPlugins]):
2007-03-10 David Kilzer <ddkilzer@webkit.org>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=9609
REGRESSION: Missing image icon needs to be moved back to WebKit
* WebView/WebHTMLView.mm:
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
Use WebCore::Image::loadPlatformResource(const char*) to load the missingImage image.
2007-03-10 Mark Rowe <mrowe@apple.com>
Reviewed by John.
<rdar://problem/5051827> HIWebView handling of kEventControlGetData is broken in 64-bit
On Leopard the kEventParamControlDataBufferSize event parameter is of type typeByteCount.
The 32-bit implementation of GetEventParameter will coerce between integer types and
typeByteCount while the 64-bit version will return a failure. As typeByteCount is new
in Leopard we must continue using typeSInt32 when building for Tiger.
* Carbon/HIWebView.m:
(HIWebViewEventHandler):
2007-03-09 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4976254> Please get off _NSSoftLinkingGetFrameworkFuncPtr
Use dlopen and dlsym to access the DCSShowDictionaryServiceWindow function.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]):
2007-03-09 Darin Adler <darin@apple.com>
Reviewed by Justin.
- fix http://bugs.webkit.org/show_bug.cgi?id=8928
<rdar://problem/5045708> REPRODUCIBLE ASSERT: Cannot paste HTML into a
contenteditable region in an XHTML document (8928)
* WebView/WebHTMLView.mm:
(-[WebHTMLView _hasHTMLDocument]): Added.
(-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
Don't call AppKit's conversion from the DOM to an attributed string if the document
is not an HTML document, to work around an AppKit limitation (Radar 5052390).
2007-03-09 Darin Adler <darin@apple.com>
* English.lproj/StringsNotToBeLocalized.txt: Updated for recent changes.
2007-03-08 Mark Rowe <mrowe@apple.com>
Reviewed by Tim Hatcher.
<rdar://problem/5051616> Mouse clicks and movement are ignored in HIWebView on 64-bit
Mouse events are not being handled correctly as GetControlKind is returning an error
on 64-bit. The more modern HIObjectIsOfClass behaves correctly for this use.
* Carbon/HIWebView.m:
(HIWebViewDestructor):
(WindowHandler): Use HIObjectIsOfClass in place of GetControlKind.
(HIWebViewEventHandler): Don't leak the NSEvent.
2007-03-08 Bruce Q Hammond <bruceq@apple.com>
Reviewed by Darin.
Fix for http://bugs.webkit.org/show_bug.cgi?id=13009
Console spews "CGContextGetType: invalid context" non-stop on web site
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
(-[WebBaseNetscapePluginView restorePortState:]):
2007-03-08 Mark Rowe <mrowe@apple.com>
Reviewed by Tim Hatcher.
<rdar://problem/4561772> HIWebView does not exist for 64-bit
Update HIWebView and friends to work without QuickDraw.
Changes are gleaned from the 64-bit support inside HICocoaView. The main
fact of interest are that all Carbon windows must have compositing enabled
so the code paths that aren't accessible are #ifdef'd out. Conveniently
these are the exact code paths that make use of QuickDraw.
There are currently minor event-handling and invalidation issues running as
64-bit that are not present in 32-bit.
* Carbon/CarbonUtils.m:
* Carbon/CarbonWindowAdapter.m:
* Carbon/CarbonWindowFrame.m:
* Carbon/HIViewAdapter.m:
(SetViewNeedsDisplay):
* Carbon/HIWebView.m:
(Draw):
(Click):
(SyncFrame):
(StartUpdateObserver):
(StopUpdateObserver):
(UpdateObserver):
* WebKit.LP64.exp: Removed.
* WebKit.xcodeproj/project.pbxproj: Always use WebKit.exp.
2007-03-08 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
<rdar://problem/4664697> highlighter SPI needs a node parameter to give more context
Added new methods to the WebHTMLHighlighter protocol that include the DOMNode being painted.
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge customHighlightRect:forLine:representedNode:WebCore::]):
(-[WebFrameBridge paintCustomHighlight:forBox:onLine:behindText:entireLine:representedNode:WebCore::]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLViewPrivate.h:
2007-03-08 Anders Carlsson <acarlsson@apple.com>
Try fixing the buildbot build.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
2007-03-07 Anders Carlsson <acarlsson@apple.com>
Leopard build fix.
* Plugins/WebBaseNetscapePluginView.mm:
2007-03-07 Bruce Q Hammond <bruceq@apple.com>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=12515
Plug-ins that draw through the Quickdraw interface fail in a CGBitmapContex.
<rdar://problem/4975122>
This fixes a problem with Netscape-style Plug-ins which draw through the Quickdraw APIs
being unable to render into offscreen bitmap contexts.
This patches both saveAndSetNewPortStateForUpdate: and restorePortState:
These methods now check the current context and see if appropriate setup/cleanup needs to be done
for offscreen rendering.
* Plugins/WebBaseNetscapePluginView.mm:
(QDPixelFormatFromCGBitmapInfo):
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
(-[WebBaseNetscapePluginView restorePortState:]):
2007-03-07 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
Use HardRetain/HardRelease.
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::setDataSource):
(WebDocumentLoaderMac::attachToFrame):
(WebDocumentLoaderMac::detachFromFrame):
(WebDocumentLoaderMac::increaseLoadCount):
(WebDocumentLoaderMac::decreaseLoadCount):
2007-03-07 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
<rdar://problem/4961259>
REGRESSION: Bumper Car 2.1.1 - Crash at WebCore::FrameLoader::receivedMainResourceError when encountering a invalid URL address
(The crash was already fixed, this actually makes Bumper Car load the error page correctly.)
This adds a "load counter" to the document loader and keeps the data source retained for as long as something is loading.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchWillSendRequest):
Increase the load counter.
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
Decrease the load counter,
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::WebDocumentLoaderMac):
(WebDocumentLoaderMac::attachToFrame):
If the document loader has been detached, make sure to retain its data source here.
(WebDocumentLoaderMac::detachFromFrame):
Release the data source.
(WebDocumentLoaderMac::increaseLoadCount):
Retain the data source if load count was 0.
(WebDocumentLoaderMac::decreaseLoadCount):
Release the data source if load count becomes 0
2007-03-07 Adele Peterson <adele@apple.com>
Reviewed by Darin.
WebKit part of fix for:
http://bugs.webkit.org/show_bug.cgi?id=10871
http://bugs.webkit.org/show_bug.cgi?id=12677
<rdar://problem/4823129> REGRESSION: IME key events different in nightly
<rdar://problem/4759563> REGRESSION: Return key is always sent when you confirm a clause in kotoeri
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent: shouldSaveCommand:]): Added shouldSaveCommand field to WebHTMLViewInterpretKeyEventsParameters.
When shouldSaveCommand is true, we call interpretKeyEvents and in doCommandBySelector and insertText, we just save the information without performing any action.
When shouldSaveCommand is false, we used the saved information and call doCommandBySelector and insertText directly.
If there's no saved command data in the KeyboardEvent, call interpretKeyEvents, and honor the shouldSaveCommand argument. This allows repeating keypress events
to function normally.
(-[WebHTMLView doCommandBySelector:]): If the WebHTMLViewInterpretKeyEventsParameters shouldSaveCommand field is set, then
just save the selector information in the KeyboardEvent, and don't perform the action.
(-[WebHTMLView insertText:]): ditto.
insertText can be called from an input method or from normal key event processing
If its from an input method, then we should go ahead and insert the text now.
The only way we know if its from an input method is to check hasMarkedText. There might be a better way to do this.
* WebView/WebHTMLViewInternal.h: Added shouldSaveCommand argument.
* WebView/WebViewInternal.h: ditto.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::handleKeypress): Changed handleKeyPress to handleKeypress. Call _interceptEditingKeyEvent with shouldSaveCommand:NO.
(WebEditorClient::handleInputMethodKeypress): Call _interceptEditingKeyEvent with shouldSaveCommand:YES.
2007-03-07 Anders Carlsson <acarlsson@apple.com>
Reviewed by Brady.
Update to match WebCore.
* Plugins/WebNetscapePluginStream.mm:
(-[WebNetscapePluginStream start]):
2007-03-07 Jim Correia <jim.correia@pobox.com>
Reviewed by Darin.
- WebCore part of fix for http://bugs.webkit.org/show_bug.cgi?id=12463
WebArchiver - attempt to insert nil exception when archive empty iframe
When dealing with an iframe element with no src attribute, the element contains
a src attribute in the DOM with a URL of "about:blank" and some HTML to implement
the blank page. In the original page source, however, the iframe element does
not include a src attribute, which caused a nil archive to be returned for the
childFrameArchive and thus caused the bug. The fix is a simple nil check.
Test: webarchive/archive-empty-frame-source.html
* WebView/WebArchiver.mm:
(+ (NSArray *)_subframeArchivesForFrame:(WebFrame *)frame): Don't add childFrameArchive
to the subframeArchives array if it is nil.
2007-03-06 John Sullivan <sullivan@apple.com>
Reviewed by Darin
Made WebAuthenticationHandler.h SPI so Safari can call it directly.
* WebKit.exp:
added .objc_class_name_WebPanelAuthenticationHandler
* WebKit.xcodeproj/project.pbxproj:
changed status of WebAuthenticationHandler.h from "project" to "private"
2007-03-06 Kevin McCullough <kmccullough@apple.com>
Reviewed by Darin.
- Rename a function to clarify its purpose.
* WebView/WebView.mm:
(+[WebView registerURLSchemeAsLocal:]):
* WebView/WebViewPrivate.h:
2007-03-06 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam.
Update for WebCore changes.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::userAgent):
2007-03-05 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam, Darin.
<rdar://problem/5025212>
In Mail, a crash occurs at WebCore::Frame::tree() when clicking on embedded flash object
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView loadPluginRequest:]):
Handle the case where the web view returned from the delegate method is null. Also, send out an error notification
in that case so we can catch it.
2007-03-05 John Sullivan <sullivan@apple.com>
Reviewed by Darin and Kevin D
- fixed <rdar://problem/5038087> Header and footer on printed page are too large after certain steps
* WebView/WebView.mm:
(-[WebView _adjustPrintingMarginsForHeaderAndFooter]):
This method was modifying the margins in the NSPrintInfo object without any sort of check whether
this had already been done. In some cases this can be called multiple times with the same
NSPrintInfo, so now we stash information in the NSPrintInfo's dictionary such that we always
start with a fresh copy of the original margins.
2007-03-02 Kevin McCullough <kmccullough@apple.com>
Reviewed by Geoff.
- rdar://problem/4922454
- This fixes a security issue by making remote referrers not able to access local
resources, unless they register their schemes to be treated as local. The result is
that those schemes can access local resources and cannot be accessed by remote
referrers.
Because this behavior is new a link-on-or-after check is made to determine if the
app should use the older, less safe, behavior.
* Misc/WebKitVersionChecks.h: added linked-on-or-after check
* Misc/WebNSAttributedStringExtras.mm: Moved functionalit into the base class.
(fileWrapperForElement):
* Plugins/WebNetscapePluginStream.mm: uses new canLoad functions
* Plugins/WebPluginContainerCheck.mm: uses new canLoad functions
(-[WebPluginContainerCheck _isForbiddenFileLoad]):
* WebView/WebView.mm: make linked-on-or-after check and cache value, exposes SPI
for registering a scheme as local.
(-[WebView _commonInitializationWithFrameName:groupName:]):
(+[WebView registerSchemeAsLocal:]):
* WebView/WebViewPrivate.h: exposes SPI for registering a scheme as local.
2007-03-01 Justin Garcia <justin.garcia@apple.com>
Reviewed by harrison
<rdar://problem/4838199>
Integrate Mail and WebKit paste operations
Provide subresources used to create the fragment as a
convenience.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:chosePlainText:]):
Update the calls to the changed method.
(-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
Give the caller the subresources in the WebArchive and RTF cases.
* WebView/WebHTMLViewPrivate.h:
2007-02-28 Oliver Hunt <oliver@apple.com>
Reviewed by Maciej.
Fixes <rdar://problem/5012009>
When looking for a requested resource we should also check
the set of manually added subresources if WebCore can't find it.
* WebView/WebDataSource.mm:
(-[WebDataSource subresourceForURL:]):
2007-02-28 Brady Eidson <beidson@apple.com>
Reviewed by Beth
Start using the Thread Safety Check implemented in WebCore for the DOM bindings in the rest of
the WebKit API instead of the ASSERT_MAIN_THREAD() hack
* History/WebBackForwardList.mm:
(-[WebBackForwardList initWithWebCoreBackForwardList:]):
(-[WebBackForwardList init]):
(-[WebBackForwardList dealloc]):
(-[WebBackForwardList finalize]):
* History/WebHistoryItem.mm:
(-[WebHistoryItem initWithURLString:title:lastVisitedTimeInterval:]):
(-[WebHistoryItem dealloc]):
(-[WebHistoryItem finalize]):
(-[WebHistoryItem copyWithZone:]):
(-[WebHistoryItem initWithWebCoreHistoryItem:]):
* Misc/WebIconDatabase.mm:
(-[WebIconDatabase init]):
2007-02-28 Adele Peterson <adele@apple.com>
Reviewed by Beth.
Fix for <rdar://problem/4887423> REGRESSION: search results popup menu strings are not localized
and <rdar://problem/3517227> accessibility-related strings in WebCore are not localized
* WebCoreSupport/WebViewFactory.mm:
(-[WebViewFactory searchMenuNoRecentSearchesText]):
(-[WebViewFactory searchMenuRecentSearchesText]):
(-[WebViewFactory searchMenuClearRecentSearchesText]):
(-[WebViewFactory AXWebAreaText]):
(-[WebViewFactory AXLinkText]):
(-[WebViewFactory AXListMarkerText]):
(-[WebViewFactory AXImageMapText]):
(-[WebViewFactory AXHeadingText]):
2007-02-28 Mark Rowe <mrowe@apple.com>
Reviewed by Maciej.
<rdar://problem/5028473> WebKit allocates a huge number of NSCalendarDates while loading history file
* History/WebHistory.mm:
(-[WebHistoryPrivate insertItem:atDateIndex:]): Use lastVisitedTimeInterval rather than _lastVisitedDate to avoid allocating NSCalendarDates.
2007-02-28 Mark Rowe <mrowe@apple.com>
Reviewed by Tim Hatcher.
<rdar://problem/4985524> Problem with Blot and ToT WebKit (decoding WebCoreScrollView)
References to WebCoreScrollView as a subview of a WebHTMLView may be present in some NIB
files, so NSUnarchiver must be still able to look up the WebCoreScrollView class.
* WebKit.exp: Export WebCoreScrollView symbol.
* WebView/WebHTMLView.mm: Add empty WebCoreScrollView class.
2007-02-27 Adam Roben <aroben@apple.com>
Reviewed by Beth.
Fix <rdar://problem/5011905> REGRESSION: "Open Link" contextual menu
item appears twice
* WebCoreSupport/WebContextMenuClient.mm:
(fixMenusToSendToOldClients): Remove the "Open Link" item from the
default menu items array before sending it off to Tiger Mail.
(WebContextMenuClient::getCustomMenuFromDefaultItems): Set the
representedObject on every NSMenuItem to match our old (correct) API
behavior.
2007-02-27 Mitz Pettel <mitz@webkit.org>
Reviewed by Darin.
- http://bugs.webkit.org/show_bug.cgi?id=12906
REGRESSION: Canvas is pixelated when the page is opened in a background tab
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::scaleFactor): If the view is not in a window, use the main
screen's scale factor as a best guess.
2007-02-26 John Sullivan <sullivan@apple.com>
Reviewed by Darin and Geoff
* WebView/WebHTMLView.mm:
(coreGraphicsScreenPointForAppKitScreenPoint):
This method was copied from WebBrowser, and it was wrong. Fixed it. This only
affects the Dictionary pop-up panel.
2007-02-26 David Hyatt <hyatt@apple.com>
Update web inspector to account for border-fit.
Reviewed by darin
* WebInspector/webInspector/inspector.js:
2007-02-26 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Re-arranged things to put deprecated methods at the bottom.
* Misc/WebCoreStatistics.h:
* Misc/WebCoreStatistics.mm:
(+[WebCoreStatistics javaScriptNoGCAllowedObjectsCount]):
(+[WebCoreStatistics javaScriptReferencedObjectsCount]):
(+[WebCoreStatistics javaScriptRootObjectClasses]):
* WebKit.xcodeproj/project.pbxproj:
2007-02-26 Maciej Stachowiak <mjs@apple.com>
Rubber stamped by Mitz.
- fix layout tests by fixing discrepancy in feature macros.
* WebInspector/WebInspector.m:
(-[WebInspector _highlightNode:]):
* WebKit.xcodeproj/project.pbxproj:
2007-02-23 Mitz Pettel <mitz@webkit.org>
Reviewed by Maciej.
- fix http://bugs.webkit.org/show_bug.cgi?id=11573
REGRESSION: pressing option-left arrow while in suggestion popup moves the insertion point to the left
* WebView/WebHTMLView.mm:
(-[WebTextCompleteController endRevertingChange:moveLeft:]):
2007-02-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Brady.
<rdar://problem/5016395> _recursive_pauseNullEventsForAllNetscapePlugins still gone
* WebView/WebFrameInternal.h: Remove _recursive_pauseNullEventsForAllNetscapePlugins
* WebView/WebFramePrivate.h: Add _recursive_pauseNullEventsForAllNetscapePlugins
* WebView/WebFrame.mm: More _recursive_pauseNullEventsForAllNetscapePlugins
2007-02-22 Adele Peterson <adele@apple.com>
Reviewed by John.
Updating this image to match the one in WebCore.
* WebKit.vcproj/textAreaResizeCorner.png:
2007-02-22 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
Fix for http://bugs.webkit.org/show_bug.cgi?id=12399 REGRESSION:
Unable to prevent default context menu from appearing. <rdar://
problem/5017416>
* WebView/WebHTMLView.mm:
(-[WebHTMLView menuForEvent:]): Clear the controller's context menu
before propagating a new context menu event through the DOM.
2007-02-22 John Sullivan <sullivan@apple.com>
Reviewed by Darin
Removed some unused keyView-related code that I happened to run across.
Replacement code is now in WebChromeClient.
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.mm:
removed unused stuff
2007-02-22 Mitz Pettel <mitz@webkit.org>
Reviewed by Maciej.
- fix http://bugs.webkit.org/show_bug.cgi?id=12804
REGRESSION (r19043-r19063): suggestion popup doesn't work after pressing Option+Esc
This patch also fixes a bug where using the arrow keys while
the suggestion popup is open moves the caret instead of changing the
selection in the popup (for up/down) or accepting the selection and
closing the popup (for left/right).
* WebView/WebHTMLView.mm:
(-[WebHTMLView keyDown:]): Changed to close the popup only if it was open
before the current event, so that the Option-Esc that opens the popup will
not close it immediately.
(-[WebHTMLView _interceptEditingKeyEvent:]): Give the completion popup a
chance to intercept keydown events.
(-[WebTextCompleteController popupWindowIsOpen]): Added. Returns whether the
suggestion popup is open.
2007-02-22 Mitz Pettel <mitz@webkit.org>
Reviewed by Mark (age 21).
- fix http://bugs.webkit.org/show_bug.cgi?id=12805
REGRESSION: suggestion popup has a disabled scroll bar
* WebView/WebHTMLView.mm:
(-[WebTextCompleteController _buildUI]): Uncommented the call to the NSWindow
SPI that forces the scroll bar to look active. Also replaced a call to
the deprecated NSTableView method setAutoresizesAllColumnsToFit: with
the new method setColumnAutoresizingStyle: to eliminate console spew.
2007-02-20 Beth Dakin <bdakin@apple.com>
Reviewed by Maciej.
WebKit changes needed to implement writeImage() in WebCore's
Pasteboard class.
* Misc/WebKitNSStringExtras.m: Call into WebCore for these
implementations.
(-[NSString _webkit_hasCaseInsensitiveSuffix:]):
(-[NSString _webkit_hasCaseInsensitiveSubstring:]):
(-[NSString _webkit_filenameByFixingIllegalCharacters]):
* Misc/WebNSURLExtras.m: Same.
(-[NSURL _webkit_suggestedFilenameWithMIMEType:]):
* WebCoreSupport/WebContextMenuClient.h: Remove
copyImageToClipboard()
* WebCoreSupport/WebContextMenuClient.mm:
* WebCoreSupport/WebSystemInterface.m: Expose
GetExtensionsForMIMEType and GetPreferredExtensionForMIMEType to
WebCore.
(InitWebCoreSystemInterface):
* WebCoreSupport/WebViewFactory.mm: New localized string for
WebCore.
(-[WebViewFactory copyImageUnknownFileLabel]):
2007-02-20 Adam Roben <aroben@apple.com>
Reviewed by Darin and Anders.
Update WebKit for WebCore fix for <rdar://problem/4736215> Make
WebCoreStringTruncator use WebCore types.
* Misc/WebStringTruncator.m:
(defaultMenuFont): Moved from WebCoreStringTruncator.mm.
(core): Added.
(+[WebStringTruncator centerTruncateString:toWidth:]):
(+[WebStringTruncator centerTruncateString:toWidth:withFont:]):
(+[WebStringTruncator rightTruncateString:toWidth:withFont:]):
(+[WebStringTruncator widthOfString:font:]):
* WebKit.xcodeproj/project.pbxproj: Changed WebStringTruncator to ObjC++.
2007-02-20 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
Fixes the version number returned when using a CFBundleVersion of "420+".
* WebView/WebView.mm:
(-[WebView _userVisibleBundleVersionFromFullVersion:]): Check the length up to the first
non-decimal digit, so this works with versions that have "." and "+".
2007-02-20 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
- fixed <rdar://problem/4989344> REGRESSION: After clicking on page, Find
won't find anything if all hits are before the clicked point
This was caused by a mismatch between WebCore's search code's notion of "selection" and
WebView's search code's notion of "selection". WebCore's search code was starting
just before or just after the "selection", which included collapsed, zero-length
selections. WebKit's search code was only considering non-zero-length selections,
and would not search all of the content when there was a zero-length selection.
The fix was to make WebKit ignore the selection. This has a side effect of increasing
the amount of redundantly-searched content in the case where no matches are found. To
compensate for that, I special-cased the most common case of WebViews with a single frame,
to avoid ever searching redundantly in those.
* WebView/WebView.mm:
(-[WebView searchFor:direction:caseSensitive:wrap:startInSelection:]):
remove startHasSelection ivar; special-case WebViews with only one frame; clarify the
code that leads to redundant searching with comments.
2007-02-20 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4900579> WebKit -finalize methods are not thread-safe; design change needed
Call WebCoreObjCFinalizeOnMainThread from the initialize method of all the classes
that have a finalizer that needs called on the main thread. Assert in finalize that we
are on the main thread.
* Carbon/CarbonWindowAdapter.m:
(+[CarbonWindowAdapter initialize]):
(-[CarbonWindowAdapter finalize]):
* History/WebBackForwardList.mm:
(+[WebBackForwardList initialize]):
(-[WebBackForwardList finalize]):
* History/WebHistoryItem.mm:
(+[WebHistoryItem initialize]):
* Misc/WebElementDictionary.mm:
(+[WebElementDictionary initialize]):
(-[WebElementDictionary finalize]):
* Plugins/WebBaseNetscapePluginStream.m:
(+[WebBaseNetscapePluginStream initialize]):
(-[WebBaseNetscapePluginStream finalize]):
* Plugins/WebBaseNetscapePluginView.mm:
(+[WebBaseNetscapePluginView initialize]):
(-[WebBaseNetscapePluginView finalize]):
* Plugins/WebBasePluginPackage.m:
(+[WebBasePluginPackage initialize]):
(-[WebBasePluginPackage finalize]):
* Plugins/WebNetscapePluginStream.mm:
(-[WebNetscapePluginStream finalize]):
* WebCoreSupport/WebEditorClient.mm:
(+[WebEditCommand initialize]):
(-[WebEditCommand finalize]):
* WebCoreSupport/WebFrameBridge.mm:
(+[WebFrameBridge initialize]):
(-[WebFrameBridge finalize]):
* WebCoreSupport/WebFrameLoaderClient.mm:
(+[WebFramePolicyListener initialize]):
(-[WebFramePolicyListener finalize]):
* WebView/WebHTMLView.mm:
(+[WebHTMLView initialize]):
(-[WebHTMLView finalize]):
* WebView/WebView.mm:
(+[WebViewPrivate initialize]):
(-[WebViewPrivate finalize]):
2007-02-20 Justin Garcia <justin.garcia@apple.com>
Reviewed by darin
<rdar://problem/4838199>
Integrate Mail and WebKit paste operations
Mail overrides paste: because it has different
preferred pasteboard types, but it should use our
fragment creation code.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:chosePlainText:]):
Moved fragment creation code into a new method.
(-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:]):
Moved fragment creation code here.
* WebView/WebHTMLViewPrivate.h: Exposed
_documentFragmentFromPasteboard:forType:inContext: as SPI.
2007-02-20 John Sullivan <sullivan@apple.com>
Reviewed by Tim Hatcher
* Misc/WebKitNSStringExtras.h:
* Misc/WebKitNSStringExtras.m:
removed _webkit_userVisibleBundleVersionFromFullVersion; we decided to do this without
adding SPI for it.
* WebView/WebView.mm:
(-[WebView _userVisibleBundleVersionFromFullVersion:]):
new method, moved here from WebKitNSStringExtras, and is now a WebView method rather than
an NSString method
(-[WebView _computeUserAgent]):
updated for method signature change
2007-02-20 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
* Misc/WebKitNSStringExtras.h: Added _webkit_userVisibleBundleVersionFromFullVersion.
* Misc/WebKitNSStringExtras.m:
(-[NSString _webkit_userVisibleBundleVersionFromFullVersion]): If the version is 4 digits long or longer,
then the first digit represents the version of the OS. Our user agent string should not
include this first digit, so strip it off and report the rest as the version.
* WebView/WebView.mm:
(-[WebView _computeUserAgent]): Call _webkit_userVisibleBundleVersionFromFullVersion on the CFBundleVersion.
2007-02-20 Darin Adler <darin@apple.com>
Reviewed by Anders.
* Plugins/WebPluginController.mm: (-[WebPluginController pluginView:receivedResponse:]):
Call cancelMainResourceLoad on the document loader instead of the frame loader.
2007-02-20 Anders Carlsson <acarlsson@apple.com>
Reviewed by Mitz.
<rdar://problem/5009627> REGRESSION: Repro overrelease of WebView in failed load, seen in DumpRenderTree
* WebView/WebView.mm:
(-[WebView _removeObjectForIdentifier:]):
Return early if the identifier can't be found in the map.
2007-02-19 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin Adler.
<rdar://problem/4841078> Remove the Mail.app editable link clicking behavior workaround when it is no longer needed
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebView.mm:
(-[WebView setPreferences:]):
2007-02-19 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam.
<rdar://problem/4868242>
http://bugs.webkit.org/show_bug.cgi?id=12670
REGRESSION: Many 3rd Party Apps crash in WebCore::DocumentLoader::frameLoader() (12670)
Bring back the semantic we had that a web view should be retained for as long as something is loading. Use the identifier
to object hash map for this.
* WebView/WebView.mm:
(-[WebView _addObject:forIdentifier:]):
(-[WebView _removeObjectForIdentifier:]):
2007-02-18 Brady Eidson <beidson@apple.com>
Reviewed by Oliver
<rdar://problem/4985321> - Can't edit templates for Web Gallery/Web Page Export in Aperture
* Misc/WebKitVersionChecks.h: Add a #define for this APERTURE quirk
* WebView/WebView.mm:
(-[WebView _shouldChangeSelectedDOMRange:toDOMRange:affinity:stillSelecting:]):
If the current app is Aperture and it was linked against Tiger WebKit, always allow selection change
2007-02-17 Lars Knoll <lars@trolltech.com>
Reviewed by Maciej.
Additional coding by Maciej, additional review by Oliver.
Added implementations for the new callbacks in EditorClient
and ChromeClient (basically moved from WebFrameBridge).
Cleaned up some code paths that are not called anymore
and done fully inside WebCore now.
* DefaultDelegates/WebDefaultContextMenuDelegate.mm:
* Misc/WebElementDictionary.mm:
* Misc/WebNSAttributedStringExtras.mm:
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView getVariable:value:]):
* Plugins/WebNetscapePluginEmbeddedView.mm:
* Plugins/WebNetscapePluginStream.mm:
* Plugins/WebPluginContainerCheck.mm:
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::shouldInterruptJavaScript):
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::shouldChangeSelectedRange):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge finishInitializingWithPage:frameName:frameView:ownerElement:]):
(-[WebFrameBridge fini]):
* WebCoreSupport/WebFrameLoaderClient.mm:
* WebView/WebArchiver.mm:
* WebView/WebFrame.mm:
(core):
(kit):
(-[WebFrame _updateBackground]):
* WebView/WebFrameInternal.h:
* WebView/WebFrameView.mm:
* WebView/WebHTMLRepresentation.mm:
* WebView/WebHTMLView.mm:
(-[WebHTMLView _updateMouseoverWithEvent:]):
(-[WebHTMLView _isEditable]):
(-[WebHTMLView validateUserInterfaceItem:]):
(-[WebHTMLView maintainsInactiveSelection]):
(-[WebHTMLView scrollWheel:]):
(-[WebHTMLView acceptsFirstMouse:]):
(-[WebHTMLView shouldDelayWindowOrderingForEvent:]):
(-[WebHTMLView cut:]):
(-[WebHTMLView paste:]):
(-[WebHTMLView selectedAttributedString]):
* WebView/WebScriptDebugDelegate.mm:
* WebView/WebView.mm:
(-[WebView _dashboardRegions]):
(-[WebView setProhibitsMainFrameScrolling:]):
(-[WebView _setInViewSourceMode:]):
(-[WebView _inViewSourceMode]):
(-[WebView shouldClose]):
(-[WebView setEditable:]):
2007-02-18 Oliver Hunt <oliver@apple.com>
Reviewed by Adam.
Moving the drag initiation logic to WebCore.
The redundant code in webkit will be moved out in a later patch.
* WebCoreSupport/WebDragClient.h:
* WebCoreSupport/WebDragClient.mm:
(getTopHTMLView):
Helper function
(WebDragClient::willPerformDragSourceAction):
(WebDragClient::startDrag):
(WebDragClient::createDragImageForLink):
Implemented new DragClient methods
(WebDragClient::declareAndWriteDragImage):
Helper function for the Mac to allow new drag and drop
code to match behaviour
* WebView/WebHTMLView.mm:
(-[WebHTMLView _dragImageForURL:withLabel:]):
(-[WebHTMLView _dragImageForLinkElement:]):
Refactoring old _dragImageForLinkElement function so that
the link drag image can be created with just a URL and label,
rather than requiring the original element
(-[WebHTMLView dragImage:at:offset:event:pasteboard:source:slideBack:]):
Removed logic that is no longer necessary
(-[WebHTMLView _mouseDownEvent]):
The WebDragClient may need the original mouseDownEvent of a drag when initiating
a drag
* WebView/WebHTMLViewInternal.h:
Declaring _mouseDownEvent
* WebView/WebHTMLViewPrivate.h:
Declaring _dragImageForURL
2007-02-16 John Sullivan <sullivan@apple.com>
Reviewed by Tim Hatcher
- fixed <rdar://problem/4811446> "Check Grammar" checkbox in Spelling+Grammar window doesn't
live update with menu change in WebKit
* WebView/WebView.mm:
(-[WebView setGrammarCheckingEnabled:]):
Use sekrit AppKit knowledge to tell NSSpellChecker about the change, since there's no API
for this yet. Also restructured a little to avoid extra work when the value hasn't changed.
2007-02-15 Brady Eidson <beidson@apple.com>
Reviewed by Adam
Save scroll state for back/forward navigation in FrameLoader, not the client
* WebCoreSupport/WebFrameLoaderClient.h: Renamed the save/restore methods
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::saveViewStateToItem): Save viewstate only
(WebFrameLoaderClient::restoreViewState): Restore viewstate only
2007-02-14 Alexey Proskuryakov <ap@webkit.org>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=12643
NPN_Status is using latin-1 encoding for the message instead of UTF-8
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView status:]): Check for possible conversion failure.
2007-02-13 Oliver Hunt <oliver@apple.com>
Reviewed by John.
Modify entry point ASSERTs for dragging functions to allow for the case
where a load has occurred mid-drag. The load may detach the HTMLView
from the WebView so it is no longer possible to check _isTopHTMLView.
The assertion changes match that of revision 14897 which fixed the
more common case ([WebHTMLView draggedImage:endedAt:operation:])
It's also necessary to check for a null Page now prior to accessing
the DragController, which is necessary in all of these methods.
See rdar://problem/4994870
* WebView/WebHTMLView.mm:
(-[WebHTMLView draggingSourceOperationMaskForLocal:]):
(-[WebHTMLView draggedImage:movedTo:]):
(-[WebHTMLView draggedImage:endedAt:operation:]):
(-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
2007-02-13 Alexey Proskuryakov <ap@webkit.org>
Reviewed by Maciej.
http://bugs.webkit.org/show_bug.cgi?id=12643
NPN_Status is using latin-1 encoding for the message instead of UTF-8
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView status:]): Use kCFStringEncodingUTF8.
2007-02-13 Mark Rowe <mrowe@apple.com>
Reviewed by Timothy Hatcher.
Fix http://bugs.webkit.org/show_bug.cgi?id=12745
Bug 12745: REGRESSION: Webkit will not load a plugin that Safari can load (symbol missing _objc_msgSend_fpret)
Treat libobjc as a sub-library of WebKit in Debug/Release so that plugins and applications linked against an
umbrella framework version of WebKit that expect to find libobjc symbols in WebKit can do so.
* WebKit.xcodeproj/project.pbxproj:
2007-02-12 Kevin McCullough <kmccullough@apple.com>
Reviewed by .
- reverting change to not cause regressions and performance problems.
* Misc/WebNSAttributedStringExtras.mm:
(fileWrapperForElement):
2007-02-12 Darin Adler <darin@apple.com>
Reviewed by Oliver.
- fix http://bugs.webkit.org/show_bug.cgi?id=12677
<rdar://problem/4759563> REGRESSION: Return key is always sent when you confirm
a clause in kotoeri (12677)
- fix http://bugs.webkit.org/show_bug.cgi?id=12596
<rdar://problem/4794346> REGRESSION: Tab key shifts form field focus instead of
navigating prediction window (12596)
- fix http://bugs.webkit.org/show_bug.cgi?id=10010
<rdar://problem/4822935> REGRESSION: Pressing Return with unconfirmed text in
Hangul inserts carriage return (10010)
- fix http://bugs.webkit.org/show_bug.cgi?id=12531
<rdar://problem/4975126> REGRESSION: Inline text input types repeated keys in
latest nightly (r19336) (12531)
- fix http://bugs.webkit.org/show_bug.cgi?id=12539
<rdar://problem/4975130> REGRESSION: Pressing Backspace while in inline input
area moves to the previous page in history (12539)
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm: (WebEditorClient::markedTextAbandoned):
Added.
* WebView/WebHTMLView.mm:
(-[WebHTMLView menuForEvent:]): Added explicit constructor needed now that the
function takes a const&.
(-[WebHTMLView becomeFirstResponder]): Removed fake event code, no longer needed
since advanceFocus now works fine with 0 for a DOM event.
(-[WebHTMLView _expandSelectionToGranularity:]): Changed to use the normal
selection controller function instead of selectRange.
(-[WebHTMLView insertTab:]): Changed to call bottleneck that receives the DOM
event.
(-[WebHTMLView insertBacktab:]): Ditto.
(-[WebHTMLView insertNewline:]): Ditto.
(-[WebHTMLView insertLineBreak:]): Ditto.
(-[WebHTMLView insertParagraphSeparator:]): Ditto.
(-[WebHTMLView insertNewlineIgnoringFieldEditor:]): Ditto.
(-[WebHTMLView insertTabIgnoringFieldEditor:]): Ditto.
(-[WebHTMLView yank:]): Updated to call Editor directly since the insertText
code now works via a text input event which is not what we want for paste-like
things such as yank.
(-[WebHTMLView yankAndSelect:]): Ditto.
(-[WebHTMLView selectToMark:]): Changed to use the normal selection controller
function instead of selectRange, which also allows us to remove the ObjC exception
handling code.
(-[WebHTMLView swapWithMark:]): Ditto.
(-[WebHTMLView transpose:]): Ditto.
(-[WebHTMLView unmarkText]): Since this is one of the calls back from the input
manager, added code to set the "event was handled" flag. Moved the actual work
into the Editor class in WebCore and just call that from here.
(-[WebHTMLView _selectRangeInMarkedText:]): Changed to use the normal selection
controller function instead of selectRange.
(-[WebHTMLView setMarkedText:selectedRange:]): Since this is one of the calls
back from the input manager, added code to set the "event was handled" flag.
Also changed the ignoreMarkedTextSelectionChange to use the flag over on the
WebCore side, since we moved it there and to call selectMarkedText over on
the WebCore side too.
(-[WebHTMLView doCommandBySelector:]): Added special cases for newline and tab
selectors so that the event is passed along. These selectors are special because
they are ones that turn into text input events.
(-[WebHTMLView _discardMarkedText]): Moved the body of this function into the
Editor class in WebCore and just call that from here.
(-[WebHTMLView insertText:]): Added code to send a text input event instead of
calling the editor to do text insertion. The insertion is then done in the
default handler for the text input event.
(-[WebHTMLView _insertNewlineWithEvent:isLineBreak:]): Added. Sends a text
input event.
(-[WebHTMLView _insertTabWithEvent:isBackTab:]): Ditto.
(-[WebHTMLView _updateSelectionForInputManager]): Changed to use the
ignoreMarkedTextSelectionChange flag in Editor now that the one here is gone.
* WebView/WebHTMLViewInternal.h: Remove ignoreMarkedTextSelectionChange field.
* WebView/WebView.mm: (-[WebView setSelectedDOMRange:affinity:]): Changed to
use the normal selection controller function instead of selectRange.
2007-02-11 Sam Weinig <sam@webkit.org>
Reviewed by Mark.
Switch the initial value of box-sizing property from "border-box" to "content-box".
* WebInspector/webInspector/inspector.js:
2007-02-10 Mitz Pettel <mitz@webkit.org>
Reviewed by Maciej.
- fix http://bugs.webkit.org/show_bug.cgi?id=11847
REGRESSION (SearchField): Dragging to select in the Web Inspector's search fields drags the inspector window
* WebInspector/webInspector/inspector.css: Added the search field to the
undraggable dashboard-region.
2007-02-09 Kevin Decker <kdecker@apple.com>
Reviewed by Darin & Maciej.
Fixed: <rdar://problem/4930688> REGRESSION: missing images when reloading webarchives (11962)
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::canUseArchivedResource): The bug here is that because a reload sets a cache
policy of NSURLRequestReloadIgnoringCacheData (rightfully so), this method was refusing to load
subresources in WebArchives. It's OK to use archive subresources for the NSURLRequestReloadIgnoringCacheData
cache policy because we're not worried about the actual contents of a WebArchive changing on disk.
2007-02-09 Justin Garcia <justin.garcia@apple.com>
Reviewed by darin
<rdar://problem/4975120>
REGRESSION: double-cursor after switching window away/back (11770)
<http://bugs.webkit.org/show_bug.cgi?id=11328>
Gmail Editor: Caret can simultaneously appear in both the TO: and message body fields
* WebCoreSupport/WebFrameBridge.mm: Removed unused methods.
* WebView/WebHTMLView.mm: Ditto.
(-[WebHTMLView _web_firstResponderCausesFocusDisplay]): Don't
appear focused if a descendant view is firstResponder.
(-[WebHTMLView _updateActiveState]): Removed the check for a BOOL
that was always false.
* WebView/WebHTMLViewInternal.h: Removed a BOOL that's always false.
2007-02-09 Beth Dakin <bdakin@apple.com>
Reviewed by Darin.
Fix for <rdar://problem/4674537> REGRESSION: Adobe Acrobat 8 - Text
blinks when mouse is moved, and is invisible otherwise
Allow quirk if the Application was linked before 3.0 and if the
application is Adobe Acrobat.
* Misc/WebKitVersionChecks.h:
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2007-02-09 Timothy Hatcher <timothy@apple.com>
Reviewed by Brady.
* WebKit.exp: Add WebBaseNetscapePluginView to the export list.
2007-02-09 John Sullivan <sullivan@apple.com>
Reviewed by Beth
- WebKit part of fix for radar 4939636, problems with context menu items and binaries linked
against WebKit 2.0.
* WebKit.xcodeproj/project.pbxproj:
Changed DYLIB_CURRENT_VERSION to 2 (was 1)
* Misc/WebKitVersionChecks.h:
Added constant WEBKIT_FIRST_VERSION_WITH_3_0_CONTEXT_MENU_TAGS, which is 2 but in the weird
format that these version checks use.
* WebView/WebUIDelegatePrivate.h:
Tweaked comments; included the old values for three tags for context menu items that changed
from SPI to API in 3.0; renamed WEBMENUITEMTAG_SPI_START to WEBMENUITEMTAG_WEBKIT_3_0_SPI_START
for clarity, and bumped its value to avoid conflict with the three old values
* WebCoreSupport/WebContextMenuClient.mm:
(isAppleMail):
new helper function that checks the bundle identifier
(fixMenusToSendToOldClients):
Removed return value for clarity; now checks linked-on version and also makes special case
for Mail; now replaces three API tags with their old SPI values for clients that linked
against old WebKit version, in addition to replacing new API with WebMenuItemTagOther for
items that had no specific tag before.
(fixMenusReceivedFromOldClients):
Removed return value for clarity; removed defaultMenuItems parameter because it's no longer
necessary; removed code that tried to recognize menus that got confused by the SPI -> API
change (we now pass the old SPI values to these clients to avoid confusing them); now
restores the tags for the items whose tags were replaced in fixMenusToSendToOldClients
(this used to restore the tags of the default items rather than the new items, which was
incorrect but happened to work since the clients we tested were using the objects from the
default items array in their new items array)
(WebContextMenuClient::getCustomMenuFromDefaultItems):
Updated to account for the removed return values for the two fix-up methods; moved the
autorelease of newItems here, which is clearer and was the source of a leak before.
2007-02-08 Kevin McCullough <KMcCullough@apple.com>
Reviewed by
- fixing a build breakage.
* Misc/WebNSAttributedStringExtras.mm:
(fileWrapperForElement):
2007-02-07 Charles Ying <charles_ying@yahoo.com>
Reviewed by Adam.
Code suggestion by aroben
Fix http://bugs.webkit.org/show_bug.cgi?id=12688
REGRESSION (r19469): ASSERT when right clicking on hyperlinks! in TOT webkit
* WebCoreSupport/WebContextMenuClient.mm:
(fixMenusReceivedFromOldClients):
- fixMenusReceivedFromOldClients was hitting an ASSERT incorrectly
because it could not match [item title] to any of the contentMenuItemTags
using pointer comparison ==. Instead, it needs to do a string comparison
between [item title] and the various contentMenuItemTags using
isEqualToString instead of ==. You would encounter this whenever the
context menu was activated, e.g., from a hyperlink right click (or
control click).
2007-02-07 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
Move shouldInterruptJavaScript to the Chrome.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::shouldInterruptJavaScript):
* WebCoreSupport/WebFrameBridge.mm:
2007-02-07 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
- fixed all places in WebKit where _web_userVisibleString was used where
_web_originalDataAsString should have been used instead.
* History/WebURLsWithTitles.m:
(+[WebURLsWithTitles writeURLs:andTitles:toPasteboard:]):
use _web_originalDataAsString when writing since these aren't displayed to the user
(+[WebURLsWithTitles URLsFromPasteboard:]):
use _web_URLWithDataAsString when reading, to match what we used when writing
* Misc/WebNSPasteboardExtras.mm:
(-[NSPasteboard _web_writeURL:andTitle:types:]):
use _web_originalDataAsString when writing the NSURL type; continue using
_web_userVisibleString when writing the plain text type
* WebView/WebHTMLView.mm:
(-[WebHTMLView _documentFragmentWithPaths:]):
added comment about why _web_userVisibleString is appropriate here
(-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:chosePlainText:]):
use _web_originalDataAsString when setting the href attribute of an anchor tag
2007-02-07 David Harrison <harrison@apple.com>
Reviewed by Adam.
<rdar://problem/4943650> REGRESSION: insertion point blink redraws entire web page, making everything slow
Problem is that AppKit recently changed NSControl to trigger a full redraw if the control has a focus ring.
WebHTMLView is a subclass of NSControl, but the focus ring type was the default value, though we actually
draw no focus ring. Fix is to formally set our focus ring type.
* WebView/WebHTMLView.mm:
(-[WebHTMLView initWithFrame:]):
Send [self setFocusRingType:NSFocusRingTypeNone].
2007-02-07 John Sullivan <sullivan@apple.com>
Undid changes that I hadn't intended to check in
* WebView/WebHTMLView.mm:
(-[WebHTMLView _documentFragmentWithPaths:]):
(-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:chosePlainText:]):
2007-02-07 John Sullivan <sullivan@apple.com>
Reviewed by Ollie and Geoff
- fixed <rdar://problem/4982345> KURL::createCFURL leak inside -[WebFrameBridge startDraggingImage...]
reported by buildbot
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
don't retain the imageURL we pass to the drag controller -- it's just automagically
converted to a KURL anyway
2007-02-07 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- fixed <rdar://problem/4974420> REGRESSION: Dragging a saved image into the browser window
displays a error (No File exists at the address "null") (12662)
* WebCoreSupport/WebPasteboardHelper.mm:
(WebPasteboardHelper::urlFromPasteboard):
use _web_originalDataAsString instead of _web_userVisibleString, since _web_userVisibleString
can return a string with non-ASCII characters -- suitable for display but not for code
2007-02-07 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- added some clarity to some menu-handling shenanigans
* WebCoreSupport/WebContextMenuClient.mm:
(fixMenusToSendToOldClients):
renamed from fixMenusForOldClients; added comments, FIXME, and assertion
(fixMenusReceivedFromOldClients):
renamed from fixMenusFromOldClients; added comments, FIXME, and assertion
(WebContextMenuClient::getCustomMenuFromDefaultItems):
updated for name changes
2007-02-06 Kevin Decker <kdecker@apple.com>
Fixed: <rdar://problem/4976681> ASSERTION failure on quit @ talkcrunch.com in _NPN_ReleaseObject
Reviewed by Anders.
* Plugins/WebPluginDatabase.m:
(+[WebPluginDatabase sharedDatabase]): Removed NSApplicationWillTerminateNotification observer and thus
also removed code that would unload the entire plug-in database when receiving that notification.
The bug here was that this notification callback would happen first before anything else thus unloading
plug-ins and releasing plug-in memory. That was crash prone because the JavaScriptCore collector would at
a later time attempt to release its CInstance references (references that point to plug-in memory)
without knowing WebKit already unloaded the plug-in out from underneath it. The WebPluginDatabase simply
does not have enough context to make this decision.
* WebView/WebView.mm: Added two statics: applicationIsTerminating, pluginDatabaseClientCount.
(+[WebView initialize]): Added NSApplicationWillTerminateNotification observer.
(+[WebView _applicationWillTerminate]): Added.
(-[WebView _close]): WebKit has both a global plug-in database and a separate, per WebView plug-in database.
We need to release both sets of plug-ins because Netscape plug-ins have "destructor functions" that should be
called when the browser unloads the plug-in. These functions can do important things, such as closing/deleting
files so it is important to ensure that they are properly called when the application terminates.
The new change is that on app shutdown, we unload WebKit's global plug-in database if and only if the last WebView
was closed. To do so otherwise would unload plug-ins out from underneath other WebViews.
2007-02-06 Darin Adler <darin@apple.com>
Reviewed by John Sullivan.
- fix http://bugs.webkit.org/show_bug.cgi?id=11080
<rdar://problem/4826648> REGRESSION: Incorrect vertical positioning of Safari
status bar text containing @ character (11080)
* Misc/WebKitNSStringExtras.m:
(canUseFastRenderer): Fix code that mistakenly used the slow renderer for strings
that have a direction of "other neutral", which includes the "@" character.
(-[NSString _web_drawAtPoint:font:textColor:]): Add code to make the baseline of
the text in the status bar right. AppKit's rule for rounding is complicated enough
that this is obviously not perfectly correct, but it does make both code paths
use the same baseline in all the places this is currently used in AppKit.
2007-02-06 Darin Adler <darin@apple.com>
Spotted by Steve F.
* Misc/WebNSURLExtras.m:
(-[NSString _web_mapHostNameWithRange:encode:makeString:]):
Fix obvious logic mistake I introduced back in revision 8255.
I can't see how to exercise this code path, but I also can't
bear to leave this obviously-broken code as-is.
2007-02-05 David Kilzer <ddkilzer@webkit.org>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=7266
Webarchive format saves duplicate WebSubresources to .webarchive file
Tests: webarchive/test-duplicate-resources.html
webarchive/test-frameset.html
* WebView/WebArchiver.mm:
(+[WebArchiver _archiveWithMarkupString:fromFrame:nodes:]): Use an NSMutableSet to prevent
duplicate subresources from being added to the webarchive.
2007-02-06 Mark Rowe <mrowe@apple.com>
Roll out incomplete support for font-stretch (r19350) at Dave Hyatt's request.
See http://bugs.webkit.org/show_bug.cgi?id=12530#c9 for more info.
* WebInspector/webInspector/inspector.js:
* WebView/WebHTMLView.mm:
(-[WebHTMLView _addToStyle:fontA:fontB:]):
2007-02-05 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
Fix for <rdar://problem/4975161> REGRESSION: With BumperCar 2.1.1,
the contextual menu fails to appear when I ctrl-click on page
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::getCustomMenuFromDefaultItems): If the
delegate does not respond to contextMenuItemsForElement, return the
default menu instead of nil.
2007-02-01 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej Stachowiak.
Added support for selectively ignoring WebCore::Node leaks during layout
tests, so that we can ignore known leaks in other components.
* Misc/WebCoreStatistics.h:
* Misc/WebCoreStatistics.mm:
(+[WebCoreStatistics startIgnoringWebCoreNodeLeaks]):
(+[WebCoreStatistics stopIgnoringWebCoreNodeLeaks]):
2007-02-01 Nicholas Shanks <webkit@nickshanks.com>
Reviewed by Mark.
Add support for CSS2 font-stretch property.
* WebInspector/webInspector/inspector.js:
* WebView/WebHTMLView.mm:
(-[WebHTMLView _addToStyle:fontA:fontB:]):
2007-02-01 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adam.
<rdar://problem/4730469> REGRESSION: Assertion failure in -[WebDataSource(WebInternal) _bridge] when forwarding message
* WebView/WebDataSource.mm:
(-[WebDataSource subresources]): Check for being uncommitted and return emtpy result.
(-[WebDataSource subresourceForURL:]): ditto
2007-01-31 Oliver Hunt <oliver@apple.com>
Reviewed by Adam.
Migrating methods to WebCore
* WebCoreSupport/WebFrameBridge.mm:
* WebView/WebHTMLView.mm:
* WebView/WebHTMLViewPrivate.h:
2007-01-31 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
<rdar://problem/4886776>
REGRESSION: After opening a web archive, location shows the actual URL, not the webarchive file
"Revert" the change done in 13734.
* WebView/WebHTMLRepresentation.mm:
(-[WebHTMLRepresentation loadArchive]):
Don't do a new load here, as this would cancel the current load and call the resource load
delegate's didFailLoadingWithError: method. Instead, call continueLoadWithData.
2007-02-01 Nikolas Zimmermann <zimmermann@kde.org>
Reviewed by Maciej.
Fix run-pageloadtest to actually work again.
* Misc/WebNSWindowExtras.m:
(+[NSWindow _webkit_displayThrottledWindows]):
2007-01-31 Adele Peterson <adele@apple.com>
Reviewed by Darin.
WebKit part of fix for <rdar://problem/4521461> REGRESSION: when keyPress event changes form focus, inserted key goes to wrong control
* WebCoreSupport/WebEditorClient.mm: (WebEditorClient::handleKeyPress): Instead of using the selected frame, use the
frame for the target of the keyboard event. Also, don't do the canEdit check here, since the target's frame might not
have a selection at this point. Do the canEdit check within Editor::insertText, where we determine which selection to use
for inserting text.
* WebView/WebEditingDelegatePrivate.h: Added forward declaration of DOMHTMLElement. This is needed after reordering includes in WebEditorClient.mm.
2007-01-31 Alice Liu <alice.liu@apple.com>
Reviewed by Tim Hatcher.
Turning an accidental API change to an SPI change
* WebView/WebEditingDelegate.h:
* WebView/WebEditingDelegatePrivate.h:
move some declarations into private header.
2007-01-31 Darin Adler <darin@apple.com>
- fix build
* ForwardingHeaders/wtf/ListHashSet.h: Added.
2007-01-31 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- related fix for <rdar://problem/4964407> REGRESSION: Mail hangs when replying, forwarding , or creating a new message
* WebView/WebFrame.mm:
(-[WebFrame loadArchive:]): This method also needs to add the lame WebDataRequest property or other things, like
Mail Contents of Page, break.
2007-01-31 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
- add back no-op version of silly method so that shipping Safari can still run the PLT
* Misc/WebNSWindowExtras.m:
(-[NSWindow _webkit_displayThrottledWindows]):
2007-01-31 Mark Rowe <mrowe@apple.com>
More build fixing.
* Misc/WebKitLogging.h: Use !defined() rather than !.
* Plugins/WebNetscapePluginStream.h: Remove #if __cplusplus as this file is only included from Obj-C++ files.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]): Use #ifdef rather than #if.
* WebView/WebView.mm:
(-[WebView isGrammarCheckingEnabled]): Ditto.
2007-01-31 Mark Rowe <mrowe@apple.com>
Build fix.
* WebView/WebView.mm:
(-[WebView initWithFrame:frameName:groupName:]):
2007-01-31 Mark Rowe <mrowe@apple.com>
Reviewed by Oliver.
Enable -Wundef in WebKit, and change misuses of #if to #ifdef or #ifndef as appropriate.
* Misc/WebKitLogging.h:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrame.mm:
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.mm:
(-[WebHTMLView validateUserInterfaceItem:]):
(-[WebHTMLView delete:]):
(-[WebHTMLView showGuessPanel:]):
(-[WebHTMLView copy:]):
(-[WebHTMLView cut:]):
(-[WebHTMLView paste:]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebView.mm:
(-[WebViewPrivate init]):
(-[WebView validateUserInterfaceItem:]):
* WebView/WebViewPrivate.h:
2007-01-30 Brady Eidson <beidson@apple.com>
Reviewed by Oliver
This is a corollary to <rdar://problem/4944887> where certain things happened on an alternate thread.
To help catch such behavior in the future, add ASSERT_MAIN_THREAD() to key WebKit API points
* History/WebHistoryItem.mm: Added ASSERT_MAIN_THREAD() to suspected API entry points
(-[WebHistoryItem dealloc]):
(-[WebHistoryItem finalize]):
(-[WebHistoryItem copyWithZone:]):
(-[WebHistoryItem URLString]):
(-[WebHistoryItem originalURLString]):
(-[WebHistoryItem title]):
(-[WebHistoryItem lastVisitedTimeInterval]):
(-[WebHistoryItem isEqual:]):
(-[WebHistoryItem description]):
(-[WebHistoryItem initWithWebCoreHistoryItem:]):
(-[WebHistoryItem initFromDictionaryRepresentation:]):
(-[WebHistoryItem scrollPoint]):
(-[WebHistoryItem dictionaryRepresentation]):
(-[WebHistoryItem target]):
(-[WebHistoryItem visitCount]):
(-[WebHistoryItem children]):
(-[WebHistoryItem URL]):
(-[WebHistoryItem _lastVisitedDate]):
(-[WebHistoryItem targetItem]):
* Misc/WebIconDatabase.mm: Added ASSERT_MAIN_THREAD() to suspected API entry points
(-[WebIconDatabase iconForURL:withSize:cache:]):
(-[WebIconDatabase iconURLForURL:]):
(-[WebIconDatabase defaultIconWithSize:]):
(-[WebIconDatabase retainIconForURL:]):
(-[WebIconDatabase releaseIconForURL:]):
(-[WebIconDatabase removeAllIcons]):
(-[WebIconDatabase _iconForFileURL:withSize:]):
(webGetNSImage):
* Misc/WebKitLogging.h: Added ASSERT_MAIN_THREAD()
* Misc/WebKitLogging.m:
(WebKitRunningOnMainThread): Added
* WebKit.xcodeproj/project.pbxproj: Define DISABLE_THREAD_CHECK until it is
safe to run with ASSERT_MAIN_THREAD() active
2007-01-30 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4961953> Stop using NSString deprecated methods like initWithCString:
* Misc/WebNSImageExtras.m:
(-[NSImage _web_saveAndOpen]):
* WebKit.xcodeproj/project.pbxproj:
2007-01-30 Mitz Pettel <mitz@webkit.org>
Reviewed by Geoff.
- fix http://bugs.webkit.org/show_bug.cgi?id=12050
REGRESSION: Assertion failure in -[WebBaseNetscapePluginView willCallPlugInFunction] (plugin)
Test: plugins/createScriptableObject-before-start.html
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView createPluginScriptableObject]): Return NULL if
the plugin is not started.
2007-01-30 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
<rdar://problem/4964407> REGRESSION: Mail hangs when replying, forwarding , or creating a new message
* WebView/WebFrame.mm:
(-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]): Set WebDataRequest property on data
load requests since Mail specifically checks for this.
2007-01-30 Graham Dennis <graham.dennis@gmail.com>
Reviewed by Maciej.
Part of fix for http://bugs.webkit.org/show_bug.cgi?id=10725
Image data in from RTFD clipboard data thrown away
The URLs for images in RTFD data must not be loaded until the resources
have been added to the WebUnarchivingState. This can't happen until
after the RTFD data has been parsed, so we must delay loading while this
RTFD data is being parsed to a document fragment.
* WebView/WebHTMLView.mm:
(uniqueURLWithRelativePart):
(-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:chosePlainText:]): defer loading the resources while RTFD data is being parsed.
(+[NSURL _web_uniqueWebDataURL]): Added this back because AppKit uses it.
* WebView/WebUnarchivingState.m:
(-[WebUnarchivingState archivedResourceForURL:]): orkaround for workaround for rdar://problem/4699166 so that other people can use archivedResourceForURL: too.
2007-01-29 Jim Correia <jim.correia@pobox.com>
Reviewed by Mark.
Added support for -allowsUndo/-setAllowsUndo: to allow editable WebView
clients to completely disable undo registration. This is functionally
equivalent to the methods with the same names on NSTextView.
* WebView/WebView.mm:
(-[WebViewPrivate init]):
(-[WebView initWithCoder:]):
(-[WebView encodeWithCoder:]):
(-[WebView allowsUndo]):
(-[WebView setAllowsUndo:]):
(-[WebView undoManager]):
* WebView/WebViewPrivate.h:
2007-01-29 Ada Chan <adachan@apple.com>
Reviewed by Brady.
Moved the update of the title of the current entry in the backforward list to WebCore.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::setTitle):
2007-01-29 Adele Peterson <adele@apple.com>
Reviewed by Darin.
More preparation for event handling fixes.
* WebCoreSupport/WebEditorClient.h: Removed EventTargetNode parameter, since you can
just get this from the KeyboardEvent.
* WebCoreSupport/WebEditorClient.mm: (WebEditorClient::handleKeyPress): ditto.
* WebView/WebHTMLViewInternal.h: Added interpretKeyEventsParameters struct.
* WebView/WebViewInternal.h: Changed parameter from NSEvent to WebCoreKeyboardEvent in _interceptEditingKeyEvent.
* WebView/WebHTMLView.mm:
(-[WebHTMLView yankAndSelect:]): Updated for new triggeringEvent parameter.
(-[WebHTMLView _interceptEditingKeyEvent:]): Set the WebHTMLViewInterpretKeyEventsParameters.
(-[WebHTMLView doCommandBySelector:]): Access WebHTMLViewInterpretKeyEventsParameters.
(-[WebHTMLView insertText:]): ditto.
(-[WebHTMLView _insertText:selectInsertedText:triggeringEvent:]): Added parameter for triggeringEvent.
2007-01-29 Oliver Hunt <oliver@apple.com>
build fix
* WebView/WebHTMLView.mm:
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
2007-01-25 Oliver Hunt <oliver@apple.com>
Reviewed by Adam.
Migrated drag state and logic to WebCore, removed superfluous methods
* ChangeLog:
* WebCoreSupport/WebDragClient.h:
* WebCoreSupport/WebDragClient.mm:
(WebDragClient::dragSourceActionMaskForPoint):
* WebCoreSupport/WebFrameBridge.mm:
allowDHTMLDrag move to WebCore::EventHandler
* WebView/WebHTMLView.mm:
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
(-[WebHTMLView draggedImage:movedTo:]):
(-[WebHTMLView draggedImage:endedAt:operation:]):
dragOffset and dragSourecAction is now stored in WebCore::DragController
migrated _delegateDragSourceActionMask to WebCore::DragController
* WebView/WebHTMLViewInternal.h:
Removed dragOffset declaration, migrated to WebCore::DragController
* WebView/WebView.mm:
removed unnecessary method, _loadingDragOperationForDraggingInfo
2007-01-29 Maciej Stachowiak <mjs@apple.com>
Reviewed by Mark.
- updated for cross-platform data loading support
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createDocumentLoader):
* WebView/WebDataSource.mm:
(-[WebDataSource initWithRequest:]):
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::WebDocumentLoaderMac):
* WebView/WebFrame.mm:
(-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]):
(-[WebFrame loadData:MIMEType:textEncodingName:baseURL:]):
(-[WebFrame _loadHTMLString:baseURL:unreachableURL:]):
(-[WebFrame loadArchive:]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.mm:
(uniqueURLWithRelativePart):
(-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:chosePlainText:]):
2007-01-27 David Kilzer <ddkilzer@webkit.org>
Reviewed by Adam.
- fix http://bugs.webkit.org/show_bug.cgi?id=12260
Windows platform build is not maintained
* COM/ChromeClientWin.cpp:
(ChromeClientWin::canTakeFocus):
(ChromeClientWin::takeFocus):
* COM/ChromeClientWin.h:
* COM/ContextMenuClientWin.cpp:
(ContextMenuClientWin::getCustomMenuFromDefaultItems):
(ContextMenuClientWin::searchWithGoogle):
* COM/ContextMenuClientWin.h:
* COM/WebFrameLoaderClient.cpp:
(WebFrameLoaderClient::assignIdentifierToInitialRequest):
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
(WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
(WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebFrameLoaderClient::dispatchDidFailLoad):
(WebFrameLoaderClient::dispatchCreatePage):
(WebFrameLoaderClient::dispatchDecidePolicyForMIMEType):
(WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
(WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
(WebFrameLoaderClient::dispatchUnableToImplementPolicy):
(WebFrameLoaderClient::setMainDocumentError):
(WebFrameLoaderClient::incrementProgress):
(WebFrameLoaderClient::completeProgress):
(WebFrameLoaderClient::startDownload):
(WebFrameLoaderClient::committedLoad):
(WebFrameLoaderClient::cancelledError):
(WebFrameLoaderClient::cannotShowURLError):
(WebFrameLoaderClient::interruptForPolicyChangeError):
(WebFrameLoaderClient::cannotShowMIMETypeError):
(WebFrameLoaderClient::fileDoesNotExistError):
(WebFrameLoaderClient::shouldFallBack):
(WebFrameLoaderClient::willUseArchive):
(WebFrameLoaderClient::createDocumentLoader):
(WebFrameLoaderClient::download):
* COM/WebFrameLoaderClient.h:
2007-01-27 David Harrison <harrison@apple.com>
Reviewed by Kevin.
<rdar://problem/4958902> REGRESSION: Dashboard widgets fail to load
This was caused by the WebView preferences rework in r18417. Specifically, in
_updateWebCoreSettingsFromPreferences when calling setUserStyleSheetLocation,
[NSURL URLWithString:] is now messaged directly with the result of
[[preferences userStyleSheetLocation] _web_originalDataAsString]], which will
be nil if the userStyleSheetLocation has not been set yet. [NSURL URLWithString:]
throws an exception when the string is nil. DashboardClient.app calls
setUserStyleSheetEnabled *before* calling setUserStyleSheetLocation.
* WebView/WebView.mm:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
Pass empty string instead of nil string to [NSURL URLWithString:].
2007-01-26 Darin Adler <darin@apple.com>
Reviewed by Timothy.
Fixes crash drawing avatar on mail.yahoo.com.
* Plugins/WebBaseNetscapePluginStream.m: Retain the object since destroyStreamWithError: might
release the last reference to it.
2007-01-26 Darin Adler <darin@apple.com>
Reviewed by Beth.
* WebInspector/webInspector/inspector.js: Updated for new computed style properties.
2007-01-26 Kevin Decker <kdecker@apple.com>
Reviewed by andersca.
Fixed: <rdar://problem/4946922> WebBaseNetscapePluginView leaks memory
http://bugs.webkit.org/show_bug.cgi?id=11523
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream setPlugin:]): Calls -[WebBaseNetscapePluginView disconnectStream:]
* Plugins/WebBaseNetscapePluginView.h: Added disconnectStream: to header.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView stop]): Make a copy of the streams collection prior to calling stop all streams.
This is necessary because calling stop has the side effect of removing the stream from this same collection.
(-[WebBaseNetscapePluginView disconnectStream:]): Added. Removes the stream from the streams collection.
2007-01-25 Kevin Decker <kdecker@apple.com>
Backed out my last patch because it crashes espn.com. Stay tuned for a newer version..
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream setPlugin:]): Removed call to streamIsDead.
* Plugins/WebBaseNetscapePluginView.h: Removed streamIsDead.
* Plugins/WebBaseNetscapePluginView.mm: Ditto.
2007-01-25 Darin Adler <darin@apple.com>
Reviewed by Beth.
- fix <rdar://problem/4952766> Safari has a top secret color picker that can be used to... uhh... I don't know
* Panels/English.lproj/WebAuthenticationPanel.nib/info.nib: Let Interface Builder have its way.
* Panels/English.lproj/WebAuthenticationPanel.nib/objects.nib: Remove the NSColorWell that was
in here (for no good reason).
2007-01-25 Kevin Decker <kdecker@apple.com>
Reviewed by andersca.
A few tweaks with of a fix done by Steve Gehrman.
Fixed: <rdar://problem/4946922> WebBaseNetscapePluginView leaks memory
http://bugs.webkit.org/show_bug.cgi?id=11523
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream setPlugin:]): Calls -[WebBaseNetscapePluginView streamIsDead:]
* Plugins/WebBaseNetscapePluginView.h: Added streamIsDead to header.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView streamIsDead:]): Added. Removes the stream from the streams collection.
2007-01-25 John Sullivan <sullivan@apple.com>
Reviewed by Kevin, Geoff, Brady, and Darin
- fixed <rdar://problem/4918446> Safari's temp files (PDF's) should be in a sub-folder when calling Preview
* WebView/WebPDFView.mm:
(-[WebPDFView _path]):
use _temporaryPDFDirectoryPath method instead of #defines for hardwiring strings; stop bad practice
of modifying the const char* returned by fileSystemRepresentation
(-[WebPDFView _temporaryPDFDirectoryPath]):
new method, lazily creates and returns a secure temporary directory created with NSTemporaryDirectory()
and mkdtemp
* English.lproj/StringsNotToBeLocalized.txt:
Updated for these and other recent changes
2007-01-24 Oliver Hunt <oliver@apple.com>
Build fix
* WebView/WebHTMLView.mm:
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
(-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
2007-01-24 Oliver Hunt <ioliver@apple.com>
Reviewed by Maciej.
Migrating more drag state information to WebCore
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.mm:
(-[WebHTMLViewPrivate dealloc]):
(-[WebHTMLViewPrivate clear]):
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
(-[WebHTMLView _mayStartDragAtEventLocation:]):
(-[WebHTMLView close]):
(-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
(-[WebHTMLView _delegateDragSourceActionMask]):
* WebView/WebHTMLViewInternal.h:
2007-01-24 Adele Peterson <adele@apple.com>
Reviewed by Darin.
Small improvement to my last checkin to prevent the keyEventWasInterpreted bool from
being overwritten by reentrancy.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _interceptEditingKeyEvent:]): Point keyEventWasInterpreted pointer to local variable.
(-[WebHTMLView doCommandBySelector:]):
(-[WebHTMLView insertText:]):
* WebView/WebHTMLViewInternal.h: Added BOOL pointer that will point to the local variable on the stack in _interceptEditingKeyEvent
2007-01-24 Adele Peterson <adele@apple.com>
Reviewed by Darin.
- Fix for <rdar://problem/4950527> REGRESSION: Can't use arrow keys (left/right) to navigate caret in input (type=text) or textarea fields
Keep track of whether interpretKeyEvents handles the key event based on whether or not we get
called in insertText or doCommandBySelector.
Test: fast/events/arrow-navigation.html
* WebView/WebHTMLView.mm:
(-[WebHTMLView performKeyEquivalent:]):
(-[WebHTMLView _interceptEditingKeyEvent:]):
(-[WebHTMLView doCommandBySelector:]):
(-[WebHTMLView insertText:]):
* WebView/WebHTMLViewInternal.h:
2007-01-25 Mark Rowe <mrowe@apple.com>
Reviewed by Maciej.
* Info.plist: Update copyright string.
2007-01-24 Darin Adler <darin@apple.com>
Reviewed by Mark Rowe.
* WebKit.xcodeproj/project.pbxproj: Changed to /usr/sbin/sysctl
so we don't rely on people's paths.
2007-01-24 Darin Adler <darin@apple.com>
Reviewed by Adele.
- fix small regression and GC problems noticed by code inspection
* WebView/WebHTMLView.mm: Move global declarations to the start of the file.
(+[WebHTMLView _excludedElementsForAttributedStringConversion]):
Add a CFRetain here for GC compatibility.
(+[WebHTMLView _insertablePasteboardTypes]): Ditto.
(-[WebHTMLView performKeyEquivalent:]): Fix small logic mistake that prevents
super from being called if EventHandler::keyEvent returns false. Reformatted
the code a bit and added a local variable for the frame.
(-[WebHTMLView _interceptEditingKeyEvent:]): Added some comments.
(-[WebHTMLView validAttributesForMarkedText]): Add a CFRetain here for
GC compatibility.
2007-01-23 Adele Peterson <adele@apple.com>
Reviewed by Adam.
Fixed 2 layout tests that I broke with my last checkin.
* WebCoreSupport/WebEditorClient.mm: (WebEditorClient::handleKeyPress): Use the selected frame to get the WebHTMLView.
* WebView/WebHTMLView.mm:
(-[WebHTMLView performKeyEquivalent:]): Added global to keep track of NSEvent used here.
(-[WebHTMLView _interceptEditingKeyEvent:]): Check NSEvent against the event used in performKeyEquivalent.
We don't want to intercept these events.
2007-01-23 Adele Peterson <adele@apple.com>
Reviewed by Darin.
WebKit part of fix for <rdar://problem/4946753>REGRESSION: Inserting tabs is broken in Mail
In addition to this fix, I also reorganized some event handling code for keyPress events to
prepare for another fix.
* WebCoreSupport/WebEditorClient.h: Added handleKeyPress method.
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::handleKeyPress): Added. Code moved from WebHTMLView keyDown method.
This is called from the defaultEventHandler so that in the future, we can make the right
decision about which selection the keyPress should apply to.
* WebView/WebHTMLView.mm:
(-[WebHTMLView keyDown:]): Moved _interceptEditingKeyEvent call to handleKeyPress.
(-[WebHTMLView _interceptEditingKeyEvent:]): Prevents intercepting keys for cmd-modified events. Removed tabCycling checks
since this is now handled in WebCore.
* WebView/WebHTMLViewInternal.h: Made _interceptEditingKeyEvent SPI.
* WebView/WebView.mm: Use new tabKeyCyclesThroughElements methods on the page.
(-[WebViewPrivate init]): ditto.
(-[WebView setTabKeyCyclesThroughElements:]): ditto.
(-[WebView tabKeyCyclesThroughElements]): ditto.
(-[WebView setEditable:]): ditto
2007-01-23 Lars Knoll <lars@trolltech.com>
Reviewed by Maciej
Make the last remaining pieces of the FrameLoader platform
independent. Move most of the code over to WebFrameLoaderClient.
Some smaller cleanups in the WebFrameBridge, and moved some
platform independent functionality over to the shared code
in WebCore.
* Webcoresupport/WebFrameBridge.mm:
(-[WebFrameBridge finishInitializingWithPage:frameName:frameView:ownerElement:]):
(-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::setTitle):
(WebFrameLoaderClient::createFrame):
(WebFrameLoaderClient::objectContentType):
(nsArray):
(WebFrameLoaderClient::createPlugin):
(WebFrameLoaderClient::redirectDataToPlugin):
(nsMutableArray):
(WebFrameLoaderClient::createJavaAppletWidget):
(WebFrameLoaderClient::overrideMediaType):
(WebFrameLoaderClient::windowObjectCleared):
2007-01-23 Oliver Hunt <oliver@apple.com>
Reviewed by Adam.
Drop logic bindings for WebKit
* WebCoreSupport/WebDragClient.h: Added.
* WebCoreSupport/WebDragClient.mm: Added.
(WebDragClient::WebDragClient):
(WebDragClient::actionMaskForDrag):
(WebDragClient::willPerformDragDestinationAction):
Standard client impl
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
Updated to use DragController to track drag state
* WebCoreSupport/WebPasteboardHelper.h: Added.
(WebPasteboardHelper::WebPasteboardHelper):
A *temporary* Helper class to access NSPasteboard access and
manipulation functions present in WebKit
* WebCoreSupport/WebPasteboardHelper.mm: Added.
(WebPasteboardHelper::urlFromPasteboard):
(WebPasteboardHelper::plainTextFromPasteboard):
(WebPasteboardHelper::fragmentFromPasteboard):
(WebPasteboardHelper::insertablePasteboardTypes):
See header comment
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDocumentInternal.h:
Remove unnecessary protocol
* WebView/WebFrameView.mm:
(-[WebFrameView _setDocumentView:]):
Updating to use DragController to track drag state
* WebView/WebHTMLView.mm:
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
ditto
(-[WebHTMLView dragImage:at:offset:event:pasteboard:source:slideBack:]):
ditto
(-[WebHTMLView draggingSourceOperationMaskForLocal:]):
ditto
(-[WebHTMLView draggedImage:endedAt:operation:]):
ditto
(-[WebHTMLView _documentFragmentForPasteboard:]):
Helper method to generate DocumentFragment from NSPasteboard without regressing
(-[WebHTMLView _canProcessDragWithDraggingInfo:]):
Updating to use DragController to track drag state
(-[WebHTMLView _isMoveDrag:]):
(-[WebHTMLView _isNSColorDrag:]):
* WebView/WebHTMLViewInternal.h:
Removing unnecessary fields and methods
* WebView/WebView.mm:
(-[WebViewPrivate dealloc]):
Remove obsolete ASSERT
(-[WebView _setInitiatedDrag:]):
Now passes directly through to DragController
(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView _loadingDragOperationForDraggingInfo:]):
Removed
(-[WebView draggingEntered:]):
Updated to use DragController
(-[WebView draggingUpdated:]):
ditto
(-[WebView draggingExited:]):
ditto
(-[WebView performDragOperation:]):
ditto
(-[WebView _hitTest:dragTypes:]):
* WebView/WebViewInternal.h:
remove unnecessary method def
2007-01-22 John Sullivan <sullivan@apple.com>
* WebView/WebHTMLView.mm:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]):
Tiger build fix: remove unused variable for return value of dictionaryServiceWindowShow
2007-01-22 John Sullivan <sullivan@apple.com>
Reviewed by Adam and Darin
- fixed <rdar://problem/4794320> "Look Up in Dictionary" does nothing in WebKit
(need to adopt new API)
* Misc/WebNSURLExtras.m:
(-[NSString _web_isUserVisibleURL]):
random typo correction in comment
* English.lproj/StringsNotToBeLocalized.txt:
updated for these changes
* WebView/WebHTMLView.mm:
(coreGraphicsScreenPointForAppKitScreenPoint):
new function to convert an AppKit screen point to a CG screen point
(-[WebHTMLView _lookUpInDictionaryFromMenu:]):
on Leopard now uses new API. There's something of an impedance mismatch between
this API and WebKit, but that was true for the SPI we were using in Tiger also.
Bug 4945808 covers the ways in which this is not perfect.
2007-01-21 Darin Adler <darin@apple.com>
Reviewed by Tim H.
* WebInspector/webInspector/inspector.css: Use row-resize for the splitter cursor
instead of move. It's a horizontal splitter resizer.
2007-01-19 Adam Roben <aroben@apple.com>
Reviewed by Beth.
Fix <rdar://problem/4942294> REGRESSION: "Spelling and Grammar",
"Font", "Speech", and "Writing Direction" are missing from contextual
menu
* WebCoreSupport/WebContextMenuClient.mm:
(fixMenusForOldClients): Change our new SPI tags to
WebMenuItemTagOther because old clients aren't expecting the new tags.
(fixMenusFromOldClients): Use each menu item's title to figure out its
correct tag again.
(WebContextMenuClient::getCustomMenuFromDefaultItems): Call
fixMenusForOldClients before calling up to the delegate.
* WebView/WebUIDelegatePrivate.h: Define WEBMENUITEMTAG_SPI_START so
that we can use it in WebContextMenuClient.
2007-01-19 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- WebKit part of fix for: <rdar://problem/4451715> REGRESSION: On some sites, have to
type a character before username/password autofill kicks in
Added new webView:didFinishDocumentLoadForFrame: SPI and wired it up
* WebView/WebViewPrivate.h:
declare new delegate method
* WebCoreSupport/WebFrameLoaderClient.h:
declare dispatchDidFinishDocumentLoad()
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidFinishDocumentLoad):
new method, calls new delegate method
* DefaultDelegates/WebDefaultFrameLoadDelegate.m:
(-[WebDefaultFrameLoadDelegate webView:didFinishDocumentLoadForFrame:]):
empty default implementation of new delegate method
2007-01-19 Anders Carlsson <acarlsson@apple.com>
Reviewed by John Sullivan.
http://bugs.webkit.org/show_bug.cgi?id=12308
REGRESSION(r18910): Crash in WebBaseNetscapePluginStream cancelLoadAndDestroyStreamWithError
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:DOMElement:]):
Move code from initWithFrame in here.
2007-01-19 Anders Carlsson <acarlsson@apple.com>
Yet another build fix.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::setStatusbarText):
2007-01-18 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam.
Move functions from the bridge to the chrome client.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::runJavaScriptAlert):
(WebChromeClient::runJavaScriptConfirm):
(WebChromeClient::runJavaScriptPrompt):
(WebChromeClient::setStatusBarText):
* WebCoreSupport/WebFrameBridge.mm:
2007-01-18 Adam Roben <aroben@apple.com>
Reviewed by Beth.
Fix <rdar://problem/4939672> REGRESSION: With text selected that is
not a link, the "Remove Link" contextual menu item remains active
* WebView/WebHTMLView.mm:
(-[WebHTMLView menuForEvent:]): Leave autoenabling of menu items on so
that clients can implement validateMenuItem:.
2007-01-18 Brady Eidson <beidson@apple.com>
Reviewed by Adele
<rdar://problem/4917290> -
Null deref in WebFrameLoaderClient::restoreScrollPositionAndViewState()
after regaining network connection
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::restoreScrollPositionAndViewState): Bail early with a null currentItem, preventing
a crash in release builds. Leave the ASSERT to help find other cases where this might happen in debug builds.
2007-01-18 Kevin Decker <kdecker@apple.com>
Reviewed by John.
<rdar://problem/4939511> WebKit should set the CG clip path for plug-ins that draw using CoreGraphics
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView drawRect:]): Set the CG clip path to the plug-in dirty rect. This allows plug-ins to obtain their
dirty rect using functions like CGContextGetClipBoundingBox().
2007-01-17 Alice Liu <alice.liu@apple.com>
Reviewed by Harrison.
Fix for <rdar://problem/4894155> REGRESSION: Extra line break is pasted with content into message body after choosing File - Paste
Migration of some editing code from WebHTMView to WebCore::Editor
resulted in not calling pasteboardTypesForSelection, which Mail was
overriding for the special purpose of adding a type to the
pasteboard after WebKit did. This patch adds 2 separate code paths
for Tiger and Leopard. On Tiger we give in and call the WebView's
pasteboardTypesForSelection. On Leopard we call a delegate after
the pasteboard types are set.
* DefaultDelegates/WebDefaultEditingDelegate.m:
(-[WebDefaultEditingDelegate webView:didSetSelectionTypesForPasteboard:]):
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::didSetSelectionTypesForPasteboard):
(WebEditorClient::pasteboardTypesForSelection):
* WebView/WebEditingDelegate.h:
2007-01-17 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- WebKit part of fix for <rdar://problem/4462420> REGRESSION: Mail hangs during
Replace All if the replacement string contains the search string
* Misc/WebKitVersionChecks.h:
Added extern "C" so this can be used from .mm files. I don't need this change anymore for
this fix, but it's still worth fixing now so it doesn't bite anyone later.
* WebView/WebDocumentPrivate.h:
Invented new private protocol WebDocumentIncrementalSearching, that has one method. The one
method is just like the one WebDocumentSearching method, but with an additional parameter.
We hope to eliminate this dependence on protocols someday, but adding another one as SPI
seems like it won't make anything worse.
* WebView/WebHTMLView.mm:
(-[WebHTMLView searchFor:direction:caseSensitive:wrap:]):
now calls through to new method that has one additional parameter, passing NO to match old behavior
(-[WebHTMLView searchFor:direction:caseSensitive:wrap:startInSelection:]):
pass new parameter to bridge
* WebView/WebPDFView.h:
Declare conformance to WebDocumentIncrementalSearching protocol
* WebView/WebPDFView.mm:
(-[WebPDFView searchFor:direction:caseSensitive:wrap:]):
now calls through to new method that has one additional parameter, passing NO to match old behavior
(-[WebPDFView searchFor:direction:caseSensitive:wrap:startInSelection:]):
new method, former guts of searchFor:direction:caseSensitive:wrap: but now handles startInSelection
parameter
* WebView/WebViewPrivate.h:
Declare new searchFor:direction:caseSensitive:wrap:startInSelection: method, just like existing
method but with one additional parameter
* WebView/WebView.mm:
(-[WebView searchFor:direction:caseSensitive:wrap:]):
now calls through to new method that has one additional parameter, passing NO to match old behavior
(-[WebView searchFor:direction:caseSensitive:wrap:startInSelection:]):
new method, former guts of searchFor:direction:caseSensitive:wrap: but now handles startInSelection
parameter
2007-01-17 Brady Eidson <beidson@apple.com>
Reviewed by Deth Bakin and Brian Dash
Drop Panther Support (?!?) and change the comment explaining some SPI forward decls
* Misc/WebDownload.m:
2007-01-17 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- fix http://bugs.webkit.org/show_bug.cgi?id=12278
<rdar://problem/4928705> REGRESSION(r13070): Dragged image size includes padding (12278)
* Misc/WebElementDictionary.mm: (-[WebElementDictionary _imageRect]):
Call HitTestResult::imageRect, not HitTestResult::boundingBox.
2007-01-17 Anders Carlsson <acarlsson@apple.com>
Reviewed by John Sullivan.
Move all code in WebNetscapePluginEmbeddedView down to WebBaseNetscapePluginView.
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:DOMElement:]):
(-[WebBaseNetscapePluginView didStart]):
(-[WebBaseNetscapePluginView dataSource]):
(-[WebBaseNetscapePluginView dealloc]):
(-[WebBaseNetscapePluginView pluginView:receivedResponse:]):
(-[WebBaseNetscapePluginView pluginView:receivedData:]):
(-[WebBaseNetscapePluginView pluginView:receivedError:]):
(-[WebBaseNetscapePluginView pluginViewFinishedLoading:]):
(-[WebBaseNetscapePluginView _redeliverStream]):
* Plugins/WebNetscapePluginEmbeddedView.h:
* Plugins/WebNetscapePluginEmbeddedView.mm:
2007-01-17 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
<rdar://problem/4887781> Seed: Repro Safari crash in -[WebHTMLRepresentation receivedData:withDataSource:] (music.aol.com)
* WebView/WebDataSource.mm:
(-[WebDataSource _receivedData:]): Protect self against destruction partway through this method.
2007-01-16 Alice Liu <alice.liu@apple.com>
Reviewed by harrison.
Fixed <rdar://problem/4921134> WebKit needs extensible cut/copy to allow additional types to be written to pasteboard
* DefaultDelegates/WebDefaultEditingDelegate.m:
(-[WebDefaultEditingDelegate webView:didWriteSelectionToPasteboard:]):
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::didWriteSelectionToPasteboard):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebEditingDelegate.h:
2007-01-15 Justin Garcia <justin.garcia@apple.com>
Reviewed by mjs
<rdar://problem/4810960>
Gmail Editor: window.focus() called on keyDown (9640)
The window's keydown event handler was being called
instead of the editable subframe's if there was a key binding
for the key event.
* WebView/WebHTMLView.mm:
(-[WebHTMLView performKeyEquivalent:]): Don't send the event
to WebCore unless this WebHTMLView is the firstResponder.
2007-01-15 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
Update to match WebCore.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::willChangeEstimatedProgress):
(WebFrameLoaderClient::didChangeEstimatedProgress):
(WebFrameLoaderClient::postProgressStartedNotification):
(WebFrameLoaderClient::postProgressEstimateChangedNotification):
(WebFrameLoaderClient::postProgressFinishedNotification):
Post the correct notifications.
* WebView/WebView.mm:
(-[WebViewPrivate init]):
(-[WebViewPrivate dealloc]):
Get rid of all progress tracking code.
(-[WebView estimatedProgress]):
Call ProgressTracker::estimatedProgress()
2007-01-15 Adam Roben <aroben@apple.com>
Reviewed by Darin.
Fix: http://bugs.webkit.org/show_bug.cgi?id=12134
REGRESSION: Assertion failure and crash when right clicking selection
in forms
* WebCoreSupport/WebContextMenuClient.mm:
(fixMenusFromOldApps): Static helper to fix up menus from applications
compiled against Tiger WebKit.
(WebContextMenuClient::getCustomMenuFromDefaultItems): Call helper to
fix menus.
* WebView/WebUIDelegatePrivate.h: Fixed typo.
2007-01-14 David Kilzer <ddkilzer@kilzer.net>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=12251
REGRESSION (r18822-r18823): Assertion failure opening document with non-existent resources
(dom/xhtml/level2/html/HTMLIFrameElement11.xhtml)
* WebView/WebView.mm:
(-[WebView _objectForIdentifier:]): Removed assertion.
(-[WebView _removeObjectForIdentifier:]): Removed assertion.
2007-01-12 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
Add a HashMap between unsigned longs and Objective-C objects and use it for
the resource load delegate.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::assignIdentifierToInitialRequest):
(WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
(WebFrameLoaderClient::incrementProgress):
(WebFrameLoaderClient::completeProgress):
* WebView/WebView.mm:
(-[WebViewPrivate init]):
(-[WebViewPrivate dealloc]):
(-[WebView _addObject:forIdentifier:]):
(-[WebView _objectForIdentifier:]):
(-[WebView _removeObjectForIdentifier:]):
* WebView/WebViewInternal.h:
2007-01-11 Brady Eidson <beidson@apple.com>
Reviewed by Anders
Rewrites HTTP Authentication setting up a more platform-independent structure
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
* WebKit.xcodeproj/project.pbxproj:
2007-01-11 Darin Adler <darin@apple.com>
Reviewed by Mitz.
- fix http://bugs.webkit.org/show_bug.cgi?id=12180
REGRESSION: Double-clicking on JS exception in JS log crashes in -[SharedBufferData initWithSharedBuffer:]
* WebView/WebDataSource.mm: (-[WebDataSource data]): Added null check.
2007-01-11 Darin Adler <darin@apple.com>
Reviewed by Hyatt.
- moved code from a couple WebCore bridging classes here instead
* Misc/WebNSPasteboardExtras.mm:
(-[NSPasteboard _web_writeImage:element:URL:title:archive:types:]):
Use MimeTypeRegistry instead of WebMimeTypeRegistryBridge.
* WebView/WebHTMLRepresentation.mm:
(stringArray): Added. Helper to convert a HashSet to an NSArray.
(concatenateArrays): Added. Helper to concatenate two NSArray objects.
(+[WebHTMLRepresentation supportedMIMETypes]): Use MimeTypeRegistry instead of
WebMimeTypeRegistryBridge. Also fix a potential GC problem by using a RetainPtr
instead of a [retain] on a global variable.
(+[WebHTMLRepresentation supportedNonImageMIMETypes]): Ditto.
(+[WebHTMLRepresentation supportedImageMIMETypes]): Ditto.
* WebView/WebHTMLView.mm:
(-[WebHTMLView _imageExistsAtPaths:]): Use MimeTypeRegistry instead of
WebMimeTypeRegistryBridge.
(-[WebHTMLView _documentFragmentWithPaths:]): Ditto.
* WebView/WebView.mm: (+[WebView _decodeData:]): Moved code here from
the old WebCoreEncodings class.
* WebKit.xcodeproj/project.pbxproj: Let Xcode have its way with this file.
Moved WebRenderNode into the appropriate group.
2007-01-10 Mitz Pettel <mitz@webkit.org>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=11775
'Show URLs in Tool Tips' preference is ignored
* WebView/WebHTMLView.mm:
(-[WebHTMLView _resetCachedWebPreferences:]):
(-[WebHTMLView setDataSource:]): Added a call to _resetCachedWebPreferences:.
Added an assertion that the view is not closed, instead of reopening it.
Reopening should not occur, now that <http://bugs.webkit.org/show_bug.cgi?id=12087>
is fixed.
2007-01-10 Beth Dakin <bdakin@apple.com>
Reviewed by John.
Fix for <rdar://problem/4914258> REGRESSION: Search in Google now
operates on the current WebView instead of invoking Safari's
service
* WebCoreSupport/WebContextMenuClient.h:
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::searchWithGoogle): Call into WebView to
search in Google.
* WebView/WebViewInternal.h: Make _searchWithGoogleFromMenu
available.
2007-01-09 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Rename the now ObjC++ files to be .mm and remove the explicit file types.
* DOM/WebDOMOperations.m: Removed.
* DefaultDelegates/WebDefaultContextMenuDelegate.m: Removed.
* English.lproj/StringsNotToBeLocalized.txt:
* Misc/WebCoreStatistics.m: Removed.
* Misc/WebElementDictionary.m: Removed.
* Misc/WebIconDatabase.m: Removed.
* Misc/WebNSAttributedStringExtras.m: Removed.
* Misc/WebNSPasteboardExtras.m: Removed.
* Plugins/WebNetscapePluginEmbeddedView.m: Removed.
* Plugins/WebNullPluginView.m: Removed.
* Plugins/WebPluginContainerCheck.m: Removed.
* WebCoreSupport/WebViewFactory.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebArchiver.m: Removed.
* WebView/WebHTMLRepresentation.m: Removed.
* WebView/WebHTMLView.m: Removed.
* WebView/WebRenderNode.m: Removed.
* WebView/WebResource.m: Removed.
* WebView/WebScriptDebugDelegate.m: Removed.
2007-01-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- remove window display throttling code; no longer used
* Misc/WebNSWindowExtras.h:
* Misc/WebNSWindowExtras.m:
* WebView/WebFrameView.mm:
(-[WebFrameView initWithFrame:]):
* WebView/WebPreferenceKeysPrivate.h:
2007-01-08 Anders Carlsson <acarlsson@apple.com>
Reviewed by Brady.
Remove bridge functions that are implemented directly in FrameLoader now.
* WebCoreSupport/WebFrameBridge.mm:
2007-01-08 Sam Weinig <sam@webkit.org>
Reviewed by Mark.
Adds default value for outline-color and fixes default
values of the recently fixed *-color properties.
* WebInspector/webInspector/inspector.js:
2007-01-08 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
Fix for http://bugs.webkit.org/show_bug.cgi?id=12161 REGRESSION:
Crash when control-clicking on an image for contextual menu
* WebView/WebHTMLView.m:
(-[WebHTMLView menuForEvent:]): We need to nil-check coreMenu since
it will be nil if the DOM popped up a menu instead. I cleaned up
the function to make all the nil checks early returns instead of
nesting all of the content. Also moved the autorelease to be with
the creation of the menu instead of at the return.
2007-01-08 Sam Weinig <sam@webkit.org>
Reviewed by Tim H.
Adds default value for -webkit-box-shadow and fixes default
value of -webkit-column-count to be "auto". Also sorts the
list of defaults.
* WebInspector/webInspector/inspector.js:
2007-01-08 Andrew Wellington <proton@wiretapped.net>
Reviewed by Mark.
* WebInspector/webInspector/inspector.js: Hide default values of
-webkit-column styles in WebInspector.
2007-01-05 Darin Adler <darin@apple.com>
Reviewed by Hyatt.
* Misc/WebNSAttributedStringExtras.m:
(+[NSAttributedString _web_attributedStringFromRange:]):
Updated to use new list marker text API that is String rather than
DeprecatedString. Also removed code to do text form of non-text list
markers since the list marker class now deals with that.
2007-01-05 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
Fix build.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchCreatePage):
2007-01-05 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
The data returned is now a SharedBuffer so wrap it in an NSData object.
* WebView/WebDataSource.mm:
(-[WebDataSource data]):
2007-01-04 Adam Roben <aroben@apple.com>
Reviewed by Geoff, cheered by others.
Dead code elimination.
* WebView/WebHTMLView.m:
2007-01-04 Adam Roben <aroben@apple.com>
Boo on me for undoing Beth's hard work.
* WebView/WebHTMLView.m:
(-[WebHTMLView menuForEvent:]): Undo a mistaken roll out of r18597.
2007-01-04 David Kilzer <ddkilzer@webkit.org>
Reviewed by Brady.
- fix http://bugs.webkit.org/show_bug.cgi?id=12111
Uninitialized variable in -[WebDefaultPolicyDelegate webView:decidePolicyForMIMEType:request:frame:decisionListener:]
* DefaultDelegates/WebDefaultPolicyDelegate.m: Initialize isDirectory.
2007-01-04 Adam Roben <aroben@apple.com>
Reviewed by Geoff.
Remove WebKit/AppKit from handling tabbing between subframes.
* WebCoreSupport/WebChromeClient.h: Added new ChromeClient methods for
moving focus out of the WebView.
* WebCoreSupport/WebChromeClient.mm: Ditto.
(WebChromeClient::canTakeFocus):
(WebChromeClient::takeFocus):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge webView]): Added null-check of m_frame.
* WebView/WebHTMLView.m: Removed -[WebHTMLView nextValidKeyView].
(-[WebHTMLView _updateActiveState]): Changed to focus the frame if
WebCore believes it to be the focused frame.
(-[WebHTMLView becomeFirstResponder]): Rewrote to call into
FocusController to place focus correctly within the WebView.
2007-01-04 Anders Carlsson <acarlsson@apple.com>
Reviewed by Brady.
FrameLoaderClient changed yet again.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
(WebFrameLoaderClient::dispatchWillSendRequest):
2007-01-04 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam.
FrameLoaderClient changed again.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::download):
(WebFrameLoaderClient::willUseArchive):
2007-01-04 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
No need to hit test twice.
* WebView/WebHTMLView.m:
(-[WebHTMLView menuForEvent:]):
2007-01-04 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
Turn on WebCore context menus. Delete a bunch of WebKit context
menu code that is no longer needed.
* DefaultDelegates/WebDefaultContextMenuDelegate.m: Removed a lot
of code from this class. This class only still needs to exist for
PDF context menus, so we only need to deal with the menu items that
might possibly be added to a PDF context menu.
(-[WebDefaultUIDelegate
menuItemWithTag:target:representedObject:]): Same.
(-[WebDefaultUIDelegate
webView:contextMenuItemsForElement:defaultMenuItems:]): Same.
* WebCoreSupport/WebContextMenuClient.h: Name change and have the
former getCustomMenuFromDefaultItems function return the
PlatformMenuDescription since it feels funny to have the client set
the new platform description.
* WebCoreSupport/WebContextMenuClient.mm: Same.
(WebContextMenuClient::getCustomMenuFromDefaultItems): Same. Also
move in some code that used to be in _menuForElement.
* WebView/WebHTMLView.m: Deleted a bunch of un-used functions
(-[WebHTMLView menuForEvent:]): Turn on menus, and append the
Inspect Element item.
* WebView/WebHTMLViewPrivate.h: Deleted a bunch of un-used
functions.
* WebView/WebView.mm:
(-[WebView _menuForElement:defaultItems:]): Removed a lot of code
from _menuForElement that now makes more sense elsewhere. Only PDF
context menus use this function now. Hopefully we can just get rid
of it soon, too.
2007-01-04 Anders Carlsson <acarlsson@apple.com>
Reviewed by Brady.
Update for WebCore changes.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::download):
(WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::incrementProgress):
2007-01-04 Peter Kasting <pkasting@google.com>
Reviewed by Alexey.
http://bugs.webkit.org/show_bug.cgi?id=11900:
Windows build bustage
* COM/ChromeClientWin.cpp:
(ChromeClientWin::addMessageToConsole):
(ChromeClientWin::runBeforeUnloadConfirmPanel):
* COM/ChromeClientWin.h:
* COM/ContextMenuClientWin.cpp:
(ContextMenuClientWin::contextMenuItemSelected):
* COM/ContextMenuClientWin.h:
* COM/WebFrameLoaderClient.cpp:
(WebFrameLoaderClient::setDocumentViewFromPageCache):
(WebFrameLoaderClient::forceLayout):
(WebFrameLoaderClient::forceLayoutForNonHTML):
(WebFrameLoaderClient::updateGlobalHistoryForStandardLoad):
(WebFrameLoaderClient::updateGlobalHistoryForReload):
(WebFrameLoaderClient::shouldGoToHistoryItem):
(WebFrameLoaderClient::saveScrollPositionAndViewStateToItem):
(WebFrameLoaderClient::restoreScrollPositionAndViewState):
(WebFrameLoaderClient::provisionalLoadStarted):
(WebFrameLoaderClient::saveDocumentViewToPageCache):
(WebFrameLoaderClient::canCachePage):
* COM/WebFrameLoaderClient.h:
* WebKit.vcproj/WebKit.vcproj:
2007-01-03 John Sullivan <sullivan@apple.com>
* WebView/WebPDFView.mm:
(-[WebPDFView _openWithFinder:]):
Tiger build fix: use [NSNumber initWithInt:] rather than the new [NSNumber initWithInteger:]
2007-01-03 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
- fixed <rdar://problem/4145714> WebKit's PDFView's "Open in Preview" puts the
PDF in /tmp, both group and world-readable
* WebView/WebPDFView.mm:
(-[WebPDFView _openWithFinder:]):
Make the file only readable by the current user
2007-01-03 Beth Dakin <bdakin@apple.com>
Reviewed by John.
Make localized strings for all of the context menu item titles that
are accessible to WebCore.
* English.lproj/Localizable.strings:
* WebCoreSupport/WebViewFactory.m:
(-[WebViewFactory contextMenuItemTagOpenLinkInNewWindow]):
(-[WebViewFactory contextMenuItemTagDownloadLinkToDisk]):
(-[WebViewFactory contextMenuItemTagCopyLinkToClipboard]):
(-[WebViewFactory contextMenuItemTagOpenImageInNewWindow]):
(-[WebViewFactory contextMenuItemTagDownloadImageToDisk]):
(-[WebViewFactory contextMenuItemTagCopyImageToClipboard]):
(-[WebViewFactory contextMenuItemTagOpenFrameInNewWindow]):
(-[WebViewFactory contextMenuItemTagCopy]):
(-[WebViewFactory contextMenuItemTagGoBack]):
(-[WebViewFactory contextMenuItemTagGoForward]):
(-[WebViewFactory contextMenuItemTagStop]):
(-[WebViewFactory contextMenuItemTagReload]):
(-[WebViewFactory contextMenuItemTagCut]):
(-[WebViewFactory contextMenuItemTagPaste]):
(-[WebViewFactory contextMenuItemTagNoGuessesFound]):
(-[WebViewFactory contextMenuItemTagIgnoreSpelling]):
(-[WebViewFactory contextMenuItemTagLearnSpelling]):
(-[WebViewFactory contextMenuItemTagSearchInSpotlight]):
(-[WebViewFactory contextMenuItemTagSearchWeb]):
(-[WebViewFactory contextMenuItemTagLookUpInDictionary]):
(-[WebViewFactory contextMenuItemTagOpenLink]):
(-[WebViewFactory contextMenuItemTagIgnoreGrammar]):
(-[WebViewFactory contextMenuItemTagSpellingMenu]):
(-[WebViewFactory contextMenuItemTagShowSpellingPanel:]):
(-[WebViewFactory contextMenuItemTagCheckSpelling]):
(-[WebViewFactory contextMenuItemTagCheckSpellingWhileTyping]):
(-[WebViewFactory contextMenuItemTagCheckGrammarWithSpelling]):
(-[WebViewFactory contextMenuItemTagFontMenu]):
(-[WebViewFactory contextMenuItemTagShowFonts]):
(-[WebViewFactory contextMenuItemTagBold]):
(-[WebViewFactory contextMenuItemTagItalic]):
(-[WebViewFactory contextMenuItemTagUnderline]):
(-[WebViewFactory contextMenuItemTagOutline]):
(-[WebViewFactory contextMenuItemTagStyles]):
(-[WebViewFactory contextMenuItemTagShowColors]):
(-[WebViewFactory contextMenuItemTagSpeechMenu]):
(-[WebViewFactory contextMenuItemTagStartSpeaking]):
(-[WebViewFactory contextMenuItemTagStopSpeaking]):
(-[WebViewFactory contextMenuItemTagWritingDirectionMenu]):
(-[WebViewFactory contextMenuItemTagDefaultDirection]):
(-[WebViewFactory contextMenuItemTagLeftToRight]):
(-[WebViewFactory contextMenuItemTagRightToLeft]):
2007-01-03 Brady Eidson <beidson@apple.com>
Reviewed by John Sullivan
In the Bookmarks View/History View, favicon may be the incorrect size
* History/WebHistoryItem.mm:
(-[WebHistoryItem icon]): Call to the WebIconDatabase until a WebCore issue is resolved
2007-01-03 Adele Peterson <adele@apple.com>
Reviewed by Darin.
- Fix for <rdar://problem/4455147> Safari allows division slash character in URLs, which looks like slash character (not fixed by IDNScriptWhiteList.txt)
* Misc/WebNSURLExtras.m: (allCharactersInIDNScriptWhiteList): Always disallow the division slash character.
2007-01-02 Brady Eidson <beidson@apple.com>
Controversially reviewed by Tim H. and Maciej
Fixes http://bugs.webkit.org/show_bug.cgi?id=12086, http://bugs.webkit.org/show_bug.cgi?id=12088,
possibly http://bugs.webkit.org/show_bug.cgi?id=12087, and probably a slew of others
WebHistoryItems returned from the WebBackForwardList accessors were being release/retained out-of-order
by the Safari app. This bug never surfaced before because the WebBackForwardList had a retain on the
item, preventing deallocation. Since the items are now just temporary wrappers, the list
is no longer actually retaining them.
This solution is to simulate the ownership with a [[id retain] autorelease] - gross, but maybe the
only solution for now... =/
We can possibly consider reverting this fix at a later date - that task is marked by
<rdar://problem/4905705>
* History/WebBackForwardList.mm:
(-[WebBackForwardList backItem]):
(-[WebBackForwardList currentItem]):
(-[WebBackForwardList forwardItem]):
(-[WebBackForwardList itemAtIndex:]):
2007-01-02 Beth Dakin <bdakin@apple.com>
Reviewed by Geoff.
Remove un-used function.
* WebCoreSupport/WebContextMenuClient.h:
* WebCoreSupport/WebContextMenuClient.mm:
2007-01-02 Brady Eidson <beidson@apple.com>
Reviewed extensively and repeatedly by Darin
<rdar://problem/4887137> - WebCore Back/Forward Cache
Most things not specifically commented on in the ChangeLog can be summed up as
"Do things exactly the same way as we used to, but just stick in WebCore-land as much as possible"
* History/WebBackForwardList.mm:
(kitPrivate): Convenience functions to help with subbing "WebBackForwardListPrivate" for WebCore::BackForwardList
(core):
(backForwardListWrappers): A HashMap pattern used to map WebCore objects to their WebKit counterpart
(kit):
(+[WebBackForwardList setDefaultPageCacheSizeIfNecessary]):
(-[WebBackForwardList initWithWebCoreBackForwardList:]):
(-[WebBackForwardList init]):
(-[WebBackForwardList dealloc]):
(-[WebBackForwardList finalize]):
(-[WebBackForwardList _close]):
(-[WebBackForwardList addItem:]):
(-[WebBackForwardList removeItem:]):
(-[WebBackForwardList containsItem:]):
(-[WebBackForwardList goBack]):
(-[WebBackForwardList goForward]):
(-[WebBackForwardList goToItem:]):
(-[WebBackForwardList backItem]):
(-[WebBackForwardList currentItem]):
(-[WebBackForwardList forwardItem]):
(vectorToNSArray):
(-[WebBackForwardList backListWithLimit:]):
(-[WebBackForwardList forwardListWithLimit:]):
(-[WebBackForwardList capacity]):
(-[WebBackForwardList setCapacity:]):
(-[WebBackForwardList description]):
(-[WebBackForwardList _clearPageCache]):
(-[WebBackForwardList setPageCacheSize:]):
(-[WebBackForwardList pageCacheSize]):
(-[WebBackForwardList _usesPageCache]):
(-[WebBackForwardList backListCount]):
(-[WebBackForwardList forwardListCount]):
(-[WebBackForwardList itemAtIndex:]):
* History/WebBackForwardListInternal.h: Added.
* History/WebHistory.m: Removed.
* History/WebHistory.mm: Added - Needed to be .mm to accept C++ header style
(-[_WebCoreHistoryProvider containsItemForURLLatin1:length:]):
(-[_WebCoreHistoryProvider containsItemForURLUnicode:length:]):
* History/WebHistoryItem.mm:
(kitPrivate): Same pattern as WebBackForwardList
(core):
(historyItemWrappers):
(WKNotifyHistoryItemChanged):
(-[WebHistoryItem init]):
(-[WebHistoryItem initWithURLString:title:lastVisitedTimeInterval:]):
(-[WebHistoryItem dealloc]):
(-[WebHistoryItem finalize]):
(-[WebHistoryItem copyWithZone:]):
(-[WebHistoryItem URLString]):
(-[WebHistoryItem originalURLString]):
(-[WebHistoryItem title]):
(-[WebHistoryItem setAlternateTitle:]):
(-[WebHistoryItem alternateTitle]):
(-[WebHistoryItem icon]):
(-[WebHistoryItem lastVisitedTimeInterval]):
(-[WebHistoryItem hash]):
(-[WebHistoryItem isEqual:]):
(-[WebHistoryItem description]):
(kit):
(+[WebHistoryItem entryWithURL:]):
(+[WebHistoryItem initWindowWatcherIfNecessary]):
(-[WebHistoryItem initWithURL:target:parent:title:]):
(-[WebHistoryItem initWithWebCoreHistoryItem:]):
(-[WebHistoryItem setTitle:]):
(-[WebHistoryItem setVisitCount:]):
(-[WebHistoryItem setViewState:]):
(-[WebHistoryItem _mergeAutoCompleteHints:]):
(-[WebHistoryItem initFromDictionaryRepresentation:]):
(-[WebHistoryItem scrollPoint]):
(-[WebHistoryItem _transientPropertyForKey:]):
(-[WebHistoryItem _setTransientProperty:forKey:]):
(-[WebHistoryItem dictionaryRepresentation]):
(-[WebHistoryItem target]):
(-[WebHistoryItem isTargetItem]):
(-[WebHistoryItem visitCount]):
(-[WebHistoryItem RSSFeedReferrer]):
(-[WebHistoryItem setRSSFeedReferrer:]):
(-[WebHistoryItem children]):
(-[WebHistoryItem setAlwaysAttemptToUsePageCache:]):
(-[WebHistoryItem URL]):
(-[WebHistoryItem _setLastVisitedTimeInterval:]):
(-[WebHistoryItem _lastVisitedDate]):
(-[WebHistoryItem targetItem]):
(+[WebHistoryItem _releaseAllPendingPageCaches]):
(-[WebWindowWatcher windowWillClose:]):
* History/WebHistoryItemInternal.h:
* History/WebHistoryItemPrivate.h:
* WebCoreSupport/WebFrameBridge.mm:
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::setDocumentViewFromPageCache):
(WebFrameLoaderClient::detachedFromParent1):
(WebFrameLoaderClient::loadedFromPageCache):
(WebFrameLoaderClient::updateGlobalHistoryForStandardLoad):
(WebFrameLoaderClient::updateGlobalHistoryForReload):
(WebFrameLoaderClient::shouldGoToHistoryItem):
(WebFrameLoaderClient::frameLoadCompleted):
(WebFrameLoaderClient::saveScrollPositionAndViewStateToItem):
(WebFrameLoaderClient::restoreScrollPositionAndViewState):
(WebFrameLoaderClient::provisionalLoadStarted):
(WebFrameLoaderClient::setTitle):
(WebFrameLoaderClient::saveDocumentViewToPageCache):
(WebFrameLoaderClient::canCachePage):
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.mm:
* WebView/WebDataSourceInternal.h:
* WebView/WebFrame.mm:
(-[WebFramePrivate dealloc]):
(-[WebFrame _canCachePage]):
(-[WebFrame _loadURL:referrer:intoChild:]):
* WebView/WebFrameInternal.h:
* WebView/WebFrameView.mm:
(-[WebFrameView initWithFrame:]):
(-[WebFrameView keyDown:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView closeIfNotCurrentView]): Added for a dirty hack in WebCore that is marked with a FIXME Radar
* WebView/WebHTMLViewInternal.h:
* WebView/WebView.mm:
(-[WebViewPrivate init]):
(-[WebViewPrivate dealloc]):
(-[WebView _close]):
(-[WebView _loadBackForwardListFromOtherView:]):
(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView initWithCoder:]):
(-[WebView backForwardList]):
(-[WebView goBack]):
(-[WebView goForward]):
(-[WebView goToBackForwardItem:]):
(-[WebView canGoBack]):
(-[WebView canGoForward]):
2007-01-02 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
- fixed <rdar://problem/4892525> Cannot open PDF in Preview if you attempted to
open it in Preview while PDF was loading
* WebView/WebPDFView.mm:
(-[WebPDFView menuForEvent:]):
added comment
(-[WebPDFView validateUserInterfaceItem:]):
disable this menu item when there's no document yet
(-[WebPDFView _openWithFinder:]):
If this is invoked when there is no document yet (e.g. via the PDFKit delegate method),
just beep and return. I should make a nice error message here, but I'll do that separately.
2007-01-03 Nikolas Zimmermann <zimmermann@kde.org>
Reviewed by Timothy.
Fix inspection of RenderSVGInlineText objects (#text nodes in SVG documents).
* WebInspector/WebInspector.m:
(-[WebInspector _highlightNode:]):
2007-01-02 Beth Dakin <bdakin@apple.com>
Reviewed by Darin.
Fix bug with WebCore context menu item "Copy Image."
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::copyImageToClipboard): We must call
declareTypes on the pasteboard.
2006-12-27 Mitz Pettel <mitz@webkit.org>
Reviewed by Geoff.
- fix http://bugs.webkit.org/show_bug.cgi?id=9403
Red outline from Web Inspector appears above all other OS X windows
Made the window containing the highlight a child window of the window
containing the view.
* WebInspector/WebNodeHighlight.m:
(-[WebNodeHighlight initWithBounds:andRects:forView:]):
(-[WebNodeHighlight dealloc]):
(-[WebNodeHighlight expire]):
2006-12-27 Matt Lilek <pewtermoose@gmail.com>
Reviewed by Tim H.
Bug 11993: REGRESSION(r18320): Web Inspector scroll bars not drawn
http://bugs.webkit.org/show_bug.cgi?id=11993
AppleVerticalScrollbar tries to set a NaN value as the scroll height which
causes DOM Exceptions after r18320. This overrides the _setObjectLength
method and checks for NaN until a system update can fix this. See rdar://4901491
* WebInspector/webInspector/inspector.html:
* WebInspector/webInspector/inspector.js:
2006-12-27 Geoffrey Garen <ggaren@apple.com>
Reviewed by Oliver Hunt.
Fixed <rdar://problem/4901629> Crash occurs at WebCore::Frame::page()
after closing window containing flash content
No testcase because we can't open and close windows in DRT.
I can't reproduce this crash, but from the backtrace it's clear that it
occured because of a NULL frame object. Since it's valid for a frame to
be NULL, I've added NULL checks.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView sendEvent:]):
(-[WebBaseNetscapePluginView requestWithURLCString:]):
(-[WebBaseNetscapePluginView getVariable:value:]):
2006-12-27 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Updated <rdar://problem/4871518> fix based on Darin's comments.
Instead of searching the frame tree to retrieve the new frame, put it in
a RefPtr, and then explicitly check for its removal. This option is slightly
more efficient, and it avoids problems that can occur due to frame name collision.
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
2006-12-26 Geoffrey Garen <ggaren@apple.com>
Reviewed by Eric Seidel.
Fixed <rdar://problem/4740328> Safari crash on quit in _NPN_ReleaseObject
from KJS::Bindings::CInstance::~CInstance
The essence of this change is that WebKit shouldn't meddle in plug-in
lifetime, since WebCore already manages it. The rest is details.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView removeTrackingRect]): Autorelease our window
instead of releasing it, since we might hold the last reference to our window,
and releasing it immediately would crash AppKit.
(-[WebBaseNetscapePluginView resetTrackingRect]):
* Plugins/WebNetscapePluginEmbeddedView.h:
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView dataSource]): Use our DOMElement to access
our WebFrame, since we don't keep around a direct pointer to our WebFrame
anymore.
* Plugins/WebNullPluginView.h:
* Plugins/WebNullPluginView.m:
(-[WebNullPluginView initWithFrame:error:DOMElement:]):
(-[WebNullPluginView dealloc]):
(-[WebNullPluginView viewDidMoveToWindow]): Use our DOMElement to access
our WebFrame, as above.
* WebCoreSupport/WebFrameBridge.mm: Don't call _addPlugInView because it
doesn't exist anymore. Do pass a DOMElement to WebNullPluginView's initializer,
so it can access its frame like WebNetscapePluginEmbeddedView does.
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
(-[WebFrameBridge viewForJavaAppletWithFrame:attributeNames:attributeValues:baseURL:DOMElement:]):
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm: Removed didCloseDocument. It had
two purposes -- one unnecessary, one harmful:
(1) NULL out plug-ins' weak references to their frames. Unnecessary. Having
plug-ins access their frames through their DOM elements solves this problem.
(2) Unload plug-ins. Harmful. If a plug-in unloads before WebCore is done
with it, WebCore will access unmapped memory. Also unnecessary. WebCore
Widgets take care of calling -removeFromSuperview on their NSViews, which
is sufficient for stopping plug-ins.
* WebKit.xcodeproj/project.pbxproj: Made WebNullPluginView.m ObjC++.
* WebView/WebFrame.mm: Removed _addPlugInView, since it was only used to
call -setWebFrame, which is gone.
(-[WebFramePrivate dealloc]):
* WebView/WebFrameInternal.h: Removed plugInViews, since it was only used
by _addPlugInView, which is gone.
2006-12-26 Geoffrey Garen <ggaren@apple.com>
Reviewed by Eric Seidel.
Some cleanup in preparation for fixing <rdar://problem/4740328> Safari
crash on quit in _NPN_ReleaseObject from KJS::Bindings::CInstance::~CInstance
Renamed "installedPlugins" to "sharedDatabase." This better follows
the Cocoa naming scheme, and calls out the key attribute that produced this
crash -- namely, that the database is shared throughout the process.
-installedPlugins is actually a part of SPI, but a global search showed
that it had no users.
* Plugins/WebPluginDatabase.h:
* Plugins/WebPluginDatabase.m:
(+[WebPluginDatabase sharedDatabase]):
(-[WebPluginDatabase refresh]):
(-[WebPluginDatabase _plugInPaths]):
(-[WebPluginDatabase _removePlugin:]):
* WebCoreSupport/WebViewFactory.m:
(-[WebViewFactory pluginsInfo]):
(-[WebViewFactory refreshPlugins:]):
(-[WebViewFactory pluginSupportsMIMEType:]):
* WebView/WebView.mm:
(+[WebView _supportedMIMETypes]):
(+[WebView _viewClass:andRepresentationClass:forMIMEType:]):
(-[WebView _close]):
(-[WebView _pluginForMIMEType:]):
(-[WebView _pluginForExtension:]):
(-[WebView _isMIMETypeRegisteredAsPlugin:]):
2006-12-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Adam Roben.
Fixed <rdar://problem/4778898> REGRESSION: crash in getInstanceForView()
when quitting from kcbs.com
No testcase because we can't open and close windows in DRT.
The crash was caused by deallocating plug-ins that were later referenced
in the unload event handler.
* Plugins/WebBaseNetscapePluginView.mm: Don't call stop on ourselves because
we may destroy our plugin before the unload handler fires. Also, we don't
need to, since didCloseDocument will do it for us.
(-[WebBaseNetscapePluginView addWindowObservers]): We don't need to listen
for windowWillClose anymore, since we don't want to call -stop on ourselves.
(-[WebBaseNetscapePluginView removeWindowObservers]): ditto.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::didCloseDocument): Renamed from "willCloseDocument."
2006-12-25 Geoffrey Garen <ggaren@apple.com>
More "plugin" => "pluginPackage" renaming that I forgot to check in.
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView setPluginPackage:]):
* Plugins/WebNetscapePluginEmbeddedView.h:
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:DOMElement:]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
(-[WebFrameBridge viewForJavaAppletWithFrame:attributeNames:attributeValues:baseURL:DOMElement:]):
2006-12-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Eric Seidel.
Fixed crash when opening view source window.
* WebView/WebView.mm:
(-[WebView initWithCoder:]): Don't use the WebView until calling
_commonInitialization...
2006-12-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Oliver Hunt.
Removed WebCoreSettings, cleaned up WebCore::Settings.
* WebView/WebFrame.mm: Added helper functions for converting between
WebKitEditableLinkBehavior and WebCore::EditableLinkBehavior. I'm not sure
that this is the best place for these functions, but it's where all the
other functions like them reside.
(core):
(kit):
* WebView/WebFrameInternal.h:
* WebView/WebView.mm: Removed uses of WebCoreSettings. Replaced with direct
use of underlying page's settings.
2006-12-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Oliver Hunt.
Some refactoring in preparation for fixing <rdar://problem/4778898>
REGRESSION: crash in getInstanceForView() when quitting from kcbs.com
Two renames:
- "plugin" => "pluginPackage" (since the type is WebNetscapePluginPackage *)
- "instance" and/or "pluginPointer" => plugin (since NPP is an opaque handle to a plug-in)
Removed braces around single-line 'if' statements.
Made plugin a pointer instead of an inline ivar. This allows us to NULL
it out once we call NPP_Destroy on it.
Added helper functions for creating and destroying plugin. The destroy function
NULLs out plugin, which helps with debugging.
(-[WebBaseNetscapePluginView willCallPlugInFunction]): Added an ASSERT
to catch attempts to call functions on destroyed plug-ins.
(-[WebBaseNetscapePluginView _createPlugin]): New helper function.
(-[WebBaseNetscapePluginView _destroyPlugin]): New helper function.
2006-12-24 David Kilzer <ddkilzer@webkit.org>
Removed empty directory.
* WebKit/Loader: Removed.
2006-12-22 Geoffrey Garen <ggaren@apple.com>
Reviewed by Brady Eidson.
Fixed <rdar://problem/4871518> Leopard9A321: Crash visiting www.audible.com
(WebCore::FrameLoader::loadSubframe)
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
- The fix:
Changed to re-fetch the child frame we're trying to load before returning it,
since its onload handler may have removed it from the document. This
allows us to treat a removed frame like a frame that never loaded.
- Plus some cleanup:
- Changed to return a WebCore::Frame* instead of a WebFrameBridge *,
to simplify some code.
- Grouped ObjC objects by usage, and moved calls to -release so that they
immediately follow the calls that retain.
2006-12-21 John Sullivan <sullivan@apple.com>
Reviewed by Geoff Garen
- improved concept and implementation of my previous checkin after discussing with Darin
* WebView/WebViewPrivate.h:
* WebView/WebView.mm:
(-[WebView setHoverFeedbackSuspended:]):
renamed from setIgnoresMouseMovedEvents, and now tells the main WebHTMLView (if any) that this state has
changed. Telling just the main WebHTMLView is a bit of an implementation hack. Hopefully someday we can
rework the document architecture and make this kind of thing less hacky (but this is following existing
customs, so I don't feel too bad)
(-[WebView isHoverFeedbackSuspended]):
renamed from ignoresMouseMovedEvents
* WebView/WebHTMLViewInternal.h:
declare _hoverFeedbackSuspendedChanged
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateMouseoverWithEvent:]):
test the webView's state of the hit-tested WebHTMLView rather than self
(-[WebHTMLView _hoverFeedbackSuspendedChanged]):
generate a fake mouse-moved event, which simulates the mouse moving away from
the current element or back over it
2006-12-21 Darin Adler <darin@apple.com>
Reviewed by Oliver.
* WebInspector/webInspector/inspector.js: Added default values for the new CSS
properties so they don't appear in the inspector when their values are
uninteresting.
2006-12-21 John Sullivan <sullivan@apple.com>
Reviewed by Geoff Garen
- added WebKit support for making a web page temporarily ignore mouse movements
* WebView/WebViewPrivate.h:
declare ignoresMouseMovedEvents and setIgnoresMouseMovedEvents:
* WebView/WebView.mm:
added ignoresMouseMovedEvents boolean field to _private data structure
(-[WebView setIgnoresMouseMovedEvents:]):
set new boolean field
(-[WebView ignoresMouseMovedEvents]):
return new boolean field
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateMouseoverWithEvent:]):
bail out right away if [[self _webView] ignoresMouseMovedEvents]
2006-12-21 Mark Rowe <bdash@webkit.org>
Reviewed by Geoff.
http://bugs.webkit.org/show_bug.cgi?id=11888
Bug 11888: REGRESSION (r18320): Web Inspector panes broken
* WebInspector/webInspector/inspector.js: Use removeProperty to reset a style property to its
initial value. Bail out early from updateNodePane if Inspector has not yet been set.
2006-12-19 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- fix for unrepro infinite recursion bug:
<rdar://problem/4448181> CrashTracer: 154 crashes in Safari at com.apple.AppKit:
-[NSView isDescendantOf:] + 24; infinite recursion in makeFirstResponder logic
* WebView/WebView.mm:
added becomingFirstResponder BOOL to private struct
(-[WebView becomeFirstResponder]):
use _private->becomingFirstResponder to guard against infinite recursion; complain on
debug builds if we run into this problem
2006-12-19 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4891774> Local WebCore/WebBrowser builds fail in 9A328 due to warning about ObjC-2.0 language features
* WebKit.xcodeproj/project.pbxproj:
2006-12-18 Ada Chan <adachan@apple.com>
Reviewed by Adam.
Moved canRunBeforeUnloadConfirmPanel, runBeforeUnloadConfirmPanel, and closeWindowSoon
from WebCoreFrameBridge to Chrome.
* COM/ChromeClientWin.cpp:
(ChromeClientWin::canRunBeforeUnloadConfirmPanel):
(ChromeClientWin::runBeforeUnloadConfirmPanel):
(ChromeClientWin::closeWindowSoon):
* COM/ChromeClientWin.h:
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::canRunBeforeUnloadConfirmPanel):
(WebChromeClient::runBeforeUnloadConfirmPanel):
(WebChromeClient::closeWindowSoon):
* WebCoreSupport/WebFrameBridge.mm:
2006-12-18 Alice Liu <alice.liu@apple.com>
Reviewed by Adam.
Have the Editor handle deletion instead of WebHTMLView
* WebKitPrefix.h:
Turned on WebCore deletion
* WebView/WebHTMLViewInternal.h:
Moved ownership of startNewKillRingSequence to the WebCore::Editor
* WebView/WebHTMLView.m:
(-[NSArray becomeFirstResponder]):
Use the Editor's startNewKillRingSequence flag
(-[NSArray deleteForward:]):
(-[NSArray deleteBackward:]):
(-[NSArray deleteWordForward:]):
(-[NSArray deleteWordBackward:]):
(-[NSArray deleteToBeginningOfLine:]):
(-[NSArray deleteToEndOfLine:]):
(-[NSArray deleteToBeginningOfParagraph:]):
(-[NSArray deleteToEndOfParagraph:]):
(-[NSArray deleteToMark:]):
use Editor::deleteWithDirection instead of WebHTMLView's
2006-12-16 Adele Peterson <adele@apple.com>
Reviewed by Adam.
WebKit part of fix for:
<rdar://problem/4463829> Switch to use new search field implementation for <input type="search">
* WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Initialize WKDrawTextFieldCellFocusRing.
* WebInspector/webInspector/inspector.css: Set -webkit-user-select:text and text-shadow:none on the search field.
These are both properties that we didn't honor in the old control, and the inherited values didn't work or look right.
2006-12-16 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
WebKit side of making WebCore context menus support state and
enabled/disabled.
* WebCoreSupport/WebContextMenuClient.h: contextMenuItemSelected
takes a pointer to the parentMenu now since menu items no longer
hold onto it.
* WebCoreSupport/WebContextMenuClient.mm: Same.
(WebContextMenuClient::contextMenuItemSelected): Same.
* WebView/WebHTMLView.m: Must call setAutoenablesItems:NO on our
menu.
(-[NSArray menuForEvent:]):
* WebView/WebUIDelegatePrivate.h: No need for if-def.
2006-12-15 Anders Carlsson <acarlsson@apple.com>
Reviewed by Geoff.
Update for WebCore changes.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
* WebView/WebDataSource.mm:
(-[WebDataSource response]):
2006-12-15 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
Update for WebCore changes.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::willUseArchive):
* WebView/WebDataSource.mm:
(-[WebDataSource _URLForHistory]):
2006-12-15 Marvin Decker <marv.decker@gmail.com>
Reviewed by Darin and Alexey.
Fix the Windows build, move various Client implementations out of
WebCore and into WebKit.
* COM/ChromeClientWin.cpp: Added.
(ChromeClientWin::~ChromeClientWin):
(ChromeClientWin::chromeDestroyed):
(ChromeClientWin::setWindowRect):
(ChromeClientWin::windowRect):
(ChromeClientWin::pageRect):
(ChromeClientWin::scaleFactor):
(ChromeClientWin::focus):
(ChromeClientWin::unfocus):
(ChromeClientWin::createWindow):
(ChromeClientWin::createModalDialog):
(ChromeClientWin::show):
(ChromeClientWin::canRunModal):
(ChromeClientWin::runModal):
(ChromeClientWin::setToolbarsVisible):
(ChromeClientWin::toolbarsVisible):
(ChromeClientWin::setStatusbarVisible):
(ChromeClientWin::statusbarVisible):
(ChromeClientWin::setScrollbarsVisible):
(ChromeClientWin::scrollbarsVisible):
(ChromeClientWin::setMenubarVisible):
(ChromeClientWin::menubarVisible):
(ChromeClientWin::setResizable):
(ChromeClientWin::addMessageToConsole):
* COM/ChromeClientWin.h: Added.
* COM/ContextMenuClientWin.cpp: Added.
(ContextMenuClientWin::~ContextMenuClientWin):
(ContextMenuClientWin::contextMenuDestroyed):
(ContextMenuClientWin::addCustomContextMenuItems):
(ContextMenuClientWin::contextMenuItemSelected):
(ContextMenuClientWin::copyLinkToClipboard):
(ContextMenuClientWin::downloadURL):
(ContextMenuClientWin::copyImageToClipboard):
(ContextMenuClientWin::lookUpInDictionary):
(ContextMenuClientWin::speak):
(ContextMenuClientWin::stopSpeaking):
* COM/ContextMenuClientWin.h: Added.
* COM/EditorClientWin.cpp: Added.
(EditorClientWin::~EditorClientWin):
(EditorClientWin::pageDestroyed):
(EditorClientWin::shouldDeleteRange):
(EditorClientWin::shouldShowDeleteInterface):
(EditorClientWin::smartInsertDeleteEnabled):
(EditorClientWin::isContinuousSpellCheckingEnabled):
(EditorClientWin::toggleContinuousSpellChecking):
(EditorClientWin::isGrammarCheckingEnabled):
(EditorClientWin::toggleGrammarChecking):
(EditorClientWin::spellCheckerDocumentTag):
(EditorClientWin::selectWordBeforeMenuEvent):
(EditorClientWin::isEditable):
(EditorClientWin::shouldBeginEditing):
(EditorClientWin::shouldEndEditing):
(EditorClientWin::shouldInsertNode):
(EditorClientWin::shouldInsertText):
(EditorClientWin::shouldApplyStyle):
(EditorClientWin::didBeginEditing):
(EditorClientWin::respondToChangedContents):
(EditorClientWin::didEndEditing):
(EditorClientWin::registerCommandForUndo):
(EditorClientWin::registerCommandForRedo):
(EditorClientWin::clearUndoRedoOperations):
(EditorClientWin::canUndo):
(EditorClientWin::canRedo):
(EditorClientWin::undo):
(EditorClientWin::redo):
* COM/EditorClientWin.h: Added.
* COM/WebFrame.cpp:
(WebFrame::WebFrame):
(WebFrame::initWithName):
* COM/WebFrame.h:
* COM/WebFrameLoaderClient.cpp: Added.
(WebFrameLoaderClient::WebFrameLoaderClient):
(WebFrameLoaderClient::~WebFrameLoaderClient):
(WebFrameLoaderClient::frameLoaderDestroyed):
(WebFrameLoaderClient::hasWebView):
(WebFrameLoaderClient::hasFrameView):
(WebFrameLoaderClient::hasBackForwardList):
(WebFrameLoaderClient::resetBackForwardList):
(WebFrameLoaderClient::provisionalItemIsTarget):
(WebFrameLoaderClient::loadProvisionalItemFromPageCache):
(WebFrameLoaderClient::invalidateCurrentItemPageCache):
(WebFrameLoaderClient::privateBrowsingEnabled):
(WebFrameLoaderClient::makeDocumentView):
(WebFrameLoaderClient::makeRepresentation):
(WebFrameLoaderClient::forceLayout):
(WebFrameLoaderClient::forceLayoutForNonHTML):
(WebFrameLoaderClient::updateHistoryForCommit):
(WebFrameLoaderClient::updateHistoryForBackForwardNavigation):
(WebFrameLoaderClient::updateHistoryForReload):
(WebFrameLoaderClient::updateHistoryForStandardLoad):
(WebFrameLoaderClient::updateHistoryForInternalLoad):
(WebFrameLoaderClient::updateHistoryAfterClientRedirect):
(WebFrameLoaderClient::setCopiesOnScroll):
(WebFrameLoaderClient::tokenForLoadErrorReset):
(WebFrameLoaderClient::resetAfterLoadError):
(WebFrameLoaderClient::doNotResetAfterLoadError):
(WebFrameLoaderClient::willCloseDocument):
(WebFrameLoaderClient::detachedFromParent1):
(WebFrameLoaderClient::detachedFromParent2):
(WebFrameLoaderClient::detachedFromParent3):
(WebFrameLoaderClient::detachedFromParent4):
(WebFrameLoaderClient::loadedFromPageCache):
(WebFrameLoaderClient::dispatchDidHandleOnloadEvents):
(WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
(WebFrameLoaderClient::dispatchDidCancelClientRedirect):
(WebFrameLoaderClient::dispatchWillPerformClientRedirect):
(WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
(WebFrameLoaderClient::dispatchWillClose):
(WebFrameLoaderClient::dispatchDidReceiveIcon):
(WebFrameLoaderClient::dispatchDidStartProvisionalLoad):
(WebFrameLoaderClient::dispatchDidReceiveTitle):
(WebFrameLoaderClient::dispatchDidCommitLoad):
(WebFrameLoaderClient::dispatchDidFinishLoad):
(WebFrameLoaderClient::dispatchDidFirstLayout):
(WebFrameLoaderClient::dispatchShow):
(WebFrameLoaderClient::cancelPolicyCheck):
(WebFrameLoaderClient::dispatchWillSubmitForm):
(WebFrameLoaderClient::dispatchDidLoadMainResource):
(WebFrameLoaderClient::clearLoadingFromPageCache):
(WebFrameLoaderClient::isLoadingFromPageCache):
(WebFrameLoaderClient::revertToProvisionalState):
(WebFrameLoaderClient::clearUnarchivingState):
(WebFrameLoaderClient::progressStarted):
(WebFrameLoaderClient::progressCompleted):
(WebFrameLoaderClient::setMainFrameDocumentReady):
(WebFrameLoaderClient::willChangeTitle):
(WebFrameLoaderClient::didChangeTitle):
(WebFrameLoaderClient::finishedLoading):
(WebFrameLoaderClient::finalSetupForReplace):
(WebFrameLoaderClient::setDefersLoading):
(WebFrameLoaderClient::isArchiveLoadPending):
(WebFrameLoaderClient::cancelPendingArchiveLoad):
(WebFrameLoaderClient::clearArchivedResources):
(WebFrameLoaderClient::canHandleRequest):
(WebFrameLoaderClient::canShowMIMEType):
(WebFrameLoaderClient::representationExistsForURLScheme):
(WebFrameLoaderClient::generatedMIMETypeForURLScheme):
(WebFrameLoaderClient::frameLoadCompleted):
(WebFrameLoaderClient::restoreScrollPositionAndViewState):
(WebFrameLoaderClient::provisionalLoadStarted):
(WebFrameLoaderClient::shouldTreatURLAsSameAsCurrent):
(WebFrameLoaderClient::addHistoryItemForFragmentScroll):
(WebFrameLoaderClient::didFinishLoad):
(WebFrameLoaderClient::prepareForDataSourceReplacement):
(WebFrameLoaderClient::setTitle):
(WebFrameLoaderClient::userAgent):
* COM/WebFrameLoaderClient.h: Added.
* COM/WebKitDLL.h:
* WebKit.vcproj/WebKit.vcproj:
2006-12-15 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
Include ResourceError.h.
* Plugins/WebNetscapePluginStream.mm:
* WebKit.xcodeproj/project.pbxproj:
2006-12-14 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
Update for WebCore changes.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::incrementProgress):
(WebFrameLoaderClient::committedLoad):
(WebFrameLoaderClient::deliverArchivedResources):
* WebView/WebView.mm:
(-[WebView _incrementProgressForIdentifier:length:]):
* WebView/WebViewInternal.h:
2006-12-14 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4827549> need NSRange-based selection support exposed.
* WebView/WebFrame.mm:
(-[WebFrame _selectedNSRange]):
(-[WebFrame _selectNSRange:]):
* WebView/WebFramePrivate.h:
2006-12-14 Anders Carlsson <acarlsson@apple.com>
Reviewed by John.
Update for WebCore changes.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidFailLoading):
(WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebFrameLoaderClient::dispatchDidFailLoad):
(WebFrameLoaderClient::dispatchUnableToImplementPolicy):
(WebFrameLoaderClient::setMainDocumentError):
(WebFrameLoaderClient::cancelledError):
(WebFrameLoaderClient::cannotShowURLError):
(WebFrameLoaderClient::interruptForPolicyChangeError):
(WebFrameLoaderClient::cannotShowMIMETypeError):
(WebFrameLoaderClient::fileDoesNotExistError):
(WebFrameLoaderClient::shouldFallBack):
2006-12-13 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- adjusted for changes from NSURLRequest to ResourceRequest
* Plugins/WebPluginController.mm:
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::updateHistoryForReload):
(WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
(WebFrameLoaderClient::dispatchDecidePolicyForMIMEType):
(WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
(WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
(WebFrameLoaderClient::startDownload):
(WebFrameLoaderClient::cannotShowURLError):
(WebFrameLoaderClient::createDocumentLoader):
* WebView/WebDataSource.mm:
(-[WebDataSource _initWithDocumentLoader:]):
(-[WebDataSource initialRequest]):
(-[WebDataSource request]):
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::WebDocumentLoaderMac):
* WebView/WebFrame.mm:
(-[WebFrame _createItem:]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame loadArchive:]):
2006-12-12 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::download):
Get the handle and proxy from the ResourceHandle now that they aren't passed to us.
2006-12-11 Darin Adler <darin@apple.com>
Reviewed by Brady.
- did some of the Mac-specific file moves mentioned in my recent mail to the WebKit list
* WebCoreSupport/WebFrameBridge.h: Updated for change to WebCoreKeyboardAccess.
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge _retrieveKeyboardUIModeFromPreferences:]): Ditto.
(-[WebFrameBridge keyboardUIMode]): Ditto.
2006-12-11 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
WebKit support for editing sub-menu actions.
* WebCoreSupport/WebContextMenuClient.h: New functions for the
speech sub-menu.
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::speak):
(WebContextMenuClient::stopSpeaking):
* WebCoreSupport/WebEditorClient.h: New functions to toggle
spelling/grammar checking.
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::toggleContinuousSpellChecking):
(WebEditorClient::toggleGrammarChecking):
* WebView/WebUIDelegatePrivate.h: Re-named some of the spelling
sub-menu tags.
2006-12-11 Alice Liu <alice.liu@apple.com>
Reviewed by Geoff, Adam.
switch to use the Editor for copying URLs
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate copyLinkToClipboard:]):
Call down to the editor for this.
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
Add some calls necessary for Pasteboard::writeURL to work
2006-12-11 Darin Adler <darin@apple.com>
Reviewed by Brady.
- http://bugs.webkit.org/show_bug.cgi?id=11794
fix lifetime problems affecting Frame's ownerElement pointer
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge finishInitializingWithPage:WebCore::frameName:frameView:ownerElement:]):
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:frameView:]):
(-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
Use HTMLFrameOwnerElement.
* WebCoreSupport/WebFrameLoaderClient.mm: Include the relevant headers for the
HTMLFormElement class.
* WebKit.xcodeproj/project.pbxproj: Let Xcode have its way.
* WebView/WebFrame.mm: (-[WebFrame frameElement]): Update includes and types for the
change in return type of ownerElement.
2006-12-11 David Harrison <harrison@apple.com>
Fix previous checkin where I committed the wrong file.
<rdar://problem/4863611> Xyle Scope crashes at launch due to WebCore-521.29.3
* WebView/WebFrame.mm:
(-[WebFrame frameElement]):
Add nil check.
* WebView/WebPreferences.m:
(-[WebPreferences editableLinkBehavior]):
Reverted to previous.
2006-12-08 David Hyatt <hyatt@apple.com>
Land new ICU abstraction layer. Patch by Lars.
Reviewed by me
* ForwardingHeaders/wtf/icu/UnicodeIcu.h: Added.
* ForwardingHeaders/wtf/unicode/Unicode.h: Added.
* WebKit.xcodeproj/project.pbxproj:
=== Safari-521.32 ===
2006-12-08 Timothy Hatcher <timothy@apple.com>
Rolling out a change that broke Mail stationary.
<rdar://problem/4699166> REGRESSION: Background images in Mail stationery do not load
* WebView/WebUnarchivingState.m:
(-[WebUnarchivingState archivedResourceForURL:]):
2006-12-08 Peter Kasting <pkasting@google.com>
Reviewed and landed by Alexey.
http://bugs.webkit.org/show_bug.cgi?id=11759:
Windows build bustage
* COM/WebFrame.cpp:
(WebFrame::loadDataSource):
* COM/WebFrame.h:
2006-12-08 David Harrison <harrison@apple.com>
Reviewed by Brady.
<rdar://problem/4863611> Xyle Scope crashes at launch due to WebCore-521.29.3
* WebView/WebPreferences.m:
(-[WebPreferences editableLinkBehavior]):
Add nil check.
2006-12-07 Beth Dakin <bdakin@apple.com>
Reviewed by Brady.
Build fix for WebCore ContextMenus. It got broken by r18046.
* WebView/WebHTMLView.m:
(-[NSArray menuForEvent:]):
2006-12-07 Beth Dakin <bdakin@apple.com>
Reviewed by Brady.
Make some parameters const and const references.
* WebCoreSupport/WebContextMenuClient.h:
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::contextMenuItemSelected):
(WebContextMenuClient::copyLinkToClipboard):
(WebContextMenuClient::downloadURL):
(WebContextMenuClient::copyImageToClipboard):
2006-12-06 Brady Eidson <beidson@apple.com>
Reviewed by John Sullivan
Fixes http://bugs.webkit.org/show_bug.cgi?id=11675 and <rdar://4857669>
Now we need to explicitly set the data source when loading from a page cache
* History/WebHistoryItem.mm:
(-[WebHistoryItem _scheduleRelease]): Enhanced a logging message
(+[WebHistoryItem _releasePageCache:]): Ditto
(+[WebHistoryItem _releaseAllPendingPageCaches]): Ditto
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::setDocumentViewFromPageCache): Reset the View's DataSource from the cache, effectively reopening it
* WebView/WebHTMLView.m:
(-[NSArray setDataSource:]): Properly Handle resetting the DataSource and "reopening" the view
2006-12-06 Brady Eidson <beidson@apple.com>
Reviewed by Adam and Oliver
While working on http://bugs.webkit.org/show_bug.cgi?id=11675 I
decided to fix much of the null-deref problems that creeped in via
the loader refactoring. This isn't changing behavior, just reintroducing
the free nil checking we used to have with pure ObjC
* WebView/WebHTMLView.m:
(-[NSArray menuForEvent:]): Explicitly check for null frames
(-[NSArray mouseDown:]): Ditto
(-[NSArray mouseDragged:]): Ditto
(-[NSArray mouseUp:]): Ditto
(-[NSArray performKeyEquivalent:]): Ditto
(-[WebHTMLView elementAtPoint:allowShadowContent:]): Ditto
2006-12-05 John Sullivan <sullivan@apple.com>
Reviewed by Beth
Updated to match Frame -> Editor changes in WebCore
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
guessesForUngrammaticalSelection() is now in Editor
* WebView/WebHTMLView.m:
(-[WebHTMLView _isSelectionUngrammatical]):
isSelectionUngrammatical() is now in Editor
(-[WebHTMLView _isSelectionMisspelled]):
isSelectionMisspelled() is now in Editor
(-[WebHTMLView checkSpelling:]):
advanceToNextMisspelling() is now in Editor
(-[WebHTMLView showGuessPanel:]):
ditto
2006-12-05 John Sullivan <sullivan@apple.com>
Reviewed by Adam
Old context-menu mechanism fix for:
<rdar://problem/4864351> Should leave out "No Guesses Found" from context menu for bad grammar
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
Leave out "No Guesses Found" and separator for grammar-checking case.
2006-12-05 John Sullivan <sullivan@apple.com>
build fix
* WebView/WebViewPrivate.h:
* WebView/WebView.mm:
(-[WebView isGrammarCheckingEnabled]):
define isGrammarCheckingEnabled whether on Tiger or not (just return NO on Tiger)
2006-12-04 John Sullivan <sullivan@apple.com>
Reviewed by Darin
WebKit part of fix for:
<rdar://problem/4817188> Context menu for bad grammar should include suggestions and "Ignore Grammar"
The context menu mechanism is currently in flux; the old mechanism is still in place, but an
up-and-coming new mechanism is waiting in the wings. I updated both of them, but couldn't
test the new mechanism because it doesn't work well enough yet. Most of this WebKit code
can be deleted when the new mechanism is in place.
* WebView/WebUIDelegatePrivate.h:
added WebMenuItemTagIgnoreGrammar
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate menuItemWithTag:target:representedObject:]):
added case for WebMenuItemTagIgnoreGrammar
(-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
now considers adding grammar-related items as well as spelling-related items
* WebView/WebHTMLViewPrivate.h:
declared _isSelectionUngrammatical
* WebView/WebHTMLView.m:
(-[WebHTMLView _isSelectionUngrammatical]):
new method, calls through to WebCore
(-[WebHTMLView _ignoreGrammarFromMenu:]):
new method, calls _ignoreSpellingFromMenu: since NSSpellChecker has one method for both
* English.lproj/Localizable.strings:
updated for "Ignore Grammar" menu item title
2006-12-04 Darin Adler <darin@apple.com>
Reviewed by Adele.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::actionDictionary): Changed to use the new
findEventWithKeyState function in WebCore instead of a local function
in this file.
2006-12-04 Geoffrey Garen <ggaren@apple.com>
Rolled out the WebDashboardBehaviorUseBackwardCompatibilityModeEnabled
part of my last checkin.
We have to turn on support for backward compatibility mode to avoid Dashboard
regressions in the short term.
* WebView/WebView.mm:
(-[WebView _setDashboardBehavior:to:]):
2006-12-02 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin Adler.
Added SPI for enabling Dashboard backward compatibility mode. For now,
we enable it unconditionally for Dashboard and Dashcode. Once they
implement specific support for the backward compatibility mode behavior,
we can change that.
Set the default WebDashboardBehaviorUseBackwardCompatibilityModeEnabled
to YES in order to turn this code on.
* WebView/WebView.mm:
(-[WebView _setDashboardBehavior:to:]):
(-[WebView _dashboardBehavior:]):
* WebView/WebViewPrivate.h:
2006-12-04 Darin Adler <darin@apple.com>
Reviewed by Alice.
* WebCoreSupport/WebEditorClient.h: Removed "_web_" prefix from
C++ userVisibleString member function.
* WebCoreSupport/WebEditorClient.mm: (WebEditorClient::userVisibleString):
Ditto.
* WebView/WebView.mm: (-[WebView selectedFrame]): Removed extra return statement.
2006-12-04 Peter Kasting <pkasting@google.com>
Reviewed and landed by Alexey.
http://bugs.webkit.org/show_bug.cgi?id=11738:
Make link clicking work again on Windows.
The WebKit changes are to ignore WM_MOUSEMOVED messages when the mouse
hasn't actually moved, which were preventing clicks from actually
getting dispatched in many cases. It's a peculiarity of Windows mouse
handling that we receive these at all.
* COM/WebView.cpp:
(WebView::WebView):
(WebView::mouseMoved):
* COM/WebView.h:
2006-12-04 John Sullivan <sullivan@apple.com>
Reviewed by Anders
- fixed <rdar://problem/4857833> REGRESSION: When ctrl-clicking on a misspelled word, "Ignore Spelling" and "Learn Spelling"
menu items not displayed in the contextual menu
* WebView/WebHTMLView.m:
(-[WebHTMLView _isSelectionMisspelled]):
We were computing isSelectionMisspelled by calling WebCore, but then ignoring the result and always
returning NO. D'oh!
2006-12-01 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
Changes to support sub-menus in WebCore ContextMenus.
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::contextMenuItemSelected):
ContextMenuItem::menu() is now called parentMenu()
* WebView/WebUIDelegatePrivate.h: New not-yet-API tags.
2006-12-01 Darin Adler <darin@apple.com>
Reviewed by Mitz.
- fix http://bugs.webkit.org/show_bug.cgi?id=11628
REGRESSION (r17597): Command-return in native text fields doesn't open a new tab or window
* WebCoreSupport/WebFrameLoaderClient.mm:
(findKeyStateEvent): Added. Helper that finds the mouse or keyboard event in a chain
of events and their underlying events.
(findMouseEvent): Added. Same, but specifically for mouse events.
(WebFrameLoaderClient::actionDictionary): Rewrote to use the above functions. This means we
use the modifiers from the underlying events rather than just the one from the event itself.
So if the event is a DOM activate event, we can still see the modifiers from the original
keyboard event that triggered it. Has no effect if the event is already the right type or
if there is no underlying event.
* WebView/WebFrame.mm: Added a newly-needed include.
* WebKit.xcodeproj/project.pbxproj: Xcode wants what it wants.
2006-12-01 Peter Kasting <pkasting@google.com>
Reviewed by Mitz.
http://bugs.webkit.org/show_bug.cgi?id=11732:
Windows build bustage.
* COM/WebFrame.cpp:
(WebFrame::initWithName):
2006-12-01 Timothy Hatcher <timothy@apple.com>
Reviewed by Adam.
<rdar://problem/4841432> 9A312: iWeb crashes on launch; _WebReportError missing from WebKit
Added back WebReportAssertionFailure and WebReportError for apps that still need these symbols.
* Misc/OldWebAssertions.c: Added.
(WebReportAssertionFailure):
(WebReportError):
* WebKit.LP64.exp: added the new symbols, and sorted the file
* WebKit.exp: added the new symbols, and sorted the file
* WebKit.xcodeproj/project.pbxproj:
2006-11-30 Geoffrey Garen <ggaren@apple.com>
Rubber Stamped by Anders Carlsson.
Global rename of Document::focusNode to Document::focusedNode. 'focusNode'
suggested a command, and conflicted with a different meaning for 'focusNode'
in the Mozilla selection API.
* WebView/WebHTMLView.m:
(-[NSArray clearFocus]):
2006-11-30 Matt Lilek <pewtermoose@gmail.com>
Reviewed by Mitz.
Bug 10698: Scroll wheel causes inspector to shift up
http://bugs.webkit.org/show_bug.cgi?id=10698
Remove size attribute from the tree popup as a workaround for
http://bugs.webkit.org/show_bug.cgi?id=11362 Bug 11362: Native popup with size="1" wraps options
* WebInspector/webInspector/inspector.css:
* WebInspector/webInspector/inspector.html:
2006-11-30 Matt Lilek <pewtermoose@gmail.com>
Reviewed by Tim H.
Move web inspector style markup to javascript to fix http://bugs.webkit.org/show_bug.cgi?id=6724
Bug 6724: Text copied from Web Inspector is different from actual text
* WebInspector/webInspector/inspector.css:
* WebInspector/webInspector/inspector.js:
2006-11-30 Adam Roben <aroben@apple.com>
Reviewed by Beth.
Put code in place to use WebCore context menus when they are turned
on.
* WebView/WebHTMLView.m:
(-[NSArray menuForEvent:]):
2006-11-29 Timothy Hatcher <timothy@apple.com>
Reviewed by Oliver.
Keep preferences separate from the rest of the client, making sure we are using expected preference values.
This lets the inspector work when plugins are disabled for the WebView.
* WebInspector/WebInspector.m:
(-[NSWindow window]):
2006-11-29 Anders Carlsson <acarlsson@apple.com>
Reviewed by Tim.
Add back methods in WebCoreStatistics that are still used by Tiger Safari.
* Misc/WebCoreStatistics.h:
* Misc/WebCoreStatistics.m:
(+[WebCoreStatistics emptyCache]):
(+[WebCoreStatistics setCacheDisabled:]):
2006-11-28 Alice Liu <alice.liu@apple.com>
Reviewed by Maciej.
A fix for a couple failing layout tests involving copy/cut in iframes.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::dataForArchivedSelection):
Use the frame parameter instead of using the webview's selectedFrame.
2006-11-28 Beth Dakin <bdakin@apple.com>
Reviewed by Geoffff.
Fix for http://bugs.webkit.org/show_bug.cgi?id=11691 REGRESSION
(r17399, r17511): WebElementDictionary no longer returns nil
NSStrings
String's NSString* operator converts null Strings to empty
NSStrings for compatibility with AppKit. We need to work around
that here.
* Misc/WebElementDictionary.m:
(NSStringOrNil):
(-[WebElementDictionary _altDisplayString]):
(-[WebElementDictionary _spellingToolTip]):
(-[WebElementDictionary _title]):
(-[WebElementDictionary _titleDisplayString]):
(-[WebElementDictionary _textContent]):
2006-11-28 Geoffrey Garen <ggaren@apple.com>
Reviewed by Beth Dakin.
Fixed <rdar://problem/4844855> Should clarify when to create clients in
the WebCore client API
All clients must now be supplied as constructor arguments. This clarifies
when you need to create clients, and also guarantees that objects can't
(for the most part) be in a clientless state.
Layout tests pass. No leaks reported.
* WebCoreSupport/WebFrameBridge.mm: Shuffled around initialization and changed
some arguments to resolve ciruclar dependencies at init time.
(-[WebFrame _initWithWebFrameView:webView:bridge:]): We no longer call setClient
here, because the client is set up at construction time.
2006-11-28 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
Update for changes to ResourceRequest.
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::createWindow):
(WebChromeClient::createModalDialog):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::canHandleRequest):
2006-11-28 Adam Roben <aroben@apple.com>
Reviewed by Beth.
More WebCore context menu work.
* DefaultDelegates/WebDefaultUIDelegate.m: New stub delegate method implementation.
(-[NSApplication webView:contextMenuItemSelected:forElement:]):
* WebCoreSupport/WebContextMenuClient.h: Updated to match ContextMenuClient.h changes.
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::addCustomContextMenuItems): Updated for method name changes.
(WebContextMenuClient::contextMenuItemSelected): Added new client method.
* WebView/WebUIDelegatePrivate.h: New private delegate method declaration.
2006-11-28 Alice Liu <alice.liu@apple.com>
Reviewed by Justin and Adam.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
added the following
(WebEditorClient::smartInsertDeleteEnabled):
(WebEditorClient::dataForArchivedSelectionInFrame):
(WebEditorClient::_web_userVisibleString):
(WebEditorClient::shouldInsertNode):
* WebKitPrefix.h:
Added flags to control whether WebCore cut/copy/paste is enabled.
Turned on Cut and Copy, left Paste and Delete off
* WebView/WebHTMLViewPrivate.h:
* WebView/WebHTMLView.m:
removed _can[Cut|Copy|Paste|Delete]
(-[NSArray validateUserInterfaceItem:]):
call the editor for canDHTML[C|C|P|D] and _can[C|C|P|D] instead
(-[NSArray delete:]):
added code to call the editor's delete instead (not turned on)
(-[WebHTMLView copy:]):
added code to call the editor's copy (turned on)
(-[WebHTMLView cut:]):
added code to call the editor's cut (turned on)
(-[WebHTMLView paste:]):
added code to call the editor's paste (not turned on)
2006-11-28 Geoffrey Garen <ggaren@apple.com>
Reviewed by Adam.
Fixed <rdar://problem/4844848> REGRESSION: extra cross-library ref/deref
calls cause .5% PLT regression.
Changed ref/deref calls to a single 'xxxDestroyed' call. Moved EditorClient
from the Frame to the Page, since it's only responsible for
Webview-level delegate calls.
I don't really love this design, but it fixes the regression and allows
a single WebKit object to implement multiple client interfaces.
Layout tests pass.
2006-11-27 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
WebKit half of getting rid of the FixMes in ContextMenu.cpp
* WebCoreSupport/WebFrameLoaderClient.h: canHandleRequest takes a
ResourceRequest now.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::canHandleRequest): Same.
* WebView/WebHTMLView.m:
(-[WebHTMLView _isSelectionMisspelled]): Call into WebCore.
2006-11-27 Ada Chan <adachan@apple.com>
Reviewed by Adam.
Part of the change to move WebCoreCache into WebKit:
Added WebCache which handles emptying and enable/disabling the cache.
emptyCache and setCacheDisabled have been removed from WebCoreStatistics.
* Misc/WebCache.h: Added.
* Misc/WebCache.mm: Added.
* Misc/WebCoreStatistics.h:
* Misc/WebCoreStatistics.m:
(+[WebCoreStatistics statistics]):
* WebKit.exp:
* WebKit.xcodeproj/project.pbxproj:
2006-11-27 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam.
Move addMessageToConsole to Chrome.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::addMessageToConsole):
* WebCoreSupport/WebFrameBridge.mm:
2006-11-27 Brady Eidson <beidson@apple.com>
Reviewed by Anders
Moved unused Private SPI to Internal and pruned other unused code
* Misc/WebIconDatabase.m:
* Misc/WebIconDatabasePrivate.h:
2006-11-21 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- make the close method do a more-complete job to prevent world leaks seen when
running some of the layout tests
* WebView/WebHTMLViewInternal.h: Added declaration of -[WebHTMLViewPrivate clear].
* WebView/WebHTMLView.m:
(-[WebHTMLViewPrivate clear]): Added method to drop references to other objects.
We want to do this at "close" time, rather than waiting for deallocation time.
This is especially important for the data source, which indirectly keeps a number of
objects alive.
(-[WebHTMLView close]): Added an explicit call to clear out the data source on the
plug-in controller. Without this, we'd see the plug-in controller making calls to
a deallocated data source during the layout tests. Added a call to the new clear method
on the private object so that we release the objects at close time instead of waiting
for deallocation time.
* WebKit.xcodeproj/project.pbxproj: Let Xcode have its way with the project file,
because I can't fight the power.
2006-11-20 Samuel Weinig <sam@webkit.org>
Reviewed by Alexey.
Fix for http://bugs.webkit.org/show_bug.cgi?id=11656
Fix Windows build
* WebKit.vcproj/WebKit.vcproj: don't include directories that no
longer exist.
2006-11-19 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
WebKit side of new context menu actions.
* WebCoreSupport/WebContextMenuClient.h: These are for the
currently-WebKit-dependent menu actions.
* WebCoreSupport/WebContextMenuClient.mm:
(WebContextMenuClient::copyLinkToClipboard):
(WebContextMenuClient::downloadURL):
(WebContextMenuClient::copyImageToClipboard):
(WebContextMenuClient::searchWithSpotlight):
(WebContextMenuClient::lookUpInDictionary):
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(core): These are to convert between WebViewInsertAction and
EditorInsertAction.
(kit):
(WebEditorClient::shouldInsertText): Added implementation for
shouldInsertText.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.m:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]): Moved
_lookUpInDictionary to be within the implementation of WebHTMLView
internal.
* WebView/WebHTMLViewInternal.h: Add _lookUpInDictionaryFromMenu
* WebView/WebViewInternal.h: Add _searchWithSpotlightFromMenu
2006-11-18 Peter Kasting <pkasting@google.com>
Reviewed by Sam Weinig.
http://bugs.webkit.org/show_bug.cgi?id=11634:
Fix segfault on startup for Windows build. Also fix segfault when
typing in a URL.
* COM/WebFrame.cpp:
(WebFrame::initWithName):
=== Safari-521.31 ===
2006-11-17 Timothy Hatcher <timothy@apple.com>
Reviewed by Geoff.
<rdar://problem/4841044> Temporarily default Mail.app editable link clicking behavior, until they do it themselves
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebView.mm:
(+[WebView initialize]):
(-[WebView setPreferences:]):
2006-11-16 Peter Kasting <pkasting@google.com>
Reviewed and landed by ap.
http://bugs.webkit.org/show_bug.cgi?id=11509:
Windows build bustage.
* COM/WebFrame.cpp:
(WebFrame::initWithName):
(WebFrame::loadHTMLString):
(WebFrame::stopLoading):
(WebFrame::reload):
(WebFrame::loadDataSource):
(WebFrame::didReceiveData):
(WebFrame::receivedResponse):
(WebFrame::receivedAllData):
* COM/WebFrame.h:
* COM/WebView.cpp:
(WebView::mouseMoved):
(WebView::mouseDown):
(WebView::mouseUp):
(WebView::mouseDoubleClick):
* WebKit.vcproj/WebKit.vcproj:
2006-11-16 Anders Carlsson <acarlsson@apple.com>
Reviewed by Tim.
<rdar://problem/4841123>
REGRESSION: Crash in WebCore::Range::boundaryPointsValid when replying to a mail Message
* Misc/WebNSAttributedStringExtras.m:
(+[NSAttributedString _web_attributedStringFromRange:]):
If the range passed in is null, return null. When this function was in the bridge, it would never get called
with a null range when nothing was selected. Instead, the range would just have invalid boundary points.
2006-11-15 Adam Roben <aroben@apple.com>
Reviewed by Anders.
Added new WebContextMenuClient class to act as WebCore's ChromeClient,
and moved context menu-related code there from WebChromeClient.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
* WebCoreSupport/WebContextMenuClient.h: Added.
(WebContextMenuClient::webView):
* WebCoreSupport/WebContextMenuClient.mm: Added.
(WebContextMenuClient::create):
(WebContextMenuClient::WebContextMenuClient):
(WebContextMenuClient::ref):
(WebContextMenuClient::deref):
(WebContextMenuClient::addCustomContextMenuItems):
* WebKit.xcodeproj/project.pbxproj: Added new files.
* WebView/WebView.mm:
(-[WebView _commonInitializationWithFrameName:groupName:]):
2006-11-15 Beth Dakin <bdakin@apple.com>
& Adam Roben <aroben@apple.com>
Reviewed by Adam & Beth.
WebKit side of first cut at engine context menus. Use the client to
call into the UIDelegate.
* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::addCustomContextMenuItems):
* WebKit.xcodeproj/project.pbxproj:
2006-11-15 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Quick change of files to ObjC++ for BF cache re-write
* History/WebBackForwardList.m: Removed.
* History/WebBackForwardList.mm: Added.
* History/WebHistoryItem.m: Removed.
* History/WebHistoryItem.mm: Added.
* WebKit.xcodeproj/project.pbxproj:
2006-11-15 Brady Eidson <beidson@apple.com>
Reviewed by Sarge
SPI addition
* WebView/WebFrame.mm:
(-[WebFrame _recursive_resumeNullEventsForAllNetscapePlugins]):
* WebView/WebFrameInternal.h:
* WebView/WebFramePrivate.h:
2006-11-15 Brady Eidson <beidson@apple.com>
Reviewed by Adele
<rdar://problem/4838729> - Replace mistakenly removed SPI
* WebView/WebHTMLView.m:
(-[WebHTMLView _handleAutoscrollForMouseDragged:]):
* WebView/WebHTMLViewPrivate.h:
2006-11-15 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adele.
isTargetItem is used by DRT, so make it private instead of internal.
* History/WebHistoryItem.m:
(-[WebHistoryItem isTargetItem]):
* History/WebHistoryItemInternal.h:
* History/WebHistoryItemPrivate.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
2006-11-15 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Split much of unused WebHistoryItemPrivate.h SPI into WebHistoryItemInternal.h
* History/WebBackForwardList.m:
* History/WebHistory.m:
* History/WebHistoryItem.m:
(-[WebHistoryItem initWithURLString:title:lastVisitedTimeInterval:]):
(-[WebHistoryItem initWithURL:title:]):
(-[WebHistoryItem visitCount]):
(-[WebHistoryItem RSSFeedReferrer]):
(-[WebHistoryItem setRSSFeedReferrer:]):
(-[WebHistoryItem children]):
(-[WebHistoryItem dictionaryRepresentation]):
(-[WebHistoryItem setAlwaysAttemptToUsePageCache:]):
(+[WebHistoryItem _releaseAllPendingPageCaches]):
(-[WebHistoryItem URL]):
(-[WebHistoryItem target]):
(-[WebHistoryItem _setLastVisitedTimeInterval:]):
(-[WebHistoryItem _lastVisitedDate]):
(-[WebHistoryItem targetItem]):
* History/WebHistoryItemInternal.h: Added.
* History/WebHistoryItemPrivate.h:
* WebCoreSupport/WebFrameBridge.mm:
* WebCoreSupport/WebFrameLoaderClient.mm:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrame.mm:
* WebView/WebView.mm:
2006-11-14 Beth Dakin <bdakin@apple.com>
Reviewed by Geoff.
Moving things off the bridge and onto clients.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::selectWordBeforeMenuEvent):
(WebEditorClient::isEditable):
* WebCoreSupport/WebFrameBridge.mm:
* WebKit.xcodeproj/project.pbxproj:
2006-11-14 Timothy Hatcher <timothy@apple.com>
Reviewed by Harrison.
<rdar://problem/4766635> Safari should never follow links in editable areas (add a WebKitEditableLinkNeverLive option)
Adds an Open Link, Open Link in New Window and Copy Link to the editing context menu.
Adds a new WebKitEditableLinkNeverLive preference value that maps to WebCore's EditableLinkNeverLive.
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate menuItemWithTag:target:representedObject:]):
(-[WebDefaultUIDelegate contextMenuItemsForElement:defaultMenuItems:]):
(-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
(-[WebDefaultUIDelegate requestWithURL:includingReferrerFromFrame:]):
(-[WebDefaultUIDelegate openNewWindowWithURL:element:]):
(-[WebDefaultUIDelegate openLink:]):
* English.lproj/Localizable.strings:
* WebKit.exp:
* WebView/WebPreferences.m:
(-[WebPreferences editableLinkBehavior]):
* WebView/WebPreferencesPrivate.h:
* WebView/WebUIDelegatePrivate.h:
2006-11-14 Anders Carlsson <acarlsson@apple.com>
Turns out I wasn't forcing DWARF on the world at all,
it's now the default!
* WebKit.xcodeproj/project.pbxproj:
2006-11-14 Anders Carlsson <acarlsson@apple.com>
I must stop trying to force DWARF on the world.
* WebKit.xcodeproj/project.pbxproj:
2006-11-14 Darin Adler <darin@apple.com>
Reviewed by Anders.
- update for creation of EventHandler
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::actionDictionary):
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateMouseoverWithEvent:]):
(-[NSArray menuForEvent:]):
(-[NSArray scrollWheel:]):
(-[NSArray acceptsFirstMouse:]):
(-[NSArray shouldDelayWindowOrderingForEvent:]):
(-[NSArray mouseDown:]):
(-[NSArray mouseDragged:]):
(-[NSArray mouseUp:]):
(-[NSArray keyDown:]):
(-[NSArray keyUp:]):
(-[NSArray performKeyEquivalent:]):
(-[WebHTMLView elementAtPoint:allowShadowContent:]):
2006-11-14 Anders Carlsson <acarlsson@apple.com>
Fix build for real this time.
* WebCoreSupport/WebEditorClient.mm:
(-[WebEditCommand initWithEditCommand:WebCore::]):
(-[WebEditCommand dealloc]):
(-[WebEditCommand finalize]):
(+[WebEditCommand commandWithEditCommand:]):
(-[WebEditCommand command]):
2006-11-14 Anders Carlsson <acarlsson@apple.com>
Try fixing the build.
* WebCoreSupport/WebEditorClient.mm:
(-[WebEditorUndoTarget undoEditing:]):
(-[WebEditorUndoTarget redoEditing:]):
2006-11-14 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
Move undo/redo handling into WebEditorClient.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::WebEditorClient):
(WebEditorClient::~WebEditorClient):
(-[WebEditCommand initWithEditCommand:WebCore::]):
(-[WebEditCommand dealloc]):
(-[WebEditCommand finalize]):
(+[WebEditCommand commandWithEditCommand:]):
(-[WebEditCommand command]):
(-[WebEditorUndoTarget undoEditing:]):
(-[WebEditorUndoTarget redoEditing:]):
(undoNameForEditAction):
(WebEditorClient::registerCommandForUndoOrRedo):
(WebEditorClient::registerCommandForUndo):
(WebEditorClient::registerCommandForRedo):
(WebEditorClient::clearUndoRedoOperations):
(WebEditorClient::canUndo):
(WebEditorClient::canRedo):
(WebEditorClient::undo):
(WebEditorClient::redo):
* WebCoreSupport/WebFrameBridge.mm:
* WebKit.xcodeproj/project.pbxproj:
2006-11-14 Alexey Proskuryakov <ap@webkit.org>
Reviewed by Tim H.
http://bugs.webkit.org/show_bug.cgi?id=3387
Redundant keydown, keypress, keyup events sent for arrow keys
Added another layer of ugly hacks around AppKit event dispatching.
1. For arrow keys, keyDown: is invoked after performKeyEquivalent:, so had to store
_private->keyDownEvent in both methods, and make it persist after leaving them.
2. For Esc, AppKit calls performKeyEquivalent: with a fake event of some kind,
use [NSApp currentEvent] to check for this to prevent it from being passed to WebCore.
Test: manual-tests/arrow-key-events.html
* WebView/WebHTMLView.m:
(-[NSMutableDictionary dealloc]):
(-[NSArray keyDown:]):
(-[NSArray keyUp:]):
(-[NSArray performKeyEquivalent:]):
* WebView/WebHTMLViewInternal.h:
2006-11-12 Brady Eidson <beidson@apple.com>
Rubberstamped by Anders
Changed some #includes from <WebKit/foo.h> to "foo.h"
* History/WebBackForwardList.m:
* History/WebHistory.m:
2006-11-11 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej Stachowiak.
- Fixed loader crash by clarifying ownership of WebKit client objects.
WebCore objects own their WebKit clients, and ref and deref through
virtual methods, leaving WebKit free to use whatever client / reference-counting
implementation it likes.
WebKit on Mac just uses the same refcounting class that WebCore uses (Shared),
but other platforms may choose to do other things.
* WebCoreSupport/WebChromeClient.h:
(WebChromeClient::ref):
(WebChromeClient::deref):
(WebChromeClient::refCount):
* WebCoreSupport/WebEditorClient.h: Nixed commented-out function prototypes.
The ones in WebCore make clear what remains to be implemented. Replaced constructor
with factory function to avoid leaks.
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::create):
(WebEditorClient::WebEditorClient):
(WebEditorClient::setWebFrame):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge initMainFrameWithPage:WebCore::frameName:view:webView:]):
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
* WebCoreSupport/WebFrameLoaderClient.h: Replaced constructor with factory
function to avoid leaks.
(WebFrameLoaderClient::ref):
(WebFrameLoaderClient::deref):
(WebFrameLoaderClient::refCount):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::create):
* WebView/WebFrame.mm:
(-[WebFrame _initWithWebFrameView:webView:coreFrame:]):
=== Safari-521.30 ===
2006-11-10 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- remove some unnecessary uses of WebDataProtocol
* WebView/WebDataSource.mm: Remove the unneeded include.
* WebView/WebView.mm:
(+[WebView _canHandleRequest:]): Don't bother to check for unreachable URL here.
Any request that has one will be an applewebdata: request, which will pass the check anyway.
2006-11-10 Anders Carlsson <acarlsson@apple.com>
Reviewed by Geoff.
Update for changes to WebCore
* WebView/WebHTMLView.m:
(-[NSArray _applyStyleToSelection:withUndoAction:]):
(-[NSArray _applyParagraphStyleToSelection:withUndoAction:]):
(-[NSArray _toggleBold]):
(-[NSArray _toggleItalic]):
2006-11-09 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej, Geoff.
Call execCommand directly here instead of going through the bridge.
* WebView/WebHTMLView.m:
(-[NSArray moveBackward:]):
(-[NSArray moveBackwardAndModifySelection:]):
(-[NSArray moveDown:]):
(-[NSArray moveDownAndModifySelection:]):
(-[NSArray moveForward:]):
(-[NSArray moveForwardAndModifySelection:]):
(-[NSArray moveLeft:]):
(-[NSArray moveLeftAndModifySelection:]):
(-[NSArray moveRight:]):
(-[NSArray moveRightAndModifySelection:]):
(-[NSArray moveToBeginningOfDocument:]):
(-[NSArray moveToBeginningOfDocumentAndModifySelection:]):
(-[NSArray moveToBeginningOfSentence:]):
(-[NSArray moveToBeginningOfSentenceAndModifySelection:]):
(-[NSArray moveToBeginningOfLine:]):
(-[NSArray moveToBeginningOfLineAndModifySelection:]):
(-[NSArray moveToBeginningOfParagraph:]):
(-[NSArray moveToBeginningOfParagraphAndModifySelection:]):
(-[NSArray moveToEndOfDocument:]):
(-[NSArray moveToEndOfDocumentAndModifySelection:]):
(-[NSArray moveToEndOfSentence:]):
(-[NSArray moveToEndOfSentenceAndModifySelection:]):
(-[NSArray moveToEndOfLine:]):
(-[NSArray moveToEndOfLineAndModifySelection:]):
(-[NSArray moveToEndOfParagraph:]):
(-[NSArray moveToEndOfParagraphAndModifySelection:]):
(-[NSArray moveParagraphBackwardAndModifySelection:]):
(-[NSArray moveParagraphForwardAndModifySelection:]):
(-[NSArray moveUp:]):
(-[NSArray moveUpAndModifySelection:]):
(-[NSArray moveWordBackward:]):
(-[NSArray moveWordBackwardAndModifySelection:]):
(-[NSArray moveWordForward:]):
(-[NSArray moveWordForwardAndModifySelection:]):
(-[NSArray moveWordLeft:]):
(-[NSArray moveWordLeftAndModifySelection:]):
(-[NSArray moveWordRight:]):
(-[NSArray moveWordRightAndModifySelection:]):
2006-11-10 Brady Eidson <beidson@apple.com>
Reviewed by Darin
Took out WebIconDatabaseBridge and made WebKit call IconDatabase directly
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
(-[WebIconDatabase iconForURL:withSize:cache:]):
(-[WebIconDatabase iconURLForURL:]):
(-[WebIconDatabase defaultIconWithSize:]):
(-[WebIconDatabase defaultIconForURL:withSize:]):
(-[WebIconDatabase retainIconForURL:]):
(-[WebIconDatabase releaseIconForURL:]):
(-[WebIconDatabase setDelegate:]):
(-[WebIconDatabase removeAllIcons]):
(-[WebIconDatabase isIconExpiredForIconURL:]):
(-[WebIconDatabase _isEnabled]):
(-[WebIconDatabase _setIconData:forIconURL:]):
(-[WebIconDatabase _setHaveNoIconForIconURL:]):
(-[WebIconDatabase _setIconURL:forURL:]):
(-[WebIconDatabase _hasEntryForIconURL:]):
(-[WebIconDatabase _applicationWillTerminate:]):
(-[WebIconDatabase _resetCachedWebPreferences:]):
(-[WebIconDatabase _convertToWebCoreFormat]):
(webGetNSImage):
* Misc/WebIconDatabaseInternal.h: Added.
* Misc/WebIconDatabasePrivate.h:
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDidReceiveIcon):
* WebCoreSupport/WebIconDatabaseBridge.h: Removed.
* WebCoreSupport/WebIconDatabaseBridge.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
2006-11-09 Oliver Hunt <oliver@apple.com>
Reviewed by Brady.
Updated to make use of MimeTypeRegistry/bridge
* Misc/WebNSPasteboardExtras.m:
(-[NSPasteboard _web_writeImage:element:URL:title:archive:types:]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge determineObjectFromMIMEType:URL:]):
* WebView/WebDataSource.mm:
(-[WebDataSource _documentFragmentWithArchive:]):
* WebView/WebHTMLRepresentation.m:
(+[WebHTMLRepresentation supportedNonImageMIMETypes]):
(+[WebHTMLRepresentation supportedImageMIMETypes]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _imageExistsAtPaths:]):
(-[WebHTMLView _documentFragmentWithPaths:]):
2006-11-09 Brady Eidson <beidson@apple.com>
Reviewed by Darin
<rdar://problem/4829080>
More loader re-factoring cleanup - WebFramePolicyListener was over-released
* WebCoreSupport/WebFrameLoaderClient.h: Changed vanilla ptr to a RetainPtr<>
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDecidePolicyForMIMEType): Ditto
(WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction): Ditto
(WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction): Ditto
(WebFrameLoaderClient::dispatchWillSubmitForm): Ditto
(WebFrameLoaderClient::setUpPolicyListener): Ditto
(-[WebFramePolicyListener receivedPolicyDecision:]): Ditto
2006-11-08 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam, Oliver.
Update for changes to WebCore. Pass a specific WebFrame to WebEditorClient
instead of just passing the WebView.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::WebEditorClient):
(WebEditorClient::setWebFrame):
(WebEditorClient::isContinuousSpellCheckingEnabled):
(WebEditorClient::spellCheckerDocumentTag):
(WebEditorClient::shouldDeleteRange):
(WebEditorClient::shouldShowDeleteInterface):
(WebEditorClient::shouldApplyStyle):
(WebEditorClient::shouldBeginEditing):
(WebEditorClient::shouldEndEditing):
(WebEditorClient::didBeginEditing):
(WebEditorClient::respondToChangedContents):
(WebEditorClient::didEndEditing):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge initMainFrameWithPage:WebCore::frameName:view:webView:]):
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
2006-11-08 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam.
Move more code into editor.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::shouldBeginEditing):
(WebEditorClient::shouldEndEditing):
(WebEditorClient::didBeginEditing):
(WebEditorClient::didEndEditing):
* WebCoreSupport/WebFrameBridge.mm:
* WebView/WebHTMLView.m:
(-[NSArray indent:]):
(-[NSArray outdent:]):
* WebView/WebView.mm:
* WebView/WebViewInternal.h:
2006-11-08 Beth Dakin <bdakin@apple.com>
Reviewed by Adam.
Add WebElementIsContentEditableKey to the WebElementDictionary, and
use it!
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate
webView:contextMenuItemsForElement:defaultMenuItems:]): Use new
WebElementIsContentEditableKey.
* Misc/WebElementDictionary.m:
(+[WebElementDictionary initializeLookupTable]):
(-[WebElementDictionary _isContentEditable]): Call into
HitTestResult::isContentEditable()
* WebView/WebView.mm: Add new key.
* WebView/WebViewPrivate.h: Add new key.
2006-11-08 Anders Carlsson <acarlsson@apple.com>
Reviewed by Oliver.
Call into the WebCore editor object directly.
* MigrateHeaders.make:
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::shouldDeleteRange):
(WebEditorClient::shouldShowDeleteInterface):
(WebEditorClient::shouldApplyStyle):
* WebView/WebFrame.mm:
(core):
(kit):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.m:
(-[NSArray _applyStyleToSelection:withUndoAction:]):
(-[NSArray _applyParagraphStyleToSelection:withUndoAction:]):
(-[NSArray _toggleBold]):
(-[NSArray _toggleItalic]):
(-[NSArray _changeCSSColorUsingSelector:inRange:]):
(-[NSArray underline:]):
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]):
* WebView/WebView.mm:
(-[WebView applyStyle:]):
2006-11-08 Anders Carlsson <acarlsson@apple.com>
Reviewed by Oliver.
<rdar://problem/4825370>
REGRESSION: Selecting "Look Up In Dictionary" from contextual menu fails to open the Dictionary app
* WebView/WebHTMLView.m:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]):
Initialize the framework pointer to 0.
2006-11-07 Darin Adler <darin@apple.com>
Reviewed by Geoff.
- udpated for changes to move from Frame/FrameMac to FrameLoader
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate openNewWindowWithURL:element:]):
* Misc/WebNSAttributedStringExtras.m:
(+[NSAttributedString _web_attributedStringFromRange:]):
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView requestWithURLCString:]):
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView didStart]):
* Plugins/WebNetscapePluginStream.mm:
* Plugins/WebPluginController.mm:
(-[WebPluginController pluginView:receivedResponse:]):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::provisionalLoadStarted):
* WebView/WebFrame.mm:
(-[WebFrame _canCachePage]):
(+[WebFrame _timeOfLastCompletedLoad]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _reloadForPluginChanges]):
(-[WebFrame stopLoading]):
2006-11-07 Anders Carlsson <acarlsson@apple.com>
Reviewed by Geoff.
Use the WebCore editing enums.
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge undoNameForEditAction:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:deletionAction:granularity:]):
(-[WebHTMLView _deleteSelection]):
(-[WebHTMLView moveBackward:]):
(-[WebHTMLView moveBackwardAndModifySelection:]):
(-[WebHTMLView moveDown:]):
(-[WebHTMLView moveDownAndModifySelection:]):
(-[WebHTMLView moveForward:]):
(-[WebHTMLView moveForwardAndModifySelection:]):
(-[WebHTMLView moveLeft:]):
(-[WebHTMLView moveLeftAndModifySelection:]):
(-[WebHTMLView moveRight:]):
(-[WebHTMLView moveRightAndModifySelection:]):
(-[WebHTMLView moveToBeginningOfDocument:]):
(-[WebHTMLView moveToBeginningOfDocumentAndModifySelection:]):
(-[WebHTMLView moveToBeginningOfSentence:]):
(-[WebHTMLView moveToBeginningOfSentenceAndModifySelection:]):
(-[WebHTMLView moveToBeginningOfLine:]):
(-[WebHTMLView moveToBeginningOfLineAndModifySelection:]):
(-[WebHTMLView moveToBeginningOfParagraph:]):
(-[WebHTMLView moveToBeginningOfParagraphAndModifySelection:]):
(-[WebHTMLView moveToEndOfDocument:]):
(-[WebHTMLView moveToEndOfDocumentAndModifySelection:]):
(-[WebHTMLView moveToEndOfSentence:]):
(-[WebHTMLView moveToEndOfSentenceAndModifySelection:]):
(-[WebHTMLView moveToEndOfLine:]):
(-[WebHTMLView moveToEndOfLineAndModifySelection:]):
(-[WebHTMLView moveToEndOfParagraph:]):
(-[WebHTMLView moveToEndOfParagraphAndModifySelection:]):
(-[WebHTMLView moveParagraphBackwardAndModifySelection:]):
(-[WebHTMLView moveParagraphForwardAndModifySelection:]):
(-[WebHTMLView moveUp:]):
(-[WebHTMLView moveUpAndModifySelection:]):
(-[WebHTMLView moveWordBackward:]):
(-[WebHTMLView moveWordBackwardAndModifySelection:]):
(-[WebHTMLView moveWordForward:]):
(-[WebHTMLView moveWordForwardAndModifySelection:]):
(-[WebHTMLView moveWordLeft:]):
(-[WebHTMLView moveWordLeftAndModifySelection:]):
(-[WebHTMLView moveWordRight:]):
(-[WebHTMLView moveWordRightAndModifySelection:]):
(-[WebHTMLView pageUp:]):
(-[WebHTMLView pageDown:]):
(-[WebHTMLView pageUpAndModifySelection:]):
(-[WebHTMLView pageDownAndModifySelection:]):
(-[WebHTMLView _expandSelectionToGranularity:]):
(-[WebHTMLView selectParagraph:]):
(-[WebHTMLView selectLine:]):
(-[WebHTMLView selectSentence:]):
(-[WebHTMLView selectWord:]):
(-[WebHTMLView _applyStyleToSelection:withUndoAction:]):
(-[WebHTMLView _applyParagraphStyleToSelection:withUndoAction:]):
(-[WebHTMLView _toggleBold]):
(-[WebHTMLView _toggleItalic]):
(-[WebHTMLView pasteFont:]):
(-[WebHTMLView changeFont:]):
(-[WebHTMLView changeAttributes:]):
(-[WebHTMLView _undoActionFromColorPanelWithSelector:]):
(-[WebHTMLView changeColor:]):
(-[WebHTMLView _alignSelectionUsingCSSValue:withUndoAction:]):
(-[WebHTMLView alignCenter:]):
(-[WebHTMLView alignJustified:]):
(-[WebHTMLView alignLeft:]):
(-[WebHTMLView alignRight:]):
(-[WebHTMLView _deleteWithDirection:SelectionController::granularity:killRing:isTypingAction:]):
(-[WebHTMLView deleteForward:]):
(-[WebHTMLView deleteBackward:]):
(-[WebHTMLView deleteWordForward:]):
(-[WebHTMLView deleteWordBackward:]):
(-[WebHTMLView deleteToBeginningOfLine:]):
(-[WebHTMLView deleteToEndOfLine:]):
(-[WebHTMLView deleteToBeginningOfParagraph:]):
(-[WebHTMLView deleteToEndOfParagraph:]):
(-[WebHTMLView subscript:]):
(-[WebHTMLView superscript:]):
(-[WebHTMLView unscript:]):
(-[WebHTMLView underline:]):
(-[WebHTMLView deleteToMark:]):
(-[WebHTMLView toggleBaseWritingDirection:]):
(-[WebHTMLView changeBaseWritingDirection:]):
(-[WebHTMLView _canSmartCopyOrDelete]):
(-[WebTextCompleteController doCompletion]):
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]):
* WebView/WebView.mm:
(-[WebView setTypingStyle:]):
(-[WebView applyStyle:]):
2006-11-06 Geoffrey Garen <ggaren@apple.com>
Reviewed by Tim Hatcher.
Removed ScreenClient. It was highly unpopular, risking my midterm re-election.
None of Screen's responsibilities require up-calls to WebKit or delegates,
so WebCore can handle it all.
* WebCoreSupport/WebChromeClient.mm:
(WebChromeClient::setWindowRect):
(WebChromeClient::windowRect):
* WebCoreSupport/WebScreenClient.h: Removed.
* WebCoreSupport/WebScreenClient.mm: Removed.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebView.mm:
(-[WebView _commonInitializationWithFrameName:groupName:]):
2006-11-06 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin.
Accidentally rolled out this change when removing the WebPageBridge. Now
putting it back.
* WebView/WebView.mm:
(-[WebView _commonInitializationWithFrameName:groupName:]):
2006-11-05 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej, Darin, Anders.
Removed the Page bridge. Beefed up Chrome. Added Screen and ScreenClient.
(WebChromeClient::pageRect): It may seem weird for the page to ask the Chrome/ChromeClient
about its own dimensions. The idea here is that we're asking the Chrome how
much space it has devoted to the page. We have API for this (-webViewContentRect), but
it was documented incorrectly (even Safari used it wrong), so we don't use
it anymore. Once we fix our API/documentation, we can return to making a
delegate callback to ask for the page's size.
(WebChromeClient::createWindow): Changed to take a FrameLoadRequest with
an appropriate referrer, instead of making up its own.
(WebChromeClient::createModalDialog): Changed to take a FrameLoadRequest with
an appropriate referrer, instead of broken out parcels.
* WebCoreSupport/WebPageBridge.h: Removed. Dead Code.
* WebCoreSupport/WebPageBridge.mm: Removed. Dead Code.
* WebCoreSupport/WebScreenClient.h: Added.
* WebCoreSupport/WebScreenClient.mm: Added.
* WebView/WebView.mm: Added NULL checks for new _private->page, since
it's not NULL-safe like the bridge was, and it gets cleared before
dealloc.
2006-11-06 Graham Dennis <graham.dennis@gmail.com>
Reviewed by Tim Hatcher.
Part of patch for http://bugs.webkit.org/show_bug.cgi?id=11323
Link dragging behaviour does not obey WebKitEditableLinkBehavior WebPref
* DefaultDelegates/WebDefaultUIDelegate.m:
(-[NSApplication webView:dragSourceActionMaskForPoint:]): Logic moved to
WebHTMLView's _mayStartDragAtEventLocation
* Misc/WebElementDictionary.m: added isLiveLink
(+[WebElementDictionary initializeLookupTable]):
(-[WebElementDictionary _isLiveLink]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _mayStartDragAtEventLocation:]): Editable links should
only be followed if isLiveLink is true
(-[WebHTMLView _isMoveDrag:]): A drag of a live editable link is not
a move
(-[WebHTMLView draggingUpdatedWithDraggingInfo:actionMask:]):
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]):
* WebView/WebView.mm: added WebElementLinkIsLiveKey
* WebView/WebViewPrivate.h: ditto
2006-11-04 Maciej Stachowiak <mjs@apple.com>
Reviewed by Oliver.
- removed unneeded (and obsolete) header includes
* WebCoreSupport/WebFrameBridge.mm:
* WebView/WebFrame.mm:
2006-11-05 Darin Adler <darin@apple.com>
- WebKit part of Frame.h check-in (forgot to land it)
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge textViewWasFirstResponderAtMouseDownTime:]):
(-[WebFrameBridge shouldInterruptJavaScript]):
(-[WebFrameBridge saveDocumentState:]):
(-[WebFrameBridge previousKeyViewOutsideWebFrameViews]):
(-[WebFrameBridge valueForKey:keys:values:]):
(-[WebFrameBridge getObjectCacheSize]):
(-[WebFrameBridge startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
(-[WebFrameBridge mayStartDragAtEventLocation:]):
(-[WebFrameBridge canGoBackOrForward:]):
(-[WebFrameBridge goBackOrForward:]):
(-[WebFrameBridge print]):
(-[WebFrameBridge getAppletInView:]):
(-[WebFrameBridge pollForAppletInView:]):
(-[WebFrameBridge respondToChangedContents]):
(-[WebFrameBridge respondToChangedSelection]):
(-[WebFrameBridge setIsSelected:forView:]):
2006-11-04 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- converted more of the loader machinery to work with cross-platform
data structures instead of Macintosh-specific ones
store the computed user agent string as a WebCore::String instead
of an NSString to avoid overhead converting it every time we get it
* COM/WebFrame.cpp:
(WebFrame::initWithName):
* ChangeLog:
* Misc/WebElementDictionary.m:
(-[WebElementDictionary _image]):
(-[WebElementDictionary _targetWebFrame]):
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchWillPerformClientRedirect):
(WebFrameLoaderClient::shouldTreatURLAsSameAsCurrent):
(WebFrameLoaderClient::setTitle):
(WebFrameLoaderClient::userAgent):
(WebFrameLoaderClient::actionDictionary):
* WebCoreSupport/WebPageBridge.mm:
(WebCore::if):
* WebView/WebDataSource.mm:
(-[WebDataSource _URL]):
(-[WebDataSource _URLForHistory]):
(-[WebDataSource unreachableURL]):
* WebView/WebHTMLView.m:
(-[WebHTMLView elementAtPoint:allowShadowContent:]):
* WebView/WebPDFView.mm:
(-[WebPDFView PDFViewWillClickOnLink:withURL:]):
(-[WebPDFView _path]):
* WebView/WebView.mm:
(-[WebViewPrivate init]):
(-[WebViewPrivate dealloc]):
(-[WebViewPrivate finalize]):
(-[WebView _preferencesChangedNotification:]):
(-[WebView _cachedResponseForURL:]):
(-[WebView setApplicationNameForUserAgent:]):
(-[WebView setCustomUserAgent:]):
(-[WebView customUserAgent]):
(-[WebView userAgentForURL:]):
(-[WebView _computeUserAgent]):
(-[WebView WebCore::]):
* WebView/WebViewInternal.h:
2006-11-04 Bertrand Guiheneuf <guiheneuf@gmail.com>
Reviewed by Maciej, tweaked and landed by Alexey (using a patch by Don Gibson).
http://bugs.webkit.org/show_bug.cgi?id=11433
Fixes to get WebKit to run on Windows; implemented AffineTransformCairo.
* COM/WebFrame.cpp:
(WebFrame::initWithName):
(WebFrame::loadDataSource):
(WebFrame::receivedRedirect):
(WebFrame::receivedResponse):
(WebFrame::didReceiveData):
(WebFrame::receivedAllData):
Use resource handles now. Do not start doc loader by hand anymore.
Handle didReceiveData() callback instead of receivedData() which
is deprecated in implementation of ResourceHandleClient
* COM/WebFrame.h:
* COM/WebView.cpp:
Applied ResourceLoader --> ResourceHandle renaming
* WebKit.vcproj/WebKit.rc:
Got rid of MFC dependencies (build fix for VCExpress).
* WebKit.vcproj/WebKit.vcproj:
Added platform/graphics platform/network and platform/network/win
to headers search paths
2006-11-03 Geoffrey Garen <ggaren@apple.com>
Forgot to add these two files. Oops.
* WebCoreSupport/WebChromeClient.h: Added.
* WebCoreSupport/WebChromeClient.mm: Added.
2006-11-02 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin, Beth.
First cut at factoring Page's UIDelegate-related functions into Chrome
and ChromeClient.
Layout tests pass.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebPageBridge.mm:
* WebKit.xcodeproj/project.pbxproj:
2006-11-02 Timothy Hatcher <timothy@apple.com>
Reviewed by Brady.
Adding outdent to the WebView responder forwarding list.
Also add outdent to WebHTMLView.h and WebViewPrivate.h.
* WebView/WebHTMLView.h:
* WebView/WebViewPrivate.h:
* WebView/WebView.mm:
2006-11-01 John Sullivan <sullivan@apple.com>
Reviewed by Adam Roben
- fixed <rdar://problem/4801351> Crash reloading PDF file in new Safari (or closing a window containing a PDF file)
* WebView/WebPDFView.mm:
(-[WebPDFView initWithFrame:]):
Retain the PDFSubview in the code path where we just obtain it by asking the PDFPreviewView for it. We were
unconditionally releasing it in dealloc, but only retaining it in one of the two code paths.
2006-10-31 Mark Rowe <bdash@webkit.org>
Reviewed by Maciej.
Fix null pointer dereference while running editing/pasteboard/drag-drop-modifies-page.html
* Misc/WebElementDictionary.m:
(-[WebElementDictionary _image]): Add null check.
2006-10-31 Beth Dakin <bdakin@apple.com>
Reviewed by Maciej.
This creates local functions for the remaining WebElementDictionary
members that calls into HitTestResult instead of doing magical
things with the Objective-C DOM classes.
* ChangeLog:
* Misc/WebElementDictionary.m:
(addLookupKey): The values of the dictionary are now just
selectors. They used to be WebElementMethods which were
WebElementTargetObjects associated with selectors, but none of that
is needed any more.
(+[WebElementDictionary initializeLookupTable]): All selectors are
now local functions, no more WebElementTargetObjects.
(-[WebElementDictionary objectForKey:]): No more target objects!
(-[WebElementDictionary _domNode]): Call into HitTestResult member
variable.
(-[WebElementDictionary _altDisplayString]): Same.
(-[WebElementDictionary _image]): Same.
(-[WebElementDictionary _absoluteImageURL]): Same.
(-[WebElementDictionary _title]): Same.
(-[WebElementDictionary _absoluteLinkURL]): Same.
(-[WebElementDictionary _targetWebFrame]): Same.
(-[WebElementDictionary _titleDisplayString]): Same.
(-[WebElementDictionary _textContent]): Same.
2006-10-31 Geoffrey Garen <ggaren@apple.com>
Reviewed by Alice.
Moved some Editing code from WebKit, the bridge, and WebCore::Frame down
to WebCore::Editor.
* WebCoreSupport/WebFrameBridge.mm:
* WebView/WebHTMLView.m:
(-[WebHTMLView _shouldDeleteRange:]):
(-[WebHTMLView _canCopy]):
(-[WebHTMLView _canCut]):
(-[WebHTMLView _canDelete]):
(-[WebHTMLView _canPaste]):
(-[WebHTMLView _canEdit]):
(-[WebHTMLView _canEditRichly]):
(-[WebHTMLView _isEditable]):
(-[WebHTMLView _isSelectionInPasswordField]):
(-[NSArray validateUserInterfaceItem:]):
(-[NSArray _expandSelectionToGranularity:]):
2006-10-31 John Sullivan <sullivan@apple.com>
Reviewed by Beth and Adam
Display a tooltip when hovering over marked bad grammar.
* Misc/WebElementDictionary.m:
(+[WebElementDictionary initializeLookupTable]):
support spelling tool tip
(-[WebElementDictionary _spellingToolTip]):
new method, calls through to HitTestResult
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateMouseoverWithEvent:]):
Check for a spelling tool tip; if found, prefer it over the other possible tool tips.
Check for empty strings instead of just nil strings being, since values from
WebElementDictionary are empty strings.
* WebView/WebViewPrivate.h:
declare new string constant WebElementSpellingToolTipKey
* WebView/WebView.mm:
define new string constant WebElementSpellingToolTipKey
2006-10-31 Beth Dakin <bdakin@apple.com>
Reviewed by Maciej.
Small tweaks to WebKit because of http://bugs.webkit.org/
show_bug.cgi?id=11461 HitTestResult should be split into
HitTestRequest and HitTestResult
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.m:
(-[WebHTMLView elementAtPoint:allowShadowContent:]): The
HitTestResult initializer now just takes a point.
2006-10-31 Darin Adler <darin@apple.com>
Reviewed by Brady.
- got "action dictionary" code out of FrameLoader,
replacing with a class called NavigationAction
* WebCoreSupport/WebFrameLoaderClient.h: Changed parameter types to NavigationAction.
Made elementForEvent non-virtual. Added actionDictionary function.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction): Changed parameter type,
and used actionDictionary to make the action dictionary.
(WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction): Ditto.
(WebFrameLoaderClient::actionDictionary): Added. Code that was originally in WebCore
that creates the action dictionary (from a NavigationAction).
* WebView/WebFrame.mm: (-[WebFrame _loadItem:withLoadType:]): Use NavigationAction
instead of a dictionary for the action parameters.
2006-10-31 Marvin Decker <marv.decker@gmail.com>
Reviewed by Maciej.
- fixed "Stop and reload don't work on the WebView"
http://bugs.webkit.org/show_bug.cgi?id=11285
* COM/WebFrame.cpp:
(WebFrame::stopLoading): Implement.
* COM/WebView.cpp:
(WebView::stopLoading): ditto
(WebView::reload): ditto
2006-10-30 Darin Adler <darin@apple.com>
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]):
Fix comment.
2006-10-30 John Sullivan <sullivan@apple.com>
Reviewed by Geoff Garen
* WebView/WebHTMLView.m:
(-[NSArray checkSpelling:]):
removed code to update spelling panel; WebCore handles that now
(-[NSArray showGuessPanel:]):
ditto
2006-10-30 John Sullivan <sullivan@apple.com>
* English.lproj/WebViewEditingContextMenu.nib/info.nib:
* English.lproj/WebViewEditingContextMenu.nib/objects.nib:
Another wording change to match framework, post-Tiger:
"Check Spelling" -> "Check Document Now"
2006-10-30 John Sullivan <sullivan@apple.com>
Reviewed by Geoff Garen.
Moved spelling-related methods from bridge to EditorClient. Added one not-yet-used
grammar-related method.
* WebCoreSupport/WebEditorClient.h:
declare overrides of isContinuousSpellCheckingEnabled(), spellCheckerDocumentTag(), and new
isGrammarCheckingEnabled()
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::isContinuousSpellCheckingEnabled):
implement by calling through to WebView
(WebEditorClient::isGrammarCheckingEnabled):
ditto
(WebEditorClient::spellCheckerDocumentTag):
ditto
* WebCoreSupport/WebFrameBridge.mm:
removed bridge equivalents of these methods
2006-10-30 Geoffrey Garen <ggaren@apple.com>
Reviewed by Beth.
Fixed nil-deref crash that I saw while using TOT (not sure how to repro,
but the debugger confirmed the cause).
* WebView/WebFrame.mm:
(core): Added check for NULL bridge.
2006-10-30 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin.
Removed a number of editing and selection methods from the bridge.
I moved cross-platform editing and selection code into WebCore::Editor and
WebCore::SelectionController, respecitvely.
All of the seemingly new code here is just code grabbed from WebCore or
merged from WebCoreFrameBridge.
I changed one piece of internal API: we now pass around Ranges in places
where we used to pass around broken out components of Ranges.
I also added WebCore XPATH_SUPPORT AND SVG_SUPPORT #defines to the project.
Since we now include WebCore headers that depend on these #defines, we need
to keep in sync with them, to avoid binary incompatibility.
2006-10-30 Darin Adler <darin@apple.com>
Reviewed by John Sullivan.
- work toward removing Objective-C data types from FrameLoader.h:
removed NSDate, NSString, WebCorePageState, WebCoreResourceLoader,
and WebCoreResourceHandle
- moved bodyBackgroundColor function here from Frame
* History/WebHistoryItem.m: (+[WebHistoryItem _closeObjectsInPendingPageCaches]):
Updated for change in WebCorePageState.
* WebCoreSupport/WebFrameBridge.mm: Removed saveDocumentToPageCache method.
* WebCoreSupport/WebFrameLoaderClient.h: Changed NSDate to double.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::invalidateCurrentItemPageCache): Moved the code that was
formerly in invalidatePageCache: on the bridge here.
(WebFrameLoaderClient::dispatchWillPerformClientRedirect): Added code to make the
NSDate here.
(WebFrameLoaderClient::createPageCache): Restructured code to create the
WebCorePageState object directly instead of calling saveDocumentToPageCache on
the bridge.
* WebView/WebFrame.mm: (-[WebFrame _bodyBackgroundColor]): Rewrote this to work
directly with the DOM and renderers rather than using a function on Frame.
2006-10-29 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- added ResourceResponse class and didReceiveResponse delegate call
* WebCoreSupport/WebFrameBridge.mm: Removed no longer needed
expiresTimeForResponse: method.
2006-10-29 Darin Adler <darin@apple.com>
- update for the WebCore rename
* WebCoreSupport/WebFrameLoaderClient.mm:
* WebView/WebFrame.mm:
2006-10-29 Darin Adler <darin@apple.com>
- update for the WebCore renames
* Plugins/WebNetscapePluginStream.mm:
* Plugins/WebPluginController.mm:
* WebCoreSupport/WebFrameBridge.mm:
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::willUseArchive):
(WebFrameLoaderClient::isArchiveLoadPending):
(WebFrameLoaderClient::cancelPendingArchiveLoad):
(WebFrameLoaderClient::deliverArchivedResources):
* WebCoreSupport/WebPageBridge.mm:
(-[WebPageBridge canRunModalNow]):
* WebView/WebDocumentLoaderMac.h:
* WebView/WebFrame.mm:
* WebView/WebHTMLRepresentation.m:
* WebView/WebView.mm:
2006-10-29 Darin Adler <darin@apple.com>
Rubber stamped by Adam Roben.
- renamed WebCore's WebFrameLoaderClient to match the class name inside it
* WebCoreSupport/WebFrameBridge.mm: Update include.
* WebCoreSupport/WebFrameLoaderClient.h: Ditto.
2006-10-29 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- eliminate use of NSArray to carry form data around
(the code in this framework was actually using the NSArray to hold a single
NSData anyway, so I just went back to an NSData for now)
- also fixed http://bugs.webkit.org/show_bug.cgi?id=11444
REGRESSION (r17378): Exception (-[NSCFDictionary setObject:forKey:]:
attempt to insert nil value) when submitting a form with an empty
uninitialized field
* History/WebHistoryItem.m:
(-[WebHistoryItem _setFormInfoFromRequest:]):
(-[WebHistoryItem formData]):
* History/WebHistoryItemPrivate.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchWillSubmitForm):
* WebView/WebFrame.mm:
(-[WebFrame _loadItem:withLoadType:]):
2006-10-28 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- eliminated the use of Objective-C for the policy decider
machinery, obviating the need for WebPolicyDeciderMac
- moved the defersLoading flag from WebView to WebCore::Page
- removed unused copies of four methods that in the frame bridge;
the actually-used copies are in the page bridge
- updated for rename of PassRefPtr::release to releaseRef
* WebView/WebPolicyDeciderMac.h: Removed.
* WebView/WebPolicyDeciderMac.m: Removed.
* WebKit.xcodeproj/project.pbxproj: Updated for removal.
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView sendEvent:]):
* Plugins/WebNetscapePluginStream.mm:
* WebCoreSupport/WebFrameBridge.mm:
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(getWebView):
(WebFrameLoaderClient::WebFrameLoaderClient):
(WebFrameLoaderClient::willCloseDocument):
(WebFrameLoaderClient::dispatchDecidePolicyForMIMEType):
(WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
(WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
(WebFrameLoaderClient::cancelPolicyCheck):
(WebFrameLoaderClient::dispatchWillSubmitForm):
(WebFrameLoaderClient::setDefersLoading):
(WebFrameLoaderClient::setTitle):
(WebFrameLoaderClient::deliverArchivedResourcesAfterDelay):
(WebFrameLoaderClient::deliverArchivedResources):
(WebFrameLoaderClient::setUpPolicyListener):
(WebFrameLoaderClient::receivedPolicyDecison):
(WebFrameLoaderClient::userAgent):
(-[WebFramePolicyListener initWithWebCoreFrame:]):
(-[WebFramePolicyListener invalidate]):
(-[WebFramePolicyListener dealloc]):
(-[WebFramePolicyListener finalize]):
(-[WebFramePolicyListener receivedPolicyDecision:]):
(-[WebFramePolicyListener ignore]):
(-[WebFramePolicyListener download]):
(-[WebFramePolicyListener use]):
(-[WebFramePolicyListener continue]):
* WebCoreSupport/WebPageBridge.mm:
(-[WebPageBridge runModal]):
* WebView/WebArchiver.m:
(+[WebArchiver archiveSelectionInFrame:]):
* WebView/WebFormDelegate.h:
* WebView/WebFormDelegate.m:
(+[WebFormDelegate _sharedWebFormDelegate]):
(-[WebFormDelegate textFieldDidBeginEditing:inFrame:]):
(-[WebFormDelegate textFieldDidEndEditing:inFrame:]):
(-[WebFormDelegate textDidChangeInTextField:inFrame:]):
(-[WebFormDelegate textDidChangeInTextArea:inFrame:]):
(-[WebFormDelegate frame:sourceFrame:willSubmitForm:withValues:submissionListener:]):
* WebView/WebFrame.mm:
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _isFrameSet]):
* WebView/WebFrameInternal.h:
* WebView/WebFrameView.mm:
(-[WebFrameView _shouldDrawBorder]):
* WebView/WebHTMLView.m:
(-[NSArray knowsPageRange:]):
* WebView/WebView.mm:
(-[WebView _formDelegate]):
* WebView/WebViewInternal.h:
* WebView/WebViewPrivate.h:
2006-10-28 Adam Roben <aroben@apple.com>
Reviewed by Maciej.
Fix layout tests that broke after r17399. Mitz discovered that the
failures were caused by HitTestResult::m_point being uninitialized
much of the time. HitTestResults are now always constructed with a
point.
* WebView/WebHTMLView.m:
(-[WebHTMLView elementAtPoint:allowShadowContent:]): Pass point to
HitTestResult constructor.
2006-10-28 Beth Dakin <bdakin@apple.com>
Reviewed by Darin.
This is the WebKit half of pushing the guts of elementAtPoint and
WebElementDictionary into WebCore. Among other things, this patch
makes WebElementDictionary.m and WebHTMLView.m Objective-C++
* MigrateHeaders.make: Add DOMElementInternal.h to the list of
headers to migrate.
* Misc/WebElementDictionary.h: Replaced DOMNode, DOMElement, and
NSPoint member variables with a HitTestResult member variable.
* Misc/WebElementDictionary.m:
(addLookupKey): Formatting.
(-[WebElementDictionary initWithHitTestResult:]): Constructor just
takes a HitTestResult now and sets the member variable.
(-[WebElementDictionary dealloc]): delete HitTestResult.
(-[WebElementDictionary finalize]): Address HitTestResult.
(-[WebElementDictionary _domNode]): Use HitTestResult and call into
WebCore.
(-[WebElementDictionary objectForKey:]): Same.
(-[WebElementDictionary _webFrame]): Same.
(-[WebElementDictionary _targetWebFrame]): Same.
(-[WebElementDictionary _title]): Same.
(-[WebElementDictionary _imageRect]): Same.
(-[WebElementDictionary _isSelected]): Same.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrame.mm:
(core): Convert from DOMNode* to Node*
(kit): Convert from Node* to DOMNode*
* WebView/WebFrameInternal.h: Support for the above.
* WebView/WebHTMLView.m:
(-[WebHTMLView elementAtPoint:allowShadowContent:]): Call directly
into Frame.cpp to get HitTestResult.
2006-10-27 Maciej Stachowiak <mjs@apple.com>
Reviewed by John & Adam.
- various performance improvements for resource delegate dispatch.
- avoid any ObjC messaging when fetching the WebView
- avoid ObjC calls to WebView to get resource load delegate and impl cache
- cache actual method pointers, not just the fact that the method is present
- added a new SPI resource load delegate method which allows clients to get
just one message in case of synchronously loading from memory cache; if this
is implemented you don't get the normal delegate calls in that case.
- various other minor tweaks
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(getWebView):
(WebFrameLoaderClient::hasBackForwardList):
(WebFrameLoaderClient::resetBackForwardList):
(WebFrameLoaderClient::privateBrowsingEnabled):
(WebFrameLoaderClient::updateHistoryForStandardLoad):
(WebFrameLoaderClient::resetAfterLoadError):
(WebFrameLoaderClient::download):
(WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
(WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
(WebFrameLoaderClient::dispatchDidHandleOnloadEvents):
(WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
(WebFrameLoaderClient::dispatchDidCancelClientRedirect):
(WebFrameLoaderClient::dispatchWillPerformClientRedirect):
(WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
(WebFrameLoaderClient::dispatchWillClose):
(WebFrameLoaderClient::dispatchDidReceiveIcon):
(WebFrameLoaderClient::dispatchDidStartProvisionalLoad):
(WebFrameLoaderClient::dispatchDidReceiveTitle):
(WebFrameLoaderClient::dispatchDidCommitLoad):
(WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebFrameLoaderClient::dispatchDidFailLoad):
(WebFrameLoaderClient::dispatchDidFinishLoad):
(WebFrameLoaderClient::dispatchDidFirstLayout):
(WebFrameLoaderClient::dispatchCreatePage):
(WebFrameLoaderClient::dispatchShow):
(WebFrameLoaderClient::dispatchDecidePolicyForMIMEType):
(WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
(WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
(WebFrameLoaderClient::dispatchUnableToImplementPolicy):
(WebFrameLoaderClient::dispatchWillSubmitForm):
(WebFrameLoaderClient::dispatchDidLoadMainResource):
(WebFrameLoaderClient::progressStarted):
(WebFrameLoaderClient::progressCompleted):
(WebFrameLoaderClient::incrementProgress):
(WebFrameLoaderClient::completeProgress):
(WebFrameLoaderClient::setMainFrameDocumentReady):
(WebFrameLoaderClient::startDownload):
(WebFrameLoaderClient::willChangeTitle):
(WebFrameLoaderClient::didChangeTitle):
(WebFrameLoaderClient::mainFrameURL):
(WebFrameLoaderClient::frameLoadCompleted):
* WebCoreSupport/WebPageBridge.h:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrame.mm:
(frame):
(core):
(kit):
(getWebView):
(-[WebFrame _addBackForwardItemClippedAtTarget:]):
(-[WebFrame _canCachePage]):
(-[WebFrame _purgePageCache]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _goToItem:withLoadType:]):
(-[WebFrame _updateBackground]):
(-[WebFrame _clearSelectionInOtherFrames]):
(-[WebFrame _isMainFrame]):
(-[WebFrame webView]):
* WebView/WebResourceLoadDelegatePrivate.h: Added.
* WebView/WebView.mm:
(-[WebView _cacheResourceLoadDelegateImplementations]):
(WebViewGetResourceLoadDelegate):
(WebViewGetResourceLoadDelegateImplementations):
* WebView/WebViewInternal.h:
* WebView/WebViewPrivate.h:
2006-10-27 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej.
Moved some WebCoreFrameBridge functions into FrameLoader.
* WebView/WebFrame.mm:
(-[WebFrame _numPendingOrLoadingRequests:]):
2006-10-27 Timothy Hatcher <timothy@apple.com>
Reviewed by Beth.
Make a DerivedSource/Webkit directory to store migrated
internal headers from WebCore.
* MigrateHeaders.make:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrame.mm: import the new migrated DOM*Internal.h headers
2006-10-27 John Sullivan <sullivan@apple.com>
Reviewed by Anders
- fixed http://bugs.webkit.org/show_bug.cgi?id=11439
REGRESSION: Another page loading crash
* WebView/WebFrame.mm:
(-[WebFrame _createItem:]):
Handle nil documentLoader the way we did before ObjC->C++ changes
2006-10-27 John Sullivan <sullivan@apple.com>
Reviewed by Anders
* WebView/WebHTMLView.m:
(-[NSArray checkSpelling:]):
call advanceToNextMisspelling directly on FrameMac, bypassing bridge
(-[NSArray showGuessPanel:]):
ditto
2006-10-27 Darin Adler <darin@apple.com>
- build fix
* WebCoreSupport/WebFrameLoaderClient.mm: Corrected header file name.
2006-10-27 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- moved methods that are there just to be called by the frame loader client into the client
in an attempt to get back some of the speed we lost yesterday
* DefaultDelegates/WebDefaultResourceLoadDelegate.m:
(-[WebDefaultResourceLoadDelegate webView:resource:didReceiveAuthenticationChallenge:fromDataSource:]):
(-[WebDefaultResourceLoadDelegate webView:resource:didCancelAuthenticationChallenge:fromDataSource:]):
* WebCoreSupport/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(dataSource):
(decisionListener):
(WebFrameLoaderClient::WebFrameLoaderClient):
(WebFrameLoaderClient::hasWebView):
(WebFrameLoaderClient::hasFrameView):
(WebFrameLoaderClient::hasBackForwardList):
(WebFrameLoaderClient::resetBackForwardList):
(WebFrameLoaderClient::provisionalItemIsTarget):
(WebFrameLoaderClient::loadProvisionalItemFromPageCache):
(WebFrameLoaderClient::invalidateCurrentItemPageCache):
(WebFrameLoaderClient::privateBrowsingEnabled):
(WebFrameLoaderClient::makeDocumentView):
(WebFrameLoaderClient::makeRepresentation):
(WebFrameLoaderClient::setDocumentViewFromPageCache):
(WebFrameLoaderClient::forceLayout):
(WebFrameLoaderClient::forceLayoutForNonHTML):
(WebFrameLoaderClient::updateHistoryForCommit):
(WebFrameLoaderClient::updateHistoryForBackForwardNavigation):
(WebFrameLoaderClient::updateHistoryForReload):
(WebFrameLoaderClient::updateHistoryForStandardLoad):
(WebFrameLoaderClient::updateHistoryForInternalLoad):
(WebFrameLoaderClient::updateHistoryAfterClientRedirect):
(WebFrameLoaderClient::setCopiesOnScroll):
(WebFrameLoaderClient::tokenForLoadErrorReset):
(WebFrameLoaderClient::resetAfterLoadError):
(WebFrameLoaderClient::doNotResetAfterLoadError):
(WebFrameLoaderClient::detachedFromParent1):
(WebFrameLoaderClient::detachedFromParent2):
(WebFrameLoaderClient::detachedFromParent3):
(WebFrameLoaderClient::detachedFromParent4):
(WebFrameLoaderClient::loadedFromPageCache):
(WebFrameLoaderClient::download):
(WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
(WebFrameLoaderClient::dispatchDidHandleOnloadEvents):
(WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
(WebFrameLoaderClient::dispatchDidCancelClientRedirect):
(WebFrameLoaderClient::dispatchWillPerformClientRedirect):
(WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
(WebFrameLoaderClient::dispatchWillClose):
(WebFrameLoaderClient::dispatchDidReceiveIcon):
(WebFrameLoaderClient::dispatchDidStartProvisionalLoad):
(WebFrameLoaderClient::dispatchDidReceiveTitle):
(WebFrameLoaderClient::dispatchDidCommitLoad):
(WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebFrameLoaderClient::dispatchDidFailLoad):
(WebFrameLoaderClient::dispatchDidFinishLoad):
(WebFrameLoaderClient::dispatchDidFirstLayout):
(WebFrameLoaderClient::dispatchCreatePage):
(WebFrameLoaderClient::dispatchShow):
(WebFrameLoaderClient::dispatchDecidePolicyForMIMEType):
(WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
(WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
(WebFrameLoaderClient::dispatchUnableToImplementPolicy):
(WebFrameLoaderClient::dispatchWillSubmitForm):
(WebFrameLoaderClient::dispatchDidLoadMainResource):
(WebFrameLoaderClient::clearLoadingFromPageCache):
(WebFrameLoaderClient::isLoadingFromPageCache):
(WebFrameLoaderClient::revertToProvisionalState):
(WebFrameLoaderClient::setMainDocumentError):
(WebFrameLoaderClient::clearUnarchivingState):
(WebFrameLoaderClient::progressStarted):
(WebFrameLoaderClient::progressCompleted):
(WebFrameLoaderClient::incrementProgress):
(WebFrameLoaderClient::completeProgress):
(WebFrameLoaderClient::setMainFrameDocumentReady):
(WebFrameLoaderClient::startDownload):
(WebFrameLoaderClient::willChangeTitle):
(WebFrameLoaderClient::didChangeTitle):
(WebFrameLoaderClient::committedLoad):
(WebFrameLoaderClient::finishedLoading):
(WebFrameLoaderClient::finalSetupForReplace):
(WebFrameLoaderClient::cancelledError):
(WebFrameLoaderClient::cannotShowURLError):
(WebFrameLoaderClient::interruptForPolicyChangeError):
(WebFrameLoaderClient::cannotShowMIMETypeError):
(WebFrameLoaderClient::fileDoesNotExistError):
(WebFrameLoaderClient::shouldFallBack):
(WebFrameLoaderClient::mainFrameURL):
(WebFrameLoaderClient::setDefersCallbacks):
(WebFrameLoaderClient::willUseArchive):
(WebFrameLoaderClient::isArchiveLoadPending):
(WebFrameLoaderClient::cancelPendingArchiveLoad):
(WebFrameLoaderClient::clearArchivedResources):
(WebFrameLoaderClient::canHandleRequest):
(WebFrameLoaderClient::canShowMIMEType):
(WebFrameLoaderClient::representationExistsForURLScheme):
(WebFrameLoaderClient::generatedMIMETypeForURLScheme):
(WebFrameLoaderClient::elementForEvent):
(WebFrameLoaderClient::createPolicyDecider):
(WebFrameLoaderClient::frameLoadCompleted):
(WebFrameLoaderClient::restoreScrollPositionAndViewState):
(WebFrameLoaderClient::provisionalLoadStarted):
(WebFrameLoaderClient::shouldTreatURLAsSameAsCurrent):
(WebFrameLoaderClient::addHistoryItemForFragmentScroll):
(WebFrameLoaderClient::didFinishLoad):
(WebFrameLoaderClient::prepareForDataSourceReplacement):
(WebFrameLoaderClient::createDocumentLoader):
(WebFrameLoaderClient::setTitle):
(WebFrameLoaderClient::canUseArchivedResource):
(WebFrameLoaderClient::deliverArchivedResourcesAfterDelay):
(WebFrameLoaderClient::deliverArchivedResources):
(WebFrameLoaderClient::createPageCache):
* WebView/WebFrame.mm:
(-[NSView setWebFrame:]):
(-[WebFrame _createItem:]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _recursiveGoToItem:fromItem:withLoadType:]):
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _saveScrollPositionAndViewStateToItem:]):
(-[WebFrame _hasSelection]):
(-[WebFrame _clearSelection]):
(-[WebFrame _setProvisionalItem:]):
(-[WebFrame _setPreviousItem:]):
(-[WebFrame _setCurrentItem:]):
(-[WebFrame loadArchive:]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.m:
(-[WebHTMLView _topHTMLView]):
* WebView/WebHTMLViewPrivate.h:
2006-10-26 Geoffrey Garen <ggaren@apple.com>
Reviewed by Darin, Maciej.
Removed many uses of NSString * from WebCore.
Changed a few files to ObjC++ for compatiblity with new WebCore methods
taking WebCore::Strings as arguments.
Added a static_cast to make the c++ compiler happy.
2006-10-26 John Sullivan <sullivan@apple.com>
Reviewed by Anders
* WebView/WebFrame.mm:
now includes <WebCore/Document.h> and <WebCore/DocumentMarker.h>
(-[WebFrame _unmarkAllBadGrammar]):
filled in guts
(-[WebFrame _unmarkAllMisspellings]):
rewrote to call Document directly, bypassing bridge
2006-10-26 John Sullivan <sullivan@apple.com>
* English.lproj/WebViewEditingContextMenu.nib/info.nib:
* English.lproj/WebViewEditingContextMenu.nib/objects.nib:
Changed "Spelling" to "Spelling and Grammar" in context menu for post-Tiger.
=== Safari-521.29 ===
2006-10-26 John Sullivan <sullivan@apple.com>
No review, just two localized string changes.
* WebView/WebHTMLView.m:
(-[NSArray validateUserInterfaceItem:]):
changed "Show/Hide Spelling" to "Show/Hide Spelling and Grammar" post-Tiger to match framework change
* English.lproj/Localizable.strings:
updated for these changes
2006-10-25 Darin Adler <darin@apple.com>
Reviewed by Anders.
- removed 55 methods from WebCoreFrameBridge
- changed callers to use Frame directly instead
- put FrameLoaderTypes.h types into the WebCore namespace
- first steps to get FrameLoader.h ready for cross-platform duty
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate openNewWindowWithURL:element:]):
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView requestWithURLCString:]):
(-[WebBaseNetscapePluginView loadPluginRequest:]):
(-[WebBaseNetscapePluginView getVariable:value:]):
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView didStart]):
* Plugins/WebNetscapePluginStream.mm:
* Plugins/WebPluginContainerCheck.m:
(-[WebPluginContainerCheck _continueWithPolicy:]):
(-[WebPluginContainerCheck _isForbiddenFileLoad]):
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::shouldDeleteRange):
(WebEditorClient::shouldShowDeleteInterface):
* WebCoreSupport/WebFrameBridge.mm:
(-[WebFrameBridge webView]):
(-[WebFrameBridge finishInitializingWithFrameName:view:]):
(-[WebFrameBridge createWindowWithURL:]):
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
(-[WebFrameBridge windowObjectCleared]):
(-[WebFrameBridge createModalDialogWithURL:]):
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::dispatchCreatePage):
(WebFrameLoaderClient::dispatchWillSubmitForm):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebArchiver.m:
(+[WebArchiver archiveSelectionInFrame:]):
* WebView/WebDataSource.mm:
(-[WebDataSource _documentFragmentWithImageResource:]):
(-[WebDataSource _imageElementWithImageResource:]):
* WebView/WebEditingDelegatePrivate.h:
* WebView/WebFrame.mm:
(core):
(kit):
(-[WebFrame _createItemTreeWithTargetFrame:clippedAtTarget:]):
(-[WebFrame _canCachePage]):
(-[WebFrame _childFramesMatchItem:]):
(-[WebFrame _URLsMatchItem:]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _recursiveGoToItem:fromItem:withLoadType:]):
(-[WebFrame _viewWillMoveToHostWindow:]):
(-[WebFrame _viewDidMoveToHostWindow]):
(-[WebFrame _addChild:]):
(-[WebFrame _saveDocumentAndScrollState]):
(-[WebFrame _numPendingOrLoadingRequests:]):
(-[WebFrame _reloadForPluginChanges]):
(-[WebFrame _recursive_pauseNullEventsForAllNetscapePlugins]):
(-[WebFrame _recursive_resumeNullEventsForAllNetscapePlugins]):
(-[WebFrame _initWithWebFrameView:webView:coreFrame:]):
(-[WebFrame _documentViews]):
(-[WebFrame _updateBackground]):
(-[WebFrame _unmarkAllMisspellings]):
(-[WebFrame _hasSelection]):
(-[WebFrame _atMostOneFrameHasSelection]):
(-[WebFrame _findFrameWithSelection]):
(-[WebFrame _frameLoader]):
(-[WebFrame _isDescendantOfFrame:]):
(-[WebFrame _setShouldCreateRenderers:]):
(-[WebFrame _bodyBackgroundColor]):
(-[WebFrame init]):
(-[WebFrame initWithName:webFrameView:webView:]):
(-[WebFrame dealloc]):
(-[WebFrame finalize]):
(-[WebFrame name]):
(-[WebFrame webView]):
(-[WebFrame DOMDocument]):
(-[WebFrame frameElement]):
(-[WebFrame findFrameNamed:]):
(-[WebFrame parentFrame]):
(-[WebFrame childFrames]):
(-[WebFrame _invalidateCurrentItemPageCache]):
(-[WebFrame _dispatchCreateWebViewWithRequest:]):
(-[WebFrame _dispatchSourceFrame:willSubmitForm:withValues:submissionDecider:]):
(-[WebFrame _prepareForDataSourceReplacement]):
(-[WebFrame _provisionalLoadStarted]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation DOMDocument]):
(-[WebHTMLRepresentation attributedText]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _documentRange]):
(-[WebHTMLView _documentFragmentWithPaths:]):
(-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:chosePlainText:]):
(-[WebHTMLView _selectedRange]):
(-[WebHTMLView _updateMouseoverWithEvent:]):
(-[WebHTMLView _canEditRichly]):
(-[WebHTMLView _hasSelection]):
(-[WebHTMLView _hasSelectionOrInsertionPoint]):
(-[WebHTMLView _hasInsertionPoint]):
(-[WebHTMLView _isEditable]):
(-[WebHTMLView _isSelectionInPasswordField]):
(-[WebHTMLView _lookUpInDictionaryFromMenu:]):
(-[WebHTMLView _selectionDraggingImage]):
(-[WebHTMLView _canIncreaseSelectionListLevel]):
(-[WebHTMLView _canDecreaseSelectionListLevel]):
(-[WebHTMLView _updateActiveState]):
(-[NSArray readSelectionFromPasteboard:]):
(-[NSArray validateUserInterfaceItem:]):
(-[NSArray maintainsInactiveSelection]):
(-[NSArray menuForEvent:]):
(-[NSArray scrollWheel:]):
(-[NSArray acceptsFirstMouse:]):
(-[NSArray shouldDelayWindowOrderingForEvent:]):
(-[NSArray mouseDown:]):
(-[NSArray mouseDragged:]):
(-[NSArray mouseUp:]):
(-[NSArray keyDown:]):
(-[NSArray keyUp:]):
(-[NSArray centerSelectionInVisibleArea:]):
(-[NSArray _selectionStartFontAttributesAsRTF]):
(-[NSArray _emptyStyle]):
(-[NSArray performKeyEquivalent:]):
(-[NSArray indent:]):
(-[NSArray outdent:]):
(-[WebHTMLView cut:]):
(-[WebHTMLView paste:]):
(-[WebHTMLView _selectRangeInMarkedText:]):
(-[WebTextCompleteController doCompletion]):
(-[WebHTMLView selectionRect]):
(-[WebHTMLView selectionImageForcingWhiteText:]):
(-[WebHTMLView selectionImageRect]):
(-[WebHTMLView attributedString]):
(-[WebHTMLView _isMoveDrag]):
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]):
* WebView/WebPolicyDelegate.mm:
(-[WebPolicyDecisionListener _usePolicy:]):
(-[WebPolicyDecisionListener use]):
(-[WebPolicyDecisionListener ignore]):
(-[WebPolicyDecisionListener download]):
(-[WebPolicyDecisionListener continue]):
* WebView/WebScriptDebugDelegate.m:
(-[WebScriptCallFrame _initWithFrame:initWithWebFrame:]):
(-[WebScriptCallFrame globalObject]):
* WebView/WebView.mm:
(-[WebView _attachScriptDebuggerToAllFrames]):
(-[WebView _detachScriptDebuggerFromAllFrames]):
(-[WebView windowScriptObject]):
(incrementFrame):
(-[WebView searchFor:direction:caseSensitive:wrap:]):
(-[WebView writeSelectionWithPasteboardTypes:toPasteboard:]):
(-[WebView removeDragCaret]):
(-[WebView setScriptDebugDelegate:]):
(-[WebView scriptDebugDelegate]):
(-[WebView shouldClose]):
(-[WebView selectedDOMRange]):
(-[WebView styleDeclarationWithText:]):
2006-10-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Adam.
Renamed WebFrameLoader to FrameLoader, to match class name.
* Plugins/WebBaseNetscapePluginView.mm:
* Plugins/WebNetscapePluginStream.mm:
* Plugins/WebPluginController.mm:
* WebCoreSupport/WebFrameBridge.mm:
* WebView/WebDataSource.mm:
* WebView/WebFrame.mm:
* WebView/WebPDFView.mm:
* WebView/WebPolicyDelegate.mm:
* WebView/WebView.mm:
2006-10-25 Mark Rowe <bdash@webkit.org>
Reviewed by Anders.
Build fix for the Buildbot.
* WebView/WebHTMLView.m:
(-[NSArray _addToStyle:fontA:fontB:]): Explicit cast.
2006-10-25 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
<rdar://problem/4785575> REGRESSION: form resubmission warning occurs twice, then Safari crashes in autorelease pool
<rdar://problem/4799383> REGRESSION: Crash occurs when dismissing the "Would you like to save this password" sheet
* WebView/WebPolicyDeciderMac.m:
(-[WebPolicyDeciderMac dealloc]): release the listener, don't dealloc it
2006-10-24 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
* WebKitPrefix.h:
Include FastMalloc.h from C++ code.
2006-10-24 Darin Adler <darin@apple.com>
Reviewed by Anders.
- converted WebFrameLoaderClient to C++
- renamed frame->frameLoader() function to frame->loader()
- renamed [bridge impl] to [bridge _frame]
- removed some bridge methods
* Plugins/WebNetscapePluginStream.mm:
* WebCoreSupport/WebEditorClient.mm:
* WebCoreSupport/WebFrameLoaderClient.h: Added.
(WebFrameLoaderClient::webFrame):
* WebCoreSupport/WebFrameLoaderClient.mm: Added.
(WebFrameLoaderClient::detachFrameLoader):
(WebFrameLoaderClient::hasWebView):
(WebFrameLoaderClient::hasFrameView):
(WebFrameLoaderClient::hasBackForwardList):
(WebFrameLoaderClient::resetBackForwardList):
(WebFrameLoaderClient::provisionalItemIsTarget):
(WebFrameLoaderClient::loadProvisionalItemFromPageCache):
(WebFrameLoaderClient::invalidateCurrentItemPageCache):
(WebFrameLoaderClient::privateBrowsingEnabled):
(WebFrameLoaderClient::makeDocumentView):
(WebFrameLoaderClient::makeRepresentation):
(WebFrameLoaderClient::setDocumentViewFromPageCache):
(WebFrameLoaderClient::forceLayout):
(WebFrameLoaderClient::forceLayoutForNonHTML):
(WebFrameLoaderClient::updateHistoryForCommit):
(WebFrameLoaderClient::updateHistoryForBackForwardNavigation):
(WebFrameLoaderClient::updateHistoryForReload):
(WebFrameLoaderClient::updateHistoryForStandardLoad):
(WebFrameLoaderClient::updateHistoryForInternalLoad):
(WebFrameLoaderClient::updateHistoryAfterClientRedirect):
(WebFrameLoaderClient::setCopiesOnScroll):
(WebFrameLoaderClient::tokenForLoadErrorReset):
(WebFrameLoaderClient::resetAfterLoadError):
(WebFrameLoaderClient::doNotResetAfterLoadError):
(WebFrameLoaderClient::detachedFromParent1):
(WebFrameLoaderClient::detachedFromParent2):
(WebFrameLoaderClient::detachedFromParent3):
(WebFrameLoaderClient::detachedFromParent4):
(WebFrameLoaderClient::loadedFromPageCache):
(WebFrameLoaderClient::download):
(WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
(WebFrameLoaderClient::dispatchWillSendRequest):
(WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
(WebFrameLoaderClient::dispatchDidReceiveResponse):
(WebFrameLoaderClient::dispatchDidReceiveContentLength):
(WebFrameLoaderClient::dispatchDidFinishLoading):
(WebFrameLoaderClient::dispatchDidFailLoading):
(WebFrameLoaderClient::dispatchDidHandleOnloadEvents):
(WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
(WebFrameLoaderClient::dispatchDidCancelClientRedirect):
(WebFrameLoaderClient::dispatchWillPerformClientRedirect):
(WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
(WebFrameLoaderClient::dispatchWillClose):
(WebFrameLoaderClient::dispatchDidReceiveIcon):
(WebFrameLoaderClient::dispatchDidStartProvisionalLoad):
(WebFrameLoaderClient::dispatchDidReceiveTitle):
(WebFrameLoaderClient::dispatchDidCommitLoad):
(WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebFrameLoaderClient::dispatchDidFailLoad):
(WebFrameLoaderClient::dispatchDidFinishLoad):
(WebFrameLoaderClient::dispatchDidFirstLayout):
(WebFrameLoaderClient::dispatchCreatePage):
(WebFrameLoaderClient::dispatchShow):
(WebFrameLoaderClient::dispatchDecidePolicyForMIMEType):
(WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
(WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
(WebFrameLoaderClient::dispatchUnableToImplementPolicy):
(WebFrameLoaderClient::dispatchWillSubmitForm):
(WebFrameLoaderClient::dispatchDidLoadMainResource):
(WebFrameLoaderClient::clearLoadingFromPageCache):
(WebFrameLoaderClient::isLoadingFromPageCache):
(WebFrameLoaderClient::revertToProvisionalState):
(WebFrameLoaderClient::setMainDocumentError):
(WebFrameLoaderClient::clearUnarchivingState):
(WebFrameLoaderClient::progressStarted):
(WebFrameLoaderClient::progressCompleted):
(WebFrameLoaderClient::incrementProgress):
(WebFrameLoaderClient::completeProgress):
(WebFrameLoaderClient::setMainFrameDocumentReady):
(WebFrameLoaderClient::startDownload):
(WebFrameLoaderClient::willChangeTitle):
(WebFrameLoaderClient::didChangeTitle):
(WebFrameLoaderClient::committedLoad):
(WebFrameLoaderClient::finishedLoading):
(WebFrameLoaderClient::finalSetupForReplace):
(WebFrameLoaderClient::cancelledError):
(WebFrameLoaderClient::cannotShowURLError):
(WebFrameLoaderClient::interruptForPolicyChangeError):
(WebFrameLoaderClient::cannotShowMIMETypeError):
(WebFrameLoaderClient::fileDoesNotExistError):
(WebFrameLoaderClient::shouldFallBack):
(WebFrameLoaderClient::mainFrameURL):
(WebFrameLoaderClient::setDefersCallbacks):
(WebFrameLoaderClient::willUseArchive):
(WebFrameLoaderClient::isArchiveLoadPending):
(WebFrameLoaderClient::cancelPendingArchiveLoad):
(WebFrameLoaderClient::clearArchivedResources):
(WebFrameLoaderClient::canHandleRequest):
(WebFrameLoaderClient::canShowMIMEType):
(WebFrameLoaderClient::representationExistsForURLScheme):
(WebFrameLoaderClient::generatedMIMETypeForURLScheme):
(WebFrameLoaderClient::elementForEvent):
(WebFrameLoaderClient::createPolicyDecider):
(WebFrameLoaderClient::frameLoadCompleted):
(WebFrameLoaderClient::restoreScrollPositionAndViewState):
(WebFrameLoaderClient::provisionalLoadStarted):
(WebFrameLoaderClient::shouldTreatURLAsSameAsCurrent):
(WebFrameLoaderClient::addHistoryItemForFragmentScroll):
(WebFrameLoaderClient::didFinishLoad):
(WebFrameLoaderClient::prepareForDataSourceReplacement):
(WebFrameLoaderClient::createDocumentLoader):
(WebFrameLoaderClient::setTitle):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.mm:
(-[WebDataSource webFrame]):
* WebView/WebFrame.mm:
(frame):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _reloadForPluginChanges]):
(-[WebFrame _initWithWebFrameView:webView:bridge:]):
(-[WebFrame _frameLoader]):
(-[WebFrame provisionalDataSource]):
(-[WebFrame dataSource]):
(-[WebFrame parentFrame]):
(-[WebFrame _provisionalLoadStarted]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation finishedLoadingWithDataSource:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]):
(-[NSArray validateUserInterfaceItem:]):
(-[NSArray scrollWheel:]):
(-[NSArray acceptsFirstMouse:]):
(-[NSArray shouldDelayWindowOrderingForEvent:]):
(-[NSArray _selectionStartFontAttributesAsRTF]):
(-[NSArray changeBaseWritingDirection:]):
(-[NSArray indent:]):
(-[NSArray outdent:]):
(-[WebHTMLView copy:]):
(-[WebHTMLView cut:]):
(-[WebHTMLView paste:]):
* WebView/WebView.mm:
(-[WebView _dashboardRegions]):
(-[WebView setProhibitsMainFrameScrolling:]):
(-[WebView _setInViewSourceMode:]):
(-[WebView _inViewSourceMode]):
(-[WebView setEditable:]):
2006-10-24 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
- fixed <rdar://problem/4801331> "Spelling..." menu item should be "Show/Hide Spelling" post-Tiger, to match AppKit
* WebView/WebHTMLView.m:
(-[NSArray validateUserInterfaceItem:]):
post-Tiger, update the menu item text to "Show Spelling"/"Hide Spelling" based on whether
the spelling panel is already showing. Also, removed else's after returns, and removed
braces around one-line if clauses.
(-[NSArray showGuessPanel:]):
post-Tiger, make this item hide the spelling panel if it's already showing
* English.lproj/Localizable.strings:
updated for this change
2006-10-24 Timothy Hatcher <timothy@apple.com>
Reviewed by Anders.
<rdar://problem/4588878> 'WebHTMLView' may not respond to '-_webView'
* Misc/WebNSViewExtras.h:
* Misc/WebNSViewExtras.m:
(-[NSView _webView]):
2006-10-24 Brady Eidson <beidson@apple.com>
Reviewed by Anders
http://bugs.webkit.org/show_bug.cgi?id=11406 - Crash in [WebFrame dataSource]
In the transition to ObjC++ we lost alot of our free nil checking that we must now do manually
to prevent null dereferencing.
* WebView/WebFrame.mm:
(-[WebFrame provisionalDataSource]):
(-[WebFrame dataSource]):
2006-10-24 John Sullivan <sullivan@apple.com>
Reviewed by Darin
Initial plumbing for grammar checking. No actual grammar are checked at this time.
* English.lproj/WebViewEditingContextMenu.nib/classes.nib:
* English.lproj/WebViewEditingContextMenu.nib/info.nib:
* English.lproj/WebViewEditingContextMenu.nib/objects.nib:
Added grammar-checking item, reworded to match changes in framework. This will be used
post-Tiger.
* English.lproj/WebViewEditingContextMenuOld.nib/classes.nib: Added.
* English.lproj/WebViewEditingContextMenuOld.nib/info.nib: Added.
* English.lproj/WebViewEditingContextMenuOld.nib/objects.nib: Added.
Copy of WebViewEditingContextMenu.nib, unchanged. This will be used on Tiger.
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
Choose the right context menu based on BUILDING_ON_TIGER.
* WebView/WebPreferenceKeysPrivate.h:
declare grammar-related NSUserDefault value
* WebView/WebViewPrivate.h:
declare grammar-related methods
* WebView/WebView.mm:
declare static BOOL grammarCheckingEnabled
(-[WebViewPrivate init]):
initialize grammarCheckingEnabled to NSUserDefaults value
(-[WebView validateUserInterfaceItem:]):
validate toggleGrammarChecking: menu item
(-[WebView isGrammarCheckingEnabled]):
return value of grammarCheckingEnabled
(-[WebView setGrammarCheckingEnabled:]):
set value of grammarCheckingEnabled, call frame to remove existing bad grammar markers
(-[WebView toggleGrammarChecking:]):
flip the value
* WebView/WebFrameInternal.h:
* WebView/WebFrame.mm:
(-[WebFrame _unmarkAllBadGrammar]):
new placeholder method, does nothing yet
* WebView/WebHTMLViewInternal.h:
declare grammar-related methods
* WebView/WebHTMLView.m:
(-[NSArray validateUserInterfaceItem:]):
validate toggleGrammarChecking: menu item
(-[WebHTMLView isGrammarCheckingEnabled]):
new method, calls through to WebView
(-[WebHTMLView setGrammarCheckingEnabled:]):
ditto
(-[WebHTMLView toggleGrammarChecking:]):
ditto
* English.lproj/StringsNotToBeLocalized.txt:
Updated for these changes
* WebKit.xcodeproj/project.pbxproj:
updated for new files
2006-10-23 Darin Adler <darin@apple.com>
Reviewed by Geoff.
- converted WebDocumentLoader to C++
* Plugins/WebPluginController.mm:
(-[WebPluginController pluginView:receivedResponse:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.mm:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _mainDocumentError]):
(-[WebDataSource _URL]):
(-[WebDataSource _loadFromPageCache:]):
(-[WebDataSource _bridge]):
(-[WebDataSource _URLForHistory]):
(-[WebDataSource _documentLoader]):
(-[WebDataSource _initWithDocumentLoader:]):
(-[WebDataSource initWithRequest:]):
(-[WebDataSource data]):
(-[WebDataSource webFrame]):
(-[WebDataSource initialRequest]):
(-[WebDataSource request]):
(-[WebDataSource response]):
(-[WebDataSource textEncodingName]):
(-[WebDataSource isLoading]):
(-[WebDataSource unreachableURL]):
(-[WebDataSource webArchive]):
* WebView/WebDataSourceInternal.h:
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.mm:
(WebDocumentLoaderMac::WebDocumentLoaderMac):
(WebDocumentLoaderMac::setDataSource):
(WebDocumentLoaderMac::dataSource):
(WebDocumentLoaderMac::attachToFrame):
(WebDocumentLoaderMac::detachFromFrame):
* WebView/WebFrame.mm:
(-[WebFrame _createItem:]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _addChild:]):
(dataSource):
(-[WebFrame _dataSourceForDocumentLoader:]):
(-[WebFrame _addDocumentLoader:toUnarchiveState:]):
(-[WebFrame loadArchive:]):
(-[WebFrame _updateHistoryForReload]):
(-[WebFrame _updateHistoryForStandardLoad]):
(-[WebFrame _updateHistoryForInternalLoad]):
(-[WebFrame _dispatchIdentifierForInitialRequest:fromDocumentLoader:]):
(-[WebFrame _dispatchResource:willSendRequest:redirectResponse:fromDocumentLoader:]):
(-[WebFrame _dispatchDidReceiveAuthenticationChallenge:forResource:fromDocumentLoader:]):
(-[WebFrame _dispatchDidCancelAuthenticationChallenge:forResource:fromDocumentLoader:]):
(-[WebFrame _dispatchResource:didReceiveResponse:fromDocumentLoader:]):
(-[WebFrame _dispatchResource:didReceiveContentLength:fromDocumentLoader:]):
(-[WebFrame _dispatchResource:didFinishLoadingFromDocumentLoader:]):
(-[WebFrame _dispatchResource:didFailLoadingWithError:fromDocumentLoader:]):
(-[WebFrame _dispatchDidLoadMainResourceForDocumentLoader:]):
(-[WebFrame _clearLoadingFromPageCacheForDocumentLoader:]):
(-[WebFrame _isDocumentLoaderLoadingFromPageCache:]):
(-[WebFrame _makeRepresentationForDocumentLoader:]):
(-[WebFrame _revertToProvisionalStateForDocumentLoader:]):
(-[WebFrame _setMainDocumentError:forDocumentLoader:]):
(-[WebFrame _clearUnarchivingStateForLoader:]):
(-[WebFrame _willChangeTitleForDocument:]):
(-[WebFrame _didChangeTitleForDocument:]):
(-[WebFrame _finishedLoadingDocument:]):
(-[WebFrame _committedLoadWithDocumentLoader:data:]):
(-[WebFrame _documentLoader:setMainDocumentError:]):
(-[WebFrame _finalSetupForReplaceWithDocumentLoader:]):
(-[WebFrame _createDocumentLoaderWithRequest:]):
(-[WebFrame _provisionalLoadStarted]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation title]):
* WebView/WebView.mm:
(-[WebView _mainFrameOverrideEncoding]):
2006-10-23 Geoffrey Garen <ggaren@apple.com>
RS by Maciej.
Gave ObjC++ files .mm extension instead of .m.
* WebCoreSupport/WebPageBridge.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDocumentLoaderMac.m: Removed.
2006-10-23 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- converted WebFrameLoader to C++
* History/WebHistoryItem.m:
(+[WebHistoryItem _closeObjectsInPendingPageCaches]):
* Plugins/WebBaseNetscapePluginView.mm:
(-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
* Plugins/WebNetscapePluginStream.mm:
(-[WebNetscapePluginStream start]):
(-[WebNetscapePluginStream stop]):
* Plugins/WebPluginController.mm:
(-[WebPluginController webPlugInContainerLoadRequest:inFrame:]):
(-[WebPluginController pluginView:receivedResponse:]):
* WebCoreSupport/WebFrameBridge.h:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.mm:
(-[WebDataSource _loadFromPageCache:]):
(-[WebDataSource _webView]):
(-[WebDataSource webFrame]):
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.m:
(-[WebDocumentLoaderMac dealloc]):
(-[WebDocumentLoaderMac attachToFrame]):
(-[WebDocumentLoaderMac detachFromFrame]):
* WebView/WebFrame.mm:
(+[WebFrame _timeOfLastCompletedLoad]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _currentBackForwardListItemToResetTo]):
(-[WebFrame _itemForRestoringDocState]):
(-[WebFrame _frameLoader]):
(-[WebFrame _firstLayoutDone]):
(-[WebFrame _loadType]):
(-[WebFrame provisionalDataSource]):
(-[WebFrame dataSource]):
(-[WebFrame loadRequest:]):
(-[WebFrame loadArchive:]):
(-[WebFrame stopLoading]):
(-[WebFrame reload]):
(-[WebFrame _updateHistoryForCommit]):
(-[WebFrame _updateHistoryForReload]):
(-[WebFrame _updateHistoryForInternalLoad]):
(-[WebFrame _deliverArchivedResourcesAfterDelay]):
(-[WebFrame _willUseArchiveForRequest:originalURL:loader:]):
(-[WebFrame _deliverArchivedResources]):
(-[WebFrame _prepareForDataSourceReplacement]):
(-[WebFrame _provisionalLoadStarted]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.m:
(-[WebHTMLView _clearLastHitViewIfSelf]):
(-[WebHTMLView _updateMouseoverWithEvent:]):
(-[NSArray removeMouseMovedObserverUnconditionally]):
(-[NSArray removeMouseMovedObserver]):
(-[NSArray viewWillMoveToWindow:]):
(-[NSArray viewDidMoveToWindow]):
(-[WebHTMLView _canMakeTextSmaller]):
(-[WebHTMLView _canMakeTextLarger]):
(-[WebHTMLView _canMakeTextStandardSize]):
* WebView/WebPDFView.mm:
(-[WebPDFView PDFViewWillClickOnLink:withURL:]):
* WebView/WebView.mm:
(-[WebView _close]):
(-[WebView setDefersCallbacks:]):
(-[WebView setCustomTextEncodingName:]):
2006-10-23 Geoffrey Garen <ggaren@apple.com>
Reviewed by Bradee.
Moved some page-level operations from WebFrameBridge to WebPageBridge.
* WebCoreSupport/WebFrameBridge.m:
* WebCoreSupport/WebPageBridge.m:
(-[WebPageBridge createModalDialogWithURL:referrer:]):
(-[WebPageBridge canRunModal]):
(-[WebPageBridge canRunModalNow]):
(-[WebPageBridge runModal]):
* WebKit.xcodeproj/project.pbxproj: Made WebPageBridge.m ObjC++ to support
WebCore #includes.
2006-10-23 John Sullivan <sullivan@apple.com>
* WebKitPrefix.h:
Removed redundant definition of BUILDING_ON_TIGER that I just added. It turns out this had
already been added between the last time I updated in this tree and when I needed it locally.
2006-10-23 John Sullivan <sullivan@apple.com>
Reviewed by Anders
* WebKit.xcodeproj/project.pbxproj:
Move WebKitPrefix.h from Misc group to top level, to match WebCore
* WebKitPrefix.h:
defined BUILDING_ON_TIGER a la WebCore, in preparation for future use of post-Tiger API
2006-10-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Rename the now ObjC++ files to be .mm and remove the explicit file types.
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
* English.lproj/StringsNotToBeLocalized.txt:
* Plugins/WebBaseNetscapePluginView.m: Removed.
* Plugins/WebNetscapePluginStream.m: Removed.
* Plugins/WebPluginController.m: Removed.
* WebCoreSupport/WebFrameBridge.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m: Removed.
* WebView/WebFrame.m: Removed.
* WebView/WebFrameView.m: Removed.
* WebView/WebPDFView.m: Removed.
* WebView/WebPolicyDelegate.m: Removed.
* WebView/WebView.m: Removed.
2006-10-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Move the undef try/catch to WebKitPrefix.h and include algorithm so we get
exception_defines.h and so the undef of try/catch works.
Break off the BGRA to ARGB code into WebGraphicsExtras.c, this lets
WebBaseNetscapePluginView.m safely compile as ObjC++ and not cause the Accelerate
framework to complain about C++ exceptions being disabled.
* Misc/WebGraphicsExtras.c: Added.
(WebConvertBGRAToARGB):
* Misc/WebGraphicsExtras.h: Added.
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView _aglOffscreenImageForDrawingInRect:]):
* WebKit.xcodeproj/project.pbxproj:
* WebKitPrefix.h:
* WebView/WebView.m:
2006-10-22 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
- Add DOMHTMLFormElementPrivate.h to the project.
* MigrateHeaders.make:
2006-10-21 Darin Adler <darin@apple.com>
Reviewed by Adele.
- convert WebLoader and its 3 subclasses to C++
* Plugins/WebNetscapePluginStream.h:
* Plugins/WebNetscapePluginStream.m:
(-[WebNetscapePluginStream dealloc]):
(-[WebNetscapePluginStream finalize]):
(-[WebNetscapePluginStream start]):
(-[WebNetscapePluginStream cancelLoadWithError:]):
(-[WebNetscapePluginStream stop]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge canRunModalNow]):
* WebView/WebFrame.m:
(-[WebFramePrivate dealloc]):
(-[WebFramePrivate finalize]):
(frame): Changed from uppercase to lowercase so that it won't conflict
with the WebCore class named Frame.
(-[WebFrame _firstChildFrame]):
(-[WebFrame _lastChildFrame]):
(-[WebFrame _previousSiblingFrame]):
(-[WebFrame _nextSiblingFrame]):
(-[WebFrame _traverseNextFrameStayWithin:]):
(-[WebFrame _immediateChildFrameNamed:]):
(-[WebFrame _nextFrameWithWrap:]):
(-[WebFrame _previousFrameWithWrap:]):
(-[WebFrame findFrameNamed:]):
(-[WebFrame parentFrame]):
(-[WebFrame _dispatchSourceFrame:willSubmitForm:withValues:submissionDecider:]):
(-[WebFrame _deliverArchivedResourcesAfterDelay]):
(-[WebFrame _willUseArchiveForRequest:originalURL:loader:]):
(-[WebFrame _archiveLoadPendingForLoader:]):
(-[WebFrame _cancelPendingArchiveLoadForLoader:]):
(-[WebFrame _clearArchivedResources]):
(-[WebFrame _deliverArchivedResources]):
2006-10-21 Darin Adler <darin@apple.com>
Reviewed by Anders.
- fix http://bugs.webkit.org/show_bug.cgi?id=10328
REGRESSION: frame leak reported by buildbot
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::WebEditorClient): Don't retain the web view.
(WebEditorClient::~WebEditorClient): Don't release the web view.
(WebEditorClient::setWebView): Ditto.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge finishInitializingWithFrameName:view:]): Added. Common code for use by both
init methods below.
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]): Changed to use new method.
Also added comment pointing out design flaw -- we attach the client to the web view here,
but we need to be sure to detach in case the web view is deallocated first.
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]): Ditto.
2006-10-21 Darin Adler <darin@apple.com>
Reviewed by Adam.
- http://bugs.webkit.org/show_bug.cgi?id=11376
build scripts should invoke make with "-j" option for multiple processors
* WebKit.xcodeproj/project.pbxproj: Pass -j `sysctl -n hw.ncpu` to make.
2006-10-21 Timothy Hatcher <timothy@apple.com>
Reviewed by Geoff.
<rdar://problem/4478625> HTML Editing: Basic table editing and culling
Initial implementaltion of table deletion user interface:
* Adds a new editing delegate method, webView:shouldShowDeleteInterfaceForElement:.
* The new delegate method is called from the new shouldShowDeleteInterface EditorClient function.
* DefaultDelegates/WebDefaultEditingDelegate.m:
(-[WebDefaultEditingDelegate webView:shouldShowDeleteInterfaceForElement:]):
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::WebEditorClient):
(WebEditorClient::shouldDeleteRange):
(WebEditorClient::shouldShowDeleteInterface):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebEditingDelegatePrivate.h: Added.
2006-10-21 Alice Liu <alice.liu@apple.com>
Reviewed by Maciej.
fix leaks.
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::setWebView):
only change webview if its different
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
actually use the client allocated in the line above instead of
allocation again, duh.
2006-10-21 Alice Liu <alice.liu@apple.com>
Build fix.
* WebCoreSupport/WebEditorClient.h:
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::setWebView):
2006-10-20 Alice Liu <alice.liu@apple.com>
Reviewed by Tim Hatcher.
Fixed a problem where the webview passed to the EditorClient wasn't valid yet.
* WebCoreSupport/WebEditorClient.h:
(WebEditorClient::setWebView):
added webview setter
* WebCoreSupport/WebEditorClient.mm:
(WebEditorClient::WebEditorClient):
add default constructor
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]):
use [page webView] since _webview isn't valid yet
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
use webview setter on editorclient
2006-10-20 David Hyatt <hyatt@apple.com>
Tweak cache sizes so that they are back to the way they were,
except for < 512, which will stay doubled.
Reviewed by Tim H.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge getObjectCacheSize]):
2006-10-20 Alice Liu <alice.liu@apple.com>
Reviewed by Maciej.
Adding knowledge of EditorClient to WebKit
* WebCoreSupport/WebEditorClient.h: Added.
* WebCoreSupport/WebEditorClient.mm: Added.
(WebEditorClient::WebEditorClient):
(WebEditorClient::~WebEditorClient):
(WebEditorClient::shouldDeleteRange):
Implementation of mac EditorClient
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]):
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
create an editor client to pass down the chain of constructors
* WebKit.xcodeproj/project.pbxproj:
Added related EditorClient files
* WebKitPrefix.h:
Added tiger build flag in order to make certain private headers from webcore compile successfully
2006-10-20 Darin Adler <darin@apple.com>
- rolled out my loader change; caused world leak and possibly a plug-in crash
2006-10-20 Darin Adler <darin@apple.com>
Reviewed by Adele.
- convert WebLoader and its 3 subclasses to C++
* Plugins/WebNetscapePluginStream.h:
* Plugins/WebNetscapePluginStream.m:
(-[WebNetscapePluginStream dealloc]):
(-[WebNetscapePluginStream finalize]):
(-[WebNetscapePluginStream start]):
(-[WebNetscapePluginStream cancelLoadWithError:]):
(-[WebNetscapePluginStream stop]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge canRunModalNow]):
* WebView/WebFrame.m:
(-[WebFramePrivate dealloc]):
(-[WebFramePrivate finalize]):
(frame): Changed from uppercase to lowercase so that it won't conflict
with the WebCore class named Frame.
(-[WebFrame _firstChildFrame]):
(-[WebFrame _lastChildFrame]):
(-[WebFrame _previousSiblingFrame]):
(-[WebFrame _nextSiblingFrame]):
(-[WebFrame _traverseNextFrameStayWithin:]):
(-[WebFrame _immediateChildFrameNamed:]):
(-[WebFrame _nextFrameWithWrap:]):
(-[WebFrame _previousFrameWithWrap:]):
(-[WebFrame findFrameNamed:]):
(-[WebFrame parentFrame]):
(-[WebFrame _dispatchSourceFrame:willSubmitForm:withValues:submissionDecider:]):
(-[WebFrame _deliverArchivedResourcesAfterDelay]):
(-[WebFrame _willUseArchiveForRequest:originalURL:loader:]):
(-[WebFrame _archiveLoadPendingForLoader:]):
(-[WebFrame _cancelPendingArchiveLoadForLoader:]):
(-[WebFrame _clearArchivedResources]):
(-[WebFrame _deliverArchivedResources]):
2006-10-20 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- fixed <rdar://problem/4794935> setAcceptsMouseMovedEvents: is called for every layout,
taking ~1% on the PLT test
* WebView/WebHTMLView.m:
(-[NSArray layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]):
Don't call setAcceptsMouseMovedEvents: and WKSetNSWindowShouldPostEventNotifications() here
because this is called too often.
* WebView/WebView.m:
(-[WebView viewWillMoveToWindow:]):
Do call them here, because this is guaranteed to be called at least once for each window
containing a webview, but isn't called too often. Also restructured this method a little.
2006-10-19 Timothy Hatcher <timothy@apple.com>
Reviewed by Anders.
Bug 11366: Web Inspector should show user agent style rules
http://bugs.webkit.org/show_bug.cgi?id=11366
* WebInspector/WebInspector.m:
(-[WebInspector init]):
(-[WebInspector showOptionsMenu]):
(-[WebInspector _toggleShowUserAgentStyles:]):
* WebInspector/WebInspectorInternal.h:
* WebInspector/webInspector/inspector.js:
2006-10-19 Brady Eidson <beidson@apple.com>
Build fix - 2gig is on that pesky signed/unsigned limit...
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge getObjectCacheSize]):
2006-10-19 Brady Eidson <beidson@apple.com>
Reviewed by Hyatt.
Death to 16777216. Long live 33554432.
(Cache size changed needs to be reflected in localization file)
* English.lproj/StringsNotToBeLocalized.txt:
2006-10-19 Brady Eidson <beidson@apple.com>
Reviewed by Hyatt
Added an larger in-memory level of cache for machines with 2+gb ram
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge getObjectCacheSize]):
2006-10-19 Brady Eidson <beidson@apple.com>
Reviewed by Hyatt
Double the default memory cache size
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
2006-10-19 John Sullivan <sullivan@apple.com>
Reviewed by Kevin D and Geoff
* WebKit.xcodeproj/project.pbxproj:
version wars
Cleaned up this file, as follows:
- renamed all file-internal methods to start with underscores
- moved all file-internal methods into a FileInternal category block, and alphabetized them
- grouped all other methods by where/how they were defined (delegate methods, protocol methods, overrides, etc.)
- removed unstylish braces around one-line clauses
* WebView/WebPDFView.m:
(_applicationInfoForMIMEType):
(_PDFSelectionsAreEqual):
(+[WebPDFView supportedMIMETypes]):
(-[WebPDFView setPDFDocument:]):
(-[WebPDFView dealloc]):
(-[WebPDFView centerSelectionInVisibleArea:]):
(-[WebPDFView scrollPageDown:]):
(-[WebPDFView scrollPageUp:]):
(-[WebPDFView scrollLineDown:]):
(-[WebPDFView scrollLineUp:]):
(-[WebPDFView scrollToBeginningOfDocument:]):
(-[WebPDFView scrollToEndOfDocument:]):
(-[WebPDFView jumpToSelection:]):
(-[WebPDFView acceptsFirstResponder]):
(-[WebPDFView becomeFirstResponder]):
(-[WebPDFView hitTest:]):
(-[WebPDFView initWithFrame:]):
(-[WebPDFView menuForEvent:]):
(-[WebPDFView setNextKeyView:]):
(-[WebPDFView viewDidMoveToWindow]):
(-[WebPDFView viewWillMoveToWindow:]):
(-[WebPDFView validateUserInterfaceItem:]):
(-[WebPDFView copy:]):
(-[WebPDFView takeFindStringFromSelection:]):
(-[WebPDFView canPrintHeadersAndFooters]):
(-[WebPDFView printOperationWithPrintInfo:]):
(-[WebPDFView viewWillMoveToHostWindow:]):
(-[WebPDFView viewDidMoveToHostWindow]):
(-[WebPDFView elementAtPoint:]):
(-[WebPDFView elementAtPoint:allowShadowContent:]):
(-[WebPDFView searchFor:direction:caseSensitive:wrap:]):
(-[WebPDFView viewState]):
(-[WebPDFView setViewState:]):
(-[WebPDFView writeSelectionWithPasteboardTypes:toPasteboard:]):
(-[WebPDFView PDFViewWillClickOnLink:withURL:]):
(+[WebPDFView _PDFPreviewViewClass]):
(+[WebPDFView _PDFViewClass]):
(-[WebPDFView _anyPDFTagsFoundInMenu:]):
(-[WebPDFView _applyPDFDefaults]):
(-[WebPDFView _fakeKeyEventWithFunctionKey:]):
(-[WebPDFView _menuItemsFromPDFKitForEvent:]):
(-[WebPDFView _openWithFinder:]):
(-[WebPDFView _path]):
(-[WebPDFView _PDFSubview]):
(-[WebPDFView _pointIsInSelection:]):
(-[WebPDFView _receivedPDFKitLaunchNotification:]):
(-[WebPDFView _scaledAttributedString:]):
(-[WebPDFView _trackFirstResponder]):
(-[PDFPrefUpdatingProxy forwardInvocation:]):
(-[PDFPrefUpdatingProxy methodSignatureForSelector:]):
2006-10-19 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker
- fixed <rdar://problem/4792761> Safari should use fancier embedded PDFKit stuff when it's available
* WebKit.xcodeproj/project.pbxproj:
version wars
* WebView/WebFrameView.m:
(-[WebFrameView _makeDocumentViewForDataSource:]):
initialize document view with frame view's rect instead of empty rect. This avoids some problems when
constructing view hierarchies from nibs
* WebView/WebPreferencesPrivate.h:
declare new _usePDFPreviewView and _setUsePDFPreviewView:, used for debugging
* WebView/WebPreferenceKeysPrivate.h:
declare new preference key string
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
initialize new preference to true (we will by default use the new view if it's available)
(-[WebPreferences _usePDFPreviewView]):
new accessor for new pref
(-[WebPreferences _setUsePDFPreviewView:]):
ditto
* WebView/WebPDFView.h:
new previewView ivar
* WebView/WebPDFView.m:
(+[WebPDFView PDFPreviewViewClass]):
new method, returns class to use for fancier embedded PDFKit stuff, or nil if fancy stuff isn't available
(-[WebPDFView initWithFrame:]):
now tries to use fancier embedded PDFKit stuff if it's available and the pref is set to use it; falls back
to old behavior otherwise
(-[WebPDFView dealloc]):
release new previewView ivar (retained in initWithFrame:)
(-[WebPDFView viewWillMoveToWindow:]):
stop observing PDFKit notification when we're removed from window
(-[WebPDFView viewDidMoveToWindow]):
start observing PDFKit notification when we're added to window
(-[WebPDFView _receivedPDFKitLaunchNotification:]):
respond to this new PDFKit notification by opening the document via NSWorkspace
* English.lproj/StringsNotToBeLocalized.txt:
updated for lots of recent changes
2006-10-19 Sam Weinig <sam.weinig@gmail.com>
Reviewed by ap.
Win32 build fix.
* COM/WebFrame.cpp:
(WebFrame::initWithName):
(WebFrame::createNewWindow):
2006-10-19 Mitz Pettel <mitz@webkit.org>
Reviewed and landed by ap.
- fixed the inspector's tree popup
* WebInspector/webInspector/inspector.html:
2006-10-18 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Maciej.
Win32 build fix.
* COM/WebFrame.cpp:
(WebFrame::createNewWindow):
* COM/WebFrame.h:
2006-10-18 Anders Carlsson <acarlsson@apple.com>
Reviewed by Adam.
http://bugs.webkit.org/show_bug.cgi?id=11000
REGRESSION (r16101): css2.1/t0801-c412-hz-box-00-b-a is failing because the QuickTime plugin is taking over but not rendering the png
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge determineObjectFromMIMEType:URL:]):
Return ObjectElementFrame if the MIME type is one of the image ones we support.
2006-10-17 Justin Garcia <justin.garcia@apple.com>
Reviewed by harrison
<rdar://problem/4765600>
REGRESSION: Mail.app: smart deletion of words does not work
Regressed when we pushed selecion expansion down into WebCore. It's OK
to try a smart delete from _deleteWithDirection:, which is called by
deleteFoward: and deleteBackward: if the current selection is a
range.
* WebView/WebHTMLView.m:
(-[NSArray _deleteWithDirection:granularity:killRing:isTypingAction:]):
2006-10-13 Justin Garcia <justin.garcia@apple.com>
Reviewed by harrison
<rdar://problem/3655385>
Editing: -indent: method unimplemented
* WebView/WebHTMLView.m:
(-[NSArray validateUserInterfaceItem:]): Only allow indent:/outdent: in
richly editable areas.
(-[NSArray indent:]):
(-[NSArray outdent:]):
2006-10-13 Maciej Stachowiak <mjs@apple.com>
Not reviewed, build fix.
* icu/unicode/putil.h: Added - needed for build if you don't have apple internal headers.
2006-10-13 Maciej Stachowiak <mjs@apple.com>
Not reviewed, build fix.
* icu/unicode/ustring.h: Added - needed for build if you don't have apple internal headers.
2006-10-13 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- add a bunch of casts to get this compiling with older Xcode versions
(I used static_cast so it will be easier to find and remove these once we have completely moved
on to a new enough compiler version.)
* Plugins/WebBaseNetscapePluginView.m:
(+[WebBaseNetscapePluginView getCarbonEvent:]):
(-[WebBaseNetscapePluginView getCarbonEvent:withEvent:]):
(-[WebBaseNetscapePluginView fixWindowPort]):
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
(-[WebBaseNetscapePluginView _createWindowlessAGLContext]):
(-[WebBaseNetscapePluginView _reshapeAGLWindow]):
(-[WebBaseNetscapePluginView _aglOffscreenImageForDrawingInRect:]):
* WebKit.xcodeproj/project.pbxproj:
2006-10-13 Kevin McCullough <KMcCullough@apple.com>
Changed by Darin, reviewed by me.
* Plugins/WebNetscapePluginStream.m: Fixed case of import so we can compile on
case-sensitive file system.
2006-10-13 Darin Adler <darin@apple.com>
Reviewed by Adele.
- converted WebFormState from Objective-C to C++
* ForwardingHeaders: Added an entire copy of WebCore's forwarding headers here.
We should eventually come up with a more-elegant solution.
* WebKit.xcodeproj/project.pbxproj: Added ForwardingHeaders to the include paths.
Converted many files from Objective-C to Objective-C++. In a later check-in, I'll
rename them to .mm instead of .m. Removed C-only warning options for now. In a
later check-in I will add these back in a way that omits them for C++.
* Plugins/WebPluginContainerCheck.m: Updated for header changes.
* WebView/WebFrameInternal.h: Updated for header changes. Removed WebFrameLoaderClient category
so this file can still be used by Objective-C code (not just Objective-C++).
* WebView/WebFrame.m: Put WebFrameLoaderClient category in here.
(-[WebFrame _loadItem:withLoadType:]): Changed to use 0 instead of nil for FormState and fixed
enum code for C++ compatibility.
(-[WebFrame _initWithWebFrameView:webView:bridge:]): Added call to setFrameLoaderClient: here.
(-[WebFrame _updateHistoryForCommit]): Fixed enum code for C++ compatibility.
(-[WebFrame _updateHistoryForReload]): Ditto.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]): Removed call to setFrameLoaderClient:.
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]): Ditto.
(-[WebFrameBridge _retrieveKeyboardUIModeFromPreferences:]): Fixed enum code for C++ compatibility.
(-[WebFrameBridge runModal]): Changed code to not use "namespace" as a local variable name.
* WebView/WebPDFView.m: Added extern "C" so this can compile as Objective-C++.
2006-10-12 Maciej Stachowiak <mjs@apple.com>
Reviewed by Oliver.
- liberate more WebKit code down to WebCore
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.m:
2006-10-12 Adele Peterson <adele@apple.com>
Reviewed by Maciej.
WebKit part of fix for <rdar://problem/4450613> need a means to attach user data to any menu that is popuped up in HTML
Added private delegate method for clients that want access to a PopupMenu's NSMenu.
* DefaultDelegates/WebDefaultUIDelegate.m: (-[NSApplication webView:willPopupMenu:]):
* WebCoreSupport/WebFrameBridge.m: (-[WebFrameBridge willPopupMenu:]):
* WebView/WebUIDelegatePrivate.h:
2006-10-12 MorganL <morganl.webkit@yahoo.com>
Reviewed/landed by Adam.
Fixes http://bugs.webkit.org/show_bug.cgi?id=11264
Windows build busted
* COM/WebFrame.cpp:
(WebFrame::receivedResponse):
2006-10-11 Darin Adler <darin@apple.com>
Reviewed by Adele.
- preparations for making more code C++
* WebKitPrefix.h: Fixed ifdef so that C++ files get all the precompiled stuff
that non-C++ files get.
* Misc/WebKitLogging.h:
* Misc/WebKitSystemBits.h:
* Misc/WebLocalizableStrings.h:
* WebCoreSupport/WebSystemInterface.h:
Added extern "C".
* Misc/WebNSViewExtras.h:
* WebView/WebDataSource.m: (addTypesFromClass):
* WebView/WebFrameView.m: (addTypesFromClass):
Eliminated use of the identifier "class".
* WebView/WebView.m: (-[WebView _goToItem:withLoadType:]): Added a type cast.
* Plugins/WebBaseNetscapePluginView.m: Added lots of type casts.
2006-10-10 Brady Eidson <beidson@apple.com>
Reviewed by Maciej.
Moved WebFrameLoader into WebCoreFrameBridge
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]):
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
(-[WebFrameBridge dealloc]):
(-[WebFrameBridge setTitle:]):
(-[WebFrameBridge receivedData:textEncodingName:]):
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:]):
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:postData:]):
(-[WebFrameBridge objectLoadedFromCacheWithURL:response:data:]):
(-[WebFrameBridge syncLoadResourceWithMethod:URL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
(-[WebFrameBridge reportClientRedirectToURL:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
(-[WebFrameBridge reportClientRedirectCancelled:]):
(-[WebFrameBridge close]):
(-[WebFrameBridge loadURL:referrer:reload:userGesture:target:triggeringEvent:form:formValues:]):
(-[WebFrameBridge postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrameBridge tokenizerProcessedData]):
(-[WebFrameBridge frameDetached]):
(-[WebFrameBridge didFirstLayout]):
(-[WebFrameBridge notifyIconChanged:]):
(-[WebFrameBridge originalRequestURL]):
(-[WebFrameBridge isLoadTypeReload]):
2006-10-10 Adele Peterson <adele@apple.com>
Reviewed by Beth.
Removed handleAutoscrollForMouseDragged. Except for autoscroll caused by drag and drop, all other
autoscrolling should be done in WebCore instead of in AppKit.
* WebCoreSupport/WebFrameBridge.m:
* WebView/WebHTMLView.m:
* WebView/WebHTMLViewPrivate.h:
2006-10-10 Darin Adler <darin@apple.com>
- corrected an archive regression caused by loader refactoring
(pointed out by Graham Dennis)
* WebView/WebFrame.m: (-[WebFrame _deliverArchivedResourcesAfterDelay]):
Fix selector name.
2006-10-10 Maciej Stachowiak <mjs@apple.com>
Rubber stamped by Eric.
- moved a whole bunch of stuff over to WebCore - updated includes appropriately
* Loader/LoaderNSURLExtras.h: Removed.
* Loader/LoaderNSURLExtras.m: Removed.
* Loader/WebDataProtocol.h: Removed.
* Loader/WebDataProtocol.m: Removed.
* Loader/WebDocumentLoader.h: Removed.
* Loader/WebDocumentLoader.m: Removed.
* Loader/WebFormDataStream.h: Removed.
* Loader/WebFormDataStream.m: Removed.
* Loader/WebFormState.h: Removed.
* Loader/WebFormState.m: Removed.
* Loader/WebFrameLoader.h: Removed.
* Loader/WebFrameLoader.m: Removed.
* Loader/WebFrameLoaderClient.h: Removed.
* Loader/WebLoader.h: Removed.
* Loader/WebLoader.m: Removed.
* Loader/WebMainResourceLoader.h: Removed.
* Loader/WebMainResourceLoader.m: Removed.
* Loader/WebNetscapePlugInStreamLoader.h: Removed.
* Loader/WebNetscapePlugInStreamLoader.m: Removed.
* Loader/WebPlugInStreamLoaderDelegate.h: Removed.
* Loader/WebPolicyDecider.h: Removed.
* Loader/WebPolicyDecider.m: Removed.
* Loader/WebSubresourceLoader.h: Removed.
* Loader/WebSubresourceLoader.m: Removed.
* Misc/WebNSURLExtras.m:
* Plugins/WebBaseNetscapePluginStream.h:
* Plugins/WebBaseNetscapePluginView.m:
* Plugins/WebNetscapePluginStream.m:
* Plugins/WebPluginContainerCheck.m:
* Plugins/WebPluginController.m:
* WebCoreSupport/WebFrameBridge.m:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
* WebView/WebDocumentLoaderMac.h:
* WebView/WebFrame.m:
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.m:
* WebView/WebPolicyDeciderMac.h:
* WebView/WebPolicyDelegate.m:
* WebView/WebView.m:
2006-10-10 Mark Rowe <bdash@webkit.org>
Reviewed by Maciej.
Fix crash on launch in nightly builds after r16965.
Safari will sometimes call through to -[NSURL _webkit_canonicalize] before creating a WebView. If this happens,
InitWebCoreSystemInterface has not yet been called so the call to wkNSURLProtocolClassForReqest is via a garbage
pointer.
* Misc/WebNSURLExtras.m:
(-[NSURL _webkit_canonicalize]): Ensure InitWebCoreSystemInterface is called prior to canonicalURL.
2006-10-10 Maciej Stachowiak <mjs@apple.com>
Reviewed by Oliver.
- split out some NSURL extras to be moved to WebCore
* Loader/LoaderNSURLExtras.h: Added.
* Loader/LoaderNSURLExtras.m: Added.
(urlByRemovingComponent):
(urlByRemovingFragment):
(urlOriginalDataAsString):
(urlOriginalData):
(urlWithData):
(WebCFAutorelease):
(urlWithDataRelativeToURL):
(urlByRemovingResourceSpecifier):
(urlIsFileURL):
(stringIsFileURL):
(urlIsEmpty):
(canonicalURL):
* Loader/WebFrameLoader.m:
(-[WebFrameLoader shouldReloadForCurrent:andDestination:]):
(setHTTPReferrer):
(-[WebFrameLoader commitProvisionalLoad:]):
(-[WebFrameLoader _notifyIconChanged:]):
(-[WebFrameLoader didChangeTitleForDocument:]):
(-[WebFrameLoader checkNavigationPolicyForRequest:documentLoader:formState:andCall:withSelector:]):
(-[WebFrameLoader safeLoadURL:]):
* Misc/WebNSURLExtras.m:
(+[NSURL _web_URLWithData:]):
(+[NSURL _web_URLWithData:relativeToURL:]):
(-[NSURL _web_originalData]):
(-[NSURL _web_originalDataAsString]):
(-[NSURL _web_isEmpty]):
(-[NSURL _webkit_canonicalize]):
(-[NSURL _webkit_URLByRemovingComponent:]):
(-[NSURL _webkit_URLByRemovingFragment]):
(-[NSURL _webkit_URLByRemovingResourceSpecifier]):
(-[NSURL _webkit_isFileURL]):
(-[NSString _webkit_isFileURL]):
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
* WebKit.xcodeproj/project.pbxproj:
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- sever final WebFrame dependencies
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader initWithFrame:client:]):
(-[WebFrameLoader defersCallbacksChanged]):
(-[WebFrameLoader subframeIsLoading]):
(-[WebFrameLoader transitionToCommitted:]):
(-[WebFrameLoader detachChildren]):
(-[WebFrameLoader checkLoadComplete]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
- convert more WebFrameLoader stuff to be independent of WebFrame
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader stopLoadingSubframes]):
(-[WebFrameLoader _receivedMainResourceError:complete:]):
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader closeOldDataSources]):
(-[WebFrameLoader isHostedByObjectElement]):
(-[WebFrameLoader isLoadingMainFrame]):
(-[WebFrameLoader loadDocumentLoader:withLoadType:formState:]):
(-[WebFrameLoader transitionToCommitted:]):
(-[WebFrameLoader checkLoadCompleteForThisFrame]):
(-[WebFrameLoader continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
(-[WebFrameLoader loadRequest:inFrameNamed:]):
(-[WebFrameLoader postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrameLoader actionInformationForNavigationType:event:originalURL:]):
(-[WebFrameLoader client]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebDataSource.m:
(-[WebDataSource _webView]):
(-[WebDataSource webFrame]):
* WebView/WebFrame.m:
(-[WebFrame _dispatchCreateWebViewWithRequest:]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders and Oliver.
- move a bunch of WebFrame methods from the Internal category to the WebFrameLoader protocol
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader loadRequest:]):
(-[WebFrameLoader loadRequest:inFrameNamed:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[WebFrame loadRequest:]):
(-[WebFrame _dispatchDidCommitLoadForFrame]):
(-[WebFrame _hasFrameView]):
(-[WebFrame _frameLoadCompleted]):
(-[WebFrame _restoreScrollPositionAndViewState]):
(-[WebFrame _setTitle:forURL:]):
(-[WebFrame _createDocumentLoaderWithRequest:]):
(-[WebFrame _prepareForDataSourceReplacement]):
(-[WebFrame _didFinishLoad]):
(-[WebFrame _addHistoryItemForFragmentScroll]):
(-[WebFrame _shouldTreatURLAsSameAsCurrent:]):
(-[WebFrame _provisionalLoadStarted]):
* WebView/WebFrameInternal.h:
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Not reviewed, build fix.
- added forgotten files
* Loader/WebPolicyDecider.h: Added.
* Loader/WebPolicyDecider.m: Added.
(-[WebPolicyDecider invalidate]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
- add wrapper for WebPolicyDecisionListener so we can remove the dependency from WebFrameLoader.
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _checkContentPolicyForMIMEType:andCall:withSelector:]):
(-[WebFrameLoader cancelContentPolicy]):
(-[WebFrameLoader invalidatePendingPolicyDecisionCallingDefaultAction:]):
(-[WebFrameLoader checkNewWindowPolicyForRequest:action:frameName:formState:andCall:withSelector:]):
(-[WebFrameLoader checkNavigationPolicyForRequest:documentLoader:formState:andCall:withSelector:]):
(-[WebFrameLoader continueAfterWillSubmitForm:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
* Loader/WebFrameLoaderClient.h:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrame.m:
(-[WebFrame _createPolicyDeciderWithTarget:action:]):
(decisionListener):
(-[WebFrame _dispatchDecidePolicyForMIMEType:request:decider:]):
(-[WebFrame _dispatchDecidePolicyForNewWindowAction:request:newFrameName:decider:]):
(-[WebFrame _dispatchDecidePolicyForNavigationAction:request:decider:]):
(-[WebFrame _dispatchSourceFrame:willSubmitForm:withValues:submissionDecider:]):
* WebView/WebPolicyDeciderMac.h: Added.
* WebView/WebPolicyDeciderMac.m: Added.
(-[WebPolicyDeciderMac initWithTarget:action:]):
(-[WebPolicyDeciderMac dealloc]):
(-[WebPolicyDeciderMac decisionListener]):
(-[WebPolicyDeciderMac invalidate]):
2006-10-09 Brady Eidson <beidson@apple.com>
Reviewed by John
http://bugs.webkit.org/show_bug.cgi?id=11195
Added the WebIconDatabaseDelegate. This allows the ability to allow customization of
IconDatabase behavior in the future, starting now with the ability to override the
default icon fairly flexibly
* Misc/WebIconDatabase.h: Added setIconDatabaseDelegate:
* Misc/WebIconDatabase.m:
(-[WebIconDatabase iconForURL:withSize:cache:]): Call the delegate for the default icon if delegate is set
(-[WebIconDatabase defaultIconForURL:withSize:]): Get the default icon through the delegate if available, built-in if not
(-[WebIconDatabase setDelegate:]):
(-[WebIconDatabase delegate]):
* Misc/WebIconDatabaseDelegate.h: Added.
* Misc/WebIconDatabasePrivate.h: Added the delegate, nuked an unused class definition
* WebKit.xcodeproj/project.pbxproj:
2006-10-09 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- eliminated uses of WebResource and WebView from WebFrameLoader
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader setDefersCallbacks:]):
(-[WebFrameLoader stopLoading]):
(-[WebFrameLoader willUseArchiveForRequest:originalURL:loader:]):
(-[WebFrameLoader archiveLoadPendingForLoader:]):
(-[WebFrameLoader cancelPendingArchiveLoadForLoader:]):
(-[WebFrameLoader _canShowMIMEType:]):
(-[WebFrameLoader _representationExistsForURLScheme:]):
(-[WebFrameLoader _generatedMIMETypeForURLScheme:]):
(-[WebFrameLoader loadDocumentLoader:]):
(-[WebFrameLoader continueAfterNavigationPolicy:]):
(-[WebFrameLoader sendRemainingDelegateMessagesWithIdentifier:response:length:error:]):
(-[WebFrameLoader actionInformationForNavigationType:event:originalURL:]):
* Loader/WebFrameLoaderClient.h:
* Loader/WebMainResourceLoader.m:
(-[WebMainResourceLoader continueAfterContentPolicy:response:]):
(-[WebMainResourceLoader loadWithRequestNow:]):
* WebView/WebFrame.m:
(-[WebFramePrivate dealloc]):
(-[WebFrame loadRequest:]):
(-[WebFrame loadArchive:]):
(-[WebFrame _canUseResourceForRequest:]):
(-[WebFrame _canUseResourceWithResponse:]):
(-[WebFrame _deliverArchivedResourcesAfterDelay]):
(-[WebFrame _willUseArchiveForRequest:originalURL:loader:]):
(-[WebFrame _archiveLoadPendingForLoader:]):
(-[WebFrame _cancelPendingArchiveLoadForLoader:]):
(-[WebFrame _clearArchivedResources]):
(-[WebFrame _deliverArchivedResources]):
(-[WebFrame _setDefersCallbacks:]):
(-[WebFrame _canHandleRequest:]):
(-[WebFrame _canShowMIMEType:]):
(-[WebFrame _representationExistsForURLScheme:]):
(-[WebFrame _generatedMIMETypeForURLScheme:]):
(-[WebFrame _elementForEvent:]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- do all the stuff that setting the referrer should
* Loader/WebFrameLoader.m:
(setHTTPReferrer):
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
* WebKit.xcodeproj/project.pbxproj:
2006-10-09 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Fix to elminate WebIconDatabaseBridge.h from WebFrameLoader
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _notifyIconChanged:]):
* WebCoreSupport/WebIconDatabaseBridge.m:
(+[WebIconDatabaseBridge createInstance]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
(Was reviewed as part of a larger patch but it looks like Darin already did the rest of it)
- avoid a needless use of WebFrame
* Loader/WebFrameLoader.m:
(-[WebFrameLoader loadDocumentLoader:withLoadType:formState:]):
2006-10-09 Brady Eidson <beidson@apple.com>
A *real* fake fix for the layouttest problem until the real fix
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _notifyIconChanged:]):
2006-10-09 Brady Eidson <beidson@apple.com>
Quick layouttest fix until I make the real fix
* Loader/WebFrameLoader.m:
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- wean WebFrameLoader from WebDataSource private stuff
(actually just tweaks tot he above to make merging my future
patches easier since Darin did a lot of the same stuff)
* Loader/WebDocumentLoader.h:
* Loader/WebDocumentLoader.m:
(-[WebDocumentLoader URLForHistory]):
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader revertToProvisionalWithDocumentLoader:]):
(-[WebFrameLoader documentLoader:setMainDocumentError:]):
(-[WebFrameLoader finalSetupForReplaceWithDocumentLoader:]):
(-[WebFrameLoader didChangeTitleForDocument:]):
(-[WebFrameLoader loadDocumentLoader:withLoadType:formState:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebDataSource.m:
(-[WebDataSource _URLForHistory]):
* WebView/WebFrame.m:
(-[WebFrame _addDocumentLoader:toUnarchiveState:]):
(-[WebFrame _revertToProvisionalStateForDocumentLoader:]):
(-[WebFrame _setMainDocumentError:forDocumentLoader:]):
(-[WebFrame _clearUnarchivingStateForLoader:]):
2006-10-09 Darin Adler <darin@apple.com>
Reviewed by Brady.
- eliminated WebFrameLoader dependency on WebDataSourceInternal.h,
WebIconDatabasePrivate.h, and WebKitErrorsPrivate.h, along with
most but not all references to WebView
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader removePlugInStreamLoader:]):
(-[WebFrameLoader _receivedMainResourceError:complete:]):
(-[WebFrameLoader _notifyIconChanged:]):
(-[WebFrameLoader cancelledErrorWithRequest:]):
(-[WebFrameLoader fileDoesNotExistErrorWithResponse:]):
(-[WebFrameLoader handleUnimplementablePolicyWithError:]):
(-[WebFrameLoader cannotShowMIMETypeWithResponse:]):
(-[WebFrameLoader interruptForPolicyChangeErrorWithRequest:]):
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader finishedLoadingDocument:]):
(-[WebFrameLoader committedLoadWithDocumentLoader:data:]):
(-[WebFrameLoader revertToProvisionalWithDocumentLoader:]):
(-[WebFrameLoader documentLoader:setMainDocumentError:]):
(-[WebFrameLoader finalSetupForReplaceWithDocumentLoader:]):
(-[WebFrameLoader didChangeTitleForDocument:]):
(-[WebFrameLoader continueAfterNavigationPolicy:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader loadDocumentLoader:withLoadType:formState:]):
(-[WebFrameLoader transitionToCommitted:]):
(-[WebFrameLoader checkLoadCompleteForThisFrame]):
(-[WebFrameLoader requestFromDelegateForRequest:identifier:error:]):
(-[WebFrameLoader addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
(-[WebFrameLoader checkLoadComplete]):
* Loader/WebFrameLoaderClient.h:
* Loader/WebMainResourceLoader.m:
(-[WebMainResourceLoader continueAfterContentPolicy:response:]):
* WebView/WebFrame.m:
(-[WebFrame _addDocumentLoader:toUnarchiveState:]):
(-[WebFrame _formDelegate]):
(-[WebFrame _finishedLoadingDocument:]):
(-[WebFrame _committedLoadWithDocumentLoader:data:]):
(-[WebFrame _revertToProvisionalWithDocumentLoader:]):
(-[WebFrame _documentLoader:setMainDocumentError:]):
(-[WebFrame _finalSetupForReplaceWithDocumentLoader:]):
(-[WebFrame _URLForHistoryForDocumentLoader:]):
(-[WebFrame _cancelledErrorWithRequest:]):
(-[WebFrame _cannotShowURLErrorWithRequest:]):
(-[WebFrame _interruptForPolicyChangeErrorWithRequest:]):
(-[WebFrame _cannotShowMIMETypeErrorWithResponse:]):
(-[WebFrame _fileDoesNotExistErrorWithResponse:]):
(-[WebFrame _shouldFallBackForError:]):
(-[WebFrame _hasWebView]):
(-[WebFrame _mainFrameURL]):
* WebView/WebFrameInternal.h:
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed, landed, tweaked a bit by Darin.
- removed most uses of WebFrameBridge from WebFrameLoader
(WebCoreFrameBridge use is OK)
* Loader/WebDocumentLoader.m:
(-[WebDocumentLoader bridge]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader initWithFrame:client:]):
(-[WebFrameLoader defersCallbacksChanged]):
(-[WebFrameLoader defersCallbacks]):
(-[WebFrameLoader provisionalLoadStarted]):
(-[WebFrameLoader stopLoadingSubframes]):
(-[WebFrameLoader _willSendRequest:forResource:redirectResponse:]):
(-[WebFrameLoader _receivedMainResourceError:complete:]):
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader continueFragmentScrollAfterNavigationPolicy:formState:]):
(-[WebFrameLoader closeOldDataSources]):
(-[WebFrameLoader commitProvisionalLoad:]):
(-[WebFrameLoader bridge]):
(-[WebFrameLoader _handleFallbackContent]):
(-[WebFrameLoader _finishedLoading]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader checkNavigationPolicyForRequest:documentLoader:formState:andCall:withSelector:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader transitionToCommitted:]):
(-[WebFrameLoader continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
(-[WebFrameLoader loadRequest:inFrameNamed:]):
(-[WebFrameLoader postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrameLoader detachFromParent]):
(-[WebFrameLoader addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
(-[WebFrameLoader safeLoadURL:]):
(-[WebFrameLoader actionInformationForLoadType:isFormSubmission:event:originalURL:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]):
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
* WebView/WebFrame.m:
(-[WebFrame _atMostOneFrameHasSelection]):
* WebView/WebFrameInternal.h:
2006-10-09 Darin Adler <darin@apple.com>
Reviewed by Brady.
- removed almost all direct use of WebView from WebFrameLoader
* Loader/WebFrameLoader.m:
(-[WebFrameLoader defersCallbacksChanged]):
(-[WebFrameLoader defersCallbacks]):
(-[WebFrameLoader clearProvisionalLoad]):
(-[WebFrameLoader _willSendRequest:forResource:redirectResponse:]):
(-[WebFrameLoader _didReceiveResponse:forResource:]):
(-[WebFrameLoader _didReceiveData:contentLength:forResource:]):
(-[WebFrameLoader _didFinishLoadingForResource:]):
(-[WebFrameLoader _didFailLoadingWithError:forResource:]):
(-[WebFrameLoader closeOldDataSources]):
(-[WebFrameLoader _notifyIconChanged:]):
(-[WebFrameLoader prepareForLoadStart]):
(-[WebFrameLoader willChangeTitleForDocument:]):
(-[WebFrameLoader didChangeTitleForDocument:]):
(-[WebFrameLoader continueAfterNewWindowPolicy:]):
(-[WebFrameLoader continueAfterNavigationPolicy:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader didFirstLayout]):
(-[WebFrameLoader transitionToCommitted:]):
(-[WebFrameLoader checkLoadCompleteForThisFrame]):
(-[WebFrameLoader addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
* Loader/WebFrameLoaderClient.h:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrame.m:
(-[WebFrame _currentBackForwardListItemToResetTo]):
(-[WebFrame _hasBackForwardList]):
(-[WebFrame _resetBackForwardList]):
(-[WebFrame _dispatchDidReceiveIcon:]):
(-[WebFrame _dispatchDidStartProvisionalLoadForFrame]):
(-[WebFrame _dispatchDidCommitLoadForFrame]):
(-[WebFrame _dispatchDidFailProvisionalLoadWithError:]):
(-[WebFrame _dispatchDidFailLoadWithError:]):
(-[WebFrame _dispatchDidFinishLoadForFrame]):
(-[WebFrame _progressStarted]):
(-[WebFrame _progressCompleted]):
(-[WebFrame _incrementProgressForIdentifier:response:]):
(-[WebFrame _incrementProgressForIdentifier:data:]):
(-[WebFrame _completeProgressForIdentifier:]):
(-[WebFrame _setMainFrameDocumentReady:]):
(-[WebFrame _willChangeTitleForDocument:]):
(-[WebFrame _didChangeTitleForDocument:]):
(-[WebFrame _startDownloadWithRequest:]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Alice.
- moved WebFormState into Loader directory and tweaked to avoid WebKit dependencies
* Loader/WebDocumentLoader.h:
* Loader/WebFormState.h: Added.
* Loader/WebFormState.m: Added.
(-[WebFormState initWithForm:values:sourceFrame:]):
(-[WebFormState dealloc]):
(-[WebFormState form]):
(-[WebFormState values]):
(-[WebFormState sourceFrame]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrame.m:
* WebView/WebFrameInternal.h:
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Oliver.
- remove dependency on WebNSURLRequestExtras.h
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrameLoader addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Oliver.
- removed unneeded logging code so I can take WebKitLogging.h out and remove a WebKit dependency
* Loader/WebFrameLoader.m:
(-[WebFrameLoader setState:]):
(-[WebFrameLoader clientRedirectCancelledOrFinished:]):
(-[WebFrameLoader clientRedirectedTo:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader continueFragmentScrollAfterNavigationPolicy:formState:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader checkLoadCompleteForThisFrame]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Oliver.
- remove WebDataSource from the WebFrameLoader interface (and thereby from a lot of internal use)
* Loader/WebDocumentLoader.h:
* Loader/WebDocumentLoader.m:
(-[WebDocumentLoader dealloc]):
(-[WebDocumentLoader initialRequest]):
(-[WebDocumentLoader URL]):
(-[WebDocumentLoader unreachableURL]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader setState:]):
(-[WebFrameLoader startLoading]):
(-[WebFrameLoader startProvisionalLoad:]):
(-[WebFrameLoader clientRedirectedTo:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader opened]):
(-[WebFrameLoader commitProvisionalLoad:]):
(-[WebFrameLoader initialRequest]):
(-[WebFrameLoader _finishedLoading]):
(-[WebFrameLoader _notifyIconChanged:]):
(-[WebFrameLoader _URL]):
(-[WebFrameLoader willUseArchiveForRequest:originalURL:loader:]):
(-[WebFrameLoader _checkNavigationPolicyForRequest:andCall:withSelector:]):
(-[WebFrameLoader shouldReloadToHandleUnreachableURLFromRequest:]):
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
(-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader checkNavigationPolicyForRequest:documentLoader:formState:andCall:withSelector:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader loadDocumentLoader:withLoadType:formState:]):
(-[WebFrameLoader frameLoadCompleted]):
(-[WebFrameLoader transitionToCommitted:]):
(-[WebFrameLoader checkLoadCompleteForThisFrame]):
(-[WebFrameLoader safeLoadURL:]):
* Loader/WebFrameLoaderClient.h:
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge originalRequestURL]):
* WebView/WebDataSource.m:
(-[WebDataSource _URL]):
(-[WebDataSource dealloc]):
(-[WebDataSource initialRequest]):
(-[WebDataSource unreachableURL]):
* WebView/WebFrame.m:
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _prepareForDataSourceReplacement]):
(-[WebFrame provisionalDataSource]):
(-[WebFrame dataSource]):
(-[WebFrame _makeDocumentView]):
(-[WebFrame _updateHistoryForReload]):
(-[WebFrame _updateHistoryForStandardLoad]):
(-[WebFrame _updateHistoryForInternalLoad]):
(-[WebFrame _forceLayoutForNonHTML]):
(-[WebFrame _clearLoadingFromPageCacheForDocumentLoader:]):
(-[WebFrame _isDocumentLoaderLoadingFromPageCache:]):
(-[WebFrame _archivedSubresourceForURL:fromDocumentLoader:]):
(-[WebFrame _makeRepresentationForDocumentLoader:]):
2006-10-09 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- removed need for WebFrameLoader to now about WebDocumentLoaderMac
* Loader/WebFrameLoader.m:
(-[WebFrameLoader loadDataSource:withLoadType:formState:]):
* WebView/WebDocumentLoaderMac.h:
* WebView/WebDocumentLoaderMac.m:
(-[WebDocumentLoaderMac setFrameLoader:]):
(-[WebDocumentLoaderMac detachFromFrameLoader]):
2006-10-09 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- passed calls that require WebScriptDebugServer across the client interface
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _finishedLoading]):
(-[WebFrameLoader documentLoader:mainReceivedCompleteError:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[WebFrame _dispatchDidLoadMainResourceForDocumentLoader:]):
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- passed calls that require WebHTMLView or WebFrameView calls across
the client interface
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(isCaseInsensitiveEqual):
(isBackForwardLoadType):
(-[WebFrameLoader opened]):
(-[WebFrameLoader cancelledErrorWithRequest:]):
(-[WebFrameLoader fileDoesNotExistErrorWithResponse:]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader transitionToCommitted:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[WebFrame _forceLayout]):
(-[WebFrame _setDocumentViewFromPageCache:]):
(-[WebFrame _setCopiesOnScroll]):
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- pass remaining delegate methods across client interface
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _checkContentPolicyForMIMEType:andCall:withSelector:]):
(-[WebFrameLoader checkNewWindowPolicyForRequest:action:frameName:formState:andCall:withSelector:]):
(-[WebFrameLoader checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
(-[WebFrameLoader handleUnimplementablePolicyWithErrorCode:forURL:]):
(-[WebFrameLoader didFirstLayout]):
(-[WebFrameLoader continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[WebFrame _dispatchDidFirstLayoutInFrame]):
(-[WebFrame _dispatchCreateWebViewWithRequest:]):
(-[WebFrame _dispatchShow]):
(-[WebFrame _dispatchDecidePolicyForMIMEType:request:decisionListener:]):
(-[WebFrame _dispatchDecidePolicyForNewWindowAction:request:newFrameName:decisionListener:]):
(-[WebFrame _dispatchDecidePolicyForNavigationAction:request:decisionListener:]):
(-[WebFrame _dispatchUnableToImplementPolicyWithError:]):
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- use WebCoreSystemInterface instead of WebSystemInterface in Loader directory
* Loader/WebFrameLoader.m: Update includes.
(-[WebFrameLoader commitProvisionalLoad:]): Use wk calls istead of WK.
(-[WebFrameLoader _canUseResourceWithResponse:]): Ditto.
* WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface):
Added the three new symbols, and resorted the list.
* Loader/WebDataProtocol.m:
* Loader/WebLoader.m:
* Loader/WebMainResourceLoader.h:
* Loader/WebMainResourceLoader.m:
* Loader/WebNetscapePlugInStreamLoader.h:
* Loader/WebNetscapePlugInStreamLoader.m:
* Loader/WebSubresourceLoader.h:
* Loader/WebSubresourceLoader.m:
Changed import statements to consistently use the "" format.
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Not reviewed.
- fix accidental build break due to editing while committing
* Loader/WebFrameLoader.m:
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- move all WebFrameLoadDelegate methods across client interface
* Loader/WebFrameLoader.m:
(-[WebFrameLoader clientRedirectCancelledOrFinished:]):
(-[WebFrameLoader clientRedirectedTo:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
(-[WebFrameLoader continueFragmentScrollAfterNavigationPolicy:formState:]):
(-[WebFrameLoader closeOldDataSources]):
(-[WebFrameLoader _notifyIconChanged:]):
(-[WebFrameLoader prepareForLoadStart]):
(-[WebFrameLoader didChangeTitleForDocument:]):
(-[WebFrameLoader transitionToCommitted:]):
(-[WebFrameLoader checkLoadCompleteForThisFrame]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[WebFrame _dispatchDidCancelClientRedirectForFrame]):
(-[WebFrame _dispatchWillPerformClientRedirectToURL:delay:fireDate:]):
(-[WebFrame _dispatchDidChangeLocationWithinPageForFrame]):
(-[WebFrame _dispatchWillCloseFrame]):
(-[WebFrame _dispatchDidReceiveIcon:]):
(-[WebFrame _dispatchDidStartProvisionalLoadForFrame]):
(-[WebFrame _dispatchDidReceiveTitle:]):
(-[WebFrame _dispatchDidCommitLoadForFrame]):
(-[WebFrame _dispatchDidFailProvisionalLoadWithError:]):
(-[WebFrame _dispatchDidFailLoadWithError:]):
(-[WebFrame _dispatchDidFinishLoadForFrame]):
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- removed some of the WebKit dependencies in WebFrameLoader
* Loader/WebFrameLoader.m:
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader _downloadWithLoadingConnection:request:response:proxy:]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader didChangeTitleForDocument:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _setTitle:forURL:]):
(-[WebFrame _downloadWithLoadingConnection:request:response:proxy:]):
* WebView/WebFrameInternal.h:
- some other tweaks
* Misc/WebNSURLRequestExtras.m:
(-[NSMutableURLRequest _web_setHTTPReferrer:]):
(-[NSMutableURLRequest _web_setHTTPUserAgent:]):
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- pass all WebResourceLoadDelegate methods across client, removing need to include related headers
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _willSendRequest:forResource:redirectResponse:]):
(-[WebFrameLoader _didReceiveAuthenticationChallenge:forResource:]):
(-[WebFrameLoader _didCancelAuthenticationChallenge:forResource:]):
(-[WebFrameLoader _didReceiveResponse:forResource:]):
(-[WebFrameLoader _didReceiveData:contentLength:forResource:]):
(-[WebFrameLoader _didFinishLoadingForResource:]):
(-[WebFrameLoader _didFailLoadingWithError:forResource:]):
(-[WebFrameLoader sendRemainingDelegateMessagesWithIdentifier:response:length:error:]):
(-[WebFrameLoader requestFromDelegateForRequest:identifier:error:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[WebFrame _dispatchDidHandleOnloadEventsForFrame]):
(-[WebFrame _dispatchDidReceiveServerRedirectForProvisionalLoadForFrame]):
(-[WebFrame _dispatchIdentifierForInitialRequest:fromDocumentLoader:]):
(-[WebFrame _dispatchResource:willSendRequest:redirectResponse:fromDocumentLoader:]):
(-[WebFrame _dispatchDidReceiveAuthenticationChallenge:forResource:fromDocumentLoader:]):
(-[WebFrame _dispatchDidCancelAuthenticationChallenge:forResource:fromDocumentLoader:]):
(-[WebFrame _dispatchResource:didReceiveResponse:fromDocumentLoader:]):
(-[WebFrame _dispatchResource:didReceiveContentLength:fromDocumentLoader:]):
(-[WebFrame _dispatchResource:didFinishLoadingFromDocumentLoader:]):
(-[WebFrame _dispatchResource:didFailLoadingWithError:fromDocumentLoader:]):
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- started adding some _dispatch methods to WebFrameLoaderClient for delegate dispatch
* Loader/WebFrameLoader.m:
(-[WebFrameLoader startLoading]):
(-[WebFrameLoader didReceiveServerRedirectForProvisionalLoadForFrame]):
* Loader/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge handledOnloadEvents]):
* WebView/WebFrame.m:
(dataSource):
(-[WebFrame _dataSourceForDocumentLoader:]):
(-[WebFrame _dispatchDidHandleOnloadEventsForFrame]):
(-[WebFrame _dispatchDidReceiveServerRedirectForProvisionalLoadForFrame]):
(-[WebFrame _dispatchIdentifierForInitialRequest:fromDocumentLoader:]):
* WebView/WebFrameInternal.h:
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- moved more methods to WebFrameLoader from WebFrame
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader defersCallbacksChanged]):
(-[WebFrameLoader startLoadingMainResourceWithRequest:identifier:]):
(-[WebFrameLoader setState:]):
(-[WebFrameLoader clearProvisionalLoad]):
(-[WebFrameLoader markLoadComplete]):
(-[WebFrameLoader commitProvisionalLoad]):
(-[WebFrameLoader stopLoading]):
(-[WebFrameLoader startProvisionalLoad:]):
(-[WebFrameLoader setupForReplace]):
(-[WebFrameLoader _identifierForInitialRequest:]):
(-[WebFrameLoader _finishedLoadingResource]):
(-[WebFrameLoader _receivedError:]):
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader continueFragmentScrollAfterNavigationPolicy:formState:]):
(-[WebFrameLoader opened]):
(-[WebFrameLoader commitProvisionalLoad:]):
(-[WebFrameLoader _finishedLoading]):
(-[WebFrameLoader willUseArchiveForRequest:originalURL:loader:]):
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader documentLoader:mainReceivedCompleteError:]):
(-[WebFrameLoader subframeIsLoading]):
(-[WebFrameLoader checkNewWindowPolicyForRequest:action:frameName:formState:andCall:withSelector:]):
(-[WebFrameLoader continueAfterNewWindowPolicy:]):
(-[WebFrameLoader checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
(-[WebFrameLoader sendRemainingDelegateMessagesWithIdentifier:response:length:error:]):
(-[WebFrameLoader loadRequest:inFrameNamed:]):
(-[WebFrameLoader postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrameLoader detachChildren]):
(-[WebFrameLoader detachFromParent]):
(-[WebFrameLoader addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
(-[WebFrameLoader safeLoadURL:]):
(-[WebFrameLoader actionInformationForLoadType:isFormSubmission:event:originalURL:]):
(-[WebFrameLoader actionInformationForNavigationType:event:originalURL:]):
(-[WebFrameLoader checkLoadComplete]):
* Loader/WebFrameLoaderClient.h:
* Loader/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forFrameLoader:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge close]):
(-[WebFrameBridge tokenizerProcessedData]):
(-[WebFrameBridge frameDetached]):
* WebView/WebDataSourceInternal.h:
* WebView/WebFrame.m:
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _prepareForDataSourceReplacement]):
(-[WebFrame _detachedFromParent1]):
(-[WebFrame _detachedFromParent2]):
(-[WebFrame _detachedFromParent3]):
(-[WebFrame _detachedFromParent4]):
(-[WebFrame _updateHistoryAfterClientRedirect]):
(-[WebFrame _loadedFromPageCache]):
* WebView/WebFrameInternal.h:
* WebView/WebPDFView.m:
(-[WebPDFView PDFViewWillClickOnLink:withURL:]):
* WebView/WebView.m:
(-[WebView _close]):
(-[WebView setDefersCallbacks:]):
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- avoid need for WebKitSystemInterface in loader code, via WebCore cover for wkSupportsMultipartXMixedReplace
* Loader/WebDocumentLoader.m:
(-[WebDocumentLoader initWithRequest:]):
* Loader/WebMainResourceLoader.m:
* Loader/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forFrameLoader:]):
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
* WebView/WebDataSource.m:
(-[WebDataSource _initWithDocumentLoader:]):
2006-10-08 Darin Adler <darin@apple.com>
- build fix (also a fix for a crasher I forgot to commit before)
* Loader/WebFrameLoader.m: Added some missing includes.
(-[WebFrameLoader checkLoadCompleteForThisFrame]):
Added a needed retain/release.
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Anders.
- quick fix to loader problem causing layout test failures
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _finishedLoading]): Use a local variable for the bridge
that we retain/release.
(-[WebFrameLoader continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
Same here.
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adam.
- removed a few includes from WebFrameLoader, fixed up as appropriate
- segregated header includes into ones that need to go away to move the code and ones that don't
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _privateBrowsingEnabled]):
(-[WebFrameLoader willUseArchiveForRequest:originalURL:loader:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[WebFrame _privateBrowsingEnabled]):
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- moved a few methods from WebFrame to WebFrameLoader
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _setState:]):
(-[WebFrameLoader stopLoadingSubframes]):
(-[WebFrameLoader _receivedMainResourceError:complete:]):
(-[WebFrameLoader closeOldDataSources]):
(-[WebFrameLoader commitProvisionalLoad:]):
(-[WebFrameLoader _finishedLoading]):
(isBackForwardLoadType):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader didFirstLayout]):
(-[WebFrameLoader frameLoadCompleted]):
(-[WebFrameLoader transitionToCommitted:]):
(-[WebFrameLoader checkLoadCompleteForThisFrame]):
(-[WebFrameLoader continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
(-[WebFrameLoader sendRemainingDelegateMessagesWithIdentifier:response:length:error:]):
(-[WebFrameLoader requestFromDelegateForRequest:identifier:error:]):
(-[WebFrameLoader loadRequest:inFrameNamed:]):
(-[WebFrameLoader postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
* Loader/WebFrameLoaderClient.h:
* Plugins/WebPluginController.m:
(-[WebPluginController webPlugInContainerLoadRequest:inFrame:]):
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]):
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
(-[WebFrameBridge dealloc]):
(-[WebFrameBridge frameLoader]):
(-[WebFrameBridge setTitle:]):
(-[WebFrameBridge receivedData:textEncodingName:]):
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:]):
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:postData:]):
(-[WebFrameBridge objectLoadedFromCacheWithURL:response:data:]):
(-[WebFrameBridge syncLoadResourceWithMethod:URL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
(-[WebFrameBridge reportClientRedirectToURL:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
(-[WebFrameBridge reportClientRedirectCancelled:]):
(-[WebFrameBridge loadURL:referrer:reload:userGesture:target:triggeringEvent:form:formValues:]):
(-[WebFrameBridge postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrameBridge didFirstLayout]):
(-[WebFrameBridge notifyIconChanged:]):
(-[WebFrameBridge originalRequestURL]):
(-[WebFrameBridge isLoadTypeReload]):
* WebView/WebFrame.m:
(-[WebFrame _opened]):
(-[WebFrame _checkLoadComplete]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _actionInformationForLoadType:isFormSubmission:event:originalURL:]):
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _currentBackForwardListItemToResetTo]):
(-[WebFrame _updateBackground]):
(-[WebFrame _frameLoader]):
(-[WebFrame _frameLoadCompleted]):
(-[WebFrame _makeDocumentView]):
(-[WebFrame _updateHistoryForCommit]):
(-[WebFrame _updateHistoryForReload]):
(-[WebFrame _updateHistoryForStandardLoad]):
(-[WebFrame _updateHistoryForBackForwardNavigation]):
(-[WebFrame _updateHistoryForInternalLoad]):
(-[WebFrame _tokenForLoadErrorReset]):
(-[WebFrame _resetAfterLoadError:]):
(-[WebFrame _doNotResetAfterLoadError:]):
* WebView/WebFrameInternal.h:
2006-10-09 Mark Rowe <bdash@webkit.org>
Rubber-stamped by Darin.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge imageTitleForFilename:size:]): Revert accidental change to a UI_STRING that
is triggering an assertion failure.
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- remove unneeded non-Loader header includes from WebFrameLoader.h (split WebFrameLoadType into
two coincidentally matching enums)
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader commitProvisionalLoad:]):
(isBackForwardLoadType):
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
(-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader isReplacing]):
(-[WebFrameLoader setReplacing]):
(-[WebFrameLoader loadType]):
(-[WebFrameLoader setLoadType:]):
(-[WebFrameLoader checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader loadDataSource:withLoadType:formState:]):
(-[WebFrameLoader didFirstLayout]):
* WebCoreSupport/WebFrameBridge.m:
* WebView/WebFrame.m:
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _provisionalLoadStarted]):
(-[WebFrame _opened]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _recursiveGoToItem:fromItem:withLoadType:]):
(-[WebFrame _goToItem:withLoadType:]):
(-[WebFrame _actionInformationForLoadType:isFormSubmission:event:originalURL:]):
(-[WebFrame _continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrame _currentBackForwardListItemToResetTo]):
(-[WebFrame _itemForRestoringDocState]):
(-[WebFrame _addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
(-[WebFrame _loadType]):
(-[WebFrame loadRequest:]):
* WebView/WebFrameInternal.h:
* WebView/WebView.m:
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- move WebFrameLoader creation and ownership from WebFrame to WebFrameBridge
* Loader/WebFrameLoader.m:
(-[WebFrameLoader stopLoadingSubframes]):
(-[WebFrameLoader closeOldDataSources]):
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]):
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
(-[WebFrameBridge dealloc]):
(-[WebFrameBridge loader]):
(-[WebFrameBridge setTitle:]):
(-[WebFrameBridge receivedData:textEncodingName:]):
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:]):
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:postData:]):
(-[WebFrameBridge reportClientRedirectToURL:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
(-[WebFrameBridge reportClientRedirectCancelled:]):
(-[WebFrameBridge loadURL:referrer:reload:userGesture:target:triggeringEvent:form:formValues:]):
(-[WebFrameBridge didFirstLayout]):
(-[WebFrameBridge imageTitleForFilename:size:]):
(-[WebFrameBridge notifyIconChanged:]):
(-[WebFrameBridge originalRequestURL]):
(-[WebFrameBridge isLoadTypeReload]):
* WebView/WebFrame.m:
(-[NSView setWebFrame::]):
(-[WebFramePrivate dealloc]):
(-[WebFramePrivate setWebFrameView:]):
(-[WebFramePrivate setProvisionalItem:]):
(-[WebFrame _webDataRequestForData:MIMEType:textEncodingName:baseURL:unreachableURL:]):
(-[WebFrame _createItem:]):
(-[WebFrame _createItemTreeWithTargetFrame:clippedAtTarget:]):
(-[WebFrame _detachFromParent]):
(-[WebFrame _makeDocumentView]):
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _provisionalLoadStarted]):
(-[WebFrame _opened]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _recursiveGoToItem:fromItem:withLoadType:]):
(-[WebFrame _continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrame _setTitle:]):
(-[WebFrame _defersCallbacksChanged]):
(-[WebFrame _currentBackForwardListItemToResetTo]):
(-[WebFrame _itemForSavingDocState]):
(-[WebFrame _itemForRestoringDocState]):
(-[WebFrame _saveDocumentAndScrollState]):
(-[WebFrame _shouldTreatURLAsSameAsCurrent:]):
(-[WebFrame _loadRequest:inFrameNamed:]):
(-[WebFrame _initWithWebFrameView:webView:bridge:]):
(-[WebFrame _addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
(-[WebFrame _frameLoader]):
(-[WebFrame _prepareForDataSourceReplacement]):
(-[WebFrame _restoreScrollPositionAndViewState]):
(-[WebFrame _firstLayoutDone]):
(-[WebFrame _loadType]):
(-[WebFrame frameView]):
(-[WebFrame provisionalDataSource]):
(-[WebFrame dataSource]):
(-[WebFrame loadRequest:]):
(-[WebFrame loadArchive:]):
(-[WebFrame stopLoading]):
(-[WebFrame reload]):
(-[WebFrame _resetBackForwardList]):
(-[WebFrame _invalidateCurrentItemPageCache]):
(-[WebFrame _provisionalItemIsTarget]):
(-[WebFrame _loadProvisionalItemFromPageCache]):
* WebView/WebFrameInternal.h:
2006-10-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- move remaining movable data fields from WebFrameLoader to WebFrame
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState commitIfReady]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader provisionalLoadStarted]):
(-[WebFrameLoader _setState:]):
(-[WebFrameLoader stopLoadingSubframes]):
(-[WebFrameLoader stopLoading]):
(-[WebFrameLoader startLoading]):
(-[WebFrameLoader _receivedMainResourceError:complete:]):
(-[WebFrameLoader clientRedirectCancelledOrFinished:]):
(-[WebFrameLoader clientRedirectedTo:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
(-[WebFrameLoader shouldReloadForCurrent:andDestination:]):
(-[WebFrameLoader loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrameLoader continueFragmentScrollAfterNavigationPolicy:formState:]):
(-[WebFrameLoader closeOldDataSources]):
(-[WebFrameLoader commitProvisionalLoad:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader isQuickRedirectComing]):
* Loader/WebFrameLoaderClient.h:
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge frameLoader]):
(-[WebFrameBridge setTitle:]):
(-[WebFrameBridge reportClientRedirectToURL:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
(-[WebFrameBridge reportClientRedirectCancelled:]):
(-[WebFrameBridge loadURL:referrer:reload:userGesture:target:triggeringEvent:form:formValues:]):
* WebView/WebDataSource.m:
(-[WebDataSource _loadFromPageCache:]):
* WebView/WebFrame.m:
(-[NSView setWebFrame::]):
(-[WebFrame _addHistoryItemForFragmentScroll]):
(-[WebFrame _didFinishLoad]):
(-[WebFrame _provisionalLoadStarted]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _frameLoadCompleted]):
(-[WebFrame stopLoading]):
(-[WebFrame _invalidateCurrentItemPageCache]):
* WebView/WebFrameInternal.h:
2006-10-08 Darin Adler <darin@apple.com>
Rubber stamped by Maciej.
- changed "document load state" to "document loader"
* Loader/WebDocumentLoadState.h: Removed.
* Loader/WebDocumentLoadState.m: Removed.
* Loader/WebDocumentLoader.h: Added.
* Loader/WebDocumentLoader.m: Added.
(-[WebDocumentLoader setMainDocumentError:]):
(-[WebDocumentLoader mainReceivedError:complete:]):
(-[WebDocumentLoader finishedLoading]):
(-[WebDocumentLoader commitLoadWithData:]):
(-[WebDocumentLoader setupForReplaceByMIMEType:]):
(-[WebDocumentLoader updateLoading]):
(-[WebDocumentLoader setTitle:]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader dealloc]):
(-[WebFrameLoader activeDocumentLoader]):
(-[WebFrameLoader activeDataSource]):
(-[WebFrameLoader addPlugInStreamLoader:]):
(-[WebFrameLoader removePlugInStreamLoader:]):
(-[WebFrameLoader addSubresourceLoader:]):
(-[WebFrameLoader removeSubresourceLoader:]):
(-[WebFrameLoader dataSource]):
(-[WebFrameLoader setDocumentLoader:]):
(-[WebFrameLoader documentLoader]):
(-[WebFrameLoader policyDataSource]):
(-[WebFrameLoader setPolicyDocumentLoader:]):
(-[WebFrameLoader clearDataSource]):
(-[WebFrameLoader provisionalDataSource]):
(-[WebFrameLoader provisionalDocumentLoader]):
(-[WebFrameLoader setProvisionalDocumentLoader:]):
(-[WebFrameLoader _clearProvisionalDataSource]):
(-[WebFrameLoader _setState:]):
(-[WebFrameLoader clearProvisionalLoad]):
(-[WebFrameLoader commitProvisionalLoad]):
(-[WebFrameLoader stopLoading]):
(-[WebFrameLoader startLoading]):
(-[WebFrameLoader startProvisionalLoad:]):
(-[WebFrameLoader setupForReplace]):
(-[WebFrameLoader _didReceiveResponse:forResource:]):
(-[WebFrameLoader _originalRequest]):
(-[WebFrameLoader _receivedMainResourceError:complete:]):
(-[WebFrameLoader _receivedData:]):
(-[WebFrameLoader _setRequest:]):
(-[WebFrameLoader _isStopping]):
(-[WebFrameLoader _setupForReplaceByMIMEType:]):
(-[WebFrameLoader _setResponse:]):
(-[WebFrameLoader _mainReceivedError:complete:]):
(-[WebFrameLoader _finishedLoading]):
(-[WebFrameLoader _checkContentPolicyForMIMEType:andCall:withSelector:]):
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
(-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader finishedLoadingDocument:]):
(-[WebFrameLoader committedLoadWithDocumentLoader:data:]):
(-[WebFrameLoader revertToProvisionalWithDocumentLoader:]):
(-[WebFrameLoader documentLoader:setMainDocumentError:]):
(-[WebFrameLoader documentLoader:mainReceivedCompleteError:]):
(-[WebFrameLoader finalSetupForReplaceWithDocumentLoader:]):
(-[WebFrameLoader willChangeTitleForDocument:]):
(-[WebFrameLoader didChangeTitleForDocument:]):
(-[WebFrameLoader checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader loadDataSource:withLoadType:formState:]):
* Plugins/WebPluginController.m:
(-[WebPluginController pluginView:receivedResponse:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge setTitle:]):
(-[WebFrameBridge receivedData:textEncodingName:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _mainDocumentError]):
(-[WebDataSource _loadFromPageCache:]):
(-[WebDataSource _bridge]):
(-[WebDataSource _webView]):
(-[WebDataSource _URLForHistory]):
(-[WebDataSource _documentLoader]):
(-[WebDataSource _initWithDocumentLoader:]):
(-[WebDataSource initWithRequest:]):
(-[WebDataSource dealloc]):
(-[WebDataSource data]):
(-[WebDataSource webFrame]):
(-[WebDataSource initialRequest]):
(-[WebDataSource request]):
(-[WebDataSource response]):
(-[WebDataSource textEncodingName]):
(-[WebDataSource isLoading]):
(-[WebDataSource unreachableURL]):
(-[WebDataSource webArchive]):
* WebView/WebDataSourceInternal.h:
* WebView/WebDocumentLoadStateMac.h: Removed.
* WebView/WebDocumentLoadStateMac.m: Removed.
* WebView/WebDocumentLoaderMac.h: Added.
* WebView/WebDocumentLoaderMac.m: Added.
* WebView/WebFrame.m:
(-[WebFrame _createItem:]):
(-[WebFrame _receivedMainResourceError:]):
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _opened]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _continueFragmentScrollAfterNavigationPolicy:formState:]):
(-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrame _addChild:]):
(-[WebFrame _provisionalLoadStarted]):
(-[WebFrame _dataSourceForDocumentLoader:]):
(-[WebFrame _createDocumentLoaderWithRequest:]):
* WebView/WebFrameInternal.h:
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation title]):
* WebView/WebView.m:
(-[WebView _mainFrameOverrideEncoding]):
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Mitz.
- fix http://bugs.webkit.org/show_bug.cgi?id=11218
REGRESSION: Assertion failure in WebFrameLoader when going back from a file: or data: URL
Also added a helper function in WebFrameLoader so that checks for back/forward load types
are easier to read.
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _setPolicyDocumentLoadState:]): Fixed line of code that was setting the load
state to nil instead of the passed-in object.
(isBackForwardLoadType): Added.
(-[WebFrameLoader shouldReloadToHandleUnreachableURLFromRequest:]): Use isBackForwardLoadType.
(-[WebFrameLoader checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
Ditto.
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]): Ditto.
2006-10-08 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- fix two recently introduced leaks: one of an NSString, the other of a WebDataSource
* Loader/WebDocumentLoadState.m: (-[WebDocumentLoadState setTitle:]):
Rearranged code to avoid storage leak in case of identical title.
* Loader/WebFrameLoader.h: Removed _setPolicyDocumentLoadState: method
from the header.
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _setPolicyDocumentLoadState:]): Added logic to call detachFromFrameLoader
as needed if this load state is going away rather than moving on to become the provisional
load state.
(-[WebFrameLoader shouldReloadToHandleUnreachableURLFromRequest:]): Tweaked formatting.
(-[WebFrameLoader _loadRequest:archive:]): Added an assertion.
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]): Added an assertion.
(-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]): Added an assertion.
(-[WebFrameLoader reload]): Added an assertion.
(-[WebFrameLoader loadDataSource:withLoadType:formState:]): Added a local variable to avoid
calling _documentLoadState over and over again.
2006-10-07 Peter Kasting <pkasting@google.com>
Reviewed/landed by Adam.
http://bugs.webkit.org/show_bug.cgi?id=11199
Update Session History when a load is committed rather than completed.
* COM/WebFrame.cpp:
(WebFrame::receivedResponse):
(WebFrame::receivedAllData):
2006-10-07 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
Patch for http://bugs.webkit.org/show_bug.cgi?id=11198
Auto-generate a few more Objective-C DOM interfaces
* MigrateHeaders.make:
2006-10-07 Mark Rowe <bdash@webkit.org>
Reviewed by Mitz.
Fix memory leak from -[WebDocumentLoadState setTitle:].
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState setTitle:]): Ensure 'trimmed' is released even when length is
zero, and untangle the confusing logic around this case.
2006-10-06 Brady Eidson <beidson@apple.com>
Reviewed by Darin
Refactored a whole bunch of WebFramePrivate.h SPI to WebFrameInternal
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
* History/WebHistoryItem.m:
* Loader/WebFrameLoader.h:
* Misc/WebCoreStatistics.m:
* Misc/WebElementDictionary.m:
* Plugins/WebNetscapePluginEmbeddedView.m:
* Plugins/WebPluginController.m:
* WebCoreSupport/WebViewFactory.m:
* WebView/WebArchiver.m:
* WebView/WebDataSource.m:
* WebView/WebFrame.m:
(-[WebFrame _isDescendantOfFrame:]):
(-[WebFrame _setShouldCreateRenderers:]):
(-[WebFrame _bodyBackgroundColor]):
(-[WebFrame _isFrameSet]):
(-[WebFrame _firstLayoutDone]):
(-[WebFrame _loadType]):
* WebView/WebFrameInternal.h:
* WebView/WebFramePrivate.h:
* WebView/WebHTMLRepresentation.m:
* WebView/WebScriptDebugDelegate.m:
2006-10-06 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- Move all delegate dispatching code out of WebDataSource.
* Loader/WebFrameLoader.m:
(-[WebFrameLoader startLoading]):
(-[WebFrameLoader _identifierForInitialRequest:]):
(-[WebFrameLoader _willSendRequest:forResource:redirectResponse:]):
(-[WebFrameLoader _didReceiveAuthenticationChallenge:forResource:]):
(-[WebFrameLoader _didCancelAuthenticationChallenge:forResource:]):
(-[WebFrameLoader _didReceiveResponse:forResource:]):
(-[WebFrameLoader _didReceiveData:contentLength:forResource:]):
(-[WebFrameLoader _didFinishLoadingForResource:]):
(-[WebFrameLoader _didFailLoadingWithError:forResource:]):
(-[WebFrameLoader _receivedMainResourceError:complete:]):
(-[WebFrameLoader _downloadWithLoadingConnection:request:response:proxy:]):
(-[WebFrameLoader _checkContentPolicyForMIMEType:andCall:withSelector:]):
* WebView/WebDataSource.m:
(-[WebDataSource _setLoadingFromPageCache:]):
(-[WebDataSource _stopLoadingWithError:]):
* WebView/WebDataSourceInternal.h:
2006-10-06 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- moved firstLayoutDone BOOL from WebFrame to WebFrameLoader
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader didFirstLayout]):
(-[WebFrameLoader provisionalLoadStarted]):
(-[WebFrameLoader frameLoadCompleted]):
(-[WebFrameLoader firstLayoutDone]):
* WebCoreSupport/WebFrameBridge.m: (-[WebFrameBridge didFirstLayout]):
* WebView/WebFrame.m:
(-[WebFrame _firstLayoutDone]):
(-[WebFrame _provisionalLoadStarted]):
(-[WebFrame _frameLoadCompleted]):
(-[WebFrame _restoreScrollPositionAndViewState]):
* WebView/WebFrameInternal.h:
2006-10-06 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- moved more data and the corresponding code from WebFrame to WebFrameLoader
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader cannotShowMIMETypeForURL:]):
(-[WebFrameLoader _checkNavigationPolicyForRequest:andCall:withSelector:]):
(-[WebFrameLoader shouldReloadToHandleUnreachableURLFromRequest:]):
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
(-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader invalidatePendingPolicyDecisionCallingDefaultAction:]):
(-[WebFrameLoader checkNewWindowPolicyForRequest:action:frameName:formState:andCall:withSelector:]):
(-[WebFrameLoader _continueAfterNewWindowPolicy:]):
(-[WebFrameLoader checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
(-[WebFrameLoader continueAfterNavigationPolicy:]):
(-[WebFrameLoader continueAfterWillSubmitForm:]):
(-[WebFrameLoader continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrameLoader loadDataSource:withLoadType:formState:]):
(-[WebFrameLoader handleUnimplementablePolicyWithErrorCode:forURL:]):
(-[WebFrameLoader delegateIsHandlingProvisionalLoadError]):
(-[WebFrameLoader setDelegateIsHandlingProvisionalLoadError:]):
* Loader/WebFrameLoaderClient.h:
* WebView/WebFrame.m:
(-[NSView setWebFrame::]):
(-[WebFramePrivate dealloc]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrame _postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrame _loadRequest:inFrameNamed:]):
(-[WebFrame stopLoading]):
(-[WebFrame _resetBackForwardList]):
(-[WebFrame _quickRedirectComing]):
(-[WebFrame _provisionalItemIsTarget]):
(-[WebFrame _loadProvisionalItemFromPageCache]):
* WebView/WebFrameInternal.h:
* WebView/WebFramePrivate.h:
* WebKit.xcodeproj/project.pbxproj:
2006-10-06 Maciej Stachowiak <mjs@apple.com>
Rubber stamped by Darin.
- removed includes of unused headers.
* WebView/WebDataSource.m:
2006-10-06 Maciej Stachowiak <mjs@apple.com>
Not reviewed.
- fix build breakage
* Loader/WebFrameLoader.m:
(-[WebFrameLoader willChangeTitleForDocumentLoadState:]):
(-[WebFrameLoader didChangeTitleForDocumentLoadState:]):
2006-10-06 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- move remaining movable WebDataSource fields to WebDocumentLoadState
* Loader/WebDocumentLoadState.h:
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState dealloc]):
(-[WebDocumentLoadState isLoadingInAPISense]):
(-[WebDocumentLoadState addResponse:]):
(-[WebDocumentLoadState stopRecordingResponses]):
(-[WebDocumentLoadState title]):
(-[WebDocumentLoadState setLastCheckedRequest:]):
(-[WebDocumentLoadState lastCheckedRequest]):
(-[WebDocumentLoadState triggeringAction]):
(-[WebDocumentLoadState setTriggeringAction:]):
(-[WebDocumentLoadState responses]):
(-[WebDocumentLoadState setOverrideEncoding:]):
(-[WebDocumentLoadState overrideEncoding]):
(-[WebDocumentLoadState setTitle:]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _setState:]):
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
(-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
(-[WebFrameLoader reload]):
(-[WebFrameLoader willChangeTitleForDocumentLoadState:]):
(-[WebFrameLoader didChangeTitleForDocumentLoadState:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge setTitle:]):
(-[WebFrameBridge receivedData:textEncodingName:]):
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _didReceiveResponse:forResource:]):
(-[WebDataSource textEncodingName]):
* WebView/WebDataSourceInternal.h:
* WebView/WebFrame.m:
(-[WebFrame _opened]):
(-[WebFrame _checkNavigationPolicyForRequest:dataSource:formState:andCall:withSelector:]):
(-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrame _addChild:]):
(-[WebFrame _loadDataSource:withLoadType:formState:]):
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation title]):
* WebView/WebView.m:
(-[WebView _mainFrameOverrideEncoding]):
2006-10-06 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- moved loadType into WebFrameLoader
* WebView/WebFramePrivate.h: Removed _setLoadType, but not _loadType because it's
currently used by Safari.
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
(-[WebFrameLoader isReplacing]):
(-[WebFrameLoader setReplacing]):
(-[WebFrameLoader loadType]):
(-[WebFrameLoader setLoadType:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge isLoadTypeReload]):
* WebView/WebFrame.m:
(-[WebFrame _loadType]):
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _commitProvisionalLoad:]):
(-[WebFrame _opened]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrame _loadURL:referrer:intoChild:]):
(-[WebFrame _currentBackForwardListItemToResetTo]):
(-[WebFrame _itemForRestoringDocState]):
(-[WebFrame _continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrame _didFirstLayout]):
(-[WebFrame _addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
(-[WebFrame _provisionalLoadStarted]):
(-[WebFrame loadRequest:]):
2006-10-06 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- added WebFrameLoaderClient protocol -- to be used to make WebFrameLoader forget all about WebFrame
* Loader/WebDocumentLoadState.h: Added comment about Maciej's planned renaming here.
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m: Renamed webFrame to client and added the new protocol.
Eventually we'll be removing the dependency on WebFrame entirely.
* WebView/WebFrame.m: (-[WebFrame _initWithWebFrameView:webView:bridge:]): Update to call the method
by its new name.
* Loader/WebFrameLoaderClient.h: Added.
* WebKit.xcodeproj/project.pbxproj: Updated for new file, sorted things.
2006-10-06 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- segregate WebFrame methods into ones that should be moved into WebFrameLoader and ones that don't need to
Also removed useless WebFrameLoader part
* WebView/WebFrame.m:
(-[WebFramePrivate dealloc]):
2006-10-06 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- moved more data from WebDataSource to WebDocumentLoadState
* Loader/WebDocumentLoadState.h:
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState commitLoadWithData:]):
(-[WebDocumentLoadState prepareForLoadStart]):
(-[WebDocumentLoadState loadingStartedTime]):
(-[WebDocumentLoadState setIsClientRedirect:]):
(-[WebDocumentLoadState isClientRedirect]):
(-[WebDocumentLoadState setPrimaryLoadComplete:]):
(-[WebDocumentLoadState isLoadingInAPISense]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _setState:]):
(-[WebFrameLoader _finishedLoading]):
(-[WebFrameLoader documentLoadState:mainReceivedCompleteError:]):
(-[WebFrameLoader prepareForLoadStart]):
(-[WebFrameLoader subframeIsLoading]):
* WebView/WebDataSource.m:
(-[WebDataSource _fileWrapperForURL:]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _loadFromPageCache:]):
(-[WebDataSource isLoading]):
* WebView/WebDataSourceInternal.h:
* WebView/WebFrame.m:
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _opened]):
(-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
2006-10-06 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=11183
REGRESSION: Safari loads error pages unstyled
* WebView/WebFrame.m:
(-[WebFrame _loadHTMLString:baseURL:unreachableURL:]):
Use utf-8 encoding instead of the string's "fastest" encoding.
2006-10-06 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adam.
- fixed the following bugs:
http://bugs.webkit.org/show_bug.cgi?id=11136
"REGRESSION: Safari snippet editor doesn't work"
http://bugs.webkit.org/show_bug.cgi?id=11140
"REGRESSION: view source window blank"
http://bugs.webkit.org/show_bug.cgi?id=11146
"REGRESSION: Instead of showing the error page, Safari opens its Resources folder in the Finder"
Possibly more.
* Loader/WebDocumentLoadState.h:
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState actualRequest]): New method.
* WebView/WebDataSource.m:
(-[WebDataSource _startLoading]): We need to make sure not to start loading the main
resource with the fake external request for an applewebdata: request.
2006-10-05 Adele Peterson <adele@apple.com>
Reviewed by the letter 'B'.
More build fixes.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDynamicScrollBarsView.h:
* WebView/WebDynamicScrollBarsView.m:
(-[WebDynamicScrollBarsView updateScrollers]):
(-[WebDynamicScrollBarsView setAllowsScrolling:]):
(-[WebDynamicScrollBarsView allowsScrolling]):
(-[WebDynamicScrollBarsView setAllowsHorizontalScrolling:]):
(-[WebDynamicScrollBarsView setAllowsVerticalScrolling:]):
(-[WebDynamicScrollBarsView allowsHorizontalScrolling]):
(-[WebDynamicScrollBarsView allowsVerticalScrolling]):
(-[WebDynamicScrollBarsView horizontalScrollingMode]):
(-[WebDynamicScrollBarsView verticalScrollingMode]):
(-[WebDynamicScrollBarsView setHorizontalScrollingMode:]):
(-[WebDynamicScrollBarsView setVerticalScrollingMode:]):
(-[WebDynamicScrollBarsView setScrollingMode:]):
* WebView/WebView.m:
(-[WebView setAlwaysShowVerticalScroller:]):
(-[WebView alwaysShowVerticalScroller]):
(-[WebView setAlwaysShowHorizontalScroller:]):
(-[WebView alwaysShowHorizontalScroller]):
2006-10-05 Vladimir Olexa <vladimir.olexa@gmail.com>
Reviewed by Timothy.
Bug: http://bugs.webkit.org/show_bug.cgi?id=9887
Continuous spell checking now remembers user's setting. The change is applied globally,
meaning, both TextArea and TextField are affected when either of them enables/disables
spell checking.
* WebView/WebPreferenceKeysPrivate.h: added a define for WebContinuousSpellCheckingEnabled
* WebView/WebView.m:
(-[WebViewPrivate init]): reads WebContinuousSpellCheckingEnabled from NSUserDefaults
(-[WebView setContinuousSpellCheckingEnabled:]):
(-[WebView isContinuousSpellCheckingEnabled]):
2006-10-05 MorganL <morganl.webkit@yahoo.com>
Reviewed by Darin.
Fixes http://bugs.webkit.org/show_bug.cgi?id=11162
* COM/WebFrame.cpp:
(WebFrame::loadDataSource):
(WebFrame::receivedResponse):
2006-10-05 Peter Kasting <pkasting@google.com>
Reviewed by Darin, landed by Adam.
http://bugs.webkit.org/show_bug.cgi?id=11176
Fix win32 build, adapt to Maciej's ResourceLoader changes.
* COM/WebFrame.cpp:
(WebFrame::loadDataSource):
2006-10-05 Marvin Decker <marv.decker@gmail.com>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=10989
Provide a way for embedders to implement BrowserExtensionWin
* COM/Interfaces/IWebUIDelegate.idl:
* COM/WebFrame.cpp:
(WebFrame::createNewWindow):
* COM/WebFrame.h:
2006-10-04 Mark Rowe <bdash@webkit.org>
Reviewed by NOBODY (build fix).
* WebView/WebView.m:
(-[WebView scrollDOMRangeToVisible:]): Move scrollDOMRangeToVisible: into the correct category.
2006-09-26 David Smith <catfish.man@gmail.com>
Reviewed by Timothy.
http://bugs.webkit.org/show_bug.cgi?id=3723
Add -scrollDOMRangeToVisible:
* WebView/WebView.m:
(-[WebView scrollDOMRangeToVisible:]):
* WebView/WebViewPrivate.h:
2006-10-03 Graham Dennis <graham.dennis@gmail.com>
Reviewed by Timothy.
<http://bugs.webkit.org/show_bug.cgi?id=10338>
When contentEditable, cursor doesn't change to hand
Allow the behaviour of editable links to be specified by a WebPreference
The preference WebKitEditableLinkBehavior has four options:
- AlwaysLive: Safari 2.0 behaviour
- OnlyLiveWithShiftKey: Firefox/WinIE behaviour (and prior WebKit-ToT behaviour)
- LiveWhenNotFocused: Editable links are live only when their editable block is not
focused, or when the shift key is pressed
- DefaultBehavior: This is the same as OnlyLiveWithShiftKey.
No layout tests, just a modification of a manual-test as it isn't possible to test
this automatically.
* WebView/WebPreferenceKeysPrivate.h:
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
(-[WebPreferences editableLinkBehavior]):
(-[WebPreferences setEditableLinkBehavior:]):
* WebView/WebPreferencesPrivate.h:
* WebView/WebView.m:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2006-10-03 Justin Garcia <justin.garcia@apple.com>
Reviewed by harrison
execCommand("Cut"/"Copy"/"Paste") broken in editable subframes.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge issueCutCommand]): Issue the command on the WebHTMLView, not the WebView.
(-[WebFrameBridge issueCopyCommand]): Ditto.
(-[WebFrameBridge issuePasteCommand]): Ditto.
(-[WebFrameBridge issuePasteAndMatchStyleCommand]): Ditto.
(-[WebFrameBridge issueTransposeCommand]): Fixed formatting.
(-[WebFrameBridge canPaste]): Ask the WebHTMLView, not the WebView.
* WebView/WebHTMLView.m:
(-[WebHTMLView copy:]): Moved to WebInternal
(-[WebHTMLView cut:]): Ditto.
(-[WebHTMLView paste:]): Ditto.
(-[WebHTMLView pasteAsPlainText:]): Ditto.
* WebView/WebHTMLViewInternal.h:
* WebView/WebView.m: Removed the now unused _canPaste.
* WebView/WebViewInternal.h: Ditto.
2006-10-03 Justin Garcia <justin.garcia@apple.com>
Reviewed by geoff
<rdar://problem/4763519> REGRESSION: Multipart/x-mixed-replace sub-resources fail to load
* Loader/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forFrameLoader:]):
Enable multipart/x-mixed-replace support on the request. This line was accidently removed during
some loader refactoring.
2006-10-02 Adam Roben <aroben@apple.com>
Reviewed by Maciej.
Add message paramter to WebView::mouse* methods to pass down to
PlatformMouseEvent.
* COM/WebView.cpp:
(WebView::mouseMoved):
(WebView::mouseDown):
(WebView::mouseUp):
(WebView::mouseDoubleClick):
(WebViewWndProc):
* COM/WebView.h:
2006-10-02 Maciej Stachowiak <mjs@apple.com>
Reviewed by Alice.
- take away direct knowledge of WebFrame from WebDataSource
* Loader/WebDocumentLoadState.h:
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState setFrameLoader:]):
(-[WebDocumentLoadState detachFromFrameLoader]):
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _setDocumentLoadState:]):
(-[WebFrameLoader _setProvisionalDocumentLoadState:]):
* WebView/WebDataSource.m:
* WebView/WebDataSourceInternal.h:
* WebView/WebDocumentLoadStateMac.m:
(-[WebDocumentLoadStateMac detachFromFrameLoader]):
* WebView/WebFrame.m:
(-[WebFrame _loadDataSource:withLoadType:formState:]):
2006-10-02 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- move a big slice of data and logic from WebDataSource to WebDocumentLoadState
* Loader/WebDocumentLoadState.h:
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState initWithRequest:]):
(-[WebDocumentLoadState dealloc]):
(-[WebDocumentLoadState originalRequestCopy]):
(-[WebDocumentLoadState request]):
(-[WebDocumentLoadState replaceRequestURLForAnchorScrollWithURL:]):
(-[WebDocumentLoadState setRequest:]):
(-[WebDocumentLoadState setResponse:]):
(-[WebDocumentLoadState isStopping]):
(-[WebDocumentLoadState bridge]):
(-[WebDocumentLoadState setMainDocumentError:]):
(-[WebDocumentLoadState mainDocumentError]):
(-[WebDocumentLoadState clearErrors]):
(-[WebDocumentLoadState mainReceivedError:complete:]):
(-[WebDocumentLoadState stopLoading]):
(-[WebDocumentLoadState setupForReplace]):
(-[WebDocumentLoadState commitIfReady]):
(-[WebDocumentLoadState finishedLoading]):
(-[WebDocumentLoadState setCommitted:]):
(-[WebDocumentLoadState isCommitted]):
(-[WebDocumentLoadState setLoading:]):
(-[WebDocumentLoadState isLoading]):
(-[WebDocumentLoadState commitLoadWithData:]):
(-[WebDocumentLoadState doesProgressiveLoadWithMIMEType:]):
(-[WebDocumentLoadState receivedData:]):
(-[WebDocumentLoadState setupForReplaceByMIMEType:]):
(-[WebDocumentLoadState updateLoading]):
(-[WebDocumentLoadState response]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader activeDocumentLoadState]):
(-[WebFrameLoader activeDataSource]):
(-[WebFrameLoader _archivedSubresourceForURL:]):
(-[WebFrameLoader addPlugInStreamLoader:]):
(-[WebFrameLoader removePlugInStreamLoader:]):
(-[WebFrameLoader addSubresourceLoader:]):
(-[WebFrameLoader removeSubresourceLoader:]):
(-[WebFrameLoader documentLoadState]):
(-[WebFrameLoader provisionalDocumentLoadState]):
(-[WebFrameLoader stopLoading]):
(-[WebFrameLoader _originalRequest]):
(-[WebFrameLoader _receivedData:]):
(-[WebFrameLoader _setRequest:]):
(-[WebFrameLoader bridge]):
(-[WebFrameLoader _handleFallbackContent]):
(-[WebFrameLoader _isStopping]):
(-[WebFrameLoader _setupForReplaceByMIMEType:]):
(-[WebFrameLoader _setResponse:]):
(-[WebFrameLoader _mainReceivedError:complete:]):
(-[WebFrameLoader _finishedLoading]):
(-[WebFrameLoader didReceiveServerRedirectForProvisionalLoadForFrame]):
(-[WebFrameLoader finishedLoadingDocumentLoadState:]):
(-[WebFrameLoader commitProvisitionalLoad]):
(-[WebFrameLoader committedLoadWithDocumentLoadState:data:]):
(-[WebFrameLoader isReplacing]):
(-[WebFrameLoader setReplacing]):
(-[WebFrameLoader revertToProvisionalWithDocumentLoadState:]):
(-[WebFrameLoader documentLoadState:setMainDocumentError:]):
(-[WebFrameLoader documentLoadState:mainReceivedCompleteError:]):
(-[WebFrameLoader finalSetupForReplaceWithDocumentLoadState:]):
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _prepareForLoadStart]):
(-[WebDataSource _mainDocumentError]):
(-[WebDataSource _finishedLoading]):
(-[WebDataSource _receivedData:]):
(-[WebDataSource _setMainDocumentError:]):
(-[WebDataSource _clearUnarchivingState]):
(-[WebDataSource _revertToProvisionalState]):
(-[WebDataSource _receivedMainResourceError:complete:]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _loadFromPageCache:]):
(-[WebDataSource _bridge]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource _URLForHistory]):
(-[WebDataSource _setTitle:]):
(-[WebDataSource _initWithDocumentLoadState:]):
(-[WebDataSource request]):
(-[WebDataSource response]):
(-[WebDataSource isLoading]):
(-[WebDataSource webArchive]):
* WebView/WebDataSourceInternal.h:
* WebView/WebDocumentLoadStateMac.m:
(-[WebDocumentLoadStateMac initWithRequest:]):
* WebView/WebFrame.m:
(-[WebFrame _createItem:]):
(-[WebFrame _receivedMainResourceError:]):
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _commitProvisionalLoad:]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _continueFragmentScrollAfterNavigationPolicy:formState:]):
(-[WebFrame _didReceiveServerRedirectForProvisionalLoadForFrame]):
(-[WebFrame _provisionalLoadStarted]):
* WebView/WebFrameInternal.h:
2006-10-02 Justin Garcia <justin.garcia@apple.com>
Reviewed by john
<rdar://problem/4757583>
REGRESSION: tabbing into page focuses wrong control on 2nd pass
<rdar://problem/4757594>
REGRESSION: Form field is left with secondary selection after tabbing out of WebView
* WebView/WebHTMLView.m:
(-[NSArray maintainsInactiveSelection]): Replace code that I removed in error in the patch
for 9642. Only leave inactive editable selections in the WebHTMLView if the nextResponder
is in the same WebView.
2006-10-02 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- remove webFrame field from WebDataSourcePrivate, it can get it from WebDocumentLoadState now
* Loader/WebDocumentLoadState.h:
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState frameLoader]):
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _revertToProvisionalState]):
(-[WebDataSource _setupForReplaceByMIMEType:]):
(-[WebDataSource _updateLoading]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _setWebFrame:]):
(-[WebDataSource _defersCallbacksChanged]):
(-[WebDataSource _stopLoading]):
(-[WebDataSource _webView]):
(-[WebDataSource _stopLoadingWithError:]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource dealloc]):
(-[WebDataSource webFrame]):
(-[WebDataSource isLoading]):
2006-10-02 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- fix crash on back/forward - reattach WebDocumentLoadState to data source when needed
* WebView/WebDataSource.m:
(-[WebDataSource _setWebFrame:]):
(-[WebDataSource _initWithDocumentLoadState:]):
* WebView/WebDataSourceInternal.h:
2006-10-02 Maciej Stachowiak <mjs@apple.com>
Build fix, not reviewed.
- Added missing files to fix build.
* WebView/WebDocumentLoadStateMac.h: Added.
* WebView/WebDocumentLoadStateMac.m: Added.
(-[WebDocumentLoadStateMac initWithRequest:]):
(-[WebDocumentLoadStateMac dealloc]):
(-[WebDocumentLoadStateMac setDataSource:]):
(-[WebDocumentLoadStateMac dataSource]):
(-[WebDocumentLoadStateMac setFrameLoader:]):
2006-10-01 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady and Oliver.
- move things around so that WebDataSource and WebDocumentLoadState know about each other in
the right way. This lines things up to move nearly all functionality down to WebDocumentLoadState.
* Loader/WebDocumentLoadState.h:
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState initWithRequest:]):
(-[WebDocumentLoadState dealloc]):
(-[WebDocumentLoadState originalRequest]):
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader dealloc]):
(-[WebFrameLoader addSubresourceLoader:]):
(-[WebFrameLoader startLoadingMainResourceWithRequest:identifier:]):
(-[WebFrameLoader dataSource]):
(-[WebFrameLoader _setDocumentLoadState:]):
(-[WebFrameLoader policyDataSource]):
(-[WebFrameLoader _setPolicyDocumentLoadState:]):
(-[WebFrameLoader clearDataSource]):
(-[WebFrameLoader provisionalDataSource]):
(-[WebFrameLoader _setProvisionalDocumentLoadState:]):
(-[WebFrameLoader _clearProvisionalDataSource]):
(-[WebFrameLoader _setState:]):
(-[WebFrameLoader clearProvisionalLoad]):
(-[WebFrameLoader commitProvisionalLoad]):
(-[WebFrameLoader stopLoading]):
(-[WebFrameLoader startLoading]):
(-[WebFrameLoader startProvisionalLoad:]):
(-[WebFrameLoader setupForReplace]):
(-[WebFrameLoader activeDocumentLoadState]):
(-[WebFrameLoader activeDataSource]):
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
(-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
(-[WebFrameLoader reload]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _setWebFrame:]):
(-[WebDataSource _documentLoadState]):
(-[WebDataSource _initWithDocumentLoadState:]):
(-[WebDataSource initWithRequest:]):
(-[WebDataSource initialRequest]):
(-[WebDataSource unreachableURL]):
* WebView/WebDataSourceInternal.h:
* WebView/WebFrame.m:
(-[WebFramePrivate dealloc]):
(-[WebFrame _continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrame _loadDataSource:withLoadType:formState:]):
(-[WebFrame _policyDataSource]):
(-[WebFrame _shouldReloadToHandleUnreachableURLFromRequest:]):
(-[WebFrame _dataSourceForDocumentLoadState:]):
(-[WebFrame _createDocumentLoadStateWithRequest:]):
* WebView/WebFrameInternal.h:
2006-09-29 David Hyatt <hyatt@apple.com>
Change the default minimum font size pref to 0 in order to allow
font-size:0 to work.
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
2006-09-28 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
Switch the inspector over to use border-image with styled buttons and selects.
* WebInspector/WebInspector.m:
(-[NSWindow window]):
(-[NSWindow setWebFrame:]):
(-[WebInspector _updateRoot]):
* WebInspector/webInspector/Images/button.png: Added.
* WebInspector/webInspector/Images/buttonDivider.png: Added.
* WebInspector/webInspector/Images/buttonPressed.png: Added.
* WebInspector/webInspector/Images/popup.png: Added.
* WebInspector/webInspector/Images/popupFill.png: Removed.
* WebInspector/webInspector/Images/popupFillPressed.png: Removed.
* WebInspector/webInspector/Images/popupLeft.png: Removed.
* WebInspector/webInspector/Images/popupLeftPressed.png: Removed.
* WebInspector/webInspector/Images/popupPressed.png: Added.
* WebInspector/webInspector/Images/popupRight.png: Removed.
* WebInspector/webInspector/Images/popupRightPressed.png: Removed.
* WebInspector/webInspector/Images/squareButtonRight.png: Removed.
* WebInspector/webInspector/Images/squareButtonRightPressed.png: Removed.
* WebInspector/webInspector/inspector.css:
* WebInspector/webInspector/inspector.html:
* WebInspector/webInspector/inspector.js:
2006-09-28 Alice Liu <alice.liu@apple.com>
fixing the windows build
* COM/WebView.cpp:
(WebView::mouseMoved):
(WebView::mouseDown):
(WebView::mouseUp):
(WebView::mouseDoubleClick):
2006-09-27 Justin Garcia <justin.garcia@apple.com>
Reviewed by thatcher
<rdar://problem/4044271>
Writing Direction menu doesn't reflect the current writing direction (9773)
* English.lproj/Localizable.strings: Added "Right to Left" and "Left to Right"
* WebView/WebHTMLView.m:
(-[NSArray validateUserInterfaceItem:]): Validate menu items that perform
toggleBaseWritingDirection and changeBaseWritingDirection.
Disable the menu item that changes the writing direction to NSWritingDirectionNautral
because NSWritingDirectionNatural's behavior can't be implemented with CSS.
Take control of the title of the menu item that performs toggleBaseWritingDirection:
instead of checking/unchecking it, otherwise we wouldn't know what a check means.
(-[NSArray changeBaseWritingDirection:]): ASSERT that the requested writing
direction is not NSWritingDirectionNatural, since we've disabled the
menu item that performs it.
2006-09-27 MorganL <morganl.webkit@yahoo.com>
Reviewed by Maciej, landed by Brady
Update URL request associated with provisional data source on redirect.
Notify IWebFrameLoadDelegate of redirects for the provisional load.
Notify IWebFrameLoadDelegate of a provisional load being commited.
* COM/WebDataSource.cpp:
(WebDataSource::replaceRequest):
* COM/WebDataSource.h:
* COM/WebFrame.cpp:
(WebFrame::receivedRedirect):
(WebFrame::receivedResponse):
(WebFrame::receivedData):
2006-09-26 John Sullivan <sullivan@apple.com>
Reviewed by Darin
* WebView/WebHTMLViewPrivate.h:
* WebView/WebHTMLView.m:
(-[WebHTMLView markAllMatchesForText:caseSensitive:limit:]):
Added limit parameter, passed over the bridge. Stop the search if it hits limit.
* WebView/WebViewPrivate.h:
* WebView/WebView.m:
(-[WebView markAllMatchesForText:caseSensitive:highlight:limit:]):
Added limit parameter, passed to WebHTMLView.
2006-09-26 David Harrison <harrison@apple.com>
Reviewed by John and TimH.
<rdar://problem/4743256> Seed: Ctrl-Y key binding does nothing when kill ring is empty
Use deleteBackward: when the killring string is empty. Was always using insertText:,
but that ends up early-returning if the string to insert is empty.
* WebView/WebHTMLView.m:
(-[NSArray yank:]):
(-[NSArray yankAndSelect:]):
2006-09-25 Timothy Hatcher <timothy@apple.com>
Reviewed by Brady.
Use the non-deprecated method names for getComputedStyle, setEnd and setStart.
* WebInspector/WebInspector.m:
(-[WebInspector _highlightNode:]):
* WebView/WebHTMLView.m:
(unionDOMRanges):
(-[WebHTMLView _selectRangeInMarkedText:]):
(-[WebTextCompleteController doCompletion]):
* WebView/WebView.m:
(-[WebView computedStyleForElement:pseudoElement:]):
2006-09-22 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Pass all headers through unifdef to filter out BUILDING_ON_TIGER blocks
if MACOSX_DEPLOYMENT_TARGET is 10.4.
* MigrateHeaders.make:
2006-09-20 Justin Garcia <justin.garcia@apple.com>
Reviewed by john
<http://bugs.webkit.org/show_bug.cgi?id=7165>
TinyMCE: Dragging & dropping content always leaves a copy when editing inside a subframe
The top level WebHTMLView is responsible for performing dragging operations, but
the inner view, the view that holds the drag caret, should be consulted to determine
if the drag is a move drag.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.m:
(-[NSArray dragImage:at:offset:event:pasteboard:source:slideBack:]): Don't set initatedDrag here, because
it's only the top level WebHTMLView that performs this operation.
(-[WebHTMLView _setInitiatedDrag:]): Added.
(-[WebHTMLView _initiatedDrag]): Ditto.
(-[WebHTMLView _canProcessDragWithDraggingInfo:]): Ask the innerView if it initiated the drag,
not the top level view.
(-[WebHTMLView _isMoveDrag]): The top level view asks the innerView if it should perform
a move drag, so don't ASSERT _isTopHTMLView.
(-[WebHTMLView draggingUpdatedWithDraggingInfo:actionMask:]): Ask the innerView if _isMoveDrag.
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]): Ditto.
* WebView/WebHTMLViewInternal.h: Added two private SPI so that
the top level WebHTMLView can set and get the initiatedDrag BOOL.
=== Safari-521.27 ===
2006-09-20 Brady Eidson <beidson@apple.com>
Reviewed by Tim Omernick
Fixing part of a crash Tim O showed me. [WebIconDatabase init] should finish
gracefully even if we can't open the database
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
2006-09-20 Timothy Hatcher <timothy@apple.com>
Reviewed by Tim O.
<rdar://problem/4741392> Develop a system to find what version of WebKit an app was linked with
* Misc/WebKitVersionChecks.h: Added.
* Misc/WebKitVersionChecks.m: Added.
(WebKitLinkedOnOrAfter): Added.
(WebKitLinkTimeVersion): Added.
(WebKitRunTimeVersion): Added.
* WebKit.xcodeproj/project.pbxproj:
2006-09-20 Tim Omernick <timo@apple.com>
Reviewed by Darin.
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
Fixed a typo.
2006-09-20 Brady Eidson <beidson@apple.com>
Reviewed by Darin
Preparing to make the WebIconDatabase disabled by default - this patch tells the bridge whether its enabled or not
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
2006-09-19 Brady Eidson <beidson@apple.com>
Reviewed by Sarge Decker
<rdar://problem/4739892> and <rdar://problem/4729797>
- WebCore::IconDatabase needs to have and respect an enabled() flag
- Mail on ToT WebKit crashes in IconDatabase code when mailing a page from Safari
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]): If preference says icons are disabled, tell the bridge
(-[WebIconDatabase _isEnabled]): Ask the bridge if the database is enabled
2006-09-19 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Tim O.
http://bugs.webkit.org/show_bug.cgi?id=10661
REGRESSION: CFM plug-ins (Shockwave, SVG) are not loaded
* Plugins/WebBasePluginPackage.m:
(-[WebBasePluginPackage initWithPath:]): On 32-bit PowerPC, don't bail out if
the bundle is nil - it can be a CFM plugin.
2006-09-18 Brady Eidson <beidson@apple.com>
Reviewed by Anders
Implement a bridge method so WebCore can find the reload type of a frame load
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge isLoadTypeReload]):
2006-09-18 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
Patch for http://bugs.webkit.org/show_bug.cgi?id=10903
Yet Another Objective-C Bindings Patch
* MigrateHeaders.make:
2006-09-17 David Harrison <harrison@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4494340> REGRESSION: Making the font size bigger/smaller in an HTML message doesn't affect the body until you reopen it
Problem was the public API -[WebView setTextSizeMultiplier] did not notify anyone that the value changed.
* WebView/WebDocumentInternal.h:
Add _textSizeMultiplierChanged to the _WebDocumentTextSizing protocol.
* WebView/WebHTMLView.m:
(-[WebHTMLView _textSizeMultiplierChanged]):
Send [self _updateTextSizeMultiplier].
* WebView/WebPDFView.m:
(-[WebPDFView _textSizeMultiplierChanged]):
ASSERT_NOT_REACHED() because WebPDFView does not track the common multiplier.
* WebView/WebView.m:
(-[WebView setTextSizeMultiplier:]):
Send [self _notifyTextSizeMultiplierChanged];
(-[WebView _performTextSizingSelector:withObject:onTrackingDocs:selForNonTrackingDocs:newScaleFactor:]):
Alter the _textSizeMultiplier directly so that notification is not sent.
Minor formatting.
(-[WebView _notifyTextSizeMultiplierChanged]):
New. Send _textSizeMultiplierChanged to all document views that track the common multiplier.
2006-09-16 Brady Eidson <beidson@apple.com>
Reviewed by Hyatt
WebIconLoader is dead, long live WebCore::IconLoader
(code prune)
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader dealloc]):
(-[WebFrameLoader commitProvisionalLoad]):
* Loader/WebIconLoader.h: Removed.
* Loader/WebIconLoader.m: Removed.
* Misc/WebIconDatabase.h:
* Misc/WebIconDatabase.m:
* Misc/WebIconDatabasePrivate.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge notifyIconChanged:]):
* WebCoreSupport/WebIconDatabaseBridge.h:
* WebCoreSupport/WebIconDatabaseBridge.m:
(-[WebIconDatabaseBridge _init]):
(-[WebIconDatabaseBridge _setIconData:forIconURL:]):
(-[WebIconDatabaseBridge _setHaveNoIconForIconURL:]):
* WebKit.exp:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _stopLoading]):
(-[WebDataSource _setPrimaryLoadComplete:]):
* WebView/WebDataSourceInternal.h:
2006-09-16 Mark Rowe <opendarwin.org@bdash.net.nz>
Reviewed by Anders.
http://bugs.webkit.org/show_bug.cgi?id=10887
Fix build error
* MigrateHeaders.make: Remove reference to DOMEventPrivate.h.
2006-09-15 Timothy Hatcher <timothy@apple.com>
Reviewed by Brady.
Make new style ObjC methods public API.
* MigrateHeaders.make:
2006-09-15 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
Patch for http://bugs.webkit.org/show_bug.cgi?id=10870
Auto-generate DOMNode for the Objective-C bindings
* MigrateHeaders.make:
2006-09-15 Timothy Hatcher <timothy@apple.com>
Reviewed by Justin.
Call the bridge directly for alter selection calls. All of this logic is now
in WebCore's SelectionController.
* WebView/WebHTMLView.m:
(-[NSArray moveBackward:]):
(-[NSArray moveBackwardAndModifySelection:]):
(-[NSArray moveDown:]):
(-[NSArray moveDownAndModifySelection:]):
(-[NSArray moveForward:]):
(-[NSArray moveForwardAndModifySelection:]):
(-[NSArray moveLeft:]):
(-[NSArray moveLeftAndModifySelection:]):
(-[NSArray moveRight:]):
(-[NSArray moveRightAndModifySelection:]):
(-[NSArray moveToBeginningOfDocument:]):
(-[NSArray moveToBeginningOfDocumentAndModifySelection:]):
(-[NSArray moveToBeginningOfSentence:]):
(-[NSArray moveToBeginningOfSentenceAndModifySelection:]):
(-[NSArray moveToBeginningOfLine:]):
(-[NSArray moveToBeginningOfLineAndModifySelection:]):
(-[NSArray moveToBeginningOfParagraph:]):
(-[NSArray moveToBeginningOfParagraphAndModifySelection:]):
(-[NSArray moveToEndOfDocument:]):
(-[NSArray moveToEndOfDocumentAndModifySelection:]):
(-[NSArray moveToEndOfSentence:]):
(-[NSArray moveToEndOfSentenceAndModifySelection:]):
(-[NSArray moveToEndOfLine:]):
(-[NSArray moveToEndOfLineAndModifySelection:]):
(-[NSArray moveToEndOfParagraph:]):
(-[NSArray moveToEndOfParagraphAndModifySelection:]):
(-[NSArray moveParagraphBackwardAndModifySelection:]):
(-[NSArray moveParagraphForwardAndModifySelection:]):
(-[NSArray moveUp:]):
(-[NSArray moveUpAndModifySelection:]):
(-[NSArray moveWordBackward:]):
(-[NSArray moveWordBackwardAndModifySelection:]):
(-[NSArray moveWordForward:]):
(-[NSArray moveWordForwardAndModifySelection:]):
(-[NSArray moveWordLeft:]):
(-[NSArray moveWordLeftAndModifySelection:]):
(-[NSArray moveWordRight:]):
(-[NSArray moveWordRightAndModifySelection:]):
(-[NSArray pageUp:]):
(-[NSArray pageDown:]):
(-[NSArray pageUpAndModifySelection:]):
(-[NSArray pageDownAndModifySelection:]):
2006-09-15 Adam Roben <aroben@apple.com>
Reviewed by eseidel.
Fixes http://bugs.webkit.org/show_bug.cgi?id=10876
containsItemForURLUnicode uses matchLetter instead of
matchUnicodeLetter
Small fixes for _WebCoreHistoryProvider.
* History/WebHistory.m: Consistently use BUFFER_SIZE #define
(-[_WebCoreHistoryProvider containsItemForURLLatin1:length:]):
(-[_WebCoreHistoryProvider containsItemForURLUnicode:length:]):
Replace incorrect call to matchLetter to matchUnicodeLetter
2006-09-13 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Add infrastructure to support icon loads taking place in WebCore
Will remove WebKit icon loaders in a later patch
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge notifyIconChanged:]):
(-[WebFrameBridge originalRequestURL]):
- Nuked two old, obsolete methods
- Added bridge for notifying of an icon change
- Added bridge for getting the "original request URL" which is still needed
until that info is available in the WebCore loaders
* WebView/WebDataSource.m:
(-[WebDataSource _loadIcon]):
- Empty body just for now, as it still gets called - next patch will prune all the old impl out
2006-09-13 Timothy Hatcher <timothy@apple.com>
Reviewed by Tim O.
<rdar://problem/4726416> obsolete confusing "ADVISORY NOTE" comment in WebHistory.h
Removed the "ADVISORY NOTE: This method may change for the 1.0 SDK" comments.
* History/WebHistory.h:
=== Safari-521.26 ===
2006-09-11 MorganL <morlmor@yahoo.com>
Reviewed/landed by aroben.
Fixes http://bugs.webkit.org/show_bug.cgi?id=10765
Windows build busted due to std::copy usage in Vector.h
* WebKit.vcproj/WebKit.vcproj: Define _SCL_SECURE_NO_DEPRECATE to get
rid of deprecation warnings on std::copy
2006-09-11 Brady Eidson <beidson@apple.com>
Despite the fact that some people built okay without this change, it sure was biting me,
probably because I just wiped my build directory for a fresh build -
Today's earlier removal of DOMList.h needed to occur in MigrateHeaders.make, as well
* MigrateHeaders.make: removed DOMList.h
2006-09-10 Darin Adler <darin@apple.com>
Reviewed by Brady.
- fix http://bugs.webkit.org/show_bug.cgi?id=10547
REGRESSION: Links that should open in a new window open in the same window,
while opening another blank window
* WebView/WebFrame.m:
(-[WebFrame _continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
Changed a mistaken "self" to "frame", which was the cause of the bug. Also
fixed the method so that it won't crash if createWebViewWithRequest does
something that has a side effect of releasing this WebView or this frame
by retaining "self" and "frame" as needed. Also fixed a problem where the
code to set "opener" was backwards, and would set the opener of the old
frame to point to the new frame instead of vice versa.
2006-09-09 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Eric.
Patch for http://bugs.webkit.org/show_bug.cgi?id=10795
Auto-generate the Objective-C DOM XPath bindings
* MigrateHeaders.make:
2006-09-09 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Eric.
Patch for http://bugs.webkit.org/show_bug.cgi?id=10791
Even More Objective-C DOM auto-generation cleanup
* MigrateHeaders.make:
2006-09-08 Tim Omernick <timo@apple.com>
Reviewed by Brady Eidson.
Rolled out Maciej's code cleanup from 8/22. It turns out that keeping the "loading" flag
is a useful optimization, as it avoids many Objective-C method calls while polling resources
for their load state.
This fixes a 3-4% PLT performance regression (as measured on my MacBook Pro).
* Loader/WebFrameLoader.m:
(-[WebFrameLoader addPlugInStreamLoader:]):
(-[WebFrameLoader removePlugInStreamLoader:]):
(-[WebFrameLoader addSubresourceLoader:]):
(-[WebFrameLoader removeSubresourceLoader:]):
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _prepareForLoadStart]):
(-[WebDataSource _setLoading:]):
(-[WebDataSource _updateLoading]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _stopLoading]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource isLoading]):
* WebView/WebDataSourceInternal.h:
2006-09-07 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Darin and Tim H.
Patch for http://bugs.webkit.org/show_bug.cgi?id=10774
Auto-generate the Objective-C DOM Traversal bindings
* MigrateHeaders.make:
2006-09-07 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Darin.
Patch for http://bugs.webkit.org/show_bug.cgi?id=10766
Auto-generate the Objective-C DOM Events bindings
* MigrateHeaders.make:
* WebKit.xcodeproj/project.pbxproj:
2006-09-06 Alexey Proskuryakov <ap@nypop.com>
* MigrateHeaders.make: Fixed a double slash in
"$(PRIVATE_HEADERS_DIR)//DOMCharacterDataPrivate.h" (this was reported
to cause a build failure under certain circumstances).
2006-09-05 MorganL <morlmor@yahoocom>
Reviewed/landed by aroben.
Fixes bug 10743: Windows build is busted.
* COM/WebView.cpp:
(WebView::keyPress):
2006-09-05 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Drastically simplified the makefile for migrating headers from
WebCore and JavaScriptCore. The old version was always copying the files.
* MigrateHeaders.make:
2006-09-05 Darin Adler <darin@apple.com>
Reviewed by Alexey.
- WebKit side of changes to encoding
* WebView/WebHTMLRepresentation.m: (-[WebHTMLRepresentation documentSource]):
Changed to call new -[WebCoreFrameBridge stringWithData:] instead of the calling
the old methods that used a CFStringEncoding: -[WebCoreFrameBridge textEncoding]
and +[WebCoreFrameBridge stringWithData:textEncoding:].
* WebView/WebResource.m: (-[WebResource _stringValue]): Removed special case for
nil encoding name. The bridge itself now has the rule that "nil encoding name
means Latin-1", so we don't need to check for nil.
* WebView/WebFrame.m: (-[WebFrame _checkLoadComplete]): Retain the frame until
we get the parent frame while walking up parent frames, because it's possible
for _checkLoadCompleteForThisFrame to release the last reference to the frame.
(Not reviewed; needed to run performance tests successfully.)
2006-09-05 Timothy Hatcher <timothy@apple.com>
Reviewed by Tim O.
<rdar://problem/4682225> conflicting typedefs in Netscape plug-in headers
* Plugins/npfunctions.h: fix the return type for NPN_IntFromIdentifierProcPtr to be int32_t
2006-09-04 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Bug 10714: ObjC autogeneration needs safe-guards against easily modifying the public API
http://bugs.webkit.org/show_bug.cgi?id=10714
- Added the new private DOM headers.
- Factored out the common commands into variables.
- Made WebDashboardRegion.h private again.
- Rename DOMDOMImplementation.h to DOMImplementation.h when files
are migrated. Also fixes up #imports.
* MigrateHeaders.make:
2006-09-03 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Darin and Tim H.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10711
Auto-generate the Objective-C DOM Stylesheet bindings
* MigrateHeaders.make:
2006-09-02 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10684
Auto-generate the Objective-C DOM CSS bindings
* MigrateHeaders.make:
2006-09-01 MorganL <morlmor@yahoo.com>
Reviewed by Darin. Updated/landed by Adam.
Fixes http://bugs.webkit.org/show_bug.cgi?id=10553
Windows build fixes
* COM/WebFrame.cpp:
(WebFrame::initWithName):
2006-09-01 Brady Eidson <beidson@apple.com>
Reviewed by Darin
A "never should be reached" method was reached - lets not release the shared database bridge, esp
since we never retain it!
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _applicationWillTerminate:]): Don't release the bridge
2006-09-01 Darin Adler <darin@apple.com>
Reviewed by Brady.
- a few small tweaks to the icon database bridge
* Misc/WebIconDatabase.m: (-[WebIconDatabase init]): Updated for name change.
* WebCoreSupport/WebIconDatabaseBridge.h: Removed unneeded declarations.
* WebCoreSupport/WebIconDatabaseBridge.m:
(-[WebIconDatabaseBridge init]): Added. Always returns nil since you're not supposed
to allocate one of these.
(-[WebIconDatabaseBridge _init]): Renamed from init. Used internally to make the
shared instance. Added the "self = [super init]" idiom even though it's not important
in this case just to be consistent.
(-[WebIconDatabaseBridge releaseCachedLoaderForIconURL:]): Moved this up in the file
so it can be called without declaring it in the header.
(+[WebIconDatabaseBridge sharedInstance]): Renamed. Calls the new _init. Also use
CFRetain for compatibility.
(-[WebIconDatabaseBridge dealloc]): Emptied this out and made it just assert (false).
(-[WebIconDatabaseBridge finalize]): Added and made it assert (false) too.
2006-09-01 Timothy Hatcher <timothy@apple.com>
Reviewed by Adele.
Bug 10677: Omit "-webkit-text-security: none;" from the computed style list
http://bugs.webkit.org/show_bug.cgi?id=10677
* WebInspector/webInspector/inspector.js:
2006-08-31 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10669
Auto-generate the remaining Objective-C HTML DOM bindings
* MigrateHeaders.make:
2006-08-31 Adele Peterson <adele@apple.com>
Reviewed by Darin.
WebKit part of fix for http://bugs.webkit.org/show_bug.cgi?id=10666
Password: Disallow Spelling, Font, Speech, and Writing Direction context menu
* DefaultDelegates/WebDefaultContextMenuDelegate.m: (-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
Check that the selection isn't in a password field before adding these items to the default editing context menu.
Search In Google, Search In Spotlight, Look up in Dictionary, Spelling, Font, Speech, Writing Direction
* WebView/WebHTMLView.m: (-[WebHTMLView _isSelectionInPasswordField]): Added.
* WebView/WebHTMLViewPrivate.h:
2006-08-31 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10653
Auto-generate another 20 Objective-C DOM HTML bindings
* MigrateHeaders.make:
* WebKit.xcodeproj/project.pbxproj:
2006-08-31 Adele Peterson <adele@apple.com>
Reviewed by John Sullivan.
Removed wkSecureEventInput and wkSetSecureEventInput, since this can be done with API.
* WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface):
2006-08-31 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick
- fixed <rdar://problem/4711200> Loading history would be faster if it bypassed
NSURL API for local files
* History/WebHistory.m:
(-[WebHistoryPrivate _loadHistoryGutsFromURL:savedItemsCount:collectDiscardedItemsInto:error:]):
Load file URLs using [NSDictionary dictionaryWithContentsOfFile:]. I also cleaned up some minor
style issues in this method, and I removed the support for old NSArray-style history files (which we
stopped using before Safari 1.0).
2006-08-30 Adele Peterson <adele@apple.com>
Reviewed by Hyatt.
WebKit part of fix for http://bugs.webkit.org/show_bug.cgi?id=10575
Enable secure input mode for new password fields
* WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface):
2006-08-30 Brady Eidson <beidson@apple.com>
Reviewed by John
<rdar://problem/4707718> Change behavior so if the WebCore::IconDatabase can't open, WebKit releases the bridge and
continues on as if the IconDatabase is disabled.
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]): Release the bridge on failure to open
* WebCoreSupport/WebIconDatabaseBridge.m:
(+[WebIconDatabaseBridge sharedBridgeInstance]): Moved static shared instance out as a global
(-[WebIconDatabaseBridge dealloc]): Clear pointer to the shared instance
2006-08-30 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Simplify the header copies from WebCore and JavaScriptCore.
Headers that need to be migrated from the other projects need
to be added to MigrateHeaders.make.
* MigrateHeaders.make: Added.
* WebKit.xcodeproj/project.pbxproj:
2006-08-30 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10640
Auto-generate 10 more Objective-C DOM HTML bindings
* WebKit.xcodeproj/project.pbxproj:
2006-08-30 Adele Peterson <adele@apple.com>
Reviewed by Darin.
WebKit part of fix for:
http://bugs.webkit.org/show_bug.cgi?id=10576
Disallow copy from new password fields
* WebView/WebHTMLView.m:
(-[WebHTMLView _canCopy]): Now also calls across the bridge to ask if it mayCopy.
(-[WebHTMLView _canCut]): Calls _canCopy now.
(-[NSArray validateUserInterfaceItem:]): Calls _canCut when validating the "Cut" menu item.
This used to call _canDelete (which used to be the same as _canCut), but now _canCut also checks _canCopy.
2006-08-30 Karl Adam <karladam@yahoo-inc.com>
Reviewed by Eric and Tim H.
Bug 10634: -webView:dragDestinationActionMaskForDraggingInfo: is ignored
http://bugs.webkit.org/show_bug.cgi?id=10634
Remove the check for canShowFile: from _web_bestURL: since
it shouldn't be concerned with whether or not the view
can show the URL, merely return the most appropriate URL.
* Misc/WebNSPasteboardExtras.m:
(-[NSPasteboard _web_bestURL]):
* Misc/WebNSViewExtras.m:
(-[NSView _web_dragOperationForDraggingInfo:]):
2006-08-29 Brady Eidson <beidson@apple.com>
Reviewed by Kevin Decker (Sarge)
<rdar://problem/4678414> - New IconDB needs to delete icons when asked
* Misc/WebIconDatabase.m:
(-[WebIconDatabase removeAllIcons]): Call through to WebCore to remove icons, then send notification
2006-08-29 Brady Eidson <beidson@apple.com>
Reviewed by Alice
Added a truth value check for to setIconURL:forURL so WebKit can avoid sending a notification
This is a win on the iBench
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _setIconURL:forURL:]):
2006-08-29 Brady Eidson <beidson@apple.com>
Reviewed by Tim Hatchers rubber stamp
Removed some accidentally left-in console spew during the conversion to the new DB
* Misc/WebIconDatabase.m:
(objectFromPathForKey): Nuked some NSLogs
2006-08-29 Tim Omernick <timo@apple.com>
Reviewed by Darin Adler.
<rdar://problem/4688618> REGRESSION(10.4.7-9A241): JMol java applet fails in Safari not Firefox
No layout test for now because Java doesn't work in DumpRenderTree.
* Plugins/WebPluginDatabase.m:
(-[WebPluginDatabase refresh]):
Add each plug-in MIME type to registeredMIMETypes, even if we don't register a document view class for the
MIME type. This fixes -[WebPluginDatabase isMIMETypeRegistered:] and thus fallback content for Java applets
(we were always rendering fallback content, if any, for Java applets).
2006-08-29 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10628
Auto-generate the remaining Objective-C DOM bindings
Auto-generates DOMHTMLCollection, DOMHTMLElement, DOMHTMLFormElement,
and DOMHTMLOptionsCollection.
* WebKit.xcodeproj/project.pbxproj:
2006-08-28 Brady Eidson <beidson@apple.com>
Reviewed by Darin
Short of a few small snippets that still need to be pushed to WebCore, this
is a final prune of WebIconDatabase. WebFileDatabase and WebLRUFileList are gone
and the small remaining snippets of WebFileDatabase code that were still important
are now in static functions in WebIconDatabase.m
* Loader/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]): Removed the flag
* Misc/WebFileDatabase.h: Removed.
* Misc/WebFileDatabase.m: Removed.
* Misc/WebIconDatabase.m:
(+[WebIconDatabase sharedIconDatabase]):
(-[WebIconDatabase init]):
(-[WebIconDatabase iconForURL:withSize:cache:]):
(-[WebIconDatabase iconURLForURL:]):
(-[WebIconDatabase defaultIconWithSize:]):
(-[WebIconDatabase retainIconForURL:]):
(-[WebIconDatabase releaseIconForURL:]):
(-[WebIconDatabase _isEnabled]):
(-[WebIconDatabase _setIconData:forIconURL:]):
(-[WebIconDatabase _setHaveNoIconForIconURL:]):
(-[WebIconDatabase _setIconURL:forURL:]):
(-[WebIconDatabase _hasEntryForIconURL:]):
(-[WebIconDatabase _applicationWillTerminate:]):
(-[WebIconDatabase _resetCachedWebPreferences:]):
(uniqueFilePathForKey): Added from WebFileDatabase
(objectFromPathForKey): Added from WebFileDatabase
(iconDataFromPathForIconURL):
(-[WebIconDatabase _convertToWebCoreFormat]): Make use of static functions and local variables
instead of using WebFileDatabase and WebIconDatabase variables that are now obsolete
* Misc/WebIconDatabasePrivate.h: Removed alot of obsoleted members
* Misc/WebLRUFileList.h: Removed.
* Misc/WebLRUFileList.m: Removed.
* WebKit.xcodeproj/project.pbxproj: Deleted 4 files
* WebKitPrefix.h: Removed ICONDEBUG
2006-08-28 Tim Omernick <timo@apple.com>
Reviewed by Darin Adler.
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView createPluginScriptableObject]):
Removed a bogus typecast.
2006-08-28 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
Part of <rdar://problem/4481553> NetscapeMoviePlugIn example code scripting doesn't work in Firefox (4319)
<http://bugs.webkit.org/show_bug.cgi?id=4319>: NetscapeMoviePlugIn example code scripting doesn't work
in Firefox
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView createPluginScriptableObject]):
Renamed this method (see corresponding WebCore ChangeLog entry for an explanation).
Style changes.
2006-08-28 Brady Eidson <beidson@apple.com>
Reviewed by Tim Hatcher's rubberstamp
Rolled out my last change (16070 - pruning WebFileDatabase code) as it caused a difficult-to-track down
failure in layout tests on a release build.
* Misc/WebFileDatabase.h:
* Misc/WebFileDatabase.m:
(+[WebFileDatabaseOp opWithCode:key:object:]):
(-[WebFileDatabaseOp initWithCode:key:object:]):
(-[WebFileDatabaseOp opcode]):
(-[WebFileDatabaseOp key]):
(-[WebFileDatabaseOp object]):
(-[WebFileDatabaseOp perform:]):
(-[WebFileDatabaseOp dealloc]):
(SetThreadPriority):
(-[WebFileDatabase _createLRUList:]):
(-[WebFileDatabase _truncateToSizeLimit:]):
(+[WebFileDatabase _syncLoop:]):
(databaseInit):
(-[WebFileDatabase setTimer]):
(-[WebFileDatabase setObject:forKey:]):
(-[WebFileDatabase removeObjectForKey:]):
(-[WebFileDatabase removeAllObjects]):
(-[WebFileDatabase objectForKey:]):
(-[WebFileDatabase performSetObject:forKey:]):
(-[WebFileDatabase performRemoveObjectForKey:]):
(-[WebFileDatabase open]):
(-[WebFileDatabase close]):
(-[WebFileDatabase lazySync:]):
(-[WebFileDatabase sync]):
(-[WebFileDatabase sizeLimit]):
(-[WebFileDatabase count]):
(-[WebFileDatabase usage]):
(-[WebFileDatabase setSizeLimit:]):
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _createFileDatabase]):
(-[WebIconDatabase _loadIconDictionaries]):
* WebKit.xcodeproj/project.pbxproj:
2006-08-28 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
* WebInspector/webInspector/inspector.js: Add "resize: none" to the list of
default values for CSS properties so it will be omitted from most displays
of computed style.
2006-08-28 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Major prune of unnecessary WebFileDatabase code. In the end, what
useful code that remains in WebFileDatabase will likely be moved directly
into WebIconDatabase
* Misc/WebFileDatabase.h:
* Misc/WebFileDatabase.m:
(-[WebFileDatabase initWithPath:]):
(-[WebFileDatabase objectForKey:]):
(-[WebFileDatabase open]):
(-[WebFileDatabase close]):
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _createFileDatabase]):
(-[WebIconDatabase _loadIconDictionaries]):
* Misc/WebLRUFileList.h: Removed.
* Misc/WebLRUFileList.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
2006-08-27 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Tim H.
- patch for http://bugs.webkit.org/show_bug.cgi?id=4624
WebCore needs autogenerated Obj-C DOM bindings
First round of auto-generated Objective C DOM bindings, starting
with the DOM Core.
* WebKit.xcodeproj/project.pbxproj:
2006-08-25 Brady Eidson <beidson@apple.com>
Reviewed by Tim Hatcher
Fixed up some leaks on [WebIconDatabase init]
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
2006-08-24 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
* WebView/WebFrame.m:
(-[WebFrame _updateBackground]): reworded the comment about scroll view and setDrawsBackground:YES
* WebView/WebView.m:
(-[WebViewPrivate dealloc]): release the background color
2006-08-24 Timothy Hatcher <timothy@apple.com>
Reviewed by Hyatt.
WebView API to allow changing the background color that draws under transparent page backgrounds.
* WebView/WebFrame.m:
(-[WebFrame _makeDocumentView]):
(-[WebFrame _updateBackground]):
* WebView/WebFrameInternal.h:
* WebView/WebFrameView.m:
(-[WebFrameView drawRect:]):
* WebView/WebView.m:
(-[WebView setBackgroundColor:]):
(-[WebView backgroundColor]):
(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView setDrawsBackground:]):
* WebView/WebViewPrivate.h:
2006-08-24 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Fix for Mail stationary. Selecting a stationary item would cause this exception.
*** -[WebSubresourceLoader copyWithZone:]: selector not recognized
Uncaught exception - *** -[WebSubresourceLoader copyWithZone:]: selector not recognized
* Loader/WebFrameLoader.m:
(-[WebFrameLoader willUseArchiveForRequest:originalURL:loader:]):
Use _webkit_setObject:forUncopiedKey: when addign the resource to pendingArchivedResources.
2006-08-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adele.
- fix assertion which I accidentally changed to one that sometimes fails
http://bugs.webkit.org/show_bug.cgi?id=10531
* Loader/WebDocumentLoadState.m:
(-[WebDocumentLoadState dealloc]):
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource dealloc]):
2006-08-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
- move WebFrame code that creates WebDataSources down to WebFrameLoader, in preparation
for WebFrameLoader just holding on to WebDocumentLoadState
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _loadRequest:archive:]):
(-[WebFrameLoader _loadRequest:triggeringAction:loadType:formState:]):
(-[WebFrameLoader _reloadAllowingStaleDataWithOverrideEncoding:]):
(-[WebFrameLoader reload]):
* WebView/WebFrame.m:
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _continueLoadRequestAfterNewWindowPolicy:frameName:formState:]):
(-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrame _postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrame _shouldReloadToHandleUnreachableURLFromRequest:]):
(-[WebFrame loadRequest:]):
(-[WebFrame loadArchive:]):
(-[WebFrame reload]):
* WebView/WebFrameInternal.h:
* WebView/WebFramePrivate.h:
* WebView/WebView.m:
(-[WebView setCustomTextEncodingName:]):
2006-08-23 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
First pass at pruning unused WebIconDatabase code. Focus on removing methods that simply
have no place in the new DB at all. A few renames and a few important FIXMEs result, but no
functionality changes.
* Loader/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]): Call to WebIconDatabase instead of directly to the bridge
* Misc/WebIconDatabase.h:
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
(-[WebIconDatabase iconForURL:withSize:cache:]):
(-[WebIconDatabase iconURLForURL:]):
(-[WebIconDatabase defaultIconWithSize:]):
(-[WebIconDatabase retainIconForURL:]):
(-[WebIconDatabase releaseIconForURL:]):
(-[WebIconDatabase removeAllIcons]):
(-[WebIconDatabase _setIconData:forIconURL:]):
(-[WebIconDatabase _setHaveNoIconForIconURL:]):
(-[WebIconDatabase _setIconURL:forURL:]):
(-[WebIconDatabase _hasEntryForIconURL:]):
(-[WebIconDatabase _applicationWillTerminate:]):
(-[WebIconDatabase _resetCachedWebPreferences:]):
* Misc/WebIconDatabasePrivate.h: Changed setIcon: to setIconData:
2006-08-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adele.
- started factoring most of the guts of WebDataSource into a new class
WebDocumentLoadState is decoupled from the rest of WebKit and will
be moved down to WebCore. I only moved one of the data fields of
WebDataSource for now.
* Loader/WebDocumentLoadState.h: Added.
* Loader/WebDocumentLoadState.m: Added.
(-[WebDocumentLoadState initWithRequest:]): New class.
(-[WebDocumentLoadState dealloc]):
(-[WebDocumentLoadState setFrameLoader:]):
(-[WebDocumentLoadState setMainResourceData:]):
(-[WebDocumentLoadState mainResourceData]):
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _setDataSource:]): Remove redundant _setWebFrame: call,
it would have been called already by this point.
(-[WebFrameLoader _setProvisionalDataSource:]): ditto.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _setWebFrame:]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource initWithRequest:]):
(-[WebDataSource data]):
2006-08-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adele.
- refactoring of WebDataSource in preparation for moving a bunch of it to a new class
- minimize WebDataSourceInternal.h to be only methods called from outside WebDataSource
- reduce Private category implementation to be only the SPI methods
- make new Internal and FileInternal categories which contain the
remainder (depending on whether they are called from outside of
WebDataSource)
* WebView/WebDataSource.m:
(-[WebDataSource _setMainDocumentError:]):
(addTypesFromClass):
(+[WebDataSource _representationClassForMIMEType:]):
(-[WebDataSource _commitIfReady]):
(-[WebDataSource _commitLoadWithData:]):
(-[WebDataSource _doesProgressiveLoadWithMIMEType:]):
(-[WebDataSource _addResponse:]):
(-[WebDataSource _revertToProvisionalState]):
(-[WebDataSource _mainDocumentError]):
(-[WebDataSource _addSubframeArchives:]):
(-[WebDataSource _fileWrapperForURL:]):
(+[WebDataSource _repTypesAllowImageTypeOmission:]):
(-[WebDataSource _decidePolicyForMIMEType:decisionListener:]):
(-[WebDataSource _finishedLoading]):
(-[WebDataSource _setResponse:]):
(-[WebDataSource _setRequest:]):
(-[WebDataSource _setupForReplaceByMIMEType:]):
(-[WebDataSource _receivedMainResourceError:complete:]):
(-[WebDataSource _mainReceivedError:complete:]):
(-[WebDataSource _defersCallbacks]):
(-[WebDataSource _downloadWithLoadingConnection:request:response:proxy:]):
(-[WebDataSource _didFailLoadingWithError:forResource:]):
(-[WebDataSource _didFinishLoadingForResource:]):
(-[WebDataSource _didReceiveData:contentLength:forResource:]):
(-[WebDataSource _didReceiveResponse:forResource:]):
(-[WebDataSource _didCancelAuthenticationChallenge:forResource:]):
(-[WebDataSource _didReceiveAuthenticationChallenge:forResource:]):
(-[WebDataSource _willSendRequest:forResource:redirectResponse:]):
(-[WebDataSource _identifierForInitialRequest:]):
(-[WebDataSource _archivedSubresourceForURL:]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _stopRecordingResponses]):
(-[WebDataSource _loadingStartedTime]):
(-[WebDataSource _replaceSelectionWithArchive:selectReplacement:]):
(-[WebDataSource _documentFragmentWithArchive:]):
(-[WebDataSource _documentFragmentWithImageResource:]):
(-[WebDataSource _imageElementWithImageResource:]):
(-[WebDataSource _title]):
(-[WebDataSource _isStopping]):
(-[WebDataSource _setWebFrame:]):
(-[WebDataSource _URL]):
(-[WebDataSource _loadFromPageCache:]):
(-[WebDataSource _popSubframeArchiveWithName:]):
(-[WebDataSource _setIsClientRedirect:]):
(-[WebDataSource _setURL:]):
(-[WebDataSource _setLastCheckedRequest:]):
(-[WebDataSource _defersCallbacksChanged]):
(-[WebDataSource _lastCheckedRequest]):
(-[WebDataSource _stopLoading]):
(-[WebDataSource _bridge]):
(-[WebDataSource _webView]):
(-[WebDataSource _triggeringAction]):
(-[WebDataSource _setTriggeringAction:]):
(-[WebDataSource __adoptRequest:]):
(-[WebDataSource _isDocumentHTML]):
(-[WebDataSource _stopLoadingWithError:]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource _responses]):
(-[WebDataSource _makeRepresentation]):
(-[WebDataSource _isClientRedirect]):
(-[WebDataSource _originalRequest]):
(-[WebDataSource _URLForHistory]):
(-[WebDataSource _addToUnarchiveState:]):
(-[WebDataSource _setOverrideEncoding:]):
(-[WebDataSource _setIconURL:]):
(-[WebDataSource _setIconURL:withType:]):
(-[WebDataSource _overrideEncoding]):
(-[WebDataSource _setTitle:]):
* WebView/WebDataSourceInternal.h:
2006-08-23 Brady Eidson <beidson@apple.com>
Reviewed by John Sullivan
/me crosses fingers
Flip the switch to the new Icon Database
Massive code pruning is coming up
* WebKitPrefix.h: Flipped the switch
2006-08-23 Brady Eidson <beidson@apple.com>
Reviewed by Beth
Since I just pushed the default URL icon from WebKit to WebCore, but
WebKit was still using its version of the default icon, this patch makes it
use the WebCore version
* Misc/WebIconDatabase.m:
(-[WebIconDatabase defaultIconWithSize:]):
2006-08-22 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
- remove "loading" flag from WebDataSource and code that manages it; it is redundat.
* Loader/WebFrameLoader.m:
(-[WebFrameLoader addPlugInStreamLoader:]):
(-[WebFrameLoader removePlugInStreamLoader:]):
(-[WebFrameLoader addSubresourceLoader:]):
(-[WebFrameLoader removeSubresourceLoader:]):
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource _stopLoading]):
(-[WebDataSource _prepareForLoadStart]):
(-[WebDataSource _startLoading]):
(-[WebDataSource isLoading]):
* WebView/WebDataSourceInternal.h:
2006-08-22 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
<rdar://problem/4683948> REGRESSION: Assertion failure in [FrameProgressEntry addChild:forDataSource:] (fandango.com)
* Loader/WebFrameLoader.m:
(-[WebFrameLoader addSubresourceLoader:]): Add a WebKit-level assertion that should fire when this bad
situation occurs.
* Loader/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forFrameLoader:]): Prevent
the situation from occuring.
2006-08-22 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- pull more WebDataSource code into WebFrameLoader
- make WebMainResourceLoader not depend on WebKit or on SPI
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _downloadWithLoadingConnection:request:response:proxy:]):
(-[WebFrameLoader _updateIconDatabaseWithURL:]):
(-[WebFrameLoader _notifyIconChanged:]):
(-[WebFrameLoader _iconLoaderReceivedPageIcon:]):
(-[WebFrameLoader _checkNavigationPolicyForRequest:andCall:withSelector:]):
(-[WebFrameLoader _checkContentPolicyForMIMEType:andCall:withSelector:]):
(-[WebFrameLoader cancelContentPolicy]):
* Loader/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]):
* Loader/WebLoader.m:
(-[NSURLProtocol loadWithRequest:]):
(-[NSURLProtocol setDefersCallbacks:]):
* Loader/WebMainResourceLoader.h:
* Loader/WebMainResourceLoader.m:
(-[WebMainResourceLoader initWithFrameLoader:]):
(-[WebMainResourceLoader dealloc]):
(-[WebMainResourceLoader cancelWithError:]):
(-[WebMainResourceLoader continueAfterNavigationPolicy:formState:]):
(-[WebMainResourceLoader willSendRequest:redirectResponse:]):
(-[WebMainResourceLoader continueAfterContentPolicy:]):
(-[WebMainResourceLoader checkContentPolicy]):
(-[WebMainResourceLoader didReceiveResponse:]):
* Plugins/WebPluginContainerCheck.m:
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
* WebView/WebDataSource.m:
(-[WebDataSource _loadIcon]):
(-[WebDataSource _cancelledError]):
(+[WebDataSource _repTypesAllowImageTypeOmission:]):
(+[WebDataSource _representationClassForMIMEType:]):
(-[WebDataSource _commitLoadWithData:]):
(-[WebDataSource _isDocumentHTML]):
* WebView/WebDataSourceInternal.h:
* WebView/WebFramePrivate.h:
* WebView/WebPolicyDelegate.m:
* WebView/WebPolicyDelegatePrivate.h:
2006-08-21 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
- move more code from WebDataSource to WebFrameLoader
Also marked a few more methods in WebDataSource as likely MOVABLE in a future round, since they do not
use any of WebDataSource's private data.
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader addPlugInStreamLoader:]):
(-[WebFrameLoader removePlugInStreamLoader:]):
(-[WebFrameLoader addSubresourceLoader:]):
(-[WebFrameLoader removeSubresourceLoader:]):
(-[WebFrameLoader _didReceiveAuthenticationChallenge:forResource:]):
(-[WebFrameLoader _didCancelAuthenticationChallenge:forResource:]):
(-[WebFrameLoader _didReceiveResponse:forResource:]):
(-[WebFrameLoader _didReceiveData:contentLength:forResource:]):
(-[WebFrameLoader _didFinishLoadingForResource:]):
(-[WebFrameLoader _didFailLoadingWithError:forResource:]):
(-[WebFrameLoader _privateBrowsingEnabled]):
(-[WebFrameLoader _finishedLoadingResource]):
(-[WebFrameLoader _receivedError:]):
(-[WebFrameLoader _finishedLoading]):
* Loader/WebMainResourceLoader.m:
(-[WebMainResourceLoader didReceiveData:lengthReceived:allAtOnce:]):
(-[WebMainResourceLoader didFinishLoading]):
* Loader/WebNetscapePlugInStreamLoader.m:
(-[WebNetscapePlugInStreamLoader didFinishLoading]):
(-[WebNetscapePlugInStreamLoader didFailWithError:]):
(-[WebNetscapePlugInStreamLoader cancelWithError:]):
* Loader/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forFrameLoader:]):
(-[WebSubresourceLoader signalFinish]):
(-[WebSubresourceLoader didFailWithError:]):
(-[WebSubresourceLoader cancel]):
* Plugins/WebNetscapePluginStream.m:
(-[WebNetscapePluginStream start]):
* WebView/WebDataSource.m:
(-[WebDataSource _replaceSelectionWithArchive:selectReplacement:]):
(-[WebDataSource _updateIconDatabaseWithURL:]):
(-[WebDataSource _loadIcon]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource _cancelledError]):
(+[WebDataSource _repTypesAllowImageTypeOmission:]):
(+[WebDataSource _representationClassForMIMEType:]):
(-[WebDataSource _commitLoadWithData:]):
(-[WebDataSource _receivedMainResourceError:complete:]):
(-[WebDataSource _iconLoaderReceivedPageIcon:]):
(-[WebDataSource _isDocumentHTML]):
* WebView/WebDataSourceInternal.h:
2006-08-21 Brady Eidson <beidson@apple.com>
Reviewed by John
Quick ICONDEBUG flag fix
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _applicationWillTerminate:]):
2006-08-21 Brady Eidson <beidson@apple.com>
Reviewed by Anders
-Renamed an internal only method for clarity
-Tweaked WebDataSource for notification purposes with the new expiring icons
-Fixed a bug with the ICONDEBUG flag
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
(-[WebIconDatabase iconForURL:withSize:cache:]): #ifdef bug fixed
(-[WebIconDatabase _hasEntryForIconURL:]): Renamed for clarity
* Misc/WebIconDatabasePrivate.h:
* WebView/WebDataSource.m:
(-[WebDataSource _updateIconDatabaseWithURL:]):
(-[WebDataSource _notifyIconChanged:]):
(-[WebDataSource _loadIcon]):
(-[WebDataSource _iconLoaderReceivedPageIcon:]):
2006-08-17 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
- pull a bit of WebDataSource code into WebFrameLoader
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _receivedError:]):
(-[WebFrameLoader webFrame]):
(-[WebFrameLoader _handleFallbackContent]):
(+[WebFrameLoader _canShowMIMEType:]):
(+[WebFrameLoader _representationExistsForURLScheme:]):
(+[WebFrameLoader _generatedMIMETypeForURLScheme:]):
* WebView/WebDataSource.m:
* WebView/WebDataSourceInternal.h:
2006-08-17 Timothy Hatcher <timothy@apple.com>
Reviewed by Kevin Decker.
<rdar://problem/4606857> WebKit: WebPreferencesChangedNotification not exported in 64-bit
* WebKit.LP64.exp:
2006-08-17 Timothy Hatcher <timothy@apple.com>
Reviewed by Kevin Decker.
<rdar://problem/4633896> -[WebView close] should clear all delegates and call setHostWindow:nil
<rdar://problem/4649759> Crash when selecting View Source menu using Chinese (-[WebView _close])
Check to make sure _private is not null. A WebView can be dealloced before _private is setup.
Set the _private->closed flag at the beginning of _close to prevent reentry.
Set the host window and all the delegates to nil in _close.
* WebView/WebView.m:
(-[WebView _close]):
2006-08-16 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
* Misc/WebIconDatabase.m: Pruned unused method
* Misc/WebIconDatabasePrivate.h: Ditto
2006-08-15 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adele (preliminary version) and later by Kevin.
- remove most WebKit dependencies from WebMainResourceLoader.
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader cannotShowMIMETypeForURL:]):
(-[WebFrameLoader interruptForPolicyChangeErrorWithRequest:]):
(-[WebFrameLoader isHostedByObjectElement]):
(-[WebFrameLoader isLoadingMainFrame]):
(+[WebFrameLoader _canShowMIMEType:]):
(+[WebFrameLoader _representationExistsForURLScheme:]):
(+[WebFrameLoader _generatedMIMETypeForURLScheme:]):
* Loader/WebMainResourceLoader.h:
* Loader/WebMainResourceLoader.m:
(-[WebMainResourceLoader interruptForPolicyChangeError]):
(-[WebMainResourceLoader willSendRequest:redirectResponse:]):
(isCaseInsensitiveEqual):
(shouldLoadAsEmptyDocument):
(-[WebMainResourceLoader continueAfterContentPolicy:response:]):
(-[WebMainResourceLoader didReceiveResponse:]):
(-[WebMainResourceLoader didReceiveData:lengthReceived:allAtOnce:]):
(-[WebMainResourceLoader didFinishLoading]):
(-[WebMainResourceLoader loadWithRequestNow:]):
(-[WebMainResourceLoader loadWithRequest:]):
2006-08-15 Tim Omernick <timo@apple.com>
Reviewed by Kevin Decker.
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage _unloadWithShutdown:]):
Fixed a subtle problem with the 64-bit debug build -- as written, this would LOG() on 64-bit and do nothing on
32-bit!
* Plugins/WebPluginDatabase.m:
(-[WebPluginDatabase _scanForNewPlugins]):
Use +[NSMutableSet set] here.
2006-08-15 Tim Omernick <timo@apple.com>
Reviewed by Darin Adler.
<http://bugs.webkit.org/show_bug.cgi?id=8980>
ASSERTION FAILED: !isLoaded (WebKit/WebKit/Plugins/WebBasePluginPackage.m:228 -[WebBasePluginPackage dealloc])
<rdar://problem/4526052> intermittent assertion failure in -[WebBasePluginPackage dealloc] running layout tests (8980)
* Plugins/WebPluginDatabase.h:
* Plugins/WebPluginDatabase.m:
(+[WebPluginDatabase installedPlugins]):
Observe NSApplicationWillTerminateNotification so we can unload plug-ins on quit.
(-[WebPluginDatabase plugins]):
'plugins' is now a dictionary.
(-[WebPluginDatabase close]):
Call new -_removePlugin: method.
(-[WebPluginDatabase refresh]):
Moved parts of this method out into other methods: -_addPlugin:, -_removePlugin:, and -_scanForNewPlugins.
(-[WebPluginDatabase _plugInPaths]):
No changes; just moved in file.
(-[WebPluginDatabase _addPlugin:]):
New method. Refactored from -refresh. Adds a plug-in to the database.
(-[WebPluginDatabase _removePlugin:]):
New method. Refactored from -refresh. Remove a plug-in from the database.
(-[WebPluginDatabase _scanForNewPlugins]):
New method. Refactored from -refresh. Returns the list of plug-in packages on disk.
(-[WebPluginDatabase _applicationWillTerminate]):
New method. Called when the application terminates. Closes the plug-in database so that all plug-ins are
removed from the DB (and unloaded if necessary).
* Plugins/WebBasePluginPackage.h:
* Plugins/WebBasePluginPackage.m:
(-[WebBasePluginPackage initWithPath:]):
Try to create the NSBundle first, so if the file is not a valid bundle we bail out early. This
avoids some stat()s and allocations during the plug-in refresh process.
(-[WebBasePluginPackage isLoaded]):
Removed.
(-[WebBasePluginPackage load]):
Base class for plug-in packages now always loads "successfully".
(-[WebBasePluginPackage dealloc]):
Removed this assertion. The base plug-in package class has no concept of
"unloading".
(-[WebBasePluginPackage finalize]):
ditto.
(-[WebBasePluginPackage wasRemovedFromPluginDatabase:]):
Moved code to unload plug-in package to WebNetscapePluginPackage. Not all plug-in
packages can be "unloaded".
* Plugins/WebNetscapePluginPackage.h:
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage _unloadWithShutdown:]):
Combined old -unload and -unloadWithoutShutdown methods into this new one.
(-[WebNetscapePluginPackage initWithPath:]):
Call new unload method.
(-[WebNetscapePluginPackage load]):
ditto
(-[WebNetscapePluginPackage wasRemovedFromPluginDatabase:]):
ditto
(-[WebNetscapePluginPackage open]):
New method. Called when a plug-in instance starts running.
(-[WebNetscapePluginPackage close]):
New method. Called when a plug-in instance stops running. When all plug-in instances
close the plug-in package, and the plug-in package is removed from the database, the plug-in
is unloaded.
* Plugins/WebPluginPackage.m:
(-[WebPluginPackage initWithPath:]):
(-[WebPluginPackage load]):
Made this a bit more efficient by checking if the bundle is already loaded.
(-[WebBasePluginPackage unload]):
Removed.
(-[WebBasePluginPackage isLoaded]):
Removed.
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView start]):
Open the plug-in package so it remains loaded while this instance uses it.
(-[WebBaseNetscapePluginView stop]):
Close the plug-in package when the plug-in instance is stopped.
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:]):
This check is not necessary. Netscape plug-in packages are never unloaded until all their instances have
been stopped, and a Netscape plug-in instance will stop its streams when it is stopped.
(-[WebBaseNetscapePluginStream _destroyStream]):
ditto
(-[WebBaseNetscapePluginStream finishedLoadingWithData:]):
ditto
(-[WebBaseNetscapePluginStream _deliverData]):
ditto
2006-08-15 Mark Rowe <opendarwin.org@bdash.net.nz>
Reviewed by Tim H.
Build fix: DWARF and -gfull are incompatible with symbol separation.
* WebKit.xcodeproj/project.pbxproj:
2006-08-15 Mark Rowe <opendarwin.org@bdash.net.nz>
Reviewed by Tim H.
http://bugs.webkit.org/show_bug.cgi?id=10394
Bug 10394: WebKit Release and Production configurations should enable dead code stripping
* WebKit.xcodeproj/project.pbxproj:
2006-08-15 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- remove WebKit dependencies from WebPlugInStreamLoader via a protocol veil of ignorance
* Loader/WebNetscapePlugInStreamLoader.h:
* Loader/WebNetscapePlugInStreamLoader.m:
(-[WebNetscapePlugInStreamLoader initWithDelegate:frameLoader:]):
* Loader/WebPlugInStreamLoaderDelegate.h: Added.
* Plugins/WebBaseNetscapePluginStream.h:
* Plugins/WebNetscapePluginStream.m:
(-[WebNetscapePluginStream initWithRequest:pluginPointer:notifyData:sendNotification:]):
* WebKit.xcodeproj/project.pbxproj:
2006-08-15 Mark Rowe <opendarwin.org@bdash.net.nz>
Reviewed by Tim H.
http://bugs.webkit.org/show_bug.cgi?id=10384
Bug 10384: Switch to DWARF for Release configuration
* WebKit.xcodeproj/project.pbxproj:
2006-08-15 Graham Dennis <graham.dennis@gmail.com>
Reviewed by Darin.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10314
WebUnarchivingState archivedResourceForURL: doesn't work
* WebView/WebUnarchivingState.m:
(-[WebUnarchivingState archivedResourceForURL:]):
Fixed to get objects from the archived resources dictionary using
the URL as a string instead of as the URL itself (as this is how
the data is put into the dictionary).
2006-08-14 Maciej Stachowiak <mjs@apple.com>
Reviewed by Beth.
- remove many (but not all) WebKit dependencies from WebNetscapePlugInStreamLoader (it still
depends on WebNetscapePluginStream).
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader fileDoesNotExistErrorWithResponse:]):
* Loader/WebNetscapePlugInStreamLoader.h:
* Loader/WebNetscapePlugInStreamLoader.m:
(-[WebNetscapePlugInStreamLoader initWithStream:frameLoader:]):
(-[WebNetscapePlugInStreamLoader releaseResources]):
(-[WebNetscapePlugInStreamLoader didReceiveResponse:]):
* Plugins/WebNetscapePluginStream.m:
(-[WebNetscapePluginStream initWithRequest:pluginPointer:notifyData:sendNotification:]):
2006-08-14 Maciej Stachowiak <mjs@apple.com>
Reviewed by Tim Omernick.
- fixed REGRESSION: crash when leaving youtube page while movie is still loading
http://bugs.webkit.org/show_bug.cgi?id=10398
* Loader/WebNetscapePlugInStreamLoader.m:
(-[WebNetscapePlugInStreamLoader initWithStream:view:]): Set the frame loader for this stream.
(-[WebNetscapePlugInStreamLoader cancelWithError:]): Make sure to destroy the stream as well;
otherwise, when we try to clean up later, we won't have the right context.
2006-08-14 David Hyatt <hyatt@apple.com>
Fix for Radar bug 4478840, Safari should not reduce null events sent to
plug-ins in windows that are inactive but visible.
With this fix you can view videos in visible background windows on YouTube
(for example) and not see any drop in frame rate.
Reviewed by timo
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView restartNullEvents]):
2006-08-14 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
- removed WebKit-level dependencies from WebFormDataStream. Use WebCore version of system interface
* Loader/WebFormDataStream.m:
(formCanRead):
(formEventCallback):
(webSetHTTPBody):
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
2006-08-14 Maciej Stachowiak <mjs@apple.com>
Rubber stamped by Brady.
- move WebFormDataStream from WebView to Loader
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFormDataStream.h: Removed.
* WebView/WebFormDataStream.m: Removed.
2006-08-13 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
- remove WebKit dependencies from WebSubresourceLoader, except WebFormDataStream
(WebFormDataStream will be moved into the Loader directory soon)
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader _addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
* Loader/WebSubresourceLoader.m:
(isConditionalRequest):
(hasCaseInsensitivePrefix):
(isFileURLString):
(setHTTPReferrer):
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forFrameLoader:]):
2006-08-13 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Relocated the WebIconLoaders
* Misc/WebIconLoader.h: Moved to Loader/
* Misc/WebIconLoader.m: Moved to Loader/
* WebKit.xcodeproj/project.pbxproj:
2006-08-13 Maciej Stachowiak <mjs@apple.com>
Reviewed by Beth.
- removed non-Loader WebKit dependencies from WebDataProtocol for
real (whoops) and fix some typos.
* Loader/WebDataProtocol.m:
(isCaseInsensitiveEqual): Added.
(+[WebDataProtocol _webIsDataProtocolURL:]): Avoid WebKit calls.
(-[WebDataProtocol startLoading]): ditto
* Loader/WebFrameLoader.m:
(isCaseInsensitiveEqual): Fixed spelling from isCaseSensitiveEqual.
(-[WebFrameLoader _canUseResourceForRequest:]): Use proper call.
2006-08-13 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
The way of detecting a failed icon load before was to try and construct
an image from the icon and if that image construction failed, mark the icon
as missing.
A much more efficient way is to check for an error response. We'll still
check for invalid image data, but most servers will correctly return an HTTP
error on a missing icon.
* Misc/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]): Added check for http error response
2006-08-13 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- remove all non-Loader dependencies from WebLoader
As part of this I moved WebDataProtocol to the loader directory
and removed dependencies on the rest of WebKit from that too.
* Loader/WebFrameLoader.h:
* Loader/WebFrameLoader.m:
(-[WebFrameLoader setDefersCallbacks:]):
(-[WebFrameLoader stopLoading]):
(-[WebFrameLoader cancelledErrorWithRequest:]):
(-[WebFrameLoader clearArchivedResources]):
(-[WebFrameLoader deliverArchivedResources]):
(-[WebFrameLoader deliverArchivedResourcesAfterDelay]):
(isCaseSensitiveEqual):
(-[WebFrameLoader _canUseResourceForRequest:]):
(-[WebFrameLoader _canUseResourceWithResponse:]):
(-[WebFrameLoader pendingArchivedResources]):
(-[WebFrameLoader willUseArchiveForRequest:originalURL:loader:]):
(-[WebFrameLoader archiveLoadPendingForLoader:]):
(-[WebFrameLoader cancelPendingArchiveLoadForLoader:]):
* Loader/WebLoader.h:
* Loader/WebLoader.m:
(-[NSURLProtocol releaseResources]):
(-[NSURLProtocol loadWithRequest:]):
(-[NSURLProtocol setDefersCallbacks:]):
(-[NSURLProtocol addData:allAtOnce:]):
(-[NSURLProtocol resourceData]):
(-[NSURLProtocol didReceiveData:lengthReceived:allAtOnce:]):
(-[NSURLProtocol connection:didReceiveData:lengthReceived:]):
(-[NSURLProtocol cancelWithError:]):
(-[NSURLProtocol cancelledError]):
* Loader/WebMainResourceLoader.m:
(-[WebMainResourceLoader addData:allAtOnce:]):
(-[WebMainResourceLoader didReceiveData:lengthReceived:allAtOnce:]):
* Loader/WebNetscapePlugInStreamLoader.m:
(-[WebNetscapePlugInStreamLoader didReceiveData:lengthReceived:allAtOnce:]):
* Loader/WebSubresourceLoader.m:
(-[WebSubresourceLoader didReceiveData:lengthReceived:allAtOnce:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataProtocol.h: Removed.
* WebView/WebDataProtocol.m: Removed.
2006-08-11 Tim Omernick <timo@apple.com>
Reviewed by Darin.
<http://bugs.webkit.org/show_bug.cgi?id=10111> - Menu flickers over Flash content
<rdar://problem/3052546> Plugins don't work with z-index (overlapping elements, etc.)
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
Don't just clip to the dirty region for "transparent" plug-ins -- do it for all plug-ins. This is a
generally useful thing to do, as it prevents the plug-in from drawing over parts of the window that
have already been drawn and are not expected to be redrawn in the same update.
2006-08-11 Brady Eidson <beidson@apple.com>
Reviewed by John, Timo, Adele, and Darin
In addition to a few style/good-practice cleanups, this patch will convert the old icon database
format to the WebCore format if the WebCore db is empty (implying this conversion has yet to take
place). After the conversion, it will delete all traces of the old format to free the unneeded space
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
(-[WebIconDatabase _setIconURL:forURL:]): Changed the bridge's name for this method to be more clear
(-[WebIconDatabase _createFileDatabase]):
(-[WebIconDatabase _iconDataForIconURL:]): This grabs the raw data for use in the conversion function
(-[WebIconDatabase _convertToWebCoreFormat]): This does the actual conversion
2006-08-11 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
Needed for <rdar://problem/4678070>.
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView sendEvent:]):
Changed an assertion to an early return. It should be possible to send events, especially updateEvt (for image capturing
purposes), to off-screen plug-ins. It just doesn't work right now. See <rdar://problem/4318269>.
2006-08-11 John Sullivan <sullivan@apple.com>
Reviewed by Darin
- fixed <rdar://problem/4522894> Would be nice if Safari shrank pages a little if necessary
to avoid printing an almost-empty page
* WebView/WebHTMLView.m:
(-[NSArray knowsPageRange:]):
If the last page has a short-enough orphan (< 1/10 of the page height is the number I pulled
out of ... the air), then we adjust the scale factor slightly and check whether this reduces
the page count and thus eliminates the orphan.
2006-08-07 Brady Eidson <beidson@apple.com>
Reviewed by Anders and John
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
(-[WebIconDatabase isIconExpiredForIconURL:]): Get if an icon expired
(-[WebIconDatabase isIconExpiredForPageURL:]): Ditto
(-[WebIconDatabase _setIconURL:forURL:]):
(-[WebIconDatabase _sendNotificationForURL:]): Moved to WebKitPendingPublic for use outside of WebIconDatabase
(-[WebIconDatabase loadIconFromURL:]): Allow a load outside the context of a page load
* Misc/WebIconDatabasePrivate.h:
* Misc/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]): fixed up the "flipping the switch" #defs a bit
(-[WebIconLoader willSendRequest:redirectResponse:]): override to allow a load
outside of the context of a page load
* WebCoreSupport/WebIconDatabaseBridge.h: Added.
* WebCoreSupport/WebIconDatabaseBridge.m: Added.
(-[WebIconDatabaseBridge init]):
(-[WebIconDatabaseBridge dealloc]):
(-[WebIconDatabaseBridge loadIconFromURL:]): Kick off a load on an icon outside
of the context of any page load
(-[WebIconDatabaseBridge _setIconData:forIconURL:]): WebKit side of bridge method
(-[WebIconDatabaseBridge _setHaveNoIconForIconURL:]): WebKit side of bridge method
(-[WebIconDatabaseBridge releaseCachedLoaderForIconURL:]):
(+[WebIconDatabaseBridge sharedBridgeInstance]): Moved this from WebCore to WebKit
so both sides of the bridge get the WebKit version
* WebKit.xcodeproj/project.pbxproj: Added some files
* WebView/WebDataSource.m:
(-[WebDataSource _loadIcon]): Added check for reload/expired icon to force
a load even if we already have it
2006-08-04 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Darin.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10192
Make WebCore (and friends) compile with -Wshorten-64-to-32
* Adds 'f' to float literals where expecting a float.
* Use ceilf() instead of ceil() when assigning to a float.
* Adds explicit casts where OK.
NOTE: The -Wshorten-64-to-32 flag was not added for WebKit
because there are still a few places where no error handling
is in place. The flag can be added as soon as those are worked
out.
* Misc/WebNSControlExtras.m:
(-[NSControl sizeToFitAndAdjustWindowHeight]):
* Misc/WebNSImageExtras.m:
(-[NSImage _web_scaleToMaxSize:]):
* Misc/WebNSViewExtras.h:
* Misc/WebNSViewExtras.m:
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
(-[WebBaseNetscapePluginView drawRect:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge expiresTimeForResponse:]):
* WebInspector/WebInspector.m:
(-[NSWindow window]):
(-[WebInspector treeViewScrollTo:]):
(-[WebInspector _updateSystemColors]):
(-[WebInspector webView:plugInViewWithArguments:]):
(-[WebInspector outlineView:objectValueForTableColumn:byItem:]):
* WebInspector/WebInspectorOutlineView.m:
(-[WebInspectorOutlineView _highlightRow:clipRect:]):
* WebInspector/WebNodeHighlight.m:
(-[WebNodeHighlight initWithBounds:andRects:forView:]):
* WebInspector/WebNodeHighlightView.m:
(-[WebNodeHighlightView roundedRect:withRadius:]):
(-[WebNodeHighlightView initWithHighlight:andRects:forView:]):
(-[WebNodeHighlightView drawRect:]):
* WebView/WebFrame.m:
(-[WebFrame _opened]):
* WebView/WebFrameView.m:
(-[WebFrameView initWithFrame:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _dragImageForLinkElement:]):
(-[WebHTMLView _web_setPrintingModeRecursive]):
(-[WebHTMLView _web_clearPrintingModeRecursive]):
(-[NSArray layout]):
(-[NSArray _setPrinting:minimumPageWidth:maximumPageWidth:adjustViewSize:]):
(-[NSArray adjustPageHeightNew:top:bottom:limit:]):
(-[NSArray _scaleFactorForPrintOperation:]):
(-[NSArray setPageWidthForPrinting:]):
(-[NSArray _endPrintMode]):
(-[NSArray knowsPageRange:]):
(-[NSArray _originalFontA]):
(-[NSArray _originalFontB]):
(-[WebTextCompleteController _buildUI]):
(-[WebTextCompleteController _placePopupWindow:]):
* WebView/WebPDFView.m:
(-[WebPDFView _makeTextStandardSize:]):
(-[WebPDFView selectionImageForcingWhiteText:]):
(-[PDFPrefUpdatingProxy forwardInvocation:]):
* WebView/WebPreferences.m:
(-[WebPreferences _floatValueForKey:]):
* WebView/WebView.m:
(-[WebView makeTextSmaller:]):
(-[WebView canMakeTextStandardSize]):
(-[WebView makeTextStandardSize:]):
2006-08-04 David Kilzer <ddkilzer@kilzer.net>
Reviewed by NOBODY (build fix).
* WebCoreSupport/WebSubresourceLoader.m: REALLY moved to Loader/
* WebView/WebFrameLoader.h: REALLY moved to Loader/
* WebView/WebFrameLoader.m: REALLY moved to Loader/
* WebView/WebLoader.h: REALLY moved to Loader/
* WebView/WebLoader.m: REALLY moved to Loader/
* WebView/WebMainResourceLoader.m: REALLY moved to Loader/
2006-08-03 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- moved all loader code that is slated to be moved down to WebCore to a new Loader directory
(next step is to remove dependencies on the rest of WebKit from this directory)
* Loader/WebNetscapePlugInStreamLoader.h: Added.
* Loader/WebNetscapePlugInStreamLoader.m: Added. Cut out of WebNetscapePluginStream.m
(-[WebNetscapePlugInStreamLoader initWithStream:view:]):
(-[WebNetscapePlugInStreamLoader isDone]):
(-[WebNetscapePlugInStreamLoader releaseResources]):
(-[WebNetscapePlugInStreamLoader didReceiveResponse:]):
(-[WebNetscapePlugInStreamLoader didReceiveData:lengthReceived:]):
(-[WebNetscapePlugInStreamLoader didFinishLoading]):
(-[WebNetscapePlugInStreamLoader didFailWithError:]):
(-[WebNetscapePlugInStreamLoader cancelWithError:]):
* Plugins/WebNetscapePluginStream.m:
* WebKit.xcodeproj/project.pbxproj:
* WebCoreSupport/WebSubresourceLoader.h: Moved to Loader/
* WebCoreSupport/WebSubresourceLoader.m: Moved to Loader/
* WebView/WebFrameLoader.h: Moved to Loader/
* WebView/WebFrameLoader.m: Moved to Loader/
* WebView/WebLoader.h: Moved to Loader/
* WebView/WebLoader.m: Moved to Loader/
* WebView/WebMainResourceLoader.h: Moved to Loader/
* WebView/WebMainResourceLoader.m: Moved to Loader/
2006-08-03 Tim Omernick <timo@apple.com>
Reviewed by Kevin Decker.
<rdar://problem/4667460> Windowless OpenGL plug-ins render incorrectly on PowerPC
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView _aglOffscreenImageForDrawingInRect:]):
Fixed color component swapping so that it works on both x86 and PPC. See comments.
2006-08-03 Brady Eidson <beidson@apple.com>
Reviewed by Tim Hatcher's rubber stamp
Fixed Intel build break caused by weinig's -W change in r15781
* WebView/WebView.m: wrapped cpu-dependent defs with defined() macro
2006-08-03 Maciej Stachowiak <mjs@apple.com>
Reviewed by John.
- fixed problem that could cause assertion failures in Safari
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]): Don't
allow a plugin to start new loads once its document is no longer the one actively loading.
2006-08-03 Maciej Stachowiak <mjs@apple.com>
Reviewed by John.
- remove use of WebDataSource from WebLoader and subclasses, just have them talk to the
WebFrameLoader instead.
For now this is done by forarding all the calls.
* Misc/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]):
* Plugins/WebNetscapePluginStream.m:
(-[WebNetscapePluginStream initWithRequest:pluginPointer:notifyData:sendNotification:]):
(-[WebNetscapePluginStream start]):
(-[WebNetscapePlugInStreamLoader didFinishLoading]):
(-[WebNetscapePlugInStreamLoader didFailWithError:]):
(-[WebNetscapePlugInStreamLoader cancelWithError:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:]):
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:postData:]):
* WebCoreSupport/WebSubresourceLoader.h:
* WebCoreSupport/WebSubresourceLoader.m:
(-[WebSubresourceLoader initWithLoader:frameLoader:]):
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forFrameLoader:]):
(+[WebSubresourceLoader startLoadingResource:withMethod:URL:customHeaders:referrer:forFrameLoader:]):
(+[WebSubresourceLoader startLoadingResource:withMethod:URL:customHeaders:postData:referrer:forFrameLoader:]):
(-[WebSubresourceLoader receivedError:]):
(-[WebSubresourceLoader signalFinish]):
(-[WebSubresourceLoader didFailWithError:]):
(-[WebSubresourceLoader cancel]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSource _updateLoading]):
(-[WebDataSource textEncodingName]):
(-[WebDataSource _mainReceivedBytesSoFar:complete:]):
* WebView/WebFrameLoader.h:
* WebView/WebFrameLoader.m:
(-[WebFrameLoader loadIconWithRequest:]):
(-[WebFrameLoader startLoadingMainResourceWithRequest:identifier:]):
(-[WebFrameLoader clearIconLoader]):
(-[WebFrameLoader commitProvisionalLoad]):
(-[WebFrameLoader activeDataSource]):
(-[WebFrameLoader _archivedSubresourceForURL:]):
(-[WebFrameLoader _defersCallbacks]):
(-[WebFrameLoader _identifierForInitialRequest:]):
(-[WebFrameLoader _willSendRequest:forResource:redirectResponse:]):
(-[WebFrameLoader _didReceiveAuthenticationChallenge:forResource:]):
(-[WebFrameLoader _didCancelAuthenticationChallenge:forResource:]):
(-[WebFrameLoader _didReceiveResponse:forResource:]):
(-[WebFrameLoader _didReceiveData:contentLength:forResource:]):
(-[WebFrameLoader _didFinishLoadingForResource:]):
(-[WebFrameLoader _didFailLoadingWithError:forResource:]):
(-[WebFrameLoader _privateBrowsingEnabled]):
(-[WebFrameLoader _addPlugInStreamLoader:]):
(-[WebFrameLoader _removePlugInStreamLoader:]):
(-[WebFrameLoader _finishedLoadingResource]):
(-[WebFrameLoader _receivedError:]):
(-[WebFrameLoader _addSubresourceLoader:]):
(-[WebFrameLoader _removeSubresourceLoader:]):
(-[WebFrameLoader _originalRequest]):
(-[WebFrameLoader webFrame]):
(-[WebFrameLoader _receivedMainResourceError:complete:]):
(-[WebFrameLoader initialRequest]):
(-[WebFrameLoader _receivedData:]):
(-[WebFrameLoader _setRequest:]):
(-[WebFrameLoader _downloadWithLoadingConnection:request:response:proxy:]):
(-[WebFrameLoader _handleFallbackContent]):
(-[WebFrameLoader _isStopping]):
(-[WebFrameLoader _decidePolicyForMIMEType:decisionListener:]):
(-[WebFrameLoader _setupForReplaceByMIMEType:]):
(-[WebFrameLoader _setResponse:]):
(-[WebFrameLoader _mainReceivedError:complete:]):
(-[WebFrameLoader _finishedLoading]):
(-[WebFrameLoader _mainReceivedBytesSoFar:complete:]):
(-[WebFrameLoader _iconLoaderReceivedPageIcon:]):
(-[WebFrameLoader _URL]):
* WebView/WebLoader.h:
* WebView/WebLoader.m:
(-[NSURLProtocol releaseResources]):
(-[NSURLProtocol loadWithRequest:]):
(-[NSURLProtocol setFrameLoader:]):
(-[NSURLProtocol frameLoader]):
(-[NSURLProtocol willSendRequest:redirectResponse:]):
(-[NSURLProtocol didReceiveAuthenticationChallenge:]):
(-[NSURLProtocol didCancelAuthenticationChallenge:]):
(-[NSURLProtocol didReceiveResponse:]):
(-[NSURLProtocol didReceiveData:lengthReceived:]):
(-[NSURLProtocol signalFinish]):
(-[NSURLProtocol didFailWithError:]):
(-[NSURLProtocol willCacheResponse:]):
(-[NSURLProtocol cancelWithError:]):
* WebView/WebMainResourceLoader.h:
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader initWithFrameLoader:]):
(-[WebMainResourceLoader receivedError:]):
(-[WebMainResourceLoader cancelWithError:]):
(-[WebMainResourceLoader _isPostOrRedirectAfterPost:redirectResponse:]):
(-[WebMainResourceLoader addData:]):
(-[WebMainResourceLoader willSendRequest:redirectResponse:]):
(-[WebMainResourceLoader continueAfterContentPolicy:response:]):
(-[WebMainResourceLoader continueAfterContentPolicy:]):
(-[WebMainResourceLoader checkContentPolicyForResponse:]):
(-[WebMainResourceLoader didReceiveResponse:]):
(-[WebMainResourceLoader didReceiveData:lengthReceived:]):
(-[WebMainResourceLoader didFinishLoading]):
(-[WebMainResourceLoader didFailWithError:]):
(-[WebMainResourceLoader loadWithRequestNow:]):
2006-08-03 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Darin.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10176
Make WebCore compile with -Wundef
* Adds -Wundef flag to Xcode project
* Converts #ifs to #ifdef and #ifndefs where needed.
* Carbon/CarbonUtils.m:
* Carbon/CarbonWindowAdapter.m:
* Carbon/HIViewAdapter.m:
(+[NSView bindHIViewToNSView:nsView:]):
* Carbon/HIWebView.m:
(HIWebViewEventHandler):
* Misc/WebFileDatabase.m:
(UniqueFilePathForKey):
* Misc/WebNSWindowExtras.m:
(swizzleInstanceMethod):
* Misc/WebTypesInternal.h:
* Plugins/WebNetscapeDeprecatedFunctions.c:
* Plugins/WebNetscapeDeprecatedFunctions.h:
* Plugins/WebNetscapePluginPackage.h:
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage unloadWithoutShutdown]):
(-[WebNetscapePluginPackage load]):
* WebKit.xcodeproj/project.pbxproj:
2006-08-03 Darin Adler <darin@apple.com>
Reviewed by Eric Seidel.
- fix storage leak
* WebView/WebFrame.m: (-[WebFramePrivate dealloc]): Release the frame loader.
2006-08-02 Timothy Hatcher <timothy@apple.com>
Rubber stamped by Maciej.
Adding back resultsWithXpathQuery, removed by Darin's earlier change.
This function is called from ObjC, but not used from JavaScript.
* WebInspector/webInspector/inspector.js:
2006-08-02 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Bug 10200: [Drosera] Deadlock between Drosera and Safari while loading page
http://bugs.webkit.org/show_bug.cgi?id=10200
Prevent reentrancy in our debugger callbacks. This was causing a deadlock in Drosera because
suspendProcessIfPaused was being called during a DO call into Safari.
Preventing reentrancy also prevents scripts that Drosera injects and evaluates from showing
up in rare cases (such as a iframe loading about:blank). I thought this would prevent cases
where you call a function from the console and expect it to break on a breakpoint in them, but
this appears to never have worked even without this change. When that is figured out we can
reconsider a better solution to reentrancy. I have filed that as bug 10214.
I also removed the NSRunLoop runMode:beforeDate: calls since DO handles this for us since
we don't use "onway void" as the return type for the callbacks. Note: using onway void for
the listener callbacks causes bad synchronization issues and obscure crashes.
* DefaultDelegates/WebScriptDebugServer.m:
(-[WebScriptDebugServer webView:didLoadMainResourceForDataSource:]):
(-[WebScriptDebugServer webView:didParseSource:baseLineNumber:fromURL:sourceId:forWebFrame:]):
(-[WebScriptDebugServer webView:failedToParseSource:baseLineNumber:fromURL:withError:forWebFrame:]):
(-[WebScriptDebugServer webView:didEnterCallFrame:sourceId:line:forWebFrame:]):
(-[WebScriptDebugServer webView:willExecuteStatement:sourceId:line:forWebFrame:]):
(-[WebScriptDebugServer webView:willLeaveCallFrame:sourceId:line:forWebFrame:]):
(-[WebScriptDebugServer webView:exceptionWasRaised:sourceId:line:forWebFrame:]):
* DefaultDelegates/WebScriptDebugServerPrivate.h:
2006-08-02 Maciej Stachowiak <mjs@apple.com>
Reviewed by John.
- fix assertion failure on layout tests by stopping plugins from loading at a clearly defined time
- add more assertions for safety
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]): Removed obsolete comment.
(-[WebDataSource _updateLoading]): Add assertion ensuring this method is only called
at a time when this data source is the one that might be loading for a frame.
(-[WebDataSource _stopLoading]): Stop loading plugins as a FIXME suggests we should.
* WebView/WebFrameLoader.m:
(-[WebFrameLoader isLoadingPlugIns]): New helper method.
(-[WebFrameLoader isLoading]): Consider plugin loads too - otherwise we won't stop them
at stopLoading time.
2006-08-02 Adam Roben <aroben@apple.com>
Reviewed by Brady.
- Rename TransferJob to ResourceLoader (this file was forgotten in an
earlier change by Maciej)
* COM/WebView.cpp:
2006-08-01 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adele.
- Change things around so WebFrameLoader tracks the main and provisional data source,
as well as the frame load state, pulling much code out of WebFrame along the way.
The most significant aspects of this change are:
- management of WebDataSources and WebFrameState was moved into WebFrameLoader
- there is now just one WebFrameLoader shared between the primary and provisional data source
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _updateLoading]):
(-[WebDataSource _loadIcon]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource _stopLoading]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _addSubresourceLoader:]):
(-[WebDataSource _removeSubresourceLoader:]):
(-[WebDataSource _addPlugInStreamLoader:]):
(-[WebDataSource _removePlugInStreamLoader:]):
(-[WebDataSource _defersCallbacksChanged]):
(-[WebDataSource _stopLoadingWithError:]):
(-[WebDataSource _revertToProvisionalState]):
(-[WebDataSource _setupForReplaceByMIMEType:]):
(-[WebDataSource initWithRequest:]):
(-[WebDataSource data]):
(-[WebDataSource isLoading]):
* WebView/WebFrame.m:
(-[WebFramePrivate init]):
(-[WebFramePrivate dealloc]):
(-[WebFrame _closeOldDataSources]):
(-[WebFrame _detachFromParent]):
(-[WebFrame _makeDocumentView]):
(-[WebFrame _receivedMainResourceError:]):
(-[WebFrame _transitionToCommitted:]):
(+[WebFrame _timeOfLastCompletedLoad]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _continueAfterWillSubmitForm:]):
(-[WebFrame _continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrame _initWithWebFrameView:webView:bridge:]):
(-[WebFrame _frameLoader]):
(-[WebFrame _provisionalLoadStarted]):
(-[WebFrame _prepareForDataSourceReplacement]):
(-[WebFrame _frameLoadCompleted]):
(-[WebFrame provisionalDataSource]):
(-[WebFrame dataSource]):
(-[WebFrame stopLoading]):
* WebView/WebFrameInternal.h:
* WebView/WebFrameLoader.h:
* WebView/WebFrameLoader.m:
(-[WebFrameLoader initWithWebFrame:]):
(-[WebFrameLoader dealloc]):
(-[WebFrameLoader dataSource]):
(-[WebFrameLoader _setDataSource:]):
(-[WebFrameLoader clearDataSource]):
(-[WebFrameLoader provisionalDataSource]):
(-[WebFrameLoader _setProvisionalDataSource:]):
(-[WebFrameLoader _clearProvisionalDataSource]):
(-[WebFrameLoader state]):
(+[WebFrameLoader timeOfLastCompletedLoad]):
(-[WebFrameLoader _setState:]):
(-[WebFrameLoader clearProvisionalLoad]):
(-[WebFrameLoader markLoadComplete]):
(-[WebFrameLoader commitProvisionalLoad]):
(-[WebFrameLoader stopLoading]):
(-[WebFrameLoader startLoading]):
(-[WebFrameLoader startProvisionalLoad:]):
(-[WebFrameLoader setupForReplace]):
* WebView/WebFramePrivate.h:
2006-08-01 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4480737> Flash crashes after it replaces itself via a document.write()
I kind of hate to do this, but this is the best way to work around buggy plug-ins like Flash that assume that
NPP_Destroy() cannot be called while the browser is calling one of its other plug-in functions. The classic
situation is a plug-in that replaces itself via an NPN_Invoke() that executes a document.write().
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView sendEvent:]):
Call -willCallPlugInFunction and -didCallPlugInFunction around calls to the NPP_* functions.
(-[WebBaseNetscapePluginView setWindowIfNecessary]):
ditto
(-[WebBaseNetscapePluginView start]):
It should not be possible to start a plug-in instance while we are calling into it (one of those chicken/egg
problems). Added a sanity-checking assertion.
(-[WebBaseNetscapePluginView stop]):
If we're already calling a plug-in function, do not call NPP_Destroy(). The plug-in function we are calling
may assume that its instance->pdata, or other memory freed by NPP_Destroy(), is valid and unchanged until said
plugin-function returns.
(-[WebBaseNetscapePluginView pluginScriptableObject]):
Call -willCallPlugInFunction and -didCallPlugInFunction around calls to the NPP_* functions.
(-[WebBaseNetscapePluginView willCallPlugInFunction]):
Increment plug-in function call depth.
(-[WebBaseNetscapePluginView didCallPlugInFunction]):
Decrement plug-in function call depth. Stop if we're supposed to stop.
(-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]):
Call -willCallPlugInFunction and -didCallPlugInFunction around calls to the NPP_* functions.
(-[WebBaseNetscapePluginView webFrame:didFinishLoadWithReason:]):
ditto
(-[WebBaseNetscapePluginView _printedPluginBitmap]):
ditto
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:]):
Call -willCallPlugInFunction and -didCallPlugInFunction around calls to the NPP_* functions.
(-[WebBaseNetscapePluginStream _destroyStream]):
ditto
(-[WebBaseNetscapePluginStream _deliverData]):
ditto
2006-08-01 Maciej Stachowiak <mjs@apple.com>
- fix build after last change
* WebView/WebFrame.m:
(-[WebFrame _checkLoadCompleteForThisFrame]):
2006-08-01 Maciej Stachowiak <mjs@apple.com>
Reviewed by Beth.
- revert part of my last fix that broke the Safari bookmarks view
* WebView/WebFrame.m:
(-[WebFrame _checkLoadCompleteForThisFrame]): still send layout message for non-HTML views
2006-08-01 Tim Omernick <timo@apple.com>
Reviewed by Anders.
Fixed an assertion failure I ran into while debugging <rdar://problem/4652683>.
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView redeliverStream]):
Don't clear the "instance" ivar here. This code was refactored here from the old WebNetscapePluginRepresentation,
which also had an "instance" ivar. It is never appropriate to clear a plug-in view's instance. That is done when
the plug-in is destroyed.
2006-08-01 Maciej Stachowiak <mjs@apple.com>
Reviewed by Geoff.
- some refactoring in preparation for moving more stuff to WebFrameLoader.
* WebView/WebFrame.m:
(-[WebFrame _clearDataSource]):
(-[WebFrame _detachFromParent]):
(-[WebFrame _commitProvisionalLoad]):
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _clearProvisionalLoad]):
(-[WebFrame _markLoadComplete]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _startProvisionalLoad:]):
(-[WebFrame _continueLoadRequestAfterNavigationPolicy:formState:]):
(-[WebFrame stopLoading]):
2006-07-31 Maciej Stachowiak <mjs@apple.com>
Reviewed by Tim Hatcher.
- renamed TransferJob to ResourceLoader in WebCore
* COM/WebFrame.cpp:
(WebFrame::loadDataSource):
(WebFrame::receivedRedirect):
(WebFrame::receivedResponse):
(WebFrame::receivedData):
(WebFrame::receivedAllData):
(WebFrame::setStatusText):
* COM/WebFrame.h:
2006-07-31 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- omit the margin and padding boxes for display types where they are ignored
- use CSS instead of properties for table spacing and padding as suggested by Tim H.
* WebInspector/webInspector/inspector.css: Added rules for spacing and padding.
Added rules that hide the margin and padding boxes (borders and all but the center cell)
when the hide attribute is present.
* WebInspector/webInspector/inspector.html: Added classes for the rules above.
Removed cellpadding and cellspacing attributes.
* WebInspector/webInspector/inspector.js: Added code to hide/show the margin and
padding boxes based on the display type.
2006-07-31 Duncan Wilcox <duncan@mclink.it>
Reviewed by Darin.
Fixes <http://bugs.webkit.org/show_bug.cgi?id=10159>
"REGRESSION: delegate returning no menu elements crashes webkit"
No automated test, because there's no way to programmatically open a context menu,
no manual test because there's no way to customize the context menu delegate.
* WebView/WebView.m:
(-[WebView _menuForElement:defaultItems:]): Make sure the context menu returned
some menu items before accessing the first one.
2006-07-31 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
<rdar://problem/4658194> REGRESSION: "Search in Google"
and "Search in Spotlight" fail to work on text selected in a frame
Use selectedFrame to get the frame with the text selection.
* WebView/WebView.m:
(-[WebView _searchWithGoogleFromMenu:]):
(-[WebView _searchWithSpotlightFromMenu:]):
2006-07-31 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
- http://bugs.webkit.org/show_bug.cgi?id=10168
add a first cut at a Metrics pane to the inspector
* WebInspector/webInspector/inspector.css: Add styles for the new metrics pane.
* WebInspector/webInspector/inspector.html: Add the new metrics pane, starting with
the table to show the box model.
* WebInspector/webInspector/inspector.js: Add the new metrics pane. Add back some
"title" attributes so we have more tooltips. Removed the optional parameter to
getComputedStyle.
2006-07-31 Anders Carlsson <acarlsson@apple.com>
Reviewed by John.
* Plugins/WebPluginDatabase.m:
(-[WebPluginDatabase refresh]):
Create a mutable set instead of a mutable array.
2006-07-30 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
* WebInspector/webInspector/inspector.js: Fix bug where a null property value
leads to an empty style pane.
2006-07-30 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
- http://bugs.webkit.org/show_bug.cgi?id=10163
some improvements for the inspector
* WebInspector/WebInspector.m:
(+[WebInspector sharedWebInspector:]): Fixed bug that could cause the inspector
to be garbage collected if used in an application with GC enabled.
(-[WebInspector dealloc]): Removed a call to a non-existent close method.
(-[WebInspector window]): Added a custom WebPreferences object and called
setPrivateBrowsingEnabled:YES so the inspector won't appear in the history menu.
Also call setProhibitsMainFrameScrolling:YES to try to get rid of trouble where
the inspector scrolls when dragging.
* WebInspector/webInspector/inspector.css: Added style for the new color swatch,
and JavaScript properties. More of the style should be shared between the panes,
but this should be OK for now.
* WebInspector/webInspector/inspector.html: Added a first cut at a JavaScript
properties pane. Needs work, but better than nothing.
* WebInspector/webInspector/inspector.js: Lots of improvements:
- Omit "typical" property values from computed style display, making it much shorter.
- Use the words "black", "white", and "transparent" when appropriate for color values.
- Refactored the loaded() function to get rid of repetitive scrollbar setup.
- Added a new scrollarea for the JavaScript properties pane.
- Simplified refreshScrollbars() -- we now refresh all scrollbars every time, which does no harm.
- Removed unused resultsWithXpathQuery().
- Use [] instead of "new Array()" and {} instead of "new Object()".
- Removed unused xpathForNode().
- Changed style pane to display the style for a text node's parent instead of saying
it can't display the style for text.
- Fixed regression I caused a while back by checking the length of a computed style
and not trying to display anything if its length is 0. Before this change and the
corresponding change in WebCore, we'd see a complete list of all styles with the
empty string as the value for each one.
- Changed the name of the computedStyle flag on the style rules array to isComputedStyle
to make it easier to understand it's a boolean.
- Fixed an error in the code that does !important scanning where it was trying to
do a special case for computed style, but was checking the computed style flag on
the wrong object.
- Added populateStyleListItem() function to factor out things in common between the
items in the top level list and the expanded tree for shorthand properties.
- Added code to make a color swatch next to the textual representation for any
property that contains a color.
- Implemented a first cut at a simple JavaScript properties pane.
2006-07-29 Darin Adler <darin@apple.com>
- Removed tabs from these source files that still had them.
We don't use them; that way source files look fine in editors
that have tabs set to 8 spaces or to 4 spaces.
- Removed allow-tabs Subversion property from the files too.
* DefaultDelegates/WebDefaultPolicyDelegate.m:
* History/WebHistory.m:
* Misc/WebDownload.m:
* Misc/WebIconDatabase.m:
* Misc/WebKitErrors.m:
* Misc/WebKitLogging.m:
* Misc/WebNSDataExtras.m:
* Misc/WebNSFileManagerExtras.m:
* Panels/WebPanelAuthenticationHandler.m:
* Plugins/WebBaseNetscapePluginView.m:
* Plugins/npfunctions.h:
* WebCoreSupport/WebSubresourceLoader.m:
* WebView/WebMainResourceLoader.m:
* WebView/WebView.h:
* WebView/WebView.m:
2006-07-29 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Darin.
- patch for http://bugs.webkit.org/show_bug.cgi?id=10080
Adopt pedantic changes from the Unity project to improve
cross-compiler compatibility
Changes include:
* Adding missing newline to the end of the file.
* Turning on gcc warning for missing newline at the end of a source file
(GCC_WARN_ABOUT_MISSING_NEWLINE in Xcode, -Wnewline in gcc).
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebResourcePrivate.h:
2006-07-29 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by John Sullivan.
- fix http://bugs.webkit.org/show_bug.cgi?id=9984
ASSERTION FAILURE: _private->mouseDownEvent != nil
(WebKit/WebView/WebHTMLView.m:4863 -[WebHTMLView(WebInternal) _delegateDragSourceActionMask])
* WebView/WebHTMLView.m:
(-[WebHTMLView _setMouseDownEvent:]): Moved into the WebHTMLViewFileInternal category and changed
to accept nil.
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
Copy the hit HTMLView's mouse down event to the top HTMLView.
(-[WebHTMLView acceptsFirstMouse:]): Added a call to _setMouseDownEvent:nil before returning.
(-[WebHTMLView shouldDelayWindowOrderingForEvent:]): Added a call to _setMouseDownEvent:nil
before returning.
(-[WebHTMLView mouseUp:]): Added a call to _setMouseDownEvent:nil to clear the event set in
mouseDown: (and used during dragging).
(-[WebHTMLView _delegateDragSourceActionMask]): Copy the hit HTMLView's mouse down event to
the top HTMLView.
2006-07-28 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
<rdar://problem/4657473> REGRESSION: Spell check not available from contextual menu in Mail
The context menu code should be checking isContentEditable
on DOMNode not just DOMElement. This is needed because DOMText
will be the node class of any text that is clicked.
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate webView:contextMenuItemsForElement:defaultMenuItems:]):
2006-07-25 Geoffrey Garen <ggaren@apple.com>
Reviewed by Maciej, inspired by John.
- Fixed <rdar://problem/4651931> 1% REGRESSION on iBench HTML due to
repeated requests for non-existent favicon
An optimization to avoid serializing favicon data for missing icons had stomped an
optimization to avoid GETing a missing favicon more than once. The solution
is a happy marriage of optimizations, ensuring that we *retain* the missing
favicon's "i am missing" data without posting a notification or saving it to disk.
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _setIconURL:forURL:]):
2006-07-25 David Harrison <harrison@apple.com>
Reviewed by timo and Darin.
<rdar://problem/4618584> "Paste and Match Style" is not working in Mail (add SPI)
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebView.m:
(-[WebView replaceSelectionWithNode:]):
(-[WebView _replaceSelectionWithNode:matchStyle:]):
* WebView/WebViewPrivate.h:
(-[WebView _replaceSelectionWithNode:matchStyle::]):
New SPI that is same as replaceSelectionWithNode: with added parameter whether to match existing style.
2006-07-24 Darin Adler <darin@apple.com>
Reviewed by Adele and Justin.
- update for change to require context when creating fragments from text
(needed to handle whitespace properly)
* WebView/WebHTMLView.m:
(-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:chosePlainText:]):
Added context parameter, pass through to bridge.
(-[WebHTMLView _pasteWithPasteboard:allowPlainText:]): Pass selection range as context
when calling above method.
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]): Pass drag caret as context when
calling above method.
2006-07-24 Maciej Stachowiak <mjs@apple.com>
Reviewed by Geoff.
- fix <rdar://problem/4609195> Help Viewer loads empty window (not getting didFailLoadingWithError: callback)
(without re-introducing http://bugs.webkit.org/show_bug.cgi?id=10062 )
* WebView/WebLoader.h:
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader receivedError:]): Copy in some code from the base class to do it in the proper
order, surrounding the call to [ds _receivedMainResourceError:error complete:YES].
2006-07-24 Anders Carlsson <acarlsson@apple.com>
Reviewed by Tim O.
* Misc/WebIconDatabase.m:
(-[WebIconDatabase removeAllIcons]):
Make an array of the keys and iterate through it to avoid modifying the
dictionary while enumerating it.
2006-07-24 Timothy Hatcher <timothy@apple.com>
Reviewed by John and Darin.
<rdar://problem/4634290> Cannot selectively install a custom
scroller that differs from the default Aqua frame size.
Adds two new private methods to WebFrameView that allows
an application to set a custom scroll view class. This is needed
if the application wants to install a custom scroller that is wider
than the typical scroller, because NSScrollView does the content
rect calculations in a class method (ignoring custom scrollers.)
The _setScrollViewClass method requires the class to be a subclass
of WebDynamicScrollBarView, or nil can be passed to reset to the default class.
A new scroll view of the specified class will then replace the previous
one without the need to reload content of the frame.
* WebView/WebFrameView.m:
(-[WebFrameView _customScrollViewClass]):
(-[WebFrameView _setCustomScrollViewClass:]):
* WebView/WebFrameViewPrivate.h:
2006-07-24 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Darin.
Fix http://bugs.webkit.org/show_bug.cgi?id=10009
REGRESSION: Schubert-IT PDF Plug-in not working for full page (works in frames)
* WebView/WebView.m:
(+[WebView _viewClass:andRepresentationClass:forMIMEType:]): If we've got a type supported by WebPDFView,
make sure to initialize the plugin database, in case a plugin wants to handle it.
2006-07-23 Mark Rowe <opendarwin.org@bdash.net.nz>
Reviewed by Maciej.
Bug 9686: [Drosera] Need the ability to break into Drosera on Javascript exceptions
http://bugs.webkit.org/show_bug.cgi?id=9686
WebKit portion of the fix.
* DefaultDelegates/WebDefaultScriptDebugDelegate.m:
(-[WebDefaultScriptDebugDelegate webView:exceptionWasRaised:sourceId:line:forWebFrame:]):
* DefaultDelegates/WebScriptDebugServer.h:
* DefaultDelegates/WebScriptDebugServer.m:
(-[WebScriptDebugServer webView:exceptionWasRaised:sourceId:line:forWebFrame:]): Notify
listeners that an exception has been raised.
* WebView/WebScriptDebugDelegate.h:
* WebView/WebScriptDebugDelegate.m:
(-[WebScriptCallFrame exceptionRaised:sourceId:line:]): Dispatch through to delegate and
WebScriptDebugServer.
2006-07-23 Adele Peterson <adele@apple.com>
Reviewed by Darin.
- Fix for <rdar://problem/4646276> CrashTracer: 7 crashes in Safari at com.apple.WebCore: WebCore::RenderTableSection::paint + 155
* WebView/WebHTMLView.m: (-[WebHTMLView _web_layoutIfNeededRecursive:testDirtyRect:]):
needsDisplay was returning NO even though the view has a dirty rect (see <rdar://problem/4647062>). Since we know about
the dirty rect, we don't actually need to check needsDisplay.
2006-07-22 Timothy Hatcher <timothy@apple.com>
Rolling out r15572.
Bug 10062: REGRESSION: dom/xhtml/level2/html/HTMLIFrameElement11.xhtml asserts/crashes
http://bugs.webkit.org/show_bug.cgi?id=10062
2006-07-21 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
<rdar://problem/4609195> Help Viewer loads empty window
(not getting didFailLoadingWithError: callback)
Call super's didFailWithError before _receivedMainResourceError
because _receivedMainResourceError will cause the datasource's
frame to be set to nil before the didFailLoadingWithError delegate
callback is sent. (This order is needed now that WebDataSource does
not hold on to the WebView; it uses the WebFrame to get to the WebView.
If the WebFrame is nil we can't get to the WebView's resource load delegate.)
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader receivedError:]):
2006-07-22 Timothy Hatcher <timothy@apple.com>
Reviewed by Adele.
<rdar://problem/4646318> REGRESSION: Ctrl-clicking on a selection containing a word doesn't display a complete contextual menu
Show the editing context menu if the WebView is editible.
The original change only checked if the DOM element was editable,
and isContentEditable returns NO if entire WebView is editable.
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate webView:contextMenuItemsForElement:defaultMenuItems:]):
2006-07-21 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
<rdar://problem/4609195> Help Viewer loads empty window
(not getting didFailLoadingWithError: callback)
Call super's didFailWithError before _receivedMainResourceError
because _receivedMainResourceError will cause the datasource's
frame to be set to nil before the didFailLoadingWithError delegate
callback is sent. (This order is needed now that WebDataSource does
not hold on to the WebView; it uses the WebFrame to get to the WebView.
If the WebFrame is nil we can't get to the WebView's resource load delegate.)
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader receivedError:]):
=== Safari-521.20 ===
2006-07-21 Timothy Hatcher <timothy@apple.com>
Reviewed by John.
<rdar://problem/4607572> REGRESSION (521.10.1 - 521.13): most context menu items missing when a form field is focused (common on google.com) (9680)
Do not use _isEditable call since that only checks if the current
selection or frame is editible. We now check if the currently clicked element
is a content editible area, a textarea, an isindex or an input element that
return YES to _isTextField.
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate webView:contextMenuItemsForElement:defaultMenuItems:]):
2006-07-20 John Sullivan <sullivan@apple.com>
Reviewed by Maciej
- WebKit part of fix for:
<rdar://problem/4557386> REGRESSION (419.3-521.19): repro Safari world leak involving
closing tabs after clicking in a web page
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge textViewWasFirstResponderAtMouseDownTime:]):
renamed to be more specific (formerly wasFirstResponderAtMouseDownTime:)
* WebView/WebHTMLViewInternal.h:
* WebView/WebHTMLView.m:
(-[WebTextCompleteController dealloc]):
updated for name change
(-[NSArray _setMouseDownEvent:]):
Now only retains the first responder if it's a textView, since that's the only case that the only client
actually cares about. This avoids a reference cycle caused by retaining self. This is the only substantive
part of the patch; all the rest is just renaming for clarity, and comments.
(-[NSArray mouseDown:]):
updated for name change
(-[WebHTMLView _textViewWasFirstResponderAtMouseDownTime:]):
renamed to be more specific (formerly _wasFirstResponderAtMouseDownTime:)
2006-07-19 Tim Omernick <timo@apple.com>
Reviewed by Darin.
<rdar://problem/4523432> safari crashed right after disabling "block pop up windows" (or other WebPreferences changes)
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView viewWillMoveToSuperview:]):
Stop the plug-in when it is removed from its superview. It is not sufficient to do this in -viewWillMoveToWindow:nil, because
the WebView might still has a hostWindow at that point, which prevents the plug-in from being destroyed.
There is no need to start the plug-in when moving into a superview. -viewDidMoveToWindow takes care of that.
=== Safari-521.19 ===
2006-07-17 Tim Omernick <timo@apple.com>
Reviewed by Maciej.
<rdar://problem/4612079> need a way to prevent pages from scrolling to reveal elements that are focused
by script
* WebView/WebViewPrivate.h:
* WebView/WebView.m:
(-[WebView setProhibitsMainFrameScrolling:]):
New method. Prohibits scrolling in the WebView's main frame. Used to "lock" a WebView to a specific
scroll position.
2006-07-17 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4635311> REGRESSION: WebKit should call windowScriptObjectAvailable before attaching the script debugger
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge windowObjectCleared]):
2006-07-17 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
<rdar://problem/4634874> WebScriptObject and WebUndefined are no longer defined by WebKit
Copy WebScriptObject.h from WebCore's private headers, not JavaScriptCore.
* WebKit.xcodeproj/project.pbxproj:
2006-07-17 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
- fixed <rdar://problem/4604366> Orange Find highlight displays text in wrong size on PDF pages
if they're not at "actual size"
To match WebHTMLView, I made the methods that return attributed strings take the view's scale
factor into account.
* WebView/WebPDFView.m:
(-[WebPDFView _scaledAttributedString:]):
new helper method, takes an attributed string and returns one that's scaled by the view's
current scale factor
(-[WebPDFView attributedString]):
pass result through _scaledAttributedString:
(-[WebPDFView selectedAttributedString]):
ditto
2006-07-17 Justin Garcia <justin.garcia@apple.com>
Reviewed by levi
Rolled the first fix for:
<http://bugs.webkit.org/show_bug.cgi?id=9642>
GMail Editor: Operations that use drop down menus blow away the selection
back in and removed the call to _clearSelectionInOtherFrames from
-[WebHTMLView becomeFirstResponder] to fix the bug.
* WebView/WebHTMLView.m:
(-[NSArray maintainsInactiveSelection]):
(-[NSArray becomeFirstResponder]):
* WebView/WebView.m:
(-[WebView maintainsInactiveSelection]):
2006-07-15 Darin Adler <darin@apple.com>
Reviewed by John Sullivan.
- fix http://bugs.webkit.org/show_bug.cgi?id=9928
REGRESSION: Text Encoding menu inoperative (after gcc protocol build fix)
* WebView/WebHTMLView.m:
(-[WebHTMLView _documentRange]): Moved into WebHTMLViewFileInternal category.
(-[WebHTMLView selectionRect]): Moved into WebDocumentPrivateProtocols category.
(-[WebHTMLView selectionView]): Ditto.
(-[WebHTMLView selectionImageForcingWhiteText:]): Ditto.
(-[WebHTMLView selectionImageRect]): Ditto.
(-[WebHTMLView pasteboardTypesForSelection]): Ditto.
(-[WebHTMLView selectAll]): Ditto.
(-[WebHTMLView deselectAll]): Ditto.
(-[WebHTMLView string]): Ditto.
(-[WebHTMLView _attributeStringFromDOMRange:]): Ditto.
(-[WebHTMLView attributedString]): Ditto.
(-[WebHTMLView selectedString]): Ditto.
(-[WebHTMLView selectedAttributedString]): Ditto.
(-[WebHTMLView supportsTextEncoding]): Ditto.
(-[WebHTMLView _canProcessDragWithDraggingInfo:]): Moved into WebDocumentInternalProtocols.
(-[WebHTMLView _isMoveDrag]): Ditto.
(-[WebHTMLView _isNSColorDrag:]): Ditto.
(-[WebHTMLView draggingUpdatedWithDraggingInfo:actionMask:]): Ditto.
(-[WebHTMLView draggingCancelledWithDraggingInfo:]): Ditto.
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]): Ditto.
(-[WebHTMLView elementAtPoint:]): Ditto.
(-[WebHTMLView elementAtPoint:allowShadowContent:]): Ditto.
* WebKit.xcodeproj/project.pbxproj: Let Xcode 2.3 do its thing.
=== Safari-521.17 ===
2006-07-14 Timothy Hatcher <timothy@apple.com>
Rolling out this fix from r15358 since it isn't resolved.
2006-07-11 Justin Garcia <justin.garcia@apple.com>
Reviewed by levi & thatcher
<http://bugs.webkit.org/show_bug.cgi?id=9642>
GMail Editor: Operations that use drop down menus blow away the selection
* WebView/WebHTMLView.m:
(-[WebHTMLView maintainsInactiveSelection]): Maintain an inactive selection
when resigning as first responder if the selection is editable
or if the WebView tells us to.
* WebView/WebView.m:
(-[WebView maintainsInactiveSelection]): Just because a WebView is
editable doesn't mean selections inside subframes will be. Return
NO by default.
2006-07-14 Timothy Hatcher <timothy@apple.com>
<rdar://problem/4623957> SWB: gcc-5412 (new?) objc warning causes WebCore project failure
Build fix with the new GCC. Removes forward declarations of protocols.
* Misc/WebSearchableTextView.h:
* WebCoreSupport/WebSubresourceLoader.h:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDocumentInternal.h:
* WebView/WebDocumentPrivate.h:
* WebView/WebHTMLView.h:
* WebView/WebPDFView.h:
* WebView/WebScriptDebugDelegatePrivate.h:
2006-06-28 Darin Adler <darin@apple.com>
Reviewed by Adele.
- fix http://bugs.webkit.org/show_bug.cgi?id=9625
<rdar://problem/4604703>
REGRESSION: Focus not removed from password field after ctrl-click in text field
* WebView/WebHTMLView.m: (-[WebHTMLView menuForEvent:]): Set handlingMouseDownEvent to
YES while calling sendContextMenuEvent: on the bridge.
2006-07-14 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
Moved JavaScriptCore to be a public framework.
* WebKit.xcodeproj/project.pbxproj:
2006-07-13 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=9795
REGRESSION: Crash in [WebHTMLView(WebPrivate)
_updateMouseoverWithEvent:]
and http://bugs.webkit.org/show_bug.cgi?id=9850
REGRESSION: Assertion failure (SHOULD NEVER BE REACHED) in -
[WebHTMLView(WebPrivate) removeTrackingRect:]
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateMouseoverWithEvent:]): Return immediately if
the view has already been closed.
2006-07-13 David Harrison <harrison@apple.com>
Reviewed by Justin and Levi.
<rdar://problem/4620743> REGRESSION: Option-Delete doesn't delete words during typing
* Tests:
editing/deleting/delete-by-word-001.html
editing/deleting/delete-by-word-002.html
* WebView/WebHTMLView.m:
(-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:deletionAction:granularity:]):
2006-07-13 Timothy Hatcher <timothy@apple.com>
Rolling out this earlier change (r15378) now that it is fixed on AGL's end.
Fixes <rdar://problem/4624865> Restore 64-bit OpenGL plug-in support once AGL is 64-bit
<rdar://problem/4624858> AGL isn't 64-bit yet; temporarily remove it from WebKit 64-bit build
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.m:
2006-07-13 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4616920> REGRESSION: tabbing in mail moves focus
to next control instead of inserting a tab space.
Change editible WebView's tabKeyCyclesThroughElements to NO only
if the setTabKeyCyclesThroughElements SPI wasn't called.
* WebView/WebView.m:
(-[WebView setEditable:]):
2006-07-12 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=9624
REGRESSION: After ctrl-clicking in a EMPTY input or textarea field, the contextual menu shows "Search in Google" and "Search in Spotlight" as active menu items
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
Don't create Dictionary, Spotlight or Google lookup items if there's no selection.
2006-07-12 Mark Rowe <opendarwin.org@bdash.net.nz>
Reviewed by Timothy.
http://bugs.webkit.org/show_bug.cgi?id=9868
Applications shown in Drosera's "Attach" window remain after exit
* DefaultDelegates/WebScriptDebugServer.m:
(-[WebScriptDebugServer init]): Register for NSApplicationWillTerminateNotification so we will
know when the application is being exited.
(-[WebScriptDebugServer dealloc]): Unregister notification before we are deallocated.
(-[WebScriptDebugServer applicationTerminating:]): Inform anyone listening that we are going away.
2006-07-12 Tim Omernick <timo@apple.com>
Reviewed by Tim Hatcher.
<rdar://problem/4624858> AGL isn't 64-bit yet; temporarily remove it from WebKit 64-bit build
Also, fixed a LOG_ERROR() so that it uses the CGL error instead of the AGL error; Tim H missed this in his build fix
from earlier.
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.m:
2006-07-11 John Sullivan <sullivan@apple.com>
Reviewed by Kevin and Tim O
- added support for creating a selection image with white text
* WebView/WebDocumentPrivate.h:
added -selectionImageForcingWhiteText: and -selectionImageRect to the private
<WebDocumentSelection> protocol
* Misc/WebSearchableTextView.m:
(-[NSString selectionImageForcingWhiteText:]):
added stub for this new method to this obsolete class to satisfy the compiler
(-[NSString selectionImageRect]):
ditto
* WebView/WebHTMLView.m:
(-[WebHTMLView _selectionDraggingImage]):
now calls -selectionImageForcingWhiteText:NO instead of just -selectionImage
(-[WebHTMLView _selectionDraggingRect]):
now calls selectionImageRect, to which the implementation moved
(-[WebHTMLView selectionImageForcingWhiteText:]):
implemented this new method by calling through to new bridge method selectionImageForcingWhiteText:
(-[WebHTMLView selectionImageRect]):
implemented this new method by using existing _selectionDraggingRect implementation
* WebView/WebPDFView.m:
(-[WebPDFView selectionImageForcingWhiteText:]):
implemented by using code that was formerly in Safari
(-[WebPDFView selectionImageRect]):
implemented by returning selectionRect
2006-07-11 Tim Omernick <timo@apple.com>
Reviewed by Geoff.
<http://bugs.webkit.org/show_bug.cgi?id=9843>:
Give Netscape plug-ins access to their own DOM element
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView dealloc]):
Release DOM element.
(-[WebBaseNetscapePluginView getVariable:value:]):
Return NPObject for plugin DOM element.
* Plugins/WebNetscapePluginEmbeddedView.h:
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView initWithFrame:plugin:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:DOMElement:]):
Now takes a DOMElement, in much the same way that WebKit plug-in views take a DOMElement.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
Pass DOMElement to Netscape plug-ins.
(-[WebFrameBridge viewForJavaAppletWithFrame:attributeNames:attributeValues:baseURL:DOMElement:]):
ditto
2006-07-11 Justin Garcia <justin.garcia@apple.com>
Reviewed by levi & thatcher
<http://bugs.webkit.org/show_bug.cgi?id=9642>
GMail Editor: Operations that use drop down menus blow away the selection
* WebView/WebHTMLView.m:
(-[WebHTMLView maintainsInactiveSelection]): Maintain an inactive selection
when resigning as first responder if the selection is editable
or if the WebView tells us to.
* WebView/WebView.m:
(-[WebView maintainsInactiveSelection]): Just because a WebView is
editable doesn't mean selections inside subframes will be. Return
NO by default.
2006-07-11 Tim Omernick <timo@apple.com>
Reviewed by Tim Hatcher.
<rdar://problem/4622748> WebKit now uses deprecated AGL functions
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView _createWindowedAGLContext]):
aglSetDrawable() is deprecated in AGL 3.0. Use aglSetWindowRef() instead.
(-[WebBaseNetscapePluginView _createWindowlessAGLContext]):
aglSetOffScreen() is deprecated in AGL 3.0. Use CGLSetOffScreen(), which does the same thing.
2006-07-11 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Tim O.
- http://bugs.webkit.org/show_bug.cgi?id=7808
Assertion failure in -[WebBaseNetscapePluginStream dealloc] when requesting an invalid URL
* Plugins/WebNetscapePluginStream.m:
(-[WebNetscapePluginStream initWithRequest:pluginPointer:notifyData:sendNotification:]):
Remove the early return when requesting an invalid (unsupported) URL.
=== Safari-521.16 ===
2006-07-10 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by John Sullivan.
- fix <rdar://problem/4621541>, aka <http://bugs.webkit.org/show_bug.cgi?id=9838>
REGRESSION (r14968-r14977): View Source doesn't work for pages from the back/forward cache
* WebView/WebDataSource.m:
(-[WebDataSource _setPrimaryLoadComplete:]): Set our data only if the frame loader is
has just loaded it (when coming from the back/forward cache, it hasn't).
2006-07-10 Brady Eidson <beidson@apple.com>
Reviewed by Alexey
Resolved the console error messages people got from the new DB even if they didn't have it enabled
* Misc/WebIconDatabase.m:
(-[WebIconDatabase init]):
Disabled initializing the IconDatabaseBridge if user is living on the old DB
2006-07-10 Darin Adler <darin@apple.com>
- try to fix Windows build
* COM/WebFrame.h: Qualify DeprecatedString and KURL with WebCore:: prefixes.
2006-07-09 Darin Adler <darin@apple.com>
- try to fix Windows build
* COM/WebFrame.cpp: Rename QChar to DeprecatedChar.
2006-07-09 Darin Adler <darin@apple.com>
- fix newlines to be consistent for all files in the COM directory
(many had mixed style) and set the EOL style to "native" on them.
* COM/*: Set properties and changed files.
2006-07-09 Tim Omernick <timo@apple.com>
Reviewed by Maciej.
<rdar://problem/4404652> Netscape plug-in mouse events broken in HiDPI
Multiply global mouse coordinates by the window scale factor so that plug-ins can use GlobalToLocal() in HiDPI.
This fixes many bugs involving plug-in mouse event handling in HiDPI. Most notably, the Flash player will now
correctly respond to clicks.
* Plugins/WebBaseNetscapePluginView.m:
(+[WebBaseNetscapePluginView getCarbonEvent:]):
(-[WebBaseNetscapePluginView getCarbonEvent:withEvent:]):
2006-07-09 Darin Adler <darin@apple.com>
Reviewed by Tim Hatcher.
- fix assertion firing in plug-in layout tests
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView restartNullEvents]):
Don't start null events if the plug-in is not in the
started state. This happens when the plug-in moves within
its view hierarchy after it has been stopped.
2006-07-09 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Bug 9820: Move new DOM API that has been through API review to public headers
http://bugs.webkit.org/show_bug.cgi?id=9820
* Misc/WebElementDictionary.m: include DOMExtensions.h
* Misc/WebNSViewExtras.m: include DOMExtensions.h
* WebKit.xcodeproj/project.pbxproj: make DOMXPath.h public
2006-07-09 Timothy Hatcher <timothy@apple.com>
Reviewed by Kevin.
Bug 9818: move new UIDelegate API that has been through API review to public headers
http://bugs.webkit.org/show_bug.cgi?id=9818
<rdar://problem/4387541> API: Remove webView:setContentRect: & webViewContentRect: delegate methods?
The fix for 4310363 removed the only use of webViewContentRect: in our code. webView:setContentRect:
was never used to begin with. There's no harm in leaving these around in the API, but they'll cruft it up.
Also removes the never used webViewPrint: SPI that was replaced by webView:printFrameView:.
* DefaultDelegates/WebDefaultUIDelegate.m:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge print]):
* WebView/WebFrameView.h:
* WebView/WebFrameView.m:
* WebView/WebFrameViewPrivate.h:
* WebView/WebUIDelegate.h:
* WebView/WebUIDelegatePrivate.h:
2006-07-09 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Bug 9814: Move new WebView API that has been through API review to public headers
http://bugs.webkit.org/show_bug.cgi?id=9814
* WebView/WebView.h:
* WebView/WebView.m:
(-[WebView close]):
(-[WebView setShouldCloseWithWindow:]):
(-[WebView shouldCloseWithWindow]):
(-[WebView selectedFrame]):
(-[WebView setMainFrameURL:]):
(-[WebView mainFrameURL]):
(-[WebView isLoading]):
(-[WebView mainFrameTitle]):
(-[WebView mainFrameIcon]):
(-[WebView mainFrameDocument]):
(-[WebView setDrawsBackground:]):
(-[WebView drawsBackground]):
(-[WebView toggleSmartInsertDelete:]):
(-[WebView toggleContinuousSpellChecking:]):
(-[WebView canMakeTextStandardSize]):
(-[WebView makeTextStandardSize:]):
(-[WebView maintainsInactiveSelection]):
* WebView/WebViewPrivate.h:
2006-07-09 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
Bug 9487: The XPath section should be removed and/or moved.
http://bugs.webkit.org/show_bug.cgi?id=9487
* WebInspector/webInspector/inspector.css:
* WebInspector/webInspector/inspector.html:
* WebInspector/webInspector/inspector.js:
2006-07-09 Anders Carlsson <acarlsson@apple.com>
Reviewed by Tim O.
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
Initialize wkPathFromFont.
2006-07-09 Darin Adler <darin@apple.com>
- fix release build
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView restorePortState:]): Cast inside the assertion so
that we don't have an unused variable in versions with assertions disabled.
The alternative would be to wrap the whole thing in an #if statement.
2006-07-08 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
* Plugins/WebBaseNetscapePluginView.h:
- Added ivars for OpenGL support. Someday it would be nice to refactor this class so
that each drawing model is encapsulated in a class; this would allow
WebBaseNetscapePluginView to make more efficient use of space, for example by not
keeping OpenGL-related ivars for Quickdraw plug-ins.
* Plugins/WebBaseNetscapePluginView.m:
- Declared a bunch of internal methods for OpenGL support (see below).
- Removed "forUpdate" from CoreGraphics port state struct; it was always set to "YES",
so I just cleaned up the silly code that used it.
- Declared OpenGL port state struct.
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
- Moved a CoreGraphics-related assertion down to the big "switch" statement.
- Don't set window.type here -- according to the Netscape Plug-in API docs, the plug-in
should default to "windowed" mode, and may call NPN_SetValue() during its NPN_New() to
request that the browser use a "windowless" (offscreen) context instead.
- Moved the assertion from the top of this method here; removed a less restrictive
assertion that is now obsolete.
- Removed "forUpdate" flag from CoreGraphics port state struct.
- Fill in OpenGL port state struct. Set up the viewport appropriately for both windowed
and windowless OpenGL plug-ins. Windowed plug-ins need to have their GL viewport
transformed by the amount the plug-in is clipped; windowless plug-ins are drawn off-screen
into a surface whose geometry is never changed or clipped, so they may always draw with
a viewport origin of (0, 0).
(-[WebBaseNetscapePluginView restorePortState:]):
- Removed "forUpdate" flag from CoreGraphics port state struct.
- Restore the old OpenGL context saved by -saveAndSetNewPortStateForUpdate:.
(-[WebBaseNetscapePluginView sendEvent:]):
- Updated an assertion to also include OpenGL. To ensure that attached plug-in window movements
happen atomically with web page redisplays, we assert that the plug-in's window is set only while
the plug-in view is redrawing.
- Same deal as with the assertion; only save/set port state when redrawing the plug-in view. Plug-ins
that use the new drawing models are only allowed to draw when the web page draws. I might consider
changing this for windowed OpenGL plug-ins, since they always obscure the page content anyway.
(-[WebBaseNetscapePluginView isNewWindowEqualToOldWindow]):
- Compare new NP_GLContext structs.
(-[WebBaseNetscapePluginView updateAndSetWindow]):
- In OpenGL mode, can only set window when updating plug-in view.
(-[WebBaseNetscapePluginView setWindowIfNecessary]):
- ditto
- Updated logging for OpenGL drawing mode.
(-[WebBaseNetscapePluginView addWindowObservers]):
- No need to observe frame/bounds change notifications for this and all parent views. See -renewGState
comments below.
(-[WebBaseNetscapePluginView removeWindowObservers]):
- Don't need to remove frame/bounds observers anymore.
(-[WebBaseNetscapePluginView start]):
- Plug-ins are "windowed" by default. This is not a change from our previous behavior, but this is a
better place to set the default value as it allows the plug-in to override it later.
(-[WebBaseNetscapePluginView stop]):
- Destroy AGL context when the plug-in stops.
(-[WebBaseNetscapePluginView dealloc]):
- Assert that the AGL stuff has been cleaned up.
(-[WebBaseNetscapePluginView drawRect:]):
- If this is a windowless OpenGL plugin, blit its contents back into this view.
(-[WebBaseNetscapePluginView renewGState]):
- This method is called when the view or one of its parents is moved or resized (see comments).
(-[WebBaseNetscapePluginView viewWillMoveToWindow:]):
- Hide the AGL window if the plug-in view is about to be removed from its window.
(-[WebBaseNetscapePluginView viewHasMoved:]):
- Renamed and moved to the "Internal" category.
(-[WebBaseNetscapePluginView invalidateRegion:]):
- Style changes.
- Add support for OpenGL (uses the same region type as CoreGraphics).
(-[WebBaseNetscapePluginView getVariable:value:]):
- Style changes.
- Implemented NPNVsupportsOpenGLBool; returns YES since we now support the OpenGL drawing model.
(-[WebBaseNetscapePluginView setVariable:value:]):
- Implemented NPPVpluginWindowBool, which allows plug-ins to specify whether they should be rendered in
"windowed" or "windowless" mode. This is an older part of the Netscape Plug-in API that was never
implemented in WebKit. "Windowed" Quickdraw plug-ins do not actually reside in a separate window, and
can already do many of the same things (such as transparency) that only "windowless" plug-ins can do on
other platforms. However, we need the "windowed" vs. "windowless" distinction for OpenGL plug-ins so
that they have some way of specifying whether they should be rendered on an accelerated overlay surface,
composited into the browser window.
- Support for setting the drawing model to OpenGL.
(-[WebBaseNetscapePluginView _viewHasMoved]):
- Renamed from -viewHasMoved:, and moved down in the file.
- None of this work is necessary when the plug-in is not in a window; the plug-in's state will be properly
restored when it is moved back into a window.
- Reshape OpenGL surface window here.
(-[WebBaseNetscapePluginView _createAGLContextIfNeeded]):
- Creates the AGL context of the appropriate type (windowed/windowless).
(-[WebBaseNetscapePluginView _createWindowedAGLContext]):
- Creates a windowed AGL context, which is an AGL context attached to a child window. This is the only way
to get true hardware acceleration.
(-[WebBaseNetscapePluginView _createWindowlessAGLContext]):
- Creates a windowless AGL context, which is an AGL context attached to an offscreen buffer. This buffer can
then be blitted back into the browser window with a different alpha, or scaled, or whatever.
(-[WebBaseNetscapePluginView _cglContext]):
- Returns the underlying CGL context from the AGL context. We give the plug-in access to the CGL context because
CGL is the more primitive of the GL drawable APIs and allows for finer control over the context.
(-[WebBaseNetscapePluginView _getAGLOffscreenBuffer:width:height:]):
- Returns the buffer allocated for the offscreen AGL context, if there is one.
(-[WebBaseNetscapePluginView _destroyAGLContext]):
- Destroys the AGL context, as well as the associated offscreen buffer or child window.
(-[WebBaseNetscapePluginView _reshapeAGLWindow]):
- Positions the AGL window over the browser window.
(-[WebBaseNetscapePluginView _hideAGLWindow]):
- Hides the AGL window.
(-[WebBaseNetscapePluginView _aglOffscreenImageForDrawingInRect:]):
- Returns an NSImage representation of the offscreen AGL context's framebuffer. This is used to draw the offscreen
bits back into the plug-in view. This is kind of tricky because it has to convert the offscreen buffer in-place
from BGRA to RGBA so that it can be wrapped in an NSBitmapImageRep. See comments.
* WebKit.xcodeproj/project.pbxproj:
Link OpenGL and AGL.
2006-07-09 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
The ICONDEBUG flag now chooses either the new icon database or the old one
No longer any need to live side by side to compare results
* Misc/WebIconDatabase.m:
(-[NSMutableDictionary iconURLForURL:]):
(-[NSMutableDictionary retainIconForURL:]):
(-[NSMutableDictionary releaseIconForURL:]):
(-[WebIconDatabase _setHaveNoIconForIconURL:]):
(-[WebIconDatabase _setIconURL:forURL:]):
(-[WebIconDatabase _resetCachedWebPreferences:]):
2006-07-08 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
Bug 5312: comments aren't available via DOM
http://bugs.webkit.org/show_bug.cgi?id=5312
Makes the Web Inspector show comment node contents.
* WebInspector/WebInspector.m:
(-[DOMNode _displayName]): return the contents of the comment
* WebInspector/webInspector/inspector.js: check for comment nodes
2006-07-09 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Darin.
- http://bugs.webkit.org/show_bug.cgi?id=9572
Add application/xhtml+xml to the Accept header
* WebView/WebFrame.m:
(-[WebFrame _addExtraFieldsToRequest:mainResource:alwaysFromRequest:]): Add an Accept header
to main resource requests.
* English.lproj/StringsNotToBeLocalized.txt: Added new strings.
2006-07-08 Darin Adler <darin@apple.com>
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate contextMenuItemsForElement:defaultMenuItems:]):
Removed misleading old comment.
=== Safari-521.15 ===
2006-07-07 Levi Weintraub <lweintraub@apple.com>
Reviewed by justin
Finished moving deletion selection expansion across the bridge... say that 3 times fast.
* WebView/WebHTMLView.m: Pass granularity to WebCore to handle expansion
(-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:deletionAction:granularity:]):
(-[WebHTMLView _deleteSelection]):
(-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]):
(-[WebHTMLView deleteToMark:]):
2006-07-07 Brady Eidson <beidson@apple.com>
Reviewed by John
Changed an ASSERT to a LOG_ERROR for an error that could be handled gracefully, but
whose assertion was reproducibly causing a build bot failure
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _releaseIconForIconURLString:]):
2006-07-06 Levi Weintraub <lweintraub@apple.com>
Reviewed by justin
Improved table editing
* WebCoreSupport/WebFrameBridge.m: Added method to allow WebCore to trigger
deletion editing delegate
(-[WebFrameBridge shouldDeleteSelectedDOMRange:]):
* WebView/WebHTMLView.m: Moved code that expanded a selection when the delete
key is pressed over to WebCore so we can be more intelligent about how to handle it
(-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:deletionAction:]):
(-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]):
2006-07-07 John Sullivan <sullivan@apple.com>
Reviewed by Tim Hatcher
- fixed <rdar://problem/4606857> WebKit: WebPreferencesChangedNotification not exported
* WebKit.exp:
added surprisingly missing _WebPreferencesChangedNotification, defined in
WebPreferences.h
2006-07-06 Brady Eidson <beidson@apple.com>
Reviewed by John.
Small fix to my previous small fix that only lets the ASSERT off the hook if the DB
is closing
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _releaseIconForIconURLString:]):
2006-07-05 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Small fix that prevents an assertion from triggering if the DB is being cleaned up
(ie, the app being shut down)
* Misc/WebIconDatabase.h:
* Misc/WebIconDatabase.m:
(-[NSMutableDictionary init]):
(-[WebIconDatabase _applicationWillTerminate:]):
(-[WebIconDatabase _releaseIconForIconURLString:]):
2006-07-05 Adele Peterson <adele@apple.com>
Reviewed by Maciej and Hyatt.
WebKit part of initial popup menu implementation.
* WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface):
Initialize WKPopupMenu.
2006-07-05 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
http://bugs.webkit.org/show_bug.cgi?id=3581
iFrames set to display:none are Missing from frames array
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
(-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
Modify to pass the owner element instead of the owner renderer.
* WebView/WebHTMLView.m:
(-[WebHTMLView _topHTMLView]):
Remove assertion, it's not valid anymore.
2006-07-05 Timothy Hatcher <timothy@apple.com>
Reviewed by Harrison.
<rdar://problem/4608423> HIViewAdapter used but not defined
Adds a new export file to fix the build.
* WebKit.LP64.exp: Added.
* WebKit.xcodeproj/project.pbxproj:
2006-07-04 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
Bug 9731: [Drosera] crash when trying to access the scope chain
http://bugs.webkit.org/show_bug.cgi?id=9731
Because of <rdar://problem/4608404> the WebScriptObject, _globalObj, that
WebCoreScriptDebugger holds is unprotected each time the page changes.
This causes Drosera to crash Safari when trying to access the scope chain.
We simply need to detach and re-attach the debugger when the window script
object is cleared until 4608404 is fixed. This change also attaches the
debugger before we call the windowScriptObjectAvailable: delegate method,
so the debugger is ready before anyone might use the window object.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge windowObjectCleared]):
2006-07-04 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Bug 9732: [Drosera] calling removeListener to many times will cause
WebKit's listener count to underflow/wraparound
http://bugs.webkit.org/show_bug.cgi?id=9732
Adds a check to make sure the listener was in our listeners set before
decrementing the global listener count. Also checks for nil in addListner
to prevent a possible exception when adding the object to the set.
* DefaultDelegates/WebScriptDebugServer.m:
(-[WebScriptDebugServer addListener:]):
(-[WebScriptDebugServer removeListener:]):
2006-07-04 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Maciej.
- http://bugs.webkit.org/show_bug.cgi?id=8210
Conditional XMLHttpRequest gets should pass 304 responses unchanged
Test: http/tests/xmlhttprequest/cache-override.html
* Misc/WebNSURLRequestExtras.h: Added _web_isConditionalRequest
* Misc/WebNSURLRequestExtras.m:
(-[NSURLRequest _web_isConditionalRequest]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge syncLoadResourceWithMethod:URL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
Bypass the cache for conditional requests.
* WebCoreSupport/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forDataSource:]): Ditto.
2006-07-01 David Kilzer <ddkilzer@kilzer.net>
Reviewed by NOBODY (fixed Tim's build fix).
* WebView/WebView.m: Added back missing '/' at the beginning of the file.
2006-07-01 Tim Omernick <timo@apple.com>
Reviewed by NOBODY (build fix)
* WebView/WebView.m:
(-[WebView _isMIMETypeRegisteredAsPlugin:]):
Changed nil to NO (typo).
=== Safari-521.14 ===
2006-06-30 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Only enable shouldCloseWithWindow when ObjC GC is enabled.
This maintains backwards compatibility with applications
that expect a WebView to be usable after the window closes.
* WebView/WebView.m:
(-[WebViewPrivate init]):
2006-06-30 Timothy Hatcher <timothy@apple.com>
Reviewed by Anders.
Call _close in dealloc to ensure we cleanup for backwards
compatibility. This will safeguard and cleanup even if the
application doesn't use the new close API yet, like Mail.
* WebView/WebView.m:
(-[WebView dealloc]):
2006-06-29 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4484405> WebKit leaks, improper tear-down
<rdar://problem/3694059> -[WebBackForwardList finalize] is incorrect; design change needed
<rdar://problem/3694103> -[WebFrame finalize] is incorrect; design change needed
<rdar://problem/3694104> -[WebHTMLView finalize] is incorrect; design change needed
Adds a close method to WebView, this needs to be called when the
WebView is no longer needed. To make this easier for the common cases
there is now an "auto close" on WebView that listens to the view's
parent window. If the parent window closes and the WebView has no
hostWindow then the WebView is automatically closed if autoClose is YES.
To manage WebView closing yourself call setAutoClose: and pass NO.
When a WebView closes it will tear-down and not be usable anymore.
Close will will called on various other internal objects as a part
of this, to ensure proper tear-down in GC without relying on finalize.
* History/WebBackForwardList.m:
(-[WebBackForwardList dealloc]):
(-[WebBackForwardList finalize]):
(-[WebBackForwardList _close]):
* History/WebHistoryItem.m:
(+[WebHistoryItem _closeObjectsInPendingPageCaches]):
(+[WebHistoryItem _releaseAllPendingPageCaches]):
* History/WebHistoryItemPrivate.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge close]):
(-[WebFrameBridge saveDocumentToPageCache:]):
(-[WebFrameBridge canGoBackOrForward:]):
* WebView/WebFrame.m:
(-[WebFrame _detachFromParent]):
(-[WebFrame dealloc]):
(-[WebFrame finalize]):
* WebView/WebFrameView.m:
(-[WebFrameView _setWebFrame:]):
(-[WebFrameView finalize]):
* WebView/WebHTMLView.m:
(-[WebHTMLView close]):
(-[WebHTMLView dealloc]):
(-[WebHTMLView finalize]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebHTMLViewPrivate.h:
* WebView/WebScriptDebugDelegate.m:
(-[WebScriptCallFrame _initWithFrame:initWithWebFrame:]):
(-[WebScriptCallFrame parsedSource:fromURL:sourceId:startLine:errorLine:errorMessage:]):
(-[WebScriptCallFrame enteredFrame:sourceId:line:]):
(-[WebScriptCallFrame hitStatement:sourceId:line:]):
(-[WebScriptCallFrame leavingFrame:sourceId:line:]):
* WebView/WebScriptDebugDelegatePrivate.h:
* WebView/WebView.m:
(-[WebViewPrivate init]):
(-[WebView _close]):
(-[WebView dealloc]):
(-[WebView finalize]):
(-[WebView viewWillMoveToWindow:]):
(-[WebView _windowWillClose:]):
(-[WebView setPreferencesIdentifier:]):
(-[WebView mainFrame]):
(-[WebView setHostWindow:]):
(-[WebView searchFor:direction:caseSensitive:wrap:]):
(-[WebView writeSelectionWithPasteboardTypes:toPasteboard:]):
(-[WebView close]):
(-[WebView setAutoClose:]):
(-[WebView autoClose]):
(-[WebView _frameViewAtWindowPoint:]):
* WebView/WebViewPrivate.h:
2006-06-29 Kevin Decker <kdecker@apple.com>
Reviewed by mjs and timo.
Fixed: <rdar://problem/4609119> handleAuthenticationFromResource was removed; needed by the Dashboard
* WebView/WebViewPrivate.h: Added handleAuthenticationFromResource back into the header. Needed by the
Dashboard, but was removed in r.14028 on 2006-04-23.
2006-06-29 Tim Omernick <timo@apple.com>
Reviewed by Kevin Decker.
<rdar://problem/4608487> REGRESSION: reproducible crash in +[WebCoreFrameBridge supportedImageMIMETypes]
* Plugins/WebPluginDatabase.m:
(+[WebPluginDatabase setAdditionalWebPlugInPaths:]):
One might be tempted to add additionalWebPlugInPaths to the global WebPluginDatabase here.
For backward compatibility with earlier versions of the +setAdditionalWebPlugInPaths: SPI,
we need to save a copy of the additional paths and not cause a refresh of the plugin DB
at this time.
(-[WebPluginDatabase _plugInPaths]):
Include additionalWebPlugInPaths if this is the global DB.
(-[WebPluginDatabase refresh]):
Call -_plugInPaths to get the modified array of paths. This is similar to what the old code
(before we had per-WebView plugin search paths).
2006-06-29 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
WebHistoryItem now supports getting and setting arbitrary properties via _transientPropertyForKey: and
-_setTransientProperty:forKey:.
For now, these properties do not persist with the rest of the history data. They are intended to hold transient
per-history-item state, which is something that was until now difficult for a WebKit client app to do.
* History/WebHistoryItemPrivate.h:
* History/WebHistoryItem.m:
(-[WebHistoryItemPrivate dealloc]):
(-[WebHistoryItem _transientPropertyForKey:]):
(-[WebHistoryItem _setTransientProperty:forKey:]):
2006-06-29 Timothy Hatcher <timothy@apple.com>
Reviewed by Harrison.
Smart insert and delete, continuous spell checking and autoscroll
can now be used for any WebView, not just editable ones. All of
these make sense for documents that might contain content editable
areas or our new text fields. Autoscroll is usefull for dragging
for file input controls also.
Added a SPI to toggle WebViews tab key behavior, tabKeyCyclesThroughElements.
WebHTMLView's _interceptEditingKeyEvent now uses WebView's
tabKeyCyclesThroughElements state to determine whether or not
to process tab key events. The idea here is that tabKeyCyclesThroughElements
will be YES when this WebView is being used in a browser, and we
desire the behavior where tab moves to the next element in tab order.
If tabKeyCyclesThroughElements is NO, it is likely that the WebView
is being embedded as the whole view, as in Mail, and tabs should input
tabs as expected in a text editor. Using Option-Tab always cycles
through elements.
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation finishedLoadingWithDataSource:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _interceptEditingKeyEvent:]):
* WebView/WebView.m:
(-[WebViewPrivate init]):
(-[WebView _autoscrollForDraggingInfo:timeDelta:]):
(-[WebView _shouldAutoscrollForDraggingInfo:]):
(-[WebView validateUserInterfaceItem:]):
(-[WebView toggleSmartInsertDelete:]):
(-[WebView toggleContinuousSpellChecking:]):
(-[WebView setTabKeyCyclesThroughElements:]):
(-[WebView tabKeyCyclesThroughElements]):
* WebView/WebViewPrivate.h:
2006-06-29 Anders Carlsson <acarlsson@apple.com>
Reviewed by Tim O.
* WebKit.xcodeproj/project.pbxproj:
Add DOMXPath.h header.
2006-06-28 David Hyatt <hyatt@apple.com>
Fix custom highlighting so that you can paint the entire line (and go
outside the bounds of the line).
Reviewed by harrison
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge customHighlightRect:forLine:]):
(-[WebFrameBridge paintCustomHighlight:forBox:onLine:behindText:entireLine:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLViewPrivate.h:
2006-06-28 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- fix Frame leak on layout tests
* WebCoreSupport/WebPageBridge.m:
(-[WebPageBridge outerView]): Return WebFrameView for main frame instead
of WebView to avoid reference cycle between WebView and Page.
2006-06-28 Timothy Hatcher <timothy@apple.com>
Prefer the Stabs debugging symbols format until DWARF bugs are fixed.
* WebKit.xcodeproj/project.pbxproj:
2006-06-28 Levi Weintraub <lweintraub@apple.com>
Reviewed by justin
http://bugs.webkit.org/show_bug.cgi?id=7568
Bug 7568: Implement Indent/Outdent
Added undo action strings and enum values
* English.lproj/Localizable.strings:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge nameForUndoAction:]):
2006-06-27 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Hookup the new semi-functional SQLite icon database.
For now, it is living side-by-side with the old DB so one can compare the
two for debugging purposes. Also, it is disabled (in WebKit) by default unless you
compile with ICONDEBUG #defined.
Note: To repeat that, if you want to try the new DB, #define ICONDEBUG (WebKitPrefix.h is a good place to do it)
* Misc/WebIconDatabase.m:
(-[NSMutableDictionary iconForURL:withSize:cache:]):
(-[NSMutableDictionary iconURLForURL:]):
(-[NSMutableDictionary retainIconForURL:]):
(-[NSMutableDictionary releaseIconForURL:]):
(-[WebIconDatabase _setHaveNoIconForIconURL:]):
(-[WebIconDatabase _setIconURL:forURL:]):
(-[WebIconDatabase _hasIconForIconURL:]):
(-[WebIconDatabase _resetCachedWebPreferences:]):
* Misc/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]):
* WebKit.xcodeproj/project.pbxproj:
2006-06-26 David Hyatt <hyatt@apple.com>
Fix for 9538, support syntax highlighting for HTML source.
Reviewed by darin
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebView.m:
(-[WebView _setInViewSourceMode:]):
(-[WebView _inViewSourceMode]):
* WebView/WebViewPrivate.h:
2006-06-25 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Bug 9574: Drosera should show inline scripts within the original HTML
http://bugs.webkit.org/show_bug.cgi?id=9574
* Adds a new version of the didParseSource delegate callback with base line number.
* Adds a new delegate callback for when a script fails to parse.
* These new callbacks use NSURLs for the url parameter.
* Adds a new script listener callback to notify when the main resource loads.
* Adds a WebScriptErrorDomian and other keys for use with NSError.
* DefaultDelegates/WebDefaultScriptDebugDelegate.m:
(-[WebDefaultScriptDebugDelegate webView:didParseSource:baseLineNumber:fromURL:sourceId:forWebFrame:]):
(-[WebDefaultScriptDebugDelegate webView:failedToParseSource:baseLineNumber:fromURL:withError:forWebFrame:]):
* DefaultDelegates/WebScriptDebugServer.h:
* DefaultDelegates/WebScriptDebugServer.m:
(-[WebScriptDebugServer webView:didLoadMainResourceForDataSource:]):
(-[WebScriptDebugServer webView:didParseSource:baseLineNumber:fromURL:sourceId:forWebFrame:]):
(-[WebScriptDebugServer webView:failedToParseSource:baseLineNumber:fromURL:withError:forWebFrame:]):
* DefaultDelegates/WebScriptDebugServerPrivate.h:
* WebKit.exp:
* WebView/WebDataSource.m:
(-[WebDataSource _setPrimaryLoadComplete:]):
* WebView/WebScriptDebugDelegate.h:
* WebView/WebScriptDebugDelegate.m:
(-[WebScriptCallFrame parsedSource:fromURL:sourceId:startLine:errorLine:errorMessage:]):
2006-06-24 David Kilzer <ddkilzer@kilzer.net>
Reviewed by Timothy.
* Info.plist: Fixed copyright to include 2003-2006.
2006-06-24 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Darin.
- http://bugs.webkit.org/show_bug.cgi?id=9418
WebKit will not build when Space exists in path
* WebKit.xcodeproj/project.pbxproj: Enclose search paths in quotes.
2006-06-23 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView sendEvent:]):
Fixed a bug I found in the CoreGraphics drawing model that was preventing certain types of
events from being dispatched to the plugin, unless the plugin was being updated. The check
for portState was only required to call -setWindowIfNecessary, not required for the entire
event dispatch.
Also, don't paint the green debug rect unless this is a QuickDraw plugin. Otherwise the
current QD port is not set, and the green rect fills the entire screen. Pretty awesome
looking, but not intended behavior.
(-[WebBaseNetscapePluginView setWindowIfNecessary]):
Improved the logging here to include the NPWindow's width and height.
2006-06-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Tim O.
Adds back SPI that Mail is still depending on.
* WebView/WebDataSource.m:
(-[WebDataSource _addSubframeArchives:]):
* WebView/WebDataSourcePrivate.h:
=== WebKit-521.13 ===
2006-06-23 Timothy Hatcher <timothy@apple.com>
Reviewed by Geoff.
script debugger should only attach to JavaScriptCore when there are listeners
http://bugs.webkit.org/show_bug.cgi?id=9552
Attaches the debugger to all WebFrames when the first listener
is added. Detaches when the last listener is removed.
Also detach when the script debug delegate is set to nil.
* DefaultDelegates/WebScriptDebugServer.m:
(+[WebScriptDebugServer listenerCount]):
(-[WebScriptDebugServer dealloc]):
(-[WebScriptDebugServer attachScriptDebuggerToAllWebViews]):
(-[WebScriptDebugServer detachScriptDebuggerFromAllWebViews]):
(-[WebScriptDebugServer listenerConnectionDidDie:]):
(-[WebScriptDebugServer addListener:]):
(-[WebScriptDebugServer removeListener:]):
* DefaultDelegates/WebScriptDebugServerPrivate.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge windowObjectCleared]):
* WebView/WebFrame.m:
(-[WebFrame _attachScriptDebugger]):
(-[WebFrame _detachScriptDebugger]):
* WebView/WebFramePrivate.h:
* WebView/WebScriptDebugDelegate.m:
(-[WebScriptCallFrame parsedSource:fromURL:sourceId:]):
(-[WebScriptCallFrame enteredFrame:sourceId:line:]):
(-[WebScriptCallFrame hitStatement:sourceId:line:]):
(-[WebScriptCallFrame leavingFrame:sourceId:line:]):
* WebView/WebView.m:
(-[WebView _attachScriptDebuggerToAllFrames]):
(-[WebView _detachScriptDebuggerFromAllFrames]):
(-[WebView setScriptDebugDelegate:]):
* WebView/WebViewPrivate.h:
2006-06-22 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick
- added support for UIDelegate to be notified of scrolling in any WebHTMLView
- cleaned up recently-added UIDelegate code
* WebView/WebUIDelegatePrivate.h:
declared webView:didScrollDocumentInFrameView: method
* DefaultDelegates/WebDefaultUIDelegate.m:
(-[NSApplication webView:didDrawRect:]):
provide default (empty) implementation of this recently-added method, so the
DelegateForwarder mechanism will work for it
(-[NSApplication webView:didScrollDocumentInFrameView:]):
same thing for the new method
* WebView/WebHTMLView.m:
(-[WebHTMLView _frameOrBoundsChanged]):
use _UIDelegateForwarder mechanism to notify delegate that scrolling occurred
(-[WebHTMLView drawSingleRect:]):
use _UIDelegateForwarder mechanism instead of checking respondsToSelector stuff
here (that's packaged up nicely by the forwarder mechanism)
2006-06-22 Tim Omernick <timo@apple.com>
Reviewed by NOBODY (build fix)
* WebView/WebFrameLoader.m:
Import WebMainResourceLoader instead of using @class so that we can call WebMainResourceLoader
methods.
2006-06-22 Tim Omernick <timo@apple.com>
Reviewed by NOBODY (build fix)
* WebView/WebFrameLoader.m:
Import JavaScriptCore/Assertions.h instead of WebKit/WebAssertions.h (which no longer exists)
2006-06-22 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adele.
- start moving loading logic to new WebFrameLoader class; move management of WebLoaders there
* Misc/WebIconLoader.h:
* Misc/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _updateLoading]):
(-[WebDataSource _loadIcon]):
(-[WebDataSource _setPrimaryLoadComplete:]):
(-[WebDataSource _stopLoading]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _addSubresourceLoader:]):
(-[WebDataSource _removeSubresourceLoader:]):
(-[WebDataSource _addPlugInStreamLoader:]):
(-[WebDataSource _removePlugInStreamLoader:]):
(-[WebDataSource _iconLoaderReceivedPageIcon:]):
(-[WebDataSource _defersCallbacksChanged]):
(-[WebDataSource _stopLoadingWithError:]):
(-[WebDataSource _setupForReplaceByMIMEType:]):
(-[WebDataSource initWithRequest:]):
(-[WebDataSource dealloc]):
(-[WebDataSource finalize]):
(-[WebDataSource data]):
(-[WebDataSource isLoading]):
* WebView/WebFrameLoader.h: Added.
* WebView/WebFrameLoader.m: Added.
(-[WebFrameLoader initWithDataSource:]):
(-[WebFrameLoader dealloc]):
(-[WebFrameLoader hasIconLoader]):
(-[WebFrameLoader loadIconWithRequest:]):
(-[WebFrameLoader stopLoadingIcon]):
(-[WebFrameLoader addPlugInStreamLoader:]):
(-[WebFrameLoader removePlugInStreamLoader:]):
(-[WebFrameLoader setDefersCallbacks:]):
(-[WebFrameLoader stopLoadingPlugIns]):
(-[WebFrameLoader isLoadingMainResource]):
(-[WebFrameLoader isLoadingSubresources]):
(-[WebFrameLoader isLoading]):
(-[WebFrameLoader stopLoadingSubresources]):
(-[WebFrameLoader addSubresourceLoader:]):
(-[WebFrameLoader removeSubresourceLoader:]):
(-[WebFrameLoader mainResourceData]):
(-[WebFrameLoader releaseMainResourceLoader]):
(-[WebFrameLoader cancelMainResourceLoad]):
(-[WebFrameLoader startLoadingMainResourceWithRequest:identifier:]):
(-[WebFrameLoader stopLoadingWithError:]):
2006-06-21 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
The WebCoreIconDatabaseBridge was getting messages sent to it after it had been closed, resulting in a crash
on an ASSERT(). After closing the databaseBridge, we simply set it to nil so this can't happen.
anymore.
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _applicationWillTerminate:]):
2006-06-21 Tim Omernick <timo@apple.com>
Reviewed by Geoff Garen.
<rdar://problem/4564131> WebPluginDatabase setAdditionalWebPlugInPaths needs to be per WebView
Added some WebView SPI so that individual WebViews may have different plugin search paths. There are some
limitations with the approach taken here:
- JavaScript may only access the global plugin DB.
- When this SPI is in use, certain WebView methods may not give accurate results, such as +canShowMIMEType:.
- This only works for plugins referenced using the <object> or <embed> tags; plugins that reside in non-standard
file system locations may not be loaded directly into frames.
None of these issues are important to the client that needs this SPI. Rather than re-architect our entire
plugin database, I think it is better to simply accept these limitations for now.
* Plugins/WebPluginDatabase.h:
Added "plugInPaths" ivar, so different plugin databases can have different search paths.
* Plugins/WebPluginDatabase.m:
(+[WebPluginDatabase installedPlugins]):
Give the global plugin database the default plugin search paths.
(+[WebPluginDatabase setAdditionalWebPlugInPaths:]):
Removed static global; this method now sets the plugin paths on the global plugin database.
(-[WebPluginDatabase setPlugInPaths:]):
Setter method for plugin paths.
(-[WebPluginDatabase close]):
New method; called when the plugin database is no longer needed (when its WebView is being destroyed).
(-[WebPluginDatabase init]):
Don't refresh in -init, so that callers can set the DB's plugin path array before it refreshes.
(-[WebPluginDatabase dealloc]):
Moved here from near the bottom of the file. Release new ivar.
(-[WebPluginDatabase refresh]):
Use the plugInPaths ivar instead of calling pluginLocations().
Notify plugin packages when they are added to and removed from a plugin database. A plugin package will
unload itself when it is removed from all of its plugin databases.
The only really tricky thing here is that the global MIME <-> view class registrations are only modified
by the shared plugin DB.
(+[WebPluginDatabase _defaultPlugInPaths]):
Refactored from the old pluginLocations() function; returns the default set of plugin search paths.
* Plugins/WebBasePluginPackage.h:
* Plugins/WebBasePluginPackage.m:
(-[WebBasePluginPackage dealloc]):
Assert that this package has been removed from all of its containing plugin databases.
(-[WebBasePluginPackage finalize]):
ditto
(-[WebBasePluginPackage wasAddedToPluginDatabase:]):
Add plugin database to set.
(-[WebBasePluginPackage wasRemovedFromPluginDatabase:]):
Remove plugin database from set. If it was the last DB, then unload the plugin package.
* WebView/WebViewInternal.h:
Added instance methods to find the view class or plugin package, given a MIME type or file extension.
* WebView/WebViewPrivate.h:
Added SPI to set plugin search paths per WebView.
* WebView/WebView.m:
(-[WebView _viewClass:andRepresentationClass:forMIMEType:]):
New method; tries the global MIME <-> view map first; failing that, it checks the WebView's plugin DB.
(-[WebView _close]):
Close the plugin DB.
(-[WebView _setAdditionalWebPlugInPaths:]):
Create the plugin DB if necessary, and set its plugin paths.
(-[WebView _pluginForMIMEType:]):
Checks global plugin DB, falls back on WebView DB.
(-[WebView _pluginForExtension:]):
ditto
(-[WebView _isMIMETypeRegisteredAsPlugin:]):
ditto
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
Use new WebView instance methods to look for plugins.
(-[WebFrameBridge viewForJavaAppletWithFrame:attributeNames:attributeValues:baseURL:DOMElement:]):
ditto
(-[WebFrameBridge determineObjectFromMIMEType:URL:]):
ditto
2006-06-20 Brady Eidson <beidson@apple.com>
Reviewed by Maciej
Added calls through to the WebCoreIconDatabaseBridge for all the major WebIconDatabase API. For now these calls
are wrapped with #ifdef's and are for debugging only.
* Misc/WebIconDatabase.h:
* Misc/WebIconDatabase.m:
(-[NSMutableDictionary _scaleIcon:toSize:]):
(-[NSMutableDictionary init]):
(-[NSMutableDictionary iconForURL:withSize:cache:]):
(-[NSMutableDictionary iconURLForURL:]):
(-[NSMutableDictionary retainIconForURL:]):
(-[NSMutableDictionary releaseIconForURL:]):
(-[WebIconDatabase _setHaveNoIconForIconURL:]):
(-[WebIconDatabase _setIconURL:forURL:]):
(-[WebIconDatabase _hasIconForIconURL:]):
* Misc/WebIconLoader.m:
(-[WebIconLoader didFinishLoading]):
* Misc/WebKitLogging.h: Added a logging channel for WebIconDatabase debugging
* Misc/WebKitLogging.m:
(WebKitInitializeLoggingChannelsIfNecessary):
2006-06-20 Adele Peterson <adele@apple.com>
Reviewed by Tim Hatcher.
* WebView/WebMainResourceLoader.m: Added missing header to fix build on Leopard.
2006-06-20 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Removes the @try/@catch from the callbacks to improve performance,
simply check if the proxy object's connection is still valid first.
Listener objects are now required to be NSDistantObjects.
Adds pause, resume and step support. The debugger process use to handle this,
but it caused problems when there were multiple listeners.
Sends the bundle identifier in the notification userInfo dictionary along with
process name and process ID.
* DefaultDelegates/WebScriptDebugServer.h:
* DefaultDelegates/WebScriptDebugServer.m:
(-[WebScriptDebugServer serverQuery:]):
(-[WebScriptDebugServer addListener:]):
(-[WebScriptDebugServer removeListener:]):
(-[WebScriptDebugServer step]):
(-[WebScriptDebugServer pause]):
(-[WebScriptDebugServer resume]):
(-[WebScriptDebugServer isPaused]):
(-[WebScriptDebugServer suspendProcessIfPaused]):
(-[WebScriptDebugServer webView:didParseSource:fromURL:sourceId:forWebFrame:]):
(-[WebScriptDebugServer webView:didEnterCallFrame:sourceId:line:forWebFrame:]):
(-[WebScriptDebugServer webView:willExecuteStatement:sourceId:line:forWebFrame:]):
(-[WebScriptDebugServer webView:willLeaveCallFrame:sourceId:line:forWebFrame:]):
* DefaultDelegates/WebScriptDebugServerPrivate.h:
* WebKit.exp:
2006-06-19 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Darin.
- http://bugs.webkit.org/show_bug.cgi?id=5499
Page reload does not send any cache control headers
* WebView/WebFrame.m:
(-[WebFrame _addExtraFieldsToRequest:mainResource:alwaysFromRequest:]): Set a proper Cache-Control header for
reload requests.
(-[WebFrame loadRequest:]): Reset loadType to WebFrameLoadTypeStandard (after a reload, it stayed at
WebFrameLoadTypeReload, so _addExtraFieldsToRequest erroneously added a Cache-Control header to them).
2006-06-19 John Sullivan <sullivan@apple.com>
Reviewed by Darin.
- added mechanism to notify UIDelegate when part of the webview is redrawn. For now, it only
works for HTML views.
* WebView/WebUIDelegatePrivate.h:
Define a new UIDelegate method -webView:didDrawRect:
* WebView/WebHTMLView.m:
(-[WebView drawSingleRect:]):
Call through to UIDelegate if it implements that method. I tested that this does not impact PLT numbers
in the case where the delegate implements the method but does nothing in it.
2006-06-19 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Maciej.
- fix http://bugs.webkit.org/show_bug.cgi?id=9452
Assertion failure in -[WebFramePrivate setProvisionalDataSource:]
* WebView/WebFrame.m:
(-[WebFrame _checkLoadCompleteForThisFrame]): Avoid re-entering the delegate's
-[webView:didFailProvisionalLoadWithError:forFrame].
2006-06-18 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by xenon.
- http://bugs.webkit.org/show_bug.cgi?id=9479
Disassociate the inspector from the frame when it detaches from its parent
* WebInspector/WebInspector.m:
(-[NSWindow setWebFrame:]): Added code to (de)register with the WebFrame
the inspector is (no longer) targeting.
(-[WebInspector _webFrameDetached:]): Added. Moved the code that was previously
in -[inspectedWindowWillClose:] here. This is called by the WebFrame when it
is detached from its parent.
* WebInspector/WebInspectorInternal.h:
* WebView/WebFrame.m:
(-[WebFramePrivate dealloc]):
(-[WebFrame _detachFromParent]): Added code to notify all registered inspectors
that the WebFrame is detaching.
(-[WebFrame _addInspector:]): Added.
(-[WebFrame _removeInspector:]): Added.
* WebView/WebFrameInternal.h:
2006-06-18 Anders Carlsson <acarlsson@apple.com>
Reviewed by Geoff.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge shouldInterruptJavaScript]):
Ask the UI delegate if the script should be interrupted.
* WebView/WebUIDelegatePrivate.h:
Declare webViewShouldInterruptJavaScript: delegate method
2006-06-17 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=9466
Assertion failure when dragging an image from the document into Safari's address bar
* WebView/WebFrameView.m:
(-[WebFrameView _setDocumentView:]): Reset the WebView's initiatedDrag flag
when the document view is changed.
* WebView/WebHTMLView.m:
(-[WebHTMLView draggedImage:endedAt:operation:]): Changed the ASSERT to allow
for drags that end after the view has been removed from the WebView.
2006-06-16 Timothy Hatcher <timothy@apple.com>
Reviewed by Tim O.
Exposes a distributed objects server for clients to register for script debugger calls.
For preformance concerns this is disabled by default, you will need to enable this per application.
To enable for Safari do this: defaults write com.apple.Safari WebKitScriptDebuggerEnabled -bool true
Clients will need to listen to the following distributed notification to discover servers:
WebScriptDebugServerDidLoadNotification
To discover servers that previously loaded before the client, the client needs to send the following notification:
WebScriptDebugServerQueryNotification
All servers will reply with the WebScriptDebugServerQueryReplyNotification notification that contains the
registered server connection name to use with distributed objects.
* DefaultDelegates/WebScriptDebugServer.h: Added.
* DefaultDelegates/WebScriptDebugServer.m: Added.
(+[WebScriptDebugServer sharedScriptDebugServer]):
(-[WebScriptDebugServer init]):
(-[WebScriptDebugServer dealloc]):
(-[WebScriptDebugServer serverQuery:]):
(-[WebScriptDebugServer listenerConnectionDidDie:]):
(-[WebScriptDebugServer addListener:]):
(-[WebScriptDebugServer removeListener:]):
(-[WebScriptDebugServer webView:didParseSource:fromURL:sourceId:forWebFrame:]):
(-[WebScriptDebugServer webView:didEnterCallFrame:sourceId:line:forWebFrame:]):
(-[WebScriptDebugServer webView:willExecuteStatement:sourceId:line:forWebFrame:]):
(-[WebScriptDebugServer webView:willLeaveCallFrame:sourceId:line:forWebFrame:]):
* DefaultDelegates/WebScriptDebugServerPrivate.h: Added.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge windowObjectCleared]):
* WebKit.exp:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebScriptDebugDelegate.m:
(-[WebScriptCallFrame parsedSource:fromURL:sourceId:]):
(-[WebScriptCallFrame enteredFrame:sourceId:line:]):
(-[WebScriptCallFrame hitStatement:sourceId:line:]):
(-[WebScriptCallFrame leavingFrame:sourceId:line:]):
* WebView/WebView.m:
(+[WebView _developerExtrasEnabled]):
(+[WebView _scriptDebuggerEnabled]):
(-[WebView _menuForElement:defaultItems:]):
(-[WebView _commonInitializationWithFrameName:groupName:]):
* WebView/WebViewPrivate.h:
2006-06-16 Adele Peterson <adele@apple.com>
Reviewed by Alice.
Added initialization for WKDrawBezeledTextArea.
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
2006-06-15 Timothy Hatcher <timothy@apple.com>
Reviewed by Geoff and Darin.
Prefer the DWARF debugging symbols format for use in Xcode 2.3.
* WebKit.xcodeproj/project.pbxproj:
2006-06-15 John Sullivan <sullivan@apple.com>
Reviewed by Tim O.
Fixed bug in WebKit support for computing but not highlighting rects for text matches.
* WebView/WebView.m:
(-[WebView rectsForTextMatches]):
leave out empty rects, and convert rects to WebView coordinates. Since this makes a batch
of autoreleased NSValue objects, use a local autorelease pool
2006-02-11 David Kilzer <ddkilzer@kilzer.net>
Reviewed by John Sullivan.
* Plugins/WebPluginController.m:
(-[WebPluginController _cancelOutstandingChecks]):
add nil check before calling CFSetApplyFunction
2006-06-14 Levi Weintraub <lweintraub@apple.com>
Reviewed by justin
<http://bugs.webkit.org/show_bug.cgi?id=7580>
TinyMCE: Implement execCommand(formatBlock, ...)
* English.lproj/Localizable.strings:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge nameForUndoAction:]):
2006-06-14 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4577988> GC: WebPluginController uses inefficient resurrecting enumeration
* Plugins/WebPluginController.m:
(cancelOutstandingCheck):
(-[WebPluginController _cancelOutstandingChecks]):
Use CFSetApplyFunction() instead of an enumerator to guard against modifications to the set while enumerating.
2006-06-13 John Sullivan <sullivan@apple.com>
Reviewed by Tim O.
- fixed <rdar://problem/4498606> REGRESSION (417.8-420+): 3 missing items (but extra separators) in context
menu in Mail message body
* WebView/WebView.m:
(-[WebView _menuForElement:defaultItems:]):
Add special-case hackery to recover from this SPI -> API mismatch.
2006-06-13 Tim Omernick <timo@apple.com>
Reviewed by Anders.
Fixed a recently-introduced assertion failure when handling 404 errors.
* WebView/WebDataSource.m:
(-[WebDataSource _handleFallbackContent]):
Use the -[WebFrame _bridge] instead of -[WebDataSource _bridge]. The former is not valid until the data
source has been committed, which is not the case when the resource fails to load. The latter is safe to call
at any time. This broke last night with Maciej's change to WebFrameResourceLoader. The old code used to
call -[WebFrame _bridge].
2006-06-13 Anders Carlsson <acarlsson@apple.com>
Reviewed by Geoff.
http://bugs.webkit.org/show_bug.cgi?id=9406
REGRESSION: fix for bug 9390 broke two layout tests
* Plugins/WebPluginDatabase.h:
(-[WebPluginDatabase isMIMETypeRegistered:]):
Add new function isMIMETypeRegistered which returns whether a given MIME type has a
plugin registered.
* Plugins/WebPluginDatabase.m:
(-[WebPluginDatabase init]):
Init set of registered MIME types.
(-[WebPluginDatabase refresh]):
Add and remove MIME types from the set of registered MIME types when registering and unregistering
plugin MIME types.
(-[WebPluginDatabase dealloc]):
Release set of registered MIME types.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge determineObjectFromMIMEType:URL:]):
Use isMIMETypeRegistered here.
2006-06-12 Maciej Stachowiak <mjs@apple.com>
- fix for cocoa exception (whoops)
* WebView/WebView.m:
(+[WebView _generatedMIMETypeForURLScheme:]): put this back
* WebView/WebDataSource.m:
(+[WebDataSource _generatedMIMETypeForURLScheme:]): call WebView
2006-06-12 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- remove use of WebView and related from WebMainResourceLoader
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(+[WebDataSource _generatedMIMETypeForURLScheme:]):
(+[WebDataSource _representationExistsForURLScheme:]):
(+[WebDataSource _canShowMIMEType:]):
(-[WebDataSource _handleFallbackContent]):
(-[WebDataSource _decidePolicyForMIMEType:decisionListener:]):
* WebView/WebDataSourceInternal.h:
* WebView/WebFrame.m:
(-[WebFrame _isMainFrame]):
* WebView/WebFrameInternal.h:
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader willSendRequest:redirectResponse:]):
(-[WebMainResourceLoader continueAfterContentPolicy:response:]):
(-[WebMainResourceLoader checkContentPolicyForResponse:]):
(-[WebMainResourceLoader loadWithRequestNow:]):
* WebView/WebView.m:
2006-06-12 Tim Omernick <timo@apple.com>
Reviewed by Maciej.
<rdar://problem/4526052> intermittent assertion failure in -[WebBasePluginPackage dealloc] running layout tests
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage _initWithPath:]):
Renamed from -initWithPath:. Instead of releasing/deallocating self on error, return NO.
(-[WebNetscapePluginPackage initWithPath:]):
Call the new -_initWithPath:. If it returns NO, unload the plugin package before deallocating it.
2006-06-11 Darin Adler <darin@apple.com>
- try to fix Windows build
* COM/WebKitDLL.cpp: (loadResourceIntoArray): Use Vector<char> instead of
DeprecatedByteArray.
2006-06-11 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Tim H.
- fix http://bugs.webkit.org/show_bug.cgi?id=8672
Red outline from web inspector reappears after inspector is closed
* WebInspector/WebInspector.m:
(-[NSWindow windowWillClose:]): Added a call to setWebFrame to avoid further
load progress notifications.
(-[NSWindow setWebFrame:]): Changed to resign the WebView's hostWindow rather
than its window for close notifications, to avoid resigning from all windows' close
notifications (including the inspector window's) when the WebView is in a hidden tab.
Also changed to prevent highlighting the initial focused node.
2006-06-11 Anders Carlsson <acarlsson@apple.com>
Reviewed by Tim.
http://bugs.webkit.org/show_bug.cgi?id=9390
Move full-frame plugins to WebCore
* Plugins/WebBaseNetscapePluginStream.h:
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream instance]):
Add instance method which returns the plugin instance.
* Plugins/WebBasePluginPackage.h:
Add WebPluginManualLoader protocol
* Plugins/WebNetscapePluginDocumentView.h: Removed.
* Plugins/WebNetscapePluginDocumentView.m: Removed.
* Plugins/WebNetscapePluginEmbeddedView.h:
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView initWithFrame:plugin:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:]):
(-[WebNetscapePluginEmbeddedView dealloc]):
(-[WebNetscapePluginEmbeddedView didStart]):
(-[WebNetscapePluginEmbeddedView pluginView:receivedResponse:]):
(-[WebNetscapePluginEmbeddedView pluginView:receivedData:]):
(-[WebNetscapePluginEmbeddedView pluginView:receivedError:]):
(-[WebNetscapePluginEmbeddedView pluginViewFinishedLoading:]):
(-[WebNetscapePluginEmbeddedView redeliverStream]):
Make WebNetscapePluginEmbeddedView support the WebPluginManualLoader protocol. It creates a plugin stream and feeds the
data manually. Much of this code has been copied from WebNetscapePluginRepresentation.
* Plugins/WebNetscapePluginRepresentation.h: Removed.
* Plugins/WebNetscapePluginRepresentation.m: Removed.
* Plugins/WebPluginController.h:
* Plugins/WebPluginController.m:
(-[WebPluginController pluginView:receivedResponse:]):
(-[WebPluginController pluginView:receivedData:]):
(-[WebPluginController pluginView:receivedError:]):
(-[WebPluginController pluginViewFinishedLoading:]):
Make WebPluginController support the WebPluginManualLoader protocol so it can feed data manually to WebKit plugins.
* Plugins/WebPluginDatabase.m:
(-[WebPluginDatabase refresh]):
Use WebHTMLView and WebHTMLRepresentation when registering/unregistering plug-in MIME types.
* Plugins/WebPluginDocumentView.h: Removed.
* Plugins/WebPluginDocumentView.m: Removed.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge pluginViewWithPackage:attributeNames:attributeValues:baseURL:DOMElement:loadManually:]):
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
Add loadManually argument.
(-[WebFrameBridge redirectDataToPlugin:]):
Call down to the HTML representation.
(-[WebFrameBridge viewForJavaAppletWithFrame:attributeNames:attributeValues:baseURL:DOMElement:]):
Pass NO to loadManually.
(-[WebFrameBridge determineObjectFromMIMEType:URL:]):
Explicitly check if the MIME type is supported by a plug-in instead of checking the view class.
* WebCoreSupport/WebViewFactory.m:
(-[WebViewFactory pluginSupportsMIMEType:]):
New function which returns whether any plugins support a given MIME type.
* WebKit.xcodeproj/project.pbxproj:
Update for removed files.
* WebView/WebFrame.m:
(-[WebFrame _reloadForPluginChanges]):
Remove view type checks.
(-[WebFrame _recursive_pauseNullEventsForAllNetscapePlugins]):
(-[WebFrame _recursive_resumeNullEventsForAllNetscapePlugins]):
Remove FIXME comments.
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation _redirectDataToManualLoader:forPluginView:]):
New function which redirects incoming data to a manual loader.
(-[WebHTMLRepresentation receivedData:withDataSource:]):
(-[WebHTMLRepresentation receivedError:withDataSource:]):
(-[WebHTMLRepresentation finishedLoadingWithDataSource:]):
Optionally redirect incoming data.
* WebView/WebHTMLRepresentationPrivate.h:
2006-06-09 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick and Dave Hyatt.
WebKit support for computing but not highlighting rects for text matches.
* WebView/WebHTMLViewPrivate.h:
added markedTextMatchesAreHighlighted/setMarkedTextMatchesAreHighlighted and
rectsForTextMatches, and renamed related methods for clarity/consistency
* WebView/WebHTMLView.m:
(-[WebHTMLView markAllMatchesForText:caseSensitive:]):
renamed, calls similarly-renamed method
(-[WebHTMLView setMarkedTextMatchesAreHighlighted:]):
new method, calls through to bridge
(-[WebHTMLView markedTextMatchesAreHighlighted]):
ditto
(-[WebHTMLView unmarkAllTextMatches]):
renamed
(-[WebHTMLView rectsForTextMatches]):
new method, calls through to bridge
* WebView/WebViewPrivate.h:
added rectsForTextMatches, renamed other methods (and added highlight: parameter)
* WebView/WebView.m:
(-[WebView markAllMatchesForText:caseSensitive:highlight:]):
renamed for clarity/consistency, and now has highlight: parameter, which is passed down
(-[WebView unmarkAllTextMatches]):
renamed for clarity/consistency, and calls similarly-renamed method lower down. diff got
confused with the end of this and the end of the next method.
(-[WebView rectsForTextMatches]):
new method, calls through to WebHTMLView as related methods currently do
2006-06-10 Graham Dennis <Graham.Dennis@gmail.com>
<http://bugs.webkit.org/show_bug.cgi?id=9384>
WebView's initWithCoder: method does not set useBackForwardList
correctly
Reviewed by John Sullivan.
* WebView/WebView.m:
(-[WebView initWithCoder:]):
Make sure that the function variable useBackForwardList is correctly
set, so that the copy in the _private ivar is set.
2006-06-09 David Hyatt <hyatt@apple.com>
Rename updateFocusState to updateActiveState.
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateActiveState]):
(-[WebHTMLView viewDidMoveToWindow]):
(-[WebHTMLView windowDidBecomeKey:]):
(-[WebHTMLView windowDidResignKey:]):
(-[WebHTMLView becomeFirstResponder]):
(-[WebHTMLView resignFirstResponder]):
(-[WebHTMLView _formControlIsBecomingFirstResponder:]):
(-[WebHTMLView _formControlIsResigningFirstResponder:]):
* WebView/WebHTMLViewPrivate.h:
2006-06-09 David Hyatt <hyatt@apple.com>
Rename displaysWithFocusAttributes to isActive.
Reviewed by sfalken
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateFocusState]):
2006-06-08 Justin Garcia <justin.garcia@apple.com>
Reviewed by levi
<http://bugs.webkit.org/show_bug.cgi?id=4468>
Implement execCommand(Insert{Un}OrderedList)
* WebView/WebFrame.m:
(-[WebFrame _findFrameWithSelection]): Removed an assertion
that we only have one frame with a selection.
* WebView/WebView.m:
(-[WebView selectedFrame]): Ditto.
2006-06-08 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin and John.
<rdar://problem/3600734> API: please add a way to turn vertical scrollbar
always on (for Mail, to avoid reflow when typing)
Adds new methods to lock the scrolling mode on WebDynamicScrollBarsView.
Locking the scroll mode prevents WebCore from changing it as needed.
Also adds an SPI on WebView that will lock the "always on" mode
for each scroller.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDynamicScrollBarsView.h:
* WebView/WebDynamicScrollBarsView.m:
(-[WebDynamicScrollBarsView setAllowsScrolling:]):
(-[WebDynamicScrollBarsView allowsScrolling]):
(-[WebDynamicScrollBarsView setAllowsHorizontalScrolling:]):
(-[WebDynamicScrollBarsView setAllowsVerticalScrolling:]):
(-[WebDynamicScrollBarsView setHorizontalScrollingMode:]):
(-[WebDynamicScrollBarsView setVerticalScrollingMode:]):
(-[WebDynamicScrollBarsView setScrollingMode:]):
(-[WebDynamicScrollBarsView setHorizontalScrollingModeLocked:]):
(-[WebDynamicScrollBarsView setVerticalScrollingModeLocked:]):
(-[WebDynamicScrollBarsView setScrollingModesLocked:]):
(-[WebDynamicScrollBarsView horizontalScrollingModeLocked]):
(-[WebDynamicScrollBarsView verticalScrollingModeLocked]):
* WebView/WebView.m:
(-[WebView setAlwaysShowVerticalScroller:]):
(-[WebView alwaysShowVerticalScroller]):
(-[WebView setAlwaysShowHorizontalScroller:]):
(-[WebView alwaysShowHorizontalScroller]):
* WebView/WebViewPrivate.h:
2006-06-08 Darin Adler <darin@apple.com>
Reviewed by Justin.
- fix http://bugs.webkit.org/show_bug.cgi?id=8616
REGRESSION: TinyMCE: Crash on Undo
* WebView/WebHTMLView.m:
(-[WebHTMLView _topHTMLView]): Added.
(-[WebHTMLView _isTopHTMLView]): Added.
(-[WebHTMLView _insideAnotherHTMLView]): Changed to use _topHTMLView.
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
Forward to the top HTML view, so that only the top view ever starts a dragging operation.
Change dragging code to not assume that the dragged node is in the current view's document.
Added checks that the node is an element in a couple places and coordinate conversions.
(-[WebHTMLView _mayStartDragAtEventLocation:]): Forward to the top HTML view.
(-[WebHTMLView addMouseMovedObserver]): Change to do nothing when the dataSource field is 0,
since we now use the dataSource field to get to the WebView.
(-[WebHTMLView removeMouseMovedObserver]): Added a comment.
(-[WebHTMLView dragImage:at:offset:event:pasteboard:source:slideBack:]):
Forward to the top HTML view.
(-[WebHTMLView draggingSourceOperationMaskForLocal:]): Assert that it's the top HTML view.
(-[WebHTMLView draggedImage:movedTo:]): Ditto.
(-[WebHTMLView draggedImage:endedAt:operation:]): Ditto.
(-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]): Ditto.
(-[WebHTMLView _canProcessDragWithDraggingInfo:]): Ditto.
(-[WebHTMLView _isMoveDrag]): Ditto.
(-[WebHTMLView draggingUpdatedWithDraggingInfo:actionMask:]): Ditto.
(-[WebHTMLView draggingCancelledWithDraggingInfo:]): Ditto.
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]): Ditto. Also added code to work
with the appropriate bridge when receiving a drag. This fixes the problem where the
top level frame got a selection intended for the inner frame; the source of the bug.
(-[WebHTMLView elementAtPoint:allowShadowContent:]): Added code to convert the coordinates
so this works properly when returning an element from an inner frame.
(-[WebHTMLView setDataSource:]): Added a call to addMouseMovedObserver, needed now that
addMouseMovedObserver won't do anything if called when dataSource is nil.
(-[WebHTMLView _delegateDragSourceActionMask]): Forward to the top HTML view.
* WebView/WebView.m:
(-[WebViewPrivate dealloc]): Removed code to release dragCaretBridge since that field
is now gone.
(-[WebView moveDragCaretToPoint:]): Always call the main frame's bridge, since the
drag caret is now a page-level item. Later we'll move it to the page bridge.
(-[WebView removeDragCaret]): Ditto.
2006-06-07 David Hyatt <hyatt@apple.com>
Add support for custom highlighting to WebKit.
Reviewed by justin
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge paintCustomHighlight:forBox:onLine:behindText:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _highlighterForType:]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebHTMLViewPrivate.h:
2006-06-07 Adele Peterson <adele@apple.com>
Reviewed by Hyatt.
Added resources for missingImage and textAreaResizeCorner.
* COM/WebKitDLL.cpp:
(loadResourceIntoArray): Added. Returns a DeprecatedByteArray with the resource's data.
* WebKit.vcproj/WebKit.rc: Added missing image and resize pngs as resources.
* WebKit.vcproj/WebKit.vcproj: Added pngs.
* WebKit.vcproj/missingImage.png: Added.
* WebKit.vcproj/resource.h: Added entries for pngs.
* WebKit.vcproj/textAreaResizeCorner.png: Added.
2006-06-07 David Hyatt <hyatt@apple.com>
Add SPI for setting and removing custom highlighters.
Reviewed by Tim H
* WebView/WebHTMLView.m:
(-[WebTextCompleteController dealloc]):
(-[WebHTMLView _setHighlighter:ofType:]):
(-[WebHTMLView _removeHighlighterOfType:]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebHTMLViewPrivate.h:
2006-06-06 Adele Peterson <adele@apple.com>
Reviewed by Justin.
* COM/WebView.cpp:
(WebView::keyPress): Added case for VK_RETURN.
2006-06-06 Anders Carlsson <acarlsson@apple.com>
Reviewed by John.
* WebView/WebFrame.m:
(-[WebFrame _reloadForPluginChanges]):
Don't traverse the view hierarchy looking for plugin views. Instead, just
ask the frame whether it contains any plugins.
2006-06-03 Steve Falkenburg <sfalken@apple.com>
Reviewed by hyatt.
Add implementation of loadHTMLString for Spinneret
* COM/WebFrame.cpp:
(WebFrame::loadHTMLString):
2006-06-02 Steve Falkenburg <sfalken@apple.com>
Reviewed by darin.
New hosting for Spinneret to avoid static linking
* COM: Added.
* COM/Interfaces: Added.
* COM/Interfaces/DOMCSS.idl: Added.
* COM/Interfaces/DOMCore.idl: Added.
* COM/Interfaces/DOMHTML.idl: Added.
* COM/Interfaces/DOMRange.idl: Added.
* COM/Interfaces/IWebArchive.idl: Added.
* COM/Interfaces/IWebAttributedString.idl: Added.
* COM/Interfaces/IWebBackForwardList.idl: Added.
* COM/Interfaces/IWebDataSource.idl: Added.
* COM/Interfaces/IWebDocument.idl: Added.
* COM/Interfaces/IWebDownload.idl: Added.
* COM/Interfaces/IWebEditingDelegate.idl: Added.
* COM/Interfaces/IWebError.idl: Added.
* COM/Interfaces/IWebFrame.idl: Added.
* COM/Interfaces/IWebFrameLoadDelegate.idl: Added.
* COM/Interfaces/IWebFrameView.idl: Added.
* COM/Interfaces/IWebHistoryItem.idl: Added.
* COM/Interfaces/IWebIconDatabase.idl: Added.
* COM/Interfaces/IWebImage.idl: Added.
* COM/Interfaces/IWebMutableURLRequest.idl: Added.
* COM/Interfaces/IWebNotification.idl: Added.
* COM/Interfaces/IWebPolicyDelegate.idl: Added.
* COM/Interfaces/IWebPreferences.idl: Added.
* COM/Interfaces/IWebResource.idl: Added.
* COM/Interfaces/IWebResourceLoadDelegate.idl: Added.
* COM/Interfaces/IWebScriptObject.idl: Added.
* COM/Interfaces/IWebUIDelegate.idl: Added.
* COM/Interfaces/IWebURLAuthenticationChallenge.idl: Added.
* COM/Interfaces/IWebURLRequest.idl: Added.
* COM/Interfaces/IWebURLResponse.idl: Added.
* COM/Interfaces/IWebUndoManager.idl: Added.
* COM/Interfaces/IWebView.idl: Added.
* COM/Interfaces/WebKit.idl: Added.
* COM/WebBackForwardList.cpp: Added.
(WebBackForwardList::WebBackForwardList):
(WebBackForwardList::~WebBackForwardList):
(WebBackForwardList::createInstance):
(WebBackForwardList::QueryInterface):
(WebBackForwardList::AddRef):
(WebBackForwardList::Release):
(WebBackForwardList::addItem):
(WebBackForwardList::goBack):
(WebBackForwardList::goForward):
(WebBackForwardList::goToItem):
(WebBackForwardList::backItem):
(WebBackForwardList::currentItem):
(WebBackForwardList::forwardItem):
(WebBackForwardList::backListWithLimit):
(WebBackForwardList::forwardListWithLimit):
(WebBackForwardList::capacity):
(WebBackForwardList::setCapacity):
(WebBackForwardList::backListCount):
(WebBackForwardList::forwardListCount):
(WebBackForwardList::containsItem):
(WebBackForwardList::itemAtIndex):
(WebBackForwardList::setPageCacheSize):
(WebBackForwardList::pageCacheSize):
* COM/WebBackForwardList.h: Added.
* COM/WebDataSource.cpp: Added.
(WebDataSource::WebDataSource):
(WebDataSource::~WebDataSource):
(WebDataSource::createInstance):
(WebDataSource::QueryInterface):
(WebDataSource::AddRef):
(WebDataSource::Release):
(WebDataSource::initWithRequest):
(WebDataSource::data):
(WebDataSource::representation):
(WebDataSource::webFrame):
(WebDataSource::initialRequest):
(WebDataSource::request):
(WebDataSource::response):
(WebDataSource::textEncodingName):
(WebDataSource::isLoading):
(WebDataSource::pageTitle):
(WebDataSource::unreachableURL):
(WebDataSource::webArchive):
(WebDataSource::mainResource):
(WebDataSource::subresources):
(WebDataSource::subresourceForURL):
(WebDataSource::addSubresource):
* COM/WebDataSource.h: Added.
* COM/WebFrame.cpp: Added.
(WebFrame::WebFramePrivate::WebFramePrivate):
(WebFrame::WebFramePrivate::~WebFramePrivate):
(WebFrame::WebFrame):
(WebFrame::~WebFrame):
(WebFrame::createInstance):
(WebFrame::QueryInterface):
(WebFrame::AddRef):
(WebFrame::Release):
(WebFrame::initWithName):
(WebFrame::name):
(WebFrame::webView):
(WebFrame::frameView):
(WebFrame::DOMDocument):
(WebFrame::frameElement):
(WebFrame::loadRequest):
(WebFrame::loadData):
(WebFrame::loadHTMLString):
(WebFrame::loadAlternateHTMLString):
(WebFrame::loadArchive):
(WebFrame::dataSource):
(WebFrame::provisionalDataSource):
(WebFrame::stopLoading):
(WebFrame::reload):
(WebFrame::findFrameNamed):
(WebFrame::parentFrame):
(WebFrame::childFrames):
(WebFrame::paint):
(WebFrame::impl):
(WebFrame::loadDataSource):
(WebFrame::loading):
(WebFrame::goToItem):
(WebFrame::loadItem):
(WebSystemMainMemory):
(WebFrame::getObjectCacheSize):
(WebFrame::receivedRedirect):
(WebFrame::receivedResponse):
(WebFrame::receivedData):
(WebFrame::receivedAllData):
(WebFrame::openURL):
(WebFrame::submitForm):
(WebFrame::setTitle):
(WebFrame::setStatusText):
* COM/WebFrame.h: Added.
* COM/WebHistoryItem.cpp: Added.
(WebHistoryItem::WebHistoryItem):
(WebHistoryItem::~WebHistoryItem):
(WebHistoryItem::createInstance):
(WebHistoryItem::QueryInterface):
(WebHistoryItem::AddRef):
(WebHistoryItem::Release):
(WebHistoryItem::initWithURLString):
(WebHistoryItem::originalURLString):
(WebHistoryItem::URLString):
(WebHistoryItem::title):
(WebHistoryItem::lastVisitedTimeInterval):
(WebHistoryItem::setAlternateTitle):
(WebHistoryItem::alternateTitle):
(WebHistoryItem::icon):
* COM/WebHistoryItem.h: Added.
* COM/WebIconDatabase.cpp: Added.
(WebIconDatabase::WebIconDatabase):
(WebIconDatabase::~WebIconDatabase):
(WebIconDatabase::createInstance):
(WebIconDatabase::QueryInterface):
(WebIconDatabase::AddRef):
(WebIconDatabase::Release):
(WebIconDatabase::sharedIconDatabase):
(WebIconDatabase::iconForURL):
(WebIconDatabase::defaultIconWithSize):
(WebIconDatabase::retainIconForURL):
(WebIconDatabase::releaseIconForURL):
(WebIconDatabase::delayDatabaseCleanup):
(WebIconDatabase::allowDatabaseCleanup):
* COM/WebIconDatabase.h: Added.
* COM/WebKitClassFactory.cpp: Added.
(WebKitClassFactory::WebKitClassFactory):
(WebKitClassFactory::~WebKitClassFactory):
(WebKitClassFactory::QueryInterface):
(WebKitClassFactory::AddRef):
(WebKitClassFactory::Release):
(WebKitClassFactory::CreateInstance):
(WebKitClassFactory::LockServer):
* COM/WebKitClassFactory.h: Added.
* COM/WebKitDLL.cpp: Added.
(DllMain):
(DllGetClassObject):
(DllCanUnloadNow):
(DllUnregisterServer):
(DllRegisterServer):
* COM/WebKitDLL.h: Added.
* COM/WebMutableURLRequest.cpp: Added.
(WebMutableURLRequest::WebMutableURLRequest):
(WebMutableURLRequest::~WebMutableURLRequest):
(WebMutableURLRequest::createInstance):
(WebMutableURLRequest::QueryInterface):
(WebMutableURLRequest::AddRef):
(WebMutableURLRequest::Release):
(WebMutableURLRequest::requestWithURL):
(WebMutableURLRequest::allHTTPHeaderFields):
(WebMutableURLRequest::cachePolicy):
(WebMutableURLRequest::HTTPBody):
(WebMutableURLRequest::HTTPBodyStream):
(WebMutableURLRequest::HTTPMethod):
(WebMutableURLRequest::HTTPShouldHandleCookies):
(WebMutableURLRequest::initWithURL):
(WebMutableURLRequest::mainDocumentURL):
(WebMutableURLRequest::timeoutInterval):
(WebMutableURLRequest::URL):
(WebMutableURLRequest::valueForHTTPHeaderField):
(WebMutableURLRequest::addValue):
(WebMutableURLRequest::setAllHTTPHeaderFields):
(WebMutableURLRequest::setCachePolicy):
(WebMutableURLRequest::setHTTPBody):
(WebMutableURLRequest::setHTTPBodyStream):
(WebMutableURLRequest::setHTTPMethod):
(WebMutableURLRequest::setHTTPShouldHandleCookies):
(WebMutableURLRequest::setMainDocumentURL):
(WebMutableURLRequest::setTimeoutInterval):
(WebMutableURLRequest::setURL):
(WebMutableURLRequest::setValue):
(WebMutableURLRequest::setFormData):
(WebMutableURLRequest::formData):
* COM/WebMutableURLRequest.h: Added.
* COM/WebView.cpp: Added.
(WebView::WebView):
(WebView::~WebView):
(WebView::createInstance):
(WebView::mouseMoved):
(WebView::mouseDown):
(WebView::mouseUp):
(WebView::mouseDoubleClick):
(WebView::keyPress):
(registerWebView):
(WebViewWndProc):
(calculateScrollDelta):
(scrollMessageForKey):
(WebView::goToItem):
(WebView::QueryInterface):
(WebView::AddRef):
(WebView::Release):
(WebView::canShowMIMEType):
(WebView::canShowMIMETypeAsHTML):
(WebView::MIMETypesShownAsHTML):
(WebView::setMIMETypesShownAsHTML):
(WebView::URLFromPasteboard):
(WebView::URLTitleFromPasteboard):
(WebView::initWithFrame):
(WebView::setUIDelegate):
(WebView::uiDelegate):
(WebView::setResourceLoadDelegate):
(WebView::resourceLoadDelegate):
(WebView::setDownloadDelegate):
(WebView::downloadDelegate):
(WebView::setFrameLoadDelegate):
(WebView::frameLoadDelegate):
(WebView::setPolicyDelegate):
(WebView::policyDelegate):
(WebView::mainFrame):
(WebView::backForwardList):
(WebView::setMaintainsBackForwardList):
(WebView::goBack):
(WebView::goForward):
(WebView::goToBackForwardItem):
(WebView::setTextSizeMultiplier):
(WebView::textSizeMultiplier):
(WebView::setApplicationNameForUserAgent):
(WebView::applicationNameForUserAgent):
(WebView::setCustomUserAgent):
(WebView::customUserAgent):
(WebView::userAgentForURL):
(WebView::supportsTextEncoding):
(WebView::setCustomTextEncodingName):
(WebView::customTextEncodingName):
(WebView::setMediaStyle):
(WebView::mediaStyle):
(WebView::stringByEvaluatingJavaScriptFromString):
(WebView::windowScriptObject):
(WebView::setPreferences):
(WebView::preferences):
(WebView::setPreferencesIdentifier):
(WebView::preferencesIdentifier):
(WebView::setHostWindow):
(WebView::hostWindow):
(WebView::searchFor):
(WebView::registerViewClass):
(WebView::takeStringURLFrom):
(WebView::stopLoading):
(WebView::reload):
(WebView::canGoBack):
(WebView::canGoForward):
(WebView::canMakeTextLarger):
(WebView::makeTextLarger):
(WebView::canMakeTextSmaller):
(WebView::makeTextSmaller):
(WebView::computedStyleForElement):
(WebView::editableDOMRangeForPoint):
(WebView::setSelectedDOMRange):
(WebView::selectedDOMRange):
(WebView::selectionAffinity):
(WebView::setEditable):
(WebView::isEditable):
(WebView::setTypingStyle):
(WebView::typingStyle):
(WebView::setSmartInsertDeleteEnabled):
(WebView::smartInsertDeleteEnabled):
(WebView::setContinuousSpellCheckingEnabled):
(WebView::isContinuousSpellCheckingEnabled):
(WebView::spellCheckerDocumentTag):
(WebView::undoManager):
(WebView::setEditingDelegate):
(WebView::editingDelegate):
(WebView::styleDeclarationWithText):
(WebView::replaceSelectionWithNode):
(WebView::replaceSelectionWithText):
(WebView::replaceSelectionWithMarkupString):
(WebView::replaceSelectionWithArchive):
(WebView::deleteSelection):
(WebView::applyStyle):
(WebView::copy):
(WebView::cut):
(WebView::paste):
(WebView::copyFont):
(WebView::pasteFont):
(WebView::delete_):
(WebView::pasteAsPlainText):
(WebView::pasteAsRichText):
(WebView::changeFont):
(WebView::changeAttributes):
(WebView::changeDocumentBackgroundColor):
(WebView::changeColor):
(WebView::alignCenter):
(WebView::alignJustified):
(WebView::alignLeft):
(WebView::alignRight):
(WebView::checkSpelling):
(WebView::showGuessPanel):
(WebView::performFindPanelAction):
(WebView::startSpeaking):
(WebView::stopSpeaking):
(WebView::viewWindow):
* COM/WebView.h: Added.
* WebKit.vcproj: Added.
* WebKit.vcproj/Interfaces.vcproj: Added.
* WebKit.vcproj/WebKit.def: Added.
* WebKit.vcproj/WebKit.rc: Added.
* WebKit.vcproj/WebKit.sln: Added.
* WebKit.vcproj/WebKit.vcproj: Added.
* WebKit.vcproj/WebKitGUID.vcproj: Added.
* WebKit.vcproj/autoversion.h: Added.
* WebKit.vcproj/resource.h: Added.
2006-06-02 Darin Adler <darin@apple.com>
* WebCoreSupport/WebImageRendererFactory.m: Fix crash on Safari startup
by include NSObject as a superclass (oops!).
2006-06-01 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- WebCore doesn't need to load WebKit images any more; removed code for that
* Resources/missing_image.tiff: Removed.
* WebCoreSupport/WebImageRendererFactory.h: Removed.
* WebCoreSupport/WebImageRendererFactory.m: Moved @interface in here.
Removed all but the "threaded decoding" calls that older Safari calls.
This file can go altogether when compatibility with that older Safari
is no longer needed.
* WebKit.xcodeproj/project.pbxproj: Removed WebImageRendererFactory.h
and missing_image.tiff.
* WebView/WebFrameView.m: (-[WebFrameView initWithFrame:]): Removed call
to [WebImageRendererFactory createSharedFactory].
2006-06-01 Brady Eidson <beidson@apple.com>
Reviewed by Maciej.
Simple changes to hook up the new WebCore based Icon Database
for testing.
* ChangeLog:
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _applicationWillTerminate:]):
* Misc/WebIconDatabasePrivate.h:
* WebKit.xcodeproj/project.pbxproj:
2006-06-01 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=6309
multiple problems prevent bookmarking/back button technique for AJAX/DHTML applications from working
* Misc/WebNSURLExtras.m:
(-[NSString _webkit_URLFragment]):
Don't include the "#" character in the fragment.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge historyURL:]):
New function, returns the history URL for a given position in the back/forward list
* WebView/WebFrame.m:
(-[WebFrame _loadItem:withLoadType:]):
Always call scrollToAnchorWithURL, even if there is no fragment. This way we keep the WebCore frame's
URL up-to-date.
2006-06-01 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- fixed "REGRESSION: Can't order from Pizza Hut (ToT, 05/24/06)"
http://bugs.webkit.org/show_bug.cgi?id=9103
* WebView/WebDataSource.m:
(-[WebDataSource _willSendRequest:forResource:redirectResponse:]): Set up the
User-Agent header.
* WebView/WebDataSourceInternal.h:
* WebView/WebLoader.m:
(-[NSURLProtocol willSendRequest:redirectResponse:]): Pass a mutable URL request
so the above can work.
2006-06-01 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
* WebView/WebFrameView.m:
(+[WebFrameView _canShowMIMETypeAsHTML:]):
Use _webkit_objectForMIMEType here so we'll get an object back for "text/".
2006-05-31 David Hyatt <hyatt@apple.com>
Make programmatic focus/blur actually work on sub-frames. Make the
top-level UI delegate get called for deactivation of windows.
Reviewed by darin
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge activateWindow]):
(-[WebFrameBridge deactivateWindow]):
(-[WebFrameBridge loadURL:referrer:reload:userGesture:target:triggeringEvent:form:formValues:]):
(-[WebFrameBridge postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
* WebKit.xcodeproj/project.pbxproj:
=== WebKit-521.12 ===
2006-05-26 David Harrison <harrison@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4514529> Add a list type parameter and a return value to _increaseSelectionListLevel
* WebView/WebHTMLView.m:
(-[WebHTMLView _increaseSelectionListLevel]):
- Now returns DOMNode*
(-[WebHTMLView _increaseSelectionListLevelOrdered]):
(-[WebHTMLView _increaseSelectionListLevelUnordered]):
- Added. These also return DOMNode*
* WebView/WebHTMLViewPrivate.h:
- Updated as above
2006-05-25 Tim Omernick <timo@apple.com>
Reviewed by Anders.
<http://bugs.webkit.org/show_bug.cgi?id=8347>
REGRESSION: Flash movie audible but not visible until window is resized
* Plugins/WebNetscapePluginDocumentView.m:
(-[WebNetscapePluginDocumentView dataSourceUpdated:]):
Layout if needed here. Maciej recently removed the "LayoutAcceptable" frame state, which used to
cause plugin document views to lay out immediately upon receiving data. This call to -layout has
the same effect.
=== WebKit-521.11.1 ===
2006-05-25 Timothy Hatcher <timothy@apple.com>
Reviewed by Tim O.
<rdar://problem/4559808> WebKit fails to compile for ppc64
<rdar://problem/4522085> 64-bit: WebKit uses FSSpec which is not available in 64-bit
Gets WebKit building under 64-bit. Rename WebNSInt and WebNSUInt to WebNSInteger and WebNSUInteger.
Start using WebNSInteger where we need to match AppKit API usage of NSInteger.
HIWebView and a couple of helper functions are disabled until they can be moved off of QuickDraw.
<rdar://problem/4561772> HIWebView needs to be reworked to not use QuickDraw, needed for 64-bit
* Carbon/CarbonUtils.m: disabled this file in 64-bit <rdar://problem/4561772>
* Carbon/CarbonWindowAdapter.m:
(-[CarbonWindowAdapter initWithCarbonWindowRef:takingOwnership:disableOrdering:carbon:]):
* Carbon/CarbonWindowFrame.m:
(+[CarbonWindowFrame frameRectForContentRect:styleMask:]):
(+[CarbonWindowFrame contentRectForFrameRect:styleMask:]):
(+[CarbonWindowFrame minFrameSizeForMinContentSize:styleMask:]):
(-[CarbonWindowFrame frameRectForContentRect:styleMask:]):
(-[CarbonWindowFrame contentRectForFrameRect:styleMask:]):
(-[CarbonWindowFrame minFrameSizeForMinContentSize:styleMask:]):
* Carbon/HIViewAdapter.m: disabled this file in 64-bit <rdar://problem/4561772>
* Carbon/HIWebView.m: disabled this file in 64-bit <rdar://problem/4561772>
(HIWebViewEventHandler):
* DefaultDelegates/WebDefaultResourceLoadDelegate.m:
(-[WebDefaultResourceLoadDelegate webView:resource:didReceiveContentLength:fromDataSource:]):
* History/WebBackForwardList.m:
(-[WebBackForwardList removeItem:]):
(-[WebBackForwardList goToItem:]):
* Misc/WebDownload.m:
(-[WebDownloadInternal download:didReceiveDataOfLength:]):
* Misc/WebFileDatabase.m:
(UniqueFilePathForKey):
* Misc/WebIconDatabase.m:
(-[NSMutableDictionary retainIconForURL:]):
(-[NSMutableDictionary releaseIconForURL:]):
(-[WebIconDatabase _totalRetainCountForIconURLString:]):
(-[WebIconDatabase _retainIconForIconURLString:]):
(-[WebIconDatabase _releaseIconForIconURLString:]):
* Misc/WebSearchableTextView.m:
(-[NSString selectionRect]):
* Misc/WebTypesInternal.h: Added.
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream _destroyStream]):
(CarbonPathFromPOSIXPath):
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView sendActivateEvent:]):
(-[WebBaseNetscapePluginView sendUpdateEvent]):
(TSMEventHandler):
(-[WebBaseNetscapePluginView _postURL:target:len:buf:file:notifyData:sendNotification:allowHeaders:]):
(-[WebBaseNetscapePluginView _printedPluginBitmap]):
(-[NSData _web_locationAfterFirstBlankLine]):
* Plugins/WebBasePluginPackage.m:
(-[WebBasePluginPackage hash]):
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage load]):
(functionPointerForTVector):
* WebInspector/WebInspector.m:
(-[WebInspector _updateSystemColors]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSource _didReceiveData:contentLength:forResource:]):
* WebView/WebFrame.m:
(-[WebFrame _sendRemainingDelegateMessagesWithIdentifier:response:length:error:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView drawRect:]):
(-[WebHTMLView characterIndexForPoint:]):
(-[WebHTMLView conversationIdentifier]):
* WebView/WebResourceLoadDelegate.h:
* WebView/WebUIDelegate.h:
* WebView/WebView.h:
* WebView/WebView.m:
(-[WebView _mouseDidMoveOverElement:modifierFlags:]):
(-[WebView spellCheckerDocumentTag]):
* WebView/WebViewInternal.h:
* WebView/WebViewPrivate.h:
=== WebKit-521.11 ===
2006-05-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Tim.
- more loader refactoring to simplify things and remove knowledge of WebView from WebSubresourceLoader
* WebCoreSupport/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forDataSource:]):
(-[WebSubresourceLoader didReceiveResponse:]):
* WebView/WebDataSource.m:
(-[WebDataSource _loadIcon]):
(-[WebDataSource _startLoading]):
* WebView/WebFrame.m:
(-[WebFrame _loadRequest:archive:]):
(-[WebFrame _loadItem:withLoadType:]):
(-[WebFrame _loadURL:referrer:loadType:target:triggeringEvent:form:formValues:]):
(-[WebFrame _postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrame _addExtraFieldsToRequest:mainResource:alwaysFromRequest:]):
* WebView/WebFrameInternal.h:
* WebView/WebFramePrivate.h:
* WebView/WebLoader.h:
* WebView/WebLoader.m:
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader initWithDataSource:]):
(-[WebMainResourceLoader didReceiveResponse:]):
2006-05-23 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4558301> REGRESSION (420+): After clearing history and closing bookmark view window,
attempting to select Safari's menu bar results in a crash
* Misc/WebNSWindowExtras.m:
(replacementPostWindowNeedsDisplay):
My fix yesterday for 4557117 was not quite good enough. Now that we cancel the display timer for a
window *before* it deallocates, we need to make sure that while a window deallocates, no new display
timers are scheduled for that window. This is actually possible, as 4558301 demonstrates.
Luckily, NSWindow sets a handy "windowDying" flag when it deallocates, so we can just check that flag
and bail out of the throttle hack if it is set. This should fix the last of the crashes involving
display timers scheduled for deallocated or deallocating windows.
2006-05-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
- remove knowledge of WebView from WebLoader in preparation for moving the code down
* WebView/WebDataSource.m:
(-[WebDataSource _defersCallbacks]):
(-[WebDataSource _identifierForInitialRequest:]):
(-[WebDataSource _willSendRequest:forResource:redirectResponse:]):
(-[WebDataSource _didReceiveAuthenticationChallenge:forResource:]):
(-[WebDataSource _didCancelAuthenticationChallenge:forResource:]):
(-[WebDataSource _didReceiveResponse:forResource:]):
(-[WebDataSource _didReceiveData:contentLength:forResource:]):
(-[WebDataSource _didFinishLoadingForResource:]):
(-[WebDataSource _didFailLoadingWithError:forResource:]):
(-[WebDataSource _downloadWithLoadingConnection:request:response:proxy:]):
(-[WebDataSource _privateBrowsingEnabled]):
* WebView/WebDataSourceInternal.h:
* WebView/WebLoader.h:
* WebView/WebLoader.m:
(-[WebLoader releaseResources]):
(-[WebLoader setDataSource:]):
(-[WebLoader willSendRequest:redirectResponse:]):
(-[WebLoader didReceiveAuthenticationChallenge:]):
(-[WebLoader didCancelAuthenticationChallenge:]):
(-[WebLoader didReceiveResponse:]):
(-[WebLoader didReceiveData:lengthReceived:]):
(-[WebLoader signalFinish]):
(-[WebLoader didFinishLoading]):
(-[WebLoader didFailWithError:]):
(-[WebLoader willCacheResponse:]):
(-[WebLoader cancelWithError:]):
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader continueAfterContentPolicy:response:]):
* WebView/WebView.m:
(-[WebView _incrementProgressForIdentifier:response:]):
(-[WebView _incrementProgressForIdentifier:data:]):
(-[WebView _completeProgressForIdentifier:]):
* WebView/WebViewInternal.h:
=== WebKit-521.10 ===
2006-05-22 Tim Omernick <timo@apple.com>
Reviewed by Geoff.
<rdar://problem/4557117> TOT REGRESSION: Repro crash in cancelPendingWindowDisplay --> _timerRelease when
opening file from file open dialog
Note that I could not reproduce this situation at all on any of my machines; I had to debug this on Geoff's
machine.
* Misc/WebNSWindowExtras.m:
(replacementDealloc):
Cancel display timer before dealloc, not after. Cancelling the timer can cause a message to be sent to the
window; best to do that before the window deallocates.
(replacementFinalize):
ditto
2006-05-20 Maciej Stachowiak <mjs@apple.com>
Reviewed by Beth.
- fix assertion failure on layout tests
* WebView/WebDataSource.m:
(-[WebDataSource _mainReceivedError:complete:]): Don't do anything
if this data source is no longer connected to a frame. Used to be
this couldn't happen because the WebView would have been nil, but
we no longer go through the WebView.
2006-05-20 Timothy Hatcher <timothy@apple.com>
Reviewed by Anders.
Bug 9018: REGRESSION: resizing the top area of the inspector does not grow as expected
http://bugs.webkit.org/show_bug.cgi?id=9018
Use clientHeight now that offsetHeight includes the border and padding.
clientHeight should have been used initially.
* WebInspector/WebInspector.m:
(-[WebInspector resizeTopArea]):
2006-05-18 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
- remove loading-related code from WebView
http://bugs.webkit.org/show_bug.cgi?id=8981
* Plugins/WebNetscapePluginStream.m:
(-[WebNetscapePlugInStreamLoader didFinishLoading]):
(-[WebNetscapePlugInStreamLoader didFailWithError:]):
* WebCoreSupport/WebSubresourceLoader.m:
(-[WebSubresourceLoader receivedError:]):
(-[WebSubresourceLoader signalFinish]):
* WebView/WebDataSource.m:
(-[WebDataSource _stopLoading]):
(-[WebDataSource _receivedMainResourceError:complete:]):
(-[WebDataSource _finishedLoadingResource]):
(-[WebDataSource _mainReceivedBytesSoFar:complete:]):
(-[WebDataSource _receivedError:]):
(-[WebDataSource _mainReceivedError:complete:]):
* WebView/WebDataSourceInternal.h:
* WebView/WebFrame.m:
(-[WebFrame _sendRemainingDelegateMessagesWithIdentifier:response:length:error:]):
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader didReceiveData:lengthReceived:]):
(-[WebMainResourceLoader didFinishLoading]):
* WebView/WebView.m:
* WebView/WebViewInternal.h:
2006-05-18 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4551938> More options needed for window display throttle
We decided to play it safe and leave our window flushing behavior unchanged from the previous
public release. By default, CoreGraphics deferred updates are once again OFF, and the window
display throttle is OFF.
Individual applications should set the WebKitThrottleWindowDisplayPreferenceKey and
WebKitEnableDeferredUpdatesPreferenceKey defaults to suit their needs.
Old behavior (like 10.4.6): WebKitThrottleWindowDisplayPreferenceKey=0 (or unset),
WebKitEnableDeferredUpdatesPreferenceKey (or unset).
Tear-free scrolling/animations: WebKitThrottleWindowDisplayPreferenceKey=0 (or unset),
WebKitEnableDeferredUpdatesPreferenceKey=1. While this configuration fixes the tearing issues
caused by over-flushing, some applications will experience performance problems as over-flushing
with CG deferred updates enabled will cause the app to block.
Tear-free scrolling/animations, high performance: WebKitThrottleWindowDisplayPreferenceKey=1,
WebKitEnableDeferredUpdatesPreferenceKey=1. This is the riskiest configuration in that it
enables the window display throttle "feature", potentially breaking applications' assumptions
about when displays occur. However, it provides the "best of both worlds", in that updates
are tear-free, and performance impact should me minimal.
* WebView/WebPreferenceKeysPrivate.h:
Declared WebKitThrottleWindowDisplayPreferenceKey and WebKitEnableDeferredUpdatesPreferenceKey.
* WebView/WebFrameView.m:
(-[WebFrameView initWithFrame:]):
Turn off CG deferred updates if WebKitEnableDeferredUpdatesPreferenceKey is NO or has no value.
Added some comments.
2006-05-18 John Sullivan <sullivan@apple.com>
Reviewed by Darin Adler.
- fixed <rdar://problem/4552713> REGRESSION: WebFrameView no longer responds to responder methods sent by Safari code
* WebView/WebView.m:
(-[WebView _responderForResponderOperations]):
Treat sibling views of the main frameView the same as views outside of the webview for the purposes of this mechanism.
2006-05-18 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4553450> Make disabling window throttle safer
* Misc/WebNSWindowExtras.m:
(+[NSWindow _webkit_enableWindowDisplayThrottle]):
Don't assume that +_webkit_disableWindowDisplayThrottle restored the NSWindow method implementations;
now we'll only swizzle them once, and our replacement IMPs will call the old IMPs when the window
throttle is disabled. This is a safer approach when other components/"haxies" override the same methods
that we are overriding, as it allows the overrides to "chain" properly.
Moved the dictionary initialization code down a bit. The order doesn't matter here.
(disableWindowDisplayThrottleApplierFunction):
Noticed that this could have been written safer with respect to the timer having the last reference to
the window. I never experienced a crash here, but this code is definitely safer.
(+[NSWindow _webkit_disableWindowDisplayThrottle]):
Don't restore NSWindow method implementations; just clear the flag, flush pending displays, and destroy
the dictionary.
(replacementPostWindowNeedsDisplay):
If throttling is disabled, just call the original IMP.
(clearWindowDisplayInfo):
Added an assert.
(replacementDealloc):
Don't call clearWindowDisplayInfo() when throttling is disabled.
(replacementFinalize):
ditto
(cancelPendingWindowDisplay):
Removed an unnecessary assertion.
2006-05-17 Tim Omernick <timo@apple.com>
Reviewed by Kevin Decker and John Sullivan.
<rdar://problem/4550801> REGRESSION: Window throttle code can sometimes leak NSWindows
The window display throttle depended on windows being closed before they were deallocated; this is
not guaranteed by AppKit. Windows that were being released without being closed were getting stuck
in our NSWindow -> WindowDisplayInfo dictionary.
* Misc/WebNSWindowExtras.m:
(+[NSWindow _webkit_enableWindowDisplayThrottle]):
Don't retain the NSWindow keys in the window display info dictionary.
Instead of overriding -close, override -dealloc and -finalize so that we can remove the NSWindow ->
WindowDisplayInfo mapping when a window deallocates.
(+[NSWindow _webkit_disableWindowDisplayThrottle]):
Restore -dealloc and -finalize.
(clearWindowDisplayInfo):
Factored the WindowDisplayInfo cleanup code out of the now-defunct replacementClose().
(replacementClose):
Removed; no longer needed.
(replacementDealloc):
Clear the WindowDisplayInfo for the window after deallocation.
(replacementFinalize):
ditto
(-[NSWindow _webkit_doPendingPostWindowNeedsDisplay:]):
Rewrote this method to be safe in the case where the firing display timer has the last reference to the
window.
Added comments.
2006-05-17 bradeeoh <beidson@apple.com>
Reviewed by Tim Hatcher
Consolidated WebDatabase base class into WebFileDatabase as the inheritance relationship became
obsolete. This improves readability and sets the stage for a further in-depth rewrite of the
WebIcon* code.
* Misc/WebDatabase.h: Removed.
* Misc/WebDatabase.m: Removed.
* Misc/WebFileDatabase.h:
* Misc/WebFileDatabase.m:
(-[WebFileDatabaseOp dealloc]):
(-[WebFileDatabase dealloc]):
(-[WebFileDatabase path]):
(-[WebFileDatabase isOpen]):
(-[WebFileDatabase sizeLimit]):
* WebKit.xcodeproj/project.pbxproj:
2006-05-17 Adele Peterson <adele@apple.com>
Reviewed by Hyatt.
WebKit part of initial checkin to prepare for http://bugs.webkit.org/show_bug.cgi?id=8948
Switch to use new text field implementation for <textarea>
* WebView/WebHTMLView.m:
(-[WebHTMLView insertNewline:]): If we're in plain text mode, insert a line break instead of a paragraph separator.
(-[WebHTMLView insertParagraphSeparator:]): ditto.
* WebView/WebView.m: (-[WebView _menuForElement:defaultItems:]):
Checks for textareas as well as textfields before allowing the delegate to control
the context menu. This won't affect the old textareas because AppKit handles those context menus.
2006-05-17 John Sullivan <sullivan@apple.com>
Reviewed by Maciej.
First step towards making text-matching mechanism more flexible; updated for changes
to WebCoreFrameBridge calls.
* WebView/WebHTMLView.m:
(-[WebHTMLView highlightAllMatchesForString:caseSensitive:]):
updated for name change in WebCoreFrameBridge, also now calls setMarkedTextMatchesAreHighlighted:
(-[WebHTMLView clearHighlightedMatches]):
updated for name change in WebCoreFrameBridge
2006-05-16 Matt Gough <matt@softchaos.com>
Reviewed by Geoff.
Ensured all the public headers have a newline at their end.
Client code can now have 'Missing Newline at end of File' warnings enabled without emitting
such warnings against any WebKit includes.
* Misc/WebDownload.h:
* Plugins/npfunctions.h:
* WebView/WebResourceLoadDelegate.h:
* WebView/WebUIDelegate.h:
* WebView/WebView.h:
2006-05-16 Tim Omernick <timo@apple.com>
Reviewed by Tim Hatcher.
http://bugs.webkit.org/show_bug.cgi?id=8945 (REGRESSION: Scrolling is very slow when dragging
the thumb)
Rolled out one of my tweaks to the window display throttle hack (remember the last flush time instead
of the last display time). While that was technically a better approach, we discovered a problem
with how it interacts with NSView scroll tracking. Rather than further complicate this already
crazy hack, I'm reverting back to the simple version. This should yield similar numbers on iBench,
but not exhibit the nasty scrolling problem.
* Misc/WebNSWindowExtras.m:
(+[NSWindow _webkit_enableWindowDisplayThrottle]):
(+[NSWindow _webkit_disableWindowDisplayThrottle]):
(getWindowDisplayInfo):
(requestWindowDisplay):
2006-05-16 bradeeoh <beidson@apple.com>
Reviewed by Maciej Stachowiak
- Fixed an old deprecated method in Misc/WebFileDatabase.m
* Misc/WebFileDatabase.m:
(UniqueFilePathForKey): changed `lossyCString` to `UTF8String`
2006-05-16 Darin Adler <darin@apple.com>
Reviewed by Anders.
- did the name change from "ImageElement" to "ImageForElement" that I said I would
(oops!)
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate copyImageToClipboard:]):
* Misc/WebNSPasteboardExtras.h:
* Misc/WebNSPasteboardExtras.m:
(-[NSPasteboard _web_declareAndWriteDragImageForElement:URL:title:archive:source:]):
* Misc/WebNSViewExtras.h:
* Misc/WebNSViewExtras.m:
(-[NSView _web_DragImageForElement:rect:event:pasteboard:source:offset:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
* WebView/WebView.m:
(-[WebView _writeImageForElement:withPasteboardTypes:toPasteboard:]):
(-[WebView writeElement:withPasteboardTypes:toPasteboard:]):
* WebView/WebViewInternal.h:
2006-05-16 Darin Adler <darin@apple.com>
Reviewed by Anders.
- http://bugs.webkit.org/show_bug.cgi?id=8940
remove extra copy of image code
* English.lproj/StringsNotToBeLocalized.txt: Updated for many recent changes.
* WebKit.xcodeproj/project.pbxproj: Removed files.
* WebCoreSupport/WebImageData.h: Removed.
* WebCoreSupport/WebImageData.m: Removed.
* WebCoreSupport/WebImageDecodeItem.h: Removed.
* WebCoreSupport/WebImageDecodeItem.m: Removed.
* WebCoreSupport/WebImageDecoder.h: Removed.
* WebCoreSupport/WebImageDecoder.m: Removed.
* WebCoreSupport/WebImageRenderer.h: Removed.
* WebCoreSupport/WebImageRenderer.m: Removed.
* WebCoreSupport/WebImageRendererFactory.h:
* WebCoreSupport/WebImageRendererFactory.m: Removed everything except for
shouldUseThreadedDecoding, setShouldUseThreadedDecoding, and imageDataForName:.
* Misc/WebNSPasteboardExtras.h: Removed WebImageRenderer parameter from
_web_declareAndWriteDragImage and renamed _web_declareAndWriteDragImageElement.
* Misc/WebNSPasteboardExtras.m:
(-[NSPasteboard _web_writeImage:element:URL:title:archive:types:]): Changed to
call +[WebFrameBridge supportedImageResourceMIMETypes] instead of
-[WebImageRendererFactory supportedMIMETypes].
(-[NSPasteboard _web_declareAndWriteDragImageElement:URL:title:archive:source:]):
Removed WebImageRenderer parameter, and updated code since it was always nil.
* Misc/WebNSViewExtras.h: Removed WebImageRenderer parameter from
_web_dragImage and renamed _web_dragImageElement.
* Misc/WebNSViewExtras.m:
(-[NSView _web_dragImageElement:rect:event:pasteboard:source:offset:]):
Removed WebImageRenderer parameter, and updated code since it was always nil.
* WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Added some new
functions now used by WebCore.
* WebView/WebDataSource.m: (-[WebDataSource _documentFragmentWithArchive:]):
Call +[WebFrameBridge supportedImageResourceMIMETypes] instead of
-[WebImageRendererFactory supportedMIMETypes].
* WebView/WebFrameView.m: Removed include of WebImageRenderer.h.
* WebView/WebHTMLRepresentation.m: (+[WebHTMLRepresentation supportedImageMIMETypes]):
Removed call to +[WebImageRendererFactory createSharedFactory].
* WebView/WebHTMLView.m:
(-[WebHTMLView _imageExistsAtPaths:]): Call +[WebFrameBridge supportedImageResourceMIMETypes]
instead of -[WebImageRendererFactory supportedMIMETypes].
(-[WebHTMLView _documentFragmentWithPaths:]): Ditto.
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]): Update
to no longer pass nil for an image to _web_declareAndWriteDragImageElement and to
_web_dragImageElement.
(-[WebHTMLView dealloc]): Remove call to now-unneeded _reset.
(-[WebHTMLView finalize]): Ditto.
(-[WebHTMLView viewDidMoveToWindow]): Remove logic for calling _reset, including the inWindow
boolean field.
* WebView/WebHTMLViewInternal.h: Removed inWindow boolean.
* WebView/WebHTMLViewPrivate.h: Removed _reset method.
2006-05-16 Darin Adler <darin@apple.com>
Reviewed by Hyatt.
- fix http://bugs.webkit.org/show_bug.cgi?id=8898
REGRESSION: Attempting to right-click image in own tab on website causes crash
- fix http://bugs.webkit.org/show_bug.cgi?id=8919
REGRESSION: image could not be dragged, subsequent click-drag activity caused crash
These fixes may become obsolete when Anders lands his standalone image viewer
patch, but in my tree they are needed to make Copy Image work after the fix
over on the WebCore side to avoid the crashes.
* Misc/WebNSPasteboardExtras.h: Change _web_writeImage parameter to an NSImage.
* Misc/WebNSPasteboardExtras.m:
(-[NSPasteboard _web_writeImage:element:URL:title:archive:types:]): Change parameter
to an NSImage instead of a WebImageRenderer.
(-[NSPasteboard _web_declareAndWriteDragImage:element:URL:title:archive:source:]):
Call -[WebImageRenderer image] to get an NSImage to pass to _web_writeImage.
* WebView/WebView.m: (-[WebView _writeImageElement:withPasteboardTypes:toPasteboard:]):
Get the image using WebElementImageKey if WebElementDOMNodeKey is nil.
2006-05-16 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
http://bugs.webkit.org/show_bug.cgi?id=8921
Use WebCore to render full-frame images
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge determineObjectFromMIMEType:URL:]):
Remove WebImageView handling.
(-[WebFrameBridge mainResourceURLResponse]):
New function which returns the URL response for the main resource. This is used by the
manual loading of images.
(-[WebFrameBridge imageTitleForFilename:size:]):
New function which returns a correctly translated image title given a filename and a size.
* WebCoreSupport/WebImageRenderer.m:
(-[WebImageRenderer _startOrContinueAnimationIfNecessary]):
Remove WebImageView handling.
* WebKit.xcodeproj/project.pbxproj:
Remove WebImageRepresentation and WebImageView.
* WebView/WebArchiver.h:
* WebView/WebArchiver.m:
(+[WebArchiver archiveMainResourceForFrame:]):
New functions which returns a WebArchive with just the main resource, ignoring any subresources.
* WebView/WebDataSource.m:
(+[WebDataSource _repTypesAllowImageTypeOmission:]):
Use MIME types from WebHTMLRepresentation instead of WebImageRepresentation.
* WebView/WebFrameView.m:
(+[WebFrameView _viewTypesAllowImageTypeOmission:]):
Use MIME types from WebHTMLRepresentation instead of WebImageRepresentation.
(+[WebHTMLRepresentation supportedMIMETypes]):
Create an array of image and non-image MIME Types.
(+[WebHTMLRepresentation supportedNonImageMIMETypes]):
(+[WebHTMLRepresentation supportedImageMIMETypes]):
New functions, separating the list of MIME types into image and non-image ones.
* WebView/WebHTMLView.m:
(+[WebHTMLView supportedImageMIMETypes]):
(+[WebHTMLView supportedNonImageMIMETypes]):
New functions which call down to WebHTMLRepresentation.
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
If the image element comes from an ImageDocument, just use an archive of the main resource
instead of the generated HTML document.
* WebView/WebHTMLViewPrivate.h:
Declare new functions.
* WebView/WebImageRepresentation.h: Removed.
* WebView/WebImageRepresentation.m: Removed.
* WebView/WebImageView.h: Removed.
* WebView/WebImageView.m: Removed.
2006-05-15 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
Part of <rdar://problem/4466508> Add 64-bit support to the Netscape Plugin API
Added to the Netscape Plugin API the concept of "plugin drawing models". The drawing model
determines the kind of graphics context created by the browser for the plugin, as well as
the Mac types of various Netscape Plugin API data structures.
There is a drawing model to represent the old QuickDraw-based API. It is used by default
if QuickDraw is available on the system, unless the plugin specifies another drawing model.
The big change is the addition of the CoreGraphics drawing model. A plugin may request this
drawing model to obtain access to a CGContextRef for drawing, instead of a QuickDraw CGrafPtr.
* Plugins/WebBaseNetscapePluginView.h:
Added PluginPort union, which wraps a NP_Port and a NP_CGContext. This is to make access to
the nPort and lastSetPort ivars more convenient now that the port type differs based on the
drawing model.
Changed types of nPort and lastSetPort to PluginPort so they can be used with any drawing model.
Added drawingModel ivar.
* Plugins/WebBaseNetscapePluginView.m:
Renamed PortState to PortState_QD. PortState is now an opaque pointer. PortState_QD cannot be
used if QuickDraw is unavailable.
(-[WebBaseNetscapePluginView fixWindowPort]):
Cannot be used if QuickDraw is unavailable.
(-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
Only fix window port if drawing model is QuickDraw.
Re-ordered some code so I could group QuickDraw-specific stuff into switch and if blocks (that's
why the diff here is so terrible).
Now returns a malloc()'ed PortState that the caller is responsible for freeing. Renamed to
better reflect this behavior.
Support for the CoreGraphics drawing model -- fill PortState_CG struct, save CGContext state.
(-[WebBaseNetscapePluginView restorePortState:]):
Switch based on drawing model.
Support for the CoreGraphics drawing model -- restore CGContext state saved earlier.
(-[WebBaseNetscapePluginView sendEvent:]):
Formatting.
Don't set save/set port state or set the window in CoreGraphics mode unless the event being
sent is an updateEvt. We can't provide the plugin with a CGContext outside of our view display
cycle.
Don't restore PortState if it's NULL (didn't used to be a pointer). Free when we're done with it.
(-[WebBaseNetscapePluginView isNewWindowEqualToOldWindow]):
Formatting.
Switch how we compare ports based on the drawing model.
(-[WebBaseNetscapePluginView updateAndSetWindow]):
Fixed for CoreGraphics by triggering a redisplay instead of sending an update event to the plugin
outside of the view display cycle.
Don't restore PortState if it's NULL (didn't used to be a pointer). Free when we're done with it.
(-[WebBaseNetscapePluginView setWindowIfNecessary]):
Assert that the window is only set when updating in CoreGraphics mode.
Log differently depending on the drawing model.
(-[WebBaseNetscapePluginView start]):
Fall back on QuickDraw if the plugin does not specify a drawing model.
(-[WebBaseNetscapePluginView tellQuickTimeToChill]):
Cannot be used if QuickDraw is unavailable.
(-[WebBaseNetscapePluginView viewWillMoveToWindow:]):
Only call -tellQuickTimeToChill in QuickDraw mode.
(-[WebBaseNetscapePluginView viewHasMoved:]):
ditto
(-[WebBaseNetscapePluginView invalidateRegion:]):
NPRegion is a CGPathRef in CoreGraphics mode.
(-[WebBaseNetscapePluginView getVariable:value:]):
Added support for retriveing the NPNVpluginDrawingModel, NPNVsupportsQuickDrawBool, and
NPNVsupportsCoreGraphicsBool browser variables.
(-[WebBaseNetscapePluginView setVariable:value:]):
Added support for setting the NPNVpluginDrawingModel variable.
2006-05-15 Tim Omernick <timo@apple.com>
Reviewed by Kevin Decker.
Follow-up to my previous PLT fix. I found upon further testing (by dramatically decreasing the
allowed display rate) that +_webkit_displayThrottledWindows did not always force a display when
necessary. The reason is that I was not giving a proper timeout to CFRunLoopRunInMode(). I was
passing 0, which was causing only "expired" timers to fire. This method is actually supposed to
block until all currently scheduled display timers fire.
I tested this change and found that it did not affect my PLT times when the display rate was
capped to 60 fps. It also behaves as expected when the display rate is set much lower (say, 1
display per second); my previous fix did not work well at such display rates.
* Misc/WebNSWindowExtras.m:
(+[NSWindow _webkit_displayThrottledWindows]):
Run the runloop for an amount of time equal to the minimum allowed interval between displays.
This ensures that we'll block until all currently scheduled display timers fire (but we won't
block for future display timers).
2006-05-15 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
- followup to previous fix; I hadn't tested quitting adequately
* WebView/WebHTMLView.m:
(-[WebHTMLView dealloc]):
call removeAllToolTips before clearing _private so that removeTrackingRect: override can work
properly. Normally removeAllToolTips would be called by super, but that's too late.
(-[WebHTMLView finalize]):
ditto
2006-05-15 John Sullivan <sullivan@apple.com>
Reviewed by Darin.
- fixed <rdar://problem/4503016> TOT assertion failure in -[WebHTMLView(WebPrivate) removeTrackingRect:]
We have some tricky code to deal with tracking rects, which succumbed to a fix in AppKit. Updated our
tricky code to work with the AppKit fix.
* WebView/WebHTMLViewInternal.h:
new instance variable lastToolTipTag
* WebView/WebHTMLView.m:
(-[WebHTMLView removeTrackingRect:]):
handle removing lastToolTipTag by calling super
(-[WebHTMLView _setToolTip:]):
save tool tip tag in lastToolTipTag; this apparently used to always return 0, so we formerly had no way
to distinguish it from the no-tool-tips-yet case.
* WebKit.xcodeproj/project.pbxproj:
Xcode removed some old cruft
2006-05-15 Tim Omernick <timo@apple.com>
Reviewed by Darin.
Safari's Page Load Test (PLT) saturates the runloop with so many sources that timers are not allowed to fire
as frequently as they should. This is a general problem with the PLT -- because of this, it does not measure
work done in timer callbacks during/after the page load process.
Unfortunately, this aspect of the PLT interferes with our window display throttle hack. Because we throttle
display using timers, and the PLT starves timers, most of the pages loaded by the PLT do not actually display.
This makes the PLT run "too fast", yielding ridiculously fast numbers compared to when throttling is disabled.
I've added a new method that the PLT can call after each page load to force any starved display throttle timers
to fire. By doing this, Safari's PLT will be guaranteed to display each page at least once.
* Misc/WebNSWindowExtras.h:
* Misc/WebNSWindowExtras.m:
Added a special internal runloop mode for the throttle timers.
(+[NSWindow _webkit_displayThrottledWindows]):
Run the runloop in our special internal mode until there are no more sources to handle.
(requestWindowDisplay):
Schedule the timer in the new mode as well as the standard modes.
2006-05-15 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
http://bugs.webkit.org/show_bug.cgi?id=8913
REGRESSION: Can view source for text files
* WebView/WebDocumentPrivate.h:
Add canSaveAsWebArchive.
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation canProvideDocumentSource]):
Call the bridge.
(-[WebHTMLRepresentation canSaveAsWebArchive]):
New function. This will be used in Safari ToT to determine if a page can be saved as an archive.
2006-05-14 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=8739
Crash in RenderTableSection::paint due to manipulating DOM on resize
Manual test: manual-tests/dom-manipulation-on-resize.html
* WebView/WebHTMLView.m:
(-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]): Relayout if necessary
after sending the resize event.
2006-05-12 Maciej Stachowiak <mjs@apple.com>
Reviewed by Brady.
http://bugs.webkit.org/show_bug.cgi?id=8876
- move most private WebDataSource methods to uninstalled header
I put the declarations for the ones only used in WebKit in WebDataSourceInternal.h
and removed two entirey unused ones.
* Plugins/WebNetscapePluginRepresentation.m:
* Plugins/WebNetscapePluginStream.m:
* Plugins/WebPluginController.m:
* Plugins/WebPluginDocumentView.m:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge dataSource]):
* WebCoreSupport/WebSubresourceLoader.m:
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSource _updateIconDatabaseWithURL:]):
(-[WebDataSource _loadIcon]):
(-[WebDataSource _clearErrors]):
(-[WebDataSource _commitLoadWithData:]):
(-[WebDataSource _doesProgressiveLoadWithMIMEType:]):
(-[WebDataSource _addResponse:]):
* WebView/WebDataSourceInternal.h: Added.
* WebView/WebDataSourcePrivate.h:
* WebView/WebFrame.m:
* WebView/WebHTMLRepresentation.m:
* WebView/WebHTMLView.m:
* WebView/WebImageView.m:
* WebView/WebLoader.m:
* WebView/WebMainResourceLoader.m:
* WebView/WebPDFView.m:
* WebView/WebRenderNode.m:
* WebView/WebView.m:
2006-05-12 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4542808> REGRESSION: benchjs test 1 has slowed by over 150% (8740)
<http://bugs.webkit.org/show_bug.cgi?id=8740>
Improvement to my NSWindow display throttle hack. Remember the last flush time instead of the last display time.
Our goal is to never draw less than 1/60th of a second after the window is flushed in order to avoid blocking on
a CG coalesced update. Using the last display time is close, but this is much more accurate. I have verified that
this further improves our score on BenchJS Test 1 (by 9.8% with the status bar shown compared to the previous build),
as well as on our internal PLT scores by a smaller percentage.
* Misc/WebNSWindowExtras.m:
Renamed lastDisplayTime to lastFlushTime.
(+[NSWindow _webkit_enableWindowDisplayThrottle]):
Replace -[NSWindow flushWindow] with our own implementation.
(+[NSWindow _webkit_disableWindowDisplayThrottle]):
Restore -[NSWindow flushWindow].
(replacementFlushWindow):
Use the last flush time instead of the last display time.
(getWindowDisplayInfo):
Renamed lastDisplayTime to lastFlushTime.
(requestWindowDisplay):
Moved some code to replacementFlushWindow().
2006-05-11 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
Bug 8856: Web Inspector should show the Xpath for the selected node
http://bugs.webkit.org/show_bug.cgi?id=8856
Adds an Xpath area to the Node panel.
* WebInspector/webInspector/inspector.css:
* WebInspector/webInspector/inspector.html:
* WebInspector/webInspector/inspector.js:
2006-05-11 Timothy Hatcher <timothy@apple.com>
Reviewed by Anders.
Fixes <rdar://problem/4411845> lots of SPOD trying to scroll through
Markup & Content inspecting body at apple.com (6614)
http://bugs.webkit.org/show_bug.cgi?id=6614
Removed the Markup & Content pane when viewing a element.
This pane was not that useful and made the inspector really slow
when the markup was large. Only show this pane for text nodes.
* WebInspector/webInspector/inspector.css: use -webkit prefix
* WebInspector/webInspector/inspector.html:
* WebInspector/webInspector/inspector.js:
2006-05-11 Sam Weinig <sam.weinig@gmail.com>
Reviewed by Timothy.
Patch for <http://bugs.webkit.org/show_bug.cgi?id=8810>
Bug 8810: Scrollbars in WebInspector rendered incorrectly
* WebInspector/webInspector/inspector.css:
Make scroll bars absolutely positioned.
2006-05-10 Tim Omernick <timo@apple.com>
Reviewed by Darin.
<rdar://problem/4542808> REGRESSION: benchjs test 1 has slowed by over 150% (8740)
<http://bugs.webkit.org/show_bug.cgi?id=8740>
* Misc/WebNSWindowExtras.h:
* Misc/WebNSWindowExtras.m:
(+[NSWindow _webkit_enableWindowDisplayThrottle]):
Overrides certain NSWindow methods so that window autodisplay can be throttled to 60Hz.
(disableWindowDisplayThrottleApplierFunction):
CFDictionary applier function for when the throttle is disabled. Cancels all pending window displays,
and calls -displayIfNeeded on each window with a pending display.
(+[NSWindow _webkit_disableWindowDisplayThrottle]):
Restores default NSWindow method implementations and clears pending window displays.
(swizzleInstanceMethod):
Helper function to swizzle ObjC method implementations.
(replacementPostWindowNeedsDisplay):
Don't call into -[NSWindow _postWindowNeedsDisplay] if requestWindowDisplay() returns NO (this is the
function that throttles display).
(replacementClose):
Clean up the WindowDisplayInfo struct for the window, since it's about to go away.
(getWindowDisplayInfo):
Gets the WindowDisplayInfo struct for the window, or creates it if absent.
(requestWindowDisplay):
Returns YES if a display is allowed right now. Returns NO otherwise, and schedules a timer to try the
display again.
(cancelPendingWindowDisplay):
Cancels the pending display for the window, if any.
(-[NSWindow _webkit_doPendingPostWindowNeedsDisplay:]):
Try to call _postWindowNeedsDisplay again.
* WebView/WebFrameView.m:
(-[WebFrameView initWithFrame:]):
If the secret "WebKitThrottleWindowDisplay" default is set, then enable the NSWindow throttle.
2006-05-10 Anders Carlsson <acarlsson@apple.com>
Reviewed by Maciej.
* WebView/WebHTMLView.m:
(+[WebHTMLView unsupportedTextMIMETypes]):
Add text/rtf
2006-05-09 Levi Weintraub <lweintraub@apple.com>
Reviewed by justin.
<rdar://problem/4442395>
Tiny MCE: Link isn't inserted after dragging into textarea field
* WebView/WebHTMLView.m:
(-[WebHTMLView _documentFragmentFromPasteboard:allowPlainText:chosePlainText:]):
Modified to create an anchor object with a title as opposed to just the URL as text.
2006-05-09 Tim Omernick <timo@apple.com>
Reviewed by Dave Harrison.
<rdar://problem/4523432> safari crashed right after disabling "block pop up windows" (or
other WebPreferences changes)
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView viewWillMoveToHostWindow:]):
When the plugin view is removed from both its window and its hostWindow, stop observing
WebPreferences.
2006-05-09 Anders Carlsson <acarlsson@apple.com>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=8808
WebCore should handle text files
* WebKit.exp:
Remove WebTextView.
* WebKit.xcodeproj/project.pbxproj:
Get rid of WebTextView and WebTextRepresentation.
* WebView/WebDataSource.m:
(+[WebDataSource _repTypesAllowImageTypeOmission:]):
* WebView/WebFrameView.m:
(+[WebFrameView _viewTypesAllowImageTypeOmission:]):
* WebView/WebHTMLView.m:
The text MIME types are now handled by WebHTMLView.
(+[WebHTMLView unsupportedTextMIMETypes]):
New function, moved here from WebTextView.
* WebView/WebHTMLViewPrivate.h:
* WebView/WebTextRepresentation.h: Removed.
* WebView/WebTextRepresentation.m: Removed.
* WebView/WebTextView.h: Removed.
* WebView/WebTextView.m: Removed.
* WebView/WebView.m:
(+[WebView _viewClass:andRepresentationClass:forMIMEType:]):
Now special-case WebHTMLView instead of WebTextView for MIME types
that shouldn't be shown.
2006-05-09 Maciej Stachowiak <mjs@apple.com>
Rubber stamped by Anders.
- renamed kxmlcore to wtf
kxmlcore --> wtf
KXMLCore --> WTF
KXC --> WTF
* Misc/WebKitLogging.h:
* Misc/WebKitLogging.m:
(initializeLogChannel):
2006-05-09 Timothy Hatcher <timothy@apple.com>
Reviewed by Anders.
Bug 8804: Inspector should support searching by Xpath query
http://bugs.webkit.org/show_bug.cgi?id=8804
* WebInspector/WebInspector.m:
(-[WebInspector _refreshSearch]):
* WebInspector/webInspector/inspector.js:
2006-05-08 Maciej Stachowiak <mjs@apple.com>
Reviewed by Tim Hatcher.
- refactor things so that WebKit doesn't save a WebResource for every loaded URL,
but rather retrieves the data from the WebCore cache as needed.
http://bugs.webkit.org/show_bug.cgi?id=8802
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge objectLoadedFromCacheWithURL:response:data:]):
(-[WebFrameBridge syncLoadResourceWithMethod:URL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
* WebCoreSupport/WebSubresourceLoader.m:
(-[WebSubresourceLoader didReceiveResponse:]):
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _setupForReplaceByMIMEType:]):
(-[WebDataSource _archivedSubresourceForURL:]):
(-[WebDataSource initWithRequest:]):
(-[WebDataSource subresources]):
(-[WebDataSource subresourceForURL:]):
(-[WebDataSource addSubresource:]):
* WebView/WebDataSourcePrivate.h:
* WebView/WebFrame.m:
* WebView/WebFrameInternal.h:
* WebView/WebHTMLView.m:
* WebView/WebLoader.h:
* WebView/WebLoader.m:
(-[NSURLProtocol loadWithRequest:]):
(-[NSURLProtocol didFinishLoading]):
* WebView/WebUnarchivingState.h:
* WebView/WebUnarchivingState.m:
(-[WebUnarchivingState addResource:]):
2006-05-04 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=8594
REGRESSION: Exception on closing a page containing (just) an mp3
Test: plugins/pluginDocumentView-deallocated-dataSource.html
* Plugins/WebPluginDocumentView.m:
(-[WebPluginDocumentView dealloc]): Release the dataSource.
(-[WebPluginDocumentView setDataSource:]): Retain the dataSource.
2006-05-04 Tim Omernick <timo@apple.com>
Reviewed by Darin.
<rdar://problem/4537606> Give Java WebKit plugin access to its own DOM element
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge viewForJavaAppletWithFrame:attributeNames:attributeValues:baseURL:DOMElement:]):
Pass the DOMElement to the plugin if it's a WebKit plugin (we need to handle Netscape plugins
differently).
2006-05-04 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4480186> Give WebKit plugins access to their own DOM element
This does not fix <rdar://problem/4480187> Give Netscape plugins access to their own DOM element --
we're not going to use the ObjC DOM API for that, but rather the NP bindings API.
* Plugins/WebPluginPackage.m:
Declared WebPlugInContainingElementKey. This is not a new plugin argument -- it's been in our public
headers since all along, but has never been concretely declared -- plugins that referenced it would not
link.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge pluginViewWithPackage:attributeNames:attributeValues:baseURL:DOMElement:]):
Added DOMElement parameter, which is now included in the plugin arguments dictionary.
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:]):
ditto
* WebKit.exp:
Export WebPlugInContainingElementKey.
2006-05-02 Darin Adler <darin@apple.com>
Reviewed by Eric.
- http://bugs.webkit.org/show_bug.cgi?id=8677
REGRESSION: wkSetUpFontCache() may be called before the SPIs are connected.
I don't know how reproduce this without one of Rosyna's hacks installed, so I
did not include a test.
* Misc/WebStringTruncator.m: (+[WebStringTruncator initialize]): Add call to
InitWebCoreSystemInterface.
* WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Add a boolean
so we will only do this one time.
2006-05-02 Adele Peterson <adele@apple.com>
Reviewed by Tim O.
- fix http://bugs.webkit.org/show_bug.cgi?id=6988
REGRESSION: Display correct context menus for new text fields
* WebView/WebView.m: (-[WebView _menuForElement:defaultItems:]):
Don't let the UI delegate have control over the context menu for text fields.
2006-05-01 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=8658
Assertion failure in -[WebPluginContainerCheck _isForbiddenFileLoad]
(bridge is null) when clicking QuickTime object with href
* WebView/WebHTMLView.m:
(-[WebHTMLView setDataSource:]): Set the pluginController's dataSource.
2006-05-01 Maciej Stachowiak <mjs@apple.com>
- fix build
* WebKit.exp: Add symbol that the new Safari will need.
2006-05-01 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
- fixed <rdar://problem/3126419> history load enforces history limit, but deletes the newest instead of oldest items
- added notification reporting items discarded during load because the age limit or item count limit is exceeded
- a few other minor tweaks
* History/WebHistory.h:
fixed a typo and an incorrect method name
* History/WebHistoryPrivate.h:
Added declaration of WebHistoryItemsDiscardedWhileLoadingNotification. Also changed signature of
WebHistoryPrivate method -loadFromURL:error: to have new collectDiscardedItemsInto: parameter.
Also deleted declarations of two methods that didn't actually exist (loadHistory and initWithFile:),
and added comments about which methods should become public API, WebKit-internal, or file-internal.
* History/WebHistory.m:
(-[WebHistoryPrivate arrayRepresentation]):
This method, called only by _saveHistoryGuts:, used to deliberately leave out items that violated
either the age limit or the item count limit. Now all the items are included (and thus saved), and
all the pruning is done at load time, so clients can keep track of the pruned items by observing
the new WebHistoryItemsDiscardedWhileLoadingNotification
(-[WebHistoryPrivate _loadHistoryGutsFromURL:savedItemsCount:collectDiscardedItemsInto:error:]):
Now keeps track of all the items that violated the age limit or item count limit in the new
collectedDiscardedItemsInto: parameter. Also, now processes items in forward order rather than
reverse order to fix 3126419. Now uses compare: rather than _webkit_compareDay: to check against
age limit; this is faster and also more correct (most noticeable with small age limits).
(-[WebHistoryPrivate loadFromURL:collectDiscardedItemsInto:error:]):
new collectDiscardedItemsInto: parameter, passed into _loadHistoryGuts:...
(-[WebHistory loadFromURL:error:]):
Now sends new WebHistoryItemsDiscardedWhileLoadingNotification if any items were discarded due
to age limit or item count limit.
* WebKit.exp:
exported symbol for WebHistoryItemsDiscardedWhileLoadingNotification
2006-04-29 Timothy Hatcher <timothy@apple.com>
Reviewed by Maciej.
Bug 8577: [TabBarView _web_superviewOfClass:stoppingAtClass:]
http://bugs.webkit.org/show_bug.cgi?id=8577
Added back _web_superviewOfClass:stoppingAtClass:.
This method was removed in r14032 (bug 8562), but Safari 2.0 still uses it.
We should remove this method once Open Source users have a new version
to use with TOT WebKit.
* Misc/WebNSViewExtras.m:
(-[NSView _web_superviewOfClass:stoppingAtClass:]):
2006-04-28 David Hyatt <hyatt@apple.com>
Double the cache size to account for our revised (more accurate)
measurement of the image buffers.
Reviewed by darin
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
2006-04-28 David Hyatt <hyatt@apple.com>
Fix for 8586, move WebTextRenderer into WebCore.
Reviewed by darin
* Misc/WebKitNSStringExtras.m:
(-[NSString _web_drawAtPoint:font:textColor:]):
(-[NSString _web_widthWithFont:]):
* Misc/WebStringTruncator.m:
(+[WebStringTruncator centerTruncateString:toWidth:]):
(+[WebStringTruncator centerTruncateString:toWidth:withFont:]):
(+[WebStringTruncator rightTruncateString:toWidth:withFont:]):
(+[WebStringTruncator widthOfString:font:]):
* WebCoreSupport/WebSystemInterface.m:
(InitWebCoreSystemInterface):
* WebCoreSupport/WebTextRenderer.h: Removed.
* WebCoreSupport/WebTextRenderer.m: Removed.
* WebCoreSupport/WebTextRendererFactory.h: Removed.
* WebCoreSupport/WebTextRendererFactory.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrameView.m:
(-[WebFrameView initWithFrame:]):
* WebView/WebHTMLView.m:
(-[WebHTMLView _addToStyle:fontA:fontB:]):
* WebView/WebTextView.m:
(-[WebTextView setFixedWidthFont]):
* WebView/WebView.m:
(+[WebView _setAlwaysUseATSU:]):
(+[WebView _setShouldUseFontSmoothing:]):
(+[WebView _shouldUseFontSmoothing]):
2006-04-28 Eric Seidel <eseidel@apple.com>
Reviewed by darin.
Misc. style cleanup.
http://bugs.webkit.org/show_bug.cgi?id=8643
* Misc/WebIconDatabase.m:
(-[NSMutableDictionary iconForURL:withSize:cache:]):
(-[NSMutableDictionary iconURLForURL:]):
(-[NSMutableDictionary retainIconForURL:]):
(-[NSMutableDictionary releaseIconForURL:]):
(-[WebIconDatabase _setIcon:forIconURL:]):
(-[WebIconDatabase _iconsForIconURLString:]):
(-[WebIconDatabase _forgetIconForIconURLString:]):
(-[WebIconDatabase _releaseIconForIconURLString:]):
(-[WebIconDatabase _iconsBySplittingRepresentationsOfIcon:]):
* Plugins/WebBasePluginPackage.m:
(+[WebBasePluginPackage pluginWithPath:]):
(-[WebBasePluginPackage pathByResolvingSymlinksAndAliasesInPath:]):
(-[WebBasePluginPackage initWithPath:]):
(-[WebBasePluginPackage getPluginInfoFromBundleAndMIMEDictionary:]):
(-[WebBasePluginPackage pListForPath:createFile:]):
(-[WebBasePluginPackage getPluginInfoFromPLists]):
(-[WebBasePluginPackage load]):
(-[WebBasePluginPackage setMIMEToExtensionsDictionary:]):
(-[WebBasePluginPackage isNativeLibraryData:]):
(-[NSArray _web_lowercaseStrings]):
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage openResourceFile]):
(-[WebNetscapePluginPackage closeResourceFile:]):
(-[WebNetscapePluginPackage stringForStringListID:andIndex:]):
(-[WebNetscapePluginPackage getPluginInfoFromResources]):
(-[WebNetscapePluginPackage initWithPath:]):
(-[WebNetscapePluginPackage executableType]):
(-[WebNetscapePluginPackage unloadWithoutShutdown]):
(-[WebNetscapePluginPackage load]):
(-[WebNetscapePluginPackage unload]):
* Plugins/WebNetscapePluginRepresentation.m:
(-[WebNetscapePluginRepresentation redeliverStream]):
* Plugins/WebPluginDatabase.m:
(+[WebPluginDatabase installedPlugins]):
(-[WebPluginDatabase pluginForKey:withEnumeratorSelector:]):
(-[WebPluginDatabase pluginForExtension:]):
(pluginLocations):
(-[WebPluginDatabase init]):
(-[WebPluginDatabase refresh]):
* Plugins/npapi.m:
(NPN_MemAlloc):
(NPN_MemFree):
(pluginViewForInstance):
* WebCoreSupport/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withRequest:customHeaders:referrer:forDataSource:]):
(-[WebSubresourceLoader willSendRequest:redirectResponse:]):
* WebView/WebDataSource.m:
(-[WebDataSource isLoading]):
* WebView/WebFrame.m:
(-[WebFrame _loadDataSource:withLoadType:formState:]):
(-[WebFrame _subframeIsLoading]):
* WebView/WebView.m:
(-[WebView initWithFrame:]):
(-[WebView initWithFrame:frameName:groupName:]):
2006-04-26 Tim Omernick <timo@apple.com>
Reviewed by Geoff.
<rdar://problem/4525105> Repro TOT crash in [WebBaseNetscapePluginView dealloc] at coachella.com
<http://bugs.webkit.org/show_bug.cgi?id=8564> crashed when closing a tab
* WebView/WebFrame.m:
(-[WebFramePrivate dealloc]):
Assert that plugInViews has been released.
(-[WebFrame _addPlugInView:]):
New method. Adds the plug-in view to the plugInViews set and calls -setWebFrame: on it.
(-[WebFrame _removeAllPlugInViews]):
New method. Calls -setWebFrame:nil on all plug-in views and releases the plugInViews set.
(-[WebFrame _willCloseURL]):
New method. Dispose of plug-in views when leaving a page (or closing the WebView).
* WebView/WebFrameInternal.h:
Declared -_addPlugInView:, -_removeAllPlugInViews, -_willCloseURL
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:]):
Call -[WebFrame _addPlugInView:] instead of directly setting plug-in views' frames. This
allows us to keep track of them so that we can explicitly dispose of them when leaving the page.
(-[WebFrameBridge closeURL]):
Override -[WebCoreFrameBridge closeURL] so that we can perform our own teardown when leaving
a page or closing the WebView.
* Plugins/WebBaseNetscapePluginView.h:
Declared -stop so that subclass WebNetscapePluginEmbeddedView can call it.
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView setWebFrame:]):
Stop the plug-in when it is removed from its WebFrame.
2006-04-25 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4472035> SPI that checks for URL policy fails in plugin documents
* Plugins/WebPluginController.h:
* Plugins/WebPluginController.m:
(-[WebPluginController URLPolicyCheckReferrer]):
New method. Get the referrer from the frame's data source's NSURLResponse. Note that for
document types loaded by WebCore, this URL is the same as -[WebCorePageBridge referrer],
since the response URL is what we pass to -[WebCorePageBridge openURL:].
* Plugins/WebPluginContainerCheck.m:
(-[WebPluginContainerCheck _isForbiddenFileLoad]):
Use the WebPluginController's -URLPolicyCheckReferrer instead of assuming that the bridge's
-referrer is valid. -[WebCorePageBridge referrer] is only set during the normal WebCore page
load process, which has nothing to do with loading standalone plugin documents.
2006-04-25 Tim Omernick <timo@apple.com>
Reviewed by Eric.
<rdar://problem/4526052> intermittent assertion failure in -[WebBasePluginPackage dealloc]
running layout tests
* Plugins/WebPluginPackage.m:
(-[WebPluginPackage unload]):
Clear isLoaded here. It turns out that only WebNetscapePluginPackage cleared its isLoaded
flag in -unload. We need to also do it here, because the superclass (WebBasePluginPackage)
asserts in -dealloc that -unload has been called.
2006-04-25 Tim Omernick <timo@apple.com>
Reviewed by Eric.
<rdar://problem/4526120> -[WebBasePluginPackage finalize] leaks the CFBundle (under GC only)
* Plugins/WebBasePluginPackage.m:
(-[WebBasePluginPackage finalize]):
Release the CFBundle here.
2006-04-25 Tim Omernick <timo@apple.com>
Reviewed by Geoff.
<rdar://problem/4472037>
Private extensions to the WebPlugin interface. A plugin may implement these methods to receive loading callbacks
for its main resource. Plug-ins that implement this SPI show better loading progress in the browser, can be saved
to disk, and are more efficient by avoiding making duplicate GET or POST requests for the plug-in's main resource.
I want to provide a solid API for plug-in networking, but time constraints require that I first provide this simple
SPI for internal clients.
* Plugins/WebPluginViewFactoryPrivate.h:
Added a new plugin argument, WebPlugInShouldLoadMainResourceKey. If YES, the plugin is responsible
for loading its own content. If NO, the plugin should wait for WebKit to send it the data via the
new request-sharing SPI.
* Plugins/WebPluginPrivate.h: Added.
Request-sharing SPI. See comments in code.
* Plugins/WebPluginDocumentView.h:
Hang onto the plugin view as an ivar so we can call the new resource loading methods on it.
* Plugins/WebPluginDocumentView.m:
(-[WebPluginDocumentView dealloc]):
Release pluginView ivar.
(-[WebPluginDocumentView setDataSource:]):
Pass NO for WebPlugInShouldLoadMainResourceKey to indicate to the plugin that it should not
load its own main resource -- the data will come from WebKit. This is only necessary for plugin
documents. By the time we create the view for a plugin document, we already have fetched some
of its main resource's data. Embedded plugins do not have this issue because WebKit is not
involved in loading their content.
Call -webPlugInMainResourceDidReceivResponse: on the plugin if necessary. This lets the plugin
know how much and what kind of data is going to be received.
(-[WebPluginDocumentView dataSourceUpdated:]):
If the plugin implements the new request-sharing SPI, don't cancel the in-progress request.
(-[WebPluginDocumentView receivedData:withDataSource:]):
Forward to the plugin via the new request-sharing SPI.
(-[WebPluginDocumentView receivedError:withDataSource:]):
ditto
(-[WebPluginDocumentView finishedLoadingWithDataSource:]):
ditto
* Plugins/WebPluginPackage.m:
Added WebPlugInShouldLoadMainResourceKey, tweaked some style a bit.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge pluginViewWithPackage:attributeNames:attributeValues:baseURL:]):
Pass YES for WebPlugInShouldLoadMainResourceKey. Embedded plugins must load their own data.
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:]):
ditto
* WebKit.xcodeproj/project.pbxproj:
Added WebPluginPrivate.h
2006-04-24 Maciej Stachowiak <mjs@apple.com>
Reviewed by Geoff.
<rdar://problem/4525364> REGRESSION (yesterday?): LOG() mechanism is broken
- initialize WebKit's log channels
* Misc/WebKitLogging.h:
* Misc/WebKitLogging.m:
(initializeLogChannel):
(WebKitInitializeLoggingChannelsIfNecessary):
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
* WebView/WebView.m:
(-[WebView _commonInitializationWithFrameName:groupName:]):
2006-04-24 Maciej Stachowiak <mjs@apple.com>
Build fix:
- move some prematurely moved code back
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge fini]):
(-[WebFrameBridge _preferences]):
(-[WebFrameBridge _retrieveKeyboardUIModeFromPreferences:]):
(-[WebFrameBridge keyboardUIMode]):
2006-04-24 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- move more code from WebFrameBridge to WebCoreFrameBridge
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge fini]):
(-[WebFrameBridge expiresTimeForResponse:]):
(-[WebFrameBridge loadURL:referrer:reload:userGesture:target:triggeringEvent:form:formValues:]):
(-[WebFrameBridge postWithURL:referrer:target:data:contentType:triggeringEvent:form:formValues:]):
(-[WebFrameBridge valueForKey:keys:values:]):
(-[WebFrameBridge _preferences]):
2006-04-24 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- Remove use of _webSuperviewOfClass: and related
http://bugs.webkit.org/show_bug.cgi?id=8562
I removed all use of these, now objects get at each other via
actual pointers, not using the view hierarchy. However, I left two
of the calls in because other clients rely on them as SPI (ugh).
* History/WebHistoryItem.m:
* Misc/WebNSViewExtras.h:
* Misc/WebNSViewExtras.m:
(-[NSView _web_superviewOfClass:]):
(-[NSView _web_parentWebFrameView]):
* Plugins/WebNetscapePluginDocumentView.m:
(-[WebNetscapePluginDocumentView layout]):
* Plugins/WebNetscapePluginEmbeddedView.h:
* Plugins/WebNetscapePluginEmbeddedView.m:
(-[WebNetscapePluginEmbeddedView setWebFrame:]):
(-[WebNetscapePluginEmbeddedView dataSource]):
* Plugins/WebNullPluginView.h:
* Plugins/WebNullPluginView.m:
(-[WebNullPluginView setWebFrame:]):
(-[WebNullPluginView viewDidMoveToWindow]):
* Plugins/WebPluginController.h:
* Plugins/WebPluginController.m:
(-[WebPluginController setDataSource:]):
(-[WebPluginController webPlugInContainerLoadRequest:inFrame:]):
(-[WebPluginController webPlugInContainerShowStatus:]):
(-[WebPluginController webPlugInContainerSelectionColor]):
(-[WebPluginController webFrame]):
* Plugins/WebPluginDocumentView.h:
* Plugins/WebPluginDocumentView.m:
(-[WebPluginDocumentView setDataSource:]):
(-[WebPluginDocumentView layout]):
(-[WebPluginDocumentView currentWindow]):
(-[WebPluginDocumentView viewWillMoveToWindow:]):
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge formControlIsBecomingFirstResponder:]):
(-[WebFrameBridge formControlIsResigningFirstResponder:]):
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:]):
* WebCoreSupport/WebViewFactory.m:
(-[WebViewFactory bridgeForView:]):
* WebView/WebClipView.m:
(-[NSView initWithFrame:]):
* WebView/WebFrameView.m:
(-[WebFrameView _shouldDrawBorder]):
(-[WebFrameView webCoreBridge]):
* WebView/WebHTMLView.m:
(-[WebTextCompleteController dealloc]):
(-[WebHTMLView _dataSource]):
(-[WebHTMLView _bridge]):
(-[WebHTMLView _webView]):
(-[WebHTMLView _frameView]):
(-[WebHTMLView _web_firstResponderCausesFocusDisplay]):
(-[WebHTMLView becomeFirstResponder]):
(-[WebHTMLView setDataSource:]):
(-[WebHTMLView pageUp:]):
(-[WebHTMLView pageDown:]):
(-[WebHTMLView pageUpAndModifySelection:]):
(-[WebHTMLView pageDownAndModifySelection:]):
(-[WebHTMLView _frame]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebImageView.h:
* WebView/WebImageView.m:
(-[WebImageView drawRect:]):
(-[WebImageView adjustFrameSize]):
(-[WebImageView setDataSource:]):
(-[WebImageView webView]):
(-[WebImageView writeImageToPasteboard:types:]):
(-[WebImageView copy:]):
(-[WebImageView elementAtPoint:]):
(-[WebImageView mouseDragged:]):
* WebView/WebPDFView.h:
* WebView/WebPDFView.m:
(-[WebPDFView _applyPDFDefaults]):
(-[WebPDFView _trackFirstResponder]):
(-[PDFPrefUpdatingProxy forwardInvocation:]):
* WebView/WebRenderNode.m:
(-[WebRenderNode initWithWebFrameView:]):
* WebView/WebTextView.h:
* WebView/WebTextView.m:
(-[WebTextView _textSizeMultiplierFromWebView]):
(-[WebTextView _preferences]):
(-[WebTextView setDataSource:]):
(-[WebTextView _webFrame]):
(-[WebTextView dragSelectionWithEvent:offset:slideBack:]):
(-[WebTextView menuForEvent:]):
(-[WebTextView resignFirstResponder]):
(-[WebTextView drawPageBorderWithSize:]):
(-[WebTextView knowsPageRange:]):
* WebView/WebView.m:
(-[WebView searchFor:direction:caseSensitive:wrap:]):
(containingFrameView):
(-[WebView _focusedFrame]):
(-[WebView _frameViewAtWindowPoint:]):
2006-04-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- push WebFileButton and WebStringTruncator code down to WebCore
http://bugs.webkit.org/show_bug.cgi?id=8552
* Misc/WebStringTruncator.m:
(+[WebStringTruncator centerTruncateString:toWidth:]):
(+[WebStringTruncator centerTruncateString:toWidth:withFont:]):
(+[WebStringTruncator rightTruncateString:toWidth:withFont:]):
(+[WebStringTruncator widthOfString:font:]):
* WebCoreSupport/WebFileButton.h: Removed.
* WebCoreSupport/WebFileButton.m: Removed.
* WebCoreSupport/WebFrameBridge.h:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge runOpenPanelForFileButtonWithResultListener:]):
* WebCoreSupport/WebViewFactory.m:
(-[WebViewFactory fileButtonChooseFileLabel]):
(-[WebViewFactory fileButtonNoFileSelectedLabel]):
* WebKit.xcodeproj/project.pbxproj:
2006-04-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
- remove WebCookieAdapter, WebCore can just use Foundation directly.
* WebCoreSupport/WebCookieAdapter.h: Removed.
* WebCoreSupport/WebCookieAdapter.m: Removed.
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebFrameView.m:
(-[WebFrameView initWithFrame:]):
2006-04-23 Maciej Stachowiak <mjs@apple.com>
Reviewed by Adele.
- prune WebView SPI of unused calls
Specifically I moved methods that have no callers outside WebKit
to WebViewInternal.h or removed them entirely.
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
* Plugins/WebBaseNetscapePluginView.m:
* Plugins/WebNetscapePluginDocumentView.m:
* Plugins/WebNetscapePluginStream.m:
* Plugins/WebNullPluginView.m:
* Plugins/WebPluginContainerCheck.m:
* Plugins/WebPluginController.m:
* WebCoreSupport/WebFrameBridge.m:
* WebCoreSupport/WebPageBridge.m:
* WebCoreSupport/WebSubresourceLoader.m:
* WebView/WebDataSource.m:
* WebView/WebHTMLView.m:
* WebView/WebImageView.m:
* WebView/WebLoader.m:
* WebView/WebMainResourceLoader.m:
* WebView/WebPDFView.m:
* WebView/WebScriptDebugDelegate.m:
* WebView/WebView.m:
(-[WebView _downloadURL:]):
* WebView/WebViewInternal.h:
* WebView/WebViewPrivate.h:
2006-04-22 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
- remove WebKit copy of assertions code, use the assertions
stuff from JavaScriptCore instead.
* Carbon/HIViewAdapter.m:
* DOM/WebDOMOperations.m:
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
* DefaultDelegates/WebDefaultPolicyDelegate.m:
(-[WebDefaultPolicyDelegate webView:unableToImplementPolicyWithError:frame:]):
* History/WebBackForwardList.m:
* History/WebHistory.m:
(-[WebHistoryPrivate _loadHistoryGuts:URL:error:]):
(-[WebHistoryPrivate _saveHistoryGuts:URL:error:]):
* History/WebHistoryItem.m:
* Misc/WebAssertions.h: Removed.
* Misc/WebAssertions.m: Removed.
* Misc/WebDatabase.m:
* Misc/WebDownload.m:
* Misc/WebFileDatabase.m:
(SetThreadPriority):
* Misc/WebIconDatabase.m:
(-[NSMutableDictionary iconForURL:withSize:cache:]):
(-[NSMutableDictionary releaseIconForURL:]):
(-[NSMutableDictionary delayDatabaseCleanup]):
(-[NSMutableDictionary allowDatabaseCleanup]):
(-[WebIconDatabase _loadIconDictionaries]):
(-[WebIconDatabase _updateFileDatabase]):
(-[WebIconDatabase _iconsBySplittingRepresentationsOfIcon:]):
* Misc/WebIconLoader.m:
* Misc/WebKitLogging.h:
* Misc/WebKitLogging.m:
* Misc/WebKitSystemBits.m:
(initCapabilities):
* Misc/WebLRUFileList.m:
(WebLRUFileListRemoveOldestFileFromList):
(WebLRUFileListGetFileSize):
* Misc/WebLocalizableStrings.m:
* Misc/WebNSCalendarDateExtras.m:
* Misc/WebNSDataExtras.m:
* Misc/WebNSDictionaryExtras.m:
* Misc/WebNSFileManagerExtras.m:
* Misc/WebNSPasteboardExtras.m:
* Misc/WebNSURLExtras.m:
(hexDigit):
(hexDigitValue):
(allCharactersInIDNScriptWhiteList):
* Misc/WebNSURLRequestExtras.m:
* Misc/WebNSUserDefaultsExtras.m:
* Misc/WebStringTruncator.m:
* Panels/WebAuthenticationPanel.m:
(-[WebAuthenticationPanel loadNib]):
* Panels/WebPanelAuthenticationHandler.m:
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:]):
(-[WebBaseNetscapePluginStream finishedLoadingWithData:]):
* Plugins/WebBaseNetscapePluginView.m:
(TSMEventHandler):
(-[WebBaseNetscapePluginView start]):
(-[WebBaseNetscapePluginView status:]):
(-[WebBaseNetscapePluginView _printedPluginBitmap]):
* Plugins/WebBasePluginPackage.m:
* Plugins/WebNetscapePluginDocumentView.m:
* Plugins/WebNetscapePluginPackage.m:
(-[WebNetscapePluginPackage load]):
* Plugins/WebNetscapePluginRepresentation.m:
* Plugins/WebPluginContainerCheck.m:
* Plugins/WebPluginController.m:
(-[WebPluginController addPlugin:]):
(-[WebPluginController webPlugInContainerLoadRequest:inFrame:]):
(-[WebPluginController webPlugInContainerShowStatus:]):
* Plugins/WebPluginDatabase.m:
* Plugins/WebPluginDocumentView.m:
* WebCoreSupport/WebCookieAdapter.m:
* WebCoreSupport/WebFileButton.m:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge runModal]):
* WebCoreSupport/WebImageData.m:
(-[WebImageData _checkSolidColor:]):
(-[WebImageData tileInRect:fromPoint:context:]):
(-[WebImageData scaleAndTileInRect:fromRect:withHorizontalTileRule:withVerticalTileRule:context:]):
* WebCoreSupport/WebImageDecoder.m:
* WebCoreSupport/WebImageRenderer.m:
(-[WebImageRenderer TIFFRepresentation]):
* WebCoreSupport/WebImageRendererFactory.m:
* WebCoreSupport/WebJavaScriptTextInputPanel.m:
* WebCoreSupport/WebKeyGenerator.m:
* WebCoreSupport/WebPageBridge.m:
* WebCoreSupport/WebSubresourceLoader.m:
* WebCoreSupport/WebTextRenderer.m:
(widthForGlyph):
(-[WebTextRenderer initWithFont:]):
(drawGlyphs):
(initializeATSUStyle):
(createATSULayoutParameters):
(getTextBounds):
(ATSU_draw):
* WebCoreSupport/WebTextRendererFactory.m:
* WebCoreSupport/WebViewFactory.m:
* WebKit.exp:
* WebKit.xcodeproj/project.pbxproj:
* WebKitPrefix.h:
* WebView/WebArchiver.m:
(+[WebArchiver _archiveWithMarkupString:fromFrame:nodes:]):
* WebView/WebClipView.m:
* WebView/WebDataProtocol.m:
* WebView/WebDataSource.m:
(-[WebDataSource _startLoading]):
* WebView/WebFormDataStream.m:
(formEventCallback):
(webSetHTTPBody):
* WebView/WebFrame.m:
(-[WebFrame _transitionToCommitted:]):
* WebView/WebFrameView.m:
* WebView/WebHTMLRepresentation.m:
* WebView/WebHTMLView.m:
(-[WebHTMLView _lookUpInDictionaryFromMenu:]):
(-[WebHTMLView drawSingleRect:]):
(-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
(-[WebHTMLView _scaleFactorForPrintOperation:]):
(-[WebHTMLView deleteBackwardByDecomposingPreviousCharacter:]):
(-[WebHTMLView checkSpelling:]):
(-[WebHTMLView showGuessPanel:]):
(-[WebHTMLView _changeSpellingToWord:]):
(-[WebHTMLView ignoreSpelling:]):
(-[WebHTMLView performFindPanelAction:]):
(-[WebTextCompleteController doCompletion]):
* WebView/WebImageView.m:
* WebView/WebLoader.m:
(-[NSURLProtocol connection:willCacheResponse:]):
* WebView/WebPDFRepresentation.m:
(+[WebPDFRepresentation PDFDocumentClass]):
* WebView/WebPDFView.m:
(+[WebPDFView PDFKitBundle]):
(+[WebPDFView PDFViewClass]):
(-[WebPDFView _menuItemsFromPDFKitForEvent:]):
* WebView/WebTextRepresentation.m:
* WebView/WebTextView.m:
* WebView/WebUnarchivingState.m:
* WebView/WebView.m:
2006-04-22 Timothy Hatcher <timothy@apple.com>
Reviewed by Eric.
http://bugs.webkit.org/show_bug.cgi?id=8514
Bug 8514: Web Inspector hides when the app is in the background
Makes the inspector not hide in the background. Since the inspector is a floating panel
we need to call setFloatingPanel:NO when the app is switching into the background. Then
call setFloatingPanel:YES when the app is activated again. Without this the inspector
would float above all applications.
* WebInspector/WebInspector.m:
(-[NSWindow window]): setHidesOnDeactivate:NO
(-[NSWindow windowWillClose:]): de-regiser appliction active notifications
(-[NSWindow showWindow:]): register for appliction active notifications
(-[WebInspector _applicationWillResignActive]): setFloatingPanel:NO
(-[WebInspector _applicationDidBecomeActive]): setFloatingPanel:YES
2006-04-21 Adele Peterson <adele@apple.com>
Reviewed by Darin.
- Fix for http://bugs.webkit.org/show_bug.cgi?id=8181
REGRESSION: After tabbing in page's field, attempting to tab from Google toolbar search to page fails on first try
Test: manual-tests/tabbing-input-google.html
* WebView/WebHTMLView.m: (-[WebHTMLView resignFirstResponder]):
When resigning first responder, reset willBecomeFirstResponderForNodeFocus, so when the WebHTMLView gets focus again
it knows it can start moving through the tab cycle.
2006-04-20 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4476875> Support printing for embedded Netscape plugins
NOTE: This only works with the Flash plugin right now. It appears that the other
major plugins either have awful printing support, or no printing support. If someone
can find an example of any other embedded Netscape plugin printing in any browser on
the Mac, I will be happy to eat my own words!
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView drawRect:]):
When printing, get the printed bitmap via -_printedPluginBitmap, and draw it into the
plugin view.
(-[WebBaseNetscapePluginView _printedPluginBitmap]):
Call NPP_Print on the plugin to render it into a GWorld. This GWorld has the same
underlying buffer as an NSBitmapImageRep, which is returned to the caller.
2006-04-20 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin.
WebKit part of:
- fix http://bugs.webkit.org/show_bug.cgi?id=8276
REGRESSION (NativeTextField): Pasting a Finder item into a text field results in
a file: URL being pasted instead of just the file name
- fix http://bugs.webkit.org/show_bug.cgi?id=8283
REGRESSION: File's path doesn't appear after dragging file into input field
* WebView/WebHTMLView.m:
(-[WebHTMLView _plainTextFromPasteboard:]): Added method that tries to copy AppKit
text fields' logic for extracting plain text from the pasteboard.
(-[WebHTMLView _pasteAsPlainTextWithPasteboard:]): Added helper method.
(-[WebHTMLView _shouldInsertText:replacingDOMRange:givenAction:]):
(-[WebHTMLView _shouldReplaceSelectionWithText:givenAction:]):
(-[WebHTMLView readSelectionFromPasteboard:]): Paste as plain text if
rich text is not allowed.
(-[WebHTMLView validateUserInterfaceItem:]): Changed to not allow pasteAsRichText:
if the paste is not going to be handled by the DOM and the selection
does not allow pasting rich text.
(-[WebHTMLView concludeDragForDraggingInfo:actionMask:]): Paste as plain text if
rich text is not allowed.
(-[WebHTMLView paste:]): Ditto.
(-[WebHTMLView pasteAsPlainText:]):
2006-04-20 Darin Adler <darin@apple.com>
Reviewed by Adele.
- WebKit part of http://bugs.webkit.org/show_bug.cgi?id=8505
eliminate WebCoreGraphics bridge, demonstrate new SystemInterface technique
* WebCoreSupport/WebGraphicsBridge.h: Removed.
* WebCoreSupport/WebGraphicsBridge.m: Removed.
* WebCoreSupport/WebSystemInterface.h: Added.
* WebCoreSupport/WebSystemInterface.m: Added.
* WebKit.xcodeproj/project.pbxproj: Updated for removed and added files.
* WebCoreSupport/WebImageData.m: Removed unneeded include of WebGraphicsBridge.h.
* WebCoreSupport/WebImageRenderer.m: Ditto.
* WebCoreSupport/WebTextRenderer.m: Ditto.
* WebView/WebFrameView.m: (-[WebFrameView initWithFrame:]): Guarded all the one-time
initialization inside a boolean, just in case some things take a little time. Added
a call to InitWebCoreSystemInterface to the one-time initialization here. Later, we
will need to add it in some other places if we call code that requires the use of
WebCoreSystemInterface functions from anywhere that can be invoked before creations
of the first WebFrameView, but for now there is no need.
2006-04-19 James G. Speth <speth@end.com>
Reviewed by Timothy.
http://bugs.webkit.org/show_bug.cgi?id=8442
Bug 8442: improvements to Cocoa bindings support in WebView - code simplification
Removes the WebController class added earlier; changes NSTreeController and
WebView to together without it. Now you can just bind the contentObject binding
of the tree controller directly to the mainFrameDocument key of the WebView.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge windowObjectCleared]):
* WebView/WebDataSource.m:
(-[WebDataSource _setTitle:]):
* WebView/WebFrame.m:
(-[WebFrame _closeOldDataSources]):
* WebView/WebView.m:
(-[WebView _progressStarted:]):
(-[WebView _finalProgressComplete]):
(-[WebView _commonInitializationWithFrameName:groupName:]):
(-[WebView setMainFrameDocumentReady:]):
(-[WebView mainFrameDocument]):
* WebView/WebViewPrivate.h:
2006-04-19 James G. Speth <speth@end.com>
Reviewed by Timothy.
http://bugs.webkit.org/show_bug.cgi?id=6635
Bug 6635: Crash selecting inspector nodes for tabs that aren't foremost
Stop observing window will close notifications before we tell the highlight window to close,
this prevents the crash. Also prevent drawing highlights for hidden tabs.
* WebInspector/WebInspector.m:
(-[WebInspector _highlightNode:]):
* WebInspector/WebNodeHighlight.m:
(-[WebNodeHighlight expire]):
2006-04-19 James G. Speth <speth@end.com>
Reviewed by Timothy.
http://bugs.webkit.org/show_bug.cgi?id=6637
Bug 6637: selecting node in Inspector after closing window crashes Safari
When the window the Web Inspector was inspecting is closed, the inspector goes into its
no-selection state. Choosing to inspect another element activates it again. The inspector
will also follow the WebView if the URL changes and select the root element on the new page.
* WebInspector/WebInspector.m:
(-[NSWindow setWebFrame:]):
(-[NSWindow setRootDOMNode:]):
(-[WebInspector _revealAndSelectNodeInTree:]):
(-[WebInspector _update]):
(-[WebInspector _updateRoot]):
(-[WebInspector inspectedWebViewProgressFinished:]):
(-[WebInspector inspectedWindowWillClose:]):
(-[WebInspector webView:didFinishLoadForFrame:]):
* WebInspector/WebInspectorPanel.m:
(-[WebInspectorPanel canBecomeMainWindow]):
2006-04-18 Darin Adler <darin@apple.com>
Reviewed by Beth.
* WebInspector/webInspector/inspector.css: Add "-webkit-" prefixes to the border
radius properties to make the corners rounded again.
2006-04-16 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin.
- WebKit part of fix for http://bugs.webkit.org/show_bug.cgi?id=8324
REGRESSION: textarea :focus not applied immediately
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge formControlIsBecomingFirstResponder:]): Added. Calls the ancestor
WebHTMLView's _formControlIsBecomingFirstResponder:
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateFocusState:]): If a descendant is becoming first responder,
enable focused appearance.
(-[WebHTMLView _formControlIsBecomingFirstResponder:]): Added. Calls _updateFocusState,
causing the frame to display with focus attributes.
* WebView/WebHTMLViewInternal.h:
2006-04-14 James G. Speth <speth@end.com>
Reviewed by Timothy.
Bug 8389: support for Cocoa bindings - binding an NSTreeController to the WebView's DOM
http://bugs.webkit.org/show_bug.cgi?id=8389
Added a controller class, WebController, that is a subclass of
NSTreeController that has a new outlet/binding for the WebView.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge windowObjectCleared]): notify bindings about the document change
* WebView/WebView.m:
(-[WebView _progressStarted:]): notify bindings about the document change
(-[WebView _finalProgressComplete]): notify bindings about the document change
(-[WebView _declaredKeys]): added a key for the main frame document
(-[WebController init]):
(-[WebController exposedBindings]):
(-[WebController valueClassForBinding:]):
(-[WebController setContent:]):
(-[WebController webView]):
(-[WebController setWebView:]):
(-[WebView mainFrameDocument]): get the main frame's DOMDocument
* WebView/WebViewPrivate.h: Adds mainFrameDocument to pending public.
2006-04-12 David Harrison <harrison@apple.com>
Reviewed by Darin.
<rdar://problem/4386640> AX: AXPreviousSentenceStartTextMarkerForTextMarker does not respect paragraph boundary
<rdar://problem/4414575> AX: Dictionary popup cannot find some words on Dictionary.app
(see related changes in WebCore)
Tests added:
* editing/selection/extend-by-sentence-001.html: Added.
* fast/dom/inner-text-001.html: Added.
* WebView/WebHTMLView.m:
(-[WebHTMLView validateUserInterfaceItem:]):
(-[WebHTMLView moveToBeginningOfSentence:]):
(-[WebHTMLView moveToBeginningOfSentenceAndModifySelection:]):
(-[WebHTMLView moveToEndOfSentence:]):
(-[WebHTMLView moveToEndOfSentenceAndModifySelection:]):
(-[WebHTMLView selectSentence:]):
* WebView/WebView.m:
* WebView/WebViewPrivate.h:
Add sentence navigation and selection.
2006-04-12 Tim Omernick <timo@apple.com>
Reviewed by Darin.
Part of <rdar://problem/4482530>
* WebView/WebView.m:
(-[WebView _focusedFrame]):
Fixed up the logic here to take into account immediate subviews of WebView, which are not actually in a WebFrameView
(they are peers to the main frame's WebFrameView).
2006-04-10 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
- fixed <rdar://problem/4139799> Seed: Safari: Private Browsing leaves traces in Icon Cache
* Misc/WebIconDatabasePrivate.h:
new ivars: pageURLsBoundDuringPrivateBrowsing, iconURLsBoundDuringPrivateBrowsing, and privateBrowsingEnabled
* Misc/WebIconDatabase.m:
(-[NSMutableDictionary init]):
initialize new ivars, and listen for notifications that WebPreferences changed so we can react to changes
to private browsing.
(-[NSMutableDictionary iconForURL:withSize:cache:]):
Don't remove icon URL from extraRetain dictionary; that's now done in _forgetIconForIconURLString. (I left a
comment here earlier about why I was worried about this change, but I convinced myself that it's fine.)
(-[WebIconDatabase removeAllIcons]):
Removed no-longer-true (and never very clear) comment, and braces. Also remove all objects from the two
private-browsing-related dictionaries.
(-[WebIconDatabase _setIcon:forIconURL:]):
remember icon URL if private browsing is enabled
(-[WebIconDatabase _setHaveNoIconForIconURL:]):
remember icon URL if private browsing is enabled
(-[WebIconDatabase _setIconURL:forURL:]):
added an assert that helped me out at one point
(-[WebIconDatabase _clearDictionaries]):
clear the two new dictionaries too
(-[WebIconDatabase _loadIconDictionaries]):
made an existing ERROR not fire in the expected case where there are no icons at all on disk
(-[WebIconDatabase _updateFileDatabase]):
when saving the pageURLToIconURL dictionary to disk, first remove any values that were created during
private browsing
(-[WebIconDatabase _retainIconForIconURLString:]):
skip the code that deals with saving changes to disk if private browsing is enabled
(-[WebIconDatabase _forgetIconForIconURLString:]):
Remove the icon URL from extraRetain dictionary here. We're forgetting everything about this icon URL
so we should forget its former extraRetain count too.
(-[WebIconDatabase _resetCachedWebPreferences:]):
Cache the new value of private browsing. If it has now been turned off, forget everything we learned
while it was on. This causes (e.g.) icons for bookmarks or pre-existing history items to be forgotten
if the icon was only learned during private browsing.
* History/WebHistoryItem.m:
removed an unnecessary #import I happened to notice
2006-04-10 David Hyatt <hyatt@apple.com>
Make the broken CG focus ring painting work when WebCore sets a clip
(in addition to respecting the dirty rect clip).
Reviewed by darin
* WebCoreSupport/WebGraphicsBridge.m:
(-[WebGraphicsBridge drawFocusRingWithPath:radius:color:clipRect:]):
2006-04-10 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=8100
REGRESSION (NativeTextField): Right-aligned and RTL text jitters in new text fields
* WebCoreSupport/WebTextRenderer.m:
(overrideLayoutOperation): For RTL runs, apply the word-rounding on the left.
(CG_floatWidthForRun): For RTL runs, apply the last character's rounding
on the left by adjusting the start position.
(initializeWidthIterator): Added finalRoundingWidth field to WidthIterator.
(advanceWidthIterator): For RTL runs, apply rounding on the left of the character,
by increasing the width of the next character (which is the character to the left). For
the last character, keep the rounding width in the iterator's finalRoundingWidth, to be used by
CG_floatWidthForRun().
2006-04-08 John Sullivan <sullivan@apple.com>
Reviewed by Adele Peterson.
- fixed http://bugs.webkit.org/show_bug.cgi?id=8260
REGRESSION: Assertion failure: ![_private->iconsToSaveWithURLs containsObject:iconURLString]
in WebIconDatabase.m:695-[WebIconDatabase(WebInternal) _retainIconForIconURLString:]
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _retainIconForIconURLString:]):
This new assertion was one block too high; moved it in.
2006-04-07 David Hyatt <hyatt@apple.com>
A fix that makes coalesced updates work much better (and makes our
single animated GIF timer work better). The new rect painting algorithm
for WebHTMLView will use the single unioned rect if the # of rects exceeds
a threshold (10 is my initial cut), or if the union has enough "wasted"
additional pixels (conservatively set at 75%).
Reviewed by darin
* WebView/WebHTMLView.m:
(-[WebHTMLView drawSingleRect:]):
(-[WebHTMLView drawRect:]):
2006-04-07 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- simplify archive loading
* WebView/WebDataSource.m:
(-[WebDataSource representation]): fix whitespace
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation loadArchive]): Use WebFrame's loadArchive: instead
of trying to do a manual load here.
(-[WebHTMLRepresentation documentSource]): No more special case for WebArchive.
2006-04-07 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
- fixed <rdar://problem/4507054> If an icon file is removed from disk behind Safari's back,
Safari will not try to refetch it
In addition to letting WebIconDatabase recover from disk/memory mismatches as per 4507054, I also found
a bug in the way icons are remembered that could account for some of the other cases where
site icons didn't appear (and you'd get an ERROR on debug builds about WebIconDatabase saying it
had some icon when it really doesn't).
* Misc/WebIconDatabase.m:
(-[WebIconDatabase iconForURL:withSize:cache:]):
When the icon file for a previously-saved site icon isn't found, forget about the darn icon URL thoroughly
so that this situation is self-correcting. Formerly, once you got into this state WebKit would never find
the icon again (short of removing the entire icon database cleanly). Note that this does *not* change
the behavior of sites that didn't have a site icon when WebKit checked -- these will continue to not
return a site icon indefinitely (that's a separate, possibly performance-sensitive issue).
(-[WebIconDatabase _retainIconForIconURLString:]):
This code did the wrong thing in the case where an icon was in the process of being forgotten about. In
that case, the icon would still be in _private->iconsOnDiskWithURLs, so we wouldn't try to save it here,
so the new icon wouldn't stick.
2006-04-07 David Hyatt <hyatt@apple.com>
Re-enable coalesced updates. Our move to a single timer has essentially
implemented coalescing of updates anyway, so the regression has already
come back. Since we have to deal with that now anyway, there's no reason
to visually tear also. :)
Reviewed by darin
* ChangeLog:
* WebView/WebView.m:
(-[WebView _commonInitializationWithFrameName:groupName:]):
2006-04-05 Darin Adler <darin@apple.com>
- fixed a storage leak from that last check-in
* WebView/WebUnarchivingState.m: (-[WebUnarchivingState dealloc]):
Release the two dictionaries.
2006-04-05 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
- start on factoring WebArchive unpacking more into a separate class.
http://bugs.webkit.org/show_bug.cgi?id=8208
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebDataSource.m:
(-[WebDataSourcePrivate dealloc]):
(-[WebDataSource _addToUnarchiveState:]):
(-[WebDataSource _popSubframeArchiveWithName:]):
(-[WebDataSource _documentFragmentWithArchive:]):
(-[WebDataSource _setupForReplaceByMIMEType:]):
(-[WebDataSource subresourceForURL:]):
* WebView/WebDataSourcePrivate.h:
* WebView/WebFrame.m:
(-[WebFrame _loadRequest:archive:]):
(-[WebFrame loadRequest:]):
(-[WebFrame loadArchive:]):
* WebView/WebFramePrivate.h:
* WebView/WebHTMLRepresentation.m:
(-[WebHTMLRepresentation loadArchive]):
* WebView/WebUnarchivingState.h: Added.
* WebView/WebUnarchivingState.m: Added.
(-[WebUnarchivingState init]):
(-[WebUnarchivingState addArchive:]):
(-[WebUnarchivingState archivedResourceForURL:]):
(-[WebUnarchivingState popSubframeArchiveWithFrameName:]):
2006-04-04 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
The Debug and Release frameworks are now built with install paths relative to the build products directory.
This removes the need for other projects to build with -framework WebCore and -framework JavaScriptCore.
* WebKit.xcodeproj/project.pbxproj:
2006-04-04 John Sullivan <sullivan@apple.com>
Reviewed by Adele Peterson.
- WebKit part of <rdar://problem/4498418> "Autosaved" searchterms are saved during private browsing
* WebView/WebView.m:
(-[WebView _updateWebCoreSettingsFromPreferences:]):
Pass private browsing setting down to WebCore.
2006-04-03 John Sullivan <sullivan@apple.com>
Reviewed by Tim Hatcher.
- re-fixed <rdar://problem/4481198> REGRESSION (TOT): search results list in bookmarks view
remains when search text is deleted
* WebView/WebView.m:
(-[WebView searchFor:direction:caseSensitive:wrap:]):
I fixed this recently, but then broke it again by adding an early bail-out to this method. So
now I'm removing the early bail-out.
2006-04-02 Trey Matteson <trey@usa.net>
Reviewed by Maciej.
fix http://bugs.webkit.org/show_bug.cgi?id=8121
REGRESSION: 404s are not displayed
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader continueAfterContentPolicy:response:]):
Only cancel failed loads for object elements, not for frames or a whole page.
2006-04-02 Maciej Stachowiak <mjs@apple.com>
Reviewed by Hyatt.
- fixed <rdar://problem/4198619> REGRESSION: tabbing through links fails after hitting text field w/ sys's "tab to all controls" off
- fixed <rdar://problem/4463760> REGRESSION: Can't tab from old text field (like password fields) to new text field (6811)
(http://bugs.webkit.org/show_bug.cgi?id=6811)
- fixed tab and shift tab don't select the right things
http://bugs.webkit.org/show_bug.cgi?id=5685
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge willMakeFirstResponderForNodeFocus]): New method
- let WebHTMLView know that the next time it becomes first
responder, it's to change focus within the page and the right node
has already been set, so it should not move focus forward or
backward inside it.
* WebView/WebHTMLView.m:
(-[WebHTMLView needsPanelToBecomeKey]): Override to return YES, oddly enough this
is the right way to tell AppKit that you should be in the tab cycle loop.
(-[WebHTMLView becomeFirstResponder]): Don't move forward or back in tab cycle
when this becomeFirstResponder is for tabbing from a control in the page.
(-[WebHTMLView _willMakeFirstResponderForNodeFocus]): Note that the next
time this view becomes first responder, it will be for in-page focus
navigation.
* WebView/WebHTMLViewInternal.h:
2006-04-01 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- fix http://bugs.webkit.org/show_bug.cgi?id=8105
REGRESSION (NativeTextField): Option-delete deletes one space before the deleted word
Test: fast/forms/input-text-option-delete.html
* WebView/WebHTMLView.m:
(-[WebHTMLView _deleteWithDirection:granularity:killRing:isTypingAction:]): Pass NO for
smartDeleteOK. Smart deletion only applies to deleting a word at a time, and none of
the callers of this function that delete a word at a time want smart deletion.
(-[WebHTMLView deleteToEndOfLine:]): Fixed tiny formatting glitch.
2006-03-31 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
We need to set reachedTerminalState to YES before we release
the resources to prevent a double dealloc of WebView
Fixes <rdar://problem/4372628> crash deallocating a WebView in -[WebFrame stopLoading]
* WebView/WebLoader.m:
(-[NSURLProtocol releaseResources]): set reachedTerminalState earlier
2006-03-31 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
Some cleanup in the WebIconDatabase code in a fruitless search for the cause
of the mysterious -[WebFileDatabase performSetObject:forKey] crash
* Misc/WebIconDatabase.m:
(-[WebIconDatabase _createFileDatabase]):
removed obsolete comment
(-[WebIconDatabase _loadIconDictionaries]):
Added ERRORs for unexpected early returns. Made dictionaries be autoreleased until
the end of the method where they are retained, so that the early returns don't leak;
added ASSERTs that the _private->dictionary values aren't being leaked.
(-[WebIconDatabase _updateFileDatabase]):
Added an ERROR for an unexpected early return, and made a trivial style fix.
2006-03-31 Trey Matteson <trey@usa.net>
Reviewed by Maciej, landed by ap.
http://bugs.webkit.org/show_bug.cgi?id=7739
REGRESSION: Assertion failure loading acid2 test in -[WebCoreFrameBridge installInFrame:]
Tests: http/tests/misc/acid2.html, http/tests/misc/acid2-pixel.html
The gist of this change is that we must cancel the load from the Webkit side when we
realize we're switching to the fallback content. This is somewhat a temp workaround
since control of loading will be moving to WebCore.
* WebView/WebMainResourceLoader.m:
(-[WebMainResourceLoader continueAfterContentPolicy:response:]):
2006-03-30 Justin Garcia <justin.garcia@apple.com>
Reviewed by darin
http://bugs.webkit.org/show_bug.cgi?id=6989
REGRESSION: Plain-text mode needed for contenteditable area used in new text field
* WebView/WebHTMLView.m:
(-[WebHTMLView _canEditRichly]): Added.
(-[WebHTMLView _canIncreaseSelectionListLevel]): Use _canEditRichly
(-[WebHTMLView _canDecreaseSelectionListLevel]): Ditto.
(-[WebHTMLView _increaseSelectionListLevel]):
(-[WebHTMLView _decreaseSelectionListLevel]):
(-[WebHTMLView validateUserInterfaceItem:]):
Split rich text editing actions off from ones that can be applied anywhere.
(-[WebHTMLView _applyStyleToSelection:withUndoAction:]):
(-[WebHTMLView _applyParagraphStyleToSelection:withUndoAction:]):
(-[WebHTMLView _alignSelectionUsingCSSValue:withUndoAction:]):
* WebView/WebHTMLViewPrivate.h:
2006-03-29 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4495316> REGRESSION (420+): After page has loaded, spinning progress indicator is displayed on
tab at versiontracker.com
* WebView/WebFrame.m:
(-[WebFrame _receivedMainResourceError:]):
Call -_clientRedirectCancelledOrFinished: here so that the frame load delegate is notified that the redirect's
status has changed, if there was a redirect. The frame load delegate may have saved some state about
the redirect in its -webView:willPerformClientRedirectToURL:delay:fireDate:forFrame:. Since we are definitely
not going to use this provisional resource, as it was cancelled, notify the frame load delegate that the redirect
has ended.
The fix for 4432562 was similar to this, but only took care of the case where the redirect load was actually
committed to the frame. The new call to -_clientRedirectCancelledOrFinished: handles the case where the redirect
load was successful, but was not committed. This happens with downloads.
2006-03-29 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
- fixed these bugs:
<rdar://problem/4483806> REGRESSION (417.8-TOT): PDFs don't scale correctly with auto-size (5356)
<rdar://problem/3874856> Safari PDF display should be full width by default rather than
sized to show the entire page
* WebView/WebPDFRepresentation.m:
(-[WebPDFRepresentation finishedLoadingWithDataSource:]):
Let the WebPDFView handle setting the document, because that's the best time to apply
the sizing-related preferences.
* WebView/WebPDFView.h:
eliminated firstLayoutDone ivar and -PDFSubview public method; added -setPDFDocument:
* WebView/WebPDFView.m:
(-[WebPDFView initWithFrame:]):
eliminate use of obsolete firstLayoutDone ivar
(-[WebPDFView _applyPDFDefaults]):
renamed from _readPDFDefaults for clarity
(-[WebPDFView layout]):
removed code that applied the preferences here. This was too early to handle auto-sizing correctly,
because -layout can be called before the document exists, and calling setAutoSize:YES at that
point confuses PDFView into setting the scale factor to 20 (the maximum).
(-[WebPDFView setPDFDocument:]):
New method, does what WebPDFRepresentation used to do and also applies the preferences here.
This is a good place to apply them because the document is guaranteed to now exist (of course).
(-[WebPDFView PDFSubview]):
Moved this into a new FileInternal category because it's still needed by another class in
this file but no longer needs to be public.
* WebView/WebPreferences.m:
(+[WebPreferences initialize]):
Change WebKitPDFScaleFactorPreferenceKey to 0, which represents auto-size. This fixes 3874856,
but wasn't feasible until 4483806 was fixed.
2006-03-28 Darin Adler <darin@apple.com>
Reviewed by Geoff.
- added a build step that checks for init routines
* WebKit.xcodeproj/project.pbxproj: Added a custom build phase that invokes the
check-for-global-initializers script.
2006-03-28 Tim Omernick <timo@apple.com>
Reviewed by Darin.
<rdar://problem/3694090> -[WebBaseNetscapePluginView finalize] is incorrect; design change needed
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView initWithFrame:]):
Don't observe preferences changes here -- we only want to observe preferences while the view is
installed in the view hierarchy. Plugins will appropriately start and stop themselves when added to
or removed from a window.
(-[WebBaseNetscapePluginView dealloc]):
Don't remove observers here -- they should have been removed when the view was removed from its
window.
(-[WebBaseNetscapePluginView finalize]):
ditto
(-[WebBaseNetscapePluginView viewWillMoveToWindow:]):
Stop observing preferences when the view is removed from its window.
(-[WebBaseNetscapePluginView viewDidMoveToWindow]):
Start observing preferences when the view is added to a window.
2006-03-27 Tim Omernick <timo@apple.com>
Reviewed by Eric.
<rdar://problem/3694090> -[WebBaseNetscapePluginView finalize] is incorrect; design change needed
* ChangeLog:
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView dealloc]):
Instead of calling -stop, assert that the plugin is not running. A plugin view cannot be deallocated
until it is removed from its window. When a plugin view is removed from its window, it calls -stop
on itself. Therefore I believe that this call to -stop is unnecessary; if I'm wrong, then the
assertion will help catch any edge cases.
(-[WebBaseNetscapePluginView finalize]):
ditto
2006-03-27 Tim Omernick <timo@apple.com>
Reviewed by Eric.
<rdar://problem/3694086> -[WebBaseNetscapePluginStream finalize] is incorrect; design change needed
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream dealloc]):
Assert that the stream file path either never existed, or was deleted and NULL-ed out. The stream file
is now deleted immediately after calling NPP_StreamAsFile().
(-[WebBaseNetscapePluginStream finalize]):
ditto
(-[WebBaseNetscapePluginStream _destroyStream]):
Delete the file after calling NPP_StreamAsFile(), instead of in -dealloc/-finalize. It should be OK
to delete the file here -- NPP_StreamAsFile() is always called immediately before NPP_DestroyStream()
(the stream destruction function), so there can be no expectation that a plugin will read the stream file
asynchronously after NPP_StreamAsFile() is called.
2006-03-27 Tim Omernick <timo@apple.com>
Reviewed by Eric.
<rdar://problem/3694093> -[WebBasePluginPackage finalize] is incorrect; design change needed
Call -unload on plug-in packages instead of relying on -dealloc/-finalize to do it. Currently
the only place plug-in packages are deallocated is when refreshing the set of plugins, as when
handling JavaScript's navigator.plugins.refresh().
* Plugins/WebBasePluginPackage.m:
(-[WebBasePluginPackage dealloc]):
Assert that the plug-in has been unloaded by the time -dealloc is called.
(-[WebBasePluginPackage finalize]):
ditto
* Plugins/WebPluginDatabase.m:
(-[WebPluginDatabase refresh]):
Call -unload on the plug-in packages before releasing them.
2006-03-27 Tim Omernick <timo@apple.com>
Reviewed by Tim Hatcher.
Part of <rdar://problem/4448350> Deprecated ObjC language API used in JavaScriptCore, WebCore,
WebKit and WebBrowser
* Carbon/HIViewAdapter.h:
HIViewAdapter is no longer an NSView subclass, since we no longer pose it as NSView.
* Carbon/HIViewAdapter.m:
(+[NSView bindHIViewToNSView:nsView:]):
Replace individual NSView methods instead of posing as NSView.
(_webkit_NSView_setNeedsDisplay):
Replacement implementation of -[NSView setNeedsDisplay:].
(_webkit_NSView_setNeedsDisplayInRect):
Replacement implementation of -[NSView setNeedsDisplayInRect:]
(_webkit_NSView_nextValidKeyView):
Replacement implementation of -[NSView nextValidKeyView]
2006-03-27 John Sullivan <sullivan@apple.com>
Reviewed by Darin Adler.
Removed two overzealous assertions that the steps to reproduce 4451831 were running into.
Improved comments to match.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge _nextKeyViewOutsideWebFrameViewsWithValidityCheck:]):
Remove assertion that _inNextKeyViewOutsideWebFrameViews should always be false here.
* WebView/WebHTMLView.m:
(-[WebHTMLView nextValidKeyView]):
Removed assertion that the frame should never be the main frame here.
2006-03-27 Tim Omernick <timo@apple.com>
Reviewed by Tim Hatcher.
Removed tabs & reformatted code.
* Carbon/HIViewAdapter.m:
(+[NSView bindHIViewToNSView:nsView:]):
(+[NSView getHIViewForNSView:]):
(+[NSView unbindNSView:]):
(-[NSView setNeedsDisplay:]):
(-[NSView setNeedsDisplayInRect:]):
(-[NSView nextValidKeyView]):
(SetViewNeedsDisplay):
2006-03-26 Justin Garcia <justin.garcia@apple.com>
Reviewed by darin
<http://bugs.webkit.org/show_bug.cgi?id=7974>
Add EditActions and WebUndoActions for CreateLink and Unlink
* English.lproj/Localizable.strings:
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge nameForUndoAction:]):
2006-03-23 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
At John's suggestion, renamed a private WebFrame method and tightened up some of the redirect logic I recently touched.
* WebView/WebFramePrivate.h:
Renamed -_clientRedirectCancelled: to -_clientRedirectCancelledOrFinished:, since we call this both when a redirect is
cancelled and when a redirect is successfully committed.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge reportClientRedirectCancelled:]):
Call renamed WebFrame method.
* WebView/WebFrame.m:
Added sentRedirectNotification flag to WebFramePrivate. This flag is set when we notify the frame load delegate that a
redirect will occur. We check this flag when committing a provisional load to ensure that the frame load delegate is
notified that the redirect finished.
(-[WebFrame _commitProvisionalLoad:]):
After committing a provisional load, make sure that the frame load delegate is notified that there is no longer a pending
redirect.
(-[WebFrame _clientRedirectedTo:delay:fireDate:lockHistory:isJavaScriptFormAction:]):
Set the new sentRedirectNotification flag.
(-[WebFrame _clientRedirectCancelledOrFinished:]):
Renamed method.
Clear the sentRedirectNotification flag.
(-[WebFrame _continueLoadRequestAfterNavigationPolicy:formState:]):
Call renamed method.
2006-03-23 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
<rdar://problem/4439752> TinyMCE: "Search in Google" context menu is active but fails to work when selection is active
in textarea field.
* DefaultDelegates/WebDefaultContextMenuDelegate.m:
(-[WebDefaultUIDelegate menuItemWithTag:target:representedObject:]):
Added a representedObject parameter, which is set on the newly created menu item.
(-[WebDefaultUIDelegate contextMenuItemsForElement:defaultMenuItems:]):
Instead of setting the representedObject on each menu item after creating them all, pass the element to
-menuItemWithTag:target:representedObject:.
(-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
ditto. This fixes 4439752 because this method failed to set the representedObject on the menu items as
-contextMenuItemsForElement:defaultMenuItems: did.
2006-03-23 Darin Adler <darin@apple.com>
Reviewed by Eric.
- fix <rdar://problem/4380465> repro crash when unsuccessfully attempting to import image from Services menu
* WebView/WebDataSource.m:
(-[WebDataSource _imageElementWithImageResource:]): Quietly do nothing if passed nil.
(-[WebDataSource _documentFragmentWithImageResource:]): Ditto.
2006-03-22 Tim Omernick <timo@apple.com>
Reviewed by Kevin Decker.
Even better fix for <rdar://problem/4432562>. We need to notify the frame delegate of a finished redirect for both
"fast" and "slow" redirects, after committing the load. My previous change only notified for "fast", history-locking
redirects. Now we notify the frame delegate after committing any kind of provisional load, not just in the case of
a fast redirect.
* WebView/WebFrame.m:
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _commitProvisionalLoad:]):
2006-03-22 Tim Omernick <timo@apple.com>
Reviewed by Kevin Decker.
Better fix for <rdar://problem/4432562> REGRESSION (TOT): Safari's "stop loading" active, "view source" inactive after page load [7058]
* WebView/WebFrame.m:
(-[WebFrame _transitionToCommitted:]):
Cancel the client redirect when we commit the provisional load, if we were waiting for a redirect.
This is a better fix for 7058 (<rdar://problem/4432562>). The original fix for 7058 changed the timing of the redirect cancel
in such a way that WebKit was precluded from ever reusing back/forward list entries for redirects. Clearing the redirect state
here actually makes logical sense, as the redirect's target page is being committed at this point.
2006-03-21 Darin Adler <darin@apple.com>
- fix http://bugs.webkit.org/show_bug.cgi?id=3784
<rdar://problem/4483827> JavaScript save dialog disappears right away (sheet triggers blur event) (3784)
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateFocusState]): Treat window as having focus if its sheet is key.
(-[WebHTMLView addWindowObservers]): Observe all focus notifications, not just the ones involving this window.
(-[WebHTMLView removeWindowObservers]): Ditto.
(-[WebHTMLView windowDidBecomeKey:]): Add checks so that we call the methods only when appropriate,
since this will now be called for all windows.
(-[WebHTMLView windowDidResignKey:]): Ditto.
2006-03-21 Adele Peterson <adele@apple.com>
Reviewed by Darin.
- Fix for http://bugs.webkit.org/show_bug.cgi?id=6813
elementAtPoint needs to return input element when clicking on new text field
* WebView/WebDocumentInternal.h: Added elementAtPoint:allowShadowContent:
* WebView/WebHTMLView.m:
(-[WebHTMLView elementAtPoint:]): Does not allow shadow content. This way, by default, callers would get the input element instead of the inner div.
(-[WebHTMLView elementAtPoint:allowShadowContent:]): Allows callers to specify whether or not the element can be a shadow node.
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]): Allows shadow content when getting element.
(-[WebHTMLView _mayStartDragAtEventLocation:]): ditto.
(-[WebHTMLView _isSelectionEvent:]): ditto.
(-[WebHTMLView _canProcessDragWithDraggingInfo:]): ditto.
* WebView/WebFrame.m: (-[WebFrame _actionInformationForNavigationType:event:originalURL:]): Does not allow shadow content when getting element.
* WebView/WebImageView.m: (-[WebImageView elementAtPoint:allowShadowContent:]): Added to conform to the WebDocumentElement protocol.
* WebView/WebPDFView.m: (-[WebPDFView elementAtPoint:allowShadowContent:]): ditto.
* WebView/WebTextView.m: (-[WebTextView elementAtPoint:allowShadowContent:]): ditto.
2006-03-21 Tim Omernick <timo@apple.com>
Reviewed by Tim Hatcher and Darin.
<rdar://problem/4427068> LMGetCurApRefNum, CloseConnection and GetDiskFragment deprecated, used in Netscape
plugin code
* Plugins/WebNetscapeDeprecatedFunctions.h: Added.
* Plugins/WebNetscapeDeprecatedFunctions.c: Added.
Added wrappers for deprecated CFM and LowMem functions. These exist in a separate file so that we can set
-Wno-deprecated-declarations on this one file without ignoring other deprecated function usage elsewhere.
(WebGetDiskFragment):
(WebCloseConnection):
(WebLMGetCurApRefNum):
(WebLMSetCurApRefNum):
* Plugins/WebNetscapePluginPackage.h:
Don't include connID ivar in 64-bit, since CFM is not supported in 64-bit.
* Plugins/WebNetscapePluginPackage.m:
(+[WebNetscapePluginPackage initialize]):
Don't bother setting the resource refNum in 64-bit, because the API to get and set it does not exist.
A theoretical 64-bit plugin couldn't possibly rely this, since there is no API.
(-[WebNetscapePluginPackage unloadWithoutShutdown]):
No need to close the connID in 64-bit.
(-[WebNetscapePluginPackage load]):
Don't load CFM bundles in 64-bit, because CFM is not supported.
* WebKit.xcodeproj/project.pbxproj:
Added WebNetscapeDeprecatedFunctions.[hm].
2006-03-21 John Sullivan <sullivan@apple.com>
Reviewed by Kevin Decker.
- fixed <rdar://problem/4485637> Implementors of searchFor:direction:caseSensitive:wrap: should bail
out early if search string is empty
This doesn't change any existing behavior, but avoids unnecessary work.
* Misc/WebSearchableTextView.m:
(-[WebSearchableTextView searchFor:direction:caseSensitive:wrap:]):
bail out immediately (returning NO) if search string is empty
* WebView/WebHTMLView.m:
(-[WebView searchFor:direction:caseSensitive:wrap:]):
ditto
* WebView/WebPDFView.m:
(-[WebPDFView searchFor:direction:caseSensitive:wrap:]):
ditto
* WebView/WebView.m:
(-[WebView searchFor:direction:caseSensitive:wrap:]):
ditto
2006-03-20 Tim Omernick <timo@apple.com>
Reviewed by John Sullivan.
Moved -_contentView from WebFrameViewInternal to WebFrameViewPrivate. Safari
needs this.
* WebView/WebFrameView.m:
(-[WebFrameView _contentView]):
* WebView/WebFrameViewInternal.h:
* WebView/WebFrameViewPrivate.h:
2006-03-17 Mitz Pettel <opendarwin.org@mitzpettel.com>
Reviewed by Darin, landed by Beth.
- fix http://bugs.webkit.org/show_bug.cgi?id=7693
WebKit relies on unpredictable timing for onload events
* WebView/WebDataSource.m:
(-[WebDataSource _receivedMainResourceError:complete:]): Check for
completion on the WebCore side before checking on the WebKit side,
to ensure that the onload event is emitted before the WebFrame load
delegate is sent the webView:didFinishLoadForFrame: message. For
DumpRenderTree, this ensures that the render tree is dumped after
the onload handler is run.
* WebView/WebLoader.m:
(-[NSURLProtocol didFailWithError:]): If load has already been
cancelled (which could happen if the parent's onload handler caused
the frame to detach), do nothing.
2006-03-17 John Sullivan <sullivan@apple.com>
Reviewed by Beth Dakin
- fixed <rdar://problem/4239051> Sometimes "Copy Link" in Safari results in a
URL on the pasteboard with no usable "title"
* History/WebURLsWithTitles.m:
(+[WebURLsWithTitles writeURLs:andTitles:toPasteboard:]):
trim whitespace from titles that are put on pasteboard. This leaves an empty string
for the title in cases where there's no displayed text, like an image in an <a> element
that happens to have whitespace in the source, e.g. <a href="foo"> <img whatever></a>
2006-03-17 Darin Adler <darin@apple.com>
- missing bit of my check-in yesterday
Maciej moved setWindowFrame for me, but I also had removed
setWindowContentRect.
* WebCoreSupport/WebFrameBridge.m: Removed unused setWindowContextRect and
windowContentRect methods.
2006-03-17 Adele Peterson <adele@apple.com>
Reviewed by Hyatt.
WebKit part of fix for:
http://bugs.webkit.org/show_bug.cgi?id=7797
Can't set background color on new text fields
Added function to draw bezeled text field without drawing background.
* WebCoreSupport/WebGraphicsBridge.m:
(-[WebGraphicsBridge drawBezeledTextFieldCell:enabled:]): Added.
2006-03-16 Maciej Stachowiak <mjs@apple.com>
Reviewed by Eric.
- move setWindowFrame / windowFrame to WebPageBridge to fix build
* WebCoreSupport/WebFrameBridge.m:
* WebCoreSupport/WebPageBridge.m:
(-[WebPageBridge setWindowFrame:]):
(-[WebPageBridge windowFrame]):
2006-03-15 Darin Adler <darin@apple.com>
Fix by Patrick Beard, reviewed by me.
- fix <rdar://problem/4478181> WebPluginController leaks NSArray and NSMutableSet objects
* Plugins/WebPluginController.m:
(-[WebPluginController initWithDocumentView:]): Call CFMakeCollectable on the CFSet
so we can act like it's an NSSet.
(-[WebPluginController dealloc]): Release _views and _checksInProgress.
2006-03-13 Tim Omernick <timo@apple.com>
Reviewed by Maciej.
<rdar://problem/4476873> Support printing for plugin documents (not embedded plugins)
* WebView/WebFrameViewPrivate.h:
* WebView/WebFrameView.m:
(-[WebFrameView documentViewShouldHandlePrint]):
Called by the host application before it initializes and runs a print operation. If NO
is returned, the host application will abort its print operation and call
-printDocumentView on the WebFrameView. The document view is then expected to run its
own print operation. If YES is returned, the host application's print operation will
continue as normal.
(-[WebFrameView printDocumentView]):
Called by the host application when the WebFrameView returns YES from -documentViewShouldHandlePrint.
* Plugins/WebNetscapePluginDocumentView.m:
(-[WebNetscapePluginDocumentView documentViewShouldHandlePrint]):
Allow the plugin to take over printing if it defines an NPP_Print function
(-[WebNetscapePluginDocumentView printDocumentView]):
Print the plugin document.
2006-03-13 Geoffrey Garen <ggaren@apple.com>
Reviewed by timo.
- Fixed the load progress indicator to give more incremental feedback,
and to stop spending so much time near 100%.
I did two things:
(1) Fixed some bugs and a misspelling in the previous heuristic's
implementation
(2) Added two new rules to the heuristic:
(a) Treat the first layout as the half-way point.
(b) Just like we jump the first 10% to indicate that a load has
started, jump the last 10% to indicate that a load has finished.
Rule 2a is good for two reasons. First, it seems unnatural for loading
to be "more than half done" when you can't even see anything. Second,
in the early stages of laading our estimate of how much we'll need to
load is often off by as much as 6000% (e.g., cnn.com). So anything that
makes the progress indicator more conservative in the early stages of
loading is helpful.
Rule 2b is good because it's confusing for loading to be "100% done"
but still ongoing.
FIXME: The indicator still isn't perfect. For example, the old behavior
shows up @ moviefone.com. Two areas for future work:
(1) Estimate number of linked resources. Our code estimates the size
of a single resource, but does nothing to estimate the number of
resources that resource might link to. This is the key to why we're
so wrong at the beginning.
(2) Improve "when to do first layout" heuristic. A JavaScript query
for a style property forces layout, creating a phantom first layout
with no content, essentially nullifying 2a for certain pages.
Filed <rdar://problem/4475834> to track estimating the number of
linked resources. Phantom layouts are already on Hyatt's radar.
* WebView/WebFrame.m:
(-[WebFrame _setState:]): Update firstLayoutDone
(-[WebFrame _numPendingOrLoadingRequests:]): Bug fix: In the recurisve
case, query 'frame' instead of 'self', so that we actually recurse.
(-[WebFrame _firstLayoutDone]): New method
(-[WebFrame _didFirstLayout]): Update firstLayoutDone
* WebView/WebFramePrivate.h: Added firstLayoutDone ivar
* WebView/WebView.m:
(-[WebView _incrementProgressForConnectionDelegate:data:]):
(1) Implemented 2a and 2b
(2) Bug fix: only update the 'last time I sent a notification' time if
we actually send a notification.
(3) Don't test for progress < 0 because ensuring progress < max
also ensures max - progress > 0. (Do still test for progress > max
because rounding errors make that a possibility -- although a very
minor one.)
(4) Query only the loading frame and its subframes for pending
requests instead of defaulting to the main frame. This is a slight
optimization in cases where the main frame did not begin the load,
and it makes the code more consistent.
2006-03-13 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
- fixed <rdar://problem/4475857> API: Setting a history item limit programmatically doesn't work
* History/WebHistory.m:
(-[WebHistoryPrivate _loadHistoryGuts:URL:error:]):
use [self historyItemLimit], which prefers the explicitly-set value and falls back to the
NSUserDefaults value, instead of using the NSUserDefaults value explicitly.
2006-03-10 Darin Adler <darin@apple.com>
Reviewed by Adele.
* WebCoreSupport/WebFrameBridge.m: Remove unused requestedURLString method.
2006-03-10 Darin Adler <darin@apple.com>
Reviewed by Geoff.
- change how frame namespacing works to be more completely on the WebCore side
* WebView/WebFrameInternal.h: Remove _setFrameNamespace: and _frameNamespace.
* WebView/WebFrame.m: Ditto.
* WebView/WebView.m:
(-[WebView setGroupName:]): Call -[WebCorePageBridge setGroupName:].
(-[WebView groupName]): Call -[WebCorePageBridge groupName].
2006-03-09 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Darin.
- http://bugs.webkit.org/show_bug.cgi?id=7656
Query string always appended to Flash URLs, instead of being replaced.
* Misc/WebNSURLExtras.h: Added _webkit_URLByRemovingResourceSpecifier.
* Misc/WebNSURLExtras.m:
(+[NSURL _web_URLWithData:relativeToURL:]): Call _webkit_URLByRemovingResourceSpecifier to
work around CFURL not removing non-path components from base URLs in some cases.
(-[NSURL _webkit_URLByRemovingComponent:]): New generic function for removing URL components.
(-[NSURL _webkit_URLByRemovingFragment]): Moved implementation to the above method.
(-[NSURL _webkit_URLByRemovingResourceSpecifier]): Added.
2006-03-07 Darin Adler <darin@apple.com>
Reviewed by Anders.
- fix http://bugs.webkit.org/show_bug.cgi?id=7655
unwanted output while running layout tests
* WebView/WebDataSourcePrivate.h:
* WebView/WebDataSource.m:
(-[WebDataSource _setRepresentation:]): Clear the flag that records whether we've sent
all the data to the representation or not; need this to prevent telling the same representation
both that we've succeeded and then later that we've failed.
(-[WebDataSource _setMainDocumentError:]): Don't send an error if representationFinishedLoading
is already YES. Set representationFinishedLoading.
(-[WebDataSource _finishedLoading]): Set representationFinishedLoading.
(-[WebDataSource _setupForReplaceByMIMEType:]): Ditto.
2006-03-06 Tim Omernick <timo@apple.com>
Reviewed by Kevin Decker.
<rdar://problem/4457574> assertion failure watching trailers at netflix.com -[WebNetscapePluginRepresentation
receivedData:withDataSource:] + 684
* Plugins/WebNetscapePluginRepresentation.m:
(-[WebNetscapePluginRepresentation receivedData:withDataSource:]):
Moved the ASSERT(instance) to the block that actually requires an assertion -- the plugin view should never
have a NULL instance by the time we start the NPStream (by calling -startStreamWithResponse:).
Some stream teardown logic changed with my fix to 4153419: when a WebBaseNetscapePluginStream is destroyed,
it now clears its NPP instance backpointer. The WebBaseNetscapePluginStream may be destroyed from within
-startStreamWithResponse: if NPP_NewStream() returns an error. We can handle this gracefully by changing
the assertion before -receivedData: to a simple NULL check.
This is unrelated to the Radar, but prior to this fix, we would attempt an NPP_Write() with the initial
stream data even if NPP_NewStream() returned an error. Seems like that alone could cause issues, though
I'm guessing that plugins handle this in practice.
2006-03-03 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
<rdar://problem/4411822> wrong element shown in Inspector inspecting main image at apple.com
<rdar://problem/4411908> in the Web Inspector, state of disclosure triangles should be preserved after search
http://bugs.webkit.org/show_bug.cgi?id=6616
Bug 6616: Double-clicking on a search result seems broken
http://bugs.webkit.org/show_bug.cgi?id=6709
Bug 6709: TypeError: Value undefined (result of expression treeScrollbar.refresh) is not object.
Code clean up and move more code into JavaScript.
Removes a few unused ObjC methods.
Many search fixes. Reveals the focused node when exiting the search.
Shows a "No Selection" screen when there are no search results.
Shows a node count for the number of results.
Fixes a couple of TypeErrors that show on the console.
Uses the system selection color in the Style pane tables.
* English.lproj/Localizable.strings: removed localized strings
* WebInspector.subproj/WebInspector.m:
(-[WebInspector init]):
(-[WebInspector dealloc]):
(-[WebInspector window]):
(-[WebInspector setSearchQuery:]):
(-[WebInspector resizeTopArea]):
(-[WebInspector searchPerformed:]): called from JavaScript when a search happens
(-[WebInspector _toggleIgnoreWhitespace:]):
(-[WebInspector _exitSearch:]): exit search results on double click
(-[WebInspector _focusRootNode:]):
(-[WebInspector _revealAndSelectNodeInTree:]):
(-[WebInspector _refreshSearch]):
(-[WebInspector _update]):
(-[WebInspector _updateTraversalButtons]):
(-[WebInspector _updateRoot]):
(-[WebInspector _updateTreeScrollbar]):
(-[WebInspector _updateSystemColors]): update CSS with system colors
(-[WebInspector webView:didFinishLoadForFrame:]):
(-[WebInspector webView:plugInViewWithArguments:]):
(-[WebInspector outlineViewSelectionDidChange:]): test for webViewLoaded
(-[WebInspectorPrivate init]): alloc rightArrowImage and downArrowImage
(-[WebInspectorPrivate dealloc]): no more matchedRules
(-[DOMNode _displayName]): removed localization UI_STRING calls.
* WebInspector.subproj/WebInspectorInternal.h:
* WebInspector.subproj/webInspector/inspector.css:
* WebInspector.subproj/webInspector/inspector.html:
* WebInspector.subproj/webInspector/inspector.js:
2006-03-02 Alexey Proskuryakov <ap@nypop.com>
Fixed a typo in the comments added in the previous checkin.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge syncLoadResourceWithMethod:URL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
* WebCoreSupport/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withMethod:URL:customHeaders:referrer:forDataSource:]):
(+[WebSubresourceLoader startLoadingResource:withMethod:URL:customHeaders:postData:referrer:forDataSource:]):
2006-03-02 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Darin.
- http://bugs.webkit.org/show_bug.cgi?id=7540
REGRESSION: frequent cache-related crashes
- http://bugs.webkit.org/show_bug.cgi?id=7393
A stale comment about XMLHttpRequest responses being never cached
* WebCoreSupport/WebFrameBridge.m: Don't call setHTTPHeader if the method is GET.
(-[WebFrameBridge syncLoadResourceWithMethod:URL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
* WebCoreSupport/WebSubresourceLoader.m: Ditto. Also removed a stale comment about
XMLHTTPRequests.
(+[WebSubresourceLoader startLoadingResource:withMethod:URL:customHeaders:referrer:forDataSource:]):
(+[WebSubresourceLoader startLoadingResource:withMethod:URL:customHeaders:postData:referrer:forDataSource:]):
2006-02-23 David Harrison <harrison@apple.com>
Reviewed by Justin.
<rdar://problem/4359736> Support outlining ability with lists
Added Mail SPI for list level changes. It is SPI because it is not complete support
for outlining. See <rdar://problem/4457070> "API for html lists as note outlines".
* WebView/WebHTMLView.m:
(-[WebHTMLView _canIncreaseSelectionListLevel]):
(-[WebHTMLView _canDecreaseSelectionListLevel]):
(-[WebHTMLView _increaseSelectionListLevel]):
(-[WebHTMLView _decreaseSelectionListLevel]):
* WebView/WebHTMLViewPrivate.h:
2006-03-01 Alexey Proskuryakov <ap@nypop.com>
Reviewed by Darin.
- http://bugs.webkit.org/show_bug.cgi?id=3812
XMLHttpRequest: PUT, DELETE, HEAD and all other methods but POST actually do a GET.
All WebKit changes are to use the method parameter passed from WebCore.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:]):
(-[WebFrameBridge startLoadingResource:withMethod:URL:customHeaders:postData:]):
(-[WebFrameBridge syncLoadResourceWithMethod:URL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
* WebCoreSupport/WebSubresourceLoader.h:
* WebCoreSupport/WebSubresourceLoader.m:
(+[WebSubresourceLoader startLoadingResource:withMethod:URL:customHeaders:referrer:forDataSource:]):
(+[WebSubresourceLoader startLoadingResource:withMethod:URL:customHeaders:postData:referrer:forDataSource:]):
2006-03-01 Timothy Hatcher <timothy@apple.com>
Reviewed by Darin.
http://bugs.webkit.org/show_bug.cgi?id=7450
elementAtPoint is expensive and should return a smart dictionary
<rdar://problem/2952761> moving the mouse around eats more CPU than I would expect (7450)
elementAtPoint for WebHTMLView now returns a WebElementDictionary,
when objectForKey is called it will lookup in the DOM, cache and return the value
* Misc/WebElementDictionary.h: Added.
* Misc/WebElementDictionary.m: Added.
(addLookupKey):
(cacheValueForKey):
(+[WebElementDictionary initializeLookupTable]):
(-[WebElementDictionary initWithInnerNonSharedNode:innerNode:URLElement:andPoint:]):
(-[WebElementDictionary dealloc]):
(-[WebElementDictionary _fillCache]):
(-[WebElementDictionary count]):
(-[WebElementDictionary keyEnumerator]):
(-[WebElementDictionary objectForKey:]):
(-[WebElementDictionary _domNode]):
(-[WebElementDictionary _webFrame]):
(-[WebElementDictionary _targetWebFrame]):
(-[WebElementDictionary _title]):
(-[WebElementDictionary _imageRect]):
(-[WebElementDictionary _isSelected]):
* Misc/WebNSViewExtras.m:
(-[NSView _web_dragImage:element:rect:event:pasteboard:source:offset:]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateMouseoverWithEvent:]):
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
(-[WebHTMLView elementAtPoint:]):
* WebView/WebView.m:
* WebView/WebViewPrivate.h:
2006-02-28 Darin Adler <darin@apple.com>
Reviewed by Adele.
- remove obsolete WebCoreScrollView class
* WebView/WebDynamicScrollBarsView.h: Change base class to NSScrollView instead of WebCoreScrollView.
* WebView/WebDynamicScrollBarsView.m: (-[WebDynamicScrollBarsView autoforwardsScrollWheelEvents]): Added.
2006-02-28 John Sullivan <sullivan@apple.com>
Reviewed by Eric Seidel
Wean WebKit from one more SPI call. We learned about this new-to-Tiger
API from filing Radar 4433222.
* WebView/WebHTMLView.m:
(-[WebHTMLView _autoscroll]):
use public CGEventSourceButtonState() instead of WKMouseIsDown() (which was using SPI internally)
2006-02-27 Tim Omernick <timo@apple.com>
Reviewed by Adele.
<rdar://problem/4222043> Safari should reduce null events sent to invisible plugins
* Plugins/WebBaseNetscapePluginView.h:
* Plugins/WebBaseNetscapePluginView.m:
(-[WebBaseNetscapePluginView restartNullEvents]):
Check to see if the plugin view is completely obscured (scrolled out of view, for example). If it is
obscured and it wasn't before, or the other way around, then restart the null event timer so it can
fire at the appropriate rate.
(-[WebBaseNetscapePluginView viewHasMoved:]):
If a plugin is obscured, send it null events as if it were in an inactive window.
2006-02-26 Mitz Pettel <opendarwin.org@mitzpettel.com>
Test: fast/frames/empty-frame-document.html
Reviewed by Darin.
- fix http://bugs.webkit.org/show_bug.cgi?id=7293
REGRESSION: Using Javascript Bookmarklets that reference location.href on a blank tab crashes WebKit
The crash happened because an empty frame did not have a document.
* WebView/WebFrame.m:
(-[WebFrame _commitProvisionalLoad:]): Use "about:blank" instead of an empty URL for empty
frames. This causes a document to be created for the frame.
2006-02-21 Kevin Decker <kdecker@apple.com>
Reviewed by Darin.
Backed out my previous check in. Since these methods are internal to WebKit (and not private)
it's perfectly OK for them to remain as categories.
* ChangeLog:
* WebView/WebPreferences.m:
(-[WebPreferences _integerValueForKey:]):
(-[WebPreferences _setIntegerValue:forKey:]):
(-[WebPreferences _floatValueForKey:]):
(-[WebPreferences _setFloatValue:forKey:]):
(-[WebPreferences _boolValueForKey:]):
(-[WebPreferences _setBoolValue:forKey:]):
* WebView/WebPreferencesPrivate.h:
2006-02-20 Darin Adler <darin@apple.com>
Collaborated with Graham Dennis <Graham.Dennis@gmail.com> on this.
- WebKit part of fix for http://bugs.webkit.org/show_bug.cgi?id=6831
contentEditable outline darkens as caret moves
* WebCoreSupport/WebGraphicsBridge.m:
(-[WebGraphicsBridge drawFocusRingWithPath:radius:color:]):
Replaced the old bridge function that set up style with this one that renders a path.
2006-02-19 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- cut out a little unneeded bridge code
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge webView]): Added. Helper, since the WebCore side of the bridge no longer
has this method.
(-[WebFrameBridge createWindowWithURL:]): Removed the frameName parameter -- this is now
handled on the WebCore side. Also return a page bridge instead of a frame bridge.
(-[WebFrameBridge createModalDialogWithURL:]): Changed to return a page bridge instead of
a frame bridge.
* WebView/WebFrame.m: (-[WebFrame webView]): Change to get the webView from the page bridge
instead of the frame bridge, since it's a per-page thing.
* WebView/WebView.m: Removed init method since it just does what the default does (calls
initWithFrame: with a zero rect).
(-[WebView initWithCoder:]): Added checking so that if the obejcts have the wrong type
we will fail gracefully instead of hitting "method not found" and the like.
(-[WebView setPreferencesIdentifier:]): Fix storage leak. The WebPreferences object was
not released.
(-[WebView mainFrame]): Removed excess "return nil".
(-[WebView _pageBridge]): Added. Helper to let you go from the WebView to the bridge
from outside the WebView class.
* WebView/WebViewInternal.h: Put _pageBridge into an internal header.
* WebCoreSupport/WebPageBridge.m: (-[WebPageBridge outerView]): Added. Replaces "webView"
as public method to tell the WebCore side about the view everything's embedded in.
- other cleanup
* WebCoreSupport/WebPageBridge.h: Removed some unneeded declarations.
* Plugins/WebBaseNetscapePluginView.m: (-[WebBaseNetscapePluginView loadPluginRequest:]):
Rearrange code so it doesn't have to get the main frame twice.
2006-02-18 Maciej Stachowiak <mjs@apple.com>
Not reviewed.
- fix build broken by my last checkin, the remaining code was not doing anything.
* WebView/WebDataSource.m:
* WebView/WebDataSourcePrivate.h:
* WebView/WebFrame.m:
(-[WebFrame _createPageCacheForItem:]):
2006-02-16 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- removed a few unused fields and methods of WebDataSource
* WebView/WebDataSource.m:
* WebView/WebDataSourcePrivate.h:
* WebView/WebView.m:
(+[WebView _MIMETypeForFile:]):
(-[WebView _updateWebCoreSettingsFromPreferences:]):
2006-02-15 Justin Garcia <justin.garcia@apple.com>
Reviewed by darin
<http://bugs.webkit.org/show_bug.cgi?id=7148>
Add drag and drop support to DumpRenderTree
Added a UI delegate method so that DumpRenderTree can perform dragging on its own.
Made _updateFocusState SPI, to allow us to test the behavior and appearance of
windows that have or don't have focus.
* WebView/WebHTMLView.m:
(-[WebHTMLView _updateFocusState]):
(-[WebHTMLView viewDidMoveToWindow]):
(-[WebHTMLView windowDidBecomeKey:]):
(-[WebHTMLView windowDidResignKey:]):
(-[WebHTMLView dragImage:at:offset:event:pasteboard:source:slideBack:]):
(-[WebHTMLView becomeFirstResponder]):
(-[WebHTMLView resignFirstResponder]):
(-[WebHTMLView _formControlIsResigningFirstResponder:]):
* WebView/WebHTMLViewInternal.h:
* WebView/WebHTMLViewPrivate.h:
* WebView/WebUIDelegatePrivate.h:
* WebView/WebView.m:
2006-02-15 Darin Adler <darin@apple.com>
* English.lproj/StringsNotToBeLocalized.txt: Updated for recent changes.
2006-02-15 Maciej Stachowiak <mjs@apple.com>
Rubber stamped by Anders.
* WebView/WebControllerPolicyHandlerDelegate.h: Removed.
2006-02-15 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
- remove some voodoo code
* WebView/WebDataSource.m:
(-[WebDataSource _setLoading:]): Removed useless ref/deref of self and WebView.
A WebDataSource cannot be loading unless it is still connected to the WebView that
owns it and retained by it, because getting disconnected stops loading.
2006-02-13 Maciej Stachowiak <mjs@apple.com>
Reviewed by Anders.
Improvements to frame loading:
- remove LayoutAcceptable state entirely
- fix WebImageView to work right without LayoutAcceptable state
- move guts of commitIfReady: to WebFrame
- try to separate page cache loading from normal loading a bit more
* English.lproj/StringsNotToBeLocalized.txt:
* WebView/WebDataSource.m:
(-[WebDataSource _prepareForLoadStart]):
(-[WebDataSource _loadFromPageCache:]):
(-[WebDataSource _startLoading]):
(-[WebDataSource _commitIfReady]):
(-[WebDataSource _setupForReplaceByMIMEType:]):
* WebView/WebDataSourcePrivate.h:
* WebView/WebFrame.m:
(-[WebFrame _transitionToCommitted:]):
(-[WebFrame _commitProvisionalLoad:]):
(-[WebFrame _checkLoadCompleteForThisFrame]):
(-[WebFrame _continueLoadRequestAfterNavigationPolicy:formState:]):
* WebView/WebFramePrivate.h:
* WebView/WebImageRepresentation.h:
* WebView/WebImageRepresentation.m:
* WebView/WebImageView.m:
(-[WebImageView dataSourceUpdated:]):
(-[WebImageView setNeedsLayout:]):
(-[WebImageView writeImageToPasteboard:types:]):
(-[WebImageView copy:]):
(-[WebImageView mouseDragged:]):
* WebView/WebView.m:
(-[WebView _finishedLoadingResourceFromDataSource:]):
(-[WebView _mainReceivedBytesSoFar:fromDataSource:complete:]):
2006-02-13 John Sullivan <sullivan@apple.com>
Reviewed by Tim Omernick.
Support for highlighting multiple text matches.
* WebView/WebHTMLViewPrivate.h:
* WebView/WebHTMLView.m:
(-[WebHTMLView highlightAllMatchesForString:caseSensitive:]):
new method, calls through to bridge
(-[WebHTMLView clearHighlightedMatches]):
ditto
* WebView/WebViewPrivate.h:
* WebView/WebView.m:
(-[WebView highlightAllMatchesForString:caseSensitive:]):
new method, calls through to documentView. For now this is hardwired to only work
with WebHTMLViews.
(-[WebView clearHighlightedMatches]):
ditto
2006-02-13 Darin Adler <darin@apple.com>
Reviewed by Maciej.
- move pointer from frame to page over to WebCore
* WebCoreSupport/WebPageBridge.m: (-[WebPageBridge initWithMainFrameName:webView:frameView:]):
Call super init to create the page before creating the main frame and calling setMainFrame: with it.
* WebCoreSupport/WebFrameBridge.h: Remove page pointer, and change init function parameters.
* WebCoreSupport/WebFrameBridge.m:
(-[WebFrameBridge initMainFrameWithPage:frameName:view:]): New function that is used only for
the main frame. Passes the page over to the other side of the bridge.
(-[WebFrameBridge initSubframeWithRenderer:frameName:view:]): New function that is used only for
subframes. Passes the renderer over to the other side of the bridge.
(-[WebFrameBridge mainFrame]):
(-[WebFrameBridge webView]):
(-[WebFrameBridge createWindowWithURL:frameName:]):
(-[WebFrameBridge showWindow]):
(-[WebFrameBridge areToolbarsVisible]):
(-[WebFrameBridge setToolbarsVisible:]):
(-[WebFrameBridge isStatusbarVisible]):
(-[WebFrameBridge setStatusbarVisible:]):
(-[WebFrameBridge setWindowFrame:]):
(-[WebFrameBridge windowFrame]):
(-[WebFrameBridge setWindowContentRect:]):
(-[WebFrameBridge windowContentRect]):
(-[WebFrameBridge setWindowIsResizable:]):
(-[WebFrameBridge windowIsResizable]):
(-[WebFrameBridge firstResponder]):
(-[WebFrameBridge makeFirstResponder:]):
(-[WebFrameBridge closeWindowSoon]):
(-[WebFrameBridge runJavaScriptAlertPanelWithMessage:]):
(-[WebFrameBridge runJavaScriptConfirmPanelWithMessage:]):
(-[WebFrameBridge canRunBeforeUnloadConfirmPanel]):
(-[WebFrameBridge runBeforeUnloadConfirmPanelWithMessage:]):
(-[WebFrameBridge runJavaScriptTextInputPanelWithPrompt:defaultText:returningText:]):
(-[WebFrameBridge addMessageToConsole:]):
(-[WebFrameBridge runOpenPanelForFileButtonWithResultListener:]):
(-[WebFrameBridge setStatusText:]):
(-[WebFrameBridge syncLoadResourceWithURL:customHeaders:postData:finalURL:responseHeaders:statusCode:]):
(-[WebFrameBridge focusWindow]):
(-[WebFrameBridge createChildFrameNamed:withURL:referrer:renderPart:allowsScrolling:marginWidth:marginHeight:]):
(-[WebFrameBridge userAgentForURL:]):
(-[WebFrameBridge _nextKeyViewOutsideWebFrameViewsWithValidityCheck:]):
(-[WebFrameBridge previousKeyViewOutsideWebFrameViews]):
(-[WebFrameBridge defersLoading]):
(-[WebFrameBridge setDefersLoading:]):
(-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:]):
(-[WebFrameBridge _preferences]):
(-[WebFrameBridge selectWordBeforeMenuEvent]):
(-[WebFrameBridge historyLength]):
(-[WebFrameBridge canGoBackOrForward:]):
(-[WebFrameBridge goBackOrForward:]):
(-[WebFrameBridge print]):
(-[WebFrameBridge pollForAppletInView:]):
(-[WebFrameBridge respondToChangedContents]):
(-[WebFrameBridge respondToChangedSelection]):
(-[WebFrameBridge undoManager]):
(-[WebFrameBridge issueCutCommand]):
(-[WebFrameBridge issueCopyCommand]):
(-[WebFrameBridge issuePasteCommand]):
(-[WebFrameBridge issuePasteAndMatchStyleCommand]):
(-[WebFrameBridge canPaste]):
(-[WebFrameBridge overrideMediaType]):
(-[WebFrameBridge isEditable]):
(-[WebFrameBridge shouldChangeSelectedDOMRange:toDOMRange:affinity:stillSelecting:]):
(-[WebFrameBridge shouldBeginEditing:]):
(-[WebFrameBridge shouldEndEditing:]):
(-[WebFrameBridge windowObjectCleared]):
(-[WebFrameBridge spellCheckerDocumentTag]):
(-[WebFrameBridge isContinuousSpellCheckingEnabled]):
(-[WebFrameBridge didFirstLayout]):
(-[WebFrameBridge dashboardRegionsChanged:]):
(-[WebFrameBridge createModalDialogWithURL:]):
(-[WebFrameBridge canRunModal]):
(-[WebFrameBridge runModal]):
Change all calls to [_page webView] to use [self webView] instead.
=== WebKit-521.7
2006-02-11 Maciej Stachowiak <mjs@apple.com>
Reviewed by Hyatt.
- factor WebArchive creation code out of other classes into new WebArchiver
http://bugs.webkit.org/show_bug.cgi?id=7208
* DOM/WebDOMOperations.m:
(-[DOMNode webArchive]):
(-[DOMRange webArchive]):
* WebKit.xcodeproj/project.pbxproj:
* WebView/WebArchiver.h: Added.
* WebView/WebArchiver.m: Added.
(+[WebArchiver _subframeArchivesForFrame:]):
(+[WebArchiver archiveFrame:]):
(+[WebArchiver _archiveCurrentStateForFrame:]):
(+[WebArchiver _archiveWithMarkupString:fromFrame:nodes:]):
(+[WebArchiver archiveRange:]):
(+[WebArchiver archiveNode:]):
(+[WebArchiver archiveSelectionInFrame:]):
* WebView/WebDataSource.m:
(-[WebDataSource webArchive]):
* WebView/WebDataSourcePrivate.h:
* WebView/WebHTMLView.m:
(-[WebHTMLView _writeSelectionWithPasteboardTypes:toPasteboard:cachedAttributedString:]):
(-[WebHTMLView _writeSelectionToPasteboard:]):
* WebView/WebHTMLViewPrivate.h:
2006-02-11 Darin Adler <darin@apple.com>
* English.lproj/StringsNotToBeLocalized.txt: Updated paths for recent changes in directory structure.
2006-02-11 David Kilzer <ddkilzer@kilzer.net>
Reviewed by John Sullivan.
- Fix http://bugs.webkit.org/show_bug.cgi?id=7171
No description in WebKitErrors.m for WebKitErrorPlugInWillHandleLoad
* English.lproj/Localizable.strings: Added new UI_STRING().
* Misc/WebKitErrors.m: Added #define for description.
(registerErrors): Added dictionary entry.
2006-02-09 Tim Omernick <timo@apple.com>
Reviewed by Tim Hatcher.
<rdar://problem/4153419> CrashTracer: 576 crashes in Safari at com.apple.WebKit: NPN_DestroyStream + 56
I never could reproduce this crasher, which seems to be caused by the Speed Download plugin. However,
I did find a way to make the affected code more bulletproof for those who are experiencing the crash.
* Plugins/WebBaseNetscapePluginStream.h:
Keep a WebBaseNetscapePluginView instead of the WebNetscapePluginPackage, since the plugin view could
potentially be deallocated before the stream finishes loading.
* Plugins/WebBaseNetscapePluginStream.m:
(-[WebBaseNetscapePluginStream _pluginCancelledConnectionError]):
Use pluginView instead of plugin.
(-[WebBaseNetscapePluginStream dealloc]):
Assert that the plugin instance has been nulled out, since that's now part of the stream's teardown
phase.
Release pluginView instead of plugin.
(-[WebBaseNetscapePluginStream setPluginPointer:]):
Retain the plugin view instead of the plugin package, since the plugin view could be deallocated while
the stream is running.
This method now accepts a NULL argument so that we can easily clear out the pluginView backpointer
(and other ivars derived from it).
(-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:]):
Use pluginView instead of plugin.
(-[WebBaseNetscapePluginStream _destroyStream]):
ditto
(-[WebBaseNetscapePluginStream finishedLoadingWithData:]):
ditto
(-[WebBaseNetscapePluginStream cancelLoadAndDestroyStreamWithError]):
Set the plugin instance to NULL, so that the pluginView backpointer is released. This method is called
for every plugin view's stream when the plugin view is stopped/destroyed.
(-[WebBaseNetscapePluginStream _deliverData]):
Use pluginView instead of plugin.
== Rolled over to ChangeLog-2006-02-09 ==