1 2009-03-26 Jungshik Shin <jshin@chromium.org>
3 Reviewed by Alexey Proskuryakov.
5 Add WebPreferences for encoding autodetection on Mac.
7 http://bugs.webkit.org/show_bug.cgi?id=16482
9 * WebView/WebPreferenceKeysPrivate.h:
10 * WebView/WebPreferences.mm:
11 (+[WebPreferences initialize]):
12 (-[WebPreferences usesEncodingDetector]):
13 (-[WebPreferences setUsesEncodingDetector:]):
14 * WebView/WebPreferencesPrivate.h:
16 (-[WebView _preferencesChangedNotification:]):
18 2009-03-26 Anders Carlsson <andersca@apple.com>
20 Reviewed by Dan Bernstein.
22 - Fix <rdar://problem/6687055> and <rdar://problem/6713639>.
24 * Plugins/Hosted/NetscapePluginHostProxy.mm:
26 Call NetscapePluginInstanceProxy::invalidateRect.
28 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
29 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
30 (WebKit::NetscapePluginInstanceProxy::cleanup):
31 Stop the request timer, set m_pluginView to nil.
33 (WebKit::NetscapePluginInstanceProxy::pluginHostDied):
34 No need to set m_pluginView to nil here anymore, it's now done in cleanup().
36 (WebKit::NetscapePluginInstanceProxy::performRequest):
37 (WebKit::NetscapePluginInstanceProxy::requestTimerFired):
38 Assert that the plug-in view is not nil.
40 (WebKit::NetscapePluginInstanceProxy::invalidateRect):
41 Call setNeedsDisplayInRect here.
43 2009-03-25 Anders Carlsson <andersca@apple.com>
45 Reviewed by Darin Adler.
47 <rdar://problem/6714964>
48 CrashTracer: [REGRESSION] 51 crashes in Safari at com.apple.WebKit • WebNetscapePluginStream::deliverData + 775
50 Don't release m_deliveryData since it's a RetainPtr. Also, use adoptNS instead of releasing newDeliveryData manually.
52 * Plugins/WebBaseNetscapePluginStream.mm:
53 (WebNetscapePluginStream::deliverData):
55 2009-03-25 Mike Thole <mthole@apple.com>
57 Reviewed by Kevin Decker.
59 <rdar://problem/6453738> call SetWindow when user creates a new tab
61 CoreGraphics plug-ins now receive an NPP_SetWindow call when moving to a background tab.
62 Flash is excluded from this change in behavior, as it has historical WebKit-specific code
63 that isn't compatible with this change.
65 * Plugins/WebNetscapePluginView.h:
66 Added an _isFlash ivar.
67 * Plugins/WebNetscapePluginView.mm:
68 (-[WebNetscapePluginView _createPlugin]):
69 Set the new _isFlash ivar based on the bundle identifier.
70 (-[WebNetscapePluginView saveAndSetNewPortStateForUpdate:]):
71 When using the CG drawing model and in a non-drawable state, set the portState
72 to NULL and return early.
73 (-[WebNetscapePluginView updateAndSetWindow]):
74 When using the CG drawing model, call -setWindowIfNecessary even if the portState is NULL.
75 Flash is an exception to this, due to its historical behavior.
76 (-[WebNetscapePluginView setWindowIfNecessary]):
77 Removed an assertion that was no longer true. The [NSView focus] view
78 is no longer guaranteed to be 'self' at this point.
79 Also modified the debug logging for CG plug-ins to include the size of the
80 window's clipRect, which was useful in verifying the correct behavior of this patch.
82 2009-03-24 Dan Bernstein <mitz@apple.com>
84 Reviewed by Oliver Hunt.
86 - speculative fix for <rdar://problem/6630134> Crash at
87 Editor::compositionRange()
89 * WebView/WebHTMLView.mm:
90 (-[WebHTMLView markedRange]): Null-check the Frame like most other
91 methods in this class.
93 2009-03-23 Sam Weinig <sam@webkit.org>
95 Reviewed by Dan Bernstein.
97 Fix for <rdar://problem/6140966>
98 Empty Caches does not clear the Cross-site XMLHttpRequest preflight cache
103 2009-03-23 Adele Peterson <adele@apple.com>
105 Reviewed by Mark Rowe & Dave Hyatt.
107 Merge some of the individual Mail quirks into two settings that we can check for future quirks.
109 * WebView/WebView.mm:
110 (runningLeopardMail):
112 (-[WebView _preferencesChangedNotification:]):
114 2009-03-23 Darin Adler <darin@apple.com>
116 * WebView/WebTextIterator.h: Fixed a spelling error in a comment.
118 2009-03-22 Dan Bernstein <mitz@apple.com>
120 Reviewed by John Sullivan.
122 - fix <rdar://problem/6640741> Messages not displaying after the
123 Safari 4 beta was installed
125 Mail assumes that if -[WebArchive subresources] is not nil, then it
126 contains at least one object.
128 * WebView/WebArchive.mm:
129 (-[WebArchive subresources]): Preserve the behavior of returning nil
130 if there are no subresources.
132 2009-03-20 Adele Peterson <adele@apple.com>
136 Reviewed by Darin Adler.
138 * WebView/WebFrameView.mm: (-[WebFrameView initWithFrame:]):
140 2009-03-20 Timothy Hatcher <timothy@apple.com>
142 Change how threading exceptions are checked so they are reported
143 by what round they were added. That way WebKit can decided the
144 behavior per-round based on linked-on-or-after checks.
146 <rdar://problem/6626741&6648478&6635474&6674079>
148 Reviewed by Darin Adler.
150 * History/WebBackForwardList.mm: Use the new WebCoreThreadViolationCheckRoundOne macro.
151 * History/WebHistoryItem.mm: Ditto.
152 * Misc/WebIconDatabase.mm: Ditto.
154 * WebView/WebArchive.mm: Use the new WebCoreThreadViolationCheckRoundTwo macro.
155 * WebView/WebResource.mm: Ditto.
156 (+[WebResource _needMailThreadWorkaroundIfCalledOffMainThread]): Check Mail's bundle version
157 to truly decide if it is an old Mail client.
158 * WebView/WebView.mm: Ditto.
160 * Misc/WebKitVersionChecks.h: Add a new linked-on-or-after version define.
161 * WebView/WebFrameView.mm:
162 (-[WebFrameView initWithFrame:]): Set the default thread violation behavior per-round
163 based on difference version checks and the Mail workaround check.
165 2009-03-20 Darin Adler <darin@apple.com>
167 Reviewed by Timothy Hatcher.
169 * WebView/WebTextIterator.h: Improved comments to point out some of the pitfalls
172 2009-03-20 Darin Adler <darin@apple.com>
174 Reviewed by Adele Peterson.
176 Use a better technique to handle finding out if something responds to a selector
177 in WebHTMLView's doCommandBySelector method.
179 * WebView/WebHTMLView.mm:
180 (-[WebHTMLView doCommandBySelector:]): Removed unneeded check for 0 coreFrame;
181 this is already handled by coreCommandBySelector: so doesn't need to be checked
182 twice. Got rid of initial value for eventWasHandled boolean to make it more clear.
183 Use WebResponderChainSink to find out if a command is handled rather than walking
184 the responder chain explicitly.
185 (-[WebResponderChainSink initWithResponderChain:]): Added.
186 (-[WebResponderChainSink detach]): Added.
187 (-[WebResponderChainSink receivedUnhandledCommand]): Added.
188 (-[WebResponderChainSink noResponderFor:]): Added.
189 (-[WebResponderChainSink doCommandBySelector:]): Added.
191 2009-03-19 Timothy Hatcher <timothy@apple.com>
193 Remove #ifndef BUILDING_ON_TIGER around code that schedules runloop modes
194 for Page, so the new RunLoopTimer in WebCore always gets a default mode.
195 Fixes the layout test failures on the Tiger build bots.
197 Reviewed by Mark Rowe.
199 * WebView/WebView.mm:
200 (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]):
201 (-[WebView scheduleInRunLoop:forMode:]):
202 (-[WebView unscheduleFromRunLoop:forMode:]):
204 2009-03-18 Anders Carlsson <andersca@apple.com>
206 Reviewed by Oliver Hunt.
208 WebKit side of <rdar://problem/6688244>.
210 Try reinitializing the vendor port if it's invalid.
212 * Plugins/Hosted/NetscapePluginHostManager.mm:
213 (WebKit::NetscapePluginHostManager::spawnPluginHost):
215 2009-03-18 Anders Carlsson <andersca@apple.com>
217 Reviewed by Darin Adler.
219 <rdar://problem/6504776>
220 CrashTracer: [USER] 188 crashes in Safari at com.apple.WebCore • WTF::HashTableIterator<WTF::RefPtr<WebCore::ResourceLoader>, ...
222 If the m_pluginView member was zeroed out as a result of making a call into the plug-in, the pluginFunctionCallDepth would be off
223 causing the plug-in never to be stopped. Simplify the code by using a RAII object.
225 * Plugins/WebBaseNetscapePluginStream.mm:
226 (PluginStopDeferrer::PluginStopDeferrer):
227 (PluginStopDeferrer::~PluginStopDeferrer):
228 (WebNetscapePluginStream::startStream):
229 (WebNetscapePluginStream::wantsAllStreams):
230 (WebNetscapePluginStream::destroyStream):
232 2009-03-17 Darin Adler <darin@apple.com>
234 Reviewed by Adele Peterson.
236 <rdar://problem/6687005> Need support for new move-left/right selectors.
238 * WebView/WebHTMLView.mm: Added the four new selectors to the command-forwarding list.
239 * WebView/WebView.mm: Ditto.
241 2009-03-17 Darin Adler <darin@apple.com>
243 Reviewed by Adele Peterson.
245 Bug 24477: REGRESSION (r41467): Page Down key scrolls two pages
246 https://bugs.webkit.org/show_bug.cgi?id=24477
247 rdar://problem/6674184
249 * WebView/WebHTMLView.mm:
250 (responderChainRespondsToSelector): Added.
251 (-[WebHTMLView doCommandBySelector:]): Set eventWasHandled based on whether we
252 can find a responder that responds to this selector rather than always assuming
253 the selector will not be handled.
255 2009-03-17 Mark Rowe <mrowe@apple.com>
259 * Plugins/Hosted/HostedNetscapePluginStream.mm:
261 2009-03-17 David Kilzer <ddkilzer@apple.com>
263 Use -[NSURLResponse(WebCoreURLResponse) _webcore_MIMEType] consistently
265 Reviewed by Darin Adler.
267 WebKit r30323 added -_webcore_MIMEType to fix issues with
268 incorrect MIME types in NS[HTTP]URLResponse objects. However,
269 uses of -[NSURLResponse MIMEType] still persist in WebKit that
270 should be switched to use -_webcore_MIMEType. Note that
271 -[WebDataSource _responseMIMEType] calls back into WebCore to
272 get the MIME type from the ResourceResponse object, which has
273 already retrieved it via -_webcore_MIMEType.
275 * Plugins/Hosted/HostedNetscapePluginStream.mm:
276 (WebKit::HostedNetscapePluginStream::didReceiveResponse): Use
278 * Plugins/WebBaseNetscapePluginStream.mm:
279 (WebNetscapePluginStream::didReceiveResponse): Ditto.
280 * Plugins/WebNetscapePluginView.mm:
281 (-[WebNetscapePluginView pluginView:receivedData:]): Ditto.
282 * Plugins/WebPluginController.mm:
283 (-[WebPluginController pluginView:receivedResponse:]): Ditto.
284 * WebView/WebHTMLRepresentation.mm:
285 (-[WebHTMLRepresentation _isDisplayingWebArchive]): Use
286 -[WebDataSource _responseMIMEType] instead.
287 * WebView/WebPDFRepresentation.m:
288 (-[WebPDFRepresentation finishedLoadingWithDataSource:]): Ditto.
289 * WebView/WebPDFView.mm:
290 (-[WebPDFView menuForEvent:]): Ditto.
292 2009-03-17 Simon Fraser <simon.fraser@apple.com>
294 Reviewed by Darin Adler
296 https://bugs.webkit.org/show_bug.cgi?id=24396
298 Add WTF_USE_ACCELERATED_COMPOSITING, defined to 0 for now.
302 2009-03-17 Kevin Ollivier <kevino@theolliviers.com>
304 Reviewed by Mark Rowe.
306 Get BUILDING_ON_* defines from Platform.h.
308 https://bugs.webkit.org/show_bug.cgi?id=24630
312 2009-03-16 Darin Adler <darin@apple.com>
314 Reviewed by Dan Bernstein.
316 <rdar://problem/6577174> Rename the text directionality submenus to “Paragraph Direction” and “Selection Direction”
318 * WebCoreSupport/WebViewFactory.mm:
319 (-[WebViewFactory contextMenuItemTagParagraphDirectionMenu]): Changed string here, but only
320 post-Leopard, since we want this to match the Mac OS X menu on Tiger and Leopard.
321 (-[WebViewFactory contextMenuItemTagSelectionDirectionMenu]): Changed string here.
323 2009-03-16 Anders Carlsson <andersca@apple.com>
325 Reviewed by Oliver Hunt.
327 Don't mig_deallocate random data in case an instance proxy method returns false.
329 * Plugins/Hosted/NetscapePluginHostProxy.mm:
336 2009-03-16 Anders Carlsson <andersca@apple.com>
338 Reviewed by Oliver Hunt.
340 <rdar://problem/6633944>
341 REGRESSION (Safari 4 PB): Many crashes in Flip4Mac involving loading the plugin
343 Defer loading while calling webPlugInInitialize since it can end up spinning the run loop.
345 * Plugins/WebPluginController.mm:
346 (-[WebPluginController addPlugin:]):
348 2009-03-16 Anders Carlsson <andersca@apple.com>
350 Reviewed by Sam Weinig.
352 Fix <rdar://problem/6622601>
354 Make sure to update both the window frame and the plug-in frame.
356 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
357 (-[WebHostedNetscapePluginView addWindowObservers]):
359 2009-03-15 Dan Bernstein <mitz@apple.com>
361 Reviewed by Adele Peterson.
363 - fix <rdar://problem/6607773> WebKit should support the "Default"
364 paragraph writing direction -- or at least validate the menu item
367 Made WebHTMLView validate user interface items with the selector
368 -makeBaseWritingDirectionNatural: by returning NO and, if the item is
369 a menu item, setting its state to "off".
371 Strictly speaking, since -makeBaseWritingDirectionNatural: is never
372 valid for WebViews, WebHTMLView should not need to respond to it and
373 validate it, however because other responders respond to all three
374 -makeBaseWritingDirection*: messages and set the menu item state, having
375 WebHTMLView do the same makes application developers' lives easier.
377 * WebView/WebHTMLView.mm:
378 (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]):
379 (-[WebHTMLView makeBaseWritingDirectionNatural:]):
381 2009-03-13 Mark Rowe <mrowe@apple.com>
383 Rubber-stamped by Dan Bernstein.
385 Take advantage of the ability of recent versions of Xcode to easily switch the active
388 * Configurations/DebugRelease.xcconfig:
390 2009-03-13 Anders Carlsson <andersca@apple.com>
392 Reviewed by Kevin Decker and Geoffrey Garen.
394 <rdar://problem/6590384>
395 REGRESSION (Safari 3-4): Tiger-only Crash occurs at WebView hostWindow () after reloading a set of tabs then quitting
397 When we're doing fast teardown, plug-in views can be destroyed from -[WebView dealloc]'s [super dealloc] call,
398 and thus calling -[WebView hostWindow] will crash since _private is nil.
400 * WebView/WebView.mm:
401 (-[WebView hostWindow]):
403 2009-03-13 Anders Carlsson <andersca@apple.com>
405 And yet another attempt...
407 * Plugins/WebNetscapePluginEventHandlerCocoa.h:
408 (WebNetscapePluginEventHandlerCocoa::installKeyEventHandler):
409 (WebNetscapePluginEventHandlerCocoa::removeKeyEventHandler):
410 * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
412 2009-03-13 Anders Carlsson <andersca@apple.com>
414 Another attempt at fixing the build.
416 * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
417 (WebNetscapePluginEventHandlerCocoa::WebNetscapePluginEventHandlerCocoa):
419 2009-03-13 Anders Carlsson <andersca@apple.com>
421 Try to fix the SL build.
423 * Plugins/WebNetscapePluginEventHandlerCocoa.h:
424 * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
425 (WebNetscapePluginEventHandlerCocoa::keyDown):
427 2009-03-13 Greg Bolsinga <bolsinga@apple.com>
429 Reviewed by Simon Fraser.
431 Update Geolocation perimission dialogs to be asynchronous.
432 https://bugs.webkit.org/show_bug.cgi?id=24505
434 WebGeolocation is a wrapper around WebCore::Geolocation. It mimics the
435 coding style set by WebSecurityOrigin.
437 WebChromeClient now calls the private UI delegate method
438 -webView:frame:requestGeolocationPermission:securityOrigin:
440 * WebCoreSupport/WebChromeClient.h:
441 * WebCoreSupport/WebChromeClient.mm:
442 (WebChromeClient::requestGeolocationPermissionForFrame):
443 * WebCoreSupport/WebGeolocation.mm: Added.
445 (-[WebGeolocation shouldClearCache]):
446 (-[WebGeolocation setIsAllowed:]):
447 (-[WebGeolocation dealloc]):
448 * WebCoreSupport/WebGeolocationInternal.h: Added.
449 * WebCoreSupport/WebGeolocationPrivate.h: Added.
450 * WebView/WebUIDelegatePrivate.h:
452 2009-03-13 Anders Carlsson <andersca@apple.com>
454 Reviewed by Dan Bernstein.
456 <rdar://problem/6610666> Revise the Cocoa event model text API
458 Replace the text input API with a simpler API that uses a separate text input window.
460 * Plugins/WebNetscapePluginEventHandlerCocoa.h:
461 * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
462 (WebNetscapePluginEventHandlerCocoa::WebNetscapePluginEventHandlerCocoa):
463 Initialize m_keyEventHandler to 0.
465 (WebNetscapePluginEventHandlerCocoa::keyDown):
466 If the plug-in returns 0 from NPP_HandleEvent, pass the event to the TSM machinery.
468 (WebNetscapePluginEventHandlerCocoa::focusChanged):
469 Install/remove the key event handler as needed.
471 (WebNetscapePluginEventHandlerCocoa::handleTSMEvent):
472 Get the text and send a TextInput event.
474 * Plugins/WebNetscapePluginView.h:
475 * Plugins/WebNetscapePluginView.mm:
476 Remove the old text input API.
478 (-[WebNetscapePluginView inputContext]):
479 Always return nil here.
482 * Plugins/nptextinput.h: Removed.
484 2009-03-12 Anders Carlsson <andersca@apple.com>
486 Reviewed by Mike Thole and Mark Rowe.
488 Fix <rdar://problem/6624105>.
490 Make sure to process incoming messages for the NSEventTrackingRunLoopMode as well.
492 * Plugins/Hosted/NetscapePluginHostProxy.mm:
493 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
495 2009-03-12 Anders Carlsson <andersca@apple.com>
497 Reviewed by Geoffrey Garen.
499 WebKit side of <rdar://problem/6607801>
501 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
502 (WebKit::NetscapePluginInstanceProxy::destroy):
503 Pass a requestID to _WKPCDestroyPluginInstance and wait until we get a reply back.
505 * Plugins/Hosted/WebKitPluginHost.defs:
506 Add requestID parameter.
508 2009-03-12 Kevin Decker <kdecker@apple.com>
510 Reviewed by Anders Carlsson.
512 * Plugins/WebNetscapePluginPackage.mm:
513 (-[WebNetscapePluginPackage _unloadWithShutdown:]): Simply a small SUPPORT_CFM code block.
515 2009-03-12 Kevin Decker <kdecker@apple.com>
517 Reviewed by Anders Carlsson.
519 Fixed: <rdar://problem/5815862> Opening a subclassed NSWindow from a Safari plugin causes Safari to crash on Quit
521 This fix addresses crashes in both Silverlight and ChemDraw. This type of crash would occur because AppKit still
522 had a reference to open windows that the plugin created (which no longer exist).
524 * Plugins/WebNetscapePluginPackage.mm:
525 (-[WebNetscapePluginPackage _unloadWithShutdown:]): Do not unload the plug-in bundle on browser shutdown.
527 2009-03-11 David Kilzer <ddkilzer@apple.com>
529 Remove duplicate header include
531 Rubber-stamped by Mark Rowe.
533 * WebView/WebView.mm: Remove duplicate #include <runtime/InitializeThreading.h>.
534 Also realphabetized lowercase #include statements.
536 2009-03-11 David Kilzer <ddkilzer@apple.com>
538 Clarify comments regarding order of FEATURE_DEFINES
540 Rubber-stamped by Mark Rowe.
542 * Configurations/WebKit.xcconfig: Added warning about the
543 consequences when FEATURE_DEFINES are not kept in sync.
545 2009-03-11 Anders Carlsson <andersca@apple.com>
547 Reviewed by Sam Weinig.
549 WebKit side of <rdar://problem/6656147>.
551 * Plugins/Hosted/NetscapePluginHostManager.mm:
552 (WebKit::NetscapePluginHostManager::instantiatePlugin):
553 Pass the requestID to _WKPHInstantiatePlugin.
555 * Plugins/Hosted/NetscapePluginHostProxy.mm:
556 Pass the requestID to setCurrentReply.
558 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
559 (WebKit::NetscapePluginInstanceProxy::setCurrentReply):
560 Store the reply in a map with the requestID as the key.
562 (WebKit::NetscapePluginInstanceProxy::waitForReply):
563 Wait for a reply that matches the given requestID.
565 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
566 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
567 Initialize member variables.
569 (WebKit::NetscapePluginInstanceProxy::~NetscapePluginInstanceProxy):
572 (WebKit::NetscapePluginInstanceProxy::print):
573 Pass the requestID to _WKPHPluginInstancePrint.
575 (WebKit::NetscapePluginInstanceProxy::loadRequest):
576 Rename m_currentRequestID to m_currentURLRequestID.
578 (WebKit::NetscapePluginInstanceProxy::processRequestsAndWaitForReply):
579 Process requests until we find a reply with the right requestID.
581 (WebKit::NetscapePluginInstanceProxy::createBindingsInstance):
582 Pass a requestID to the _WKPH function.
584 (WebKit::NetscapePluginInstanceProxy::nextRequestID):
587 * Plugins/Hosted/ProxyInstance.mm:
588 Pass a requestID to the _WKPH functions.
590 * Plugins/Hosted/WebKitPluginClient.defs:
591 * Plugins/Hosted/WebKitPluginHost.defs:
592 Add requestID parameters.
594 2009-03-11 Anders Carlsson <andersca@apple.com>
596 Reviewed by Darin Adler.
598 Fix <rdar://problem/6620064>.
600 * Plugins/WebPluginContainerPrivate.h:
602 2009-03-10 Xan Lopez <xlopez@igalia.com>
604 Build fix, no review.
606 * WebView/WebFrame.mm:
607 (-[WebFrame _smartDeleteRangeForProposedRange:]):
609 2009-03-09 Anders Carlsson <andersca@apple.com>
611 Reviewed by Kevin Decker.
613 WebKit side of <rdar://problem/6530007>
615 * Plugins/Hosted/NetscapePluginHostProxy.mm:
617 Call NetscapePluginInstanceProxy::enumerate.
619 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
620 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
621 (WebKit::NetscapePluginInstanceProxy::enumerate):
622 Enumerate the JS object and serialize its values.
624 * Plugins/Hosted/ProxyInstance.h:
625 * Plugins/Hosted/ProxyInstance.mm:
626 (WebKit::ProxyInstance::getPropertyNames):
627 Ask the plug-in host to get the property names and deserialize them.
629 * Plugins/Hosted/WebKitPluginClient.defs:
630 * Plugins/Hosted/WebKitPluginHost.defs:
632 2009-03-09 Simon Fraser <simon.fraser@apple.com>
634 Reviewed by Oliver Hunt and Cameron Zwarich
636 https://bugs.webkit.org/show_bug.cgi?id=24440
638 The sublayer added to WebHTMLView to host accelerated compositing layers needs to
639 be a subclass of NSView which allows context menu clicks through.
641 * WebView/WebHTMLView.mm:
642 (-[WebLayerHostingView rightMouseDown:]):
643 (-[WebHTMLView attachRootLayer:]):
645 2009-03-08 Mark Rowe <mrowe@apple.com>
647 Reviewed by Oliver Hunt.
649 Split ScrollAlignment and ScrollBehavior out of RenderLayer.h so that
650 Frame.h no longer needs to include it. This cuts the size of the symbols
651 for a debug build by around 3%.
653 * Plugins/WebNetscapePluginView.mm:
654 * WebView/WebFrame.mm:
655 (-[WebFrame _scrollDOMRangeToVisible:]):
656 (-[WebFrame _insertParagraphSeparatorInQuotedContent]):
657 (-[WebFrame _replaceSelectionWithFragment:selectReplacement:smartReplace:matchStyle:]):
658 * WebView/WebHTMLView.mm:
659 (-[WebHTMLView jumpToSelection:]):
660 (-[WebHTMLView centerSelectionInVisibleArea:]):
662 2009-03-07 Dan Bernstein <mitz@apple.com>
664 Reviewed by Alexey Proskuryakov.
666 - fix a bug where debug builds were clearing the HTML5 application cache
667 on application termination
669 * WebView/WebView.mm:
670 (-[WebView _close]): Call -[WebCache setDisabled:YES] instead of
673 2009-03-06 Douglas R. Davidson <ddavidso@apple.com>
675 Reviewed by Justin Garcia.
677 https://bugs.webkit.org/show_bug.cgi?id=24108
679 Update spelling and grammar checking to use the new combined text
680 checking (with automatic language identification) on Snow Leopard.
682 * WebCoreSupport/WebEditorClient.h:
683 * WebCoreSupport/WebEditorClient.mm:
684 (WebEditorClient::checkSpellingAndGrammarOfParagraph):
686 2009-03-05 Adele Peterson <adele@apple.com>
688 Reviewed by Darin Adler.
690 Fix for https://bugs.webkit.org/show_bug.cgi?id=24079
691 <rdar://problem/6611233> REGRESSION (r39549): Page loads cannot be interrupted with Command-. or Escape
692 <rdar://problem/6636563> Ctrl-tab shortcut doesn't switch tabs when focus is in text field
694 * WebView/WebHTMLView.mm: (-[WebHTMLView doCommandBySelector:]):
695 If WebKit does not support the command, we need to pass the selector to super. In this case,
696 we'll consider the event not to be handled. This is not perfect because in theory, [super doCommandBySelector:]
697 can do some action that would cause WebKit to need to consider the event handled. But in practice, I've found no
698 example of that happening and causing broken behavior.
700 2009-03-04 Mark Rowe <mrowe@apple.com>
702 Reviewed by Dan Bernstein.
704 <rdar://problem/6206172> Adoption of new Cocoa API for dictionary contextual menu
706 * WebView/WebHTMLView.mm:
707 (-[WebHTMLView _lookUpInDictionaryFromMenu:]):
709 2009-03-04 Adam Barth <abath@webkit.org>
711 Reviewed by Alexey Proskuryakov.
713 https://bugs.webkit.org/show_bug.cgi?id=24356
715 Fix WebKit style for allowUniversalAccessFromFileURLs.
717 * WebView/WebPreferenceKeysPrivate.h:
718 * WebView/WebPreferences.mm:
719 (+[WebPreferences initialize]):
720 (-[WebPreferences allowUniversalAccessFromFileURLs]):
721 (-[WebPreferences setAllowUniversalAccessFromFileURLs:]):
722 * WebView/WebPreferencesPrivate.h:
723 * WebView/WebView.mm:
724 (-[WebView _preferencesChangedNotification:]):
726 2009-03-03 David Kilzer <ddkilzer@apple.com>
728 <rdar://problem/6581203> WebCore and WebKit should install the same set of headers during installhdrs phase as build phase
730 Reviewed by Mark Rowe.
732 The fix is to add INSTALLHDRS_COPY_PHASE = YES and
733 INSTALLHDRS_SCRIPT_PHASE = YES to WebKit.xcconfig, then to
734 make sure various build phase scripts work with the installhdrs
737 * Configurations/Base.xcconfig: Defined REAL_PLATFORM_NAME
738 based on PLATFORM_NAME to work around the missing definition on
740 * Configurations/WebKit.xcconfig: Added
741 WEBCORE_PRIVATE_HEADERS_DIR variable to remove definition of
742 UMBRELLA_FRAMEWORKS_DIR for Debug and Release builds in the
743 Xcode project file. Added INSTALLHDRS_COPY_PHASE = YES and
744 INSTALLHDRS_SCRIPT_PHASE = YES.
746 2009-03-03 David Kilzer <ddkilzer@apple.com>
748 Remove last vestiges of JAVASCRIPTCORE_PRIVATE_HEADERS_DIR from WebKit
750 Reviewed by Adam Roben.
752 Use of JAVASCRIPTCORE_PRIVATE_HEADERS_DIR was removed in r37465
753 since NPAPI headers had migrated from JavaScriptCore to WebCore
756 * Configurations/WebKit.xcconfig: Removed definition of
757 JAVASCRIPTCORE_PRIVATE_HEADERS_DIR used in Production builds.
759 2009-03-03 Anders Carlsson <andersca@apple.com>
761 Reviewed by Darin Adler.
763 Fix <rdar://problem/6633834>.
765 * Plugins/Hosted/NetscapePluginHostManager.mm:
766 (WebKit::NetscapePluginHostManager::instantiatePlugin):
767 Create a new plug-in instance if the plug-in host has crashed.
769 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
770 (WebKit::NetscapePluginInstanceProxy::invalidate):
771 Add a null check for the plug-in host proxy.
773 2009-03-02 Sam Weinig <sam@webkit.org>
775 Reviewed by Mark Rowe.
777 Enable Geolocation (except on Tiger and Leopard).
779 * Configurations/WebKit.xcconfig:
781 2009-03-02 Anders Carlsson <andersca@apple.com>
783 Reviewed by Dan Bernstein.
785 WebKit part of <rdar://problem/6638658>.
787 * Plugins/Hosted/NetscapePluginHostManager.h:
788 * Plugins/Hosted/NetscapePluginHostManager.mm:
789 (WebKit::NetscapePluginHostManager::createPropertyListFile):
790 Spawn the plug-in host and wait for it to create the property list.
792 * Plugins/WebBasePluginPackage.mm:
793 (-[WebBasePluginPackage createPropertyListFile]):
794 Factor code out into a new method.
796 (-[WebBasePluginPackage pListForPath:createFile:]):
797 Call the newly added createPropertyListFile method.
799 * Plugins/WebNetscapePluginPackage.mm:
800 (-[WebNetscapePluginPackage createPropertyListFile]):
801 Tell the plug-in host manager to create a property list file for us.
803 2009-03-02 Sam Weinig <sam@webkit.org>
805 Reviewed by Geoffrey Garen.
807 Fix for <rdar://problem/6507404> Add Geolocation support.
809 This is not yet turned on for any Mac platform.
811 Add SPI to ask the embedding application whether to allow
812 Geolocation for an origin.
814 * WebCoreSupport/WebChromeClient.h:
815 * WebCoreSupport/WebChromeClient.mm:
816 (WebChromeClient::shouldAllowGeolocationForFrame):
817 * WebView/WebUIDelegatePrivate.h:
819 2009-03-02 Anders Carlsson <andersca@apple.com>
823 * Plugins/WebNetscapePluginPackage.mm:
824 (-[WebNetscapePluginPackage _tryLoad]):
826 2009-03-02 Anders Carlsson <andersca@apple.com>
828 Reviewed by John Sullivan, Ada Chan.
830 Factor loading code out into its own method and get rid of a bunch of gotos.
832 * Plugins/WebNetscapePluginPackage.mm:
833 (-[WebNetscapePluginPackage _tryLoad]):
834 (-[WebNetscapePluginPackage load]):
836 2009-03-02 Anders Carlsson <andersca@apple.com>
840 * Plugins/WebNetscapeDeprecatedFunctions.h:
842 2009-03-02 Anders Carlsson <andersca@apple.com>
844 Reviewed by John Sullivan.
846 Rename WebNetscapePluginPackage.m to WebNetscapePluginPackage.mm
848 * Plugins/WebNetscapePluginPackage.m: Removed.
849 * Plugins/WebNetscapePluginPackage.mm: Copied from mac/Plugins/WebNetscapePluginPackage.m.
851 2009-03-01 Anders Carlsson <andersca@apple.com>
853 Reviewed by Sam Weinig.
855 WebKit side of <rdar://problem/6449689>
857 Pass the visible name to the plug-in host.
859 * Plugins/Hosted/NetscapePluginHostManager.mm:
860 (WebKit::NetscapePluginHostManager::spawnPluginHost):
862 2009-02-27 Alice Liu <alice.liu@apple.com>
864 Fix <rdar://problem/6531265> REGRESSION (r39185): adding ".jpeg"
865 extension to images that already have .jpg extension
867 Reviewed by Oliver Hunt.
869 * WebView/WebHTMLView.mm:
870 (-[NSString matchesExtensionEquivalent:]):
871 (-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
872 Relax the check for the proper extension to allow for known
873 equivalents, special-cased in matchesExtensionEquivalent function.
875 2009-02-27 Anders Carlsson <andersca@apple.com>
877 Reviewed by Geoffrey Garen.
879 <rdar://problem/6631436>
880 CrashTracer: [USER] 1 crash in Safari at com.apple.WebKit • WebKit::NetscapePluginInstanceProxy::addValueToArray + 55
882 Port the NPN_Evaluate code over from WebCore instead of using the frame loader.
884 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
885 (WebKit::NetscapePluginInstanceProxy::evaluate):
887 2009-02-27 Anders Carlsson <andersca@apple.com>
889 Reviewed by Geoffrey Garen.
891 WebKit side of <rdar://problem/6626814>.
893 * Plugins/Hosted/NetscapePluginHostProxy.mm:
895 Make InvokeDefault async.
897 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
898 (WebKit::NetscapePluginInstanceProxy::addValueToArray):
899 Handle passing NPObjects back to the plug-in host.
901 * Plugins/Hosted/ProxyInstance.h:
902 (WebKit::ProxyInstance::objectID):
905 * Plugins/Hosted/WebKitPluginClient.defs:
906 Make InvokeDefault a simpleroutine.
908 2009-02-27 Timothy Hatcher <timothy@apple.com>
910 Fixes an exception by null checking the WebResource before adding it to
911 the subresources array.
913 <rdar://problem/5950769> Bug in [WebDataSource subresources] can throw an exception
915 Reviewed by Geoff Garen and Anders Carlsson.
917 * WebView/WebDataSource.mm:
918 (-[WebDataSource subresources]): Null check the WebResource before adding it.
920 2009-02-27 Timothy Hatcher <timothy@apple.com>
922 Adds a workaround for Automator creating a WebView from a secondary thread.
924 <rdar://problem/6631951> REGRESSION (Safari 4 Beta): Automator crash on
925 secondary thread beneath -[WebView initWithFrame:frameName:groupName:]
927 Reviewed by Geoff Garen.
929 * WebView/WebView.mm:
930 (needsWebViewInitThreadWorkaround): Check for com.apple.Automator.
932 2009-02-27 Adam Barth <abarth@webkit.org>
934 Reviewed by Eric Seidel.
936 Add a preference to reduce the power of file:// URLs.
938 * WebView/WebPreferenceKeysPrivate.h:
939 * WebView/WebPreferences.mm:
940 (+[WebPreferences initialize]):
941 (-[WebPreferences allowUniversalAccessFromFileUrls]):
942 (-[WebPreferences setAllowUniversalAccessFromFileUrls:]):
943 * WebView/WebPreferencesPrivate.h:
944 * WebView/WebView.mm:
945 (-[WebView _preferencesChangedNotification:]):
947 2009-02-27 Simon Fraser <simon.fraser@apple.com>
949 Reviewed by Anders Carlsson
951 https://bugs.webkit.org/show_bug.cgi?id=24242
953 setCursor(), and resetCursorRects() on Tiger, were using global, not local
954 coordinates for elementAtPoint:
956 * WebView/WebHTMLView.mm:
960 2009-02-27 Adam Barth <abarth@webkit.org>
962 Reviewed by Eric Seidel.
964 Add a preference to reduce the power of file:// URLs.
966 * WebView/WebPreferenceKeysPrivate.h:
967 * WebView/WebPreferences.mm:
968 (+[WebPreferences initialize]):
969 (-[WebPreferences allowUniversalAccessFromFileUrls]):
970 (-[WebPreferences setAllowUniversalAccessFromFileUrls:]):
971 * WebView/WebPreferencesPrivate.h:
972 * WebView/WebView.mm:
973 (-[WebView _preferencesChangedNotification:]):
975 2009-02-26 Adele Peterson <adele@apple.com>
977 Reviewed by Geoff Garen.
979 Fix for <rdar://problem/6618166>
980 https://bugs.webkit.org/show_bug.cgi?id=24216
981 (REGRESSION r36919) Safari 4 Beta causes MSN Messenger's text entry field to lose focus after entering a message
983 During a series of firstResponder changes, at some point while the WebHTMLView was losing first responder status,
984 we incorrectly marked the page as active, and then when the WebHTMLView became first responder again, setActive did nothing.
985 This change restores behavior from before r36919 to check if the WebHTMLView is in the middle of losing first responder when calling setActive.
987 In addition to updating editing/selection/designmode-no-caret.html results, I also made sure the test cases that were
988 fixed in r36919 and r38570 are still fixed.
990 * WebView/WebHTMLView.mm:
991 (-[WebHTMLView resignFirstResponder]): Keep track if we're in the process of resigning first responder.
992 (-[WebHTMLView _isResigningFirstResponder]): Added.
993 * WebView/WebHTMLViewInternal.h:
994 * WebView/WebView.mm: (-[WebView _updateFocusedAndActiveStateForFrame:]): Don't set the page to be active
995 if the document view is currently resigning first responder.
997 2009-02-25 Anders Carlsson <andersca@apple.com>
999 Reviewed by Kevin Decker.
1001 Fix <rdar://problem/6623697>.
1003 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1004 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1005 (WebKit::NetscapePluginInstanceProxy::print):
1006 Ask the plug-in host to print, create a CGImage of the returned bytes and draw
1007 the image into the passed in context.
1009 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1010 (-[WebHostedNetscapePluginView drawRect:]):
1011 When printing, call NetscapePluginInstanceProxy::print.
1013 * Plugins/Hosted/WebKitPluginHost.defs:
1015 2009-02-19 Alexey Proskuryakov <ap@webkit.org>
1017 Reviewed by Darin Adler.
1019 https://bugs.webkit.org/show_bug.cgi?id=24024
1020 REGRESSION (r39845): Assertion failure in -[WebHistoryItem dictionaryRepresentation] when
1021 archiving a submission to about:blank
1023 I don't know how to make an automated test for this bug.
1025 * History/WebHistory.mm: (-[WebHistory _visitedURL:withTitle:method:wasFailure:]):
1026 Account for the fact that HTTP method may be non-empty for non-HTTP requests.
1028 2009-02-25 Chris Fleizach <cfleizach@apple.com>
1030 Reviewed by Beth Dakin.
1033 Bug 24143: Crash occurs at WebCore::AccessibilityTable::isTableExposableThroughAccessibility() when applying a link in GMail
1034 https://bugs.webkit.org/show_bug.cgi?id=24143
1036 * WebView/WebFrame.mm:
1037 (-[WebFrame _accessibilityTree]):
1039 2009-02-25 Simon Fraser <simon.fraser@apple.com>
1041 Build fix with ACCELERATED_COMPOSITING turned on.
1043 I missed a spot in my last commit in renaming to
1044 _stoppedAcceleratedCompositingForFrame:
1046 * WebView/WebHTMLView.mm:
1047 (-[WebHTMLView close]):
1049 2009-02-25 Simon Fraser <simon.fraser@apple.com>
1051 Reviewed by Dan Bernstein
1053 https://bugs.webkit.org/show_bug.cgi?id=23854
1055 Make an observable property, _isUsingAcceleratedCompositing, on
1056 WebView that DumpRenderTree can use to specialize behavior.
1058 This is implemented via a count of Frames that are using
1059 accelerated compositing.
1061 * WebView/WebHTMLView.mm:
1062 (-[WebHTMLViewPrivate clear]):
1063 (-[WebHTMLView close]):
1064 (-[WebHTMLView attachRootLayer:]):
1065 (-[WebHTMLView detachRootLayer]):
1066 * WebView/WebView.mm:
1067 (+[WebView automaticallyNotifiesObserversForKey:]):
1068 (-[WebView _startedAcceleratedCompositingForFrame:]):
1069 (-[WebView _stoppedAcceleratedCompositingForFrame:]):
1070 (-[WebView _isUsingAcceleratedCompositing]):
1071 * WebView/WebViewInternal.h:
1072 * WebView/WebViewPrivate.h:
1074 2009-02-24 Sam Weinig <sam@webkit.org>
1076 Reviewed by Geoffrey Garen.
1078 Related to <rdar://problem/6590295>
1079 Allow disabling javascript: urls.
1081 * WebView/WebView.mm:
1082 (-[WebView _setJavaScriptURLsAreAllowed:]):
1083 * WebView/WebViewPrivate.h:
1085 2009-02-24 Mark Rowe <mrowe@apple.com>
1087 Reviewed by Oliver Hunt.
1089 <rdar://problem/6259220> Rename AVAILABLE_AFTER_WEBKIT_VERSION_3_1 (etc.) to match the other macros
1091 * Carbon/CarbonUtils.h:
1092 * Carbon/HIWebView.h:
1093 * Plugins/WebPlugin.h:
1094 * Plugins/WebPluginViewFactory.h:
1095 * WebView/WebUIDelegate.h:
1097 2009-02-24 Peter Ammon <pammon@apple.com>
1099 Reviewed by Mark Rowe.
1101 Fix <rdar://problem/6251410> Services can modify non-editable content in Safari
1103 * WebView/WebHTMLView.mm:
1104 (-[WebHTMLView validRequestorForSendType:returnType:]): Return self only if we can handle
1105 both the send and return type. We should also handle a nil send or return type by ignoring
1106 the argument and returning whether we can handle the other type passed in.
1108 2009-02-23 Anders Carlsson <andersca@apple.com>
1110 Reviewed by Geoffrey Garen and Darin Adler.
1112 WebKit side of <rdar://problem/6613151>.
1114 Make sure to vm_deallocate all memory we get from MIG callbacks.
1116 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1117 (DataDeallocator::DataDeallocator):
1118 (DataDeallocator::~DataDeallocator):
1119 Add a simple deallocator class.
1123 (WKPCBooleanAndDataReply):
1125 (WKPCGetStringIdentifier):
1127 (WKPCInvokeDefault):
1130 Use the new deallocator class.
1132 2009-02-23 Anders Carlsson <andersca@apple.com>
1134 Reviewed by Darin Adler.
1136 Fix <rdar://problem/6450656>.
1138 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1139 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1140 (WebKit::NetscapePluginInstanceProxy::insertText):
1141 Add insert text which just calls the new WKPH function.
1143 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1144 (-[WebHostedNetscapePluginView inputContext]):
1145 Get the input context from the shared input panel.
1147 (-[WebHostedNetscapePluginView keyDown:]):
1148 Let the shared input panel have a go at the event first.
1150 * Plugins/Hosted/WebKitPluginHost.defs:
1151 Add new InsertText function.
1153 2009-02-23 Mark Rowe <mrowe@apple.com>
1155 Fix the build after r41126.
1157 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1158 (WebKit::NetscapePluginInstanceProxy::invoke):
1159 (WebKit::NetscapePluginInstanceProxy::invokeDefault):
1160 (WebKit::NetscapePluginInstanceProxy::construct):
1162 2009-02-22 Dan Bernstein <mitz@apple.com>
1164 Reviewed by Darin Adler.
1166 - fix <rdar://problem/5966123> REGRESSION (r30741): Generic Sun Applet loading logo appears half off screen
1168 * WebCoreSupport/WebFrameLoaderClient.mm: Correct a copy & paste error
1169 in r30741, and assign the height value, rather than the width, to the
1172 2009-02-21 Anders Carlsson <andersca@apple.com>
1176 * Plugins/Hosted/WebTextInputWindowController.m:
1178 2009-02-20 Anders Carlsson <andersca@apple.com>
1180 Reviewed by Dan Bernstein.
1182 Add a shared floating text input window implementation, to be used by the hosted plug-in view.
1184 * Plugins/Hosted/WebTextInputWindowController.h: Added.
1185 * Plugins/Hosted/WebTextInputWindowController.m: Added.
1187 2009-02-20 Kevin Decker <kdecker@apple.com>
1189 Reviewed by andersca.
1191 <rdar://problem/6496140> Safari sometimes hangs in WKSetMetadataURL for several seconds after downloading a file
1193 Spawn a background thread for WKSetMetadataURL because this function will not return until mds has journaled the data
1194 we are trying to set. Depending on what other I/O is going on, it can take some time.
1196 * Misc/WebNSFileManagerExtras.m: Import pthread.h and FoundationExtras.h
1197 (setMetaData): Added. Calls WKSetMetadataURL().
1198 (-[NSFileManager _webkit_setMetadataURL:referrer:atPath:]): Call setMetaData on a background thread
1200 2009-02-19 Dan Bernstein <mitz@apple.com>
1202 Reviewed by Sam Weinig.
1204 - WebKit part of fixing https://bugs.webkit.org/show_bug.cgi?id=24027
1205 Do not send loader callbacks during CSS styling
1207 * WebView/WebView.mm:
1208 (-[WebView _preferencesChangedNotification:]): Reverted the
1209 iChat-specific quirk added in <http://trac.webkit.org/changeset/41071>.
1211 2009-02-18 Dan Bernstein <mitz@apple.com>
1213 Reviewed by Brady Eidson.
1215 - WebKit part of fixing <rdar://problem/6507512> Crash in iChat at CSSStyleSelector::adjustRenderStyle
1217 * WebView/WebView.mm:
1218 (-[WebView _preferencesChangedNotification:]): Activate the WebCore
1219 workaround for this crash in iChat.
1221 2009-02-18 Anders Carlsson <andersca@apple.com>
1223 Reviewed by Sam Weinig.
1225 Fix for <rdar://problem/6542390>
1227 There's no need to call setDefersLoading here - we already defer anything a plug-in can do that
1228 would cause a load to begin.
1230 * Plugins/WebNetscapePluginView.mm:
1231 (-[WebNetscapePluginView sendEvent:isDrawRect:]):
1233 2009-02-18 Adam Roben <aroben@apple.com>
1235 Add SPI to get WebKit's custom pointing-hand cursor
1237 Reviewed by John Sullivan.
1239 * WebView/WebView.mm:
1240 (+[WebView _pointingHandCursor]): Added. Returns the custom
1241 pointing-hand cursor that WebKit uses.
1242 * WebView/WebViewPrivate.h: Added +_pointingHandCursor.
1244 2009-02-17 Eric Carlson <eric.carlson@apple.com>
1246 Reviewed by Antti Koivisto.
1248 https://bugs.webkit.org/show_bug.cgi?id=23917
1249 Allow a WebKit plug-in to act as a proxy for the <audio> and <video>
1252 * Plugins/WebPluginContainerPrivate.h:
1253 * Plugins/WebPluginController.mm:
1254 (mediaProxyClient): New, cast to HTMLMediaElement if it is a video or audio element
1255 (-[WebPluginController _setMediaPlayerProxy:forElement:]): New, pass proxy to HTMLMediaElement
1256 (-[WebPluginController _postMediaPlayerNotification:forElement:]): New, deliver event to HTMLMediaElement
1258 * WebCoreSupport/WebFrameLoaderClient.mm:
1259 (WebFrameLoaderClient::createPlugin): Don't allow a media player proxy plug-in to be chosen by
1260 file extension, only want a match for the new MIME type proxy plug-ins should have.
1262 2009-02-13 Anders Carlsson <andersca@apple.com>
1264 Reviewed by Kevin Decker.
1266 <rdar://problem/6584834> ESPN radio live stream link hangs Safari
1268 When a plug-in invokes JavaScript code that will destroy the plug-in, we need to
1269 defer destruction until we're done executing the script.
1271 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1272 (WebKit::PluginDestroyDeferrer::PluginDestroyDeferrer):
1273 (WebKit::PluginDestroyDeferrer::~PluginDestroyDeferrer):
1274 Add a simple RAII object for deferring destruction of the plug-in instance.
1278 (WKPCInvokeDefault):
1282 (WKPCRemoveProperty):
1285 Use the PluginDestroyDeferrer.
1287 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1288 (WebKit::NetscapePluginInstanceProxy::pluginID):
1289 Assert that the plug-in ID is not 0 here.
1291 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1292 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
1293 Initialize the call depth.
1295 (WebKit::NetscapePluginInstanceProxy::~NetscapePluginInstanceProxy):
1296 Set the plug-in ID to 0 to aid debugging.
1298 (WebKit::NetscapePluginInstanceProxy::willCallPluginFunction):
1299 Increment the call depth.
1301 (WebKit::NetscapePluginInstanceProxy::didCallPluginFunction):
1302 Decrement the call depth, if it's 0 and we should stop the plug-in, do so.
1304 (WebKit::NetscapePluginInstanceProxy::shouldStop):
1305 If we're called this with a non-zero call depth, set shouldStopSoon to true.
1307 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1308 (-[WebHostedNetscapePluginView shouldStop]):
1311 2009-02-12 Brady Eidson <beidson@apple.com>
1313 Reviewed by Kevin Decker
1315 <rdar://problem/6582180> - Wrong HTTP method applied to history item.
1317 * WebCoreSupport/WebFrameLoaderClient.mm:
1318 (WebFrameLoaderClient::updateGlobalHistory): Check the original request, not any
1321 2009-02-12 Anders Carlsson <andersca@apple.com>
1323 Reviewed by Kevin Decker.
1325 <rdar://problem/6579412>
1326 REGRESSION (3.2.1-ToT): Crash in Silverlight viewing streaming lecture
1328 * Plugins/WebNetscapePluginView.h:
1329 * Plugins/WebNetscapePluginView.mm:
1330 (-[WebNetscapePluginView userAgent]):
1331 Apply workaround for Silverlight workaround.
1333 (-[WebNetscapePluginView _createPlugin]):
1334 Check if the plug-in that we're creating is the silverlight plug-in.
1336 2009-02-12 Brady Eidson <beidson@apple.com>
1338 Reviewed by Darin Adler
1340 Fix potential ref-count or null-deref problems with C++ objects as Obj-C members.
1342 * History/WebBackForwardList.mm:
1343 (-[WebBackForwardList dealloc]): Null check before deref()'ing.
1344 (-[WebBackForwardList finalize]): Ditto.
1346 * Misc/WebIconFetcher.mm:
1347 (-[WebIconFetcher dealloc]): Null check before deref()'ing.
1348 (-[WebIconFetcher finalize]): Ditto.
1350 * WebCoreSupport/WebEditorClient.mm: Change to use RefPtr<> instead of ref()/deref().
1351 (-[WebEditCommand initWithEditCommand:]):
1352 (-[WebEditCommand dealloc]):
1353 (-[WebEditCommand finalize]):
1354 (-[WebEditCommand command]):
1356 * WebView/WebArchive.mm: Change to use RefPtr<> instead of ref()/deref().
1357 (-[WebArchivePrivate init]):
1358 (-[WebArchivePrivate initWithCoreArchive:]):
1359 (-[WebArchivePrivate coreArchive]):
1360 (-[WebArchivePrivate setCoreArchive:]):
1361 (-[WebArchivePrivate dealloc]):
1362 (-[WebArchivePrivate finalize]):
1364 * WebView/WebDataSource.mm:
1365 (-[WebDataSourcePrivate dealloc]): Null check before deref()'ing.
1366 (-[WebDataSourcePrivate finalize]): Ditto.
1368 2009-02-12 Brady Eidson <beidson@apple.com>
1370 Reviewed by Kevin Decker
1372 <rdar://problem/6579750> - Crash in WebArchivePrivate in Tiger TextEdit
1374 NSHTMLReader tries to create a WebArchive from a random chunk of data. Previously, WebArchive creation would
1375 fail and return nil and NSHTMLReader would try something else. When we changed the behavior to return an invalid
1376 WebArchive object, things started getting weird.
1378 * WebView/WebArchive.mm:
1379 (-[WebArchivePrivate setCoreArchive:]): Null check the pointer before calling ->deref()
1380 (-[WebArchivePrivate dealloc]): Remove the ASSERT which is now invalid, and null check the pointer before ->deref().
1381 (-[WebArchivePrivate finalize]): Ditto
1382 (-[WebArchive initWithData:]): If the LegacyWebArchive cannot be created, return nil instead of an invalid object.
1384 2009-02-11 Mark Rowe <mrowe@apple.com>
1388 * History/WebHistory.mm:
1389 (-[WebHistoryPrivate visitedURL:withTitle:]): Use ASSERT_UNUSED in a manner that makes sense.
1391 2009-02-11 Brady Eidson <beidson@apple.com>
1393 Reviewed by Mark Rowe
1395 <rdar://problem/6570573> Some visit counts in History.plist have insanely high values, can roll over to negative
1397 Remove the item from the date caches before registering the visit. Otherwise it might not be successfully removed
1398 and when we add it back later it will exist in the list twice. This will cause the entry to be written out twice,
1399 which would lead to doubling (or more!) the visit count on next launch when these multiple items are merged.
1401 * History/WebHistory.mm:
1402 (-[WebHistoryPrivate visitedURL:withTitle:]): Swap the removeItemFromDateCaches and visitedWithTitle calls.
1403 (-[WebHistoryPrivate addItem:discardDuplicate:]): Add a mode that allows the entry being added to be discarded
1404 if an entry for the URL already exists. Use that mode when reading the History.plist so only the most
1405 recent entry for a given URL will be used.
1406 (-[WebHistoryPrivate addItems:]):
1407 (-[WebHistoryPrivate loadHistoryGutsFromURL:savedItemsCount:collectDiscardedItemsInto:error:]):
1409 2009-02-11 Dimitri Dupuis-latour <dupuislatour@apple.com>
1411 Added a preference to disable some Inspector's panels (rdar://6419624, rdar://6419645).
1412 This is controlled via the 'WebKitInspectorHiddenPanels' key; if nothing is specified, all panels are shown.
1414 Reviewed by Timothy Hatcher.
1416 * WebCoreSupport/WebInspectorClient.h:
1417 * WebCoreSupport/WebInspectorClient.mm:
1418 (WebInspectorClient::hiddenPanels):
1420 2009-02-11 Alexey Proskuryakov <ap@webkit.org>
1422 Reviewed by Darin Adler.
1424 <rdar://problem/6562920> Pasted text should be normalized to NFC
1426 * Misc/WebNSURLExtras.mm: (-[NSURL _web_userVisibleString]): Route the URL string through
1427 -[NSString precomposedStringWithCanonicalMapping].
1429 * WebCoreSupport/WebPasteboardHelper.mm:
1430 (WebPasteboardHelper::plainTextFromPasteboard): Ditto.
1432 * WebView/WebHTMLView.mm:
1433 (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
1434 Ditto. The affected cases are all plain text ones - RTF, RTFD and HTML are assumed to be
1435 precomposed already, and the conversion is performed outside WebKit for those anyway.
1437 2009-02-10 John Sullivan <sullivan@apple.com>
1439 Reviewed by Dan Bernstein
1441 <https://bugs.webkit.org/show_bug.cgi?id=23889>, <rdar://problem/6572300>
1442 Negative visit counts stored in History.plist aren't corrected.
1444 It's not clear how a huge negative visit count ended up in History.plist, but we can't
1445 trust data read from disk so we can at least reset this to something sane. WebCore has
1446 no guard against a visit count overflowing an int, but that seems very unlikely to have
1449 * History/WebHistoryItem.mm:
1450 (-[WebHistoryItem initFromDictionaryRepresentation:]):
1451 If a negative visit count is in the dictionary, replace it with 1. If a negative daily or
1452 weekly visit count is in the dictionary, replace it with 0.
1454 2009-02-10 John Sullivan <sullivan@apple.com>
1456 Reviewed by Dan Bernstein
1458 <https://bugs.webkit.org/show_bug.cgi?id=23891>
1459 [WebHistoryItem _setVisitCount:] is unused and should be removed
1461 * History/WebHistoryItem.mm:
1462 (-[WebHistoryItem _setVisitCount:]):
1463 removed this unused method, which is a synonym for setVisitCount: that was introduced
1464 recently and abandoned even more recently
1466 * History/WebHistoryItemInternal.h:
1467 removed declaration of _setVisitCount:
1469 2009-02-10 Anders Carlsson <andersca@apple.com>
1471 Reviewed by Mark Rowe.
1473 <rdar://problem/6573916>
1474 CrashTracer: [USER] 1 crash in Safari at com.apple.WebKit • WebKit::NetscapePluginInstanceProxy::pluginHostDied + 25.
1476 * Plugins/Hosted/NetscapePluginHostManager.mm:
1477 (WebKit::NetscapePluginHostManager::instantiatePlugin):
1478 If we failed to instantiate the plug-in, invalidate the instance proxy.
1480 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1481 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1482 (WebKit::NetscapePluginInstanceProxy::invalidate):
1483 Remove the instance from the plug-in host's set.
1485 (WebKit::NetscapePluginInstanceProxy::destroy):
1488 2009-02-09 Mark Rowe <mrowe@apple.com>
1490 Reviewed by Dan Bernstein.
1492 Fix <https://bugs.webkit.org/show_bug.cgi?id=23863> / <rdar://problem/6571390>.
1493 Bug 23863: Reproducible crash in Mail with TOT WebKit when creating a new message
1495 * WebView/WebHTMLView.mm:
1496 (-[WebHTMLView _removeMouseMovedObserverUnconditionally]): Nil-check _private as it may have not
1497 yet been initialized if this WebHTMLView was loaded from a nib.
1498 (-[WebHTMLView _removeSuperviewObservers]): Ditto.
1500 2009-02-09 Eric Seidel <eric@webkit.org>
1502 Reviewed by Dave Hyatt.
1504 Rename Selection to VisibleSelection to allow us to separate
1505 the selections the user works with from the ones used by
1506 the JS editing APIs.
1507 https://bugs.webkit.org/show_bug.cgi?id=23852
1509 * WebView/WebFrame.mm:
1510 (-[WebFrame _selectNSRange:]):
1511 * WebView/WebView.mm:
1512 (-[WebView textIteratorForRect:]):
1514 2009-02-06 Anders Carlsson <andersca@apple.com>
1516 Reviewed by Kevin Decker.
1518 Fix crash when plug-in host dies.
1520 * Plugins/Hosted/HostedNetscapePluginStream.mm:
1521 (WebKit::HostedNetscapePluginStream::didFail):
1523 2009-02-05 Eric Seidel <eric@webkit.org>
1525 Reviewed by Justin Garcia.
1527 DOMSelection.getRangeAt() returns a different range than the selection
1528 https://bugs.webkit.org/show_bug.cgi?id=23601
1530 Rename toRange to toNormalizedRange and add new firstRange which returns an unmodified range
1532 * WebView/WebFrame.mm:
1533 (-[WebFrame _rangeByAlteringCurrentSelection:SelectionController::direction:SelectionController::granularity:]):
1534 (-[WebFrame _markDOMRange]):
1535 (-[WebFrame _replaceSelectionWithText:selectReplacement:smartReplace:]):
1536 (-[WebFrame _selectedNSRange]):
1537 * WebView/WebHTMLView.mm:
1538 (-[WebHTMLView _selectedRange]):
1539 (-[WebTextCompleteController doCompletion]):
1540 (-[WebHTMLView selectedAttributedString]):
1541 * WebView/WebView.mm:
1542 (-[WebView textIteratorForRect:]):
1543 (-[WebView selectedDOMRange]):
1545 2009-02-06 Geoffrey Garen <ggaren@apple.com>
1547 Reviewed by Sam Weinig.
1549 Part III of <rdar://problem/6552272>.
1551 Refactored to use the redirect data WebCore makes available, instead of
1552 tracking loading state in WebKit.
1554 * History/WebHistory.mm:
1555 (-[WebHistoryPrivate dealloc]):
1556 (-[WebHistory _visitedURL:withTitle:method:wasFailure:]):
1557 (-[WebHistory _visitedURLForRedirectWithoutHistoryItem:]):
1558 * History/WebHistoryInternal.h:
1559 * WebCoreSupport/WebFrameLoaderClient.h:
1560 * WebCoreSupport/WebFrameLoaderClient.mm:
1561 (WebFrameLoaderClient::updateGlobalHistory):
1562 (WebFrameLoaderClient::updateGlobalHistoryRedirectLinks):
1564 2009-02-06 Anders Carlsson <andersca@apple.com>
1566 Reviewed by Sam Weinig.
1568 <rdar://problem/6562220>
1569 CrashTracer: [USER] 21 crashes in Safari at com.apple.WebKit • WebKit::NetscapePluginHostProxy::port
1571 Make the handling of crashes in the plug-in host more robust.
1573 * Plugins/Hosted/NetscapePluginHostProxy.h:
1576 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1577 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
1578 Initialize m_portSet.
1580 (WebKit::NetscapePluginHostProxy::~NetscapePluginHostProxy):
1583 (WebKit::NetscapePluginHostProxy::processRequests):
1584 Listen for messages on the port set. If we get a message to the port death notification port,
1585 then call pluginHostDied. Otherwise, process the message.
1587 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1588 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1589 (WebKit::NetscapePluginInstanceProxy::cleanup):
1590 Factor code that should be shared between destroy() and pluginHostDied() into cleanup.
1592 (WebKit::NetscapePluginInstanceProxy::destroy):
1595 (WebKit::NetscapePluginInstanceProxy::pluginHostDied):
1598 (WebKit::NetscapePluginInstanceProxy::processRequestsAndWaitForReply):
1599 Call NetscapePluginHostProxy::processRequests.
1601 * Plugins/Hosted/ProxyInstance.mm:
1602 (WebKit::ProxyInstance::invalidate):
1603 Add a null check for the host proxy.
1605 2009-02-06 Dan Bernstein <mitz@apple.com>
1607 - try to fix the Tiger build
1609 * Misc/WebNSArrayExtras.h:
1611 2009-02-06 Anders Carlsson <andersca@apple.com>
1613 Reviewed by Dan Bernstein.
1615 <rdar://problem/6563650>
1616 Add Netscape plug-in API to tell the browser not to load streams (some plug-ins handle network loading manually)
1618 * Plugins/WebNetscapePluginView.mm:
1619 (-[WebNetscapePluginView loadStream]):
1620 (-[WebNetscapePluginView pluginView:receivedData:]):
1621 (-[WebNetscapePluginView _shouldCancelSrcStream]):
1623 2009-02-05 Maciej Stachowiak <mjs@apple.com> and Brady Eidson <beidson@apple.com>
1625 Reviewed by Dan Bernstein and Geoff Garen.
1627 - WebKit code to track per-day and per-week visit counts in history
1629 For now this data is only exposed via SPI for performance reasons.
1631 * History/WebHistoryItem.mm:
1632 (-[WebHistoryItem initFromDictionaryRepresentation:]): Add parsing support
1634 (-[WebHistoryItem _recordInitialVisit]): Tell WebCore to record an initial visit.
1635 (-[WebHistoryItem dictionaryRepresentation]): Add saving support for new data.
1636 (-[WebHistoryItem _getDailyVisitCounts:]): SPI accessor.
1637 (-[WebHistoryItem _getWeeklyVisitCounts:]): SPI accessor.
1638 * History/WebHistoryItemInternal.h: Declare new methods.
1639 * History/WebHistoryItemPrivate.h: Ditto.
1641 * History/WebHistory.mm:
1642 (-[WebHistoryPrivate visitedURL:withTitle:]): For the initial visit, use
1643 the new _recordInitialVisit method instead of setting visit count to 1.
1645 * Misc/WebNSArrayExtras.h:
1646 * Misc/WebNSArrayExtras.m:
1647 (-[NSArray _webkit_numberAtIndex:]): Helper to retrieve an NSNumber or nil from an NSArray
1648 (-[NSArray _webkit_stringAtIndex:]): Helper to retrieve an NSString of nil from an NSArray
1650 2009-02-05 Aaron Boodman <aa@chromium.org>
1652 Reviewed by Dave Hyatt.
1654 https://bugs.webkit.org/show_bug.cgi?id=23708
1655 Adds documentElementAvailable() callback to FrameLoaderClient.
1657 * WebCoreSupport/WebFrameLoaderClient.h:
1658 Stub out documentElementAvailable().
1659 * WebCoreSupport/WebFrameLoaderClient.mm:
1662 2009-02-05 Dan Bernstein <mitz@apple.com>
1666 * WebView/WebScriptDebugger.mm:
1667 (WebScriptDebugger::initGlobalCallFrame):
1669 2009-02-05 Beth Dakin <bdakin@apple.com>
1671 Reviewed by John Sullivan and Brady Eidson.
1673 Fix for <rdar://problem/6557595> REGRESSION: In Mail, selecting a
1674 mail note message doesn't display it in Mail's preview pane
1676 This was failing because revision 36962 removed a version of
1677 setVerticalScrollingMode that mail calls. This patch simply adds
1680 * WebView/WebDynamicScrollBarsView.m:
1681 (-[WebDynamicScrollBarsView setVerticalScrollingMode:]):
1683 2009-02-04 Anders Carlsson <andersca@apple.com>
1687 * WebView/WebScriptDebugger.mm:
1688 (WebScriptDebugger::initGlobalCallFrame):
1690 2009-02-04 Anders Carlsson <andersca@apple.com>
1692 Reviewed by Sam Weinig.
1694 Change PCHasProperty, PCHasMethod and PCGetProperty into simpleroutines.
1696 Rename PHEvaluateReply to PHBooleanAndDataReply and add PHBooleanReply.
1698 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1704 * Plugins/Hosted/WebKitPluginClient.defs:
1705 * Plugins/Hosted/WebKitPluginHost.defs:
1707 2009-02-04 Anders Carlsson <andersca@apple.com>
1709 Reviewed by Mark Rowe.
1713 * WebView/WebScriptDebugger.mm:
1714 (WebScriptDebugger::initGlobalCallFrame):
1716 2009-02-04 Geoffrey Garen <ggaren@apple.com>
1718 Reviewed by Mark Rowe.
1720 Part I of <rdar://problem/6552272>.
1722 Clear the redirectURLs entry when first visiting a site, so sites that
1723 only redirect you the first time you visit them can later learn that
1724 they don't redirect.
1726 * History/WebHistory.mm:
1727 (-[WebHistory _visitedURL:withTitle:method:wasFailure:serverRedirectURL:isClientRedirect:]):
1729 2009-02-04 Timothy Hatcher <timothy@apple.com>
1731 Change the WebSourceId typedef from int to intptr_t now that <rdar://problem/6263297> is fixed.
1733 <rdar://problem/6263293> WebScriptDebugDelegate should use intptr_t for sourceId, not int
1735 Reviewed by Oliver Hunt.
1737 * WebView/WebScriptDebugDelegate.h:
1739 2009-02-04 Timothy Hatcher <timothy@apple.com>
1741 Switched over from using the WebSafeForwarder for the Script Debug
1742 delegate and added high performance CallScriptDebugDelegate functions.
1744 <rdar://problem/6508457> Launching widget in Dashcode debugger is
1745 super-slow due forwardInvocation: calling debug delegate
1747 Reviewed by Oliver Hunt.
1749 * DefaultDelegates/WebDefaultScriptDebugDelegate.h: Removed.
1750 * DefaultDelegates/WebDefaultScriptDebugDelegate.m: Removed.
1751 * WebView/WebScriptDebugger.mm:
1752 (WebScriptDebugger::initGlobalCallFrame): Use CallScriptDebugDelegate.
1753 (WebScriptDebugger::sourceParsed): Ditto.
1754 (WebScriptDebugger::callEvent): Ditto.
1755 (WebScriptDebugger::atStatement): Ditto.
1756 (WebScriptDebugger::returnEvent): Ditto.
1757 (WebScriptDebugger::exception): Ditto.
1758 * WebView/WebView.mm:
1759 (-[WebViewPrivate dealloc]): Removed scriptDebugDelegateForwarder.
1760 (-[WebView _cacheScriptDebugDelegateImplementations]): Added. Gets the
1761 method implementations for the script debug delegate. Also caches what
1762 didParseSource method to use.
1763 (WebViewGetScriptDebugDelegateImplementations): Added. Returns the
1764 WebScriptDebugDelegateImplementations structure.
1765 (-[WebView setScriptDebugDelegate:]): Call _cacheScriptDebugDelegateImplementations.
1766 (CallDelegate): Added more overloaded versions that take different arguments.
1767 (CallScriptDebugDelegate): Added overloaded versions that take different arguments.
1768 * WebView/WebViewInternal.h:
1770 2009-02-03 Simon Fraser <simon.fraser@apple.com>
1772 Reviewed by Dave Hyatt
1774 https://bugs.webkit.org/show_bug.cgi?id=23365
1776 Hook up accelerated compositing layers the native
1779 * WebCoreSupport/WebChromeClient.h:
1780 * WebCoreSupport/WebChromeClient.mm:
1781 (WebChromeClient::attachRootGraphicsLayer):
1782 (WebChromeClient::setNeedsOneShotDrawingSynchronization):
1783 New methods to hook up the root GraphicsLayer to the native
1784 view system, and to synchronize layer changes with view-based
1785 drawing when layers come and go.
1787 * WebView/WebHTMLView.mm:
1788 (-[WebHTMLViewPrivate clear]):
1789 Clear the pointer to layerHostingView.
1791 (-[WebHTMLView _setAsideSubviews]):
1792 (-[WebHTMLView willRemoveSubview:]):
1793 Keep the special layer-hosting view in the subviews even
1794 when the rest of the subviews are ripped out for
1797 (-[WebHTMLView _isUsingAcceleratedCompositing]):
1798 New utility method for DumpRenderTree to know if we're
1801 (-[WebHTMLView drawRect:]):
1802 Call -disableScreenUpdatesUntilFlush if we have to
1803 synchronize layer changes with painting.
1805 (-[WebHTMLView attachRootLayer:]):
1806 (-[WebHTMLView detachRootLayer]):
1807 Attach and detach the root GraphicsLayer.
1809 * WebView/WebViewInternal.h:
1810 * WebView/WebHTMLViewInternal.h:
1811 * WebView/WebHTMLViewPrivate.h:
1812 New method declarations.
1814 * WebView/WebView.mm:
1815 (-[WebView _needsOneShotDrawingSynchronization]):
1816 (-[WebView _setNeedsOneShotDrawingSynchronization:]):
1817 Set the flag to say if we need to synchronize layer
1818 changes and painting on the next -drawRect: call.
1820 (-[WebView viewWillMoveToWindow:]):
1821 (-[WebView viewDidMoveToWindow]):
1822 Call new notifications that the view was added to or removed from
1823 the window, which are required by the layer hosting mechanism.
1825 2009-02-02 Geoffrey Garen <ggaren@apple.com>
1829 * Plugins/WebPluginController.mm:
1830 (-[WebPluginController webPlugInContainerLoadRequest:inFrame:]):
1832 2009-02-02 Geoffrey Garen <ggaren@apple.com>
1834 Reviewed by Sam Weinig.
1836 Track redirects in global history.
1838 * History/WebHistory.mm:
1839 (-[WebHistoryPrivate dealloc]):
1840 (-[WebHistoryPrivate lastVisitedEntry]):
1841 (-[WebHistoryPrivate setLastVisitedEntry:]): Remember the last global history
1842 entry in case we're asked to add redirect information to it later.
1844 (-[WebHistory _visitedURL:withTitle:method:wasFailure:serverRedirectURL:isClientRedirect:]):
1845 (-[WebHistory _visitedURLForRedirectWithoutHistoryItem:]): Record redirect
1846 information in global history.
1848 * History/WebHistoryInternal.h:
1849 * WebCoreSupport/WebFrameLoaderClient.h: See above and below.
1851 * WebCoreSupport/WebFrameLoaderClient.mm:
1852 (WebFrameLoaderClient::updateGlobalHistory):
1853 (WebFrameLoaderClient::updateGlobalHistoryForRedirectWithoutHistoryItem): Record redirect
1854 information in global history.
1856 * WebView/WebFrame.mm:
1857 (-[WebFrame loadRequest:]):
1858 (-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]):
1859 * WebView/WebFramePrivate.h: Updated for rename and extra parameter.
1861 2009-02-02 Anders Carlsson <andersca@apple.com>
1863 Reviewed by Dan Bernstein.
1865 Work around a limitation in MIG where two functions can't have the same name even if they're
1866 not in the same subsystem.
1868 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1869 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
1870 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1871 (WebKit::NetscapePluginInstanceProxy::processRequestsAndWaitForReply):
1872 * Plugins/Hosted/WebKitPluginClient.defs:
1873 * Plugins/Hosted/WebKitPluginHost.defs:
1875 2009-02-02 Anders Carlsson <andersca@apple.com>
1877 Reviewed by Sam Weinig.
1879 Implement WKPCGetPluginElementObject.
1881 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1882 (WKPCGetPluginElementNPObject):
1883 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1884 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1885 (WebKit::NetscapePluginInstanceProxy::getPluginElementNPObject):
1886 * Plugins/Hosted/WebKitPluginClient.defs:
1887 * Plugins/WebBaseNetscapePluginView.h:
1888 * Plugins/WebBaseNetscapePluginView.mm:
1889 (-[WebBaseNetscapePluginView WebCore::]):
1891 2009-02-02 Anders Carlsson <andersca@apple.com>
1895 * WebView/WebHTMLView.mm:
1897 2009-02-02 Anders Carlsson <andersca@apple.com>
1899 Reviewed by Dan Bernstein.
1901 Make WebBaseNetscapePluginView hold a reference to a HTMLPlugInElement instead of a DOMElement.
1903 * Plugins/Hosted/WebHostedNetscapePluginView.h:
1904 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1905 (-[WebHostedNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:element:WebCore::]):
1906 * Plugins/WebBaseNetscapePluginView.h:
1907 * Plugins/WebBaseNetscapePluginView.mm:
1908 (-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:element:WebCore::]):
1909 (-[WebBaseNetscapePluginView _windowClipRect]):
1910 (-[WebBaseNetscapePluginView visibleRect]):
1911 (-[WebBaseNetscapePluginView dataSource]):
1912 * Plugins/WebKitPluginContainerView.h: Removed.
1913 * Plugins/WebKitPluginContainerView.mm: Removed.
1914 * Plugins/WebNetscapePluginView.h:
1915 * Plugins/WebNetscapePluginView.mm:
1916 (-[WebNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:element:WebCore::]):
1917 (-[WebNetscapePluginView getVariable:value:]):
1918 * WebCoreSupport/WebFrameLoaderClient.mm:
1919 (WebFrameLoaderClient::createPlugin):
1921 2009-02-02 Anders Carlsson <andersca@apple.com>
1923 Reviewed by Dan Bernstein.
1925 Update for changes to WebCore.
1927 * WebCoreSupport/WebFrameLoaderClient.h:
1928 * WebCoreSupport/WebFrameLoaderClient.mm:
1929 (WebFrameLoaderClient::createPlugin):
1931 2009-02-02 Anders Carlsson <andersca@apple.com>
1933 Reviewed by Oliver Hunt.
1935 When a new Web View was not created, report back to the plug-in host.
1937 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1938 (WebKit::NetscapePluginInstanceProxy::performRequest):
1939 * Plugins/Hosted/WebKitPluginHost.defs:
1941 2009-02-02 Anders Carlsson <andersca@apple.com>
1943 Reviewed by Kevin Decker.
1945 Draw the regular missing plug-in icon instead of a red rect when a plug-in has crashed.
1947 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1948 (-[WebHostedNetscapePluginView drawRect:]):
1950 2009-02-02 Holger Hans Peter Freyther <zecke@selfish.org>
1952 Reviewed by Darin Adler.
1954 Move Frame::forceLayout, Frame::adjustPageHeight and Frame::forceLayoutWithPageWidthRange to FrameView
1956 https://bugs.webkit.org/show_bug.cgi?id=23428
1958 FrameView::forceLayout could be killed but the comment might
1959 contain a value over the the plain FrameView::layout...
1961 Adjust the WebCore/WebKit consumers of these methods.
1963 * WebView/WebFrame.mm:
1964 (-[WebFrame _computePageRectsWithPrintWidthScaleFactor:printHeight:]):
1965 * WebView/WebHTMLView.mm:
1966 (-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]):
1967 (-[WebHTMLView adjustPageHeightNew:top:bottom:limit:]):
1969 2009-01-31 John Sullivan <sullivan@apple.com>
1971 https://bugs.webkit.org/show_bug.cgi?id=23665
1973 Cleaned up code to add/remove NSNotification observers, to avoid performance hit
1974 of calling removeObserver with unspecified notifications, or calling removeObserver
1975 multiple times for the same notification.
1977 Reviewed by Darin Adler
1979 * WebView/WebHTMLView.mm:
1980 added observingMouseMovedNotifications, observingSuperviewNotifications, and
1981 observingWindowNotifications as BOOL ivars of _private object
1982 (-[WebHTMLView _removeMouseMovedObserverUnconditionally]):
1983 moved to file-internal section of file, added leading underscore, now bails out
1984 if we aren't observing the relevant notifications, now records that we are no longer
1985 observing the relevant notifications
1986 (-[WebHTMLView _removeSuperviewObservers]):
1987 ditto, also stores [NSNoticationCenter defaultCenter] in local var to avoid objc dispatch
1988 (-[WebHTMLView _removeWindowObservers]):
1990 (-[WebHTMLView close]):
1991 replace general removeObserver: call with three specific calls for all the notifications
1992 that this class actually observes
1993 (-[WebHTMLView addMouseMovedObserver]):
1994 bail out if already observing relevant notifications, now records that we are observing
1995 the relevant notifications
1996 (-[WebHTMLView removeMouseMovedObserver]):
1997 updated for name change
1998 (-[WebHTMLView addSuperviewObservers]):
1999 bail out if already observing relevant notifications, now records that we are observing
2000 the relevant notifications; also stores [NSNoticationCenter defaultCenter] in local var
2001 to avoid objc dispatch
2002 (-[WebHTMLView addWindowObservers]):
2004 (-[WebHTMLView viewWillMoveToSuperview:]):
2005 updated for name change
2006 (-[WebHTMLView viewWillMoveToWindow:]):
2007 updated for name changes
2009 2009-01-31 Darin Adler <darin@apple.com>
2011 Reviewed by Mark Rowe.
2013 Fix code that assumes all command selectors end in colons.
2014 rdar://problem/6545874
2016 * WebView/WebHTMLView.mm:
2017 (commandNameForSelector): Don't assert, just return a null string, when
2018 the selector doesn't end in a colon.
2020 2009-01-30 Adam Barth <abarth@webkit.org>
2022 Reviewed by Sam Weinig.
2024 Add a pref to disable web security.
2026 * WebView/WebPreferenceKeysPrivate.h:
2027 * WebView/WebPreferencesPrivate.h:
2028 * WebView/WebPreferences.mm:
2029 (+[WebPreferences initialize]):
2030 (-[WebPreferences isWebSecurityEnabled]):
2031 (-[WebPreferences setWebSecurityEnabled:]):
2032 * WebView/WebView.mm:
2033 (-[WebView _preferencesChangedNotification:]):
2035 2009-01-30 Holger Hans Peter Freyther <zecke@selfish.org>
2037 Reviewed by Darin Adler.
2039 Move Frame::sendResizeEvent and Frame::sendScrollEvent to EventHandler
2041 Carry out the move and catch up in two call sites.
2043 * WebView/WebHTMLView.mm:
2044 (-[WebHTMLView _frameOrBoundsChanged]):
2046 2009-01-30 Holger Hans Peter Freyther <zecke@selfish.org>
2048 Reviewed by Darin Adler.
2050 isFrameSet was moved from Frame to Document. Update the
2053 * WebView/WebFrame.mm:
2054 (-[WebFrame _isFrameSet]):
2055 * WebView/WebHTMLView.mm:
2056 (-[WebHTMLView knowsPageRange:]):
2058 2009-01-30 Geoffrey Garen <ggaren@apple.com>
2062 * WebView/WebFramePrivate.h:
2064 2009-01-30 Geoffrey Garen <ggaren@apple.com>
2066 Reviewed by Sam Weinig.
2068 Split "lockHistory" into "lockHistory" and "lockBackForwardList" in
2069 preparation for setting them differently during a redirect.
2071 * WebView/WebPDFView.mm:
2072 (-[WebPDFView PDFViewWillClickOnLink:withURL:]):
2074 2009-01-30 Anders Carlsson <andersca@apple.com>
2076 Reviewed by Sam Weinig.
2078 Fix <rdar://problem/6544048>
2080 Have NetscapePluginInstanceProxy keep track of all the ProxyInstance objects associated.
2082 When the plug-in instance is destroyed, invalidate all proxy instances.
2084 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2085 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2086 (WebKit::NetscapePluginInstanceProxy::destroy):
2087 (WebKit::NetscapePluginInstanceProxy::addInstance):
2088 (WebKit::NetscapePluginInstanceProxy::removeInstance):
2089 * Plugins/Hosted/ProxyInstance.h:
2090 * Plugins/Hosted/ProxyInstance.mm:
2091 (WebKit::ProxyInstance::ProxyInstance):
2092 (WebKit::ProxyInstance::~ProxyInstance):
2093 (WebKit::ProxyInstance::invalidate):
2095 2009-01-30 Anders Carlsson <andersca@apple.com>
2097 Reviewed by Sam Weinig.
2099 Fix <rdar://problem/6490778>.
2101 Change the NPRuntime related functions to use IdentifierRep directly, and make sure to always
2102 validate IdentifierReps before dereferencing them.
2104 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2106 (WKPCGetStringIdentifier):
2107 (WKPCGetIntIdentifier):
2108 (identifierFromIdentifierRep):
2112 (WKPCRemoveProperty):
2115 (WKPCIdentifierInfo):
2117 2009-01-30 Brady Eidson <beidson@apple.com>
2119 Reviewed by Sam Weinig
2121 Remove FrameLoaderClient code that is now handled by FrameLoader itself
2123 * WebCoreSupport/WebFrameLoaderClient.mm:
2124 (WebFrameLoaderClient::frameLoadCompleted):
2126 2009-01-29 Stephanie Lewis <slewis@apple.com>
2130 Update the order files.
2134 2009-01-29 Sam Weinig <sam@webkit.org>
2136 Reviewed by Anders Carlsson.
2138 Second step in tracking the urls a HistoryItem was redirected through
2139 Add SPI to access the array of redirect urls associated with a HistoryItem.
2141 * History/WebHistoryItem.mm:
2142 (-[WebHistoryItem dictionaryRepresentation]):
2143 (-[WebHistoryItem _redirectURLs]):
2144 * History/WebHistoryItemPrivate.h:
2146 2009-01-29 Anders Carlsson <andersca@apple.com>
2148 Reviewed by Dan Bernstein.
2150 Always activate the plug-in host process if we're in "modal mode" and are being told to activate.
2152 * Plugins/Hosted/NetscapePluginHostProxy.h:
2153 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2154 (WebKit::NetscapePluginHostProxy::pluginHostDied):
2157 (WebKit::NetscapePluginHostProxy::applicationDidBecomeActive):
2158 If we're modal, we should always bring the plug-in host process to the front.
2160 (WebKit::NetscapePluginHostProxy::beginModal):
2161 Add an observer for the NSApplicationWillBecomeActiveNotification callback.
2163 (WebKit::NetscapePluginHostProxy::endModal):
2164 Remove the observer.
2166 2009-01-29 Sam Weinig <sam@webkit.org>
2168 Reviewed by Mark Rowe.
2170 First step in tracking the urls a HistoryItem was redirected through.
2172 * History/WebHistoryItem.mm:
2173 (-[WebHistoryItem initFromDictionaryRepresentation:]):
2174 (-[WebHistoryItem dictionaryRepresentation]):
2175 * Misc/WebNSDictionaryExtras.h:
2176 * Misc/WebNSDictionaryExtras.m:
2177 (-[NSDictionary _webkit_arrayForKey:]): Add helper.
2179 2009-01-29 Anders Carlsson <andersca@apple.com>
2181 Reviewed by Sam Weinig.
2183 Pass the PSN of the client to the host, and get the PSN of the host back when checking in.
2185 * Plugins/Hosted/NetscapePluginHostManager.h:
2186 * Plugins/Hosted/NetscapePluginHostManager.mm:
2187 (WebKit::NetscapePluginHostManager::hostForPackage):
2188 Get the current PSN and pass it to spawnPluginHost.
2190 (WebKit::NetscapePluginHostManager::spawnPluginHost):
2191 Pass the PSN to the "check in" function.
2193 * Plugins/Hosted/NetscapePluginHostProxy.h:
2194 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2195 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
2197 (WebKit::NetscapePluginHostProxy::pluginHostDied):
2198 Fix a bug noticed by Julien Chaffraix. Call endModal if necessary.
2200 (WebKit::NetscapePluginHostProxy::beginModal):
2201 (WebKit::NetscapePluginHostProxy::endModal):
2202 (WebKit::NetscapePluginHostProxy::setModal):
2203 Split out the code that does all of the work into beginModal and endModal methods.
2205 * Plugins/Hosted/WebKitPluginHost.defs:
2206 * Plugins/WebNetscapePluginView.mm:
2207 (-[WebNetscapePluginView loadStream]):
2209 2009-01-29 David Kilzer <ddkilzer@apple.com>
2211 Remove semi-colons from the end of ObjC method implementations
2213 Rubber-stamped by Adam Roben.
2215 $ find WebKit -name \*.m -o -name \*.mm -exec perl -e 'undef $/; $s = <>; while ($s =~ m/[\n\r][-+].*;[\s\r\n]+\{/g) { print "$ARGV: $&\n"; }' {} \;
2217 * DefaultDelegates/WebDefaultUIDelegate.m:
2218 (-[WebDefaultUIDelegate webView:setResizable:]):
2219 (-[WebDefaultUIDelegate webView:dragDestinationActionMaskForDraggingInfo:]):
2220 (-[WebDefaultUIDelegate webView:dragSourceActionMaskForPoint:]):
2221 (-[WebDefaultUIDelegate webView:willPerformDragSourceAction:fromPoint:withPasteboard:]):
2222 * History/WebBackForwardList.mm:
2223 (-[WebBackForwardList addItem:]):
2224 (-[WebBackForwardList backListWithLimit:]):
2225 (-[WebBackForwardList forwardListWithLimit:]):
2226 * History/WebHistoryItem.mm:
2227 (-[WebHistoryItem alternateTitle]):
2228 (-[WebHistoryItem setViewState:]):
2229 * Misc/WebCoreStatistics.mm:
2230 (+[WebCoreStatistics garbageCollectJavaScriptObjectsOnAlternateThreadForDebugging:]):
2231 * Misc/WebKitNSStringExtras.m:
2232 (-[NSString _web_drawAtPoint:font:textColor:]):
2233 * Plugins/WebNetscapePluginView.mm:
2234 (-[WebNetscapePluginView setAttributeKeys:andValues:]):
2235 * WebCoreSupport/WebEditorClient.mm:
2236 (-[WebEditCommand command]):
2237 * WebView/WebFrame.mm:
2238 (-[WebFrame _getVisibleRect:]):
2239 * WebView/WebHTMLRepresentation.mm:
2240 (-[WebHTMLRepresentation _redirectDataToManualLoader:forPluginView:]):
2241 * WebView/WebHTMLView.mm:
2242 (-[WebHTMLView elementAtPoint:allowShadowContent:]):
2243 * WebView/WebPreferences.mm:
2244 (-[WebPreferences setAllowsAnimatedImages:]):
2245 (-[WebPreferences setAutosaves:]):
2246 (-[WebPreferences PDFDisplayMode]):
2247 * WebView/WebView.mm:
2248 (+[WebView _viewClass:andRepresentationClass:forMIMEType:]):
2249 (-[WebView _viewClass:andRepresentationClass:forMIMEType:]):
2250 (+[WebView _unregisterViewClassAndRepresentationClassForMIMEType:]):
2251 (+[WebView _registerViewClass:representationClass:forURLScheme:]):
2252 (-[WebView _shouldChangeSelectedDOMRange:toDOMRange:affinity:stillSelecting:]):
2253 (-[WebView _insertNewlineInQuotedContent]):
2255 2009-01-28 Geoffrey Garen <ggaren@apple.com>
2257 Reviewed by Sam Weinig.
2259 Updated for WebCore rename.
2261 * WebView/WebView.mm:
2262 (-[WebView setCustomTextEncodingName:]):
2264 2009-01-28 David Kilzer <ddkilzer@apple.com>
2266 Add missing declaration for -[NSURL(WebNSURLExtras) _webkit_isFileURL]
2268 Reviewed by Dan Bernstein.
2270 * Misc/WebNSURLExtras.h:
2271 (-[NSURL(WebNSURLExtras) _webkit_isFileURL]): Added missing
2272 declaration after the implementation was added in r9258.
2274 2009-01-28 Sam Weinig <sam@webkit.org>
2276 Reviewed by Geoff Garen.
2278 Fix for <rdar://problem/6129678>
2279 REGRESSION (Safari 3-4): Local variable not accessible from Dashcode console or variables view
2281 * WebView/WebScriptDebugDelegate.mm:
2282 (-[WebScriptCallFrame scopeChain]): Wrap JSActivations in DebuggerActivations.
2284 2009-01-27 Anders Carlsson <andersca@apple.com>
2286 Reviewed by Oliver Hunt.
2288 Fix two bugs with Core Animation based plug-ins.
2290 1. The plug-in view was marked as opaque even though it's not.
2291 (This would leave garbage in the plug-in view).
2292 2. The plug-in layer needs to have autoresizing turned on.
2294 * Plugins/WebNetscapePluginView.mm:
2295 (-[WebNetscapePluginView setLayer:]):
2297 2009-01-27 Brady Eidson <beidson@apple.com>
2299 Reviewed by Dan Bernstein
2301 Rework FrameLoaderClient to work on a CachedFrame basis instead of CachedPage
2303 * History/WebHistoryItem.mm:
2305 * WebCoreSupport/WebFrameLoaderClient.h:
2306 * WebCoreSupport/WebFrameLoaderClient.mm:
2307 (WebFrameLoaderClient::savePlatformDataToCachedFrame):
2308 (WebFrameLoaderClient::transitionToCommittedFromCachedFrame):
2311 2009-01-26 Anders Carlsson <andersca@apple.com>
2313 Reviewed by Dan Bernstein.
2315 Add the ability for plug-ins to make WebKit operate in "modal mode"
2317 * Plugins/Hosted/NetscapePluginHostProxy.h:
2318 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2319 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
2320 (WebKit::NetscapePluginHostProxy::pluginHostDied):
2321 If the plug-in crashes while we're modal, make sure to leave the modal mode.
2323 (WebKit::NetscapePluginHostProxy::setModal):
2325 * Plugins/Hosted/WebKitPluginClient.defs:
2327 2009-01-26 John Sullivan <sullivan@apple.com>
2329 fixed <rdar://problem/6530053> REGRESSION (Leopard): Shift-tab in http authentication window gets
2330 stuck in the Name field rather than cycling around
2332 Reviewed by Dan Bernstein
2334 * Panels/English.lproj/WebAuthenticationPanel.nib/designable.nib:
2335 * Panels/English.lproj/WebAuthenticationPanel.nib/keyedobjects.nib:
2336 The two static text fields and the last button all had their "next key view" outlets set to the
2337 name field, which caused shift-tab from the name field to do the wrong thing. Fixed by making each
2338 selectable view have exactly one "next key view" set to it.
2340 2009-01-26 Anders Carlsson <andersca@apple.com>
2342 Reviewed by Sam Weinig.
2344 Add the ability for a plug-in to show or hide the menu bar.
2346 * Plugins/Hosted/NetscapePluginHostProxy.h:
2347 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2348 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
2349 (WebKit::NetscapePluginHostProxy::pluginHostDied):
2350 (WebKit::NetscapePluginHostProxy::setMenuBarVisible):
2351 (WKPCSetMenuBarVisible):
2352 * Plugins/Hosted/WebKitPluginClient.defs:
2354 2009-01-26 Cameron Zwarich <cwzwarich@uwaterloo.ca>
2356 Reviewed by Gavin Barraclough.
2358 Bug 23552: Dashcode evaluator no longer works after making ExecStates actual call frames
2359 <https://bugs.webkit.org/show_bug.cgi?id=23552>
2360 <rdar://problem/6398839>
2362 Dashcode will crash when using the evaluator because it saves a global call
2363 frame, even after global code has finished executing, and then uses this as
2364 a launching pad to execute new JS in the evaluator. The fix is to detect
2365 when Dashcode is attempting to do this and execute code from a global call
2368 * ForwardingHeaders/runtime/Protect.h: Added.
2369 * WebView/WebScriptDebugDelegate.mm:
2370 (-[WebScriptCallFrame _initWithGlobalObject:debugger:caller:debuggerCallFrame:]):
2371 Added debugger, a WebScriptDebugger* argument.
2372 (-[WebScriptCallFrame evaluateWebScript:]): Detect when Dashcode is using
2373 a stale WebScriptCallFrame to execute new JS and evaluate it starting from
2374 the global object's global call frame instead.
2375 * WebView/WebScriptDebugger.h:
2376 (WebScriptDebugger::globalObject): Added.
2377 (WebScriptDebugger::globalCallFrame): Added.
2378 * WebView/WebScriptDebugger.mm:
2379 (WebScriptDebugger::WebScriptDebugger): Initialize m_globalObject.
2380 (WebScriptDebugger::initGlobalCallFrame): Created as a clone of callEvent
2381 so that the global call frame can be saved immediately after being created.
2382 (WebScriptDebugger::callEvent): Pass 'this' as the debugger argument of
2383 WebScriptCallFrame's _initWithGlobalObject method.
2385 2009-01-26 Anders Carlsson <andersca@apple.com>
2387 Reviewed by Oliver Hunt.
2389 Make WKPCInvoke a simpleroutine.
2391 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2393 * Plugins/Hosted/WebKitPluginClient.defs:
2395 2009-01-26 Anders Carlsson <andersca@apple.com>
2397 Reviewed by Sam Weinig.
2399 Implement using plug-in objects as constructors, and setting and getting properties from a plug-in object.
2401 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2402 (WKPCBooleanAndDataReply):
2403 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2404 (WebKit::NetscapePluginInstanceProxy::Reply::):
2405 (WebKit::NetscapePluginInstanceProxy::BooleanAndDataReply::BooleanAndDataReply):
2406 Rename NPObjectInvokeReply to BooleanAndDataReply.
2408 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2409 (WebKit::NetscapePluginInstanceProxy::addValueToArray):
2410 Fix a cut and paste error.
2412 (WebKit::NetscapePluginInstanceProxy::demarshalValueFromArray):
2415 * Plugins/Hosted/ProxyInstance.h:
2416 * Plugins/Hosted/ProxyInstance.mm:
2417 (WebKit::ProxyField::valueFromInstance):
2418 (WebKit::ProxyField::setValueToInstance):
2419 Call the ProxyInstance method.
2421 (WebKit::ProxyInstance::~ProxyInstance):
2422 Release the NPObject.
2424 (WebKit::ProxyInstance::supportsConstruct):
2425 Ask the plug-in host if an instance supports construct.
2427 (WebKit::ProxyInstance::fieldValue):
2428 (WebKit::ProxyInstance::setFieldValue):
2429 Call the plug-in host methods.
2431 * Plugins/Hosted/WebKitPluginHostTypes.h:
2432 Rename ObjectValueType to JSObjectValueType, and add NPObjectValueType.
2434 2009-01-26 Mark Rowe <mrowe@apple.com>
2438 Remove -Wformat=2 from the warning flags as newer versions of GCC emit
2439 warnings about non-literal format strings for uses of our UI_STRING macro.
2441 * Configurations/Base.xcconfig:
2443 2009-01-26 Mark Rowe <mrowe@apple.com>
2445 Rubber-stamped by Sam Weinig.
2447 Clean up after r40240.
2449 * Configurations/Base.xcconfig: Don't dead code strip in debug builds for now as it leads to link errors.
2450 * Plugins/Hosted/HostedNetscapePluginStream.mm: Revert change that is no longer needed now that WebKitPluginHost.defs
2451 is back in the build.
2453 2009-01-25 Darin Adler <darin@apple.com>
2455 * Plugins/Hosted/HostedNetscapePluginStream.mm: Added a missing extern "C".
2457 2009-01-25 Darin Adler <darin@apple.com>
2459 Discussed with Mark Rowe; not sure he reviewed it.
2461 * Configurations/Base.xcconfig: Add all the same warnings as in WebCore except for
2462 -Wcast-qual and -Wunused-parameter, which both need to be off at least for now.
2464 2009-01-25 Mark Rowe <mrowe@apple.com>
2466 Rubber-stamped by Dan Bernstein.
2468 Improve the consistency of settings in our .xcconfig files.
2470 * Configurations/Base.xcconfig: Only dead code strip the normal variant.
2471 Handle all cases in GCC_GENERATE_DEBUGGING_SYMBOLS.
2473 2009-01-25 Darin Adler <darin@apple.com>
2475 Reviewed by Sam Weinig.
2477 Bug 23522: use checked casts for render tree
2478 https://bugs.webkit.org/show_bug.cgi?id=23522
2480 Step one: RenderText.
2482 * WebView/WebRenderNode.mm:
2483 (copyRenderNode): Use toRenderText.
2485 2009-01-23 Brady Eidson <beidson@apple.com>
2487 Rubberstamped by Darin Adler
2489 Rename CachedPagePlatformData to CachedFramePlatformData to more accurately reflect its true role.
2491 * WebCoreSupport/WebCachedFramePlatformData.h: Copied from WebKit/mac/WebCoreSupport/WebCachedPagePlatformData.h.
2492 (WebCachedFramePlatformData::WebCachedFramePlatformData):
2493 * WebCoreSupport/WebCachedPagePlatformData.h: Removed.
2495 * WebCoreSupport/WebFrameLoaderClient.mm:
2496 (WebFrameLoaderClient::savePlatformDataToCachedPage):
2497 (WebFrameLoaderClient::transitionToCommittedFromCachedPage):
2501 2009-01-23 Adele Peterson <adele@apple.com>
2505 Use new linesBoundingBox method instead of
2506 boundingBoxWidth and boundingBoxHeight for RenderText objects.
2508 * WebView/WebRenderNode.mm: (copyRenderNode):
2510 2009-01-23 Anders Carlsson <andersca@apple.com>
2514 * Plugins/Hosted/ProxyInstance.mm:
2515 (WebKit::proxyClass):
2517 2009-01-23 Anders Carlsson <andersca@apple.com>
2521 * Configurations/Base.xcconfig:
2523 2009-01-23 Anders Carlsson <andersca@apple.com>
2525 Reviewed by Sam Weinig.
2527 Turn on -Wmissing-prototypes and fix the resulting warnings.
2529 * Configurations/Base.xcconfig:
2530 * History/WebHistory.mm:
2531 (timeIntervalForBeginningOfDay):
2532 * History/WebHistoryItem.mm:
2533 (historyItemWrappers):
2534 * Misc/WebNSPasteboardExtras.mm:
2536 * WebView/WebFrame.mm:
2537 * WebView/WebScriptDebugger.mm:
2540 2009-01-22 Mark Rowe <mrowe@apple.com>
2542 Rubber-stamped by Anders Carlsson.
2544 Disable GCC_WARN_ABOUT_MISSING_PROTOTYPES temporarily.
2546 Current versions of Xcode only respect it for C and Objective-C files,
2547 and our code doesn't currently compile if it is applied to C++ and
2548 Objective-C++ files.
2550 * Configurations/Base.xcconfig:
2552 2009-01-22 Anders Carlsson <andersca@apple.com>
2554 Reviewed by Sam Weinig.
2556 Add support for Invoke and InvokeDefault. Clean up code.
2558 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2560 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2561 (WebKit::NetscapePluginInstanceProxy::Reply::):
2562 (WebKit::NetscapePluginInstanceProxy::BooleanReply::BooleanReply):
2563 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2564 (WebKit::NetscapePluginInstanceProxy::demarshalValueFromArray):
2565 * Plugins/Hosted/ProxyInstance.h:
2566 * Plugins/Hosted/ProxyInstance.mm:
2567 (WebKit::ProxyInstance::invoke):
2568 (WebKit::ProxyInstance::invokeMethod):
2569 (WebKit::ProxyInstance::supportsInvokeDefaultMethod):
2570 (WebKit::ProxyInstance::invokeDefaultMethod):
2571 (WebKit::ProxyInstance::methodsNamed):
2572 (WebKit::ProxyInstance::fieldNamed):
2573 * Plugins/Hosted/WebKitPluginClient.defs:
2574 * Plugins/Hosted/WebKitPluginHost.defs:
2575 * Plugins/Hosted/WebKitPluginHostTypes.h:
2577 2009-01-22 Eric Roman <eroman@chromium.og>
2579 Reviewed by Eric Seidel.
2581 https://bugs.webkit.org/show_bug.cgi?id=20806
2582 Deprecate RSSFeedReferrer() and setRSSFeedReferrer().
2584 * History/WebHistoryItem.mm:
2585 (-[WebHistoryItem RSSFeedReferrer]):
2586 (-[WebHistoryItem setRSSFeedReferrer:]):
2588 2009-01-22 Anders Carlsson <andersca@apple.com>
2590 Reviewed by Kevin Decker.
2592 Don't crash or hang when we fail to instantiate a plug-in.
2594 * Plugins/Hosted/NetscapePluginHostManager.mm:
2595 (WebKit::NetscapePluginHostManager::instantiatePlugin):
2596 Return 0 on failure.
2598 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
2599 (-[WebHostedNetscapePluginView JSC::Bindings::createPluginBindingsInstance:JSC::Bindings::]):
2600 Null check for the proxy member.
2602 2009-01-21 David Hyatt <hyatt@apple.com>
2604 Devirtualize width/height/x/y on RenderObject and move the methods to RenderBox.
2606 Reviewed by Eric Seidel and Darin Adler
2608 * WebView/WebRenderNode.mm:
2611 2009-01-21 Anders Carlsson <andersca@apple.com>
2613 Reviewed by Sam Weinig.
2615 More browser->plug-in scripting support.
2617 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2618 (WKPCNPObjectHasPropertyReply):
2619 (WKPCNPObjectHasMethodReply):
2620 (WKPCNPObjectInvokeReply):
2621 MIG reply functions.
2623 (WKPCIdentifierInfo):
2624 Return information about an identifier given its 64-bit value.
2626 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2627 Add new reply structs.
2629 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2630 (WebKit::NetscapePluginInstanceProxy::addValueToArray):
2631 Split out code that adds values to the arrays from marshalValue.
2633 (WebKit::NetscapePluginInstanceProxy::marshalValue):
2634 Call addValueToArray.
2636 (WebKit::NetscapePluginInstanceProxy::marshalValues):
2637 Marshal a list of values.
2639 (WebKit::NetscapePluginInstanceProxy::createBindingsInstance):
2640 Actually create a proxy instance.
2642 * Plugins/Hosted/ProxyInstance.h:
2643 * Plugins/Hosted/ProxyInstance.mm:
2644 (WebKit::ProxyClass::methodsNamed):
2645 (WebKit::ProxyClass::fieldNamed):
2646 Add a proxy ProxyClass class that just forwards everything to the ProxyInstance class.
2648 (WebKit::proxyClass):
2649 Shared proxyClass getter.
2651 (WebKit::ProxyField::ProxyField):
2652 (WebKit::ProxyField::valueFromInstance):
2653 (WebKit::ProxyField::setValueToInstance):
2654 Add a proxy ProxyField class that just forwards everything to the ProxyInstance class.
2656 (WebKit::ProxyMethod::ProxyMethod):
2657 (WebKit::ProxyMethod::serverIdentifier):
2658 (WebKit::ProxyMethod::numParameters):
2659 Add a dummy ProxyMethod class.
2661 (WebKit::ProxyInstance::invokeMethod):
2662 Call _WKPHNPObjectInvoke.
2664 (WebKit::ProxyInstance::defaultValue):
2665 (WebKit::ProxyInstance::stringValue):
2666 (WebKit::ProxyInstance::numberValue):
2667 (WebKit::ProxyInstance::booleanValue):
2668 (WebKit::ProxyInstance::valueOf):
2669 Add dummy implementations (taken from CInstance).
2671 (WebKit::ProxyInstance::methodsNamed):
2672 Call _WKPHNPObjectHasMethod to determine whether a method with the given name exists.
2674 (WebKit::ProxyInstance::fieldNamed):
2675 Call _WKPHNPObjectHasProperty to determine whether a property with the given name exists.
2677 * Plugins/Hosted/WebKitPluginClient.defs:
2678 * Plugins/Hosted/WebKitPluginHost.defs:
2679 Add new MIG definitions.
2681 2009-01-21 Mark Rowe <mrowe@apple.com>
2683 Reviewed by Tim Hatcher.
2685 Clean up how we force invocations of API that happened on background threads over to the main thread.
2687 This was previously accomplished in a somewhat ad-hoc manner using a mutable dictionary to pass arguments
2688 and return values back from the function. The new approach is to use a proxy object that forwards an
2689 NSInvocation over to the main thread and applies it to the target object, which leads to a much cleaner
2692 * Misc/WebNSObjectExtras.h:
2693 * Misc/WebNSObjectExtras.mm:
2694 (-[WebMainThreadInvoker initWithTarget:]):
2695 (-[WebMainThreadInvoker forwardInvocation:]):
2696 (-[WebMainThreadInvoker methodSignatureForSelector:]):
2697 (-[WebMainThreadInvoker handleException:]):
2698 (-[NSInvocation _webkit_invokeAndHandleException:]): Execute the invocation and forward any exception that was
2699 raised back to the WebMainThreadInvoker.
2700 (-[NSObject _webkit_invokeOnMainThread]):
2702 The following methods are updated to use the proxy object to forward methods to the main thread:
2704 * WebView/WebArchive.mm:
2705 (-[WebArchive initWithMainResource:subresources:subframeArchives:]):
2706 (-[WebArchive mainResource]):
2707 (-[WebArchive subresources]):
2708 (-[WebArchive subframeArchives]):
2709 * WebView/WebResource.mm:
2710 (-[WebResource data]):
2711 (-[WebResource URL]):
2712 (-[WebResource MIMEType]):
2713 (-[WebResource textEncodingName]):
2714 (-[WebResource frameName]):
2715 (-[WebResource _ignoreWhenUnarchiving]):
2716 (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]):
2717 (-[WebResource _initWithData:URL:response:]):
2718 (-[WebResource _suggestedFilename]):
2719 (-[WebResource _response]):
2720 (-[WebResource _stringValue]):
2721 * WebView/WebView.mm:
2722 (-[WebView initWithFrame:frameName:groupName:]):
2723 (-[WebView initWithCoder:]):
2725 2009-01-20 Nikolas Zimmermann <nikolas.zimmermann@torchmobile.com>
2727 Reviewed by George Staikos.
2729 Fixes: https://bugs.webkit.org/show_bug.cgi?id=23434 (Add WML <input> element support)
2731 Protect text field related WebEditorClient.mm methods against non-HTMLElement callers.
2732 WebEditorClient.mm relies on HTMLInputElement as input element. Ignore calls from non-HTMLElement elements.
2734 * WebCoreSupport/WebEditorClient.mm:
2735 (WebEditorClient::textFieldDidBeginEditing):
2736 (WebEditorClient::textFieldDidEndEditing):
2737 (WebEditorClient::textDidChangeInTextField):
2738 (WebEditorClient::doTextFieldCommandFromEvent):
2739 (WebEditorClient::textWillBeDeletedInTextField):
2740 (WebEditorClient::textDidChangeInTextArea):
2742 2009-01-19 Anders Carlsson <andersca@apple.com>
2744 Reviewed by Sam Weinig.
2746 Add and implement GetScriptableNPObject.
2748 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2749 (WKPCGetScriptableNPObjectReply):
2750 Create a new reply struct and set it as the current reply.
2753 Get rid of an unused variable.
2755 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2756 (WebKit::NetscapePluginInstanceProxy::Reply::):
2757 (WebKit::NetscapePluginInstanceProxy::GetScriptableNPObjectReply::GetScriptableNPObjectReply):
2758 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2759 (WebKit::NetscapePluginInstanceProxy::createBindingsInstance):
2760 Call _WKPHGetScriptableNPObject and wait for a reply.
2762 * Plugins/Hosted/ProxyInstance.h: Added.
2763 * Plugins/Hosted/ProxyInstance.mm: Added.
2766 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
2767 (-[WebHostedNetscapePluginView JSC::Bindings::createPluginBindingsInstance:JSC::Bindings::]):
2768 Call NetscapePluginInstanceProxy::createBindingsInstance.
2770 * Plugins/Hosted/WebKitPluginClient.defs:
2771 * Plugins/Hosted/WebKitPluginHost.defs:
2772 Add new declarations.
2774 2009-01-19 Sam Weinig <sam@webkit.org>
2776 Rubber-stamped by Gavin Barraclough.
2778 Remove temporary operator-> from JSValuePtr.
2780 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2781 (WebKit::NetscapePluginInstanceProxy::invoke):
2782 (WebKit::NetscapePluginInstanceProxy::hasMethod):
2783 (WebKit::NetscapePluginInstanceProxy::marshalValue):
2784 * WebView/WebFrame.mm:
2785 (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
2786 * WebView/WebView.mm:
2787 (aeDescFromJSValue):
2789 2009-01-19 Anders Carlsson <andersca@apple.com>
2791 Reviewed by Sam Weinig.
2793 Make Evaluate an asynchronous method that has a reply method.
2795 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2797 * Plugins/Hosted/WebKitPluginClient.defs:
2798 * Plugins/Hosted/WebKitPluginHost.defs:
2800 2009-01-19 Brady Eidson <beidson@apple.com>
2802 Rubberstamped by Tim Hatcher
2804 Fix long standing typo.
2806 * History/WebBackForwardList.h:
2808 2009-01-19 Mark Rowe <mrowe@apple.com>
2812 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2813 (WebKit::NetscapePluginInstanceProxy::demarshalValue):
2814 (WebKit::NetscapePluginInstanceProxy::demarshalValues):
2816 2009-01-18 Mark Rowe <mrowe@apple.com>
2818 Reviewed by Anders Carlsson.
2820 Fix <https://bugs.webkit.org/show_bug.cgi?id=23414>.
2821 Bug 23414: Reproducible crash accessing View menu with plugins disabled
2823 * WebView/WebFrame.mm:
2824 (-[WebFrame _canProvideDocumentSource]): Null-check the PluginData before using it.
2826 2009-01-17 David Hyatt <hyatt@apple.com>
2828 Eliminate dependencies on "backslashAsCurrencySymbol()" from WebKit, and make sure these alterations
2829 are done in WebCore instead.
2831 Reviewed by Oliver Hunt
2833 * WebView/WebFrame.mm:
2834 (-[WebFrame _selectedString]):
2835 (-[WebFrame _stringForRange:]):
2837 2009-01-17 Eric Carlson <eric.carlson@apple.com>
2839 Reviewed by Adele Peterson
2841 Complete <rdar://problem/6293969>
2843 * WebCoreSupport/WebSystemInterface.m:
2844 (InitWebCoreSystemInterface): Remove UseSharedMediaUI
2846 2009-01-15 Brady Eidson <beidson@apple.com>
2848 Reviewed by Dan Bernstein
2850 Fix problem where a URL visited as non-GET once is flagged as non-GET forever.
2852 * History/WebHistory.mm:
2853 (-[WebHistory _visitedURL:withTitle:method:wasFailure:]): Always update the HTTPNonGet
2854 flag for all loads with an HTTP Method
2856 2009-01-14 Anders Carlsson <andersca@apple.com>
2858 Reviewed by Sam Weinig.
2860 Implement InvokeDefault, Construct, GetProperty and SetProperty.
2862 Fully implement marshalValue.
2864 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2865 (WKPCInvokeDefault):
2869 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2870 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2871 (WebKit::NetscapePluginInstanceProxy::evaluate):
2872 (WebKit::NetscapePluginInstanceProxy::invoke):
2873 (WebKit::NetscapePluginInstanceProxy::invokeDefault):
2874 (WebKit::NetscapePluginInstanceProxy::construct):
2875 (WebKit::NetscapePluginInstanceProxy::getProperty):
2876 (WebKit::NetscapePluginInstanceProxy::setProperty):
2877 (WebKit::NetscapePluginInstanceProxy::marshalValue):
2878 (WebKit::NetscapePluginInstanceProxy::demarshalValue):
2879 * Plugins/Hosted/WebKitPluginClient.defs:
2881 2009-01-14 Anders Carlsson <andersca@apple.com>
2883 Reviewed by Sam Weinig.
2885 Demarshal arguments and pass them to the JS call.
2887 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2889 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2890 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2891 (WebKit::NetscapePluginInstanceProxy::invoke):
2892 (WebKit::NetscapePluginInstanceProxy::demarshalValueFromArray):
2893 (WebKit::NetscapePluginInstanceProxy::demarshalValues):
2895 2009-01-14 Mark Rowe <mrowe@apple.com>
2897 Reviewed by Timothy Hatcher.
2899 <rdar://problem/6496520> REGRESSION: In Mail, a crash occurs when attempting to display a mail message
2901 Move WebArchive and WebResource to use the same approach for initializing themselves on the main thread
2904 * WebView/WebArchive.mm:
2905 (-[WebArchive initWithMainResource:subresources:subframeArchives:]): Use _webkit_performSelectorOnMainThread:withObject:.
2906 (-[WebArchive _initWithArguments:]):
2907 * WebView/WebResource.mm:
2908 (-[WebResource _initWithArguments:]): Unbox the BOOL argument.
2910 2009-01-14 Darin Adler <darin@apple.com>
2912 Reviewed by Oliver Hunt.
2914 Fix crash I ran into while printing. I was unable to reproduce it, but also,
2915 it's clear there's no guarantee that the frame will be non-zero in this case,
2916 so it seems fine to check it.
2918 * WebView/WebHTMLView.mm: (-[WebHTMLView reapplyStyles]): Check frame for zero
2919 and don't do anything with it if it's zero.
2921 2009-01-14 Dan Bernstein <mitz@apple.com>
2923 Reviewed by John Sullivan.
2929 2009-01-12 Anders Carlsson <andersca@apple.com>
2931 Reviewed by Darin Adler.
2933 Add a bunch of methods to WebKitPluginClient.defs, and implement them.
2935 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2936 (WebKit::fromUTF8WithLatin1Fallback):
2937 If the length isn't specified, get it by calling strlen.
2940 Evaluate doesn't take any arguments.
2942 (WKPCGetIntIdentifier):
2943 Call _NPN_GetIntIdentifier.
2945 (identifierFromServerIdentifier):
2946 New helper function that returns a JSC Identifier from an NPIdentifier.
2949 Call identifierFromServerIdentifier.
2951 (WKPCRemoveProperty):
2954 Call NetscapePluginInstanceProxy.
2956 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2957 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2958 (WebKit::NetscapePluginInstanceProxy::removeProperty):
2959 (WebKit::NetscapePluginInstanceProxy::hasProperty):
2960 (WebKit::NetscapePluginInstanceProxy::hasMethod):
2962 * Plugins/Hosted/WebKitPluginClient.defs:
2963 Add new definitions.
2965 2009-01-13 Anders Carlsson <andersca@apple.com>
2969 * WebView/WebView.mm:
2970 (-[WebView _initWithArguments:]):
2972 2009-01-13 Timothy Hatcher <timothy@apple.com>
2974 Adds a workaround for the flip4mac installer plugin decoding a WebView from a NIB on a secondary thread.
2976 <rdar://problem/6489788> New WebKit thread checks break installation of flip4mac (thread violation)
2978 Reviewed by Darin Adler.
2980 * Misc/WebKitVersionChecks.h: Add WEBKIT_FIRST_VERSION_WITHOUT_WEBVIEW_INIT_THREAD_WORKAROUND.
2981 * Misc/WebNSObjectExtras.h: Add _webkit_performSelectorOnMainThread:withObject:.
2982 * Misc/WebNSObjectExtras.mm:
2983 (-[NSObject _webkit_performSelectorWithArguments:]): Renamed from _webkit_getPropertyWithArguments.
2984 Passes the optional object to the selector.
2985 (-[NSObject _webkit_performSelectorOnMainThread:withObject:]): Renamed from _webkit_getPropertyOnMainThread:.
2986 Put the optional object into the arguments dictionary.
2987 (-[NSObject _webkit_getPropertyOnMainThread:]): Call _webkit_performSelectorOnMainThread with a nil object.
2988 * WebView/WebResource.mm:
2989 (-[WebResource _ignoreWhenUnarchiving]): Use _cmd instead of making the selector again.
2990 (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]): Use the new
2991 _webkit_performSelectorOnMainThread:withObject: method instead of performSelectorOnMainThread.
2992 * WebView/WebView.mm:
2993 (-[WebView _initWithArguments:]): Added. Pulls arguments out of the dictionary and calls the right init method.
2994 (needsWebViewInitThreadWorkaround): Checks if the thead is not the main thread and if we are in the Installer bundle.
2995 (-[WebView initWithFrame:frameName:groupName:]): Call needsWebViewInitThreadWorkaround and use _webkit_performSelectorOnMainThread
2996 to call _initWithArguments: passing the frame, frameName and groupName.
2997 (-[WebView initWithCoder:]): Ditto, except pass the coder to _initWithArguments:.
2999 2009-01-12 Gavin Barraclough <barraclough@apple.com>
3001 Reviewed by Oliver Hunt.
3003 Deprecate JSValuePtr::getNumber() - two ways to get a number should be enough.
3005 * WebView/WebView.mm:
3006 (aeDescFromJSValue):
3008 2009-01-12 Brady Eidson <beidson@apple.com>
3010 Reviewed by Darin Adler
3012 <rdar://problem/6468274> - Track Non-get requests in global history
3014 * History/WebHistory.mm:
3015 (-[WebHistory _visitedURL:withTitle:method:wasFailure:]):
3016 * History/WebHistoryInternal.h:
3018 * History/WebHistoryItem.mm:
3019 (-[WebHistoryItem initFromDictionaryRepresentation:]):
3020 (-[WebHistoryItem dictionaryRepresentation]):
3021 (-[WebHistoryItem _lastVisitWasHTTPNonGet]):
3022 * History/WebHistoryItemPrivate.h:
3024 * WebCoreSupport/WebFrameLoaderClient.mm:
3025 (WebFrameLoaderClient::updateGlobalHistory): Only pass the method through if it was an HTTP load
3027 2009-01-12 Anders Carlsson <andersca@apple.com>
3029 Reviewed by Sam Weinig.
3031 Move marshalling into NetscapePluginInstanceProxy.
3033 Add support for marshallin strings.
3035 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3038 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3039 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3040 (WebKit::NetscapePluginInstanceProxy::evaluate):
3041 (WebKit::NetscapePluginInstanceProxy::invoke):
3042 (WebKit::NetscapePluginInstanceProxy::marshalValue):
3043 * Plugins/Hosted/WebKitPluginHostTypes.h:
3045 2009-01-12 Anders Carlsson <andersca@apple.com>
3047 Reviewed by Sam Weinig.
3049 Implement WKPCInvoke.
3051 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3054 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3055 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3056 (WebKit::NetscapePluginInstanceProxy::idForObject):
3057 (WebKit::NetscapePluginInstanceProxy::invoke):
3058 * Plugins/Hosted/WebKitPluginClient.defs:
3060 2009-01-12 Anders Carlsson <andersca@apple.com>
3062 Reviewed by Sam Weinig.
3064 Move marshalling code to NetscapePluginInstanceProxy. Add support for marshalling JS objects.
3066 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3068 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3069 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3070 (WebKit::NetscapePluginInstanceProxy::marshalValue):
3071 * Plugins/Hosted/WebKitPluginHostTypes.h:
3073 2009-01-12 Julien Chaffraix <jchaffraix@pleyo.com>
3075 Reviewed by Darin Adler.
3077 Bug 22861: Turn the FontCache into a singleton
3078 https://bugs.webkit.org/show_bug.cgi?id=22861
3080 * Misc/WebCoreStatistics.mm:
3081 (+[WebCoreStatistics cachedFontDataCount]):
3082 (+[WebCoreStatistics cachedFontDataInactiveCount]):
3083 (+[WebCoreStatistics purgeInactiveFontData]):
3084 Redirected all the static calls to the global FontCache
3087 2009-01-11 Dmitry Titov <dimich@chromium.org>
3089 Reviewed by Darin Adler.
3091 https://bugs.webkit.org/show_bug.cgi?id=23207
3092 Moved currentTime() to from WebCore to WTF.
3094 * WebView/WebFrame.mm: a different header file included.
3096 2009-01-10 Darin Adler <darin@apple.com>
3098 Reviewed by Sam Weinig.
3100 <rdar://problem/5845089> REGRESSION (r30044): Mail custom stationery missing images
3101 because of change to -[HTMLObjectElement data]
3103 * WebView/WebView.mm:
3104 (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]): Added a thread
3105 violation check because I saw this being done off the main thread while testing Mail, and it
3106 caused problems. Put all the one time initialization under a single guard to make things just
3107 a little faster other times, and to make it clearer which things are one-time. Added a call to
3108 the new patchMailRemoveAttributesMethod function.
3109 (-[WebView initWithFrame:frameName:groupName:]): Added a thread violation check here too,
3110 because I assumed it would be slightly better to have a public method name in the violation
3111 message. This calls commonInitialization later, so it will hit that one eventually.
3112 (objectElementDataAttribute): Added. Just returns the value of the "data" attribute.
3113 (recursivelyRemoveMailAttributes): Added. Patch to an internal Mail method that in turn patches
3114 a WebKit method and removes the patch again on the way out.
3115 (patchMailRemoveAttributesMethod): Added. On Leopard only, checks the Mail version, and then
3116 applies the patch that fixes this bug.
3118 2009-01-09 Dan Bernstein <mitz@apple.com>
3120 Reviewed by Darin Adler.
3122 - fixed <rdar://problem/6234347> Add/change conditional key
3123 bindings for changing paragraph- and character-level writing
3124 direction (to match NSTextView)
3126 * WebView/WebHTMLView.mm:
3127 (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]): Added
3128 code to validate makeBaseWritingDirectionLeftToRight: and
3129 makeBaseWritingDirectionRightToLeft:.
3130 (writingDirectionKeyBindingsEnabled): Changed this function to
3131 always return YES, except on Tiger and Leopard.
3132 (-[WebHTMLView makeBaseWritingDirectionLeftToRight:]): Renamed
3133 changeBaseWritingDirectionToLTR: to this.
3134 (-[WebHTMLView makeBaseWritingDirectionRightToLeft:]): Renamed
3135 changeBaseWritingDirectionToRTL: to this.
3136 (-[WebHTMLView changeBaseWritingDirectionToLTR:]): Now calls
3137 makeBaseWritingDirectionLeftToRight:.
3138 (-[WebHTMLView changeBaseWritingDirectionToRTL:]): Now calls
3139 makeBaseWritingDirectionRightToLeft:.
3140 * WebView/WebView.mm: Added makeBaseWritingDirectionLeftToRight
3141 and makeBaseWritingDirectionRightToLeft to
3142 FOR_EACH_RESPONDER_SELECTOR.
3144 2009-01-08 Anders Carlsson <andersca@apple.com>
3146 Reviewed by Sam Weinig.
3148 Add and implement WKPCGetStringIdentifier.
3150 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3151 (WKPCGetStringIdentifier):
3152 * Plugins/Hosted/WebKitPluginClient.defs:
3154 2009-01-08 Stephanie Lewis <slewis@gmail.com>
3158 * WebView/WebTextIterator.mm:
3160 2009-01-08 Anders Carlsson <andersca@apple.com>
3162 Reviewed by Sam Weinig.
3164 Add basic support for evaluating scripts.
3166 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3167 (WebKit::fromUTF8WithLatin1Fallback):
3168 (WebKit::NetscapePluginHostProxy::~NetscapePluginHostProxy):
3169 (WKPCReleaseObject):
3172 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3173 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3174 (WebKit::NetscapePluginInstanceProxy::releaseObject):
3175 (WebKit::NetscapePluginInstanceProxy::evaluate):
3176 * Plugins/Hosted/WebKitPluginClient.defs:
3177 * Plugins/Hosted/WebKitPluginHostTypes.h:
3179 2009-01-08 David Hyatt <hyatt@apple.com>
3181 Fix for <rdar://problem/6465682> REGRESSION: In Mail, can't force a message to auto scroll
3183 Add a new ChromeClient method for handling exposure of scrolled rects.
3185 Reviewed by Oliver Hunt
3187 * WebCoreSupport/WebChromeClient.h:
3188 * WebCoreSupport/WebChromeClient.mm:
3189 (WebChromeClient::scrollRectIntoView):
3191 2009-01-08 Darin Adler <darin@apple.com>
3193 Reviewed by Tim Hatcher.
3195 Bug 23185: add a currentRange method to the WebTextIterator SPI
3196 https://bugs.webkit.org/show_bug.cgi?id=23185
3197 rdar://problem/6455834
3199 I also noticed a garbage-collection-related threading issue that I fixed, and
3200 that the SPI for getting text was unnecessarily inefficient, so I fixed that too.
3202 * WebView/WebTextIterator.h: Moved currentNode and currentText into a "deprecated"
3203 category. Added currentTextPointer and currentTextLength.
3205 * WebView/WebTextIterator.mm: Changed m_textIterator into an OwnPtr, and also
3206 used _textIterator to be consistent with ObjC rather than C++ naming.
3207 (+[WebTextIteratorPrivate initialize]): Added. Calls WebCoreObjCFinalizeOnMainThread,
3208 since the finalize method here works with main-thread only WebCore objects.
3209 (-[WebTextIterator initWithRange:]): Changed since _textIterator is an OwnPtr now.
3210 (-[WebTextIterator advance]): Changed name of m_textIterator. Removed null assertion,
3211 since I don't think it provides much value.
3212 (-[WebTextIterator atEnd]): Ditto.
3213 (-[WebTextIterator currentRange]): Added.
3214 (-[WebTextIterator currentTextPointer]): Added.
3215 (-[WebTextIterator currentTextLength]): Added.
3216 (-[WebTextIterator currentNode]): Did same as above, but also put into new category.
3217 (-[WebTextIterator currentText]): Ditto.
3219 2009-01-08 Eric Carlson <eric.carlson@apple.com>
3221 Reviewed by Adele Peterson.
3223 Simplify Mac interfaces for drawing media controller elements
3225 <rdar://problem/6293969>
3227 * WebCoreSupport/WebSystemInterface.m:
3228 (InitWebCoreSystemInterface): Update for changes to media controller functions
3230 2009-01-07 Anders Carlsson <andersca@apple.com>
3232 Reviewed by Dan Bernstein.
3236 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3237 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3238 (WebKit::NetscapePluginInstanceProxy::idForObject):
3240 2009-01-07 Anders Carlsson <andersca@apple.com>
3242 Reviewed by Dan Bernstein.
3244 Add a way for a plug-in to get a reference to the Window JS object.
3246 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3247 (WKPCGetWindowNPObject):
3248 Call the appropriate instance.
3250 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3251 Add object ID counter.
3253 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3254 (WebKit::NetscapePluginInstanceProxy::destroy):
3255 Clear the object ID map.
3257 (WebKit::NetscapePluginInstanceProxy::idForObject):
3258 New method that returns a unique ID for a given JS object.
3260 (WebKit::NetscapePluginInstanceProxy::getWindowNPObject):
3261 Return the object ID for the window JS object.
3263 * Plugins/Hosted/WebKitPluginClient.defs:
3264 Add GetWindowNPObject.
3266 2009-01-07 Darin Adler <darin@apple.com>
3268 Reviewed by Oliver Hunt.
3270 Bug 23160: add setMemoryCacheClientCallsEnabled SPI so Safari can be faster with activity window closed
3271 https://bugs.webkit.org/show_bug.cgi?id=23160
3273 * WebView/WebView.mm:
3274 (-[WebView setMemoryCacheDelegateCallsEnabled:]): Added.
3275 (-[WebView areMemoryCacheDelegateCallsEnabled]): Added
3276 * WebView/WebViewPrivate.h: Ditto.
3278 2009-01-05 Gavin Barraclough <baraclough@apple.com>
3280 Rubber Stamped by Oliver Hunt.
3282 Replace all uses of JSValue* with new wrapper class, JSValuePtr.
3283 See JavaScriptCore/ChangeLog for more detailed description.
3285 * WebView/WebFrame.mm:
3286 (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
3287 * WebView/WebScriptDebugDelegate.mm:
3288 (-[WebScriptCallFrame _convertValueToObjcValue:]):
3289 (-[WebScriptCallFrame exception]):
3290 (-[WebScriptCallFrame evaluateWebScript:]):
3291 * WebView/WebView.mm:
3292 (aeDescFromJSValue):
3293 (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
3295 2009-01-06 Pierre-Olivier Latour <pol@apple.com>
3297 Reviewed by Darin Adler.
3299 Exposed through WebFrame private interface the new WebCore API AnimationController::numberOfActiveAnimations() to be used by DRT.
3301 https://bugs.webkit.org/show_bug.cgi?id=23126
3303 * WebView/WebFrame.mm:
3304 (-[WebFrame _numberOfActiveAnimations]):
3305 * WebView/WebFramePrivate.h:
3307 2009-01-05 David Kilzer <ddkilzer@apple.com>
3309 Add SPI to enable, disable and check state of WebIconDatabase
3311 Reviewed by Darin Adler & Timothy Hatcher.
3313 Add -[WebIconDatabase isEnabled] and -[WebIconDatabase setEnabled:]
3314 SPI to make it possible to enable, disable and check the state of
3317 * Misc/WebIconDatabase.mm:
3318 (-[WebIconDatabase init]): Extracted code into -_startUpIconDatabase.
3319 (-[WebIconDatabase iconForURL:withSize:cache:]): Switched to use
3320 -isEnabled instead of -_isEnabled.
3321 (-[WebIconDatabase iconURLForURL:]): Ditto.
3322 (-[WebIconDatabase retainIconForURL:]): Ditto.
3323 (-[WebIconDatabase releaseIconForURL:]): Ditto.
3324 (-[WebIconDatabase isEnabled]): Renamed from -_isEnabled in
3325 WebInternal category.
3326 (-[WebIconDatabase setEnabled:]): Added. Takes care of changing
3327 the enabled/disabled state of the icon database.
3328 (-[WebIconDatabase removeAllIcons]): Switched to use -isEnabled
3329 instead of -_isEnabled.
3330 (-[WebIconDatabase _startUpIconDatabase]): Added. Extrated from
3332 (-[WebIconDatabase _shutDownIconDatabase]): Added. Remove
3333 observers when the icon database is disabled.
3334 * Misc/WebIconDatabaseInternal.h: Added declarations for
3335 -_startUpIconDatabase and -_shutDownIconDatabase.
3336 * Misc/WebIconDatabasePrivate.h: Added declarations for
3337 -isEnabled and -setEnabled:.
3339 2009-01-05 Brady Eidson <beidson@apple.com>
3341 Reviewed by Jon Honeycutt
3343 Expose setting the last-visit-was-failure flag on a history items in preparation for <rdar://problem/6173319>
3345 * History/WebHistoryItem.mm:
3346 (-[WebHistoryItem _setLastVisitWasFailure:]):
3347 * History/WebHistoryItemPrivate.h:
3349 2009-01-05 Adam Treat <adam.treat@torchmobile.com>
3351 Another blind mac build fix
3353 * WebCoreSupport/WebChromeClient.mm:
3354 (WebChromeClient::contentsSizeChanged):
3356 2009-01-05 Adam Treat <adam.treat@torchmobile.com>
3360 * WebCoreSupport/WebChromeClient.mm:
3362 2009-01-05 Adam Treat <adam.treat@torchmobile.com>
3366 * WebCoreSupport/WebChromeClient.h:
3368 2009-01-05 Adam Treat <adam.treat@torchmobile.com>
3370 Reviewed by George Staikos.
3372 Build fix for contentsSizeChanged
3374 * WebCoreSupport/WebChromeClient.h:
3375 * WebCoreSupport/WebChromeClient.mm:
3376 (WebChromeClient::contentsSizeChanged):
3378 2009-01-02 Darin Adler <darin@apple.com>
3380 Reviewed by Sam Weinig.
3382 Bug 23072: REGRESSION (r37371): In the Dictionary application, scroll bar appears
3383 inside its web view when resizing its window
3384 https://bugs.webkit.org/show_bug.cgi?id=23072
3385 rdar://problem/6368028
3387 The first attempt at fixing this did not work.
3388 This time I was able to reproduce the bug and test the fix.
3390 * WebCoreSupport/WebFrameLoaderClient.mm:
3391 (applyAppleDictionaryApplicationQuirkNonInlinePart): Changed the arguments and
3392 function names around a bit to make even less code at the call site.
3393 (applyAppleDictionaryApplicationQuirk): Put the check for whether this is the
3394 Dictionary application in here.
3395 (WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache): Put a call to
3396 applyAppleDictionaryApplicationQuirk here. This was a case I had missed before,
3397 when the script is cached. This fixes one of the two problems with the initial
3398 patch; the other fix is in WebCore.
3399 (WebFrameLoaderClient::dispatchWillSendRequest): Changed the
3400 applyAppleDictionaryApplicationQuirk call here to work the new simpler way.
3402 * WebView/WebView.mm: Had to add an include due to changes in WebCore header includes.
3404 2009-01-02 Cameron Zwarich <cwzwarich@uwaterloo.ca>
3406 Reviewed by Darin Adler.
3408 Bug 23060: REGRESSION (r38629): Cannot scroll a WebHTMLView using Home/End/Page up/Page down
3409 <https://bugs.webkit.org/show_bug.cgi?id=23060>
3410 <rdar://problem/6467830>
3412 After r38629, all keyboard events get sent by Editor to the EditorClient, even
3413 if the selection is not editable. If the event's command is unsupported by
3414 WebHTMLView, WebHTMLView mistakenly thinks that the event was handled when it
3415 was not. When using the page up / page down keys, the events generated are of
3416 the form scrollPageUp rather than movePageUp, so they are unsupported by
3417 WebHTMLView and cause this bug to occur.
3419 * WebView/WebHTMLView.mm:
3420 (-[WebHTMLView doCommandBySelector:]):
3422 2009-01-02 Darin Adler <darin@apple.com>
3424 Reviewed by Oliver Hunt.
3426 Bug 23072: REGRESSION (r37371): In the Dictionary application, scroll bar appears inside its web view when resizing its window
3427 https://bugs.webkit.org/show_bug.cgi?id=23072
3428 rdar://problem/6368028
3430 * WebCoreSupport/WebFrameLoaderClient.mm:
3431 (isAppleDictionaryApplication): Added.
3432 (applyAppleDictionaryApplicationQuirk): Added. Under the right conditions, sets
3433 a flag to ask HTMLFrameElementBase to ignore the scrolling attribute.
3434 (WebFrameLoaderClient::dispatchWillSendRequest): Call the two functions above to
3435 apply the quirk when the relevant script is loaded.
3437 2008-12-26 Dan Bernstein <mitz@apple.com>
3439 Reviewed by Sam Weinig.
3441 - fix <rdar://problem/6467608> lastVisitWasFailure flag persists in
3442 global history after a successful visit
3444 * History/WebHistory.mm:
3445 (-[WebHistory _visitedURL:withTitle:wasFailure:]): Changed to always
3446 update the wasFailure flag on the HistoryItem.
3448 2008-12-23 Darin Adler <darin@apple.com>
3450 Reviewed by Alexey Proskuryakov (a slightly earlier version).
3452 - fix https://bugs.webkit.org/show_bug.cgi?id=22976
3453 crash due to Mail's use of WebArchive and WebResource on non-main thread
3455 * Misc/WebKitLogging.h: Improved comments for ASSERT_MAIN_THREAD. Got rid of
3456 WebKitRunningOnMainThread function, which was just a cover for pthread_main_np.
3457 * Misc/WebKitLogging.m: Ditto.
3459 * Misc/WebKitVersionChecks.h: Added a version after which we won't do the
3460 main thread workaround.
3462 * Misc/WebNSObjectExtras.h: Added a new method, _webkit_getPropertyOnMainThread:,
3463 which performs a selector on the main thread, waits for it to complete, and then
3464 returns the value on the caller thread.
3465 * Misc/WebNSObjectExtras.mm: Added.
3467 * WebView/WebArchive.mm:
3468 (-[WebArchive init]): Added WebCoreThreadViolationCheck.
3469 (-[WebArchive initWithMainResource:subresources:subframeArchives:]): Perform
3470 initialization on main thread if needMailThreadWorkaround is true.
3471 Also added WebCoreThreadViolationCheck.
3472 (-[WebArchive initWithData:]): Added WebCoreThreadViolationCheck.
3473 (-[WebArchive mainResource]): Get property on main thread if
3474 needMailThreadWorkaround is true. Also added WebCoreThreadViolationCheck.
3475 (-[WebArchive subresources]): Ditto.
3476 (-[WebArchive subframeArchives]): Ditto.
3477 (-[WebArchive data]): Ditto.
3478 (-[WebArchive _initWithCoreLegacyWebArchive:]): Added WebCoreThreadViolationCheck.
3479 (-[WebArchive _coreLegacyWebArchive]): Ditto.
3480 (-[WebArchive _initWithArguments:]): Added. Used to implement the cross-thread
3481 version of initWithMainResource above.
3483 * WebView/WebResource.mm:
3484 (-[WebResource initWithCoder:]): Added WebCoreThreadViolationCheck.
3485 (-[WebResource data]): Get property on main thread if
3486 needMailThreadWorkaround is true. Also added WebCoreThreadViolationCheck.
3487 (-[WebResource URL]): Ditto.
3488 (-[WebResource MIMEType]): Ditto.
3489 (-[WebResource textEncodingName]): Ditto.
3490 (-[WebResource frameName]): Ditto.
3491 (-[WebResource _ignoreWhenUnarchiving]): Ditto.
3492 (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]):
3493 Perform initialization on main thread if needMailThreadWorkaround is true.
3494 Also added WebCoreThreadViolationCheck.
3495 (-[WebResource _suggestedFilename]): Added. Helper for _fileWrapperRepresentation.
3496 (-[WebResource _fileWrapperRepresentation]): Rewrote to use methods instead of
3497 getting at coreResource directly.
3498 (-[WebResource _response]): Get property on main thread if
3499 needMailThreadWorkaround is true. Also added WebCoreThreadViolationCheck.
3500 (-[WebResource _stringValue]): Ditto.
3501 (+[WebResource _needMailThreadWorkaroundIfCalledOffMainThread]): Added.
3502 (-[WebResource _initWithArguments:]): Added. Used to implement the cross-thread
3503 version of _initWithData above.
3505 * WebView/WebResourceInternal.h: Changed to include WebResourcePrivate.h since internal
3506 clients have access to the SPI as well as the API. Added definition of MAIL_THREAD_WORKAROUND
3507 and the needMainThreadWorkaround helper function.
3509 * Misc/WebIconDatabase.mm: Removed include of now-defunct FoundationExtras.h
3510 file. This probably fixes clean builds.
3511 * WebCoreSupport/WebIconDatabaseClient.mm: Ditto.
3513 * WebCoreSupport/WebFrameLoaderClient.mm: Removed include of WebResourcePrivate.h,
3514 since it's not actually used.
3515 * WebView/WebDataSource.mm: Ditto.
3516 * WebView/WebHTMLRepresentation.mm: Ditto.
3518 2008-12-23 Darin Adler <darin@apple.com>
3520 Reviewed by Dan Bernstein.
3522 - fix https://bugs.webkit.org/show_bug.cgi?id=22979
3523 crash seen in -[WebView drawsBackground] when quitting
3524 <rdar://problem/6464601>
3526 * WebView/WebView.mm:
3527 (-[WebView drawsBackground]): Added comment and a null check for _private.
3529 2008-12-22 Kevin Decker <kdecker@apple.com>
3531 Reviewed by Anders Carlsson.
3533 <rdar://problem/6449588> REGRESSION (r38279-r38280): Minimize them remaximize a window with a flash plugin, plugin doesn't resume at full speed
3535 * Plugins/WebBaseNetscapePluginView.mm:
3536 (-[WebBaseNetscapePluginView windowDidDeminiaturize:]): Deminiaturizing should restart timers, not stop timers.
3538 2008-12-19 Geoffrey Garen <ggaren@apple.com>
3540 Reviewed by Darin Adler, Adele Peterson, Brady Eidson.
3542 Added SPI for getting an unsorted vector of all items in history.
3544 * History/WebHistory.h:
3545 * History/WebHistory.mm:
3546 (-[WebHistory allItems]):
3548 2008-12-18 Dan Bernstein <mitz@apple.com>
3550 Reviewed by Sam Weinig.
3552 - implement FrameLoaderClient::shouldUseCredentialStorage() by calling
3553 a new resource load delegae method.
3555 * WebCoreSupport/WebFrameLoaderClient.h:
3556 * WebCoreSupport/WebFrameLoaderClient.mm:
3557 (WebFrameLoaderClient::shouldUseCredentialStorage): Added. Calls the
3558 delegate method. If the method is unimplemented, returns true for
3559 backwards compatibility.
3560 * WebView/WebView.mm:
3561 (-[WebView _cacheResourceLoadDelegateImplementations]): Initialize the
3562 shouldUseCredentialStorageFunc member.
3563 (CallResourceLoadDelegateReturningBoolean): Added.
3564 * WebView/WebViewInternal.h:
3565 * WebView/WebResourceLoadDelegatePrivate.h: Declared the delegate method
3566 -webView:resource:shouldUseCredentialStorageForDataSource:.
3568 2008-12-18 Cameron Zwarich <zwarich@apple.com>
3570 Reviewed by Jonathan Honeycutt.
3572 Fix an apparent typo in r39385 that is causing lots of crashes.
3574 * WebCoreSupport/WebFrameLoaderClient.mm:
3575 (WebFrameLoaderClient::dispatchDidFirstVisuallyNonEmptyLayout):
3577 2008-12-18 Brady Eidson <beidson@apple.com>
3579 Reviewed by John Sullivan
3581 Initial visit to a website creates history items that start with a visit count of
3584 * History/WebHistory.mm:
3585 (-[WebHistoryPrivate visitedURL:withTitle:]): Set the visit count on new items
3587 * History/WebHistoryItem.mm:
3588 (-[WebHistoryItem _setVisitCount:]): Call through to the WebCore item