1 2009-03-17 Mark Rowe <mrowe@apple.com>
5 * Plugins/Hosted/HostedNetscapePluginStream.mm:
7 2009-03-17 David Kilzer <ddkilzer@apple.com>
9 Use -[NSURLResponse(WebCoreURLResponse) _webcore_MIMEType] consistently
11 Reviewed by Darin Adler.
13 WebKit r30323 added -_webcore_MIMEType to fix issues with
14 incorrect MIME types in NS[HTTP]URLResponse objects. However,
15 uses of -[NSURLResponse MIMEType] still persist in WebKit that
16 should be switched to use -_webcore_MIMEType. Note that
17 -[WebDataSource _responseMIMEType] calls back into WebCore to
18 get the MIME type from the ResourceResponse object, which has
19 already retrieved it via -_webcore_MIMEType.
21 * Plugins/Hosted/HostedNetscapePluginStream.mm:
22 (WebKit::HostedNetscapePluginStream::didReceiveResponse): Use
24 * Plugins/WebBaseNetscapePluginStream.mm:
25 (WebNetscapePluginStream::didReceiveResponse): Ditto.
26 * Plugins/WebNetscapePluginView.mm:
27 (-[WebNetscapePluginView pluginView:receivedData:]): Ditto.
28 * Plugins/WebPluginController.mm:
29 (-[WebPluginController pluginView:receivedResponse:]): Ditto.
30 * WebView/WebHTMLRepresentation.mm:
31 (-[WebHTMLRepresentation _isDisplayingWebArchive]): Use
32 -[WebDataSource _responseMIMEType] instead.
33 * WebView/WebPDFRepresentation.m:
34 (-[WebPDFRepresentation finishedLoadingWithDataSource:]): Ditto.
35 * WebView/WebPDFView.mm:
36 (-[WebPDFView menuForEvent:]): Ditto.
38 2009-03-17 Simon Fraser <simon.fraser@apple.com>
40 Reviewed by Darin Adler
42 https://bugs.webkit.org/show_bug.cgi?id=24396
44 Add WTF_USE_ACCELERATED_COMPOSITING, defined to 0 for now.
48 2009-03-17 Kevin Ollivier <kevino@theolliviers.com>
50 Reviewed by Mark Rowe.
52 Get BUILDING_ON_* defines from Platform.h.
54 https://bugs.webkit.org/show_bug.cgi?id=24630
58 2009-03-16 Darin Adler <darin@apple.com>
60 Reviewed by Dan Bernstein.
62 <rdar://problem/6577174> Rename the text directionality submenus to “Paragraph Direction” and “Selection Direction”
64 * WebCoreSupport/WebViewFactory.mm:
65 (-[WebViewFactory contextMenuItemTagParagraphDirectionMenu]): Changed string here, but only
66 post-Leopard, since we want this to match the Mac OS X menu on Tiger and Leopard.
67 (-[WebViewFactory contextMenuItemTagSelectionDirectionMenu]): Changed string here.
69 2009-03-16 Anders Carlsson <andersca@apple.com>
71 Reviewed by Oliver Hunt.
73 Don't mig_deallocate random data in case an instance proxy method returns false.
75 * Plugins/Hosted/NetscapePluginHostProxy.mm:
82 2009-03-16 Anders Carlsson <andersca@apple.com>
84 Reviewed by Oliver Hunt.
86 <rdar://problem/6633944>
87 REGRESSION (Safari 4 PB): Many crashes in Flip4Mac involving loading the plugin
89 Defer loading while calling webPlugInInitialize since it can end up spinning the run loop.
91 * Plugins/WebPluginController.mm:
92 (-[WebPluginController addPlugin:]):
94 2009-03-16 Anders Carlsson <andersca@apple.com>
96 Reviewed by Sam Weinig.
98 Fix <rdar://problem/6622601>
100 Make sure to update both the window frame and the plug-in frame.
102 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
103 (-[WebHostedNetscapePluginView addWindowObservers]):
105 2009-03-15 Dan Bernstein <mitz@apple.com>
107 Reviewed by Adele Peterson.
109 - fix <rdar://problem/6607773> WebKit should support the "Default"
110 paragraph writing direction -- or at least validate the menu item
113 Made WebHTMLView validate user interface items with the selector
114 -makeBaseWritingDirectionNatural: by returning NO and, if the item is
115 a menu item, setting its state to "off".
117 Strictly speaking, since -makeBaseWritingDirectionNatural: is never
118 valid for WebViews, WebHTMLView should not need to respond to it and
119 validate it, however because other responders respond to all three
120 -makeBaseWritingDirection*: messages and set the menu item state, having
121 WebHTMLView do the same makes application developers' lives easier.
123 * WebView/WebHTMLView.mm:
124 (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]):
125 (-[WebHTMLView makeBaseWritingDirectionNatural:]):
127 2009-03-13 Mark Rowe <mrowe@apple.com>
129 Rubber-stamped by Dan Bernstein.
131 Take advantage of the ability of recent versions of Xcode to easily switch the active
134 * Configurations/DebugRelease.xcconfig:
136 2009-03-13 Anders Carlsson <andersca@apple.com>
138 Reviewed by Kevin Decker and Geoffrey Garen.
140 <rdar://problem/6590384>
141 REGRESSION (Safari 3-4): Tiger-only Crash occurs at WebView hostWindow () after reloading a set of tabs then quitting
143 When we're doing fast teardown, plug-in views can be destroyed from -[WebView dealloc]'s [super dealloc] call,
144 and thus calling -[WebView hostWindow] will crash since _private is nil.
146 * WebView/WebView.mm:
147 (-[WebView hostWindow]):
149 2009-03-13 Anders Carlsson <andersca@apple.com>
151 And yet another attempt...
153 * Plugins/WebNetscapePluginEventHandlerCocoa.h:
154 (WebNetscapePluginEventHandlerCocoa::installKeyEventHandler):
155 (WebNetscapePluginEventHandlerCocoa::removeKeyEventHandler):
156 * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
158 2009-03-13 Anders Carlsson <andersca@apple.com>
160 Another attempt at fixing the build.
162 * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
163 (WebNetscapePluginEventHandlerCocoa::WebNetscapePluginEventHandlerCocoa):
165 2009-03-13 Anders Carlsson <andersca@apple.com>
167 Try to fix the SL build.
169 * Plugins/WebNetscapePluginEventHandlerCocoa.h:
170 * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
171 (WebNetscapePluginEventHandlerCocoa::keyDown):
173 2009-03-13 Greg Bolsinga <bolsinga@apple.com>
175 Reviewed by Simon Fraser.
177 Update Geolocation perimission dialogs to be asynchronous.
178 https://bugs.webkit.org/show_bug.cgi?id=24505
180 WebGeolocation is a wrapper around WebCore::Geolocation. It mimics the
181 coding style set by WebSecurityOrigin.
183 WebChromeClient now calls the private UI delegate method
184 -webView:frame:requestGeolocationPermission:securityOrigin:
186 * WebCoreSupport/WebChromeClient.h:
187 * WebCoreSupport/WebChromeClient.mm:
188 (WebChromeClient::requestGeolocationPermissionForFrame):
189 * WebCoreSupport/WebGeolocation.mm: Added.
191 (-[WebGeolocation shouldClearCache]):
192 (-[WebGeolocation setIsAllowed:]):
193 (-[WebGeolocation dealloc]):
194 * WebCoreSupport/WebGeolocationInternal.h: Added.
195 * WebCoreSupport/WebGeolocationPrivate.h: Added.
196 * WebView/WebUIDelegatePrivate.h:
198 2009-03-13 Anders Carlsson <andersca@apple.com>
200 Reviewed by Dan Bernstein.
202 <rdar://problem/6610666> Revise the Cocoa event model text API
204 Replace the text input API with a simpler API that uses a separate text input window.
206 * Plugins/WebNetscapePluginEventHandlerCocoa.h:
207 * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
208 (WebNetscapePluginEventHandlerCocoa::WebNetscapePluginEventHandlerCocoa):
209 Initialize m_keyEventHandler to 0.
211 (WebNetscapePluginEventHandlerCocoa::keyDown):
212 If the plug-in returns 0 from NPP_HandleEvent, pass the event to the TSM machinery.
214 (WebNetscapePluginEventHandlerCocoa::focusChanged):
215 Install/remove the key event handler as needed.
217 (WebNetscapePluginEventHandlerCocoa::handleTSMEvent):
218 Get the text and send a TextInput event.
220 * Plugins/WebNetscapePluginView.h:
221 * Plugins/WebNetscapePluginView.mm:
222 Remove the old text input API.
224 (-[WebNetscapePluginView inputContext]):
225 Always return nil here.
228 * Plugins/nptextinput.h: Removed.
230 2009-03-12 Anders Carlsson <andersca@apple.com>
232 Reviewed by Mike Thole and Mark Rowe.
234 Fix <rdar://problem/6624105>.
236 Make sure to process incoming messages for the NSEventTrackingRunLoopMode as well.
238 * Plugins/Hosted/NetscapePluginHostProxy.mm:
239 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
241 2009-03-12 Anders Carlsson <andersca@apple.com>
243 Reviewed by Geoffrey Garen.
245 WebKit side of <rdar://problem/6607801>
247 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
248 (WebKit::NetscapePluginInstanceProxy::destroy):
249 Pass a requestID to _WKPCDestroyPluginInstance and wait until we get a reply back.
251 * Plugins/Hosted/WebKitPluginHost.defs:
252 Add requestID parameter.
254 2009-03-12 Kevin Decker <kdecker@apple.com>
256 Reviewed by Anders Carlsson.
258 * Plugins/WebNetscapePluginPackage.mm:
259 (-[WebNetscapePluginPackage _unloadWithShutdown:]): Simply a small SUPPORT_CFM code block.
261 2009-03-12 Kevin Decker <kdecker@apple.com>
263 Reviewed by Anders Carlsson.
265 Fixed: <rdar://problem/5815862> Opening a subclassed NSWindow from a Safari plugin causes Safari to crash on Quit
267 This fix addresses crashes in both Silverlight and ChemDraw. This type of crash would occur because AppKit still
268 had a reference to open windows that the plugin created (which no longer exist).
270 * Plugins/WebNetscapePluginPackage.mm:
271 (-[WebNetscapePluginPackage _unloadWithShutdown:]): Do not unload the plug-in bundle on browser shutdown.
273 2009-03-11 David Kilzer <ddkilzer@apple.com>
275 Remove duplicate header include
277 Rubber-stamped by Mark Rowe.
279 * WebView/WebView.mm: Remove duplicate #include <runtime/InitializeThreading.h>.
280 Also realphabetized lowercase #include statements.
282 2009-03-11 David Kilzer <ddkilzer@apple.com>
284 Clarify comments regarding order of FEATURE_DEFINES
286 Rubber-stamped by Mark Rowe.
288 * Configurations/WebKit.xcconfig: Added warning about the
289 consequences when FEATURE_DEFINES are not kept in sync.
291 2009-03-11 Anders Carlsson <andersca@apple.com>
293 Reviewed by Sam Weinig.
295 WebKit side of <rdar://problem/6656147>.
297 * Plugins/Hosted/NetscapePluginHostManager.mm:
298 (WebKit::NetscapePluginHostManager::instantiatePlugin):
299 Pass the requestID to _WKPHInstantiatePlugin.
301 * Plugins/Hosted/NetscapePluginHostProxy.mm:
302 Pass the requestID to setCurrentReply.
304 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
305 (WebKit::NetscapePluginInstanceProxy::setCurrentReply):
306 Store the reply in a map with the requestID as the key.
308 (WebKit::NetscapePluginInstanceProxy::waitForReply):
309 Wait for a reply that matches the given requestID.
311 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
312 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
313 Initialize member variables.
315 (WebKit::NetscapePluginInstanceProxy::~NetscapePluginInstanceProxy):
318 (WebKit::NetscapePluginInstanceProxy::print):
319 Pass the requestID to _WKPHPluginInstancePrint.
321 (WebKit::NetscapePluginInstanceProxy::loadRequest):
322 Rename m_currentRequestID to m_currentURLRequestID.
324 (WebKit::NetscapePluginInstanceProxy::processRequestsAndWaitForReply):
325 Process requests until we find a reply with the right requestID.
327 (WebKit::NetscapePluginInstanceProxy::createBindingsInstance):
328 Pass a requestID to the _WKPH function.
330 (WebKit::NetscapePluginInstanceProxy::nextRequestID):
333 * Plugins/Hosted/ProxyInstance.mm:
334 Pass a requestID to the _WKPH functions.
336 * Plugins/Hosted/WebKitPluginClient.defs:
337 * Plugins/Hosted/WebKitPluginHost.defs:
338 Add requestID parameters.
340 2009-03-11 Anders Carlsson <andersca@apple.com>
342 Reviewed by Darin Adler.
344 Fix <rdar://problem/6620064>.
346 * Plugins/WebPluginContainerPrivate.h:
348 2009-03-10 Xan Lopez <xlopez@igalia.com>
350 Build fix, no review.
352 * WebView/WebFrame.mm:
353 (-[WebFrame _smartDeleteRangeForProposedRange:]):
355 2009-03-09 Anders Carlsson <andersca@apple.com>
357 Reviewed by Kevin Decker.
359 WebKit side of <rdar://problem/6530007>
361 * Plugins/Hosted/NetscapePluginHostProxy.mm:
363 Call NetscapePluginInstanceProxy::enumerate.
365 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
366 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
367 (WebKit::NetscapePluginInstanceProxy::enumerate):
368 Enumerate the JS object and serialize its values.
370 * Plugins/Hosted/ProxyInstance.h:
371 * Plugins/Hosted/ProxyInstance.mm:
372 (WebKit::ProxyInstance::getPropertyNames):
373 Ask the plug-in host to get the property names and deserialize them.
375 * Plugins/Hosted/WebKitPluginClient.defs:
376 * Plugins/Hosted/WebKitPluginHost.defs:
378 2009-03-09 Simon Fraser <simon.fraser@apple.com>
380 Reviewed by Oliver Hunt and Cameron Zwarich
382 https://bugs.webkit.org/show_bug.cgi?id=24440
384 The sublayer added to WebHTMLView to host accelerated compositing layers needs to
385 be a subclass of NSView which allows context menu clicks through.
387 * WebView/WebHTMLView.mm:
388 (-[WebLayerHostingView rightMouseDown:]):
389 (-[WebHTMLView attachRootLayer:]):
391 2009-03-08 Mark Rowe <mrowe@apple.com>
393 Reviewed by Oliver Hunt.
395 Split ScrollAlignment and ScrollBehavior out of RenderLayer.h so that
396 Frame.h no longer needs to include it. This cuts the size of the symbols
397 for a debug build by around 3%.
399 * Plugins/WebNetscapePluginView.mm:
400 * WebView/WebFrame.mm:
401 (-[WebFrame _scrollDOMRangeToVisible:]):
402 (-[WebFrame _insertParagraphSeparatorInQuotedContent]):
403 (-[WebFrame _replaceSelectionWithFragment:selectReplacement:smartReplace:matchStyle:]):
404 * WebView/WebHTMLView.mm:
405 (-[WebHTMLView jumpToSelection:]):
406 (-[WebHTMLView centerSelectionInVisibleArea:]):
408 2009-03-07 Dan Bernstein <mitz@apple.com>
410 Reviewed by Alexey Proskuryakov.
412 - fix a bug where debug builds were clearing the HTML5 application cache
413 on application termination
415 * WebView/WebView.mm:
416 (-[WebView _close]): Call -[WebCache setDisabled:YES] instead of
419 2009-03-06 Douglas R. Davidson <ddavidso@apple.com>
421 Reviewed by Justin Garcia.
423 https://bugs.webkit.org/show_bug.cgi?id=24108
425 Update spelling and grammar checking to use the new combined text
426 checking (with automatic language identification) on Snow Leopard.
428 * WebCoreSupport/WebEditorClient.h:
429 * WebCoreSupport/WebEditorClient.mm:
430 (WebEditorClient::checkSpellingAndGrammarOfParagraph):
432 2009-03-05 Adele Peterson <adele@apple.com>
434 Reviewed by Darin Adler.
436 Fix for https://bugs.webkit.org/show_bug.cgi?id=24079
437 <rdar://problem/6611233> REGRESSION (r39549): Page loads cannot be interrupted with Command-. or Escape
438 <rdar://problem/6636563> Ctrl-tab shortcut doesn't switch tabs when focus is in text field
440 * WebView/WebHTMLView.mm: (-[WebHTMLView doCommandBySelector:]):
441 If WebKit does not support the command, we need to pass the selector to super. In this case,
442 we'll consider the event not to be handled. This is not perfect because in theory, [super doCommandBySelector:]
443 can do some action that would cause WebKit to need to consider the event handled. But in practice, I've found no
444 example of that happening and causing broken behavior.
446 2009-03-04 Mark Rowe <mrowe@apple.com>
448 Reviewed by Dan Bernstein.
450 <rdar://problem/6206172> Adoption of new Cocoa API for dictionary contextual menu
452 * WebView/WebHTMLView.mm:
453 (-[WebHTMLView _lookUpInDictionaryFromMenu:]):
455 2009-03-04 Adam Barth <abath@webkit.org>
457 Reviewed by Alexey Proskuryakov.
459 https://bugs.webkit.org/show_bug.cgi?id=24356
461 Fix WebKit style for allowUniversalAccessFromFileURLs.
463 * WebView/WebPreferenceKeysPrivate.h:
464 * WebView/WebPreferences.mm:
465 (+[WebPreferences initialize]):
466 (-[WebPreferences allowUniversalAccessFromFileURLs]):
467 (-[WebPreferences setAllowUniversalAccessFromFileURLs:]):
468 * WebView/WebPreferencesPrivate.h:
469 * WebView/WebView.mm:
470 (-[WebView _preferencesChangedNotification:]):
472 2009-03-03 David Kilzer <ddkilzer@apple.com>
474 <rdar://problem/6581203> WebCore and WebKit should install the same set of headers during installhdrs phase as build phase
476 Reviewed by Mark Rowe.
478 The fix is to add INSTALLHDRS_COPY_PHASE = YES and
479 INSTALLHDRS_SCRIPT_PHASE = YES to WebKit.xcconfig, then to
480 make sure various build phase scripts work with the installhdrs
483 * Configurations/Base.xcconfig: Defined REAL_PLATFORM_NAME
484 based on PLATFORM_NAME to work around the missing definition on
486 * Configurations/WebKit.xcconfig: Added
487 WEBCORE_PRIVATE_HEADERS_DIR variable to remove definition of
488 UMBRELLA_FRAMEWORKS_DIR for Debug and Release builds in the
489 Xcode project file. Added INSTALLHDRS_COPY_PHASE = YES and
490 INSTALLHDRS_SCRIPT_PHASE = YES.
492 2009-03-03 David Kilzer <ddkilzer@apple.com>
494 Remove last vestiges of JAVASCRIPTCORE_PRIVATE_HEADERS_DIR from WebKit
496 Reviewed by Adam Roben.
498 Use of JAVASCRIPTCORE_PRIVATE_HEADERS_DIR was removed in r37465
499 since NPAPI headers had migrated from JavaScriptCore to WebCore
502 * Configurations/WebKit.xcconfig: Removed definition of
503 JAVASCRIPTCORE_PRIVATE_HEADERS_DIR used in Production builds.
505 2009-03-03 Anders Carlsson <andersca@apple.com>
507 Reviewed by Darin Adler.
509 Fix <rdar://problem/6633834>.
511 * Plugins/Hosted/NetscapePluginHostManager.mm:
512 (WebKit::NetscapePluginHostManager::instantiatePlugin):
513 Create a new plug-in instance if the plug-in host has crashed.
515 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
516 (WebKit::NetscapePluginInstanceProxy::invalidate):
517 Add a null check for the plug-in host proxy.
519 2009-03-02 Sam Weinig <sam@webkit.org>
521 Reviewed by Mark Rowe.
523 Enable Geolocation (except on Tiger and Leopard).
525 * Configurations/WebKit.xcconfig:
527 2009-03-02 Anders Carlsson <andersca@apple.com>
529 Reviewed by Dan Bernstein.
531 WebKit part of <rdar://problem/6638658>.
533 * Plugins/Hosted/NetscapePluginHostManager.h:
534 * Plugins/Hosted/NetscapePluginHostManager.mm:
535 (WebKit::NetscapePluginHostManager::createPropertyListFile):
536 Spawn the plug-in host and wait for it to create the property list.
538 * Plugins/WebBasePluginPackage.mm:
539 (-[WebBasePluginPackage createPropertyListFile]):
540 Factor code out into a new method.
542 (-[WebBasePluginPackage pListForPath:createFile:]):
543 Call the newly added createPropertyListFile method.
545 * Plugins/WebNetscapePluginPackage.mm:
546 (-[WebNetscapePluginPackage createPropertyListFile]):
547 Tell the plug-in host manager to create a property list file for us.
549 2009-03-02 Sam Weinig <sam@webkit.org>
551 Reviewed by Geoffrey Garen.
553 Fix for <rdar://problem/6507404> Add Geolocation support.
555 This is not yet turned on for any Mac platform.
557 Add SPI to ask the embedding application whether to allow
558 Geolocation for an origin.
560 * WebCoreSupport/WebChromeClient.h:
561 * WebCoreSupport/WebChromeClient.mm:
562 (WebChromeClient::shouldAllowGeolocationForFrame):
563 * WebView/WebUIDelegatePrivate.h:
565 2009-03-02 Anders Carlsson <andersca@apple.com>
569 * Plugins/WebNetscapePluginPackage.mm:
570 (-[WebNetscapePluginPackage _tryLoad]):
572 2009-03-02 Anders Carlsson <andersca@apple.com>
574 Reviewed by John Sullivan, Ada Chan.
576 Factor loading code out into its own method and get rid of a bunch of gotos.
578 * Plugins/WebNetscapePluginPackage.mm:
579 (-[WebNetscapePluginPackage _tryLoad]):
580 (-[WebNetscapePluginPackage load]):
582 2009-03-02 Anders Carlsson <andersca@apple.com>
586 * Plugins/WebNetscapeDeprecatedFunctions.h:
588 2009-03-02 Anders Carlsson <andersca@apple.com>
590 Reviewed by John Sullivan.
592 Rename WebNetscapePluginPackage.m to WebNetscapePluginPackage.mm
594 * Plugins/WebNetscapePluginPackage.m: Removed.
595 * Plugins/WebNetscapePluginPackage.mm: Copied from mac/Plugins/WebNetscapePluginPackage.m.
597 2009-03-01 Anders Carlsson <andersca@apple.com>
599 Reviewed by Sam Weinig.
601 WebKit side of <rdar://problem/6449689>
603 Pass the visible name to the plug-in host.
605 * Plugins/Hosted/NetscapePluginHostManager.mm:
606 (WebKit::NetscapePluginHostManager::spawnPluginHost):
608 2009-02-27 Alice Liu <alice.liu@apple.com>
610 Fix <rdar://problem/6531265> REGRESSION (r39185): adding ".jpeg"
611 extension to images that already have .jpg extension
613 Reviewed by Oliver Hunt.
615 * WebView/WebHTMLView.mm:
616 (-[NSString matchesExtensionEquivalent:]):
617 (-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
618 Relax the check for the proper extension to allow for known
619 equivalents, special-cased in matchesExtensionEquivalent function.
621 2009-02-27 Anders Carlsson <andersca@apple.com>
623 Reviewed by Geoffrey Garen.
625 <rdar://problem/6631436>
626 CrashTracer: [USER] 1 crash in Safari at com.apple.WebKit • WebKit::NetscapePluginInstanceProxy::addValueToArray + 55
628 Port the NPN_Evaluate code over from WebCore instead of using the frame loader.
630 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
631 (WebKit::NetscapePluginInstanceProxy::evaluate):
633 2009-02-27 Anders Carlsson <andersca@apple.com>
635 Reviewed by Geoffrey Garen.
637 WebKit side of <rdar://problem/6626814>.
639 * Plugins/Hosted/NetscapePluginHostProxy.mm:
641 Make InvokeDefault async.
643 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
644 (WebKit::NetscapePluginInstanceProxy::addValueToArray):
645 Handle passing NPObjects back to the plug-in host.
647 * Plugins/Hosted/ProxyInstance.h:
648 (WebKit::ProxyInstance::objectID):
651 * Plugins/Hosted/WebKitPluginClient.defs:
652 Make InvokeDefault a simpleroutine.
654 2009-02-27 Timothy Hatcher <timothy@apple.com>
656 Fixes an exception by null checking the WebResource before adding it to
657 the subresources array.
659 <rdar://problem/5950769> Bug in [WebDataSource subresources] can throw an exception
661 Reviewed by Geoff Garen and Anders Carlsson.
663 * WebView/WebDataSource.mm:
664 (-[WebDataSource subresources]): Null check the WebResource before adding it.
666 2009-02-27 Timothy Hatcher <timothy@apple.com>
668 Adds a workaround for Automator creating a WebView from a secondary thread.
670 <rdar://problem/6631951> REGRESSION (Safari 4 Beta): Automator crash on
671 secondary thread beneath -[WebView initWithFrame:frameName:groupName:]
673 Reviewed by Geoff Garen.
675 * WebView/WebView.mm:
676 (needsWebViewInitThreadWorkaround): Check for com.apple.Automator.
678 2009-02-27 Adam Barth <abarth@webkit.org>
680 Reviewed by Eric Seidel.
682 Add a preference to reduce the power of file:// URLs.
684 * WebView/WebPreferenceKeysPrivate.h:
685 * WebView/WebPreferences.mm:
686 (+[WebPreferences initialize]):
687 (-[WebPreferences allowUniversalAccessFromFileUrls]):
688 (-[WebPreferences setAllowUniversalAccessFromFileUrls:]):
689 * WebView/WebPreferencesPrivate.h:
690 * WebView/WebView.mm:
691 (-[WebView _preferencesChangedNotification:]):
693 2009-02-27 Simon Fraser <simon.fraser@apple.com>
695 Reviewed by Anders Carlsson
697 https://bugs.webkit.org/show_bug.cgi?id=24242
699 setCursor(), and resetCursorRects() on Tiger, were using global, not local
700 coordinates for elementAtPoint:
702 * WebView/WebHTMLView.mm:
706 2009-02-27 Adam Barth <abarth@webkit.org>
708 Reviewed by Eric Seidel.
710 Add a preference to reduce the power of file:// URLs.
712 * WebView/WebPreferenceKeysPrivate.h:
713 * WebView/WebPreferences.mm:
714 (+[WebPreferences initialize]):
715 (-[WebPreferences allowUniversalAccessFromFileUrls]):
716 (-[WebPreferences setAllowUniversalAccessFromFileUrls:]):
717 * WebView/WebPreferencesPrivate.h:
718 * WebView/WebView.mm:
719 (-[WebView _preferencesChangedNotification:]):
721 2009-02-26 Adele Peterson <adele@apple.com>
723 Reviewed by Geoff Garen.
725 Fix for <rdar://problem/6618166>
726 https://bugs.webkit.org/show_bug.cgi?id=24216
727 (REGRESSION r36919) Safari 4 Beta causes MSN Messenger's text entry field to lose focus after entering a message
729 During a series of firstResponder changes, at some point while the WebHTMLView was losing first responder status,
730 we incorrectly marked the page as active, and then when the WebHTMLView became first responder again, setActive did nothing.
731 This change restores behavior from before r36919 to check if the WebHTMLView is in the middle of losing first responder when calling setActive.
733 In addition to updating editing/selection/designmode-no-caret.html results, I also made sure the test cases that were
734 fixed in r36919 and r38570 are still fixed.
736 * WebView/WebHTMLView.mm:
737 (-[WebHTMLView resignFirstResponder]): Keep track if we're in the process of resigning first responder.
738 (-[WebHTMLView _isResigningFirstResponder]): Added.
739 * WebView/WebHTMLViewInternal.h:
740 * WebView/WebView.mm: (-[WebView _updateFocusedAndActiveStateForFrame:]): Don't set the page to be active
741 if the document view is currently resigning first responder.
743 2009-02-25 Anders Carlsson <andersca@apple.com>
745 Reviewed by Kevin Decker.
747 Fix <rdar://problem/6623697>.
749 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
750 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
751 (WebKit::NetscapePluginInstanceProxy::print):
752 Ask the plug-in host to print, create a CGImage of the returned bytes and draw
753 the image into the passed in context.
755 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
756 (-[WebHostedNetscapePluginView drawRect:]):
757 When printing, call NetscapePluginInstanceProxy::print.
759 * Plugins/Hosted/WebKitPluginHost.defs:
761 2009-02-19 Alexey Proskuryakov <ap@webkit.org>
763 Reviewed by Darin Adler.
765 https://bugs.webkit.org/show_bug.cgi?id=24024
766 REGRESSION (r39845): Assertion failure in -[WebHistoryItem dictionaryRepresentation] when
767 archiving a submission to about:blank
769 I don't know how to make an automated test for this bug.
771 * History/WebHistory.mm: (-[WebHistory _visitedURL:withTitle:method:wasFailure:]):
772 Account for the fact that HTTP method may be non-empty for non-HTTP requests.
774 2009-02-25 Chris Fleizach <cfleizach@apple.com>
776 Reviewed by Beth Dakin.
779 Bug 24143: Crash occurs at WebCore::AccessibilityTable::isTableExposableThroughAccessibility() when applying a link in GMail
780 https://bugs.webkit.org/show_bug.cgi?id=24143
782 * WebView/WebFrame.mm:
783 (-[WebFrame _accessibilityTree]):
785 2009-02-25 Simon Fraser <simon.fraser@apple.com>
787 Build fix with ACCELERATED_COMPOSITING turned on.
789 I missed a spot in my last commit in renaming to
790 _stoppedAcceleratedCompositingForFrame:
792 * WebView/WebHTMLView.mm:
793 (-[WebHTMLView close]):
795 2009-02-25 Simon Fraser <simon.fraser@apple.com>
797 Reviewed by Dan Bernstein
799 https://bugs.webkit.org/show_bug.cgi?id=23854
801 Make an observable property, _isUsingAcceleratedCompositing, on
802 WebView that DumpRenderTree can use to specialize behavior.
804 This is implemented via a count of Frames that are using
805 accelerated compositing.
807 * WebView/WebHTMLView.mm:
808 (-[WebHTMLViewPrivate clear]):
809 (-[WebHTMLView close]):
810 (-[WebHTMLView attachRootLayer:]):
811 (-[WebHTMLView detachRootLayer]):
812 * WebView/WebView.mm:
813 (+[WebView automaticallyNotifiesObserversForKey:]):
814 (-[WebView _startedAcceleratedCompositingForFrame:]):
815 (-[WebView _stoppedAcceleratedCompositingForFrame:]):
816 (-[WebView _isUsingAcceleratedCompositing]):
817 * WebView/WebViewInternal.h:
818 * WebView/WebViewPrivate.h:
820 2009-02-24 Sam Weinig <sam@webkit.org>
822 Reviewed by Geoffrey Garen.
824 Related to <rdar://problem/6590295>
825 Allow disabling javascript: urls.
827 * WebView/WebView.mm:
828 (-[WebView _setJavaScriptURLsAreAllowed:]):
829 * WebView/WebViewPrivate.h:
831 2009-02-24 Mark Rowe <mrowe@apple.com>
833 Reviewed by Oliver Hunt.
835 <rdar://problem/6259220> Rename AVAILABLE_AFTER_WEBKIT_VERSION_3_1 (etc.) to match the other macros
837 * Carbon/CarbonUtils.h:
838 * Carbon/HIWebView.h:
839 * Plugins/WebPlugin.h:
840 * Plugins/WebPluginViewFactory.h:
841 * WebView/WebUIDelegate.h:
843 2009-02-24 Peter Ammon <pammon@apple.com>
845 Reviewed by Mark Rowe.
847 Fix <rdar://problem/6251410> Services can modify non-editable content in Safari
849 * WebView/WebHTMLView.mm:
850 (-[WebHTMLView validRequestorForSendType:returnType:]): Return self only if we can handle
851 both the send and return type. We should also handle a nil send or return type by ignoring
852 the argument and returning whether we can handle the other type passed in.
854 2009-02-23 Anders Carlsson <andersca@apple.com>
856 Reviewed by Geoffrey Garen and Darin Adler.
858 WebKit side of <rdar://problem/6613151>.
860 Make sure to vm_deallocate all memory we get from MIG callbacks.
862 * Plugins/Hosted/NetscapePluginHostProxy.mm:
863 (DataDeallocator::DataDeallocator):
864 (DataDeallocator::~DataDeallocator):
865 Add a simple deallocator class.
869 (WKPCBooleanAndDataReply):
871 (WKPCGetStringIdentifier):
876 Use the new deallocator class.
878 2009-02-23 Anders Carlsson <andersca@apple.com>
880 Reviewed by Darin Adler.
882 Fix <rdar://problem/6450656>.
884 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
885 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
886 (WebKit::NetscapePluginInstanceProxy::insertText):
887 Add insert text which just calls the new WKPH function.
889 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
890 (-[WebHostedNetscapePluginView inputContext]):
891 Get the input context from the shared input panel.
893 (-[WebHostedNetscapePluginView keyDown:]):
894 Let the shared input panel have a go at the event first.
896 * Plugins/Hosted/WebKitPluginHost.defs:
897 Add new InsertText function.
899 2009-02-23 Mark Rowe <mrowe@apple.com>
901 Fix the build after r41126.
903 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
904 (WebKit::NetscapePluginInstanceProxy::invoke):
905 (WebKit::NetscapePluginInstanceProxy::invokeDefault):
906 (WebKit::NetscapePluginInstanceProxy::construct):
908 2009-02-22 Dan Bernstein <mitz@apple.com>
910 Reviewed by Darin Adler.
912 - fix <rdar://problem/5966123> REGRESSION (r30741): Generic Sun Applet loading logo appears half off screen
914 * WebCoreSupport/WebFrameLoaderClient.mm: Correct a copy & paste error
915 in r30741, and assign the height value, rather than the width, to the
918 2009-02-21 Anders Carlsson <andersca@apple.com>
922 * Plugins/Hosted/WebTextInputWindowController.m:
924 2009-02-20 Anders Carlsson <andersca@apple.com>
926 Reviewed by Dan Bernstein.
928 Add a shared floating text input window implementation, to be used by the hosted plug-in view.
930 * Plugins/Hosted/WebTextInputWindowController.h: Added.
931 * Plugins/Hosted/WebTextInputWindowController.m: Added.
933 2009-02-20 Kevin Decker <kdecker@apple.com>
935 Reviewed by andersca.
937 <rdar://problem/6496140> Safari sometimes hangs in WKSetMetadataURL for several seconds after downloading a file
939 Spawn a background thread for WKSetMetadataURL because this function will not return until mds has journaled the data
940 we are trying to set. Depending on what other I/O is going on, it can take some time.
942 * Misc/WebNSFileManagerExtras.m: Import pthread.h and FoundationExtras.h
943 (setMetaData): Added. Calls WKSetMetadataURL().
944 (-[NSFileManager _webkit_setMetadataURL:referrer:atPath:]): Call setMetaData on a background thread
946 2009-02-19 Dan Bernstein <mitz@apple.com>
948 Reviewed by Sam Weinig.
950 - WebKit part of fixing https://bugs.webkit.org/show_bug.cgi?id=24027
951 Do not send loader callbacks during CSS styling
953 * WebView/WebView.mm:
954 (-[WebView _preferencesChangedNotification:]): Reverted the
955 iChat-specific quirk added in <http://trac.webkit.org/changeset/41071>.
957 2009-02-18 Dan Bernstein <mitz@apple.com>
959 Reviewed by Brady Eidson.
961 - WebKit part of fixing <rdar://problem/6507512> Crash in iChat at CSSStyleSelector::adjustRenderStyle
963 * WebView/WebView.mm:
964 (-[WebView _preferencesChangedNotification:]): Activate the WebCore
965 workaround for this crash in iChat.
967 2009-02-18 Anders Carlsson <andersca@apple.com>
969 Reviewed by Sam Weinig.
971 Fix for <rdar://problem/6542390>
973 There's no need to call setDefersLoading here - we already defer anything a plug-in can do that
974 would cause a load to begin.
976 * Plugins/WebNetscapePluginView.mm:
977 (-[WebNetscapePluginView sendEvent:isDrawRect:]):
979 2009-02-18 Adam Roben <aroben@apple.com>
981 Add SPI to get WebKit's custom pointing-hand cursor
983 Reviewed by John Sullivan.
985 * WebView/WebView.mm:
986 (+[WebView _pointingHandCursor]): Added. Returns the custom
987 pointing-hand cursor that WebKit uses.
988 * WebView/WebViewPrivate.h: Added +_pointingHandCursor.
990 2009-02-17 Eric Carlson <eric.carlson@apple.com>
992 Reviewed by Antti Koivisto.
994 https://bugs.webkit.org/show_bug.cgi?id=23917
995 Allow a WebKit plug-in to act as a proxy for the <audio> and <video>
998 * Plugins/WebPluginContainerPrivate.h:
999 * Plugins/WebPluginController.mm:
1000 (mediaProxyClient): New, cast to HTMLMediaElement if it is a video or audio element
1001 (-[WebPluginController _setMediaPlayerProxy:forElement:]): New, pass proxy to HTMLMediaElement
1002 (-[WebPluginController _postMediaPlayerNotification:forElement:]): New, deliver event to HTMLMediaElement
1004 * WebCoreSupport/WebFrameLoaderClient.mm:
1005 (WebFrameLoaderClient::createPlugin): Don't allow a media player proxy plug-in to be chosen by
1006 file extension, only want a match for the new MIME type proxy plug-ins should have.
1008 2009-02-13 Anders Carlsson <andersca@apple.com>
1010 Reviewed by Kevin Decker.
1012 <rdar://problem/6584834> ESPN radio live stream link hangs Safari
1014 When a plug-in invokes JavaScript code that will destroy the plug-in, we need to
1015 defer destruction until we're done executing the script.
1017 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1018 (WebKit::PluginDestroyDeferrer::PluginDestroyDeferrer):
1019 (WebKit::PluginDestroyDeferrer::~PluginDestroyDeferrer):
1020 Add a simple RAII object for deferring destruction of the plug-in instance.
1024 (WKPCInvokeDefault):
1028 (WKPCRemoveProperty):
1031 Use the PluginDestroyDeferrer.
1033 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1034 (WebKit::NetscapePluginInstanceProxy::pluginID):
1035 Assert that the plug-in ID is not 0 here.
1037 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1038 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
1039 Initialize the call depth.
1041 (WebKit::NetscapePluginInstanceProxy::~NetscapePluginInstanceProxy):
1042 Set the plug-in ID to 0 to aid debugging.
1044 (WebKit::NetscapePluginInstanceProxy::willCallPluginFunction):
1045 Increment the call depth.
1047 (WebKit::NetscapePluginInstanceProxy::didCallPluginFunction):
1048 Decrement the call depth, if it's 0 and we should stop the plug-in, do so.
1050 (WebKit::NetscapePluginInstanceProxy::shouldStop):
1051 If we're called this with a non-zero call depth, set shouldStopSoon to true.
1053 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1054 (-[WebHostedNetscapePluginView shouldStop]):
1057 2009-02-12 Brady Eidson <beidson@apple.com>
1059 Reviewed by Kevin Decker
1061 <rdar://problem/6582180> - Wrong HTTP method applied to history item.
1063 * WebCoreSupport/WebFrameLoaderClient.mm:
1064 (WebFrameLoaderClient::updateGlobalHistory): Check the original request, not any
1067 2009-02-12 Anders Carlsson <andersca@apple.com>
1069 Reviewed by Kevin Decker.
1071 <rdar://problem/6579412>
1072 REGRESSION (3.2.1-ToT): Crash in Silverlight viewing streaming lecture
1074 * Plugins/WebNetscapePluginView.h:
1075 * Plugins/WebNetscapePluginView.mm:
1076 (-[WebNetscapePluginView userAgent]):
1077 Apply workaround for Silverlight workaround.
1079 (-[WebNetscapePluginView _createPlugin]):
1080 Check if the plug-in that we're creating is the silverlight plug-in.
1082 2009-02-12 Brady Eidson <beidson@apple.com>
1084 Reviewed by Darin Adler
1086 Fix potential ref-count or null-deref problems with C++ objects as Obj-C members.
1088 * History/WebBackForwardList.mm:
1089 (-[WebBackForwardList dealloc]): Null check before deref()'ing.
1090 (-[WebBackForwardList finalize]): Ditto.
1092 * Misc/WebIconFetcher.mm:
1093 (-[WebIconFetcher dealloc]): Null check before deref()'ing.
1094 (-[WebIconFetcher finalize]): Ditto.
1096 * WebCoreSupport/WebEditorClient.mm: Change to use RefPtr<> instead of ref()/deref().
1097 (-[WebEditCommand initWithEditCommand:]):
1098 (-[WebEditCommand dealloc]):
1099 (-[WebEditCommand finalize]):
1100 (-[WebEditCommand command]):
1102 * WebView/WebArchive.mm: Change to use RefPtr<> instead of ref()/deref().
1103 (-[WebArchivePrivate init]):
1104 (-[WebArchivePrivate initWithCoreArchive:]):
1105 (-[WebArchivePrivate coreArchive]):
1106 (-[WebArchivePrivate setCoreArchive:]):
1107 (-[WebArchivePrivate dealloc]):
1108 (-[WebArchivePrivate finalize]):
1110 * WebView/WebDataSource.mm:
1111 (-[WebDataSourcePrivate dealloc]): Null check before deref()'ing.
1112 (-[WebDataSourcePrivate finalize]): Ditto.
1114 2009-02-12 Brady Eidson <beidson@apple.com>
1116 Reviewed by Kevin Decker
1118 <rdar://problem/6579750> - Crash in WebArchivePrivate in Tiger TextEdit
1120 NSHTMLReader tries to create a WebArchive from a random chunk of data. Previously, WebArchive creation would
1121 fail and return nil and NSHTMLReader would try something else. When we changed the behavior to return an invalid
1122 WebArchive object, things started getting weird.
1124 * WebView/WebArchive.mm:
1125 (-[WebArchivePrivate setCoreArchive:]): Null check the pointer before calling ->deref()
1126 (-[WebArchivePrivate dealloc]): Remove the ASSERT which is now invalid, and null check the pointer before ->deref().
1127 (-[WebArchivePrivate finalize]): Ditto
1128 (-[WebArchive initWithData:]): If the LegacyWebArchive cannot be created, return nil instead of an invalid object.
1130 2009-02-11 Mark Rowe <mrowe@apple.com>
1134 * History/WebHistory.mm:
1135 (-[WebHistoryPrivate visitedURL:withTitle:]): Use ASSERT_UNUSED in a manner that makes sense.
1137 2009-02-11 Brady Eidson <beidson@apple.com>
1139 Reviewed by Mark Rowe
1141 <rdar://problem/6570573> Some visit counts in History.plist have insanely high values, can roll over to negative
1143 Remove the item from the date caches before registering the visit. Otherwise it might not be successfully removed
1144 and when we add it back later it will exist in the list twice. This will cause the entry to be written out twice,
1145 which would lead to doubling (or more!) the visit count on next launch when these multiple items are merged.
1147 * History/WebHistory.mm:
1148 (-[WebHistoryPrivate visitedURL:withTitle:]): Swap the removeItemFromDateCaches and visitedWithTitle calls.
1149 (-[WebHistoryPrivate addItem:discardDuplicate:]): Add a mode that allows the entry being added to be discarded
1150 if an entry for the URL already exists. Use that mode when reading the History.plist so only the most
1151 recent entry for a given URL will be used.
1152 (-[WebHistoryPrivate addItems:]):
1153 (-[WebHistoryPrivate loadHistoryGutsFromURL:savedItemsCount:collectDiscardedItemsInto:error:]):
1155 2009-02-11 Dimitri Dupuis-latour <dupuislatour@apple.com>
1157 Added a preference to disable some Inspector's panels (rdar://6419624, rdar://6419645).
1158 This is controlled via the 'WebKitInspectorHiddenPanels' key; if nothing is specified, all panels are shown.
1160 Reviewed by Timothy Hatcher.
1162 * WebCoreSupport/WebInspectorClient.h:
1163 * WebCoreSupport/WebInspectorClient.mm:
1164 (WebInspectorClient::hiddenPanels):
1166 2009-02-11 Alexey Proskuryakov <ap@webkit.org>
1168 Reviewed by Darin Adler.
1170 <rdar://problem/6562920> Pasted text should be normalized to NFC
1172 * Misc/WebNSURLExtras.mm: (-[NSURL _web_userVisibleString]): Route the URL string through
1173 -[NSString precomposedStringWithCanonicalMapping].
1175 * WebCoreSupport/WebPasteboardHelper.mm:
1176 (WebPasteboardHelper::plainTextFromPasteboard): Ditto.
1178 * WebView/WebHTMLView.mm:
1179 (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
1180 Ditto. The affected cases are all plain text ones - RTF, RTFD and HTML are assumed to be
1181 precomposed already, and the conversion is performed outside WebKit for those anyway.
1183 2009-02-10 John Sullivan <sullivan@apple.com>
1185 Reviewed by Dan Bernstein
1187 <https://bugs.webkit.org/show_bug.cgi?id=23889>, <rdar://problem/6572300>
1188 Negative visit counts stored in History.plist aren't corrected.
1190 It's not clear how a huge negative visit count ended up in History.plist, but we can't
1191 trust data read from disk so we can at least reset this to something sane. WebCore has
1192 no guard against a visit count overflowing an int, but that seems very unlikely to have
1195 * History/WebHistoryItem.mm:
1196 (-[WebHistoryItem initFromDictionaryRepresentation:]):
1197 If a negative visit count is in the dictionary, replace it with 1. If a negative daily or
1198 weekly visit count is in the dictionary, replace it with 0.
1200 2009-02-10 John Sullivan <sullivan@apple.com>
1202 Reviewed by Dan Bernstein
1204 <https://bugs.webkit.org/show_bug.cgi?id=23891>
1205 [WebHistoryItem _setVisitCount:] is unused and should be removed
1207 * History/WebHistoryItem.mm:
1208 (-[WebHistoryItem _setVisitCount:]):
1209 removed this unused method, which is a synonym for setVisitCount: that was introduced
1210 recently and abandoned even more recently
1212 * History/WebHistoryItemInternal.h:
1213 removed declaration of _setVisitCount:
1215 2009-02-10 Anders Carlsson <andersca@apple.com>
1217 Reviewed by Mark Rowe.
1219 <rdar://problem/6573916>
1220 CrashTracer: [USER] 1 crash in Safari at com.apple.WebKit • WebKit::NetscapePluginInstanceProxy::pluginHostDied + 25.
1222 * Plugins/Hosted/NetscapePluginHostManager.mm:
1223 (WebKit::NetscapePluginHostManager::instantiatePlugin):
1224 If we failed to instantiate the plug-in, invalidate the instance proxy.
1226 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1227 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1228 (WebKit::NetscapePluginInstanceProxy::invalidate):
1229 Remove the instance from the plug-in host's set.
1231 (WebKit::NetscapePluginInstanceProxy::destroy):
1234 2009-02-09 Mark Rowe <mrowe@apple.com>
1236 Reviewed by Dan Bernstein.
1238 Fix <https://bugs.webkit.org/show_bug.cgi?id=23863> / <rdar://problem/6571390>.
1239 Bug 23863: Reproducible crash in Mail with TOT WebKit when creating a new message
1241 * WebView/WebHTMLView.mm:
1242 (-[WebHTMLView _removeMouseMovedObserverUnconditionally]): Nil-check _private as it may have not
1243 yet been initialized if this WebHTMLView was loaded from a nib.
1244 (-[WebHTMLView _removeSuperviewObservers]): Ditto.
1246 2009-02-09 Eric Seidel <eric@webkit.org>
1248 Reviewed by Dave Hyatt.
1250 Rename Selection to VisibleSelection to allow us to separate
1251 the selections the user works with from the ones used by
1252 the JS editing APIs.
1253 https://bugs.webkit.org/show_bug.cgi?id=23852
1255 * WebView/WebFrame.mm:
1256 (-[WebFrame _selectNSRange:]):
1257 * WebView/WebView.mm:
1258 (-[WebView textIteratorForRect:]):
1260 2009-02-06 Anders Carlsson <andersca@apple.com>
1262 Reviewed by Kevin Decker.
1264 Fix crash when plug-in host dies.
1266 * Plugins/Hosted/HostedNetscapePluginStream.mm:
1267 (WebKit::HostedNetscapePluginStream::didFail):
1269 2009-02-05 Eric Seidel <eric@webkit.org>
1271 Reviewed by Justin Garcia.
1273 DOMSelection.getRangeAt() returns a different range than the selection
1274 https://bugs.webkit.org/show_bug.cgi?id=23601
1276 Rename toRange to toNormalizedRange and add new firstRange which returns an unmodified range
1278 * WebView/WebFrame.mm:
1279 (-[WebFrame _rangeByAlteringCurrentSelection:SelectionController::direction:SelectionController::granularity:]):
1280 (-[WebFrame _markDOMRange]):
1281 (-[WebFrame _replaceSelectionWithText:selectReplacement:smartReplace:]):
1282 (-[WebFrame _selectedNSRange]):
1283 * WebView/WebHTMLView.mm:
1284 (-[WebHTMLView _selectedRange]):
1285 (-[WebTextCompleteController doCompletion]):
1286 (-[WebHTMLView selectedAttributedString]):
1287 * WebView/WebView.mm:
1288 (-[WebView textIteratorForRect:]):
1289 (-[WebView selectedDOMRange]):
1291 2009-02-06 Geoffrey Garen <ggaren@apple.com>
1293 Reviewed by Sam Weinig.
1295 Part III of <rdar://problem/6552272>.
1297 Refactored to use the redirect data WebCore makes available, instead of
1298 tracking loading state in WebKit.
1300 * History/WebHistory.mm:
1301 (-[WebHistoryPrivate dealloc]):
1302 (-[WebHistory _visitedURL:withTitle:method:wasFailure:]):
1303 (-[WebHistory _visitedURLForRedirectWithoutHistoryItem:]):
1304 * History/WebHistoryInternal.h:
1305 * WebCoreSupport/WebFrameLoaderClient.h:
1306 * WebCoreSupport/WebFrameLoaderClient.mm:
1307 (WebFrameLoaderClient::updateGlobalHistory):
1308 (WebFrameLoaderClient::updateGlobalHistoryRedirectLinks):
1310 2009-02-06 Anders Carlsson <andersca@apple.com>
1312 Reviewed by Sam Weinig.
1314 <rdar://problem/6562220>
1315 CrashTracer: [USER] 21 crashes in Safari at com.apple.WebKit • WebKit::NetscapePluginHostProxy::port
1317 Make the handling of crashes in the plug-in host more robust.
1319 * Plugins/Hosted/NetscapePluginHostProxy.h:
1322 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1323 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
1324 Initialize m_portSet.
1326 (WebKit::NetscapePluginHostProxy::~NetscapePluginHostProxy):
1329 (WebKit::NetscapePluginHostProxy::processRequests):
1330 Listen for messages on the port set. If we get a message to the port death notification port,
1331 then call pluginHostDied. Otherwise, process the message.
1333 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1334 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1335 (WebKit::NetscapePluginInstanceProxy::cleanup):
1336 Factor code that should be shared between destroy() and pluginHostDied() into cleanup.
1338 (WebKit::NetscapePluginInstanceProxy::destroy):
1341 (WebKit::NetscapePluginInstanceProxy::pluginHostDied):
1344 (WebKit::NetscapePluginInstanceProxy::processRequestsAndWaitForReply):
1345 Call NetscapePluginHostProxy::processRequests.
1347 * Plugins/Hosted/ProxyInstance.mm:
1348 (WebKit::ProxyInstance::invalidate):
1349 Add a null check for the host proxy.
1351 2009-02-06 Dan Bernstein <mitz@apple.com>
1353 - try to fix the Tiger build
1355 * Misc/WebNSArrayExtras.h:
1357 2009-02-06 Anders Carlsson <andersca@apple.com>
1359 Reviewed by Dan Bernstein.
1361 <rdar://problem/6563650>
1362 Add Netscape plug-in API to tell the browser not to load streams (some plug-ins handle network loading manually)
1364 * Plugins/WebNetscapePluginView.mm:
1365 (-[WebNetscapePluginView loadStream]):
1366 (-[WebNetscapePluginView pluginView:receivedData:]):
1367 (-[WebNetscapePluginView _shouldCancelSrcStream]):
1369 2009-02-05 Maciej Stachowiak <mjs@apple.com> and Brady Eidson <beidson@apple.com>
1371 Reviewed by Dan Bernstein and Geoff Garen.
1373 - WebKit code to track per-day and per-week visit counts in history
1375 For now this data is only exposed via SPI for performance reasons.
1377 * History/WebHistoryItem.mm:
1378 (-[WebHistoryItem initFromDictionaryRepresentation:]): Add parsing support
1380 (-[WebHistoryItem _recordInitialVisit]): Tell WebCore to record an initial visit.
1381 (-[WebHistoryItem dictionaryRepresentation]): Add saving support for new data.
1382 (-[WebHistoryItem _getDailyVisitCounts:]): SPI accessor.
1383 (-[WebHistoryItem _getWeeklyVisitCounts:]): SPI accessor.
1384 * History/WebHistoryItemInternal.h: Declare new methods.
1385 * History/WebHistoryItemPrivate.h: Ditto.
1387 * History/WebHistory.mm:
1388 (-[WebHistoryPrivate visitedURL:withTitle:]): For the initial visit, use
1389 the new _recordInitialVisit method instead of setting visit count to 1.
1391 * Misc/WebNSArrayExtras.h:
1392 * Misc/WebNSArrayExtras.m:
1393 (-[NSArray _webkit_numberAtIndex:]): Helper to retrieve an NSNumber or nil from an NSArray
1394 (-[NSArray _webkit_stringAtIndex:]): Helper to retrieve an NSString of nil from an NSArray
1396 2009-02-05 Aaron Boodman <aa@chromium.org>
1398 Reviewed by Dave Hyatt.
1400 https://bugs.webkit.org/show_bug.cgi?id=23708
1401 Adds documentElementAvailable() callback to FrameLoaderClient.
1403 * WebCoreSupport/WebFrameLoaderClient.h:
1404 Stub out documentElementAvailable().
1405 * WebCoreSupport/WebFrameLoaderClient.mm:
1408 2009-02-05 Dan Bernstein <mitz@apple.com>
1412 * WebView/WebScriptDebugger.mm:
1413 (WebScriptDebugger::initGlobalCallFrame):
1415 2009-02-05 Beth Dakin <bdakin@apple.com>
1417 Reviewed by John Sullivan and Brady Eidson.
1419 Fix for <rdar://problem/6557595> REGRESSION: In Mail, selecting a
1420 mail note message doesn't display it in Mail's preview pane
1422 This was failing because revision 36962 removed a version of
1423 setVerticalScrollingMode that mail calls. This patch simply adds
1426 * WebView/WebDynamicScrollBarsView.m:
1427 (-[WebDynamicScrollBarsView setVerticalScrollingMode:]):
1429 2009-02-04 Anders Carlsson <andersca@apple.com>
1433 * WebView/WebScriptDebugger.mm:
1434 (WebScriptDebugger::initGlobalCallFrame):
1436 2009-02-04 Anders Carlsson <andersca@apple.com>
1438 Reviewed by Sam Weinig.
1440 Change PCHasProperty, PCHasMethod and PCGetProperty into simpleroutines.
1442 Rename PHEvaluateReply to PHBooleanAndDataReply and add PHBooleanReply.
1444 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1450 * Plugins/Hosted/WebKitPluginClient.defs:
1451 * Plugins/Hosted/WebKitPluginHost.defs:
1453 2009-02-04 Anders Carlsson <andersca@apple.com>
1455 Reviewed by Mark Rowe.
1459 * WebView/WebScriptDebugger.mm:
1460 (WebScriptDebugger::initGlobalCallFrame):
1462 2009-02-04 Geoffrey Garen <ggaren@apple.com>
1464 Reviewed by Mark Rowe.
1466 Part I of <rdar://problem/6552272>.
1468 Clear the redirectURLs entry when first visiting a site, so sites that
1469 only redirect you the first time you visit them can later learn that
1470 they don't redirect.
1472 * History/WebHistory.mm:
1473 (-[WebHistory _visitedURL:withTitle:method:wasFailure:serverRedirectURL:isClientRedirect:]):
1475 2009-02-04 Timothy Hatcher <timothy@apple.com>
1477 Change the WebSourceId typedef from int to intptr_t now that <rdar://problem/6263297> is fixed.
1479 <rdar://problem/6263293> WebScriptDebugDelegate should use intptr_t for sourceId, not int
1481 Reviewed by Oliver Hunt.
1483 * WebView/WebScriptDebugDelegate.h:
1485 2009-02-04 Timothy Hatcher <timothy@apple.com>
1487 Switched over from using the WebSafeForwarder for the Script Debug
1488 delegate and added high performance CallScriptDebugDelegate functions.
1490 <rdar://problem/6508457> Launching widget in Dashcode debugger is
1491 super-slow due forwardInvocation: calling debug delegate
1493 Reviewed by Oliver Hunt.
1495 * DefaultDelegates/WebDefaultScriptDebugDelegate.h: Removed.
1496 * DefaultDelegates/WebDefaultScriptDebugDelegate.m: Removed.
1497 * WebView/WebScriptDebugger.mm:
1498 (WebScriptDebugger::initGlobalCallFrame): Use CallScriptDebugDelegate.
1499 (WebScriptDebugger::sourceParsed): Ditto.
1500 (WebScriptDebugger::callEvent): Ditto.
1501 (WebScriptDebugger::atStatement): Ditto.
1502 (WebScriptDebugger::returnEvent): Ditto.
1503 (WebScriptDebugger::exception): Ditto.
1504 * WebView/WebView.mm:
1505 (-[WebViewPrivate dealloc]): Removed scriptDebugDelegateForwarder.
1506 (-[WebView _cacheScriptDebugDelegateImplementations]): Added. Gets the
1507 method implementations for the script debug delegate. Also caches what
1508 didParseSource method to use.
1509 (WebViewGetScriptDebugDelegateImplementations): Added. Returns the
1510 WebScriptDebugDelegateImplementations structure.
1511 (-[WebView setScriptDebugDelegate:]): Call _cacheScriptDebugDelegateImplementations.
1512 (CallDelegate): Added more overloaded versions that take different arguments.
1513 (CallScriptDebugDelegate): Added overloaded versions that take different arguments.
1514 * WebView/WebViewInternal.h:
1516 2009-02-03 Simon Fraser <simon.fraser@apple.com>
1518 Reviewed by Dave Hyatt
1520 https://bugs.webkit.org/show_bug.cgi?id=23365
1522 Hook up accelerated compositing layers the native
1525 * WebCoreSupport/WebChromeClient.h:
1526 * WebCoreSupport/WebChromeClient.mm:
1527 (WebChromeClient::attachRootGraphicsLayer):
1528 (WebChromeClient::setNeedsOneShotDrawingSynchronization):
1529 New methods to hook up the root GraphicsLayer to the native
1530 view system, and to synchronize layer changes with view-based
1531 drawing when layers come and go.
1533 * WebView/WebHTMLView.mm:
1534 (-[WebHTMLViewPrivate clear]):
1535 Clear the pointer to layerHostingView.
1537 (-[WebHTMLView _setAsideSubviews]):
1538 (-[WebHTMLView willRemoveSubview:]):
1539 Keep the special layer-hosting view in the subviews even
1540 when the rest of the subviews are ripped out for
1543 (-[WebHTMLView _isUsingAcceleratedCompositing]):
1544 New utility method for DumpRenderTree to know if we're
1547 (-[WebHTMLView drawRect:]):
1548 Call -disableScreenUpdatesUntilFlush if we have to
1549 synchronize layer changes with painting.
1551 (-[WebHTMLView attachRootLayer:]):
1552 (-[WebHTMLView detachRootLayer]):
1553 Attach and detach the root GraphicsLayer.
1555 * WebView/WebViewInternal.h:
1556 * WebView/WebHTMLViewInternal.h:
1557 * WebView/WebHTMLViewPrivate.h:
1558 New method declarations.
1560 * WebView/WebView.mm:
1561 (-[WebView _needsOneShotDrawingSynchronization]):
1562 (-[WebView _setNeedsOneShotDrawingSynchronization:]):
1563 Set the flag to say if we need to synchronize layer
1564 changes and painting on the next -drawRect: call.
1566 (-[WebView viewWillMoveToWindow:]):
1567 (-[WebView viewDidMoveToWindow]):
1568 Call new notifications that the view was added to or removed from
1569 the window, which are required by the layer hosting mechanism.
1571 2009-02-02 Geoffrey Garen <ggaren@apple.com>
1575 * Plugins/WebPluginController.mm:
1576 (-[WebPluginController webPlugInContainerLoadRequest:inFrame:]):
1578 2009-02-02 Geoffrey Garen <ggaren@apple.com>
1580 Reviewed by Sam Weinig.
1582 Track redirects in global history.
1584 * History/WebHistory.mm:
1585 (-[WebHistoryPrivate dealloc]):
1586 (-[WebHistoryPrivate lastVisitedEntry]):
1587 (-[WebHistoryPrivate setLastVisitedEntry:]): Remember the last global history
1588 entry in case we're asked to add redirect information to it later.
1590 (-[WebHistory _visitedURL:withTitle:method:wasFailure:serverRedirectURL:isClientRedirect:]):
1591 (-[WebHistory _visitedURLForRedirectWithoutHistoryItem:]): Record redirect
1592 information in global history.
1594 * History/WebHistoryInternal.h:
1595 * WebCoreSupport/WebFrameLoaderClient.h: See above and below.
1597 * WebCoreSupport/WebFrameLoaderClient.mm:
1598 (WebFrameLoaderClient::updateGlobalHistory):
1599 (WebFrameLoaderClient::updateGlobalHistoryForRedirectWithoutHistoryItem): Record redirect
1600 information in global history.
1602 * WebView/WebFrame.mm:
1603 (-[WebFrame loadRequest:]):
1604 (-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]):
1605 * WebView/WebFramePrivate.h: Updated for rename and extra parameter.
1607 2009-02-02 Anders Carlsson <andersca@apple.com>
1609 Reviewed by Dan Bernstein.
1611 Work around a limitation in MIG where two functions can't have the same name even if they're
1612 not in the same subsystem.
1614 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1615 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
1616 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1617 (WebKit::NetscapePluginInstanceProxy::processRequestsAndWaitForReply):
1618 * Plugins/Hosted/WebKitPluginClient.defs:
1619 * Plugins/Hosted/WebKitPluginHost.defs:
1621 2009-02-02 Anders Carlsson <andersca@apple.com>
1623 Reviewed by Sam Weinig.
1625 Implement WKPCGetPluginElementObject.
1627 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1628 (WKPCGetPluginElementNPObject):
1629 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1630 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1631 (WebKit::NetscapePluginInstanceProxy::getPluginElementNPObject):
1632 * Plugins/Hosted/WebKitPluginClient.defs:
1633 * Plugins/WebBaseNetscapePluginView.h:
1634 * Plugins/WebBaseNetscapePluginView.mm:
1635 (-[WebBaseNetscapePluginView WebCore::]):
1637 2009-02-02 Anders Carlsson <andersca@apple.com>
1641 * WebView/WebHTMLView.mm:
1643 2009-02-02 Anders Carlsson <andersca@apple.com>
1645 Reviewed by Dan Bernstein.
1647 Make WebBaseNetscapePluginView hold a reference to a HTMLPlugInElement instead of a DOMElement.
1649 * Plugins/Hosted/WebHostedNetscapePluginView.h:
1650 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1651 (-[WebHostedNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:element:WebCore::]):
1652 * Plugins/WebBaseNetscapePluginView.h:
1653 * Plugins/WebBaseNetscapePluginView.mm:
1654 (-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:element:WebCore::]):
1655 (-[WebBaseNetscapePluginView _windowClipRect]):
1656 (-[WebBaseNetscapePluginView visibleRect]):
1657 (-[WebBaseNetscapePluginView dataSource]):
1658 * Plugins/WebKitPluginContainerView.h: Removed.
1659 * Plugins/WebKitPluginContainerView.mm: Removed.
1660 * Plugins/WebNetscapePluginView.h:
1661 * Plugins/WebNetscapePluginView.mm:
1662 (-[WebNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:element:WebCore::]):
1663 (-[WebNetscapePluginView getVariable:value:]):
1664 * WebCoreSupport/WebFrameLoaderClient.mm:
1665 (WebFrameLoaderClient::createPlugin):
1667 2009-02-02 Anders Carlsson <andersca@apple.com>
1669 Reviewed by Dan Bernstein.
1671 Update for changes to WebCore.
1673 * WebCoreSupport/WebFrameLoaderClient.h:
1674 * WebCoreSupport/WebFrameLoaderClient.mm:
1675 (WebFrameLoaderClient::createPlugin):
1677 2009-02-02 Anders Carlsson <andersca@apple.com>
1679 Reviewed by Oliver Hunt.
1681 When a new Web View was not created, report back to the plug-in host.
1683 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1684 (WebKit::NetscapePluginInstanceProxy::performRequest):
1685 * Plugins/Hosted/WebKitPluginHost.defs:
1687 2009-02-02 Anders Carlsson <andersca@apple.com>
1689 Reviewed by Kevin Decker.
1691 Draw the regular missing plug-in icon instead of a red rect when a plug-in has crashed.
1693 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1694 (-[WebHostedNetscapePluginView drawRect:]):
1696 2009-02-02 Holger Hans Peter Freyther <zecke@selfish.org>
1698 Reviewed by Darin Adler.
1700 Move Frame::forceLayout, Frame::adjustPageHeight and Frame::forceLayoutWithPageWidthRange to FrameView
1702 https://bugs.webkit.org/show_bug.cgi?id=23428
1704 FrameView::forceLayout could be killed but the comment might
1705 contain a value over the the plain FrameView::layout...
1707 Adjust the WebCore/WebKit consumers of these methods.
1709 * WebView/WebFrame.mm:
1710 (-[WebFrame _computePageRectsWithPrintWidthScaleFactor:printHeight:]):
1711 * WebView/WebHTMLView.mm:
1712 (-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]):
1713 (-[WebHTMLView adjustPageHeightNew:top:bottom:limit:]):
1715 2009-01-31 John Sullivan <sullivan@apple.com>
1717 https://bugs.webkit.org/show_bug.cgi?id=23665
1719 Cleaned up code to add/remove NSNotification observers, to avoid performance hit
1720 of calling removeObserver with unspecified notifications, or calling removeObserver
1721 multiple times for the same notification.
1723 Reviewed by Darin Adler
1725 * WebView/WebHTMLView.mm:
1726 added observingMouseMovedNotifications, observingSuperviewNotifications, and
1727 observingWindowNotifications as BOOL ivars of _private object
1728 (-[WebHTMLView _removeMouseMovedObserverUnconditionally]):
1729 moved to file-internal section of file, added leading underscore, now bails out
1730 if we aren't observing the relevant notifications, now records that we are no longer
1731 observing the relevant notifications
1732 (-[WebHTMLView _removeSuperviewObservers]):
1733 ditto, also stores [NSNoticationCenter defaultCenter] in local var to avoid objc dispatch
1734 (-[WebHTMLView _removeWindowObservers]):
1736 (-[WebHTMLView close]):
1737 replace general removeObserver: call with three specific calls for all the notifications
1738 that this class actually observes
1739 (-[WebHTMLView addMouseMovedObserver]):
1740 bail out if already observing relevant notifications, now records that we are observing
1741 the relevant notifications
1742 (-[WebHTMLView removeMouseMovedObserver]):
1743 updated for name change
1744 (-[WebHTMLView addSuperviewObservers]):
1745 bail out if already observing relevant notifications, now records that we are observing
1746 the relevant notifications; also stores [NSNoticationCenter defaultCenter] in local var
1747 to avoid objc dispatch
1748 (-[WebHTMLView addWindowObservers]):
1750 (-[WebHTMLView viewWillMoveToSuperview:]):
1751 updated for name change
1752 (-[WebHTMLView viewWillMoveToWindow:]):
1753 updated for name changes
1755 2009-01-31 Darin Adler <darin@apple.com>
1757 Reviewed by Mark Rowe.
1759 Fix code that assumes all command selectors end in colons.
1760 rdar://problem/6545874
1762 * WebView/WebHTMLView.mm:
1763 (commandNameForSelector): Don't assert, just return a null string, when
1764 the selector doesn't end in a colon.
1766 2009-01-30 Adam Barth <abarth@webkit.org>
1768 Reviewed by Sam Weinig.
1770 Add a pref to disable web security.
1772 * WebView/WebPreferenceKeysPrivate.h:
1773 * WebView/WebPreferencesPrivate.h:
1774 * WebView/WebPreferences.mm:
1775 (+[WebPreferences initialize]):
1776 (-[WebPreferences isWebSecurityEnabled]):
1777 (-[WebPreferences setWebSecurityEnabled:]):
1778 * WebView/WebView.mm:
1779 (-[WebView _preferencesChangedNotification:]):
1781 2009-01-30 Holger Hans Peter Freyther <zecke@selfish.org>
1783 Reviewed by Darin Adler.
1785 Move Frame::sendResizeEvent and Frame::sendScrollEvent to EventHandler
1787 Carry out the move and catch up in two call sites.
1789 * WebView/WebHTMLView.mm:
1790 (-[WebHTMLView _frameOrBoundsChanged]):
1792 2009-01-30 Holger Hans Peter Freyther <zecke@selfish.org>
1794 Reviewed by Darin Adler.
1796 isFrameSet was moved from Frame to Document. Update the
1799 * WebView/WebFrame.mm:
1800 (-[WebFrame _isFrameSet]):
1801 * WebView/WebHTMLView.mm:
1802 (-[WebHTMLView knowsPageRange:]):
1804 2009-01-30 Geoffrey Garen <ggaren@apple.com>
1808 * WebView/WebFramePrivate.h:
1810 2009-01-30 Geoffrey Garen <ggaren@apple.com>
1812 Reviewed by Sam Weinig.
1814 Split "lockHistory" into "lockHistory" and "lockBackForwardList" in
1815 preparation for setting them differently during a redirect.
1817 * WebView/WebPDFView.mm:
1818 (-[WebPDFView PDFViewWillClickOnLink:withURL:]):
1820 2009-01-30 Anders Carlsson <andersca@apple.com>
1822 Reviewed by Sam Weinig.
1824 Fix <rdar://problem/6544048>
1826 Have NetscapePluginInstanceProxy keep track of all the ProxyInstance objects associated.
1828 When the plug-in instance is destroyed, invalidate all proxy instances.
1830 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1831 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1832 (WebKit::NetscapePluginInstanceProxy::destroy):
1833 (WebKit::NetscapePluginInstanceProxy::addInstance):
1834 (WebKit::NetscapePluginInstanceProxy::removeInstance):
1835 * Plugins/Hosted/ProxyInstance.h:
1836 * Plugins/Hosted/ProxyInstance.mm:
1837 (WebKit::ProxyInstance::ProxyInstance):
1838 (WebKit::ProxyInstance::~ProxyInstance):
1839 (WebKit::ProxyInstance::invalidate):
1841 2009-01-30 Anders Carlsson <andersca@apple.com>
1843 Reviewed by Sam Weinig.
1845 Fix <rdar://problem/6490778>.
1847 Change the NPRuntime related functions to use IdentifierRep directly, and make sure to always
1848 validate IdentifierReps before dereferencing them.
1850 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1852 (WKPCGetStringIdentifier):
1853 (WKPCGetIntIdentifier):
1854 (identifierFromIdentifierRep):
1858 (WKPCRemoveProperty):
1861 (WKPCIdentifierInfo):
1863 2009-01-30 Brady Eidson <beidson@apple.com>
1865 Reviewed by Sam Weinig
1867 Remove FrameLoaderClient code that is now handled by FrameLoader itself
1869 * WebCoreSupport/WebFrameLoaderClient.mm:
1870 (WebFrameLoaderClient::frameLoadCompleted):
1872 2009-01-29 Stephanie Lewis <slewis@apple.com>
1876 Update the order files.
1880 2009-01-29 Sam Weinig <sam@webkit.org>
1882 Reviewed by Anders Carlsson.
1884 Second step in tracking the urls a HistoryItem was redirected through
1885 Add SPI to access the array of redirect urls associated with a HistoryItem.
1887 * History/WebHistoryItem.mm:
1888 (-[WebHistoryItem dictionaryRepresentation]):
1889 (-[WebHistoryItem _redirectURLs]):
1890 * History/WebHistoryItemPrivate.h:
1892 2009-01-29 Anders Carlsson <andersca@apple.com>
1894 Reviewed by Dan Bernstein.
1896 Always activate the plug-in host process if we're in "modal mode" and are being told to activate.
1898 * Plugins/Hosted/NetscapePluginHostProxy.h:
1899 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1900 (WebKit::NetscapePluginHostProxy::pluginHostDied):
1903 (WebKit::NetscapePluginHostProxy::applicationDidBecomeActive):
1904 If we're modal, we should always bring the plug-in host process to the front.
1906 (WebKit::NetscapePluginHostProxy::beginModal):
1907 Add an observer for the NSApplicationWillBecomeActiveNotification callback.
1909 (WebKit::NetscapePluginHostProxy::endModal):
1910 Remove the observer.
1912 2009-01-29 Sam Weinig <sam@webkit.org>
1914 Reviewed by Mark Rowe.
1916 First step in tracking the urls a HistoryItem was redirected through.
1918 * History/WebHistoryItem.mm:
1919 (-[WebHistoryItem initFromDictionaryRepresentation:]):
1920 (-[WebHistoryItem dictionaryRepresentation]):
1921 * Misc/WebNSDictionaryExtras.h:
1922 * Misc/WebNSDictionaryExtras.m:
1923 (-[NSDictionary _webkit_arrayForKey:]): Add helper.
1925 2009-01-29 Anders Carlsson <andersca@apple.com>
1927 Reviewed by Sam Weinig.
1929 Pass the PSN of the client to the host, and get the PSN of the host back when checking in.
1931 * Plugins/Hosted/NetscapePluginHostManager.h:
1932 * Plugins/Hosted/NetscapePluginHostManager.mm:
1933 (WebKit::NetscapePluginHostManager::hostForPackage):
1934 Get the current PSN and pass it to spawnPluginHost.
1936 (WebKit::NetscapePluginHostManager::spawnPluginHost):
1937 Pass the PSN to the "check in" function.
1939 * Plugins/Hosted/NetscapePluginHostProxy.h:
1940 * Plugins/Hosted/NetscapePluginHostProxy.mm:
1941 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
1943 (WebKit::NetscapePluginHostProxy::pluginHostDied):
1944 Fix a bug noticed by Julien Chaffraix. Call endModal if necessary.
1946 (WebKit::NetscapePluginHostProxy::beginModal):
1947 (WebKit::NetscapePluginHostProxy::endModal):
1948 (WebKit::NetscapePluginHostProxy::setModal):
1949 Split out the code that does all of the work into beginModal and endModal methods.
1951 * Plugins/Hosted/WebKitPluginHost.defs:
1952 * Plugins/WebNetscapePluginView.mm:
1953 (-[WebNetscapePluginView loadStream]):
1955 2009-01-29 David Kilzer <ddkilzer@apple.com>
1957 Remove semi-colons from the end of ObjC method implementations
1959 Rubber-stamped by Adam Roben.
1961 $ find WebKit -name \*.m -o -name \*.mm -exec perl -e 'undef $/; $s = <>; while ($s =~ m/[\n\r][-+].*;[\s\r\n]+\{/g) { print "$ARGV: $&\n"; }' {} \;
1963 * DefaultDelegates/WebDefaultUIDelegate.m:
1964 (-[WebDefaultUIDelegate webView:setResizable:]):
1965 (-[WebDefaultUIDelegate webView:dragDestinationActionMaskForDraggingInfo:]):
1966 (-[WebDefaultUIDelegate webView:dragSourceActionMaskForPoint:]):
1967 (-[WebDefaultUIDelegate webView:willPerformDragSourceAction:fromPoint:withPasteboard:]):
1968 * History/WebBackForwardList.mm:
1969 (-[WebBackForwardList addItem:]):
1970 (-[WebBackForwardList backListWithLimit:]):
1971 (-[WebBackForwardList forwardListWithLimit:]):
1972 * History/WebHistoryItem.mm:
1973 (-[WebHistoryItem alternateTitle]):
1974 (-[WebHistoryItem setViewState:]):
1975 * Misc/WebCoreStatistics.mm:
1976 (+[WebCoreStatistics garbageCollectJavaScriptObjectsOnAlternateThreadForDebugging:]):
1977 * Misc/WebKitNSStringExtras.m:
1978 (-[NSString _web_drawAtPoint:font:textColor:]):
1979 * Plugins/WebNetscapePluginView.mm:
1980 (-[WebNetscapePluginView setAttributeKeys:andValues:]):
1981 * WebCoreSupport/WebEditorClient.mm:
1982 (-[WebEditCommand command]):
1983 * WebView/WebFrame.mm:
1984 (-[WebFrame _getVisibleRect:]):
1985 * WebView/WebHTMLRepresentation.mm:
1986 (-[WebHTMLRepresentation _redirectDataToManualLoader:forPluginView:]):
1987 * WebView/WebHTMLView.mm:
1988 (-[WebHTMLView elementAtPoint:allowShadowContent:]):
1989 * WebView/WebPreferences.mm:
1990 (-[WebPreferences setAllowsAnimatedImages:]):
1991 (-[WebPreferences setAutosaves:]):
1992 (-[WebPreferences PDFDisplayMode]):
1993 * WebView/WebView.mm:
1994 (+[WebView _viewClass:andRepresentationClass:forMIMEType:]):
1995 (-[WebView _viewClass:andRepresentationClass:forMIMEType:]):
1996 (+[WebView _unregisterViewClassAndRepresentationClassForMIMEType:]):
1997 (+[WebView _registerViewClass:representationClass:forURLScheme:]):
1998 (-[WebView _shouldChangeSelectedDOMRange:toDOMRange:affinity:stillSelecting:]):
1999 (-[WebView _insertNewlineInQuotedContent]):
2001 2009-01-28 Geoffrey Garen <ggaren@apple.com>
2003 Reviewed by Sam Weinig.
2005 Updated for WebCore rename.
2007 * WebView/WebView.mm:
2008 (-[WebView setCustomTextEncodingName:]):
2010 2009-01-28 David Kilzer <ddkilzer@apple.com>
2012 Add missing declaration for -[NSURL(WebNSURLExtras) _webkit_isFileURL]
2014 Reviewed by Dan Bernstein.
2016 * Misc/WebNSURLExtras.h:
2017 (-[NSURL(WebNSURLExtras) _webkit_isFileURL]): Added missing
2018 declaration after the implementation was added in r9258.
2020 2009-01-28 Sam Weinig <sam@webkit.org>
2022 Reviewed by Geoff Garen.
2024 Fix for <rdar://problem/6129678>
2025 REGRESSION (Safari 3-4): Local variable not accessible from Dashcode console or variables view
2027 * WebView/WebScriptDebugDelegate.mm:
2028 (-[WebScriptCallFrame scopeChain]): Wrap JSActivations in DebuggerActivations.
2030 2009-01-27 Anders Carlsson <andersca@apple.com>
2032 Reviewed by Oliver Hunt.
2034 Fix two bugs with Core Animation based plug-ins.
2036 1. The plug-in view was marked as opaque even though it's not.
2037 (This would leave garbage in the plug-in view).
2038 2. The plug-in layer needs to have autoresizing turned on.
2040 * Plugins/WebNetscapePluginView.mm:
2041 (-[WebNetscapePluginView setLayer:]):
2043 2009-01-27 Brady Eidson <beidson@apple.com>
2045 Reviewed by Dan Bernstein
2047 Rework FrameLoaderClient to work on a CachedFrame basis instead of CachedPage
2049 * History/WebHistoryItem.mm:
2051 * WebCoreSupport/WebFrameLoaderClient.h:
2052 * WebCoreSupport/WebFrameLoaderClient.mm:
2053 (WebFrameLoaderClient::savePlatformDataToCachedFrame):
2054 (WebFrameLoaderClient::transitionToCommittedFromCachedFrame):
2057 2009-01-26 Anders Carlsson <andersca@apple.com>
2059 Reviewed by Dan Bernstein.
2061 Add the ability for plug-ins to make WebKit operate in "modal mode"
2063 * Plugins/Hosted/NetscapePluginHostProxy.h:
2064 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2065 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
2066 (WebKit::NetscapePluginHostProxy::pluginHostDied):
2067 If the plug-in crashes while we're modal, make sure to leave the modal mode.
2069 (WebKit::NetscapePluginHostProxy::setModal):
2071 * Plugins/Hosted/WebKitPluginClient.defs:
2073 2009-01-26 John Sullivan <sullivan@apple.com>
2075 fixed <rdar://problem/6530053> REGRESSION (Leopard): Shift-tab in http authentication window gets
2076 stuck in the Name field rather than cycling around
2078 Reviewed by Dan Bernstein
2080 * Panels/English.lproj/WebAuthenticationPanel.nib/designable.nib:
2081 * Panels/English.lproj/WebAuthenticationPanel.nib/keyedobjects.nib:
2082 The two static text fields and the last button all had their "next key view" outlets set to the
2083 name field, which caused shift-tab from the name field to do the wrong thing. Fixed by making each
2084 selectable view have exactly one "next key view" set to it.
2086 2009-01-26 Anders Carlsson <andersca@apple.com>
2088 Reviewed by Sam Weinig.
2090 Add the ability for a plug-in to show or hide the menu bar.
2092 * Plugins/Hosted/NetscapePluginHostProxy.h:
2093 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2094 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
2095 (WebKit::NetscapePluginHostProxy::pluginHostDied):
2096 (WebKit::NetscapePluginHostProxy::setMenuBarVisible):
2097 (WKPCSetMenuBarVisible):
2098 * Plugins/Hosted/WebKitPluginClient.defs:
2100 2009-01-26 Cameron Zwarich <cwzwarich@uwaterloo.ca>
2102 Reviewed by Gavin Barraclough.
2104 Bug 23552: Dashcode evaluator no longer works after making ExecStates actual call frames
2105 <https://bugs.webkit.org/show_bug.cgi?id=23552>
2106 <rdar://problem/6398839>
2108 Dashcode will crash when using the evaluator because it saves a global call
2109 frame, even after global code has finished executing, and then uses this as
2110 a launching pad to execute new JS in the evaluator. The fix is to detect
2111 when Dashcode is attempting to do this and execute code from a global call
2114 * ForwardingHeaders/runtime/Protect.h: Added.
2115 * WebView/WebScriptDebugDelegate.mm:
2116 (-[WebScriptCallFrame _initWithGlobalObject:debugger:caller:debuggerCallFrame:]):
2117 Added debugger, a WebScriptDebugger* argument.
2118 (-[WebScriptCallFrame evaluateWebScript:]): Detect when Dashcode is using
2119 a stale WebScriptCallFrame to execute new JS and evaluate it starting from
2120 the global object's global call frame instead.
2121 * WebView/WebScriptDebugger.h:
2122 (WebScriptDebugger::globalObject): Added.
2123 (WebScriptDebugger::globalCallFrame): Added.
2124 * WebView/WebScriptDebugger.mm:
2125 (WebScriptDebugger::WebScriptDebugger): Initialize m_globalObject.
2126 (WebScriptDebugger::initGlobalCallFrame): Created as a clone of callEvent
2127 so that the global call frame can be saved immediately after being created.
2128 (WebScriptDebugger::callEvent): Pass 'this' as the debugger argument of
2129 WebScriptCallFrame's _initWithGlobalObject method.
2131 2009-01-26 Anders Carlsson <andersca@apple.com>
2133 Reviewed by Oliver Hunt.
2135 Make WKPCInvoke a simpleroutine.
2137 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2139 * Plugins/Hosted/WebKitPluginClient.defs:
2141 2009-01-26 Anders Carlsson <andersca@apple.com>
2143 Reviewed by Sam Weinig.
2145 Implement using plug-in objects as constructors, and setting and getting properties from a plug-in object.
2147 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2148 (WKPCBooleanAndDataReply):
2149 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2150 (WebKit::NetscapePluginInstanceProxy::Reply::):
2151 (WebKit::NetscapePluginInstanceProxy::BooleanAndDataReply::BooleanAndDataReply):
2152 Rename NPObjectInvokeReply to BooleanAndDataReply.
2154 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2155 (WebKit::NetscapePluginInstanceProxy::addValueToArray):
2156 Fix a cut and paste error.
2158 (WebKit::NetscapePluginInstanceProxy::demarshalValueFromArray):
2161 * Plugins/Hosted/ProxyInstance.h:
2162 * Plugins/Hosted/ProxyInstance.mm:
2163 (WebKit::ProxyField::valueFromInstance):
2164 (WebKit::ProxyField::setValueToInstance):
2165 Call the ProxyInstance method.
2167 (WebKit::ProxyInstance::~ProxyInstance):
2168 Release the NPObject.
2170 (WebKit::ProxyInstance::supportsConstruct):
2171 Ask the plug-in host if an instance supports construct.
2173 (WebKit::ProxyInstance::fieldValue):
2174 (WebKit::ProxyInstance::setFieldValue):
2175 Call the plug-in host methods.
2177 * Plugins/Hosted/WebKitPluginHostTypes.h:
2178 Rename ObjectValueType to JSObjectValueType, and add NPObjectValueType.
2180 2009-01-26 Mark Rowe <mrowe@apple.com>
2184 Remove -Wformat=2 from the warning flags as newer versions of GCC emit
2185 warnings about non-literal format strings for uses of our UI_STRING macro.
2187 * Configurations/Base.xcconfig:
2189 2009-01-26 Mark Rowe <mrowe@apple.com>
2191 Rubber-stamped by Sam Weinig.
2193 Clean up after r40240.
2195 * Configurations/Base.xcconfig: Don't dead code strip in debug builds for now as it leads to link errors.
2196 * Plugins/Hosted/HostedNetscapePluginStream.mm: Revert change that is no longer needed now that WebKitPluginHost.defs
2197 is back in the build.
2199 2009-01-25 Darin Adler <darin@apple.com>
2201 * Plugins/Hosted/HostedNetscapePluginStream.mm: Added a missing extern "C".
2203 2009-01-25 Darin Adler <darin@apple.com>
2205 Discussed with Mark Rowe; not sure he reviewed it.
2207 * Configurations/Base.xcconfig: Add all the same warnings as in WebCore except for
2208 -Wcast-qual and -Wunused-parameter, which both need to be off at least for now.
2210 2009-01-25 Mark Rowe <mrowe@apple.com>
2212 Rubber-stamped by Dan Bernstein.
2214 Improve the consistency of settings in our .xcconfig files.
2216 * Configurations/Base.xcconfig: Only dead code strip the normal variant.
2217 Handle all cases in GCC_GENERATE_DEBUGGING_SYMBOLS.
2219 2009-01-25 Darin Adler <darin@apple.com>
2221 Reviewed by Sam Weinig.
2223 Bug 23522: use checked casts for render tree
2224 https://bugs.webkit.org/show_bug.cgi?id=23522
2226 Step one: RenderText.
2228 * WebView/WebRenderNode.mm:
2229 (copyRenderNode): Use toRenderText.
2231 2009-01-23 Brady Eidson <beidson@apple.com>
2233 Rubberstamped by Darin Adler
2235 Rename CachedPagePlatformData to CachedFramePlatformData to more accurately reflect its true role.
2237 * WebCoreSupport/WebCachedFramePlatformData.h: Copied from WebKit/mac/WebCoreSupport/WebCachedPagePlatformData.h.
2238 (WebCachedFramePlatformData::WebCachedFramePlatformData):
2239 * WebCoreSupport/WebCachedPagePlatformData.h: Removed.
2241 * WebCoreSupport/WebFrameLoaderClient.mm:
2242 (WebFrameLoaderClient::savePlatformDataToCachedPage):
2243 (WebFrameLoaderClient::transitionToCommittedFromCachedPage):
2247 2009-01-23 Adele Peterson <adele@apple.com>
2251 Use new linesBoundingBox method instead of
2252 boundingBoxWidth and boundingBoxHeight for RenderText objects.
2254 * WebView/WebRenderNode.mm: (copyRenderNode):
2256 2009-01-23 Anders Carlsson <andersca@apple.com>
2260 * Plugins/Hosted/ProxyInstance.mm:
2261 (WebKit::proxyClass):
2263 2009-01-23 Anders Carlsson <andersca@apple.com>
2267 * Configurations/Base.xcconfig:
2269 2009-01-23 Anders Carlsson <andersca@apple.com>
2271 Reviewed by Sam Weinig.
2273 Turn on -Wmissing-prototypes and fix the resulting warnings.
2275 * Configurations/Base.xcconfig:
2276 * History/WebHistory.mm:
2277 (timeIntervalForBeginningOfDay):
2278 * History/WebHistoryItem.mm:
2279 (historyItemWrappers):
2280 * Misc/WebNSPasteboardExtras.mm:
2282 * WebView/WebFrame.mm:
2283 * WebView/WebScriptDebugger.mm:
2286 2009-01-22 Mark Rowe <mrowe@apple.com>
2288 Rubber-stamped by Anders Carlsson.
2290 Disable GCC_WARN_ABOUT_MISSING_PROTOTYPES temporarily.
2292 Current versions of Xcode only respect it for C and Objective-C files,
2293 and our code doesn't currently compile if it is applied to C++ and
2294 Objective-C++ files.
2296 * Configurations/Base.xcconfig:
2298 2009-01-22 Anders Carlsson <andersca@apple.com>
2300 Reviewed by Sam Weinig.
2302 Add support for Invoke and InvokeDefault. Clean up code.
2304 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2306 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2307 (WebKit::NetscapePluginInstanceProxy::Reply::):
2308 (WebKit::NetscapePluginInstanceProxy::BooleanReply::BooleanReply):
2309 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2310 (WebKit::NetscapePluginInstanceProxy::demarshalValueFromArray):
2311 * Plugins/Hosted/ProxyInstance.h:
2312 * Plugins/Hosted/ProxyInstance.mm:
2313 (WebKit::ProxyInstance::invoke):
2314 (WebKit::ProxyInstance::invokeMethod):
2315 (WebKit::ProxyInstance::supportsInvokeDefaultMethod):
2316 (WebKit::ProxyInstance::invokeDefaultMethod):
2317 (WebKit::ProxyInstance::methodsNamed):
2318 (WebKit::ProxyInstance::fieldNamed):
2319 * Plugins/Hosted/WebKitPluginClient.defs:
2320 * Plugins/Hosted/WebKitPluginHost.defs:
2321 * Plugins/Hosted/WebKitPluginHostTypes.h:
2323 2009-01-22 Eric Roman <eroman@chromium.og>
2325 Reviewed by Eric Seidel.
2327 https://bugs.webkit.org/show_bug.cgi?id=20806
2328 Deprecate RSSFeedReferrer() and setRSSFeedReferrer().
2330 * History/WebHistoryItem.mm:
2331 (-[WebHistoryItem RSSFeedReferrer]):
2332 (-[WebHistoryItem setRSSFeedReferrer:]):
2334 2009-01-22 Anders Carlsson <andersca@apple.com>
2336 Reviewed by Kevin Decker.
2338 Don't crash or hang when we fail to instantiate a plug-in.
2340 * Plugins/Hosted/NetscapePluginHostManager.mm:
2341 (WebKit::NetscapePluginHostManager::instantiatePlugin):
2342 Return 0 on failure.
2344 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
2345 (-[WebHostedNetscapePluginView JSC::Bindings::createPluginBindingsInstance:JSC::Bindings::]):
2346 Null check for the proxy member.
2348 2009-01-21 David Hyatt <hyatt@apple.com>
2350 Devirtualize width/height/x/y on RenderObject and move the methods to RenderBox.
2352 Reviewed by Eric Seidel and Darin Adler
2354 * WebView/WebRenderNode.mm:
2357 2009-01-21 Anders Carlsson <andersca@apple.com>
2359 Reviewed by Sam Weinig.
2361 More browser->plug-in scripting support.
2363 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2364 (WKPCNPObjectHasPropertyReply):
2365 (WKPCNPObjectHasMethodReply):
2366 (WKPCNPObjectInvokeReply):
2367 MIG reply functions.
2369 (WKPCIdentifierInfo):
2370 Return information about an identifier given its 64-bit value.
2372 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2373 Add new reply structs.
2375 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2376 (WebKit::NetscapePluginInstanceProxy::addValueToArray):
2377 Split out code that adds values to the arrays from marshalValue.
2379 (WebKit::NetscapePluginInstanceProxy::marshalValue):
2380 Call addValueToArray.
2382 (WebKit::NetscapePluginInstanceProxy::marshalValues):
2383 Marshal a list of values.
2385 (WebKit::NetscapePluginInstanceProxy::createBindingsInstance):
2386 Actually create a proxy instance.
2388 * Plugins/Hosted/ProxyInstance.h:
2389 * Plugins/Hosted/ProxyInstance.mm:
2390 (WebKit::ProxyClass::methodsNamed):
2391 (WebKit::ProxyClass::fieldNamed):
2392 Add a proxy ProxyClass class that just forwards everything to the ProxyInstance class.
2394 (WebKit::proxyClass):
2395 Shared proxyClass getter.
2397 (WebKit::ProxyField::ProxyField):
2398 (WebKit::ProxyField::valueFromInstance):
2399 (WebKit::ProxyField::setValueToInstance):
2400 Add a proxy ProxyField class that just forwards everything to the ProxyInstance class.
2402 (WebKit::ProxyMethod::ProxyMethod):
2403 (WebKit::ProxyMethod::serverIdentifier):
2404 (WebKit::ProxyMethod::numParameters):
2405 Add a dummy ProxyMethod class.
2407 (WebKit::ProxyInstance::invokeMethod):
2408 Call _WKPHNPObjectInvoke.
2410 (WebKit::ProxyInstance::defaultValue):
2411 (WebKit::ProxyInstance::stringValue):
2412 (WebKit::ProxyInstance::numberValue):
2413 (WebKit::ProxyInstance::booleanValue):
2414 (WebKit::ProxyInstance::valueOf):
2415 Add dummy implementations (taken from CInstance).
2417 (WebKit::ProxyInstance::methodsNamed):
2418 Call _WKPHNPObjectHasMethod to determine whether a method with the given name exists.
2420 (WebKit::ProxyInstance::fieldNamed):
2421 Call _WKPHNPObjectHasProperty to determine whether a property with the given name exists.
2423 * Plugins/Hosted/WebKitPluginClient.defs:
2424 * Plugins/Hosted/WebKitPluginHost.defs:
2425 Add new MIG definitions.
2427 2009-01-21 Mark Rowe <mrowe@apple.com>
2429 Reviewed by Tim Hatcher.
2431 Clean up how we force invocations of API that happened on background threads over to the main thread.
2433 This was previously accomplished in a somewhat ad-hoc manner using a mutable dictionary to pass arguments
2434 and return values back from the function. The new approach is to use a proxy object that forwards an
2435 NSInvocation over to the main thread and applies it to the target object, which leads to a much cleaner
2438 * Misc/WebNSObjectExtras.h:
2439 * Misc/WebNSObjectExtras.mm:
2440 (-[WebMainThreadInvoker initWithTarget:]):
2441 (-[WebMainThreadInvoker forwardInvocation:]):
2442 (-[WebMainThreadInvoker methodSignatureForSelector:]):
2443 (-[WebMainThreadInvoker handleException:]):
2444 (-[NSInvocation _webkit_invokeAndHandleException:]): Execute the invocation and forward any exception that was
2445 raised back to the WebMainThreadInvoker.
2446 (-[NSObject _webkit_invokeOnMainThread]):
2448 The following methods are updated to use the proxy object to forward methods to the main thread:
2450 * WebView/WebArchive.mm:
2451 (-[WebArchive initWithMainResource:subresources:subframeArchives:]):
2452 (-[WebArchive mainResource]):
2453 (-[WebArchive subresources]):
2454 (-[WebArchive subframeArchives]):
2455 * WebView/WebResource.mm:
2456 (-[WebResource data]):
2457 (-[WebResource URL]):
2458 (-[WebResource MIMEType]):
2459 (-[WebResource textEncodingName]):
2460 (-[WebResource frameName]):
2461 (-[WebResource _ignoreWhenUnarchiving]):
2462 (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]):
2463 (-[WebResource _initWithData:URL:response:]):
2464 (-[WebResource _suggestedFilename]):
2465 (-[WebResource _response]):
2466 (-[WebResource _stringValue]):
2467 * WebView/WebView.mm:
2468 (-[WebView initWithFrame:frameName:groupName:]):
2469 (-[WebView initWithCoder:]):
2471 2009-01-20 Nikolas Zimmermann <nikolas.zimmermann@torchmobile.com>
2473 Reviewed by George Staikos.
2475 Fixes: https://bugs.webkit.org/show_bug.cgi?id=23434 (Add WML <input> element support)
2477 Protect text field related WebEditorClient.mm methods against non-HTMLElement callers.
2478 WebEditorClient.mm relies on HTMLInputElement as input element. Ignore calls from non-HTMLElement elements.
2480 * WebCoreSupport/WebEditorClient.mm:
2481 (WebEditorClient::textFieldDidBeginEditing):
2482 (WebEditorClient::textFieldDidEndEditing):
2483 (WebEditorClient::textDidChangeInTextField):
2484 (WebEditorClient::doTextFieldCommandFromEvent):
2485 (WebEditorClient::textWillBeDeletedInTextField):
2486 (WebEditorClient::textDidChangeInTextArea):
2488 2009-01-19 Anders Carlsson <andersca@apple.com>
2490 Reviewed by Sam Weinig.
2492 Add and implement GetScriptableNPObject.
2494 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2495 (WKPCGetScriptableNPObjectReply):
2496 Create a new reply struct and set it as the current reply.
2499 Get rid of an unused variable.
2501 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2502 (WebKit::NetscapePluginInstanceProxy::Reply::):
2503 (WebKit::NetscapePluginInstanceProxy::GetScriptableNPObjectReply::GetScriptableNPObjectReply):
2504 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2505 (WebKit::NetscapePluginInstanceProxy::createBindingsInstance):
2506 Call _WKPHGetScriptableNPObject and wait for a reply.
2508 * Plugins/Hosted/ProxyInstance.h: Added.
2509 * Plugins/Hosted/ProxyInstance.mm: Added.
2512 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
2513 (-[WebHostedNetscapePluginView JSC::Bindings::createPluginBindingsInstance:JSC::Bindings::]):
2514 Call NetscapePluginInstanceProxy::createBindingsInstance.
2516 * Plugins/Hosted/WebKitPluginClient.defs:
2517 * Plugins/Hosted/WebKitPluginHost.defs:
2518 Add new declarations.
2520 2009-01-19 Sam Weinig <sam@webkit.org>
2522 Rubber-stamped by Gavin Barraclough.
2524 Remove temporary operator-> from JSValuePtr.
2526 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2527 (WebKit::NetscapePluginInstanceProxy::invoke):
2528 (WebKit::NetscapePluginInstanceProxy::hasMethod):
2529 (WebKit::NetscapePluginInstanceProxy::marshalValue):
2530 * WebView/WebFrame.mm:
2531 (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
2532 * WebView/WebView.mm:
2533 (aeDescFromJSValue):
2535 2009-01-19 Anders Carlsson <andersca@apple.com>
2537 Reviewed by Sam Weinig.
2539 Make Evaluate an asynchronous method that has a reply method.
2541 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2543 * Plugins/Hosted/WebKitPluginClient.defs:
2544 * Plugins/Hosted/WebKitPluginHost.defs:
2546 2009-01-19 Brady Eidson <beidson@apple.com>
2548 Rubberstamped by Tim Hatcher
2550 Fix long standing typo.
2552 * History/WebBackForwardList.h:
2554 2009-01-19 Mark Rowe <mrowe@apple.com>
2558 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2559 (WebKit::NetscapePluginInstanceProxy::demarshalValue):
2560 (WebKit::NetscapePluginInstanceProxy::demarshalValues):
2562 2009-01-18 Mark Rowe <mrowe@apple.com>
2564 Reviewed by Anders Carlsson.
2566 Fix <https://bugs.webkit.org/show_bug.cgi?id=23414>.
2567 Bug 23414: Reproducible crash accessing View menu with plugins disabled
2569 * WebView/WebFrame.mm:
2570 (-[WebFrame _canProvideDocumentSource]): Null-check the PluginData before using it.
2572 2009-01-17 David Hyatt <hyatt@apple.com>
2574 Eliminate dependencies on "backslashAsCurrencySymbol()" from WebKit, and make sure these alterations
2575 are done in WebCore instead.
2577 Reviewed by Oliver Hunt
2579 * WebView/WebFrame.mm:
2580 (-[WebFrame _selectedString]):
2581 (-[WebFrame _stringForRange:]):
2583 2009-01-17 Eric Carlson <eric.carlson@apple.com>
2585 Reviewed by Adele Peterson
2587 Complete <rdar://problem/6293969>
2589 * WebCoreSupport/WebSystemInterface.m:
2590 (InitWebCoreSystemInterface): Remove UseSharedMediaUI
2592 2009-01-15 Brady Eidson <beidson@apple.com>
2594 Reviewed by Dan Bernstein
2596 Fix problem where a URL visited as non-GET once is flagged as non-GET forever.
2598 * History/WebHistory.mm:
2599 (-[WebHistory _visitedURL:withTitle:method:wasFailure:]): Always update the HTTPNonGet
2600 flag for all loads with an HTTP Method
2602 2009-01-14 Anders Carlsson <andersca@apple.com>
2604 Reviewed by Sam Weinig.
2606 Implement InvokeDefault, Construct, GetProperty and SetProperty.
2608 Fully implement marshalValue.
2610 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2611 (WKPCInvokeDefault):
2615 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2616 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2617 (WebKit::NetscapePluginInstanceProxy::evaluate):
2618 (WebKit::NetscapePluginInstanceProxy::invoke):
2619 (WebKit::NetscapePluginInstanceProxy::invokeDefault):
2620 (WebKit::NetscapePluginInstanceProxy::construct):
2621 (WebKit::NetscapePluginInstanceProxy::getProperty):
2622 (WebKit::NetscapePluginInstanceProxy::setProperty):
2623 (WebKit::NetscapePluginInstanceProxy::marshalValue):
2624 (WebKit::NetscapePluginInstanceProxy::demarshalValue):
2625 * Plugins/Hosted/WebKitPluginClient.defs:
2627 2009-01-14 Anders Carlsson <andersca@apple.com>
2629 Reviewed by Sam Weinig.
2631 Demarshal arguments and pass them to the JS call.
2633 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2635 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2636 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2637 (WebKit::NetscapePluginInstanceProxy::invoke):
2638 (WebKit::NetscapePluginInstanceProxy::demarshalValueFromArray):
2639 (WebKit::NetscapePluginInstanceProxy::demarshalValues):
2641 2009-01-14 Mark Rowe <mrowe@apple.com>
2643 Reviewed by Timothy Hatcher.
2645 <rdar://problem/6496520> REGRESSION: In Mail, a crash occurs when attempting to display a mail message
2647 Move WebArchive and WebResource to use the same approach for initializing themselves on the main thread
2650 * WebView/WebArchive.mm:
2651 (-[WebArchive initWithMainResource:subresources:subframeArchives:]): Use _webkit_performSelectorOnMainThread:withObject:.
2652 (-[WebArchive _initWithArguments:]):
2653 * WebView/WebResource.mm:
2654 (-[WebResource _initWithArguments:]): Unbox the BOOL argument.
2656 2009-01-14 Darin Adler <darin@apple.com>
2658 Reviewed by Oliver Hunt.
2660 Fix crash I ran into while printing. I was unable to reproduce it, but also,
2661 it's clear there's no guarantee that the frame will be non-zero in this case,
2662 so it seems fine to check it.
2664 * WebView/WebHTMLView.mm: (-[WebHTMLView reapplyStyles]): Check frame for zero
2665 and don't do anything with it if it's zero.
2667 2009-01-14 Dan Bernstein <mitz@apple.com>
2669 Reviewed by John Sullivan.
2675 2009-01-12 Anders Carlsson <andersca@apple.com>
2677 Reviewed by Darin Adler.
2679 Add a bunch of methods to WebKitPluginClient.defs, and implement them.
2681 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2682 (WebKit::fromUTF8WithLatin1Fallback):
2683 If the length isn't specified, get it by calling strlen.
2686 Evaluate doesn't take any arguments.
2688 (WKPCGetIntIdentifier):
2689 Call _NPN_GetIntIdentifier.
2691 (identifierFromServerIdentifier):
2692 New helper function that returns a JSC Identifier from an NPIdentifier.
2695 Call identifierFromServerIdentifier.
2697 (WKPCRemoveProperty):
2700 Call NetscapePluginInstanceProxy.
2702 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2703 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2704 (WebKit::NetscapePluginInstanceProxy::removeProperty):
2705 (WebKit::NetscapePluginInstanceProxy::hasProperty):
2706 (WebKit::NetscapePluginInstanceProxy::hasMethod):
2708 * Plugins/Hosted/WebKitPluginClient.defs:
2709 Add new definitions.
2711 2009-01-13 Anders Carlsson <andersca@apple.com>
2715 * WebView/WebView.mm:
2716 (-[WebView _initWithArguments:]):
2718 2009-01-13 Timothy Hatcher <timothy@apple.com>
2720 Adds a workaround for the flip4mac installer plugin decoding a WebView from a NIB on a secondary thread.
2722 <rdar://problem/6489788> New WebKit thread checks break installation of flip4mac (thread violation)
2724 Reviewed by Darin Adler.
2726 * Misc/WebKitVersionChecks.h: Add WEBKIT_FIRST_VERSION_WITHOUT_WEBVIEW_INIT_THREAD_WORKAROUND.
2727 * Misc/WebNSObjectExtras.h: Add _webkit_performSelectorOnMainThread:withObject:.
2728 * Misc/WebNSObjectExtras.mm:
2729 (-[NSObject _webkit_performSelectorWithArguments:]): Renamed from _webkit_getPropertyWithArguments.
2730 Passes the optional object to the selector.
2731 (-[NSObject _webkit_performSelectorOnMainThread:withObject:]): Renamed from _webkit_getPropertyOnMainThread:.
2732 Put the optional object into the arguments dictionary.
2733 (-[NSObject _webkit_getPropertyOnMainThread:]): Call _webkit_performSelectorOnMainThread with a nil object.
2734 * WebView/WebResource.mm:
2735 (-[WebResource _ignoreWhenUnarchiving]): Use _cmd instead of making the selector again.
2736 (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]): Use the new
2737 _webkit_performSelectorOnMainThread:withObject: method instead of performSelectorOnMainThread.
2738 * WebView/WebView.mm:
2739 (-[WebView _initWithArguments:]): Added. Pulls arguments out of the dictionary and calls the right init method.
2740 (needsWebViewInitThreadWorkaround): Checks if the thead is not the main thread and if we are in the Installer bundle.
2741 (-[WebView initWithFrame:frameName:groupName:]): Call needsWebViewInitThreadWorkaround and use _webkit_performSelectorOnMainThread
2742 to call _initWithArguments: passing the frame, frameName and groupName.
2743 (-[WebView initWithCoder:]): Ditto, except pass the coder to _initWithArguments:.
2745 2009-01-12 Gavin Barraclough <barraclough@apple.com>
2747 Reviewed by Oliver Hunt.
2749 Deprecate JSValuePtr::getNumber() - two ways to get a number should be enough.
2751 * WebView/WebView.mm:
2752 (aeDescFromJSValue):
2754 2009-01-12 Brady Eidson <beidson@apple.com>
2756 Reviewed by Darin Adler
2758 <rdar://problem/6468274> - Track Non-get requests in global history
2760 * History/WebHistory.mm:
2761 (-[WebHistory _visitedURL:withTitle:method:wasFailure:]):
2762 * History/WebHistoryInternal.h:
2764 * History/WebHistoryItem.mm:
2765 (-[WebHistoryItem initFromDictionaryRepresentation:]):
2766 (-[WebHistoryItem dictionaryRepresentation]):
2767 (-[WebHistoryItem _lastVisitWasHTTPNonGet]):
2768 * History/WebHistoryItemPrivate.h:
2770 * WebCoreSupport/WebFrameLoaderClient.mm:
2771 (WebFrameLoaderClient::updateGlobalHistory): Only pass the method through if it was an HTTP load
2773 2009-01-12 Anders Carlsson <andersca@apple.com>
2775 Reviewed by Sam Weinig.
2777 Move marshalling into NetscapePluginInstanceProxy.
2779 Add support for marshallin strings.
2781 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2784 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2785 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2786 (WebKit::NetscapePluginInstanceProxy::evaluate):
2787 (WebKit::NetscapePluginInstanceProxy::invoke):
2788 (WebKit::NetscapePluginInstanceProxy::marshalValue):
2789 * Plugins/Hosted/WebKitPluginHostTypes.h:
2791 2009-01-12 Anders Carlsson <andersca@apple.com>
2793 Reviewed by Sam Weinig.
2795 Implement WKPCInvoke.
2797 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2800 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2801 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2802 (WebKit::NetscapePluginInstanceProxy::idForObject):
2803 (WebKit::NetscapePluginInstanceProxy::invoke):
2804 * Plugins/Hosted/WebKitPluginClient.defs:
2806 2009-01-12 Anders Carlsson <andersca@apple.com>
2808 Reviewed by Sam Weinig.
2810 Move marshalling code to NetscapePluginInstanceProxy. Add support for marshalling JS objects.
2812 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2814 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2815 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2816 (WebKit::NetscapePluginInstanceProxy::marshalValue):
2817 * Plugins/Hosted/WebKitPluginHostTypes.h:
2819 2009-01-12 Julien Chaffraix <jchaffraix@pleyo.com>
2821 Reviewed by Darin Adler.
2823 Bug 22861: Turn the FontCache into a singleton
2824 https://bugs.webkit.org/show_bug.cgi?id=22861
2826 * Misc/WebCoreStatistics.mm:
2827 (+[WebCoreStatistics cachedFontDataCount]):
2828 (+[WebCoreStatistics cachedFontDataInactiveCount]):
2829 (+[WebCoreStatistics purgeInactiveFontData]):
2830 Redirected all the static calls to the global FontCache
2833 2009-01-11 Dmitry Titov <dimich@chromium.org>
2835 Reviewed by Darin Adler.
2837 https://bugs.webkit.org/show_bug.cgi?id=23207
2838 Moved currentTime() to from WebCore to WTF.
2840 * WebView/WebFrame.mm: a different header file included.
2842 2009-01-10 Darin Adler <darin@apple.com>
2844 Reviewed by Sam Weinig.
2846 <rdar://problem/5845089> REGRESSION (r30044): Mail custom stationery missing images
2847 because of change to -[HTMLObjectElement data]
2849 * WebView/WebView.mm:
2850 (-[WebView _commonInitializationWithFrameName:groupName:usesDocumentViews:]): Added a thread
2851 violation check because I saw this being done off the main thread while testing Mail, and it
2852 caused problems. Put all the one time initialization under a single guard to make things just
2853 a little faster other times, and to make it clearer which things are one-time. Added a call to
2854 the new patchMailRemoveAttributesMethod function.
2855 (-[WebView initWithFrame:frameName:groupName:]): Added a thread violation check here too,
2856 because I assumed it would be slightly better to have a public method name in the violation
2857 message. This calls commonInitialization later, so it will hit that one eventually.
2858 (objectElementDataAttribute): Added. Just returns the value of the "data" attribute.
2859 (recursivelyRemoveMailAttributes): Added. Patch to an internal Mail method that in turn patches
2860 a WebKit method and removes the patch again on the way out.
2861 (patchMailRemoveAttributesMethod): Added. On Leopard only, checks the Mail version, and then
2862 applies the patch that fixes this bug.
2864 2009-01-09 Dan Bernstein <mitz@apple.com>
2866 Reviewed by Darin Adler.
2868 - fixed <rdar://problem/6234347> Add/change conditional key
2869 bindings for changing paragraph- and character-level writing
2870 direction (to match NSTextView)
2872 * WebView/WebHTMLView.mm:
2873 (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]): Added
2874 code to validate makeBaseWritingDirectionLeftToRight: and
2875 makeBaseWritingDirectionRightToLeft:.
2876 (writingDirectionKeyBindingsEnabled): Changed this function to
2877 always return YES, except on Tiger and Leopard.
2878 (-[WebHTMLView makeBaseWritingDirectionLeftToRight:]): Renamed
2879 changeBaseWritingDirectionToLTR: to this.
2880 (-[WebHTMLView makeBaseWritingDirectionRightToLeft:]): Renamed
2881 changeBaseWritingDirectionToRTL: to this.
2882 (-[WebHTMLView changeBaseWritingDirectionToLTR:]): Now calls
2883 makeBaseWritingDirectionLeftToRight:.
2884 (-[WebHTMLView changeBaseWritingDirectionToRTL:]): Now calls
2885 makeBaseWritingDirectionRightToLeft:.
2886 * WebView/WebView.mm: Added makeBaseWritingDirectionLeftToRight
2887 and makeBaseWritingDirectionRightToLeft to
2888 FOR_EACH_RESPONDER_SELECTOR.
2890 2009-01-08 Anders Carlsson <andersca@apple.com>
2892 Reviewed by Sam Weinig.
2894 Add and implement WKPCGetStringIdentifier.
2896 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2897 (WKPCGetStringIdentifier):
2898 * Plugins/Hosted/WebKitPluginClient.defs:
2900 2009-01-08 Stephanie Lewis <slewis@gmail.com>
2904 * WebView/WebTextIterator.mm:
2906 2009-01-08 Anders Carlsson <andersca@apple.com>
2908 Reviewed by Sam Weinig.
2910 Add basic support for evaluating scripts.
2912 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2913 (WebKit::fromUTF8WithLatin1Fallback):
2914 (WebKit::NetscapePluginHostProxy::~NetscapePluginHostProxy):
2915 (WKPCReleaseObject):
2918 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2919 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2920 (WebKit::NetscapePluginInstanceProxy::releaseObject):
2921 (WebKit::NetscapePluginInstanceProxy::evaluate):
2922 * Plugins/Hosted/WebKitPluginClient.defs:
2923 * Plugins/Hosted/WebKitPluginHostTypes.h:
2925 2009-01-08 David Hyatt <hyatt@apple.com>
2927 Fix for <rdar://problem/6465682> REGRESSION: In Mail, can't force a message to auto scroll
2929 Add a new ChromeClient method for handling exposure of scrolled rects.
2931 Reviewed by Oliver Hunt
2933 * WebCoreSupport/WebChromeClient.h:
2934 * WebCoreSupport/WebChromeClient.mm:
2935 (WebChromeClient::scrollRectIntoView):
2937 2009-01-08 Darin Adler <darin@apple.com>
2939 Reviewed by Tim Hatcher.
2941 Bug 23185: add a currentRange method to the WebTextIterator SPI
2942 https://bugs.webkit.org/show_bug.cgi?id=23185
2943 rdar://problem/6455834
2945 I also noticed a garbage-collection-related threading issue that I fixed, and
2946 that the SPI for getting text was unnecessarily inefficient, so I fixed that too.
2948 * WebView/WebTextIterator.h: Moved currentNode and currentText into a "deprecated"
2949 category. Added currentTextPointer and currentTextLength.
2951 * WebView/WebTextIterator.mm: Changed m_textIterator into an OwnPtr, and also
2952 used _textIterator to be consistent with ObjC rather than C++ naming.
2953 (+[WebTextIteratorPrivate initialize]): Added. Calls WebCoreObjCFinalizeOnMainThread,
2954 since the finalize method here works with main-thread only WebCore objects.
2955 (-[WebTextIterator initWithRange:]): Changed since _textIterator is an OwnPtr now.
2956 (-[WebTextIterator advance]): Changed name of m_textIterator. Removed null assertion,
2957 since I don't think it provides much value.
2958 (-[WebTextIterator atEnd]): Ditto.
2959 (-[WebTextIterator currentRange]): Added.
2960 (-[WebTextIterator currentTextPointer]): Added.
2961 (-[WebTextIterator currentTextLength]): Added.
2962 (-[WebTextIterator currentNode]): Did same as above, but also put into new category.
2963 (-[WebTextIterator currentText]): Ditto.
2965 2009-01-08 Eric Carlson <eric.carlson@apple.com>
2967 Reviewed by Adele Peterson.
2969 Simplify Mac interfaces for drawing media controller elements
2971 <rdar://problem/6293969>
2973 * WebCoreSupport/WebSystemInterface.m:
2974 (InitWebCoreSystemInterface): Update for changes to media controller functions
2976 2009-01-07 Anders Carlsson <andersca@apple.com>
2978 Reviewed by Dan Bernstein.
2982 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2983 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
2984 (WebKit::NetscapePluginInstanceProxy::idForObject):
2986 2009-01-07 Anders Carlsson <andersca@apple.com>
2988 Reviewed by Dan Bernstein.
2990 Add a way for a plug-in to get a reference to the Window JS object.
2992 * Plugins/Hosted/NetscapePluginHostProxy.mm:
2993 (WKPCGetWindowNPObject):
2994 Call the appropriate instance.
2996 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
2997 Add object ID counter.
2999 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3000 (WebKit::NetscapePluginInstanceProxy::destroy):
3001 Clear the object ID map.
3003 (WebKit::NetscapePluginInstanceProxy::idForObject):
3004 New method that returns a unique ID for a given JS object.
3006 (WebKit::NetscapePluginInstanceProxy::getWindowNPObject):
3007 Return the object ID for the window JS object.
3009 * Plugins/Hosted/WebKitPluginClient.defs:
3010 Add GetWindowNPObject.
3012 2009-01-07 Darin Adler <darin@apple.com>
3014 Reviewed by Oliver Hunt.
3016 Bug 23160: add setMemoryCacheClientCallsEnabled SPI so Safari can be faster with activity window closed
3017 https://bugs.webkit.org/show_bug.cgi?id=23160
3019 * WebView/WebView.mm:
3020 (-[WebView setMemoryCacheDelegateCallsEnabled:]): Added.
3021 (-[WebView areMemoryCacheDelegateCallsEnabled]): Added
3022 * WebView/WebViewPrivate.h: Ditto.
3024 2009-01-05 Gavin Barraclough <baraclough@apple.com>
3026 Rubber Stamped by Oliver Hunt.
3028 Replace all uses of JSValue* with new wrapper class, JSValuePtr.
3029 See JavaScriptCore/ChangeLog for more detailed description.
3031 * WebView/WebFrame.mm:
3032 (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
3033 * WebView/WebScriptDebugDelegate.mm:
3034 (-[WebScriptCallFrame _convertValueToObjcValue:]):
3035 (-[WebScriptCallFrame exception]):
3036 (-[WebScriptCallFrame evaluateWebScript:]):
3037 * WebView/WebView.mm:
3038 (aeDescFromJSValue):
3039 (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
3041 2009-01-06 Pierre-Olivier Latour <pol@apple.com>
3043 Reviewed by Darin Adler.
3045 Exposed through WebFrame private interface the new WebCore API AnimationController::numberOfActiveAnimations() to be used by DRT.
3047 https://bugs.webkit.org/show_bug.cgi?id=23126
3049 * WebView/WebFrame.mm:
3050 (-[WebFrame _numberOfActiveAnimations]):
3051 * WebView/WebFramePrivate.h:
3053 2009-01-05 David Kilzer <ddkilzer@apple.com>
3055 Add SPI to enable, disable and check state of WebIconDatabase
3057 Reviewed by Darin Adler & Timothy Hatcher.
3059 Add -[WebIconDatabase isEnabled] and -[WebIconDatabase setEnabled:]
3060 SPI to make it possible to enable, disable and check the state of
3063 * Misc/WebIconDatabase.mm:
3064 (-[WebIconDatabase init]): Extracted code into -_startUpIconDatabase.
3065 (-[WebIconDatabase iconForURL:withSize:cache:]): Switched to use
3066 -isEnabled instead of -_isEnabled.
3067 (-[WebIconDatabase iconURLForURL:]): Ditto.
3068 (-[WebIconDatabase retainIconForURL:]): Ditto.
3069 (-[WebIconDatabase releaseIconForURL:]): Ditto.
3070 (-[WebIconDatabase isEnabled]): Renamed from -_isEnabled in
3071 WebInternal category.
3072 (-[WebIconDatabase setEnabled:]): Added. Takes care of changing
3073 the enabled/disabled state of the icon database.
3074 (-[WebIconDatabase removeAllIcons]): Switched to use -isEnabled
3075 instead of -_isEnabled.
3076 (-[WebIconDatabase _startUpIconDatabase]): Added. Extrated from
3078 (-[WebIconDatabase _shutDownIconDatabase]): Added. Remove
3079 observers when the icon database is disabled.
3080 * Misc/WebIconDatabaseInternal.h: Added declarations for
3081 -_startUpIconDatabase and -_shutDownIconDatabase.
3082 * Misc/WebIconDatabasePrivate.h: Added declarations for
3083 -isEnabled and -setEnabled:.
3085 2009-01-05 Brady Eidson <beidson@apple.com>
3087 Reviewed by Jon Honeycutt
3089 Expose setting the last-visit-was-failure flag on a history items in preparation for <rdar://problem/6173319>
3091 * History/WebHistoryItem.mm:
3092 (-[WebHistoryItem _setLastVisitWasFailure:]):
3093 * History/WebHistoryItemPrivate.h:
3095 2009-01-05 Adam Treat <adam.treat@torchmobile.com>
3097 Another blind mac build fix
3099 * WebCoreSupport/WebChromeClient.mm:
3100 (WebChromeClient::contentsSizeChanged):
3102 2009-01-05 Adam Treat <adam.treat@torchmobile.com>
3106 * WebCoreSupport/WebChromeClient.mm:
3108 2009-01-05 Adam Treat <adam.treat@torchmobile.com>
3112 * WebCoreSupport/WebChromeClient.h:
3114 2009-01-05 Adam Treat <adam.treat@torchmobile.com>
3116 Reviewed by George Staikos.
3118 Build fix for contentsSizeChanged
3120 * WebCoreSupport/WebChromeClient.h:
3121 * WebCoreSupport/WebChromeClient.mm:
3122 (WebChromeClient::contentsSizeChanged):
3124 2009-01-02 Darin Adler <darin@apple.com>
3126 Reviewed by Sam Weinig.
3128 Bug 23072: REGRESSION (r37371): In the Dictionary application, scroll bar appears
3129 inside its web view when resizing its window
3130 https://bugs.webkit.org/show_bug.cgi?id=23072
3131 rdar://problem/6368028
3133 The first attempt at fixing this did not work.
3134 This time I was able to reproduce the bug and test the fix.
3136 * WebCoreSupport/WebFrameLoaderClient.mm:
3137 (applyAppleDictionaryApplicationQuirkNonInlinePart): Changed the arguments and
3138 function names around a bit to make even less code at the call site.
3139 (applyAppleDictionaryApplicationQuirk): Put the check for whether this is the
3140 Dictionary application in here.
3141 (WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache): Put a call to
3142 applyAppleDictionaryApplicationQuirk here. This was a case I had missed before,
3143 when the script is cached. This fixes one of the two problems with the initial
3144 patch; the other fix is in WebCore.
3145 (WebFrameLoaderClient::dispatchWillSendRequest): Changed the
3146 applyAppleDictionaryApplicationQuirk call here to work the new simpler way.
3148 * WebView/WebView.mm: Had to add an include due to changes in WebCore header includes.
3150 2009-01-02 Cameron Zwarich <cwzwarich@uwaterloo.ca>
3152 Reviewed by Darin Adler.
3154 Bug 23060: REGRESSION (r38629): Cannot scroll a WebHTMLView using Home/End/Page up/Page down
3155 <https://bugs.webkit.org/show_bug.cgi?id=23060>
3156 <rdar://problem/6467830>
3158 After r38629, all keyboard events get sent by Editor to the EditorClient, even
3159 if the selection is not editable. If the event's command is unsupported by
3160 WebHTMLView, WebHTMLView mistakenly thinks that the event was handled when it
3161 was not. When using the page up / page down keys, the events generated are of
3162 the form scrollPageUp rather than movePageUp, so they are unsupported by
3163 WebHTMLView and cause this bug to occur.
3165 * WebView/WebHTMLView.mm:
3166 (-[WebHTMLView doCommandBySelector:]):
3168 2009-01-02 Darin Adler <darin@apple.com>
3170 Reviewed by Oliver Hunt.
3172 Bug 23072: REGRESSION (r37371): In the Dictionary application, scroll bar appears inside its web view when resizing its window
3173 https://bugs.webkit.org/show_bug.cgi?id=23072
3174 rdar://problem/6368028
3176 * WebCoreSupport/WebFrameLoaderClient.mm:
3177 (isAppleDictionaryApplication): Added.
3178 (applyAppleDictionaryApplicationQuirk): Added. Under the right conditions, sets
3179 a flag to ask HTMLFrameElementBase to ignore the scrolling attribute.
3180 (WebFrameLoaderClient::dispatchWillSendRequest): Call the two functions above to
3181 apply the quirk when the relevant script is loaded.
3183 2008-12-26 Dan Bernstein <mitz@apple.com>
3185 Reviewed by Sam Weinig.
3187 - fix <rdar://problem/6467608> lastVisitWasFailure flag persists in
3188 global history after a successful visit
3190 * History/WebHistory.mm:
3191 (-[WebHistory _visitedURL:withTitle:wasFailure:]): Changed to always
3192 update the wasFailure flag on the HistoryItem.
3194 2008-12-23 Darin Adler <darin@apple.com>
3196 Reviewed by Alexey Proskuryakov (a slightly earlier version).
3198 - fix https://bugs.webkit.org/show_bug.cgi?id=22976
3199 crash due to Mail's use of WebArchive and WebResource on non-main thread
3201 * Misc/WebKitLogging.h: Improved comments for ASSERT_MAIN_THREAD. Got rid of
3202 WebKitRunningOnMainThread function, which was just a cover for pthread_main_np.
3203 * Misc/WebKitLogging.m: Ditto.
3205 * Misc/WebKitVersionChecks.h: Added a version after which we won't do the
3206 main thread workaround.
3208 * Misc/WebNSObjectExtras.h: Added a new method, _webkit_getPropertyOnMainThread:,
3209 which performs a selector on the main thread, waits for it to complete, and then
3210 returns the value on the caller thread.
3211 * Misc/WebNSObjectExtras.mm: Added.
3213 * WebView/WebArchive.mm:
3214 (-[WebArchive init]): Added WebCoreThreadViolationCheck.
3215 (-[WebArchive initWithMainResource:subresources:subframeArchives:]): Perform
3216 initialization on main thread if needMailThreadWorkaround is true.
3217 Also added WebCoreThreadViolationCheck.
3218 (-[WebArchive initWithData:]): Added WebCoreThreadViolationCheck.
3219 (-[WebArchive mainResource]): Get property on main thread if
3220 needMailThreadWorkaround is true. Also added WebCoreThreadViolationCheck.
3221 (-[WebArchive subresources]): Ditto.
3222 (-[WebArchive subframeArchives]): Ditto.
3223 (-[WebArchive data]): Ditto.
3224 (-[WebArchive _initWithCoreLegacyWebArchive:]): Added WebCoreThreadViolationCheck.
3225 (-[WebArchive _coreLegacyWebArchive]): Ditto.
3226 (-[WebArchive _initWithArguments:]): Added. Used to implement the cross-thread
3227 version of initWithMainResource above.
3229 * WebView/WebResource.mm:
3230 (-[WebResource initWithCoder:]): Added WebCoreThreadViolationCheck.
3231 (-[WebResource data]): Get property on main thread if
3232 needMailThreadWorkaround is true. Also added WebCoreThreadViolationCheck.
3233 (-[WebResource URL]): Ditto.
3234 (-[WebResource MIMEType]): Ditto.
3235 (-[WebResource textEncodingName]): Ditto.
3236 (-[WebResource frameName]): Ditto.
3237 (-[WebResource _ignoreWhenUnarchiving]): Ditto.
3238 (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]):
3239 Perform initialization on main thread if needMailThreadWorkaround is true.
3240 Also added WebCoreThreadViolationCheck.
3241 (-[WebResource _suggestedFilename]): Added. Helper for _fileWrapperRepresentation.
3242 (-[WebResource _fileWrapperRepresentation]): Rewrote to use methods instead of
3243 getting at coreResource directly.
3244 (-[WebResource _response]): Get property on main thread if
3245 needMailThreadWorkaround is true. Also added WebCoreThreadViolationCheck.
3246 (-[WebResource _stringValue]): Ditto.
3247 (+[WebResource _needMailThreadWorkaroundIfCalledOffMainThread]): Added.
3248 (-[WebResource _initWithArguments:]): Added. Used to implement the cross-thread
3249 version of _initWithData above.
3251 * WebView/WebResourceInternal.h: Changed to include WebResourcePrivate.h since internal
3252 clients have access to the SPI as well as the API. Added definition of MAIL_THREAD_WORKAROUND
3253 and the needMainThreadWorkaround helper function.
3255 * Misc/WebIconDatabase.mm: Removed include of now-defunct FoundationExtras.h
3256 file. This probably fixes clean builds.
3257 * WebCoreSupport/WebIconDatabaseClient.mm: Ditto.
3259 * WebCoreSupport/WebFrameLoaderClient.mm: Removed include of WebResourcePrivate.h,
3260 since it's not actually used.
3261 * WebView/WebDataSource.mm: Ditto.
3262 * WebView/WebHTMLRepresentation.mm: Ditto.
3264 2008-12-23 Darin Adler <darin@apple.com>
3266 Reviewed by Dan Bernstein.
3268 - fix https://bugs.webkit.org/show_bug.cgi?id=22979
3269 crash seen in -[WebView drawsBackground] when quitting
3270 <rdar://problem/6464601>
3272 * WebView/WebView.mm:
3273 (-[WebView drawsBackground]): Added comment and a null check for _private.
3275 2008-12-22 Kevin Decker <kdecker@apple.com>
3277 Reviewed by Anders Carlsson.
3279 <rdar://problem/6449588> REGRESSION (r38279-r38280): Minimize them remaximize a window with a flash plugin, plugin doesn't resume at full speed
3281 * Plugins/WebBaseNetscapePluginView.mm:
3282 (-[WebBaseNetscapePluginView windowDidDeminiaturize:]): Deminiaturizing should restart timers, not stop timers.
3284 2008-12-19 Geoffrey Garen <ggaren@apple.com>
3286 Reviewed by Darin Adler, Adele Peterson, Brady Eidson.
3288 Added SPI for getting an unsorted vector of all items in history.
3290 * History/WebHistory.h:
3291 * History/WebHistory.mm:
3292 (-[WebHistory allItems]):
3294 2008-12-18 Dan Bernstein <mitz@apple.com>
3296 Reviewed by Sam Weinig.
3298 - implement FrameLoaderClient::shouldUseCredentialStorage() by calling
3299 a new resource load delegae method.
3301 * WebCoreSupport/WebFrameLoaderClient.h:
3302 * WebCoreSupport/WebFrameLoaderClient.mm:
3303 (WebFrameLoaderClient::shouldUseCredentialStorage): Added. Calls the
3304 delegate method. If the method is unimplemented, returns true for
3305 backwards compatibility.
3306 * WebView/WebView.mm:
3307 (-[WebView _cacheResourceLoadDelegateImplementations]): Initialize the
3308 shouldUseCredentialStorageFunc member.
3309 (CallResourceLoadDelegateReturningBoolean): Added.
3310 * WebView/WebViewInternal.h:
3311 * WebView/WebResourceLoadDelegatePrivate.h: Declared the delegate method
3312 -webView:resource:shouldUseCredentialStorageForDataSource:.
3314 2008-12-18 Cameron Zwarich <zwarich@apple.com>
3316 Reviewed by Jonathan Honeycutt.
3318 Fix an apparent typo in r39385 that is causing lots of crashes.
3320 * WebCoreSupport/WebFrameLoaderClient.mm:
3321 (WebFrameLoaderClient::dispatchDidFirstVisuallyNonEmptyLayout):
3323 2008-12-18 Brady Eidson <beidson@apple.com>
3325 Reviewed by John Sullivan
3327 Initial visit to a website creates history items that start with a visit count of
3330 * History/WebHistory.mm:
3331 (-[WebHistoryPrivate visitedURL:withTitle:]): Set the visit count on new items
3333 * History/WebHistoryItem.mm:
3334 (-[WebHistoryItem _setVisitCount:]): Call through to the WebCore item
3335 * History/WebHistoryItemInternal.h:
3337 2008-12-18 Sam Weinig <sam@webkit.org>
3339 Reviewed by John Sullivan.
3341 Implement FrameLoaderClient::dispatchDidFirstVisuallyNonEmptyLayout() by calling
3342 a new private frame load delegate method.
3344 * WebCoreSupport/WebFrameLoaderClient.h:
3345 * WebCoreSupport/WebFrameLoaderClient.mm:
3346 (WebFrameLoaderClient::dispatchDidFirstVisuallyNonEmptyLayout):
3347 * WebView/WebView.mm:
3348 (-[WebView _cacheFrameLoadDelegateImplementations]):
3349 * WebView/WebViewInternal.h:
3350 * WebView/WebViewPrivate.h:
3352 2008-12-16 Antti Koivisto <antti@apple.com>
3354 Reviewed by John Sullivan.
3356 Add version check for shift-reload behavior.
3358 * Misc/WebKitVersionChecks.h:
3359 * WebView/WebFrame.mm:
3360 (-[WebFrame reload]):
3362 2008-12-16 Anders Carlsson <andersca@apple.com>
3364 Reviewed by Dan Bernstein.
3366 Start sending keyboard events to the plug-in host.
3368 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3369 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3370 (WebKit::NetscapePluginInstanceProxy::keyEvent):
3371 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
3372 (-[WebHostedNetscapePluginView keyDown:]):
3373 (-[WebHostedNetscapePluginView keyUp:]):
3374 * Plugins/Hosted/WebKitPluginHost.defs:
3376 2008-12-16 Anders Carlsson <andersca@apple.com>
3378 Reviewed by Kevin Decker.
3380 <rdar://problem/6450538>
3382 Fix flag enumeration.
3384 * Plugins/Hosted/WebKitPluginHostTypes.h:
3386 2008-12-16 Anders Carlsson <andersca@apple.com>
3388 Reviewed by Kevin Decker.
3390 Instead of passing a gazillion booleans to WKPCLoadURL, pass a single set of flags.
3392 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3394 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3395 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3396 (WebKit::NetscapePluginInstanceProxy::loadURL):
3397 * Plugins/Hosted/WebKitPluginClient.defs:
3398 * Plugins/Hosted/WebKitPluginHostTypes.h:
3400 2008-12-16 Anders Carlsson <andersca@apple.com>
3402 Reviewed by Kevin Decker.
3404 Add trailing null to headers to avoid a crash in the plug-in host.
3406 * Plugins/Hosted/HostedNetscapePluginStream.mm:
3407 (WebKit::HostedNetscapePluginStream::didReceiveResponse):
3409 2008-12-15 Mark Rowe <mrowe@apple.com>
3411 Rubber-stamped by Cameron Zwarich.
3413 <rdar://problem/6289933> Change WebKit-related projects to build with GCC 4.2 on Leopard.
3415 * Configurations/Base.xcconfig:
3416 * Configurations/DebugRelease.xcconfig:
3418 2008-12-15 Stephanie Lewis <slewis@apple.com>
3422 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3424 2008-12-15 Anders Carlsson <andersca@apple.com>
3426 Reviewed by Sam Weinig.
3428 Change InstantiatePlugin to be asynchronous so we won't deadlock if the plug-in tries to call
3429 back into us while it's being instantiated.
3431 * Plugins/Hosted/NetscapePluginHostManager.mm:
3432 (WebKit::NetscapePluginHostManager::instantiatePlugin):
3433 * Plugins/Hosted/NetscapePluginHostProxy.h:
3434 (WebKit::NetscapePluginHostProxy::clientPort):
3435 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3436 (WKPCInstantiatePluginReply):
3437 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3438 (WebKit::NetscapePluginInstanceProxy::Reply::):
3439 (WebKit::NetscapePluginInstanceProxy::Reply::Reply):
3440 (WebKit::NetscapePluginInstanceProxy::Reply::~Reply):
3441 (WebKit::NetscapePluginInstanceProxy::InstantiatePluginReply::InstantiatePluginReply):
3442 (WebKit::NetscapePluginInstanceProxy::setCurrentReply):
3443 (WebKit::NetscapePluginInstanceProxy::waitForReply):
3444 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3445 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
3446 (WebKit::NetscapePluginInstanceProxy::processRequestsAndWaitForReply):
3447 * Plugins/Hosted/WebKitPluginClient.defs:
3448 * Plugins/Hosted/WebKitPluginHost.defs:
3450 2008-12-15 Anders Carlsson <andersca@apple.com>
3452 Reviewed by Darin Adler.
3454 Let WebKit generate a plug-in ID instead of having the plug-in host do it.
3456 * Plugins/Hosted/NetscapePluginHostManager.mm:
3457 (WebKit::NetscapePluginHostManager::instantiatePlugin):
3458 Create the plug-in proxy before instantiating the plug-in.
3460 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3461 (WebKit::NetscapePluginInstanceProxy::create):
3462 (WebKit::NetscapePluginInstanceProxy::setRenderContextID):
3463 (WebKit::NetscapePluginInstanceProxy::setUseSoftwareRenderer):
3464 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3465 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
3466 * Plugins/Hosted/WebKitPluginHost.defs:
3468 2008-12-15 Anders Carlsson <andersca@apple.com>
3470 Reviewed by Sam Weinig.
3472 LoadURL doesn't need to be asynchronous.
3474 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3476 * Plugins/Hosted/WebKitPluginClient.defs:
3477 * Plugins/Hosted/WebKitPluginHost.defs:
3479 2008-12-15 Antti Koivisto <antti@apple.com>
3481 Reviewed by Darin Adler.
3483 - Add [WebFrame reloadFromOrigin] for performing end-to-end reload.
3484 - Add corresponding IBAction to WebView.
3485 - Temporarily make [WebFrame reload] trigger end-to-end reload if shift modifier is pressed when it is called.
3487 * WebView/WebFrame.h:
3488 * WebView/WebFrame.mm:
3489 (-[WebFrame reload]):
3490 (-[WebFrame reloadFromOrigin]):
3491 * WebView/WebFramePrivate.h: Match the FrameLoadType enum in WebCore.
3492 * WebView/WebView.h:
3493 * WebView/WebView.mm:
3494 (-[WebView reloadFromOrigin:]):
3496 2008-12-14 Dan Bernstein <mitz@apple.com>
3498 Reviewed by Darin Adler.
3500 - fix <rdar://problem/3258561> WebHistoryAllItemsRemovedNotification
3501 should add items to userInfo
3503 * History/WebHistory.mm:
3504 (-[WebHistoryPrivate allItems]): Added this helper method, which returns
3505 all values in the _entriesByURL dictionary.
3506 (-[WebHistory removeAllItems]): Changed to send the array of all items
3507 in the notification.
3509 2008-12-13 Darin Adler <darin@apple.com>
3511 - <rdar://problem/6441035> WebTextIterator class not exported in WebKit
3513 * WebKit.exp: Added the class. We forgot to export it when we added
3514 the WebTextIterator SPI.
3516 2008-12-12 Darin Adler <darin@apple.com>
3518 Rubber stamped by Adam Roben.
3520 - fix <rdar://problem/5648301> Can't tab around to text fields in Safari
3521 login sheet after clicking static text, due to AppKit key loop change
3523 * Panels/English.lproj/WebAuthenticationPanel.nib/classes.nib: Removed.
3524 * Panels/English.lproj/WebAuthenticationPanel.nib/designable.nib: Added.
3525 * Panels/English.lproj/WebAuthenticationPanel.nib/info.nib: Removed.
3526 * Panels/English.lproj/WebAuthenticationPanel.nib/keyedobjects.nib:
3527 Set nextKeyView of the selectable static texts to the editable text.
3530 2008-12-12 Stephanie Lewis <slewis@apple.com>
3532 Reviewed by Geoff Garen.
3536 * WebView/WebView.mm:
3537 (+[WebView _setCacheModel:]):
3539 2008-12-12 Anders Carlsson <andersca@apple.com>
3541 Reviewed by Tim Hatcher.
3543 Don't try to free the dummy "1" port state.
3545 * Plugins/WebNetscapePluginView.mm:
3546 (-[WebNetscapePluginView sendEvent:isDrawRect:]):
3547 (-[WebNetscapePluginView updateAndSetWindow]):
3549 2008-12-11 Cameron Zwarich <zwarich@apple.com>
3551 Rubber-stamped by Mark Rowe.
3553 Roll out r39212 due to assertion failures during layout tests, multiple
3554 layout test failures, memory leaks, and obvious incorrectness.
3556 * WebView/WebPreferenceKeysPrivate.h:
3557 * WebView/WebPreferences.mm:
3558 (-[WebPreferences fullDocumentTeardownEnabled]):
3559 * WebView/WebPreferencesPrivate.h:
3561 2008-12-11 Stephanie Lewis <slewis@apple.com>
3565 * WebView/WebView.mm:
3567 2008-12-11 Stephanie Lewis <slewis@apple.com>
3569 Reviewed by Oliver Hunt.
3571 Empty Web cache before quitting a debug build in order
3572 to report accurate CachedResource leaks.
3574 * WebView/WebView.mm:
3575 (-[WebView _close]):
3577 2008-12-11 Anders Carlsson <andersca@apple.com>
3581 * Misc/WebNSDataExtras.h:
3583 2008-12-11 Anders Carlsson <andersca@apple.com>
3585 Reviewed by Cameron Zwarich.
3587 https://bugs.webkit.org/show_bug.cgi?id=22797
3588 REGRESSION: Crash at http://news.cnet.com/8301-17939_109-10119149-2.html
3590 Make sure to protect the stream because destroyStream can otherwise cause it to be deleted.
3592 * Plugins/WebBaseNetscapePluginStream.mm:
3593 (WebNetscapePluginStream::destroyStreamWithReason):
3595 2008-12-10 Glenn Wilson <gwilson@google.com>
3597 Reviewed by Adam Roben.
3599 Added new methods for overriding default WebPreference values
3600 and for resetting preferences to their defaults.
3601 https://bugs.webkit.org/show_bug.cgi?id=20534
3603 * WebView/WebPreferenceKeysPrivate.h:
3604 * WebView/WebPreferences.mm:
3605 (-[WebPreferences resetToDefaults]): new method
3606 (-[WebPreferences overridePreference:flag:]): new method
3607 * WebView/WebPreferencesPrivate.h: new method signatures
3609 2008-12-10 Anders Carlsson <andersca@apple.com>
3611 Reviewed by Darin Adler.
3613 Implement support for NPN_PostURL/NPN_PostURLNotify in WebKit.
3615 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3618 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3619 (WebKit::NetscapePluginInstanceProxy::stopAllStreams):
3620 Factored out this from ::destroy.
3622 (WebKit::NetscapePluginInstanceProxy::destroy):
3623 Call stopAllStreams().
3625 (WebKit::NetscapePluginInstanceProxy::pluginHostDied):
3628 (WebKit::NetscapePluginInstanceProxy::loadURL):
3629 Handle post being true. This code has been copied from WebNetscapePluginView.mm (for now).
3631 2008-12-10 Anders Carlsson <andersca@apple.com>
3633 Reviewed by Darin Adler.
3635 Move two NSData category methods to WebNSDataExtras.m.
3637 * Misc/WebNSDataExtras.h:
3638 * Misc/WebNSDataExtras.m:
3639 (-[NSData _web_startsWithBlankLine]):
3640 (-[NSData _web_locationAfterFirstBlankLine]):
3641 * Plugins/WebNetscapePluginView.mm:
3643 2008-12-10 Alice Liu <alice.liu@apple.com>
3645 fixed https://bugs.webkit.org/show_bug.cgi?id=20685
3647 Reviewed by Darin Adler.
3649 * Misc/WebNSPasteboardExtras.mm:
3650 Ask image for its file extension instead of falling back on MIME type and file path.
3651 Also moved this code to before setting the pasteboard data so as not to set any if
3652 no extension can be determined.
3653 (-[NSPasteboard _web_declareAndWriteDragImageForElement:URL:title:archive:source:]):
3655 * WebView/WebHTMLView.mm:
3656 Fixed a separate but related long-standing bug of how the filename for the promised
3657 drag data is determined by asking the image for a proper file extension.
3658 (-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]):
3660 2008-12-09 Anders Carlsson <andersca@apple.com>
3662 Reviewed by Darin Adler.
3666 * WebView/WebHTMLView.mm:
3667 (-[WebHTMLView _pauseNullEventsForAllNetscapePlugins]):
3669 2008-12-09 Anders Carlsson <andersca@apple.com>
3671 Reviewed by Darin Adler.
3673 Implement software rendering of hosted plug-ins.
3675 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3676 (WKPCInvalidateRect):
3677 New MiG function. This is called by the plug-in host when it has drawn something.
3679 * Plugins/Hosted/WebHostedNetscapePluginView.h:
3680 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
3681 (-[WebHostedNetscapePluginView createPlugin]):
3682 Create a software renderer.
3684 (-[WebHostedNetscapePluginView destroyPlugin]):
3685 Destroy the software renderer.
3687 (-[WebHostedNetscapePluginView drawRect:]):
3688 Draw using the software renderer.
3690 * Plugins/Hosted/WebKitPluginClient.defs:
3693 2008-12-09 Brett Wilson <brettw@chromium.org>
3695 Reviewed by Dave Hyatt.
3697 https://bugs.webkit.org/show_bug.cgi?id=22177
3699 Add a callback on ChromeClient that the state of form elements on
3700 the page has changed. This is to allow clients implementing session
3701 saving to know when the current state is dirty.
3703 * WebCoreSupport/WebChromeClient.h:
3704 (WebChromeClient::formStateDidChange):
3706 2008-12-09 Anders Carlsson <andersca@apple.com>
3708 Reviewed by Dan Bernstein.
3710 Make sure to pause null events for hosted plug-ins as well.
3712 * WebView/WebHTMLView.mm:
3713 (-[WebHTMLView _pauseNullEventsForAllNetscapePlugins]):
3715 2008-12-09 Anders Carlsson <andersca@apple.com>
3717 Reviewed by Darin Adler.
3719 * Plugins/Hosted/NetscapePluginHostProxy.h:
3720 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3721 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
3722 (WebKit::NetscapePluginHostProxy::~NetscapePluginHostProxy):
3723 Unfortunately we can't use a libdispatch source right now, because of <rdar://problem/6393180>.
3725 2008-12-09 Timothy Hatcher <timothy@apple.com>
3727 Implement a few methods needed to keep Dictionary.app working on Leopard.
3729 <rdar://problem/6002160> Internal changes to WebKit in Safari 4
3730 Developer Preview might break Dictionary
3732 Reviewed by Dan Bernstein.
3734 * WebView/WebFrame.mm:
3735 (-[WebFrame convertNSRangeToDOMRange:]): Added. Calls _convertNSRangeToDOMRange.
3736 (-[WebFrame convertDOMRangeToNSRange:]): Added. Calls _convertDOMRangeToNSRange.
3737 * WebView/WebHTMLView.mm:
3738 (-[WebHTMLView _bridge]): Added. Returns the WebFrame, which has the methods
3739 that Dictionary.app is using.
3741 2008-12-08 Anders Carlsson <andersca@apple.com>
3743 Reviewed by Darin Adler.
3745 More work towards getting NPN_GetURL working.
3747 * Plugins/Hosted/HostedNetscapePluginStream.h:
3748 Inherit from NetscapePlugInStreamLoaderClient.
3750 (WebKit::HostedNetscapePluginStream::streamID):
3751 * Plugins/Hosted/HostedNetscapePluginStream.mm:
3752 (WebKit::HostedNetscapePluginStream::startStream):
3753 Keep track of the resposne URL and the MIME type. Pass the response URL to the
3756 (WebKit::HostedNetscapePluginStream::didFinishLoading):
3757 Disconnect the stream.
3759 (WebKit::HostedNetscapePluginStream::start):
3760 Create a plug-in stream loader and start loading.
3762 (WebKit::HostedNetscapePluginStream::stop):
3765 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3767 Fix the parameter order.
3769 (WKPCCancelLoadURL):
3770 New function that cancels a load of a stream with a given reason.
3772 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3773 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3774 (WebKit::NetscapePluginInstanceProxy::destroy):
3777 (WebKit::NetscapePluginInstanceProxy::pluginStream):
3778 Return a plug-in stream given a stream ID.
3780 (WebKit::NetscapePluginInstanceProxy::disconnectStream):
3781 Remove the stream from the streams map.
3783 (WebKit::NetscapePluginInstanceProxy::loadRequest):
3784 Create a stream and load it.
3786 * Plugins/Hosted/WebKitPluginClient.defs:
3789 * Plugins/Hosted/WebKitPluginHost.defs:
3790 Add responseURL to StartStream.
3792 * Plugins/WebBaseNetscapePluginView.h:
3793 * Plugins/WebBaseNetscapePluginView.mm:
3794 (-[WebBaseNetscapePluginView pluginPackage]):
3795 Move this down to the base class from WebNetscapePluginView.
3797 * Plugins/WebNetscapePluginView.h:
3798 * Plugins/WebNetscapePluginView.mm:
3800 2008-12-08 Dan Bernstein <mitz@apple.com>
3802 Reviewed by John Sullivan.
3804 - WebKit/mac part of tracking the global history item for a WebView
3806 * WebView/WebView.mm:
3807 (-[WebView _globalHistoryItem]): Added. Returns the page's global
3809 * WebView/WebViewPrivate.h:
3811 2008-12-06 Simon Fraser <simon.fraser@apple.com>
3813 Reviewed by Dave Hyatt
3815 https://bugs.webkit.org/show_bug.cgi?id=15671
3817 VisiblePosition::caretRect() was renaemd to absoluteCaretBounds().
3819 * WebView/WebFrame.mm:
3820 (-[WebFrame _caretRectAtNode:offset:affinity:]):
3822 2008-12-06 David Kilzer <ddkilzer@apple.com>
3824 Bug 22666: Clean up data structures used when collecting URLs of subresources for webarchives
3826 <https://bugs.webkit.org/show_bug.cgi?id=22666>
3828 Reviewed by Darin Adler.
3830 * DOM/WebDOMOperations.mm:
3831 (-[DOMNode _subresourceURLs]): Changed from using Vector<KURL> to
3832 ListHashSet<KURL> when calling WebCore::Node::getSubresourceURLs().
3834 2008-12-05 Alexey Proskuryakov <ap@webkit.org>
3836 Reviewed by Darin Adler.
3838 <rdar://problem/6405599> Tiger Mail crashes when using "Mail Contents of This Page"
3839 in Safari before opening a mail message in Mail
3841 * Carbon/CarbonWindowAdapter.m: Removed.
3842 * Carbon/CarbonWindowAdapter.mm: Copied from WebKit/mac/Carbon/CarbonWindowAdapter.m.
3843 (+[CarbonWindowAdapter initialize]):
3844 * History/WebBackForwardList.mm:
3845 (+[WebBackForwardList initialize]):
3846 * History/WebHistoryItem.mm:
3847 (+[WebHistoryItem initialize]):
3848 * Misc/WebElementDictionary.mm:
3849 (+[WebElementDictionary initialize]):
3850 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
3851 (+[WebHostedNetscapePluginView initialize]):
3852 * Plugins/WebBaseNetscapePluginView.mm:
3853 * Plugins/WebBasePluginPackage.m: Removed.
3854 * Plugins/WebBasePluginPackage.mm: Copied from WebKit/mac/Plugins/WebBasePluginPackage.m.
3855 (+[WebBasePluginPackage initialize]):
3856 * Plugins/WebNetscapePluginView.mm:
3857 (+[WebNetscapePluginView initialize]):
3858 * WebCoreSupport/WebEditorClient.mm:
3859 (+[WebEditCommand initialize]):
3860 * WebCoreSupport/WebFrameLoaderClient.mm:
3861 * WebView/WebArchive.mm:
3862 (+[WebArchivePrivate initialize]):
3863 * WebView/WebDataSource.mm:
3864 (+[WebDataSourcePrivate initialize]):
3865 * WebView/WebHTMLView.mm:
3866 (+[WebHTMLViewPrivate initialize]):
3867 (+[WebHTMLView initialize]):
3868 * WebView/WebResource.mm:
3869 (+[WebResourcePrivate initialize]):
3870 * WebView/WebView.mm:
3871 (+[WebViewPrivate initialize]):
3872 Call JSC::initializeThreading();
3874 2008-12-04 Stephanie Lewis <slewis@apple.com>
3878 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3881 2008-12-04 Anders Carlsson <andersca@apple.com>
3883 Reviewed by Sam Weinig.
3885 More work on streams.
3887 * Plugins/Hosted/HostedNetscapePluginStream.h: Added.
3888 (WebKit::HostedNetscapePluginStream::create):
3889 * Plugins/Hosted/HostedNetscapePluginStream.mm: Added.
3890 (WebKit::HostedNetscapePluginStream::HostedNetscapePluginStream):
3891 (WebKit::HostedNetscapePluginStream::startStreamWithResponse):
3892 (WebKit::HostedNetscapePluginStream::startStream):
3893 (WebKit::HostedNetscapePluginStream::didReceiveData):
3894 (WebKit::HostedNetscapePluginStream::didFinishLoading):
3895 (WebKit::HostedNetscapePluginStream::didReceiveResponse):
3896 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3897 (WebKit::NetscapePluginInstanceProxy::pluginView):
3898 (WebKit::NetscapePluginInstanceProxy::hostProxy):
3899 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3900 (WebKit::NetscapePluginInstanceProxy::PluginRequest::PluginRequest):
3901 (WebKit::NetscapePluginInstanceProxy::PluginRequest::requestID):
3902 (WebKit::NetscapePluginInstanceProxy::PluginRequest::request):
3903 (WebKit::NetscapePluginInstanceProxy::PluginRequest::frameName):
3904 (WebKit::NetscapePluginInstanceProxy::PluginRequest::didStartFromUserGesture):
3905 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
3906 (WebKit::NetscapePluginInstanceProxy::performRequest):
3907 (WebKit::NetscapePluginInstanceProxy::evaluateJavaScript):
3908 (WebKit::NetscapePluginInstanceProxy::requestTimerFired):
3909 (WebKit::NetscapePluginInstanceProxy::loadRequest):
3910 * Plugins/Hosted/WebKitPluginHost.defs:
3912 2008-12-04 Anders Carlsson <andersca@apple.com>
3914 Reviewed by Sam Weinig.
3916 Start implementing WKPCLoadURL. Currently this has copied a lot of code from WebNetscapePluginView
3917 but once we have a more complete implementation of NPStreams we can start refactoring things so that the
3918 implementations can share more code.
3920 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3922 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
3923 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3924 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
3925 (WebKit::NetscapePluginInstanceProxy::loadURL):
3926 (WebKit::NetscapePluginInstanceProxy::performRequest):
3927 (WebKit::NetscapePluginInstanceProxy::requestTimerFired):
3928 (WebKit::NetscapePluginInstanceProxy::loadRequest):
3929 * Plugins/Hosted/WebKitPluginClient.defs:
3930 * Plugins/Hosted/WebKitPluginHost.defs:
3932 2008-12-04 Anders Carlsson <andersca@apple.com>
3934 Reviewed by Dan Bernstein.
3936 Move requestWithURLCString to WebBaseNetscapePluginView.
3938 * Plugins/WebBaseNetscapePluginView.h:
3939 * Plugins/WebBaseNetscapePluginView.mm:
3940 (-[WebBaseNetscapePluginView requestWithURLCString:]):
3941 * Plugins/WebNetscapePluginView.mm:
3943 2008-12-03 Anders Carlsson <andersca@apple.com>
3945 Reviewed by Sam Weinig.
3947 Move WebPluginRequest to its own file.
3949 * Plugins/WebNetscapePluginView.mm:
3950 * Plugins/WebPluginRequest.h: Added.
3951 * Plugins/WebPluginRequest.m: Added.
3952 (-[WebPluginRequest initWithRequest:frameName:notifyData:sendNotification:didStartFromUserGesture:]):
3953 (-[WebPluginRequest dealloc]):
3954 (-[WebPluginRequest request]):
3955 (-[WebPluginRequest frameName]):
3956 (-[WebPluginRequest isCurrentEventUserGesture]):
3957 (-[WebPluginRequest sendNotification]):
3958 (-[WebPluginRequest notifyData]):
3960 2008-12-03 Anders Carlsson <andersca@apple.com>
3962 Handle the CA model.
3964 * Plugins/WebNetscapePluginView.mm:
3965 (-[WebNetscapePluginView setWindowIfNecessary]):
3967 2008-12-03 Anders Carlsson <andersca@apple.com>
3969 Reviewed by Kevin Decker.
3971 <rdar://problem/6412293>
3972 Call NPP_SetWindow for CA plug-ins.
3974 * Plugins/WebNetscapePluginView.mm:
3975 (-[WebNetscapePluginView saveAndSetNewPortStateForUpdate:]):
3976 (-[WebNetscapePluginView restorePortState:]):
3977 (-[WebNetscapePluginView isNewWindowEqualToOldWindow]):
3978 (-[WebNetscapePluginView updateAndSetWindow]):
3979 (-[WebNetscapePluginView setWindowIfNecessary]):
3981 2008-12-03 Anders Carlsson <andersca@apple.com>
3983 Fix the release build.
3985 * Plugins/Hosted/NetscapePluginHostProxy.mm:
3986 (WebKit::NetscapePluginHostProxy::deadNameNotificationCallback):
3988 2008-12-03 Anders Carlsson <andersca@apple.com>
3990 Reviewed by Dan Bernstein.
3992 <rdar://problem/6412234>
3993 Don't crash if we can't launch the plug-in host.
3995 * Plugins/Hosted/NetscapePluginHostManager.mm:
3996 (WebKit::NetscapePluginHostManager::instantiatePlugin):
3998 2008-12-02 Anders Carlsson <andersca@apple.com>
4000 Reviewed by Dan Bernstein.
4002 Start processing messages sent to the client port.
4004 * Plugins/Hosted/NetscapePluginHostProxy.h:
4005 * Plugins/Hosted/NetscapePluginHostProxy.mm:
4006 Add a map from ports to plug-in proxies. Turn the set of instances into a map from
4007 pluginID to instance proxy.
4010 Look up the right instance proxy and call status().
4012 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
4013 (WebKit::NetscapePluginInstanceProxy::pluginID):
4014 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
4015 (WebKit::NetscapePluginInstanceProxy::status):
4018 * Plugins/Hosted/WebKitPluginClient.defs:
4019 Add the plug-in ID to StatusText.
4021 2008-12-02 Gregory Hughes <ghughes@apple.com>
4023 Reviewed by Beth Dakin.
4025 Bug 22513: ZOOM: text selection does not send correct zoom bounds
4027 When zoomed, text selection must send the zoom bounds in flipped
4030 * WebCoreSupport/WebViewFactory.mm:
4031 (-[WebViewFactory accessibilityConvertScreenRect:]):
4033 2008-12-02 Anders Carlsson <andersca@apple.com>
4035 Reviewed by Dan Bernstein.
4037 Create a client mach port and pass it to the plug-in host.
4039 * Plugins/Hosted/NetscapePluginHostManager.h:
4040 * Plugins/Hosted/NetscapePluginHostManager.mm:
4041 (WebKit::NetscapePluginHostManager::hostForPackage):
4042 (WebKit::NetscapePluginHostManager::spawnPluginHost):
4043 * Plugins/Hosted/NetscapePluginHostProxy.h:
4044 * Plugins/Hosted/NetscapePluginHostProxy.mm:
4045 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
4046 * Plugins/Hosted/WebKitPluginHost.defs:
4048 2008-12-02 Anders Carlsson <andersca@apple.com>
4050 Reviewed by Sam Weinig.
4052 Let the plug-in views know if the plug-in host crashes.
4054 * Plugins/Hosted/NetscapePluginHostManager.h:
4055 * Plugins/Hosted/NetscapePluginHostManager.mm:
4056 (WebKit::NetscapePluginHostManager::instantiatePlugin):
4057 * Plugins/Hosted/NetscapePluginHostProxy.h:
4058 * Plugins/Hosted/NetscapePluginHostProxy.mm:
4059 (WebKit::NetscapePluginHostProxy::pluginHostDied):
4060 (WebKit::NetscapePluginHostProxy::addPluginInstance):
4061 (WebKit::NetscapePluginHostProxy::removePluginInstance):
4063 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
4064 (WebKit::NetscapePluginInstanceProxy::create):
4065 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
4066 Keep a pointer to the host proxy.
4068 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
4069 Add the instance to the host set.
4071 (WebKit::NetscapePluginInstanceProxy::~NetscapePluginInstanceProxy):
4072 Remove the instance form the host set.
4074 (WebKit::NetscapePluginInstanceProxy::pluginHostDied):
4075 Tell the plug-in view that the plug-in died.
4077 * Plugins/Hosted/WebHostedNetscapePluginView.h:
4078 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
4079 (-[WebHostedNetscapePluginView createPlugin]):
4080 Pass the plug-in view to the instantiatePlugin.
4082 (-[WebHostedNetscapePluginView pluginHostDied]):
4083 Handle the plug-in host crashing.
4085 (-[WebHostedNetscapePluginView drawRect:]):
4086 Fill the plug-in view with a nice red shade if the plug-in crashes.
4088 2008-12-01 Anders Carlsson <andersca@apple.com>
4090 Reviewed by Dan Bernstein.
4092 Recover if the plug-in host dies and we try to instantiate another plugin before we get the port death notification
4094 * Plugins/Hosted/NetscapePluginHostManager.h:
4095 * Plugins/Hosted/NetscapePluginHostManager.mm:
4096 (WebKit::NetscapePluginHostManager::pluginHostDied):
4097 Remove the plug-in host from the map.
4099 (WebKit::NetscapePluginHostManager::instantiatePlugin):
4100 NetscapePluginHostProxy is no longer refcounted.
4102 * Plugins/Hosted/NetscapePluginHostProxy.h:
4103 This is no longer refcounted. Add a set of plug-in instances (unused for now).
4105 * Plugins/Hosted/NetscapePluginHostProxy.mm:
4106 (WebKit::NetscapePluginHostProxy::NetscapePluginHostProxy):
4107 Create a death notification port.
4109 (WebKit::NetscapePluginHostProxy::pluginHostDied):
4110 Tell the manager that we're gone and delete ourselves.
4112 (WebKit::NetscapePluginHostProxy::deathPortCallback):
4113 New CFMachPort callback.
4115 2008-12-01 Anders Carlsson <andersca@apple.com>
4117 Reviewed by Dan Bernstein.
4119 Move instantiatePlugin to NetscapePluginHostManager.
4121 * Plugins/Hosted/NetscapePluginHostManager.h:
4122 * Plugins/Hosted/NetscapePluginHostManager.mm:
4123 (WebKit::NetscapePluginHostManager::instantiatePlugin):
4124 * Plugins/Hosted/NetscapePluginHostProxy.h:
4125 * Plugins/Hosted/NetscapePluginHostProxy.mm:
4126 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
4127 (-[WebHostedNetscapePluginView createPlugin]):
4129 2008-12-01 Anders Carlsson <andersca@apple.com>
4131 Reviewed by Dan Bernstein.
4133 Pass the plug-in host port directly to the instance proxy.
4135 * Plugins/Hosted/NetscapePluginHostProxy.mm:
4136 (WebKit::NetscapePluginHostProxy::instantiatePlugin):
4137 * Plugins/Hosted/NetscapePluginInstanceProxy.h:
4138 (WebKit::NetscapePluginInstanceProxy::create):
4139 * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
4140 (WebKit::NetscapePluginInstanceProxy::NetscapePluginInstanceProxy):
4141 (WebKit::NetscapePluginInstanceProxy::resize):
4142 (WebKit::NetscapePluginInstanceProxy::destroy):
4143 (WebKit::NetscapePluginInstanceProxy::focusChanged):
4144 (WebKit::NetscapePluginInstanceProxy::windowFocusChanged):
4145 (WebKit::NetscapePluginInstanceProxy::windowFrameChanged):
4146 (WebKit::NetscapePluginInstanceProxy::startTimers):
4147 (WebKit::NetscapePluginInstanceProxy::mouseEvent):
4148 (WebKit::NetscapePluginInstanceProxy::stopTimers):
4150 2008-12-01 Anders Carlsson <andersca@apple.com>
4152 Try to fix the Tiger build.
4154 * Plugins/WebNetscapePluginView.mm:
4156 2008-12-01 Anders Carlsson <andersca@apple.com>
4158 Rename _layer to _pluginLayer where I forgot to do so.
4160 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
4161 (-[WebHostedNetscapePluginView destroyPlugin]):
4162 * Plugins/WebNetscapePluginView.h:
4163 * Plugins/WebNetscapePluginView.mm:
4164 (-[WebNetscapePluginView createPlugin]):
4165 (-[WebNetscapePluginView setLayer:]):
4166 (-[WebNetscapePluginView destroyPlugin]):
4168 2008-12-01 Anders Carlsson <andersca@apple.com>
4170 Reviewed by Adam Roben.
4172 Make sure to re-insert layers as needed so they won't be lost when the layer backed
4173 view is removed from the view hierarchy.
4175 * Plugins/Hosted/WebHostedNetscapePluginView.h:
4176 Add _pluginLayer ivar.
4178 * Plugins/Hosted/WebHostedNetscapePluginView.mm:
4179 (-[WebHostedNetscapePluginView createPlugin]):
4180 Don't add the layer here.
4182 (-[WebHostedNetscapePluginView setLayer:]):
4183 Instead, add it here.
4185 (-[WebHostedNetscapePluginView destroyPlugin]):
4186 Set _pluginLayer to 0.
4188 * Plugins/WebNetscapePluginView.mm:
4189 (-[WebNetscapePluginView createPlugin]):
4190 Don't add the layer here.
4192 (-[WebNetscapePluginView setLayer:]):
4195 2008-11-30 Antti Koivisto <antti@apple.com>
4197 Reviewed by Mark Rowe.
4199 https://bugs.webkit.org/show_bug.cgi?id=22557
4201 Report free size in central and thread caches too.
4203 * Misc/WebCoreStatistics.mm:
4204 (+[WebCoreStatistics memoryStatistics]):
4206 2008-11-29 Antti Koivisto <antti@apple.com>
4208 Reviewed by Dan Bernstein.
4210 https://bugs.webkit.org/show_bug.cgi?id=22557
4211 Add statistics for JavaScript GC heap.
4213 * Misc/WebCoreStatistics.mm:
4214 (+[WebCoreStatistics javaScriptObjectsCount]):
4215 (+[WebCoreStatistics memoryStatistics]):
4217 2008-11-29 Antti Koivisto <antti@apple.com>
4219 Reviewed by Alexey Proskuryakov.
4221 https://bugs.webkit.org/show_bug.cgi?id=22557
4223 - Add purgeable memory statistics to cache statistics.
4224 - Add method for getting fastMalloc statistics.
4225 - Add method to force returning free memory back to system.
4228 (+[WebCache statistics]):
4229 * Misc/WebCoreStatistics.h:
4230 * Misc/WebCoreStatistics.mm:
4231 (+[WebCoreStatistics stopIgnoringWebCoreNodeLeaks]):
4232 (+[WebCoreStatistics memoryStatistics]):
4233 (+[WebCoreStatistics returnFreeMemoryToSystem]):
4235 2008-11-26 Mark Rowe <mrowe@apple.com>
4237 Fix the Tiger build.
4239 mig.h does not always define __MigTypeCheck on Tiger, which leads to problems when the generated
4240 code is built with -Wundef.
4242 * Plugins/Hosted/WebKitPluginHostTypes.h:
4244 2008-11-26 Anders Carlsson <andersca@apple.com>
4248 * Configurations/Base.xcconfig:
4250 2008-11-26 Anders Carlsson <andersca@apple.com>