WebCore:
[WebKit-https.git] / WebKit / mac / ChangeLog
1 2008-09-01  Adam Barth  <abarth@webkit.org>
2
3         Reviewed by Sam Weinig.
4
5         https://bugs.webkit.org/show_bug.cgi?id=19760
6
7         Add a linked-on-or-after check to prevent substitute data from loading
8         local resources on newer users of WebKit.
9
10         * Misc/WebKitVersionChecks.h:
11         * WebView/WebView.mm:
12         (-[WebView _commonInitializationWithFrameName:groupName:]):
13
14 2008-08-29  Brady Eidson  <beidson@apple.com>
15
16         Reviewed by Anders
17
18         Fix regression I introducted in 35946
19         Already covered by media/video-click-dlbclick-standalone.html
20
21         * WebView/WebHTMLRepresentation.mm:
22         (-[WebHTMLRepresentation receivedData:withDataSource:]): Cancel the load here after
23           calling [WebFrame _receivedData:] which more closely follows the path taken by PluginDocuments
24
25 2008-08-28  Kevin McCullough  <kmccullough@apple.com>
26
27         Reviewed by Geoff.
28
29         <rdar://problem/6095949> REGRESSION (5525.8-6527.1?): "this" is null
30         when you first hit a breakpoint in Dashcode
31         - We wanted to reset the callframe whenever eval() was called but
32         dashcode uses eval() when broken to evaluate the state of the current
33         call frame.
34
35         * WebView/WebScriptDebugger.mm:
36         (WebScriptDebugger::willExecuteProgram):
37         (WebScriptDebugger::didExecuteProgram):
38
39 2008-08-27  Robert Kroeger  <rjkroege@liqui.org>
40
41         Tweaked by Sam Weinig.
42
43         Reviewed by Eric Seidel.
44
45         Fix https://bugs.webkit.org/show_bug.cgi?id=6595
46         <rdar://problem/4432150>
47         Right-click does not fire mouseup event
48
49         Adds a rightMouseUp handler to the WebHTMLView.
50
51         The added method generates mouseup events for button 2.  The result
52         is that webkit will deliver mousedown and mouseup events for button
53         2 in a fashion identical to FireFox and will retain event ordering
54         identical to Internet Explorer.
55
56         Test: fast/events/mouseup-from-button2.html
57
58         * WebView/WebHTMLView.mm:
59         (-[WebHTMLView rightMouseUp:]):
60
61 2008-08-27  Timothy Hatcher  <timothy@apple.com>
62
63         Add support for support for -webkit-appearance: default-button on the Mac platform.
64
65         <rdar://problem/6173530>
66
67         Reviewed by Dave Hyatt.
68
69         * WebCoreSupport/WebSystemInterface.m:
70         (InitWebCoreSystemInterface): Init AdvanceDefaultButtonPulseAnimation.
71         * WebView/WebPreferenceKeysPrivate.h: Added WebKitApplicationChromeModeEnabledPreferenceKey.
72         * WebView/WebPreferences.mm:
73         (+[WebPreferences initialize]): Set WebKitApplicationChromeModeEnabledPreferenceKey to NO.
74         (-[WebPreferences applicationChromeModeEnabled]): Added.
75         (-[WebPreferences setApplicationChromeModeEnabledEnabled:]): Added.
76         * WebView/WebPreferencesPrivate.h:
77         * WebView/WebView.mm:
78         (-[WebView _preferencesChangedNotification:]): Call Settings::setApplicationChromeMode
79         with the value of -[WebPreferences applicationChromeModeEnabled].
80
81 2008-08-27  Brady Eidson  <beidson@apple.com>
82
83         Reviewed by Anders
84
85         <rdar://problem/6134133> - Crash when loading large movie as a standalone document
86
87         * WebCoreSupport/WebFrameLoaderClient.h:
88         * WebCoreSupport/WebFrameLoaderClient.mm:
89         (WebFrameLoaderClient::pluginWillHandleLoadError):
90
91 2008-08-20  Dan Bernstein  <mitz@apple.com>
92
93         Rubber-stamped by John Sullivan.
94
95         - rename shouldUpdateWhileHidden to shouldUpdateWhileOffscreen,
96           rename related methods and variables accordingly, and make
97           -setShouldUpdateWhileOffscreen: and -shouldUpdateWhileOffscreen
98           WebView API.
99
100         * WebCoreSupport/WebFrameLoaderClient.mm:
101         (WebFrameLoaderClient::transitionToCommittedForNewPage):
102         * WebView/WebFrame.mm:
103         (-[WebFrame _updateBackgroundAndUpdatesWhileOffscreen]):
104         * WebView/WebFrameInternal.h:
105         * WebView/WebHTMLView.mm:
106         (-[WebHTMLView windowWillOrderOnScreen:]):
107         * WebView/WebView.h:
108         * WebView/WebView.mm:
109         (-[WebViewPrivate init]):
110         (-[WebView setBackgroundColor:]):
111         (-[WebView setDrawsBackground:]):
112         (-[WebView setShouldUpdateWhileOffscreen:]):
113         (-[WebView shouldUpdateWhileOffscreen]):
114         * WebView/WebViewPrivate.h:
115
116 2008-08-18  Mark Rowe  <mrowe@apple.com>
117
118         Reviewed by Darin Adler.
119
120         Switch to non-deprecated NSFileManager API.
121
122         In order to minimize #if's the new NSFileManager APIs have been implemented for
123         Tiger and call sites updated to use the new methods.
124
125         * Misc/WebIconDatabase.mm:
126         (importToWebCoreFormat):
127         * Misc/WebKitNSStringExtras.m:
128         (-[NSString _webkit_fixedCarbonPOSIXPath]):
129         * Misc/WebKitSystemBits.m:
130         * Misc/WebNSFileManagerExtras.h:
131         * Misc/WebNSFileManagerExtras.m: Remove implementations of methods that are not used.
132         (-[NSFileManager _webkit_backgroundRemoveFileAtPath:]):
133         (-[NSFileManager attributesOfFileSystemForPath:error:]): Implement new API for Tiger in terms of Tiger API.
134         (-[NSFileManager contentsOfDirectoryAtPath:error:]): Ditto.
135         (-[NSFileManager moveItemAtPath:toPath:error:]): Ditto.
136         (-[NSFileManager removeItemAtPath:error:]): Ditto.
137         * Plugins/WebPluginDatabase.mm:
138         (-[WebPluginDatabase _scanForNewPlugins]):
139
140 2008-08-20  Josh Aas  <joshmoz@gmail.com>
141
142         Reviewed and landed by Anders.
143
144         <rdar://problem/6163636> 
145         rename NPCocoaEvent's "event" struct to "data" (20446)
146
147         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
148         (WebNetscapePluginEventHandlerCocoa::drawRect):
149         (WebNetscapePluginEventHandlerCocoa::sendMouseEvent):
150         (WebNetscapePluginEventHandlerCocoa::flagsChanged):
151         (WebNetscapePluginEventHandlerCocoa::sendKeyEvent):
152         (WebNetscapePluginEventHandlerCocoa::windowFocusChanged):
153         (WebNetscapePluginEventHandlerCocoa::focusChanged):
154
155 2008-08-20  Beth Dakin  <bdakin@apple.com>
156
157         Reviewed by Darin.
158
159         Fix for <rdar://problem/6145626>
160         Allows a WebKit client to mark a frame as not-text-searchable 
161         through SPI.
162
163         * WebView/WebFrame.mm:
164         (-[WebFrame _setExcludeFromTextSearch:]):
165         * WebView/WebFramePrivate.h:
166
167 2008-08-19  Alexey Proskuryakov  <ap@webkit.org>
168
169         Reviewed by Geoff Garen.
170
171         Bring back shared JSGlobalData and implicit locking, because too many clients rely on it.
172
173         * ForwardingHeaders/kjs/JSLock.h: Added.
174         * Misc/WebCoreStatistics.mm:
175         (+[WebCoreStatistics javaScriptObjectsCount]):
176         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
177         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
178         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
179         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
180         (+[WebCoreStatistics shouldPrintExceptions]):
181         (+[WebCoreStatistics setShouldPrintExceptions:]):
182         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
183         * Plugins/WebBaseNetscapePluginStream.mm:
184         (-[WebBaseNetscapePluginStream wantsAllStreams]):
185         * Plugins/WebBaseNetscapePluginView.mm:
186         (-[WebBaseNetscapePluginView sendEvent:isDrawRect:]):
187         (-[WebBaseNetscapePluginView setWindowIfNecessary]):
188         (-[WebBaseNetscapePluginView start]):
189         (-[WebBaseNetscapePluginView createPluginScriptableObject]):
190         (-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]):
191         (-[WebBaseNetscapePluginView webFrame:didFinishLoadWithReason:]):
192         (-[WebBaseNetscapePluginView loadPluginRequest:]):
193         (-[WebBaseNetscapePluginView _printedPluginBitmap]):
194         * Plugins/WebPluginController.mm:
195         (+[WebPluginController plugInViewWithArguments:fromPluginPackage:]):
196         (-[WebPluginController startAllPlugins]):
197         (-[WebPluginController stopAllPlugins]):
198         (-[WebPluginController addPlugin:]):
199         (-[WebPluginController destroyPlugin:]):
200         (-[WebPluginController destroyAllPlugins]):
201         * WebView/WebFrame.mm:
202         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
203         * WebView/WebScriptDebugDelegate.mm:
204         (-[WebScriptCallFrame evaluateWebScript:]):
205         * WebView/WebView.mm:
206         (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
207
208 2008-08-19  Timothy Hatcher  <timothy@apple.com>
209
210         Fixes the Web Inspector flashing white while resizing after
211         highlighting a page element. Calling disableScreenUpdatesUntilFlush
212         when attaching and detaching the Inspector page highlight is bad,
213         since the browser window might not flush again for a while. So screen
214         updates could be disabled for long periods of time, causing backing store
215         flashing while resizing. There is no need to call disableScreenUpdatesUntilFlush
216         when attaching or detaching the child window.
217
218         Reviewed by John Sullivan and Kevin McCullough.
219
220         * WebInspector/WebNodeHighlight.m:
221         (-[WebNodeHighlight attach]): Remove the call to disableScreenUpdatesUntilFlush.
222         (-[WebNodeHighlight detach]): Ditto.
223
224 2008-08-19  Timothy Hatcher  <timothy@apple.com>
225
226         Correctly remembers the attached state of the Web Inspector so
227         it opens in that state for the next window, or next launch.
228
229         Reviewed by Kevin McCullough.
230
231         * WebCoreSupport/WebInspectorClient.mm:
232         (-[WebInspectorWindowController attach]): Set WebKitInspectorAttachedKey
233         to YES in the user defaults.
234         (-[WebInspectorWindowController detach]): Set WebKitInspectorAttachedKey
235         to NO in the user defaults.
236
237 2008-08-18  Alexey Proskuryakov  <ap@webkit.org>
238
239         Reviewed by Dan Bernstein.
240
241         https://bugs.webkit.org/show_bug.cgi?id=19347
242         <rdar://problem/5977562> Input methods do not work after switching to a password field
243         and back.
244
245         Fix <rdar://problem/5522011> (The content of the password field of Safari is displayed by
246         reconversion) in a different way which doesn't conflict with context caching performed
247         by AppKit.
248
249         This original bug does not really occur in ToT or shipping Safari under Mac OS X 10.5.4,
250         because input methods are disabled in password fields. Attempting to reconvert text typed
251         with Romaji only yields a string of bullets. Still, it is probably better to match Cocoa
252         password field behavior and disable reconversion completely.
253
254         * WebView/WebHTMLView.mm:
255         (isInPasswordField): Factored out code to determine that the current selection is in
256         a password field.
257         (inputContext): Removed a hack that was breaking TSMGetActiveDocument().
258         (-[WebHTMLView attributedSubstringFromRange:]): Check for password fields.
259         (-[WebHTMLView textStorage]): Ditto.
260
261 2008-08-12  Darin Adler  <darin@apple.com>
262
263         Reviewed by Geoff.
264
265         - eliminate JSValue::type()
266
267         * WebView/WebView.mm:
268         (aeDescFromJSValue): Rewrite to use the JSValue::is functions instead
269         of a switch on JSValue::type().
270
271 2008-08-17  Geoffrey Garen  <ggaren@apple.com>
272
273         Reviewed by Cameron Zwarich.
274
275         Made room for a free word in JSCell.
276         
277         (Updated for JavaScriptCore changes.)
278
279 2008-08-15  Mark Rowe  <mrowe@apple.com>
280
281         Rubber-stamped by Geoff Garen.
282
283         <rdar://problem/6139914> Please include a _debug version of JavaScriptCore framework
284
285         * Configurations/Base.xcconfig: Factor out the debug-only settings so that they can shared
286         between the Debug configuration and debug Production variant.
287
288 2008-08-14  Sam Weinig  <sam@webkit.org>
289
290         Reviewed by Geoffrey Garen and Timothy Hatcher.
291
292         Add WebView SPI to set HTMLTokenizer yielding parameters.
293
294         * WebView/WebView.mm:
295         (-[WebView _setCustomHTMLTokenizerTimeDelay:]):
296         (-[WebView _setCustomHTMLTokenizerChunkSize:]):
297         * WebView/WebViewPrivate.h:
298
299 2008-08-13  Timothy Hatcher  <timothy@apple.com>
300
301         Fixes a bug where Safari's find banner would be permanently hidden
302         when attaching or closing the Web Inspector while attached.
303
304         https://bugs.webkit.org/show_bug.cgi?id=20376
305
306         Reviewed by Kevin McCullough.
307
308         * WebCoreSupport/WebInspectorClient.mm:
309         (-[WebInspectorWindowController close]):
310         Carefully manipulate the WebFrameView's frame when closing to
311         not assume the WebFrameView's frame fills the inspected WebView.
312         (-[WebInspectorWindowController setAttachedWindowHeight:]):
313         Carefully manipulate the WebFrameView's frame when docking to
314         not assume the WebFrameView plus the Web Inspector WebViews fills
315         the full inspected WebView.
316
317 2008-08-13  Stephanie Lewis  <slewis@apple.com>
318
319         fix 64bit build
320
321         * WebCoreSupport/WebInspectorClient.mm:
322
323 2008-08-13  Timothy Hatcher  <timothy@apple.com>
324
325         Remember the docked state of the Web Inspector, so it can be
326         reopened docked if it was last docked.
327
328         https://bugs.webkit.org/show_bug.cgi?id=14271
329
330         Reviewed by Kevin McCullough.
331
332         * WebCoreSupport/WebInspectorClient.mm:
333         (-[WebInspectorWindowController init]): Initialize _shouldAttach
334         to the value stored in the user defaults. If there has never
335         been a value stored, default to being attached.
336         (-[WebInspectorWindowController showWindow:]): Pass the attached
337         state to InspectorController::setWindowVisible.
338
339 2008-08-12  Timothy Hatcher  <timothy@apple.com>
340
341         Remove the Inspector's WebView for the view hierarchy when closed
342         while attached. This prevents it from showing in the background
343         while the page changes.
344
345         Reviewed by Kevin McCullough.
346
347         * WebCoreSupport/WebInspectorClient.mm:
348         (-[WebInspectorWindowController close:]): Call removeFromSuperview
349         on the Inspector's WebView if it isn't attached, so it will not
350         be visible when navigating pages while closed.
351
352 2008-08-12  Timothy Hatcher  <timothy@apple.com>
353
354         Make the docked Web Inspector resizable.
355
356         https://bugs.webkit.org/show_bug.cgi?id=14282
357
358         Reviewed by Kevin McCullough.
359
360         * WebCoreSupport/WebInspectorClient.h:
361         * WebCoreSupport/WebInspectorClient.mm:
362         (WebInspectorClient::setAttachedWindowHeight): Call setAttachedWindowHeight:
363         on the WebInspectorWindowController.
364         (-[WebInspectorWindowController showWindow:]): Call setAttachedWindowHeight:.
365         (-[WebInspectorWindowController setAttachedWindowHeight:]): Moved code
366         from showWindow: and generalized to allow being called multiple times.
367         Remembers the last height passed, which is used by showWindow: the next
368         time the Inspector attaches.
369
370 2008-08-12  Timothy Hatcher  <timothy@apple.com>
371
372         Remove unneeded header imports from some Web Inspector files.
373
374         Reviewed by Adam Roben.
375
376         * WebCoreSupport/WebInspectorClient.mm:
377         * WebInspector/WebInspector.mm:
378         * WebInspector/WebNodeHighlightView.m:
379
380 2008-08-12  Timothy Hatcher  <timothy@apple.com>
381
382         Remove the call to WKNSWindowMakeBottomCornersSquare on the
383         Web Inspector's window. This isn't needed anymore since the
384         window style masks used always have square bottom corners.
385
386         Reviewed by Adam Roben.
387
388         * WebCoreSupport/WebInspectorClient.mm:
389         (-[WebInspectorWindowController window]): Remove the call
390         to WKNSWindowMakeBottomCornersSquare.
391
392 2008-08-12  Timothy Hatcher  <timothy@apple.com>
393
394         Make attaching and detaching the Web Inspector instantaneous.
395         This also preserves the current view, other state, and keeps
396         the script debugger attached.
397
398         https://bugs.webkit.org/show_bug.cgi?id=19301
399
400         Reviewed by Adam Roben.
401
402         * WebCoreSupport/WebInspectorClient.mm:
403         (-[WebInspectorWindowController close]): Only call setWindowVisible(false)
404         when not moving windows.
405
406 2008-08-12  Dan Bernstein  <mitz@apple.com>
407
408         Reviewed by John Sullivan.
409
410         - replace -[WebPreferences updatesWhenOffscreen] with -[WebView shouldUpdateWhileHidden]
411
412         * WebCoreSupport/WebFrameLoaderClient.mm:
413         (WebFrameLoaderClient::transitionToCommittedForNewPage):
414         * WebView/WebFrame.mm:
415         (-[WebFrame _updateBackgroundAndUpdatesWhileHidden]):
416         * WebView/WebFrameInternal.h:
417         * WebView/WebHTMLView.mm:
418         (-[WebHTMLView windowWillOrderOnScreen:]):
419         * WebView/WebPreferenceKeysPrivate.h:
420         * WebView/WebPreferences.mm:
421         (+[WebPreferences initialize]):
422         * WebView/WebPreferencesPrivate.h:
423         * WebView/WebView.mm:
424         (-[WebViewPrivate init]):
425         (-[WebView _preferencesChangedNotification:]):
426         (-[WebView setBackgroundColor:]):
427         (-[WebView setDrawsBackground:]):
428         (-[WebView shouldUpdateWhileHidden]):
429         (-[WebView setShouldUpdateWhileHidden:]):
430         * WebView/WebViewPrivate.h:
431
432 2008-08-08  Dan Bernstein  <mitz@apple.com>
433
434         Reviewed by John Sullivan.
435
436         - fix <rdar://problem/6130216> Exception "windowRegionBeingDrawn != nil" in NSView when caching image of a subframe
437
438         This change reintroduces <https://bugs.webkit.org/show_bug.cgi?id=5195> on Leopard.
439
440         * WebView/WebHTMLView.mm:
441         (-[WebHTMLView _recursive:displayRectIgnoringOpacity:inContext:topView:]): Removed an
442         unsuccessful workaround for <rdar://problem/5668489>, because invoking
443         layout may change the view hierarchy during the drawing operation,
444         which is not supported on Leopard.
445
446 2008-08-08  Maxime Britto  <britto@apple.com>
447
448         Reviewed by Adele.
449
450         * WebView/WebFrame.mm:
451         (-[WebFrame _scrollDOMRangeToVisible:]):
452
453 2008-08-08  Brady Eidson  <beidson@apple.com>
454
455         Reviewed by Sam Weinig
456
457         Fix for <rdar://problem/5865504>
458
459         This bug was actually *largely* fixed by http://trac.webkit.org/changeset/35538.
460         But with that same patch, it became possible for a WebResource to fail to initialize.  
461         Therefore we were trying to add nil to an NSCFArray for certain situations, which is bad.
462         Lets fix that, shall we?
463
464         * WebView/WebArchive.mm:
465         (-[WebArchive subresources]): 
466
467 2008-08-06  Eric Seidel  <eric@webkit.org>
468
469         Reviewed by Cameron Zwarich.
470
471         Move more methods from Frame into ScriptController
472         https://bugs.webkit.org/show_bug.cgi?id=20294
473
474         The WebKit side of this move.  Calls to frame() are now frame()->script()
475
476         * Plugins/WebBaseNetscapePluginView.mm:
477         (-[WebBaseNetscapePluginView getVariable:value:]):
478         (-[WebBaseNetscapePluginView _destroyPlugin]):
479         * Plugins/WebPluginController.mm:
480         (-[WebPluginController destroyPlugin:]):
481         (-[WebPluginController destroyAllPlugins]):
482         * WebCoreSupport/WebFrameLoaderClient.mm:
483         * WebView/WebFrame.mm:
484         (-[WebFrame windowObject]):
485         * WebView/WebScriptDebugger.mm:
486         (WebScriptDebugger::callEvent):
487         * WebView/WebView.mm:
488         (-[WebView windowScriptObject]):
489
490 2008-08-06  Dan Bernstein  <mitz@apple.com>
491
492         Reviewed by Mark Rowe.
493
494         - fix an assertion failure in Cache::setCapacities()
495
496         * Misc/WebKitSystemBits.h: Changed the return type of WebMemorySize()
497         to uint64_t.
498         * Misc/WebKitSystemBits.m:
499         (WebMemorySize):
500         * WebView/WebView.mm:
501         (+[WebView _setCacheModel:]):
502
503 2008-08-05  Anders Carlsson  <andersca@apple.com>
504
505         Pass in the correct class here.
506         
507         * WebView/WebResource.mm:
508         (-[WebResourcePrivate dealloc]):
509
510 2008-08-05  Anders Carlsson  <andersca@apple.com>
511
512         Reviewed by Darin.
513
514         <rdar://problem/6037398>
515         ER: Deallocate WebKit objects on the main thread, even if released on secondary thread
516         
517         Add calls to WebCoreObjCScheduleDeallocateOnMainThread in dealloc methods of objects we expose.
518
519         * Carbon/CarbonWindowAdapter.m:
520         (-[CarbonWindowAdapter dealloc]):
521         * History/WebBackForwardList.mm:
522         (-[WebBackForwardList dealloc]):
523         * History/WebHistoryItem.mm:
524         (-[WebHistoryItem dealloc]):
525         * Misc/WebElementDictionary.mm:
526         (+[WebElementDictionary initialize]):
527         (-[WebElementDictionary dealloc]):
528         * WebCoreSupport/WebEditorClient.mm:
529         (-[WebEditCommand dealloc]):
530         * WebCoreSupport/WebFrameLoaderClient.mm:
531         * WebView/WebArchive.mm:
532         (-[WebArchivePrivate dealloc]):
533         * WebView/WebDataSource.mm:
534         (-[WebDataSourcePrivate dealloc]):
535         * WebView/WebHTMLView.mm:
536         (-[WebHTMLViewPrivate dealloc]):
537         (-[WebHTMLView dealloc]):
538         * WebView/WebResource.mm:
539         (-[WebResourcePrivate dealloc]):
540
541 2008-08-05  Anders Carlsson  <andersca@apple.com>
542
543         Reviewed by Darin.
544
545         Remove MainThreadObjectDeallocator.{h|mm}.
546
547         * WebView/MainThreadObjectDeallocator.h: Removed.
548         * WebView/MainThreadObjectDeallocator.mm: Removed.
549         
550         * WebView/WebView.mm:
551         (-[WebView dealloc]):
552         Call WebCoreObjCScheduleDeallocateOnMainThread instead.
553
554 2008-08-05  Anders Carlsson  <andersca@apple.com>
555
556         Reviewed by Darin.
557
558         Make the main thread object deallocator work with subclasses.
559         
560         * WebView/MainThreadObjectDeallocator.h:
561         * WebView/MainThreadObjectDeallocator.mm:
562         (deallocCallback):
563         Call the correct dealloc method.
564                 
565         (scheduleDeallocateOnMainThread):
566         Store both the class and the instance, so we know which dealloc method to call.
567         
568         * WebView/WebView.mm:
569         (-[WebViewPrivate dealloc]):
570         Schedule deallocation on the main thread.
571
572 2008-08-05  Dan Bernstein  <mitz@apple.com>
573
574         Reviewed by Mark Rowe and Anders Carlsson.
575
576         - fix WebMemorySize() reporting a value capped at 2GB
577
578         * misc/WebKitSystemBits.m:
579         (WebMemorySize): Changed to return the max_mem field, which, unlike
580         memory_size, is not capped at 2GB.
581         * WebView/WebView.mm:
582         (+[WebView _setCacheModel:]): Made the cache sizes for over 2GB RAM the
583         same as for 2GB, so that behavior on machines that have more than 2GB
584         RAM is not affected by the fix to WebMemorySize().
585
586 2008-08-04  Mark Rowe  <mrowe@apple.com>
587
588         Build fix.
589
590         * WebView/WebHTMLView.mm:
591
592 2008-08-04  Mark Rowe  <mrowe@apple.com>
593
594         Reviewed by Kevin Decker.
595
596         Adopt the formal protocols where necessary.
597         Final part of fix for <rdar://problem/5853147>.
598
599         * WebCoreSupport/WebInspectorClient.mm:
600         * WebView/WebHTMLView.mm:
601         * WebView/WebView.mm:
602         (-[WebView _openFrameInNewWindowFromMenu:]):
603
604 2008-08-04  Mark Rowe  <mrowe@apple.com>
605
606         Reviewed by Darin Adler.
607
608         Declare empty protocols when using versions of AppKit that do not use formal protocols for delegates and data sources.
609         Part one of fix for <rdar://problem/5853147>.
610
611         * Misc/EmptyProtocolDefinitions.h:
612         * WebKitPrefix.h:
613
614 2008-08-04  Brady Eidson  <beidson@apple.com>
615
616         Reviewed by Mitz Pettel
617
618         Fix <rdar://problem/5820157> - Saving WebArchives of Mail attachments broken.
619
620         This broke in r31355 when we stopped returning nil WebResources when there was nil
621         resource data.
622
623         * WebView/WebResource.mm:
624         (-[WebResource _initWithCoreResource:]): Restore previous behavior of returning nil
625           when the resource data is null.
626
627 2008-08-02  Matt Lilek  <webkit@mattlilek.com>
628
629         Reviewed by Tim Hatcher.
630
631         Update the window gradient offset to match the inspector toolbar's new height.
632
633         * WebCoreSupport/WebInspectorClient.mm:
634         (-[WebInspectorWindowController window]):
635
636 2008-08-01  Anders Carlsson  <andersca@apple.com>
637
638         Reviewed by Jon.
639
640         <rdar://problem/6120206>
641         Crash when plug-in queries for NPPVpluginWantsAllNetworkStreams.
642         
643         Pass in a pointer to a void* to make sure that plug-ins don't overwrite the stack.
644
645         * Plugins/WebBaseNetscapePluginStream.mm:
646         (-[WebBaseNetscapePluginStream wantsAllStreams]):
647
648 2008-07-31  Anders Carlsson  <andersca@apple.com>
649
650         Reviewed by Darin.
651
652         <rdar://problem/5949410>
653         Add the ability to transfer a given application cache to a new database.
654
655         * Misc/WebKitNSStringExtras.h:
656         * Misc/WebKitNSStringExtras.m:
657         (+[NSString _webkit_applicationCacheDirectoryWithBundleIdentifier:]):
658         New method which returns the appopriate cache directory for a given bundle identifier.
659         
660         * WebView/WebDataSource.mm:
661         (-[WebDataSource _transferApplicationCache:]):
662         Transfer the application cache.
663         
664         * WebView/WebDataSourcePrivate.h:
665         * WebView/WebView.mm:
666         (WebKitInitializeApplicationCachePathIfNecessary):
667         Change this to use _webkit_applicationCacheDirectoryWithBundleIdentifier.
668
669 2008-07-31  John Sullivan  <sullivan@apple.com>
670
671         WebKit part of <rdar://problem/6116650> Text-only zoom setting should be stored in WebKit prefs
672
673         Reviewed by Hyatt
674
675         * WebView/WebPreferenceKeysPrivate.h:
676         added WebKitZoomsTextOnlyPreferenceKey
677         
678         * WebView/WebPreferences.mm:
679         (+[WebPreferences initialize]):
680         default value of YES for WebKitZoomsTextOnlyPreferenceKey
681         (-[WebPreferences zoomsTextOnly]):
682         getter for WebKitZoomsTextOnlyPreferenceKey
683         (-[WebPreferences setZoomsTextOnly:]):
684         setter for WebKitZoomsTextOnlyPreferenceKey
685         
686         * WebView/WebPreferencesPrivate.h:
687         declare zoomsTextOnly/setZoomsTextOnly:
688         
689         * WebView/WebView.mm:
690         (-[WebView _preferencesChangedNotification:]):
691         update WebCore::Settings value for zoomsTextOnly
692
693 2008-07-31  David D. Kilzer  <ddkilzer@webkit.org>
694
695         Fix layout test results for webarchive/test-xml-stylesheet.xml
696
697         Reviewed by Darin.
698
699         Needed to expose -[WebHTMLRepresentation supportedNonImageMIMETypes]
700         for DumpRenderTree.
701
702         * WebView/WebHTMLRepresentationInternal.h: Added.
703
704 2008-07-31  Alexey Proskuryakov  <ap@webkit.org>
705
706         Release build fix.
707
708         * Plugins/WebBaseNetscapePluginView.mm: (-[WebBaseNetscapePluginView setWindowIfNecessary]):
709         Don't define to npErr in release builds, as it is only used for logging.
710
711 2008-07-31  John Sullivan  <sullivan@apple.com>
712
713         Fixed <https://bugs.webkit.org/show_bug.cgi?id=5195>
714         drawing with cacheDisplayInRect:toBitmapImageRep: doesn't trigger layout on Leopard
715
716         Reviewed by Dan
717
718         * WebView/WebHTMLView.mm:
719         (-[WebHTMLView _recursive:displayRectIgnoringOpacity:inContext:topView:]):
720         include Leopard in the #ifdef that forces a layout if needed
721
722 2008-07-30  Brady Eidson  <beidson@apple.com>
723
724         Reviewed by Adam and Hyatt
725
726         Fix for <rdar://problem/6099748>
727
728         * WebView/WebView.mm:
729         (-[WebView _preferencesChangedNotification:]): Set the "don't enforce CSS mime type in strict mode" 
730           quirk when running under iWeb 2
731
732 2008-07-31  Alexey Proskuryakov  <ap@webkit.org>
733
734         Rubber-stamped by Maciej.
735
736         Eliminate JSLock (it was already disabled, removing the stub implementaion and all
737         call sites now).
738
739         * ForwardingHeaders/kjs/JSLock.h: Removed.
740         * Misc/WebCoreStatistics.mm:
741         (+[WebCoreStatistics javaScriptObjectsCount]):
742         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
743         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
744         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
745         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
746         (+[WebCoreStatistics shouldPrintExceptions]):
747         (+[WebCoreStatistics setShouldPrintExceptions:]):
748         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
749         * Plugins/WebBaseNetscapePluginStream.mm:
750         (-[WebBaseNetscapePluginStream wantsAllStreams]):
751         * Plugins/WebBaseNetscapePluginView.mm:
752         (-[WebBaseNetscapePluginView sendEvent:isDrawRect:]):
753         (-[WebBaseNetscapePluginView setWindowIfNecessary]):
754         (-[WebBaseNetscapePluginView start]):
755         (-[WebBaseNetscapePluginView createPluginScriptableObject]):
756         (-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]):
757         (-[WebBaseNetscapePluginView webFrame:didFinishLoadWithReason:]):
758         (-[WebBaseNetscapePluginView loadPluginRequest:]):
759         (-[WebBaseNetscapePluginView _printedPluginBitmap]):
760         * Plugins/WebPluginController.mm:
761         (+[WebPluginController plugInViewWithArguments:fromPluginPackage:]):
762         (-[WebPluginController startAllPlugins]):
763         (-[WebPluginController stopAllPlugins]):
764         (-[WebPluginController addPlugin:]):
765         (-[WebPluginController destroyPlugin:]):
766         (-[WebPluginController destroyAllPlugins]):
767         * WebView/WebFrame.mm:
768         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
769         * WebView/WebScriptDebugDelegate.mm:
770         (-[WebScriptCallFrame evaluateWebScript:]):
771         * WebView/WebView.mm:
772         (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
773
774 2008-07-30  Beth Dakin  <bdakin@apple.com>
775
776         Reviewed by Anders Carlsson.
777
778         Fixes <rdar://problem/6041390>
779
780         Adds the ability to have a frame that is "disconnected" from the 
781         main frame from the perspective of top and parent in 
782         Javascript.
783
784         * WebView/WebFrame.mm:
785         (-[WebFrame _setIsDisconnectedFrame]):
786         * WebView/WebFramePrivate.h:
787
788 2008-07-29  Mark Rowe  <mrowe@apple.com>
789
790         Tweak to the build fix to keep Dan happy.
791
792         * Plugins/WebBaseNetscapePluginView.mm:
793         * WebView/WebHTMLView.mm:
794
795 2008-07-29  Mark Rowe  <mrowe@apple.com>
796
797         Build fix.
798
799         * Plugins/WebBaseNetscapePluginView.mm:
800         (-[WebBaseNetscapePluginView inputContext]):
801         * WebView/WebHTMLView.mm:
802
803 2008-07-28  Anders Carlsson  <andersca@apple.com>
804
805         Reviewed by Kevin Decker.
806
807         Based on a patch by Dimcho Balev.
808         
809         https://bugs.webkit.org/show_bug.cgi?id=18676
810         <rdar://problem/6106578>
811         Plug-In API Proposal: Enable plugins to receive response body when an HTTP error occurs
812
813         * Plugins/WebBaseNetscapePluginStream.h:
814         Add NPP_GetValue pointer.
815         
816         * Plugins/WebBaseNetscapePluginStream.mm:
817         (-[WebBaseNetscapePluginStream setPlugin:]):
818         Initialize NPP_GetValue.
819         
820         (-[WebBaseNetscapePluginStream wantsAllStreams]):
821         Call NPP_GetValue.
822         
823         * Plugins/WebPlugInStreamLoaderDelegate.h:
824         * WebCoreSupport/WebNetscapePlugInStreamLoaderClient.h:
825         * WebCoreSupport/WebNetscapePlugInStreamLoaderClient.mm:
826         (WebNetscapePlugInStreamLoaderClient::wantsAllStreams):
827         Implement this and call down to the stream.
828
829 2008-07-28  Anders Carlsson  <andersca@apple.com>
830
831         Reviewed by Adam.
832
833         <rdar://problem/6105529> 
834         https://bugs.webkit.org/show_bug.cgi?id=19659
835         Turning off plugins causes crash
836         
837         When an active page has plug-ins, and plug-ins are disabled, they will be stopped and will
838         end up in a state where they don't have an event handler. Because of this, we need to 
839         check that the plug-in has been started before calling the event handler.
840         
841         * Plugins/WebBaseNetscapePluginView.mm:
842         (-[WebBaseNetscapePluginView sendActivateEvent:]):
843         (-[WebBaseNetscapePluginView sendDrawRectEvent:]):
844         (-[WebBaseNetscapePluginView setHasFocus:]):
845         (-[WebBaseNetscapePluginView mouseDown:]):
846         (-[WebBaseNetscapePluginView mouseUp:]):
847         (-[WebBaseNetscapePluginView mouseEntered:]):
848         (-[WebBaseNetscapePluginView mouseExited:]):
849         (-[WebBaseNetscapePluginView handleMouseMoved:]):
850         (-[WebBaseNetscapePluginView mouseDragged:]):
851         (-[WebBaseNetscapePluginView scrollWheel:]):
852         (-[WebBaseNetscapePluginView keyUp:]):
853         (-[WebBaseNetscapePluginView keyDown:]):
854         (-[WebBaseNetscapePluginView flagsChanged:]):
855         (-[WebBaseNetscapePluginView cut:]):
856         (-[WebBaseNetscapePluginView copy:]):
857         (-[WebBaseNetscapePluginView paste:]):
858         (-[WebBaseNetscapePluginView selectAll:]):
859         (-[WebBaseNetscapePluginView drawRect:]):
860         (-[WebBaseNetscapePluginView inputContext]):
861
862 2008-07-26  Daniel Jalkut  <jalkut@red-sweater.com>
863
864         Reviewed by Geoff Garen.
865
866         Changes to accommodate newly named/signatured loading methods in WebCore.
867
868         * Plugins/WebNetscapePluginStream.mm:
869         (-[WebNetscapePluginStream initWithRequest:plugin:notifyData:sendNotification:]):
870         * Plugins/WebPluginContainerCheck.mm:
871         (-[WebPluginContainerCheck _isForbiddenFileLoad]):
872         * WebView/WebPDFView.mm:
873         (-[WebPDFView PDFViewWillClickOnLink:withURL:]):
874
875 2008-07-21  Mark Rowe  <mrowe@apple.com>
876
877         Reviewed by Sam Weinig.
878
879         <rdar://problem/6091287> Revamp the handling of CFBundleShortVersionString to be fixed at the major component of the version number.
880
881         * Configurations/Version.xcconfig:
882         * Info.plist:
883
884 2008-07-21  Anders Carlsson  <andersca@apple.com>
885
886         Reviewed by Geoff.
887
888         <rdar://problem/5820667> 
889         CrashTracer: [USER] 3759 crashes in Safari at FrameLoader::activeDocumentLoader const + 6 while canceling plug-in load
890         
891         Don't allow URLs to be loaded in response to an NPP_DestroyStream that happens when tearing down the plug-in.
892         
893         * Plugins/WebBaseNetscapePluginView.mm:
894         (-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
895
896 2008-07-21  Mark Rowe  <mrowe@apple.com>
897
898         Reviewed by Adam Roben.
899
900         <rdar://problem/5624143> WebView printing doesn't work correctly in x86_64
901
902         Fix the return type of an NSView method that we override so that the correct data type is used in 64-bit.
903         This prevents a garbage value being used for the scale factor that the NSView print machinery applies.
904
905         * WebView/WebHTMLView.mm:
906
907 2008-07-21  Mark Rowe  <mrowe@apple.com>
908
909         Reviewed by Adam Roben.
910
911         Fix CallDelegateReturningFloat for x86_64.  The x86_64 Objective-C runtime
912         only uses objc_msgSend_fpret for long double return values.  For float return
913         values the standard objc_msgSend is used, as on ppc and ppc64.
914
915         * WebView/WebView.mm: Use objc_msgSend_float_return as the name of our version of
916         objc_msgSend with the correct return type.  We can no longer call it objc_msgSend_fpret
917         as that method is defined by the Objective-C runtime for x86_64.
918         (CallDelegateReturningFloat):
919
920 2008-07-14  Dan Bernstein  <mitz@apple.com>
921
922         Reviewed by John Sullivan.
923
924         - WebKit part of fixing <rdar://problem/6071850> Subviews not drawn correctly when using -cacheDisplayInRect:toBitmapImageRep:
925
926         * Plugins/WebBaseNetscapePluginView.mm:
927         (-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]): Changed
928         to account for the case of being drawn into a bitmap context that is not
929         a window's backing store. In that case, there are no valid "rects being
930         drawn" to clip to.
931         * WebView/WebHTMLView.mm:
932         (-[WebHTMLView _recursive:displayRectIgnoringOpacity:inContext:topView:]):
933         Added an override of this NSView method which is used in for
934         -cacheDisplayInRect:toBitmapImageRep:. Like two existing NSView drawing
935         machinery overrides, it sets subviews aside before invoking the
936         superclass implementation. On Tiger, it also updates the layout.
937
938 2008-07-14  Alexey Proskuryakov  <ap@webkit.org>
939
940         Reviewed by Geoff Garen.
941
942         Eliminate per-thread JavaScript global data instance support and make arbitrary
943         global data/global object combinations possible.
944
945         * Misc/WebCoreStatistics.mm:
946         (+[WebCoreStatistics javaScriptObjectsCount]):
947         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
948         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
949         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
950         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
951         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
952         Ask WebCore for its instance of JSGlobalData, now that it is not in per-thread storage.
953
954 2008-07-11  Stephanie Lewis  <slewis@apple.com>
955
956         Reviewed by Darin Adler.
957
958         Disable WTF leak messages when using fast teardown.  Use full document teardown while running in debug.
959
960         * WebView/WebPreferences.m: Removed.
961         * WebView/WebPreferences.mm: Copied from http:/svn.webkit.org/repository/webkit/trunk/WebKit/mac/WebView/WebPreferences.m.
962         (+[WebPreferences initialize]): if running in Default enable full  document teardown
963         (-[WebPreferences editableLinkBehavior]):
964         (-[WebPreferences setFullDocumentTeardownEnabled:]):
965         * WebView/WebView.mm:
966         (-[WebView _close]): disable leak messages if using fast teardown
967
968 2008-07-10  Mark Rowe  <mrowe@apple.com>
969
970         Reviewed by Sam Weinig.
971
972         Define WEBKIT_VERSION_MIN_REQUIRED=WEBKIT_VERSION_LATEST when building WebKit to ensure that no symbols end up with the weak_import attribute.
973
974         * Configurations/WebKit.xcconfig:
975
976 2008-07-10  Mark Rowe  <mrowe@apple.com>
977
978         Reviewed by Sam Weinig.
979
980         Fix the Tiger build by omitting annotations from methods declared in categories when using old versions of GCC.
981
982         * Plugins/WebPlugin.h: Wrap annotations on methods declared in categories in the WEBKIT_CATEGORY_METHOD_ANNOTATION macro.
983         * WebView/WebFrameLoadDelegate.h: Ditto.
984         * WebView/WebUIDelegate.h: Ditto.
985
986 2008-07-10  Anders Carlsson  <andersca@apple.com>
987
988         Reviewed by Mark.
989         
990         Add availability macros for the new WebPlugin methods.
991
992         * Plugins/WebPlugin.h:
993         * Plugins/WebPluginViewFactory.h:
994
995 2008-07-09  Mark Rowe  <mrowe@apple.com>
996
997         Reviewed by Geoff Garen.
998
999         Don't warn about deprecated functions in production builds.
1000
1001         * Configurations/Base.xcconfig:
1002         * Configurations/DebugRelease.xcconfig:
1003
1004 2008-07-09  Brady Eidson  <beidson@apple.com>
1005
1006         Reviewed by Darin
1007
1008         <rdar://problem/5823684> - Crash manipulating frame tree of a new frame before the new frame
1009         has been installed in a frame tree.
1010
1011         The root of this problem was that calling init() on a new frame could end up calling arbitrary
1012         javascript that might end up removing the frame from the tree.  This opened up a small can of worms
1013         such as the frame not having yet been installed in its frame tree, and other assumed behavior while
1014         destroying the frame.
1015
1016         Note that each platforms WebKit API layer needs to make this new guarantee:
1017         "The new Frame must be installed in its FrameTree before newCoreFrame->init() is called"
1018         I am fixing Mac, and Windows and GTK already have this property.  Wx currently has subframes disabled
1019         but will need to add this guarantee when re-enabling, and Qt is currently vulnerable to this same bug.
1020
1021         Alternately, the way frames are created right now is roundabout and asinine, and this is a key
1022         architectural improvement we can make in the future so the individual platform clients are no longer
1023         vulnerable to this problem, which should really have been a WebCore issue.
1024
1025         * WebCoreSupport/WebFrameLoaderClient.mm:
1026         (WebFrameLoaderClient::createFrame):  Don't bother null checking the newCoreFrame - can't be NULL.
1027           Don't appendChild() the new frame here.
1028           Null-check the new frame's page before loading the URL into it, as it might already have been
1029           removed from the page.
1030
1031         * WebView/WebFrame.mm:
1032         (+[WebFrame _createFrameWithPage:frameName:frameView:ownerElement:]):  If there is an ownerElement,
1033           go ahead and install the new frame in the frame tree *before* calling init() on it.
1034
1035 2008-07-09  Anders Carlsson  <andersca@apple.com>
1036
1037         Reviewed by Darin.
1038
1039         Make some WebPlugin and WebPluginFactory SPI public.
1040         
1041         * Plugins/WebPlugin.h:
1042         * Plugins/WebPluginPrivate.h:
1043         * Plugins/WebPluginViewFactory.h:
1044         * Plugins/WebPluginViewFactoryPrivate.h:
1045
1046 2008-07-08  Jon Honeycutt  <jhoneycutt@apple.com>
1047
1048         Reviewed by Anders.
1049
1050         Port r34988 to Mac: don't call NPP_DestroyStream if NPP_NewStream was
1051         unsuccessful.
1052
1053         * Plugins/WebBaseNetscapePluginStream.h: Added new member,
1054         newStreamSuccessful.
1055         * Plugins/WebBaseNetscapePluginStream.mm:
1056         (-[WebBaseNetscapePluginStream initWithRequestURL:plugin:notifyData:sendNotification:]): Initialize new member.
1057         (-[WebBaseNetscapePluginStream startStreamResponseURL:expectedContentLength:lastModifiedDate:MIMEType:headers:]): If NPP_NewStream is successful, set
1058         newStreamSuccessful to YES.
1059         (-[WebBaseNetscapePluginStream _destroyStream]): Only call
1060         NPP_DestroyStream if newStreamSuccessful is true.
1061
1062 2008-07-08  Dan Bernstein  <mitz@apple.com>
1063
1064         Reviewed by John Sullivan.
1065
1066         - WebKit part of <rdar://problem/6008409> Need a way to disable updates in offscreen views
1067
1068         * WebView/WebHTMLView.mm:
1069         (-[WebHTMLView addWindowObservers]): Added code to observe when the
1070         window goes onscreen.
1071         (-[WebHTMLView removeWindowObservers]): Added.
1072         (-[WebHTMLView windowWillOrderOnScreen:]): Added. If the view is set to
1073         not update when offscreen, calls -setNeedsDisplay: just before it comes
1074         onscreen.
1075         * WebView/WebPreferenceKeysPrivate.h: Added preference key.
1076         * WebView/WebPreferences.m:
1077         (+[WebPreferences initialize]): Made updates when offscreen on by
1078         default.
1079         (-[WebPreferences updatesWhenOffscreen]): Added.
1080         (-[WebPreferences setUpdatesWhenOffscreen:]): Added.
1081         * WebView/WebPreferencesPrivate.h:
1082         * WebView/WebView.mm:
1083         (-[WebView _preferencesChangedNotification:]): Added code to update the
1084         updatesWhenOffscreen setting in WebCore.
1085
1086 2008-07-07  Anders Carlsson  <andersca@apple.com>
1087
1088         Reviewed by Darin.
1089
1090         Speculative fix for     
1091         <rdar://problem/5839800>
1092         CrashTracer: [USER] 5802 crashes in Safari at com.apple.WebKit: -[WebHTMLView(WebPrivate) _updateMouseoverWithFakeEvent] + 389
1093         
1094         Set _private->closed to YES before calling -[WebPluginController destroyAllPlugins].
1095         
1096         My theory is that the plug-in destruction callbacks could end up rescheduling timers or re-adding notifications.
1097         This is usually protected by _private->closed, but in this case it might still be false.
1098
1099         * WebView/WebHTMLView.mm:
1100         (-[WebHTMLView close]):
1101
1102 2008-07-05  Mark Rowe  <mrowe@apple.com>
1103
1104         Reviewed by John Sullivan.
1105
1106         Remove WebSearchableTextView as it has been unused for some time now.
1107
1108         * Misc/WebSearchableTextView.h: Removed.
1109         * Misc/WebSearchableTextView.m: Removed.
1110
1111 2008-07-05  Mark Rowe  <mrowe@apple.com>
1112
1113         Reviewed by John Sullivan.
1114
1115         Don't leak the result of WKCopyCFLocalizationPreferredName when running under GC.
1116
1117         * Misc/WebNSUserDefaultsExtras.m:
1118         (-[NSString _webkit_HTTPStyleLanguageCode]):
1119
1120 2008-07-02  Alexey Proskuryakov  <ap@webkit.org>
1121
1122         Inspired and reviewed by Mark Rowe.
1123
1124         Change non-API includes from JavaScriptCore/ to kjs/ and wtf/ to match prevalent style.
1125
1126         * Carbon/HIViewAdapter.m:
1127         * DOM/WebDOMOperations.mm:
1128         * DefaultDelegates/WebDefaultContextMenuDelegate.mm:
1129         * DefaultDelegates/WebDefaultPolicyDelegate.m:
1130         * History/WebBackForwardList.mm:
1131         * History/WebHistory.mm:
1132         * History/WebHistoryItem.mm:
1133         * History/WebHistoryItemInternal.h:
1134         * Misc/WebCoreStatistics.mm:
1135         * Misc/WebDownload.m:
1136         * Misc/WebGraphicsExtras.c:
1137         * Misc/WebKitLogging.h:
1138         * Misc/WebKitSystemBits.m:
1139         * Misc/WebLocalizableStrings.m:
1140         * Misc/WebNSArrayExtras.m:
1141         * Misc/WebNSDataExtras.m:
1142         * Misc/WebNSDictionaryExtras.m:
1143         * Misc/WebNSFileManagerExtras.m:
1144         * Misc/WebNSPasteboardExtras.mm:
1145         * Misc/WebNSURLExtras.mm:
1146         * Misc/WebNSUserDefaultsExtras.m:
1147         * Panels/WebAuthenticationPanel.m:
1148         * Panels/WebPanelAuthenticationHandler.m:
1149         * Plugins/WebBaseNetscapePluginView.mm:
1150         * Plugins/WebBasePluginPackage.m:
1151         * Plugins/WebNetscapePluginEmbeddedView.mm:
1152         * Plugins/WebPluginContainerCheck.mm:
1153         * Plugins/WebPluginController.mm:
1154         * Plugins/WebPluginDatabase.mm:
1155         * WebCoreSupport/WebJavaScriptTextInputPanel.m:
1156         * WebCoreSupport/WebKeyGenerator.m:
1157         * WebCoreSupport/WebViewFactory.mm:
1158         * WebKitPrefix.h:
1159         * WebView/WebHTMLRepresentation.mm:
1160         * WebView/WebPDFRepresentation.m:
1161         * WebView/WebPDFView.mm:
1162         * WebView/WebScriptDebugger.mm:
1163
1164 2008-07-01  Alexey Proskuryakov  <ap@webkit.org>
1165
1166         Reviewed by Darin.
1167
1168         Disable JSLock for per-thread contexts.
1169
1170         * Misc/WebCoreStatistics.mm:
1171         (+[WebCoreStatistics javaScriptObjectsCount]):
1172         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
1173         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
1174         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
1175         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
1176         (+[WebCoreStatistics shouldPrintExceptions]):
1177         (+[WebCoreStatistics setShouldPrintExceptions:]):
1178         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
1179         * Plugins/WebBaseNetscapePluginView.mm:
1180         (-[WebBaseNetscapePluginView sendEvent:isDrawRect:]):
1181         (-[WebBaseNetscapePluginView setWindowIfNecessary]):
1182         (-[WebBaseNetscapePluginView start]):
1183         (-[WebBaseNetscapePluginView createPluginScriptableObject]):
1184         (-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]):
1185         (-[WebBaseNetscapePluginView webFrame:didFinishLoadWithReason:]):
1186         (-[WebBaseNetscapePluginView loadPluginRequest:]):
1187         (-[WebBaseNetscapePluginView _printedPluginBitmap]):
1188         * Plugins/WebPluginController.mm:
1189         (+[WebPluginController plugInViewWithArguments:fromPluginPackage:]):
1190         (-[WebPluginController startAllPlugins]):
1191         (-[WebPluginController stopAllPlugins]):
1192         (-[WebPluginController addPlugin:]):
1193         (-[WebPluginController destroyPlugin:]):
1194         (-[WebPluginController destroyAllPlugins]):
1195         * WebView/WebFrame.mm:
1196         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
1197         * WebView/WebScriptDebugDelegate.mm:
1198         (-[WebScriptCallFrame evaluateWebScript:]):
1199         * WebView/WebView.mm:
1200         (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
1201         Pass a parameter (always false) to JSLock and JSLock::DropAllLocks to indicate that WebKit
1202         doesn't need locking. In the future, it may be possible to remove some of these if we
1203         establish that this won't make JSC assertions fail (and that we don't want to add such
1204         assertions either).
1205         Added includes that are now needed.
1206
1207 2008-07-01  Kevin McCullough  <kmccullough@apple.com>
1208
1209         Build fix.
1210
1211         * WebView/WebView.mm:
1212
1213 2008-07-01  Anders Carlsson  <andersca@apple.com>
1214
1215         Reviewed by Darin.
1216
1217         Use the PluginMainThreadScheduler, and implement NPN_PluginThreadAsyncCall.
1218         
1219         * Plugins/WebBaseNetscapePluginView.mm:
1220         (-[WebBaseNetscapePluginView _createPlugin]):
1221         Register the plug-in instance.
1222         
1223         (-[WebBaseNetscapePluginView _destroyPlugin]):
1224         Unegister the plug-in instance.
1225         
1226         * Plugins/WebNetscapePluginPackage.m:
1227         (-[WebNetscapePluginPackage load]):
1228         Set NPN_PluginThreadAsyncCall.
1229         
1230         * Plugins/npapi.mm:
1231         (NPN_PluginThreadAsyncCall):
1232         Implement this.
1233
1234 2008-07-01  Dan Bernstein  <mitz@apple.com>
1235
1236         Reviewed by Darin Adler.
1237
1238         - WebKit part of moving the method to set the base writing direction from Frame to Editor
1239
1240         * WebView/WebHTMLView.mm:
1241         (-[WebHTMLView toggleBaseWritingDirection:]): Changed back to call the
1242         Editor method.
1243         (-[WebHTMLView changeBaseWritingDirection:]): Ditto.
1244         (-[WebHTMLView _changeBaseWritingDirectionTo:]): Ditto.
1245
1246 2008-07-01  Geoffrey Garen  <ggaren@apple.com>
1247
1248         Build fix: forgot to check in this file.
1249
1250         * WebView/WebScriptDebugger.mm:
1251         (WebScriptDebugger::WebScriptDebugger):
1252
1253 2008-06-30  Dan Bernstein  <mitz@apple.com>
1254
1255         Reviewed by Adele Peterson.
1256
1257         - WebKit/mac part of <rdar://problem/3881497> Writing direction context menu item has no effect on text typed in Safari
1258
1259         * WebView/WebHTMLView.mm:
1260         (-[WebHTMLView toggleBaseWritingDirection:]): Changed to call
1261         WebCore::Frame::setSelectionBaseWritingDirection() instead of
1262         WebCore::Editor::setBaseWritingDirection().
1263         (-[WebHTMLView changeBaseWritingDirection:]): Ditto.
1264         (-[WebHTMLView _changeBaseWritingDirectionTo:]): Ditto.
1265
1266 2008-06-28  Darin Adler  <darin@apple.com>
1267
1268         - fix build
1269
1270         * WebView/WebView.mm:
1271         (aeDescFromJSValue): Use get instead of getItem, which no longer exists.
1272
1273 2008-06-26  Anders Carlsson  <andersca@apple.com>
1274
1275         Reviewed by Darin.
1276
1277         Add a new MainThreadObjectDeallocator which can schedule dealloc calls on the main thread
1278         if necessary. Use this for the WebView class. 
1279                 
1280         * WebView/MainThreadObjectDeallocator.h: Added.
1281         * WebView/MainThreadObjectDeallocator.mm: Added.
1282         (deallocCallback):
1283         (scheduleDeallocateOnMainThread):
1284         * WebView/WebView.mm:
1285         (-[WebViewPrivate dealloc]):
1286         (+[WebView initialize]):
1287
1288 2008-06-25  Anders Carlsson  <andersca@apple.com>
1289
1290         Reviewed by Mark.
1291
1292         <rdar://problem/5984270> 
1293         REGRESSION (Tiger only) : Mail crashes because message load is being processed on a secondary thread
1294         
1295         * WebView/WebView.mm:
1296         (tigerMailReleaseIMP):
1297         New method that makes sure that the final release happens on the main thread.
1298         
1299         (-[WebView release]):
1300         New method that just calls [super release];
1301         
1302         (+[WebView initialize]):
1303         When running under Tiger mail, replace the release method with tigerMailReleaseIMP.
1304
1305 2008-06-19  Alexey Proskuryakov  <ap@webkit.org>
1306
1307         Reviewed by Geoff.
1308
1309         Make Machine per-JSGlobalData.
1310
1311         * WebView/WebScriptDebugger.mm:
1312         (WebScriptDebugger::WebScriptDebugger):
1313
1314 2008-06-17  Alexey Proskuryakov  <ap@webkit.org>
1315
1316         Reviewed by Darin.
1317
1318         Prepare JavaScript heap for being per-thread.
1319
1320         * Misc/WebCoreStatistics.mm:
1321         (+[WebCoreStatistics javaScriptObjectsCount]):
1322         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
1323         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
1324         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
1325         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
1326         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
1327         Use JSGlobalData::threadInstance()->heap instead of static Collector calls.
1328
1329 2008-06-17  Darin Adler  <darin@apple.com>
1330
1331         Reviewed by Sam.
1332
1333         * WebView/WebHTMLView.mm:
1334         (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]): Use create instead of new
1335         to create a CSSMutableStyleDeclaration.
1336
1337 2008-06-16  Mark Rowe  <mrowe@apple.com>
1338
1339         Reviewed by Darin Adler.
1340
1341         <rdar://problem/5951874> WebHTMLHighlighter mistakenly gained two new methods, causing compile warnings
1342
1343         _pauseNullEventsForAllNetscapePlugins and _resumeNullEventsForAllNetscapePlugins ended up being declared both in
1344         WebHTMLViewInternal.h and as members of the WebHTMLHighlighter protocol in WebHTMLViewPrivate.h.  They don't belong
1345         in the protocol, but they do need to be available outside of WebKit so they're being moved to the correct location
1346         in WebHTMLViewPrivate.h and removed from WebHTMLViewInternal.h.
1347
1348         * WebView/WebHTMLView.mm:
1349         (-[WebHTMLView _pauseNullEventsForAllNetscapePlugins]):
1350         (-[WebHTMLView _resumeNullEventsForAllNetscapePlugins]):
1351         * WebView/WebHTMLViewInternal.h:
1352         * WebView/WebHTMLViewPrivate.h:
1353
1354 2008-06-15  Darin Adler  <darin@apple.com>
1355
1356         - give Frame object functions shorter names: scriptProxy() -> script(),
1357           selectionController() -> selection(), animationController() -> animation()
1358
1359         * Plugins/WebPluginController.mm:
1360         (-[WebPluginController webPlugInContainerSelectionColor]):
1361         * WebView/WebFrame.mm:
1362         (-[WebFrame _attachScriptDebugger]):
1363         (-[WebFrame _hasSelection]):
1364         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
1365         (-[WebFrame _rangeByAlteringCurrentSelection:SelectionController::direction:SelectionController::granularity:]):
1366         (-[WebFrame _convertToNSRange:]):
1367         (-[WebFrame _convertToDOMRange:]):
1368         (-[WebFrame _replaceSelectionWithFragment:selectReplacement:smartReplace:matchStyle:]):
1369         (-[WebFrame _replaceSelectionWithText:selectReplacement:smartReplace:]):
1370         (-[WebFrame _insertParagraphSeparatorInQuotedContent]):
1371         (-[WebFrame _selectedNSRange]):
1372         (-[WebFrame _selectNSRange:]):
1373         (-[WebFrame globalContext]):
1374         * WebView/WebHTMLView.mm:
1375         (-[WebHTMLView _selectedRange]):
1376         (-[WebHTMLView _hasSelection]):
1377         (-[WebHTMLView _hasSelectionOrInsertionPoint]):
1378         (-[WebHTMLView _hasInsertionPoint]):
1379         (-[WebHTMLView _isEditable]):
1380         (-[WebHTMLView _updateFocusedAndActiveState]):
1381         (-[WebHTMLView readSelectionFromPasteboard:]):
1382         (-[WebHTMLView validateUserInterfaceItemWithoutDelegate:]):
1383         (-[WebHTMLView maintainsInactiveSelection]):
1384         (-[WebHTMLView paste:]):
1385         (isTextInput):
1386         (-[WebHTMLView inputContext]):
1387         (-[WebTextCompleteController doCompletion]):
1388         (-[WebHTMLView selectAll]):
1389         (-[WebHTMLView deselectAll]):
1390         (-[WebHTMLView selectedAttributedString]):
1391         * WebView/WebView.mm:
1392         (-[WebView aeDescByEvaluatingJavaScriptFromString:]):
1393         (-[WebView setSelectedDOMRange:affinity:]):
1394         (-[WebView selectedDOMRange]):
1395         (-[WebView selectionAffinity]):
1396
1397 2008-06-15  Darin Adler  <darin@apple.com>
1398
1399         - rename KJS::List to KJS::ArgList
1400
1401         * WebView/WebScriptDebugger.h:
1402
1403 2008-06-15  Darin Adler  <darin@apple.com>
1404
1405         - new names for more JavaScriptCore files
1406
1407         * WebView/WebView.mm:
1408
1409 2008-06-15  Darin Adler  <darin@apple.com>
1410
1411         - new names for a few key JavaScriptCore files
1412
1413         * ForwardingHeaders/kjs/JSFunction.h: Copied from WebKit/mac/ForwardingHeaders/kjs/function.h.
1414         * ForwardingHeaders/kjs/JSObject.h: Copied from WebKit/mac/ForwardingHeaders/kjs/object.h.
1415         * ForwardingHeaders/kjs/JSString.h: Copied from WebKit/mac/ForwardingHeaders/kjs/internal.h.
1416         * ForwardingHeaders/kjs/JSValue.h: Copied from WebKit/mac/ForwardingHeaders/kjs/value.h.
1417         * ForwardingHeaders/kjs/function.h: Removed.
1418         * ForwardingHeaders/kjs/internal.h: Removed.
1419         * ForwardingHeaders/kjs/object.h: Removed.
1420         * ForwardingHeaders/kjs/value.h: Removed.
1421         * WebView/WebScriptDebugDelegate.mm:
1422
1423 2008-06-15  Darin Adler  <darin@apple.com>
1424
1425         Rubber stamped by Sam.
1426
1427         - use JS prefix and simpler names for basic JavaScriptCore types,
1428           to complement JSValue and JSObject
1429
1430         * WebView/WebView.mm:
1431         (aeDescFromJSValue):
1432
1433 2008-06-14  Darin Adler  <darin@apple.com>
1434
1435         Rubber stamped by Sam.
1436
1437         - new names for kjs_binding.h and kjs_proxy.h
1438
1439         * WebView/WebFrame.mm:
1440         * WebView/WebScriptDebugDelegate.mm:
1441         * WebView/WebView.mm:
1442
1443 2008-06-14  Darin Adler  <darin@apple.com>
1444
1445         Rubber stamped by Sam.
1446
1447         - renamed HTMLGenericFormElement to HTMLFormControlElement
1448
1449         * WebView/WebHTMLRepresentation.mm:
1450         (-[WebHTMLRepresentation elementWithName:inForm:]):
1451         (-[WebHTMLRepresentation controlsInForm:]):
1452
1453 2008-06-14  Darin Adler  <darin@apple.com>
1454
1455         Reviewed by Sam.
1456
1457         - more of https://bugs.webkit.org/show_bug.cgi?id=17257
1458           start ref counts at 1 instead of 0 for speed
1459
1460         * WebCoreSupport/WebFrameLoaderClient.mm:
1461         (WebFrameLoaderClient::createDocumentLoader): Use create instead of new.
1462         (WebFrameLoaderClient::createFrame): Remove now-obsolete adoptRef that was balanced by
1463         a ref call inside the Frame constructor. The lifetime rules for Frame are now the
1464         conventional ones without a special case.
1465
1466         * WebView/WebDataSource.mm:
1467         (-[WebDataSource _initWithDocumentLoader:]): Changed argument to be a PassRefPtr, since
1468         this function takes ownership of the DocumentLoader.
1469         (-[WebDataSource initWithRequest:]): Use create instead of new.
1470         * WebView/WebDataSourceInternal.h: Changed _initWithDocumentLoader argument to be a
1471         PassRefPtr and also cleaned up the header a bit.
1472
1473         * WebView/WebDocumentLoaderMac.h:
1474         (WebDocumentLoaderMac::create): Added. Also made the constructor and a couple of virtual
1475         functions private.
1476
1477         * WebView/WebFrame.mm:
1478         (+[WebFrame _createFrameWithPage:frameName:frameView:ownerElement:]): Use create instead
1479         of new.
1480
1481 2008-06-14  Darin Adler  <darin@apple.com>
1482
1483         Reviewed by Sam.
1484
1485         - more work on https://bugs.webkit.org/show_bug.cgi?id=17257
1486           start ref counts at 1 instead of 0 for speed
1487
1488         * WebView/WebFrame.mm:
1489         (-[WebFrame _replaceSelectionWithFragment:selectReplacement:smartReplace:matchStyle:]):
1490         * WebView/WebPDFView.mm:
1491         (-[WebPDFView PDFViewWillClickOnLink:withURL:]):
1492
1493 2008-06-13  Darin Adler  <darin@apple.com>
1494
1495         Reviewed by John Sullivan.
1496
1497         - updated for addition of FormState argument to action policy functions
1498         - added WebActionFormKey
1499
1500         * WebCoreSupport/WebFrameLoaderClient.h:
1501         * WebCoreSupport/WebFrameLoaderClient.mm:
1502         (WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
1503         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
1504         (WebFrameLoaderClient::actionDictionary):
1505         * WebKit.exp:
1506         * WebView/WebPolicyDelegate.mm:
1507         * WebView/WebPolicyDelegatePrivate.h:
1508
1509 2008-06-12  John Sullivan  <sullivan@apple.com>
1510
1511         Reviewed by Dan and Darin
1512
1513         Clear up the confusion about _close (older private method) vs -close (newer public method).
1514
1515         * WebView/WebView.mm:
1516         (-[WebView _isClosed]):
1517         simplified style
1518         (-[WebView _close]):
1519         added a comment about how clients and subclasses should use -close instead
1520         (-[WebView dealloc]):
1521         call -close instead of _close, so subclasses that override the public method will have the intended behavior
1522         (-[WebView close]):
1523         added a comment
1524         (-[WebView _windowWillClose:]):
1525         call -close instead of _close, so subclasses that override the public method will have the intended behavior
1526
1527         * WebView/WebViewPrivate.h:
1528         added a comment about how clients and subclasses should use -close instead
1529
1530 2008-06-07  Darin Adler  <darin@apple.com>
1531
1532         Reviewed by Mitz.
1533
1534         - work on https://bugs.webkit.org/show_bug.cgi?id=17257
1535           start ref counts at 1 instead of 0 for speed
1536
1537         * History/WebHistoryItem.mm:
1538         (-[WebHistoryItem init]):
1539         (-[WebHistoryItem initWithURLString:title:lastVisitedTimeInterval:]):
1540         (-[WebHistoryItem initWithURL:target:parent:title:]):
1541         (-[WebHistoryItem initWithURLString:title:displayTitle:lastVisitedTimeInterval:]):
1542         * WebView/WebView.mm:
1543         (+[WebView _decodeData:]):
1544
1545 2008-06-03  Oliver Hunt  <oliver@apple.com>
1546
1547         Reviewed by Tim.
1548
1549         Bug 12983: Web Inspector break on the debugger keyword
1550         <https://bugs.webkit.org/show_bug.cgi?id=12983>
1551
1552         Add stubs to allow old webkit debugger interface to build.
1553
1554         * WebView/WebScriptDebugger.h:
1555         * WebView/WebScriptDebugger.mm:
1556
1557 2008-06-03  Anders Carlsson  <andersca@apple.com>
1558
1559         Reviewed by Darin.
1560
1561         <rdar://problem/5980961>
1562         
1563         In 64-bit Web Kit, converting between float and double, can cause rounding errors which in turn causes
1564         newBottom to be larger than oldBottom which is illegal.
1565         
1566         * WebView/WebHTMLView.mm:
1567         (-[WebHTMLView adjustPageHeightNew:top:bottom:limit:]):
1568
1569 2008-06-02  Anders Carlsson  <andersca@apple.com>
1570
1571         Reviewed by Mitz.
1572
1573         Speculative fix for <rdar://problem/5661112> 
1574         CrashTracer: [USER] 49 crashes in DashboardClient at com.apple.WebCore: WebCore::RenderPart::setWidget + 62
1575         
1576         Defer loads while calling NPP_New. Some plug-ins start a run-loop inside NPP_New and finished loads could cause
1577         layouts to be triggered.
1578         
1579         * Plugins/WebBaseNetscapePluginView.mm:
1580         (-[WebBaseNetscapePluginView _createPlugin]):
1581
1582 2008-05-29  Justin Garcia  <justin.garcia@apple.com>
1583
1584         Reviewed by Darin.
1585         
1586         <rdar://problem/5949462> REGRESSION: Can't paste screen captures into Mail
1587         
1588         AppKit started putting PNG instead of PICT onto the pasteboard for screen 
1589         captures.  Added support for PNG with kUTTypePNG.  Tiger doesn't support
1590         setting and retrieving pasteboard types with UTIs, but we don't know of any
1591         applications on Tiger that put only PNG on the pasteboard.
1592
1593         * WebView/WebHTMLView.mm:
1594         (-[WebHTMLView _documentFragmentFromPasteboard:inContext:allowPlainText:]):
1595         (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
1596
1597 2008-05-29  Anders Carlsson  <andersca@apple.com>
1598
1599         Reviewed by Brady.
1600
1601         <rdar://problem/5970312> 
1602         icon file specified for stand alone web app causes crash if the icon can't be found
1603         
1604         Handle the case where iconData is null.
1605         
1606         * Misc/WebIconFetcher.mm:
1607         (WebIconFetcherClient::finishedFetchingIcon):
1608
1609 2008-05-29  Anders Carlsson  <andersca@apple.com>
1610
1611         Reviewed by Mitz.
1612
1613         <rdar://problem/5971845>
1614         https://bugs.webkit.org/show_bug.cgi?id=19313
1615         Add version member to NPCocoaEvent
1616
1617         Initialize the version member to 0 for all events.
1618         
1619         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
1620         (initializeEvent):
1621         (WebNetscapePluginEventHandlerCocoa::drawRect):
1622         (WebNetscapePluginEventHandlerCocoa::sendMouseEvent):
1623         (WebNetscapePluginEventHandlerCocoa::flagsChanged):
1624         (WebNetscapePluginEventHandlerCocoa::sendKeyEvent):
1625         (WebNetscapePluginEventHandlerCocoa::windowFocusChanged):
1626         (WebNetscapePluginEventHandlerCocoa::focusChanged):
1627
1628 2008-05-29  Dan Bernstein  <mitz@apple.com>
1629
1630         Reviewed by Jessica Kahn.
1631
1632         - fix <rdar://problem/5965013> Page 2 does not print correctly
1633
1634         When printing, _recursiveDisplayRectIfNeededIgnoringOpacity:... and
1635         _recursiveDisplayAllDirtyWithLockFocus:... can be invoked without
1636         -viewWillDraw being sent first, which could lead to painting without
1637         valid layout. The fix is to ensure up-to-date layout in those methods
1638         when printing.
1639
1640         * WebView/WebHTMLView.mm:
1641         (-[WebHTMLView _recursiveDisplayRectIfNeededIgnoringOpacity:isVisibleRect:rectIsVisibleRectForView:topView:]):
1642         (-[WebHTMLView _recursiveDisplayAllDirtyWithLockFocus:visRect:]):
1643
1644 2008-05-28  Anders Carlsson  <andersca@apple.com>
1645
1646         Reviewed by Jon.
1647
1648         Remove workaround, this is no longer a problem.
1649         
1650         * WebView/WebView.mm:
1651         (-[WebView _removeObjectForIdentifier:]):
1652
1653 2008-05-27  Geoffrey Garen  <ggaren@apple.com>
1654
1655         Reviewed by Tim Hatcher.
1656         
1657         Fixed https://bugs.webkit.org/show_bug.cgi?id=19183
1658         REGRESSION (r33979): Crash in DebuggerCallFrame::functionName when
1659         clicking button in returnEvent-crash.html
1660         
1661         Added implementations for willExecuteProgram and didExecuteProgram, which
1662         take care of making sure we're not hanging on to stale data.
1663
1664 2008-05-27  Timothy Hatcher  <timothy@apple.com>
1665
1666         Fixes a bug where unplugging the monitor from a video card and
1667         moving it to another video card would no longer show OpenGL plugins
1668         until you relaunched Safari.
1669
1670         <rdar://problem/5790983> Add AllowOfflineDisplays pixel format
1671         attribute to OpenGL contexts
1672
1673         Reviewed by Kevin Decker.
1674
1675         * Plugins/WebBaseNetscapePluginView.mm:
1676         (-[WebBaseNetscapePluginView _createWindowedAGLContext]): Added
1677         AGL_ALLOW_OFFLINE_RENDERERS for non-Tiger builds.
1678         (-[WebBaseNetscapePluginView _createWindowlessAGLContext]): Ditto.
1679
1680 2008-05-25  Mark Rowe  <mrowe@apple.com>
1681
1682         Reviewed by Darin Adler.
1683
1684         <rdar://problem/5840884> _recursive_resumeNullEventsForAllNetscapePlugins and _pauseNullEvents not defined
1685
1686         Follow-up for r33052.  _recursive_resumeNullEventsForAllNetscapePlugins and _recursive_pauseNullEventsForAllNetscapePlugins
1687         need to be declared in WebFramePrivate.h rather than WebFrameInternal.h so they can be used from outside of WebKit.
1688
1689         * WebView/WebFrame.mm:
1690         (-[WebFrame _recursive_resumeNullEventsForAllNetscapePlugins]):
1691         (-[WebFrame _recursive_pauseNullEventsForAllNetscapePlugins]):
1692         * WebView/WebFrameInternal.h:
1693         * WebView/WebFramePrivate.h:
1694
1695 2008-05-23  Timothy Hatcher  <timothy@apple.com>
1696
1697         Fix attaching and detaching the Web Inspector. This change removes
1698         the clunky animation that never looked right and was causing issues
1699         where the inspected WebView would get into a no useable state.
1700
1701         <rdar://problem/5958812> Attaching and Detaching the Web Inspector
1702         can cause the inspected WebVIew to be unusable
1703
1704         Reviewed by Adam Roben.
1705
1706         * WebCoreSupport/WebInspectorClient.mm:
1707         (-[WebInspectorWindowController close]): Removes animation code.
1708         Sets the frame directly and does a displayIfNeeded to prevent
1709         showing the Inspector in the page and in the Inspector window.
1710         (-[WebInspectorWindowController showWindow:]): Removes animation code.
1711         Sets the frame directly.
1712         (-[WebInspectorWindowController attach]): Simplified.
1713         (-[WebInspectorWindowController detach]): Ditto.
1714
1715 2008-05-22  Dan Bernstein  <mitz@apple.com>
1716
1717         Reviewed by Darin Adler.
1718
1719         - fix broken documentation of
1720           webView:runBeforeUnloadConfirmPanelWithMessage:initiatedByFrame:
1721
1722         * WebView/WebUIDelegate.h: Fixed method name in HeaderDoc for
1723         -webView:runBeforeUnloadConfirmPanelWithMessage:initiatedByFrame:
1724
1725 2008-05-22  Timothy Hatcher  <timothy@apple.com>
1726
1727         <rdar://problem/5956403> Update the Develop menu to match the new Inspector items
1728
1729         Reviewed by Adam Roben.
1730
1731         * WebCoreSupport/WebInspectorClient.mm:
1732         (-[WebInspectorWindowController showWebInspector:]):
1733         (-[WebInspectorWindowController showErrorConsole:]):
1734         (-[WebInspectorWindowController toggleDebuggingJavaScript:]):
1735         (-[WebInspectorWindowController toggleProfilingJavaScript:]):
1736         (-[WebInspectorWindowController validateUserInterfaceItem:]):
1737         * WebInspector/WebInspector.h:
1738         * WebInspector/WebInspector.mm:
1739         (-[WebInspector showConsole:]):
1740         (-[WebInspector showTimeline:]):
1741         (-[WebInspector isDebuggingJavaScript]):
1742         (-[WebInspector toggleDebuggingJavaScript:]):
1743         (-[WebInspector startDebuggingJavaScript:]):
1744         (-[WebInspector stopDebuggingJavaScript:]):
1745         (-[WebInspector isProfilingJavaScript]):
1746         (-[WebInspector toggleProfilingJavaScript:]):
1747         (-[WebInspector startProfilingJavaScript:]):
1748         (-[WebInspector stopProfilingJavaScript:]):
1749
1750 2008-05-22  Josh Aas  <joshmoz@gmail.com>
1751
1752         Reviewed by Anders.
1753
1754         <rdar://problem/5956429> 
1755         https://bugs.webkit.org/show_bug.cgi?id=19192
1756         remove NPNVpluginEventModel, fix example plugin
1757         
1758         * Plugins/WebBaseNetscapePluginView.mm:
1759         (-[WebBaseNetscapePluginView getVariable:value:]):
1760
1761 2008-05-21  Anders Carlsson  <andersca@apple.com>
1762
1763         Reviewed by Maciej.
1764
1765         Add WebIconFetcher.
1766         
1767         * Misc/WebIconFetcher.h: Added.
1768         * Misc/WebIconFetcher.mm: Added.
1769         (WebIconFetcherClient::WebIconFetcherClient):
1770         (WebIconFetcherClient::finishedFetchingIcon):
1771         (WebIconFetcherClient::setFetcher):
1772         (-[WebIconFetcher init]):
1773         (-[WebIconFetcher dealloc]):
1774         (-[WebIconFetcher finalize]):
1775         (-[WebIconFetcher cancel]):
1776         (-[WebIconFetcher _initWithIconFetcher:client:]):
1777         (+[WebIconFetcher _fetchApplicationIconForFrame:target:selector:]):
1778         * Misc/WebIconFetcherInternal.h: Added.
1779         * WebView/WebFrame.mm:
1780         (-[WebFrame fetchApplicationIcon:selector:]):
1781         * WebView/WebFramePrivate.h:
1782
1783 === End merge of squirrelfish ===
1784
1785 2008-05-21  Geoffrey Garen  <ggaren@apple.com>
1786
1787         Reviewed by Tim Hatcher.
1788         
1789         Updated for API changes from merging with trunk WebCore's new debugger.
1790
1791         * WebView/WebScriptDebugDelegate.mm:
1792         (-[WebScriptCallFrame evaluateWebScript:]): Explicitly check for an
1793         exception return, since the DebuggerCallFrame no longer automatically
1794         substitutes the exception for the return value.
1795
1796         * WebView/WebScriptDebugger.mm: Use the dynamic global object, not the
1797         lexical global object, since the debugger attaches based on dynamic
1798         global object.
1799
1800 2008-05-17  Geoffrey Garen  <ggaren@apple.com>
1801
1802         Reviewed by Oliver Hunt.
1803         
1804         Re-enabled previously disabled debugging functionality.
1805         
1806         There are two major changes from how the WebKit debugger used to work:
1807         
1808         (1) All the interesting bits are implemented down in JavaScriptCore. The
1809         debugger just calls through to KJS::DebuggerCallFrame for everything.
1810         
1811         (2) Instead of copyihng a pointer to an ExecState once, the debugger
1812         copies the DebuggerCallFrame passed to it in each callback. This is
1813         because the VM no longer maintains a fully transparent execution state
1814         to which you can hold a pointer, and the DebuggerCallFrames it vends
1815         are temporaries.
1816         
1817         Also, we NULL out a WebScriptCallFrame's DebuggerCallFrame upon return
1818         from its function. This is safer than the old method, which was to
1819         hold a stale ExecState* and hope for the best.
1820
1821 2008-05-13  Geoffrey Garen  <ggaren@apple.com>
1822
1823         Reviewed by Oliver Hunt.
1824
1825         Updated for API changes in KJS::Debugger.
1826
1827         * WebView/WebFrame.mm:
1828         (-[WebFrame _attachScriptDebugger]): Changed the order of operations to
1829         fix an ASSERT that can happen when re-entering _attachScriptDebugger.
1830
1831 2008-05-13  Geoffrey Garen  <ggaren@apple.com>
1832
1833         Reviewed by Oliver Hunt.
1834         
1835         Updated WebScriptDebugger API to accept a SourceProvider instead
1836         of a WebCore::String, to avoid copying.
1837
1838         (WebScriptDebugger::sourceParsed): Updated this function not to return
1839         a value.
1840
1841 2008-04-30  Geoffrey Garen  <ggaren@apple.com>
1842
1843         Build fix: #ifdef'd out some code that doesn't work anymore.
1844
1845 2008-04-30  Geoffrey Garen  <ggaren@apple.com>
1846
1847         Reviewed by Oliver Hunt.
1848         
1849         #ifdef'd out some debugger code that doesn't work anymore.
1850
1851         * WebView/WebScriptDebugDelegate.mm:
1852         (-[WebScriptCallFrame scopeChain]):
1853
1854 2008-04-21  Geoffrey Garen  <ggaren@apple.com>
1855
1856         Build fix.
1857
1858         * ChangeLog:
1859         * WebView/WebScriptDebugDelegate.mm:
1860         (-[WebScriptCallFrame scopeChain]):
1861
1862 2008-03-30  Geoffrey Garen  <ggaren@apple.com>
1863
1864         Reviewed by Oliver Hunt.
1865         
1866         Build fix.
1867
1868 === Start merge of squirrelfish ===
1869
1870 2008-05-21  Darin Adler  <darin@apple.com>
1871
1872         - fix build
1873
1874         * WebView/WebViewPrivate.h: Remove declaration of closeWithFastTeardown. We can add it back later
1875         if we want, but if we do, we should probably make some refinements like checking _private->closed
1876         and applicationIsTerminating.
1877
1878 2008-05-21  Darin Adler  <darin@apple.com>
1879
1880         Reviewed by Anders and Kevin Decker.
1881
1882         - fix <rdar://problem/5951130> REGRESSION: crash on quit after reopening windows from previous session
1883
1884         * WebView/WebView.mm:
1885         (-[WebViewPrivate dealloc]): Fix assertions to not complain when fast teardown is used.
1886         (-[WebView _closePluginDatabases]): Factored out some common code from both versions of close.
1887         (-[WebView _closeWithFastTeardown]): Added an underscore to this method's name, since it's internal.
1888         Streamlined the code a bit. Added a line of code to set _private->closed (this is the bug fix).
1889         (-[WebView _close]): Changed for new method name and to use _closePluginDatabases.
1890
1891 2008-05-19  Stephanie Lewis  <slewis@apple.com>
1892
1893         Reviewed by Darin.
1894     
1895         more fast teardown performance work
1896
1897         * Misc/WebDownload.m:
1898         (-[WebDownloadInternal downloadDidBegin:]):
1899         (-[WebDownloadInternal downloadDidFinish:]):
1900         (-[WebDownloadInternal download:didFailWithError:]):
1901         * WebCoreSupport/WebChromeClient.h:
1902         * WebCoreSupport/WebChromeClient.mm:
1903         (WebChromeClient::disableSuddenTermination):
1904         (WebChromeClient::enableSuddenTermination):
1905
1906 2008-05-18  Dan Bernstein  <mitz@apple.com>
1907
1908         Reviewed by Sam Weinig.
1909
1910         - fix <rdar://problem/5944596> IDNs are displayed as punycode in the authentication panel
1911
1912         * Panels/WebAuthenticationPanel.m:
1913         (-[WebAuthenticationPanel setUpForChallenge:]):
1914
1915 2008-05-16  Timothy Hatcher  <timothy@apple.com>
1916
1917         Removes WebScriptDebugServer files and related calls. This removes
1918         the hooks that Drosera uses for debugging. Now that the Web Inspector
1919         has a better debugger, we don't need these anymore.
1920
1921         Reviewed by Sam Weinig.
1922
1923         * DefaultDelegates/WebScriptDebugServer.h: Removed.
1924         * DefaultDelegates/WebScriptDebugServer.m: Removed.
1925         * DefaultDelegates/WebScriptDebugServerPrivate.h: Removed.
1926         * WebCoreSupport/WebFrameLoaderClient.mm:
1927         * WebKit.exp:
1928         * WebView/WebScriptDebugDelegate.mm:
1929         * WebView/WebScriptDebugger.mm:
1930         (WebScriptDebugger::sourceParsed):
1931         (WebScriptDebugger::callEvent):
1932         (WebScriptDebugger::atStatement):
1933         (WebScriptDebugger::returnEvent):
1934         (WebScriptDebugger::exception):
1935         * WebView/WebView.mm:
1936         (-[WebView _commonInitializationWithFrameName:groupName:]):
1937         * WebView/WebViewPrivate.h:
1938
1939 2008-05-16  Brady Eidson  <beidson@apple.com>
1940
1941         Reviewed by Anders
1942
1943         <rdar://problem/5942616> - Need to standardize LocalStorage persistence path
1944
1945         Took the opportunity to touch up another pref that needs the same standardization.
1946         That pref is currently not in use on Mac.
1947
1948         * WebView/WebPreferences.m:
1949         (-[WebPreferences _setFTPDirectoryTemplatePath:]):
1950         (-[WebPreferences _localStorageDatabasePath]):
1951         (-[WebPreferences _setLocalStorageDatabasePath:]):
1952         (-[WebPreferences _ftpDirectoryTemplatePath]):
1953
1954 2008-05-16  Chris Fleizach  <cfleizach@apple.com>
1955
1956         Reviewed by Alice Liu
1957
1958         <rdar://problem/5710317> REGRESSION:Selecting ranges of text should be possible using the keyboard (15310)
1959
1960         * WebView/WebFrame.mm:
1961         (-[WebFrame _accessibilityTree]):
1962
1963 2008-05-15  Stephanie Lewis  <slewis@apple.com>
1964         
1965         fix mac build
1966
1967         * WebView/WebView.mm:
1968         (-[WebView closeWithFastTeardown]):
1969
1970 2008-05-15  Stephanie Lewis  <slewis@apple.com>
1971
1972         Reviewed by Anders.
1973
1974         Turn on fast teardown.  I added a preference for using full teardown because 
1975         the LEAKS output will be useless without a full teardown.  
1976
1977         preference for fullteardown
1978         * WebView/WebPreferenceKeysPrivate.h:
1979         * WebView/WebPreferences.m:
1980         (-[WebPreferences setFullDocumentTeardownEnabled:]):
1981         (-[WebPreferences fullDocumentTeardownEnabled]):
1982         * WebView/WebPreferencesPrivate.h:
1983         
1984         on application quit dispatch unload events and destroy plugins then exit
1985         * WebView/WebView.mm:
1986         (-[WebView closeWithFastTeardown]):
1987         (-[WebView _close]):
1988         * WebView/WebViewPrivate.h:
1989
1990 2008-05-15  Stephanie Lewis  <slewis@apple.com>
1991
1992         Reviewed by Anders.
1993
1994         get the pending frame unload count from WebCore
1995
1996         * WebView/WebFrame.mm:
1997         (-[WebFrame _pendingFrameUnloadEventCount]):
1998         * WebView/WebFramePrivate.h:
1999
2000 2008-05-15  John Sullivan  <sullivan@apple.com>
2001
2002         Reviewed by Kevin Decker
2003         
2004         - fixed <rdar://problem/5940275> Inspector highlighting moves to bottom-left corner of 
2005           screen when new tab appears
2006           
2007         The highlight should go away entirely, but this simple patch just makes it not jump away.
2008         The issue with it not going away entirely is harder to fix and covered by <rdar://problem/5322306>
2009
2010         * WebInspector/WebNodeHighlight.m:
2011         (-[WebNodeHighlight _repositionHighlightWindow]):
2012         Bail out if target view isn't in a window
2013
2014 2008-05-15  Stephanie Lewis  <slewis@apple.com>
2015
2016         Reviewed by Anders.
2017
2018         Track views that contain plugin instances so that they can be destroyed at application
2019         quit without walking the entire document tree.
2020
2021         Add/Remove Netscape plugin views from instance list.  Start/stop are when netscape
2022         plugins are created and destroyed
2023         * Plugins/WebBaseNetscapePluginView.mm:
2024         (-[WebBaseNetscapePluginView start]):
2025         (-[WebBaseNetscapePluginView stop]):
2026  
2027         Add/remove WebKit plugin views from instance list
2028         * Plugins/WebPluginController.mm:
2029         (-[WebPluginController addPlugin:]):
2030         (-[WebPluginController destroyPlugin:]):
2031         (-[WebPluginController destroyAllPlugins]):
2032
2033         Add a set of views with plugin instances to the WebPluginDatabase
2034         * Plugins/WebPluginDatabase.h:
2035         * Plugins/WebPluginDatabase.mm:
2036         (-[WebPluginDatabase init]):
2037         (-[WebPluginDatabase dealloc]):
2038         (-[WebPluginDatabase addPluginInstanceView:]):
2039         (-[WebPluginDatabase removePluginInstanceView:]):
2040         (-[WebPluginDatabase removePluginInstanceViewsFor:]):
2041         (-[WebPluginDatabase destroyAllPluginInstanceViews]):
2042         
2043         Handle cases where plugin views are detached before the plugin is destroyed.
2044         * WebCoreSupport/WebFrameLoaderClient.mm:
2045         (WebFrameLoaderClient::detachedFromParent2):
2046         (WebFrameLoaderClient::transitionToCommittedFromCachedPage):
2047         (WebFrameLoaderClient::transitionToCommittedForNewPage):
2048
2049         Add plugin instances to the set in the WebPluginDatabase by way of the WebView
2050         * WebView/WebHTMLView.mm:
2051         (-[WebHTMLView _destroyAllWebPlugins]):
2052         * WebView/WebHTMLViewInternal.h:
2053         * WebView/WebView.mm:
2054         (-[WebView addPluginInstanceView:]):
2055         (-[WebView removePluginInstanceView:]):
2056         (-[WebView removePluginInstanceViewsFor:]):
2057         * WebView/WebViewInternal.h:
2058
2059 2008-05-15  Brady Eidson  <beidson@apple.com>
2060
2061         Reviewed by Tim Hatcher
2062
2063         Until the settings/preferences equation can be reworked, we'll need to manually set the local storage path
2064         before setting the page group of the new page.
2065         
2066         * WebView/WebView.mm:
2067         (-[WebView _commonInitializationWithFrameName:groupName:]): Set the LocalStorage path 
2068           immediately after creating the page so it is in place for initializing the LocalStorageThread
2069
2070 2008-05-15  Timothy Hatcher  <timothy@apple.com>
2071
2072         Fixes the bug where the Web Inspector would flash white while resizing.
2073         This was cause by deferring the window creation.
2074
2075         <rdar://problem/5873549> REGRESSION: Inspector flickers horribly while resizing (17979)
2076
2077         Reviewed by Darin Adler.
2078
2079         * WebCoreSupport/WebInspectorClient.mm:
2080         (-[WebInspectorWindowController window]): Don't defer the window creation.
2081
2082 2008-05-15  Alexey Proskuryakov  <ap@webkit.org>
2083
2084         Tiger build fix.
2085
2086         * Misc/WebNSAttributedStringExtras.mm: Import WebTypesInternal.h for NSUInteger.
2087
2088 2008-05-15  Adele Peterson  <adele@apple.com>
2089
2090         Reviewed and landed by Alexey.
2091
2092         Use TextIterator in +[NSAttributedString _web_attributedStringFromRange:].
2093
2094         * Misc/WebNSAttributedStringExtras.mm:
2095         (+[NSAttributedString _web_attributedStringFromRange:]):
2096
2097 2008-05-14  Eric Seidel  <eric@webkit.org>
2098
2099         Reviewed by Oliver.
2100
2101         Add missing NULL check to match rest of file, this was found by the editing fuzzer.
2102
2103         * WebView/WebResource.mm:
2104         (-[WebResource data]):
2105
2106 2008-05-14  Alexey Proskuryakov  <ap@webkit.org>
2107
2108         Reviewed by Dan Bernstein.
2109
2110         NPP_ValidAttributesForMarkedText should return NSArray*, not NSArray.
2111
2112         * Plugins/nptextinput.h:
2113
2114 2008-05-13  Anders Carlsson  <andersca@apple.com>
2115
2116         Reviewed by Sam.
2117
2118         Don't empty the application cache in _setCacheModel, since it will be called during initialization.
2119         Instead, do it in [WebCache empty].
2120         
2121         * Misc/WebCache.mm:
2122         (+[WebCache empty]):
2123         * WebView/WebView.mm:
2124         (+[WebView _setCacheModel:]):
2125
2126 2008-05-13  chris fleizach  <cfleizach@apple.com>
2127
2128         Reviewed by Beth Dakin
2129
2130         <rdar://problem/4780592> WebKit application has its window announced as HTML content
2131
2132         * WebCoreSupport/WebViewFactory.mm:
2133         (-[WebViewFactory AXWebAreaText]):
2134
2135 2008-05-13  Timothy Hatcher  <timothy@apple.com>
2136
2137         Fixes a crash seen in Xcode where CallUIDelegateReturningBoolean
2138         was referencing a nil WebView under validateUserInterfaceItem.
2139         The validateUserInterfaceItem methods was being called at a time
2140         when the WebHTMLView is being torndown.
2141
2142         <rdar://problem/5806229> A crash occurs at CallUIDelegateReturningBoolean()
2143         while mousing down on menu bar after Xcode News window is opened
2144
2145         Reviewed by Ada Chan.
2146
2147         * WebView/WebHTMLView.mm:
2148         (-[WebHTMLView validateUserInterfaceItem:]): NULL check the WebView and
2149         return NO when it is nil. Adds a comment.
2150         * WebView/WebPDFView.mm:
2151         (-[WebPDFView validateUserInterfaceItem:]): Ditto.
2152
2153 2008-05-13  Mark Rowe  <mrowe@apple.com>
2154
2155         Reviewed by John Sullivan.
2156
2157         <rdar://problem/5926425> HIWebViewCreateWithClass declared as API in HIWebView.h but never exported from WebKit.framework
2158
2159         * Carbon/HIWebView.h: Remove HIWebViewCreateWithClass.
2160         * Carbon/HIWebView.m: Ditto.
2161         (HIWebViewCreate):
2162         (HIWebViewConstructor):
2163
2164 2008-05-12  Dan Bernstein  <mitz@apple.com>
2165
2166         Reviewed by Ada Chan.
2167
2168         - WebKit/mac changes for https://bugs.webkit.org/show_bug.cgi?id=17097
2169           <rdar://problem/5715471> CGFontRefs (and HFONTs on Windows) leak because FontCache grows without bound
2170
2171         Added font cache statistics and a function to purge inactive font data.
2172
2173         * Misc/WebCoreStatistics.h:
2174         * Misc/WebCoreStatistics.mm:
2175         (+[WebCoreStatistics cachedFontDataCount]):
2176         (+[WebCoreStatistics cachedFontDataInactiveCount]):
2177         (+[WebCoreStatistics purgeInactiveFontData]):
2178         (+[WebCoreStatistics glyphPageCount]):
2179
2180 2008-05-12  Mark Rowe  <mrowe@apple.com>
2181
2182         Reviewed by Tim Hatcher.
2183
2184         Decorate some deprecated delegate methods with the availability macros.
2185
2186         The compiler doesn't appear to warn if a delegate implements these methods, but using the availability
2187         macros is good for consistency and documentation.
2188
2189         * WebView/WebFrameLoadDelegate.h:
2190         * WebView/WebUIDelegate.h:
2191
2192 2008-05-12  Mark Rowe  <mrowe@apple.com>
2193
2194         Reviewed by Tim Hatcher.
2195
2196         <rdar://problem/5835604> Deprecate HIWebView
2197
2198         Use of HIWebView is deprecated in favor of embedding a WebView in a HICocoaView.
2199
2200         * Carbon/CarbonUtils.h: Include the availability macro header and decorate the functions appropriately.
2201         * Carbon/HIWebView.h: Ditto.
2202
2203 2008-05-12  Kevin Decker  <kdecker@apple.com>
2204
2205         Reviewed by Anders.
2206
2207         Fixed: <rdar://problem/5840884>_recursive_resumeNullEventsForAllNetscapePlugins and _pauseNullEvents not defined
2208         
2209         Re-added these SPI methods because they are needed by some clients. They were accidentally removed
2210         in changeset <http://trac.webkit.org/changeset/31028>
2211         
2212         * Plugins/WebBaseNetscapePluginView.h: Added stopTimers, restartTimers to the header.
2213         * WebView/WebFrame.mm:
2214         (-[WebFrame _recursive_resumeNullEventsForAllNetscapePlugins]): Re-addd.
2215         (-[WebFrame _recursive_pauseNullEventsForAllNetscapePlugins]): Ditto.
2216         * WebView/WebFrameInternal.h: Ditto.
2217         * WebView/WebHTMLView.mm: Ditto.
2218         (-[WebHTMLView _pauseNullEventsForAllNetscapePlugins]): Ditto.
2219         (-[WebHTMLView _resumeNullEventsForAllNetscapePlugins]): Ditto.
2220         * WebView/WebHTMLViewInternal.h: Ditto.
2221         * WebView/WebHTMLViewPrivate.h: Ditto.
2222
2223 2008-05-12  Anders Carlsson  <andersca@apple.com>
2224
2225         Reviewed by Alexey.
2226
2227         Empty the application cache when changing the cache model.
2228         
2229         * WebView/WebView.mm:
2230         (+[WebView _setCacheModel:]):
2231
2232 2008-05-12  Anders Carlsson  <andersca@apple.com>
2233
2234         Reviewed by Oliver.
2235
2236         <rdar://problem/5774495> Make Unicode text input possible in Netscape-style plug-ins
2237         
2238         * Plugins/WebBaseNetscapePluginView.h:
2239         * Plugins/WebBaseNetscapePluginView.mm:
2240         (-[WebBaseNetscapePluginView start]):
2241         Get the plug-in text input vtable pointer.
2242         
2243         (-[WebBaseNetscapePluginView stop]):
2244         Set the plug-in text input vtable pointer to 0.
2245         
2246         (-[WebBaseNetscapePluginView inputContext]):
2247         Return 0 for Carbon plug-ins since we don't want Cocoa to handle text input for them.
2248         
2249         (-[WebBaseNetscapePluginView hasMarkedText]):        
2250         (-[WebBaseNetscapePluginView insertText:]):
2251         (-[WebBaseNetscapePluginView markedRange]):
2252         (-[WebBaseNetscapePluginView selectedRange]):
2253         (-[WebBaseNetscapePluginView setMarkedText:selectedRange:]):
2254         (-[WebBaseNetscapePluginView unmarkText]):
2255         (-[WebBaseNetscapePluginView validAttributesForMarkedText]):
2256         (-[WebBaseNetscapePluginView attributedSubstringFromRange:]):
2257         (-[WebBaseNetscapePluginView characterIndexForPoint:]):
2258         (-[WebBaseNetscapePluginView doCommandBySelector:]):
2259         (-[WebBaseNetscapePluginView firstRectForCharacterRange:]):
2260         (-[WebBaseNetscapePluginView conversationIdentifier]):
2261         Implement NSTextInput and call into the plug-in text input vtable.
2262         
2263         (browserTextInputFuncs):
2264         New method which returns the browser input vtable.
2265         
2266         (-[WebBaseNetscapePluginView getVariable:value:]):
2267         Support getting the browser input vtable pointer.
2268         
2269         * Plugins/WebNetscapePluginEventHandlerCocoa.h:
2270         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
2271         (WebNetscapePluginEventHandlerCocoa::keyDown):
2272         (WebNetscapePluginEventHandlerCocoa::sendKeyEvent):
2273         If the plug-in returns 0 when a NPCocoaEventKeyDown is passed to NPP_HandleEvent,
2274         it means that the event should be passed on to the input manager.
2275          
2276         * Plugins/npapi.mm:
2277         (NPN_MarkedTextAbandoned):
2278         (NPN_MarkedTextSelectionChanged):
2279         Add implementations of browser input method methods.
2280         
2281         * Plugins/nptextinput.h: Added.
2282         Add file with new text input API.
2283
2284 2008-05-12  Alexey Proskuryakov  <ap@webkit.org>
2285
2286         Roll out recent  threading changes (r32807, r32810, r32819, r32822) to simplify
2287         SquirrelFish merging.
2288
2289         * Misc/WebCoreStatistics.mm:
2290         (+[WebCoreStatistics javaScriptObjectsCount]):
2291         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
2292         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
2293         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
2294         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
2295         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
2296         * WebView/WebScriptDebugDelegate.mm:
2297         (-[WebScriptCallFrame evaluateWebScript:]):
2298
2299 2008-05-07  Anders Carlsson  <andersca@apple.com>
2300
2301         Reviewed by Mitz.
2302
2303         REGRESSION (3.1.1-TOT): Arrow keys are sticky in Google Maps street view
2304         https://bugs.webkit.org/show_bug.cgi?id=18880
2305         <rdar://problem/5909513>
2306
2307         Stop suspending key up events before calling handleEvent.
2308         
2309         * Plugins/WebNetscapePluginEventHandlerCarbon.mm:
2310         (WebNetscapePluginEventHandlerCarbon::sendEvent):
2311
2312 2008-05-06  Stephanie Lewis  <slewis@apple.com>
2313
2314         Reviewed by Andersca.
2315
2316         prepare for plugin fast teardown work - make WebPluginDatabase a objective C++ file.
2317
2318         * Plugins/WebPluginDatabase.m: Removed.
2319         * Plugins/WebPluginDatabase.mm: Copied from WebKit/mac/Plugins/WebPluginDatabase.m.
2320         * Plugins/npapi.m: Removed.
2321         * Plugins/npapi.mm: Copied from WebKit/mac/Plugins/npapi.m.
2322
2323 2008-05-06  Anders Carlsson  <andersca@apple.com>
2324
2325         Reviewed by Darin.
2326
2327         Initialize numArchs to 0.
2328         
2329         * Plugins/WebBasePluginPackage.m:
2330         (-[WebBasePluginPackage isNativeLibraryData:]):
2331
2332 2008-05-06  Anders Carlsson  <andersca@apple.com>
2333
2334         Reviewed by Darin.
2335
2336         Add implementation of NPN_PopUpContextMenu.
2337         
2338         * Plugins/WebBaseNetscapePluginView.mm:
2339         (-[WebBaseNetscapePluginView popUpContextMenu:]):
2340         * Plugins/WebBaseNetscapePluginViewPrivate.h:
2341         * Plugins/WebNetscapePluginPackage.m:
2342         (-[WebNetscapePluginPackage load]):
2343         * Plugins/npapi.m:
2344         (NPN_PopUpContextMenu):
2345
2346 2008-05-06  Anders Carlsson  <andersca@apple.com>
2347
2348         Fix typo (don't read random memory).
2349         
2350         * Plugins/WebBasePluginPackage.m:
2351         (-[WebBasePluginPackage isNativeLibraryData:]):
2352
2353 2008-05-05  Anders Carlsson  <andersca@apple.com>
2354
2355         Reviewed by Darin.
2356
2357         Change the isNativeLibraryData: method to handle universal binaries.
2358         
2359         * Plugins/WebBasePluginPackage.m:
2360         (swapIntsInHeader):
2361         (-[WebBasePluginPackage isNativeLibraryData:]):
2362
2363 2008-05-06  Brady Eidson  <beidson@apple.com>
2364
2365         Reviewed by Darin Adler
2366
2367         Preparation for upcoming work making LocalStorage persistent.
2368
2369         When the application terminates, all LocalStorage areas must be sync'ed out to disk first.
2370
2371         * WebView/WebView.mm:
2372         (+[WebView _applicationWillTerminate]):  Close all LocalStorage areas before quitting.
2373
2374 2008-05-05  Sam Weinig  <sam@webkit.org>
2375
2376         Reviewed by Darin Adler.
2377
2378         Fix for <rdar://problem/5884383>
2379         Escape look-a-like characters from the the entire url.
2380
2381         * Misc/WebNSURLExtras.mm:
2382         (escapeUnsafeCharacters):
2383         (-[NSURL _web_userVisibleString]):
2384
2385 2008-05-05  Justin Garcia  <justin.garcia@apple.com>
2386
2387         Reviewed by Darin.
2388         
2389         <rdar://problem/5865171> REGRESSION: Creating a new quote places caret at beginning of quote instead of the end
2390
2391         * WebView/WebView.mm:
2392         (-[WebView _updateSettingsFromPreferences:]): Disable Range mutation on changes to
2393         the document for Tiger and Leopard Mail.  There is code in Mail that does it, and
2394         the two interfere.
2395
2396 2008-05-05  Sam Weinig  <sam@webkit.org>
2397
2398         Reviewed by Tim Hatcher.
2399
2400         Make the Inspector's localizable strings file match the format used by Dashboard widgets.
2401
2402         * WebCoreSupport/WebInspectorClient.mm:
2403         (WebInspectorClient::localizedStringsURL):
2404
2405 2008-05-05  Anders Carlsson  <andersca@apple.com>
2406
2407         Reviewed by Jess.
2408
2409         Apparently preflighting can cause hangs for some reason. Revert this for now.
2410         
2411         * Plugins/WebNetscapePluginPackage.m:
2412         (-[WebNetscapePluginPackage _initWithPath:]):
2413         * Plugins/WebPluginPackage.m:
2414         (-[WebPluginPackage initWithPath:]):
2415
2416 2008-05-05  Darin Adler  <darin@apple.com>
2417
2418         Reviewed by Mitz.
2419
2420         - https://bugs.webkit.org/show_bug.cgi?id=18789
2421           fix some shouldCloseWithWindow edge cases
2422
2423         * WebView/WebView.mm:
2424         (-[WebView viewWillMoveToWindow:]): Fix bug where we would stop observing the
2425         NSWindowWillCloseNotification if the view was moved out of the window but still
2426         had that window set as the host window. Also make sure this function doesn't do
2427         anything if the WebView is already closed.
2428         (-[WebView setHostWindow:]): Ditto.
2429
2430 2008-05-04  David Kilzer  <ddkilzer@apple.com>
2431
2432         Make parameters match for WebChromeClient::addMessageToConsole()
2433
2434         Reviewed by John.
2435
2436         * WebCoreSupport/WebChromeClient.h:
2437         (WebChromeClient::addMessageToConsole): Renamed sourceID parameter
2438         to sourceURL to match implementation in WebChromeClient.mm.
2439
2440 2008-05-02  Anders Carlsson  <andersca@apple.com>
2441
2442         Reviewed by Mark.
2443
2444         Various Cocoa event model and 64-bit plug-in fixes.
2445         
2446         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
2447         (WebNetscapePluginEventHandlerCocoa::sendMouseEvent):
2448         Set click count.
2449         
2450         (WebNetscapePluginEventHandlerCocoa::flagsChanged):
2451         (WebNetscapePluginEventHandlerCocoa::sendKeyEvent):
2452         Don't try to get the mouse location for keyboard events.
2453         
2454         * Plugins/WebPluginPackage.m:
2455         (-[WebPluginPackage initWithPath:]):
2456         Preflight the bundle so we won't show 32-bit WebKit plug-ins when running as 64-bit.
2457
2458 2008-05-02  Anders Carlsson  <andersca@apple.com>
2459
2460         Reviewed by Sam.
2461
2462         The event union is now named.
2463         
2464         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
2465         (WebNetscapePluginEventHandlerCocoa::drawRect):
2466         (WebNetscapePluginEventHandlerCocoa::sendMouseEvent):
2467         (WebNetscapePluginEventHandlerCocoa::flagsChanged):
2468         (WebNetscapePluginEventHandlerCocoa::sendKeyEvent):
2469         (WebNetscapePluginEventHandlerCocoa::windowFocusChanged):
2470         (WebNetscapePluginEventHandlerCocoa::focusChanged):
2471
2472 2008-05-02  Anders Carlsson  <andersca@apple.com>
2473
2474         Reviewed by Mark.
2475
2476         Make sure that 32-bit only plug-ins aren't shown when running as 64-bit.
2477         
2478         Call preflightAndReturnError on the bundle, which will check if any of the architectures
2479         in the bundle match the current architecture.
2480         
2481         * Plugins/WebNetscapePluginPackage.m:
2482         (-[WebNetscapePluginPackage _initWithPath:]):
2483
2484 2008-05-02  Alexey Proskuryakov  <ap@webkit.org>
2485
2486         Reviewed by Geoffrey Garen.
2487
2488         https://bugs.webkit.org/show_bug.cgi?id=18826
2489         Make JavaScript heap per-thread
2490
2491         * Misc/WebCoreStatistics.mm:
2492         (+[WebCoreStatistics javaScriptObjectsCount]):
2493         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
2494         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
2495         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
2496         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
2497         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
2498         Replaced static Collector calls with calls to a current thread's instance.
2499
2500         * WebView/WebScriptDebugDelegate.mm:
2501         (-[WebScriptCallFrame evaluateWebScript:]):
2502         Pass ExecState to jsString().
2503
2504 2008-05-01  Anders Carlsson  <andersca@apple.com>
2505
2506         Reviewed by Mark.
2507
2508         64-bit NPAPI plugin build fixes.
2509         
2510         * Plugins/WebBaseNetscapePluginView.mm:
2511         (-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
2512         (-[WebBaseNetscapePluginView updateAndSetWindow]):
2513         (-[WebBaseNetscapePluginView start]):
2514         (-[WebBaseNetscapePluginView windowBecameKey:]):
2515         * Plugins/WebNetscapeDeprecatedFunctions.c:
2516         * Plugins/WebNetscapeDeprecatedFunctions.h:
2517         * Plugins/WebNetscapePluginEventHandler.mm:
2518         (WebNetscapePluginEventHandler::create):
2519         * Plugins/WebNetscapePluginEventHandlerCarbon.h:
2520         * Plugins/WebNetscapePluginEventHandlerCarbon.mm:
2521         * Plugins/WebPluginDatabase.m:
2522         (-[WebPluginDatabase pluginForKey:withEnumeratorSelector:]):
2523
2524 2008-05-01  Anders Carlsson  <andersca@apple.com>
2525
2526         Reviewed by Tim.
2527
2528         Remove duplicate npfunctions.h header from WebKit.
2529
2530         * MigrateHeaders.make:
2531         Migrate npfunctions.h
2532         
2533         * Plugins/npfunctions.h: Removed.
2534
2535 2008-05-01  Anders Carlsson  <andersca@apple.com>
2536
2537         Reviewed by John.
2538         
2539         Add null checks for the event handler.
2540         
2541         * Plugins/WebBaseNetscapePluginView.mm:
2542         (-[WebBaseNetscapePluginView stopTimers]):
2543         (-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
2544
2545 2008-05-01  Anders Carlsson  <andersca@apple.com>
2546
2547         Fix 64-bit build.
2548         
2549         * Plugins/WebNetscapePluginEventHandlerCocoa.h:
2550         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
2551         * WebCoreSupport/WebFrameLoaderClient.mm:
2552
2553 2008-05-01  Anders Carlsson  <andersca@apple.com>
2554
2555         Fix build.
2556         
2557         * Plugins/npfunctions.h:
2558
2559 2008-05-01  Anders Carlsson  <andersca@apple.com>
2560
2561         Reviewed by Adam.
2562
2563         Forward mouse move events to the Netscape plug-in view.
2564         
2565         * Plugins/WebBaseNetscapePluginView.h:
2566         * Plugins/WebBaseNetscapePluginView.mm:
2567         (-[WebBaseNetscapePluginView handleMouseMoved:]):
2568         New method that just calls the current event handler.
2569         
2570         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
2571         (WebNetscapePluginEventHandlerCocoa::flagsChanged):
2572         NSFlagsChanged is not a regular keyboard event and some of the NSEvent accessors
2573         don't work on it so don't call them.
2574         
2575         * WebCoreSupport/WebFrameLoaderClient.mm:
2576         (NetscapePluginWidget::NetscapePluginWidget):
2577         New Widget subclass to be used for Netscape plug-ins.
2578         
2579         (NetscapePluginWidget::handleEvent):
2580         Forward NSMouseMoved events to the plug-in.
2581         
2582         (WebFrameLoaderClient::createPlugin):
2583         Wrap the plug-in view in a NetscapePluginWidget.
2584
2585 2008-05-01  Alp Toker  <alp@nuanti.com>
2586
2587         Rubber-stamped by Anders.
2588
2589         GTK+ build fix for changes in r32752. Use int32, not int32_t types in
2590         npapi.h.
2591
2592         Additional fix to use same signedness in npapi.h and Mac for the
2593         interval parameter.
2594
2595         * Plugins/WebBaseNetscapePluginView.h:
2596         * Plugins/WebBaseNetscapePluginView.mm:
2597         (PluginTimer::PluginTimer):
2598         (-[WebBaseNetscapePluginView stopTimers]):
2599         (-[WebBaseNetscapePluginView restartTimers]):
2600         (-[WebBaseNetscapePluginView scheduleTimerWithInterval:repeat:timerFunc:]):
2601         (-[WebBaseNetscapePluginView unscheduleTimer:]):
2602         * Plugins/WebBaseNetscapePluginViewPrivate.h:
2603         * Plugins/npapi.m:
2604         (NPN_ScheduleTimer):
2605         (NPN_UnscheduleTimer):
2606         * Plugins/npfunctions.h:
2607
2608 2008-04-30  Anders Carlsson  <andersca@apple.com>
2609
2610         Reviewed by Adam.
2611
2612         Add new Cocoa event model and the NPN_ScheduleTimer/NPN_UnscheduleTimer methods.
2613         
2614         * Plugins/WebBaseNetscapePluginView.h:
2615         * Plugins/WebBaseNetscapePluginView.mm:
2616         (PluginTimer::PluginTimer):
2617         (PluginTimer::start):
2618         (PluginTimer::fired):
2619         (-[WebBaseNetscapePluginView saveAndSetNewPortStateForUpdate:]):
2620         (-[WebBaseNetscapePluginView stopTimers]):
2621         (-[WebBaseNetscapePluginView restartTimers]):
2622         (-[WebBaseNetscapePluginView scrollWheel:]):
2623         (-[WebBaseNetscapePluginView flagsChanged:]):
2624         (-[WebBaseNetscapePluginView start]):
2625         (-[WebBaseNetscapePluginView eventModel]):
2626         (-[WebBaseNetscapePluginView fini]):
2627         (-[WebBaseNetscapePluginView getVariable:value:]):
2628         (-[WebBaseNetscapePluginView setVariable:value:]):
2629         (-[WebBaseNetscapePluginView scheduleTimerWithInterval:repeat:timerFunc:]):
2630         (-[WebBaseNetscapePluginView unscheduleTimer:]):
2631         * Plugins/WebBaseNetscapePluginViewInternal.h:
2632         * Plugins/WebBaseNetscapePluginViewPrivate.h:
2633         * Plugins/WebNetscapePluginEventHandler.h:
2634         * Plugins/WebNetscapePluginEventHandler.mm:
2635         (WebNetscapePluginEventHandler::create):
2636         * Plugins/WebNetscapePluginEventHandlerCarbon.h:
2637         * Plugins/WebNetscapePluginEventHandlerCarbon.mm:
2638         (WebNetscapePluginEventHandlerCarbon::scrollWheel):
2639         (WebNetscapePluginEventHandlerCarbon::flagsChanged):
2640         (WebNetscapePluginEventHandlerCarbon::platformWindow):
2641         * Plugins/WebNetscapePluginEventHandlerCocoa.h: Added.
2642         (WebNetscapePluginEventHandlerCocoa::startTimers):
2643         (WebNetscapePluginEventHandlerCocoa::stopTimers):
2644         * Plugins/WebNetscapePluginEventHandlerCocoa.mm: Added.
2645         (WebNetscapePluginEventHandlerCocoa::WebNetscapePluginEventHandlerCocoa):
2646         (WebNetscapePluginEventHandlerCocoa::drawRect):
2647         (WebNetscapePluginEventHandlerCocoa::mouseDown):
2648         (WebNetscapePluginEventHandlerCocoa::mouseDragged):
2649         (WebNetscapePluginEventHandlerCocoa::mouseEntered):
2650         (WebNetscapePluginEventHandlerCocoa::mouseExited):
2651         (WebNetscapePluginEventHandlerCocoa::mouseMoved):
2652         (WebNetscapePluginEventHandlerCocoa::mouseUp):
2653         (WebNetscapePluginEventHandlerCocoa::scrollWheel):
2654         (WebNetscapePluginEventHandlerCocoa::sendMouseEvent):
2655         (WebNetscapePluginEventHandlerCocoa::keyDown):
2656         (WebNetscapePluginEventHandlerCocoa::keyUp):
2657         (WebNetscapePluginEventHandlerCocoa::flagsChanged):
2658         (WebNetscapePluginEventHandlerCocoa::sendKeyEvent):
2659         (WebNetscapePluginEventHandlerCocoa::windowFocusChanged):
2660         (WebNetscapePluginEventHandlerCocoa::focusChanged):
2661         (WebNetscapePluginEventHandlerCocoa::platformWindow):
2662         (WebNetscapePluginEventHandlerCocoa::sendEvent):
2663         * Plugins/WebNetscapePluginPackage.m:
2664         (-[WebNetscapePluginPackage load]):
2665         * Plugins/npapi.m:
2666         (NPN_ScheduleTimer):
2667         (NPN_UnscheduleTimer):
2668         * Plugins/npfunctions.h:
2669
2670 2008-04-30  Brady Eidson  <beidson@apple.com>
2671
2672         Fix my WebPreferences revert check-in
2673
2674         * WebView/WebView.mm:
2675         (-[WebView _preferencesChangedNotification:]):
2676
2677 2008-04-30  Brady Eidson  <beidson@apple.com>
2678
2679         Rubberstamped by John Sullivan
2680
2681         Revert the remainder of my original preferences changes from last week.
2682         They caused a massive PLT regression (too many notifications being sent out
2683         or listened to that weren't previously) and it's not in my schedule to refine
2684         the preferences code instead of working on my feature!
2685
2686         * WebView/WebView.mm:
2687         (-[WebView _updateSettingsFromPreferences:]):
2688         (-[WebView _commonInitializationWithFrameName:groupName:]):
2689
2690 2008-04-30  Anders Carlsson  <andersca@apple.com>
2691
2692         Fix the 64-bit build.
2693         
2694         * Plugins/WebNetscapePluginEventHandler.h:
2695         * Plugins/WebNetscapePluginEventHandler.mm:
2696         * Plugins/WebNetscapePluginEventHandlerCarbon.h:
2697         * Plugins/WebNetscapePluginEventHandlerCarbon.mm:
2698
2699 2008-04-29  David D. Kilzer  <ddkilzer@apple.com>
2700
2701         BUILD FIX for Release build.
2702
2703         * Plugins/WebNetscapePluginEventHandlerCarbon.mm:
2704         (WebNetscapePluginEventHandlerCarbon::drawRect): Declare acceptedEvent
2705         separately so the compiler doesn't complain about an unused variable.
2706         (WebNetscapePluginEventHandlerCarbon::TSMEventHandler): Ditto.
2707
2708 2008-04-29  Anders Carlsson  <andersca@apple.com>
2709
2710         Reviewed by Adam.
2711
2712         Refactor the Carbon event handling code out into a separate class in preparation for adding
2713         the Cocoa event handling code.
2714         
2715         * Plugins/WebBaseNetscapePluginView.h:
2716         * Plugins/WebBaseNetscapePluginView.mm:
2717         (-[WebBaseNetscapePluginView sendEvent:isDrawRect:]):
2718         (-[WebBaseNetscapePluginView sendActivateEvent:]):
2719         (-[WebBaseNetscapePluginView sendDrawRectEvent:]):
2720         (-[WebBaseNetscapePluginView stopTimers]):
2721         (-[WebBaseNetscapePluginView restartTimers]):
2722         (-[WebBaseNetscapePluginView setHasFocus:]):
2723         (-[WebBaseNetscapePluginView mouseDown:]):
2724         (-[WebBaseNetscapePluginView mouseUp:]):
2725         (-[WebBaseNetscapePluginView mouseEntered:]):
2726         (-[WebBaseNetscapePluginView mouseExited:]):
2727         (-[WebBaseNetscapePluginView mouseDragged:]):
2728         (-[WebBaseNetscapePluginView keyUp:]):
2729         (-[WebBaseNetscapePluginView keyDown:]):
2730         (-[WebBaseNetscapePluginView cut:]):
2731         (-[WebBaseNetscapePluginView copy:]):
2732         (-[WebBaseNetscapePluginView paste:]):
2733         (-[WebBaseNetscapePluginView selectAll:]):
2734         (-[WebBaseNetscapePluginView start]):
2735         (-[WebBaseNetscapePluginView stop]):
2736         (-[WebBaseNetscapePluginView fini]):
2737         (-[WebBaseNetscapePluginView drawRect:]):
2738         (-[WebBaseNetscapePluginView viewWillMoveToWindow:]):
2739         (-[WebBaseNetscapePluginView viewDidMoveToWindow]):
2740         (-[WebBaseNetscapePluginView windowBecameKey:]):
2741         (-[WebBaseNetscapePluginView windowResignedKey:]):
2742         (-[WebBaseNetscapePluginView windowDidMiniaturize:]):
2743         (-[WebBaseNetscapePluginView windowDidDeminiaturize:]):
2744         (-[WebBaseNetscapePluginView loginWindowDidSwitchFromUser:]):
2745         (-[WebBaseNetscapePluginView loginWindowDidSwitchToUser:]):
2746         (-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
2747         (-[WebBaseNetscapePluginView _viewHasMoved]):
2748         * Plugins/WebBaseNetscapePluginViewInternal.h:
2749         * Plugins/WebNetscapePluginEmbeddedView.h:
2750         * Plugins/WebNetscapePluginEventHandler.h: Added.
2751         (WebNetscapePluginEventHandler::~WebNetscapePluginEventHandler):
2752         (WebNetscapePluginEventHandler::currentEventIsUserGesture):
2753         (WebNetscapePluginEventHandler::WebNetscapePluginEventHandler):
2754         * Plugins/WebNetscapePluginEventHandler.mm: Added.
2755         (WebNetscapePluginEventHandler::create):
2756         * Plugins/WebNetscapePluginEventHandlerCarbon.h: Added.
2757         * Plugins/WebNetscapePluginEventHandlerCarbon.mm: Added.
2758         (WebNetscapePluginEventHandlerCarbon::WebNetscapePluginEventHandlerCarbon):
2759         (getCarbonEvent):
2760         (modifiersForEvent):
2761         (WebNetscapePluginEventHandlerCarbon::sendNullEvent):
2762         (WebNetscapePluginEventHandlerCarbon::drawRect):
2763         (WebNetscapePluginEventHandlerCarbon::mouseDown):
2764         (WebNetscapePluginEventHandlerCarbon::mouseUp):
2765         (WebNetscapePluginEventHandlerCarbon::mouseEntered):
2766         (WebNetscapePluginEventHandlerCarbon::mouseExited):
2767         (WebNetscapePluginEventHandlerCarbon::mouseDragged):
2768         (WebNetscapePluginEventHandlerCarbon::mouseMoved):
2769         (WebNetscapePluginEventHandlerCarbon::keyDown):
2770         (keyMessageForEvent):
2771         (WebNetscapePluginEventHandlerCarbon::keyUp):
2772         (WebNetscapePluginEventHandlerCarbon::focusChanged):
2773         (WebNetscapePluginEventHandlerCarbon::windowFocusChanged):
2774         (WebNetscapePluginEventHandlerCarbon::TSMEventHandler):
2775         (WebNetscapePluginEventHandlerCarbon::installKeyEventHandler):
2776         (WebNetscapePluginEventHandlerCarbon::removeKeyEventHandler):
2777         (WebNetscapePluginEventHandlerCarbon::nullEventTimerFired):
2778         (WebNetscapePluginEventHandlerCarbon::startTimers):
2779         (WebNetscapePluginEventHandlerCarbon::stopTimers):
2780         (WebNetscapePluginEventHandlerCarbon::sendEvent):
2781
2782 2008-04-29  Mark Rowe  <mrowe@apple.com>
2783
2784         Reviewed by David Harrison.
2785
2786         Ensure that WebDynamicScrollBarsView defines WebCoreScrollbarAlwaysOn to keep Mail building.
2787
2788         * WebKit.exp:
2789         * WebView/WebDynamicScrollBarsView.h:
2790         * WebView/WebDynamicScrollBarsView.m:
2791
2792 2008-04-29  Greg Bolsinga  <bolsinga@apple.com>
2793
2794         Reviewed by Darin.
2795
2796         Wrapped Dashboard code with ENABLE(DASHBOARD_SUPPORT)
2797
2798         * WebCoreSupport/WebChromeClient.h:
2799         * WebCoreSupport/WebChromeClient.mm:
2800         * WebView/WebClipView.m:
2801         (-[WebClipView scrollWheel:]):
2802         * WebView/WebHTMLView.mm:
2803         (-[WebHTMLView addMouseMovedObserver]):
2804         (-[WebHTMLView removeMouseMovedObserver]):
2805         (-[WebHTMLView acceptsFirstMouse:]):
2806         * WebView/WebUIDelegatePrivate.h:
2807         * WebView/WebView.mm:
2808         (-[WebViewPrivate init]):
2809         * WebView/WebViewPrivate.h:
2810
2811 2008-04-28  Rob Buis  <buis@kde.org>
2812
2813         Reviewed by Maciej.
2814
2815         Build fix for Tiger.
2816
2817         * WebView/WebView.mm:
2818         (WebKitInitializeApplicationCachePathIfNecessary):
2819
2820 2008-04-28  Adele Peterson  <adele@apple.com>
2821
2822         Reviewed by Dan Bernstein, Tim Hatcher, Anders Carlsson, and Darin Adler.
2823
2824         WebKit part of fix for <rdar://problem/3709505>
2825         Safari should have a way to upload bundles from the file upload control (as zip)
2826
2827         Added UIDelegate methods to let the application handle generating replacement files for uploads.
2828         In this case, Safari will create archived files for bundles so they can be uploaded properly.
2829
2830         * DefaultDelegates/WebDefaultUIDelegate.m:
2831         (-[WebDefaultUIDelegate webView:shouldReplaceUploadFile:usingGeneratedFilename:]):
2832         (-[WebDefaultUIDelegate webView:generateReplacementFile:]):
2833         * WebCoreSupport/WebChromeClient.h:
2834         * WebCoreSupport/WebChromeClient.mm:
2835         (WebChromeClient::shouldReplaceWithGeneratedFileForUpload):
2836         (WebChromeClient::generateReplacementFile):
2837         * WebView/WebUIDelegatePrivate.h:
2838
2839 2008-04-28  Anders Carlsson  <andersca@apple.com>
2840
2841         Reviewed by Sam, Mark, Adele and Darin.
2842
2843         Initialize the application cache path.
2844         
2845         * WebView/WebView.mm:
2846         (WebKitInitializeApplicationCachePathIfNecessary):
2847         (-[WebView _commonInitializationWithFrameName:groupName:]):
2848
2849 2008-04-28  Alice Liu  <alice.liu@apple.com>
2850
2851         Reviewed by Darin.
2852
2853         Fix <rdar://problem/4911289> Add tabindex property to all children 
2854         of HTMLElement (7138)
2855         http://bugs.webkit.org/show_bug.cgi?id=7138
2856
2857         * MigrateHeaders.make:
2858         Removing DOMHTMLLabelElementPrivate.h and DOMHTMLLegendElementPrivate.h
2859         because now that focus() has been moved to DOMHTMLElement.h, these
2860         files are no longer needed.
2861
2862 2008-04-25  Alexey Proskuryakov  <ap@webkit.org>
2863
2864         Reviewed by Darin.
2865
2866         Fix run-webkit-tests --threading
2867         and provisionally fix <https://bugs.webkit.org/show_bug.cgi?id=18661>
2868         Proxy server issue in Sunday's Nightly
2869
2870         * WebView/WebView.mm: (-[WebViewPrivate init]): Initialize threading. Previously, this was
2871         only done from icon database code, which is not robust enough.
2872
2873 2008-04-20 Adam Barth <hk9565@gmail.com>
2874
2875         Reviewed by Adam Roben and Sam Weinig.
2876
2877         Updated WebSecurityOrigin to match new SecurityOrigin API.
2878
2879         Collin Jackson <collinj-webkit@collinjackson.com> also contributed to this patch.
2880
2881         * Storage/WebSecurityOrigin.mm:
2882         (-[WebSecurityOrigin host]):
2883         (-[WebSecurityOrigin domain]):
2884         * Storage/WebSecurityOriginPrivate.h:
2885
2886 2008-04-25  Mark Rowe  <mrowe@apple.com>
2887
2888         Rubber-stamped by Sam Weinig.
2889
2890         Add some content to an empty ICU header file to prevent verification errors.
2891
2892         * icu/unicode/utf_old.h:
2893
2894 2008-04-25  Anders Carlsson  <andersca@apple.com>
2895
2896         Reviewed by Sam.
2897
2898         Add offlineWebApplicationCacheEnabled preference.
2899         
2900         * WebView/WebPreferenceKeysPrivate.h:
2901         * WebView/WebPreferences.m:
2902         (+[WebPreferences initialize]):
2903         (-[WebPreferences offlineWebApplicationCacheEnabled]):
2904         (-[WebPreferences setOfflineWebApplicationCacheEnabled:]):
2905         * WebView/WebPreferencesPrivate.h:
2906         * WebView/WebView.mm:
2907         (-[WebView _updateSettingsFromPreferences:]):
2908
2909 2008-04-24  Mark Rowe  <mrowe@apple.com>
2910
2911         Reviewed by Sam Weinig.
2912
2913         Remove code for calculating the glyph cache size.
2914
2915         * WebCoreSupport/WebSystemInterface.m:
2916         (InitWebCoreSystemInterface): Remove unused symbol.
2917
2918 2008-04-24  Mark Rowe  <mrowe@apple.com>
2919
2920         Reviewed by Sam Weinig.
2921
2922         Add a definition of BUILDING_ON_LEOPARD to complement BUILDING_ON_TIGER.
2923
2924         * WebKitPrefix.h:
2925
2926 2008-04-24  Brady Eidson  <beidson@apple.com>
2927
2928         Reviewed by Darin
2929
2930         Fix layout test regressions from my earlier preferences/settings tweak.
2931
2932         * WebView/WebView.mm:
2933         (-[WebView _commonInitializationWithFrameName:groupName:]): Even if we're not posting
2934           the notification to update the settings, each WebView still needs to register for the
2935           notification - restore that behavior.
2936
2937 2008-04-24  Dan Bernstein  <mitz@apple.com>
2938
2939         Reviewed by Darin Adler.
2940
2941         - preparation for https://bugs.webkit.org/show_bug.cgi?id=3729
2942           <rdar://problem/4036353> REGRESSION: arrow keys move insertion bar backwards in RTL text
2943
2944         * WebView/WebFrame.mm:
2945         (-[WebFrame _caretRectAtNode:offset:affinity:]): Changed to use
2946         VisiblePosition::caretRect() instead of the RenderObject method which
2947         was removed.
2948
2949 2008-04-24  Brady Eidson  <beidson@apple.com>
2950
2951         Reviewed by Darin
2952
2953         Rework the Settings population again.
2954
2955         * WebView/WebView.mm:
2956         (-[WebView _updateSettingsFromPreferences:]): This method is called both from _preferencesChangedNotification
2957           and directly from WebView's common init function.
2958         (-[WebView _preferencesChangedNotification:]):
2959         (-[WebView _commonInitializationWithFrameName:groupName:]): Call _updateSettingsFromPreferences immediately
2960           after creating the new Page
2961
2962 2008-04-24  Darin Adler  <darin@apple.com>
2963
2964         Reviewed by Geoff.
2965
2966         - fix crash in regression test where we'd ask a frame for a user agent string
2967           after the WebView was already closed
2968
2969         * WebCoreSupport/WebFrameLoaderClient.mm:
2970         (WebFrameLoaderClient::userAgent): Assert that the WebView is not nil. Also
2971         added some code to prevent the crash in release builds if this problem happens
2972         again.
2973
2974 2008-04-24  Anders Carlsson  <andersca@apple.com>
2975
2976         Reviewed by Sam.
2977
2978         Change some String arguments to be const references instead.
2979
2980         * WebCoreSupport/WebEditorClient.h:
2981         * WebCoreSupport/WebEditorClient.mm:
2982         (WebEditorClient::shouldInsertText):
2983
2984 2008-04-24  John Sullivan  <sullivan@apple.com>
2985
2986         Mac build fix
2987         
2988         * WebCoreSupport/WebViewFactory.mm:
2989         (-[WebViewFactory AXButtonActionVerb]):
2990         implement this method using the text in WebCoreLocalizedStrings.cpp
2991         (-[WebViewFactory AXRadioButtonActionVerb]):
2992         ditto
2993         (-[WebViewFactory AXTextFieldActionVerb]):
2994         ditto
2995         (-[WebViewFactory AXCheckedCheckBoxActionVerb]):
2996         ditto
2997         (-[WebViewFactory AXUncheckedCheckBoxActionVerb]):
2998         ditto
2999         (-[WebViewFactory AXLinkActionVerb]):
3000         ditto
3001
3002 2008-04-23  Brady Eidson  <beidson@apple.com>
3003
3004         Reviewed by Sam Weinig
3005
3006         In some current work I noticed that when a new Page is created, it is possible that it requires info from its Settings
3007         object before the Settings object is initialized.  It seems quite prudent to post the preferences changed notification,
3008         thereby populating the Settings object, immediately after the Page is created.
3009
3010         * WebView/WebView.mm:
3011         (-[WebView _commonInitializationWithFrameName:groupName:]): Post the notification right after the Page is created
3012
3013 2008-04-24  John Sullivan  <sullivan@apple.com>
3014
3015         Reviewed by Jess
3016         
3017         - fixed <rdar://problem/5886655> JavaScript input panel automatic resizing doesn't work right with HiDPI
3018
3019         * Misc/WebNSControlExtras.m:
3020         (-[NSControl sizeToFitAndAdjustWindowHeight]):
3021         deploy userSpaceScaleFactor when using view distances on the window
3022
3023 2008-04-22  Anders Carlsson  <andersca@apple.com>
3024
3025         Reviewed by Darin.
3026
3027         Add NPN_Construct and NPN_PluginThreadAsyncCall declarations.
3028         
3029         * Plugins/npfunctions.h:
3030
3031 2008-04-20  Matt Lilek  <webkit@mattlilek.com>
3032
3033         Mysteriously reviewed by mitz|away.
3034
3035         Bug 18111: Closing a tab while dragging crashes Safari
3036         https://bugs.webkit.org/show_bug.cgi?id=18111
3037
3038         Null check the page before handling drag events.
3039
3040         * WebView/WebView.mm:
3041         (-[WebView draggingUpdated:]):
3042         (-[WebView draggingExited:]):
3043
3044 2008-04-19  Brady Eidson  <beidson@apple.com>
3045
3046         Reviewed by Tim Hatcher
3047
3048         Add a WebPreference for the path of the local storage persistent store.
3049
3050         * WebView/WebPreferenceKeysPrivate.h:
3051
3052         * WebView/WebPreferences.m:
3053         (-[WebPreferences _localStorageDatabasePath]):
3054         (-[WebPreferences _setLocalStorageDatabasePath:]):
3055         * WebView/WebPreferencesPrivate.h:
3056
3057         * WebView/WebView.mm:
3058         (-[WebView _preferencesChangedNotification:]):
3059
3060 2008-04-18  Brady Eidson  <beidson@apple.com>
3061
3062         Reviewed by Sam Weinig
3063
3064         Don't clear the PageGroup on _close, as the WebCore::Page destructor already does this.
3065         No reason to do the work twice...
3066
3067         * WebView/WebView.mm:
3068         (-[WebView _close]):
3069
3070 2008-04-17  Eric Seidel  <eric@webkit.org>
3071
3072         Reviewed by beth.
3073
3074         Rename Frame::renderer() to contentRenderer() and fix uses.
3075
3076         * Misc/WebCoreStatistics.mm:
3077         * WebView/WebRenderNode.mm:
3078         (-[WebRenderNode initWithWebFrameView:]):
3079
3080 2008-04-17  Jon Honeycutt  <jhoneycutt@apple.com>
3081
3082         Reviewed by mrowe.
3083
3084         * WebView/WebFrame.mm: Remove temporary build fix.
3085
3086 2008-04-17  Mark Rowe  <mrowe@apple.com>
3087
3088         Reviewed by Dan Bernstein.
3089
3090         Fix <rdar://problem/5863552> REGRESSION (r30741): Attachments don't appear in the iChat message window after sending
3091
3092         The order of arguments to -[NSDictionary initWithObjects:andKeys:] had been transposed accidentally during refactoring.
3093
3094         * WebCoreSupport/WebFrameLoaderClient.mm:
3095         (WebFrameLoaderClient::createPlugin): Pass the arguments in the correct order.
3096
3097 2008-04-17  Mark Rowe  <mrowe@apple.com>
3098
3099         Rubber-stamped by Dan Bernstein.
3100
3101         Fix the Mac build.
3102
3103         * WebView/WebFrame.mm: Define HAVE_ACCESSIBILITY before including AccessibilityObject.h and AXObjectCache.h to get things building
3104         for now.  This comes from config.h in WebCore but we don't have an equivalent in WebKit so we'll need to work out the correct place
3105         for this to live going forward.
3106
3107 2008-04-15  Kevin Decker  <kdecker@apple.com>
3108
3109         Reviewed by Anders.
3110
3111         <rdar://problem/5412759> CrashTracer: [USER] 22 crashes in Safari at com.apple.quicktime.webplugin: NPN_SetValue + 15403
3112         
3113         In certain situations, code in WebBasePluginPackage would load a plug-in only for the explicit reason of asking it to create a
3114         preference file, but wouldn't actually unload the bundle. This created problems for the QuickTime WebKit plug-in by unloading
3115         a bundle out from underneath itself.
3116
3117         * Plugins/WebBasePluginPackage.h: Added unload method.
3118         * Plugins/WebBasePluginPackage.m:
3119         (-[WebBasePluginPackage unload]): Added new method. Currently, only Netscape plug-ins support unload.
3120         (-[WebBasePluginPackage pListForPath:createFile:]): Added a call to unload.
3121         * Plugins/WebNetscapePluginPackage.m:
3122         (-[WebNetscapePluginPackage unload]): Added.
3123
3124 2008-04-15  Anders Carlsson  <andersca@apple.com>
3125
3126         Reviewed by Adam.
3127
3128         Add ENABLE_OFFLINE_WEB_APPLICATIONS to FEATURE_DEFINES.
3129
3130         * Configurations/WebKit.xcconfig:
3131
3132 2008-04-15  Brady Eidson  <beidson@apple.com>
3133
3134         Reviewed by John Sullivan
3135
3136         Do a more complete job adding the "WebArchiveDebugMode" pref
3137
3138         * WebView/WebPreferences.m: Add both getter *and* setter
3139         (-[WebPreferences webArchiveDebugModeEnabled]):
3140         (-[WebPreferences setWebArchiveDebugModeEnabled:]):
3141         * WebView/WebPreferencesPrivate.h:
3142
3143         * WebView/WebView.mm:
3144         (-[WebView _preferencesChangedNotification:]): Call the renamed getter
3145
3146 2008-04-14  Brady Eidson  <beidson@apple.com>
3147
3148         Reviewed by Anders
3149
3150         Add a hidden pref to debug WebArchive loading.  With this pref on, when loading a WebArchive,
3151         if the resource isn't in the ArchiveResourceCollection, the loader will not fall back to the 
3152         network and will instead fail the load as "cancelled."
3153
3154         * WebView/WebPreferenceKeysPrivate.h:
3155
3156         * WebView/WebPreferences.m:
3157         (+[WebPreferences initialize]):
3158         (-[WebPreferences _webArchiveDebugModeEnabled]):
3159         * WebView/WebPreferencesPrivate.h:
3160
3161         * WebView/WebView.mm:
3162         (-[WebView _preferencesChangedNotification:]):
3163
3164 2008-04-11  David Hyatt  <hyatt@apple.com>
3165
3166         Rename CachedResource ref/deref methods to addClient/removeClient.
3167
3168         Reviewed by olliej
3169
3170         * WebView/WebHTMLView.mm:
3171         (-[WebHTMLViewPrivate dealloc]):
3172         (-[WebHTMLViewPrivate finalize]):
3173         (-[WebHTMLViewPrivate clear]):
3174         (-[WebHTMLView setPromisedDragTIFFDataSource:WebCore::]):
3175
3176 2008-04-07  Brady Eidson  <beidson@apple.com>
3177
3178         Add "ENABLE_DOM_STORAGE" to keep in sync with the rest of the project
3179
3180         * Configurations/WebKit.xcconfig:
3181
3182 2008-04-04  Adam Roben  <aroben@apple.com>
3183
3184         Use WebCore's ICU headers instead of our own copy
3185
3186         Rubberstamped by Tim Hatcher.
3187
3188         * Configurations/WebKit.xcconfig: Pick up ICU headers from WebCore's
3189         PrivateHeaders.
3190
3191 2008-04-04  Adam Roben  <aroben@apple.com>
3192
3193         Fix <rdar://problem/5804776> Would like to use WebCore's
3194         ForwardingHeaders in WebKit without manually creating copies
3195
3196         Patch by Tim Hatcher, typed by me.
3197
3198         * Configurations/WebKit.xcconfig: Use the copy of ForwardingHeaders in
3199         WebCore's PrivateHeaders instead of our own copy.
3200
3201 2008-04-04  Ada Chan  <adachan@apple.com>
3202
3203         Now we pass width and height directly as integers to format
3204         the window title for a standalone image.
3205
3206         Reviewed by Dan.
3207
3208         * WebCoreSupport/WebViewFactory.mm:
3209         (-[WebViewFactory imageTitleForFilename:width:height:]):
3210
3211 2008-04-03  Nicholas Shanks  <webkit@nickshanks.com>
3212
3213         Updated by Dan Bernstein. Reviewed by Dave Hyatt.
3214
3215         - WebKit part of fixing http://bugs.webkit.org/show_bug.cgi?id=6484
3216           font-weight does not properly support graded weights
3217
3218         * WebView/WebHTMLView.mm:
3219         (-[WebHTMLView _styleFromFontAttributes:]):
3220         (-[WebHTMLView _originalFontB]):
3221         (-[WebHTMLView _addToStyle:fontA:fontB:]):
3222
3223 2008-04-02  Mark Rowe  <mrowe@apple.com>
3224
3225         Reviewed by Oliver Hunt.
3226
3227         Ensure that debug symbols are generated for x86_64 and ppc64 builds.
3228
3229         * Configurations/Base.xcconfig:
3230
3231 2008-03-31  Alice Liu  <alice.liu@apple.com>
3232
3233         Reviewed by Darin.
3234
3235         * WebView/WebFrame.mm:
3236         (-[WebFrame _accessibilityTree]):
3237         The syntax for fetching an object from the AXObjectCache changed slightly
3238
3239 2008-03-31  Brady Eidson  <beidson@apple.com>
3240
3241         Reviewed by Jon Honeycutt
3242         
3243         Move a WebArchive loading check into WebCore
3244
3245         * WebView/WebHTMLRepresentation.mm:
3246         (-[WebHTMLRepresentation receivedData:withDataSource:]): Don't check "isDisplayingWebArchive" as WebCore is now
3247           responsible for checking that state
3248
3249 2008-03-31  Brady Eidson  <beidson@apple.com>
3250
3251         Reviewed by Darin and Mitz's rubber stamp
3252
3253         Remove dataForArchivedSelection(WebCore::Frame*) from the EditorClient - only usage is now directly in WebCore
3254
3255         * WebCoreSupport/WebEditorClient.mm:
3256         * WebCoreSupport/WebEditorClient.h:
3257
3258 2008-03-28  Brady Eidson  <beidson@apple.com>
3259
3260         Rubberstamped by Darin Adler
3261
3262         Remove WebArchiver.h/mm
3263
3264         * WebView/WebArchiver.h: Removed.
3265         * WebView/WebArchiver.mm: Removed.
3266
3267         * DOM/WebDOMOperations.mm:
3268         * WebCoreSupport/WebDragClient.mm:
3269         * WebCoreSupport/WebEditorClient.mm:
3270         * WebView/WebDataSource.mm:
3271         * WebView/WebHTMLView.mm:
3272
3273 2008-03-28  Brady Eidson  <beidson@apple.com>
3274
3275         Reviewed by Darin Adler
3276
3277         Now that WebCore can create archives from a frame selection directly, we don't need it in WebArchiver anymore
3278
3279         * WebCoreSupport/WebEditorClient.mm:
3280         (WebEditorClient::dataForArchivedSelection):
3281
3282         * WebView/WebArchiver.h: Nuke archiveSelectionInFrame, as there are no remaining users
3283         * WebView/WebArchiver.mm: Ditto
3284
3285         * WebView/WebHTMLView.mm:
3286         (-[WebHTMLView _writeSelectionWithPasteboardTypes:toPasteboard:cachedAttributedString:]):
3287
3288 2008-03-28  Brady Eidson  <beidson@apple.com>
3289
3290         Reviewed by Darin Adler
3291
3292         More Kit->Core WebArchive changes.
3293
3294         Create an archive from the current selection in a frame
3295
3296         * WebView/WebArchiver.mm: Remove one more *undeclared* method, the last method will drop off
3297           easily in a followup
3298
3299 2008-03-28  Brady Eidson  <beidson@apple.com>
3300
3301         Reviewed by Sam Weinig
3302
3303         WebArchive saga continues - Can now make archives from ranges in WebCore
3304
3305         * DOM/WebDOMOperations.mm:
3306         (-[DOMRange webArchive]):
3307         (-[DOMRange markupString]):
3308
3309         * WebView/WebArchiver.h: Remove newly obsolete [WebArchiver archiveRange:]
3310         * WebView/WebArchiver.mm:
3311
3312 2008-03-28  Brady Eidson  <beidson@apple.com>
3313
3314         Reviewed by Sam Weinig
3315
3316         More Kit->Core webarchive code movement
3317
3318         * DOM/WebDOMOperations.mm:
3319         (-[DOMNode markupString]): Call createFullMarkup() instead
3320
3321         * WebView/WebFrame.mm: Remove obsolete _markupStringFromNode
3322         * WebView/WebFrameInternal.h: Ditto
3323
3324 2008-03-28  Brady Eidson  <beidson@apple.com>
3325
3326         Reviewed by Sam Weinig
3327
3328         Fold [WebArchiver archiveFrame:] into WebDataSource - the last remaining caller
3329
3330         * WebView/WebArchiver.h:
3331         * WebView/WebArchiver.mm:
3332         * WebView/WebDataSource.mm:
3333         (-[WebDataSource webArchive]):
3334
3335 2008-03-28  Brady Eidson  <beidson@apple.com>
3336
3337         Reviewed by Sam Weinig
3338
3339         Remove unused [WebArchiver archiveNode:], made obsolete in r31400
3340
3341         * WebView/WebArchiver.h:
3342         * WebView/WebArchiver.mm:
3343
3344 2008-03-28  Brady Eidson  <beidson@apple.com>
3345
3346         Reviewed by Darin
3347
3348         "Yet another transitional step" to empty out WebKit-based code for archiving.
3349
3350         With this patch, the key operation of "Creating a WebArchive rooted at a single Node" takes place
3351         entirely within WebCore, and opens the door to saving WebArchives on Windows.
3352
3353         * DOM/WebDOMOperations.mm:
3354         * WebView/WebArchiver.mm:
3355         (+[WebArchiver _archiveWithMarkupString:fromFrame:nodes:]):
3356
3357 2008-03-27  Brady Eidson  <beidson@apple.com>
3358
3359         Reviewed by Adam Roben
3360
3361         Move [WebDataSource mainResource] and [WebDataSource subresources] down into WebCore
3362         as the push to core-ify WebArchives continues.
3363
3364         This patch also introduces a behavior change.  WebCore allows ArchiveResources with null or empty data.  
3365         WebKit has had the inexplicable distinction of allowing empty Data in a WebResource, but not null.  
3366         Since WebResource is API, I decided to leave it be to avoid a behavior change.  But internally created resources 
3367         (as in "while archiving a page") are accepting of null or empty data.
3368
3369         This actually fixes a bug where not all subframes are archived, and resulted in a layout test change. 
3370
3371         * WebView/WebDataSource.mm:
3372         (-[WebDataSource mainResource]): Call DocumentLoader implementation
3373         (-[WebDataSource subresources]): Ditto
3374         * WebView/WebFrame.mm: Remove [WebFrame _getAllResourceDatas:andResponses:] as its only caller is obsolete
3375         * WebView/WebFrameInternal.h:
3376
3377 2008-03-27  Brady Eidson  <beidson@apple.com>
3378
3379         Reviewed by Adam
3380
3381         Change the "init from WebCore resource" version of WebResource to take PassRefPtr
3382         (more efficient)
3383
3384         * WebView/WebResource.mm:
3385         (-[WebResource _initWithCoreResource:]):
3386         * WebView/WebResourceInternal.h:
3387
3388 2008-03-26  Brady Eidson  <beidson@apple.com>
3389
3390         Build fix - accidentally checked in this change which was work in progress
3391
3392         * DOM/WebDOMOperations.mm:
3393
3394 2008-03-26  Brady Eidson  <beidson@apple.com>
3395
3396         Reviewed by Darin
3397
3398         When we create a WebArchive, we walk every node from some starting point, asking each node
3399         along the way "What are your subresource URLs?"
3400
3401         That logic is currently in DOMNode in WebKitMac - this patch moves that ability down into
3402         WebCore::Node
3403
3404         * DOM/WebDOMOperations.mm:
3405         (-[DOMNode _subresourceURLs]): One generic DOMNode method can now handle all DOMNodes by
3406           calling into individual WebCore::Node implementations
3407         * DOM/WebDOMOperationsPrivate.h:
3408
3409 2008-03-26  Brady Eidson  <beidson@apple.com>
3410
3411         Reviewed by Mark Rowe
3412
3413         Part of the continued push to move WebArchive-related code down to WebCore, this
3414         moves [WebDataSource subresourceForURL:] down to DocumentLoader->subresource()
3415
3416         * WebView/WebDataSource.mm:
3417         (-[WebDataSource subresourceForURL:]): Call through to the DocumentLoader 
3418
3419         * WebView/WebFrame.mm: Remove [WebFrame _getData:andResponse:forURL:], as its only use
3420           has now been ported down to WebCore
3421         * WebView/WebFrameInternal.h:
3422
3423 2008-03-26  Mark Rowe  <mrowe@apple.com>
3424
3425         Rubber-stamped by Brady Eidson.
3426
3427         Update FEATURE_DEFINES to be consistent with the other locations in which it is defined.
3428
3429         * Configurations/WebKit.xcconfig:
3430
3431 2008-03-26  Mark Rowe  <mrowe@apple.com>
3432
3433         Reviewed by David Hyatt.
3434
3435         Make the Ahem font antialias correctly on Acid3 on Tiger.
3436
3437         * WebCoreSupport/WebSystemInterface.m:
3438         (InitWebCoreSystemInterface):
3439
3440 2008-03-26  Mark Rowe  <mrowe@apple.com>
3441
3442         Fix the Mac build.
3443
3444         * MigrateHeaders.make: Copy the newly generated header into the right place.
3445
3446 2008-03-25  Brady Eidson  <beidson@apple.com>
3447
3448         Reviewed by Beth Dakin
3449
3450         Remove entirely unused internal method
3451
3452         * WebView/WebArchiver.h:
3453         * WebView/WebArchiver.mm:
3454
3455 2008-03-25  Brady Eidson  <beidson@apple.com>
3456
3457         Reviewed by Adam Roben
3458
3459         <rdar://problem/5819308> - View Source is empty when view webarchives
3460
3461         * WebCore.base.exp:
3462         * loader/DocumentLoader.cpp:
3463         (WebCore::DocumentLoader::setParsedArchiveData):
3464         (WebCore::DocumentLoader::parsedArchiveData):
3465         * loader/DocumentLoader.h:
3466
3467         * loader/FrameLoader.cpp:
3468         (WebCore::FrameLoader::finishedLoadingDocument): Set the archive's MainResource data as the parsedArchiveData
3469           in the DocumentLoader
3470
3471 2008-03-25  Dan Bernstein  <mitz@apple.com>
3472
3473         Reviewed by Darin Adler.
3474
3475         - fix http://bugs.webkit.org/show_bug.cgi?id=17933
3476           Reopen All Windows From Last Session causes crash
3477
3478         * WebView/WebHTMLView.mm:
3479         (-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]): Added null
3480         check.
3481
3482 2008-03-25  Brady Eidson  <beidson@apple.com>
3483
3484         Reviewed by Jon Honeycutt's rubberstamp
3485
3486         Fix a leak with the new WebArchive setup
3487
3488         * WebView/WebArchive.mm:
3489         (-[WebArchivePrivate setCoreArchive:]): Deref() the old WebArchive
3490
3491 2008-03-25  Brady Eidson  <beidson@apple.com>
3492
3493         Reviewed by Darin
3494
3495         Removed the concept of "pending archive resources" and the "archive resources delivery timer"
3496         from WebFrameLoaderClient, as those concepts have been pushed into WebCore
3497
3498         * WebCoreSupport/WebFrameLoaderClient.h:
3499         * WebCoreSupport/WebFrameLoaderClient.mm:
3500         (WebFrameLoaderClient::WebFrameLoaderClient):
3501
3502 2008-03-25  Brady Eidson  <beidson@apple.com>
3503
3504         Reviewed by Darin
3505
3506         Remove newly obsolete FrameLoaderClient methods
3507
3508         * WebCoreSupport/WebFrameLoaderClient.h:
3509         * WebCoreSupport/WebFrameLoaderClient.mm:
3510
3511 2008-03-25  Brady Eidson  <beidson@apple.com>
3512
3513         Release build fix
3514
3515         * WebView/WebArchive.mm:
3516         (-[WebArchive subresources]):
3517         (-[WebArchive subframeArchives]):
3518
3519 2008-03-25  Brady Eidson  <beidson@apple.com>
3520
3521         Reviewed by Darin
3522
3523         <rdar://problem/4516169> - Support WebArchives on Windows
3524         And paves the way for many future WebArchive bug fixes and enhancements
3525
3526         This change moves most of the real workhorse code about WebArchives into WebCore.  It maintains 
3527         1-to-1 relationships between a few objects in WebCore and WebKit.  Such as:
3528          * WebArchive <-> LegacyWebArchive
3529          * WebResource <-> ArchiveResource
3530          * WebUnarchivingState <-> ArchiveResourceCollection
3531  
3532         The other biggest changes involve many FrameLoaderClient methods that existed soley for WebArchives 
3533         and now exist in WebCore
3534
3535         * WebCoreSupport/WebFrameLoaderClient.mm:
3536         (WebFrameLoaderClient::clearUnarchivingState): Emptied - to be removed in a followup patch
3537         (WebFrameLoaderClient::finalSetupForReplace):
3538         (WebFrameLoaderClient::setDefersLoading):
3539         (WebFrameLoaderClient::willUseArchive):
3540         (WebFrameLoaderClient::isArchiveLoadPending):
3541         (WebFrameLoaderClient::cancelPendingArchiveLoad):
3542         (WebFrameLoaderClient::clearArchivedResources):
3543         (WebFrameLoaderClient::createFrame):
3544
3545         * WebView/WebArchive.mm:
3546         (+[WebArchivePrivate initialize]):
3547         (-[WebArchivePrivate init]):
3548         (-[WebArchivePrivate initWithCoreArchive:]):
3549         (-[WebArchivePrivate coreArchive]):
3550         (-[WebArchivePrivate setCoreArchive:]):
3551         (-[WebArchivePrivate dealloc]):
3552         (-[WebArchivePrivate finalize]):
3553         (-[WebArchive init]):
3554         (-[WebArchive initWithMainResource:subresources:subframeArchives:]):
3555         (-[WebArchive initWithData:]):
3556         (-[WebArchive initWithCoder:]):
3557         (-[WebArchive encodeWithCoder:]):
3558         (-[WebArchive mainResource]):
3559         (-[WebArchive subresources]):
3560         (-[WebArchive subframeArchives]):
3561         (-[WebArchive data]):
3562         (-[WebArchive _initWithCoreLegacyWebArchive:WebCore::]):
3563         (-[WebArchive WebCore::]):
3564         * WebView/WebArchiveInternal.h: Added.
3565
3566         * WebView/WebDataSource.mm:
3567         (-[WebDataSourcePrivate dealloc]):
3568         (-[WebDataSource _addSubframeArchives:]):
3569         (-[WebDataSource _documentFragmentWithArchive:]):
3570         (-[WebDataSource subresourceForURL:]):
3571         (-[WebDataSource addSubresource:]):
3572         * WebView/WebDataSourceInternal.h:
3573
3574         * WebView/WebFrame.mm:
3575         (-[WebFrame loadArchive:]):
3576         * WebView/WebFrameInternal.h:
3577
3578         * WebView/WebHTMLRepresentation.mm:
3579         (-[WebHTMLRepresentation finishedLoadingWithDataSource:]):
3580
3581         * WebView/WebResource.mm:
3582         (+[WebResourcePrivate initialize]):
3583         (-[WebResourcePrivate init]):
3584         (-[WebResourcePrivate initWithCoreResource:]):
3585         (-[WebResourcePrivate dealloc]):
3586         (-[WebResourcePrivate finalize]):
3587         (-[WebResource initWithCoder:]):
3588         (-[WebResource encodeWithCoder:]):
3589         (-[WebResource data]):
3590         (-[WebResource URL]):
3591         (-[WebResource MIMEType]):
3592         (-[WebResource textEncodingName]):
3593         (-[WebResource frameName]):
3594         (-[WebResource _initWithCoreResource:WebCore::]):
3595         (-[WebResource WebCore::]):
3596         (-[WebResource _ignoreWhenUnarchiving]):
3597         (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]):
3598         (-[WebResource _fileWrapperRepresentation]):
3599         (-[WebResource _response]):
3600         (-[WebResource _stringValue]):
3601         * WebView/WebResourceInternal.h: Added.
3602         * WebView/WebResourcePrivate.h:
3603
3604         * WebView/WebUnarchivingState.h: Removed.
3605         * WebView/WebUnarchivingState.m: Removed.
3606
3607 2008-03-24  Oliver Hunt  <oliver@apple.com>
3608
3609         Reviewed by Mark Rowe.
3610
3611         Bug 18030: REGRESSION(r31236): Space bar fails to scroll down page
3612         <http://bugs.webkit.org/show_bug.cgi?id=18030>
3613
3614         Rollout keyDown changes from r31236 -- fix for keyDown behaviour is
3615         tracked by Bug 18057: keyDown incorrectly propagates up the frame tree
3616         <http://bugs.webkit.org/show_bug.cgi?id=18057>
3617
3618         * WebView/WebHTMLView.mm:
3619         (-[WebHTMLView keyDown:]):
3620
3621 2008-03-24  Cameron Zwarich  <cwzwarich@uwaterloo.ca>
3622
3623         Reviewed by Maciej, landed by Brady
3624
3625         Bug 3580: iFrames Appear to be Cached
3626         <http://bugs.webkit.org/show_bug.cgi?id=3580>
3627
3628         Bug 15486: REGRESSION: Reload causes WebKit to *forget* fragment URLs
3629         <http://bugs.webkit.org/show_bug.cgi?id=15486>
3630
3631         Bug 15554: Reload causes <object> to use old data
3632         <http://bugs.webkit.org/show_bug.cgi?id=15554>
3633
3634         If a page is reloaded, a child frame's URL can not be taken from a history item.
3635
3636         * WebView/WebFrame.mm:
3637         (-[WebFrame _loadURL:referrer:intoChild:]):
3638
3639 2008-03-24  Darin Adler  <darin@apple.com>
3640
3641         Reviewed by Beth.
3642
3643         - fix <rdar://problem/5817067> -[WebDataSource unreachableURL] invokes KURL's copy constructor
3644
3645         * History/WebHistoryItem.mm:
3646         (-[WebHistoryItem URL]): Use a reference to avoid making a copy.
3647         * WebView/WebDataSource.mm:
3648         (-[WebDataSource _URL]): Ditto.
3649         (-[WebDataSource unreachableURL]): Ditto.
3650         * WebView/WebHTMLView.mm:
3651         (-[WebHTMLView namesOfPromisedFilesDroppedAtDestination:]): Ditto.
3652
3653         * DefaultDelegates/WebDefaultContextMenuDelegate.mm:
3654         * History/WebHistory.mm:
3655         * Misc/WebElementDictionary.mm:
3656         * Misc/WebNSAttributedStringExtras.mm:
3657         Remove unneeded imports of KURL.h.
3658
3659 2008-03-24  Brady Eidson  <beidson@apple.com>
3660
3661         Reviewed by Darin's rubberstamp
3662
3663         Rename this file for upcoming work.
3664
3665         * WebView/WebArchive.m: Removed.
3666         * WebView/WebArchive.mm: Copied from WebKit/mac/WebView/WebArchive.m.
3667
3668 2008-03-24  Alexey Proskuryakov  <ap@webkit.org>
3669
3670         Build fix.
3671
3672         * MigrateHeaders.make: Added DOMSVGAltGlyphElement.h and DOMSVGAltGlyphElementInternal.h.
3673
3674 2008-03-23  Oliver Hunt  <oliver@apple.com>
3675
3676         Reviewed by Maciej.
3677
3678         Bug 17670: Key events may improperly propagate from iframe to parent frame
3679         <http://bugs.webkit.org/show_bug.cgi?id=17670>
3680         Bug 16381: REGRESSION: Shift, command, option, ctrl keys in Gmail Rich Text changes focus
3681         <http://bugs.webkit.org/show_bug.cgi?id=16381>
3682
3683         Prevent the Cocoa event system from propagating key events to the parent WebHTMLView,
3684         as that results in us dispatching the key events for each frame going up the frame
3685         tree.
3686
3687         * WebView/WebHTMLView.mm:
3688         (-[WebHTMLView keyDown:]):
3689         (-[WebHTMLView keyUp:]):
3690         (-[WebHTMLView flagsChanged:]):
3691
3692 2008-03-21  Timothy Hatcher  <timothy@apple.com>
3693
3694         Bug 17980: Regression: Inspector highlighting of webpage not cleared when going to new URL
3695         http://bugs.webkit.org/show_bug.cgi?id=17980
3696
3697         Reviewed by Adam.
3698
3699         The new highlight drawing was not honoring the fade value, so it was
3700         always drawing at full opacity. The animation code didn't match Windows
3701         and the new highlight anyway, so it has been removed. The highlight
3702         how just detaches when it is hidden.
3703
3704         * WebCoreSupport/WebInspectorClient.mm:
3705         (-[WebInspectorWindowController windowShouldClose:]): Call hideHighlight.
3706         (-[WebInspectorWindowController close]): Ditto.
3707         (-[WebInspectorWindowController highlightNode:]): Call attach.
3708         (-[WebInspectorWindowController hideHighlight]): Call detach and release _currentHighlight.
3709         * WebInspector/WebNodeHighlight.h:
3710         * WebInspector/WebNodeHighlight.m:
3711         (-[WebNodeHighlight initWithTargetView:inspectorController:]):
3712         (-[WebNodeHighlight dealloc]): Assert we have no _highlightView.
3713         (-[WebNodeHighlight attach]): Renamed from attachHighlight.
3714         (-[WebNodeHighlight detach]): Renamed from detachHighlight.
3715         (-[WebNodeHighlight setNeedsUpdateInTargetViewRect:]): Renamed from setHolesNeedUpdateInTargetViewRect:.
3716         * WebInspector/WebNodeHighlightView.h:
3717         * WebInspector/WebNodeHighlightView.m:
3718         (-[WebNodeHighlightView setNeedsDisplayInRect:]): Renamed from setHolesNeedUpdateInRect:.
3719
3720 2008-03-20  Mark Rowe  <mrowe@apple.com>
3721
3722         Reviewed by Sam Weinig.
3723
3724         Ensure that the defines in FEATURE_DEFINES are sorted so that they will match the default settings of build-webkit.
3725         This will prevent the world from being rebuilt if you happen to switch between building in Xcode and with build-webkit on the
3726         command-line.
3727
3728         * Configurations/WebKit.xcconfig:
3729
3730 2008-03-20  Adam Roben  <aroben@apple.com>
3731
3732         Make WebNodeHighlightView use InspectorController to do its painting
3733
3734         Reviewed by Tim Hatcher.
3735
3736         * WebCoreSupport/WebInspectorClient.mm:
3737         (-[WebInspectorWindowController highlightNode:]): Pass the
3738         InspectorController to the WebNodeHighlight, and don't call
3739         setHighlightedNode: (which has been removed).
3740         (-[WebInspectorWindowController hideHighlight]): Removed call to
3741         setHighlightedNode:.
3742         * WebInspector/WebNodeHighlight.h:
3743           - Replaced _highlightNode with _inspectorController
3744           - Removed _highlightedNode accessors
3745           - Added -inspectorController method
3746         * WebInspector/WebNodeHighlight.m:
3747         (-[WebNodeHighlight initWithTargetView:inspectorController:]): Now
3748         takes an InspectorController* and stores it in _inspectorController.
3749         (-[WebNodeHighlight dealloc]): Removed code dealing with
3750         _highlightedNode.
3751         (-[WebNodeHighlight inspectorController]): Added.
3752         * WebInspector/WebNodeHighlightView.m: Removed FileInternal category.
3753         (-[WebNodeHighlightView isFlipped]): Added. WebCore expects all
3754         GraphicsContexts to be based on a flipped CGContext, so we have to
3755         specify that this view is flipped.
3756         (-[WebNodeHighlightView drawRect:]): Changed to create a
3757         GraphicsContext and pass it to InspectorController::drawNodeHighlight.
3758
3759 2008-03-18  David Hyatt  <hyatt@apple.com>
3760
3761         Add support for a preference in WebKit that can be used in nightly builds to test full page
3762         zoom.
3763
3764         Reviewed by Antti
3765
3766         * WebView/WebPreferenceKeysPrivate.h:
3767         * WebView/WebView.mm:
3768         (-[WebView setTextSizeMultiplier:]):
3769         (-[WebView canMakeTextSmaller]):
3770         (-[WebView makeTextSmaller:]):
3771         (-[WebView canMakeTextLarger]):
3772         (-[WebView makeTextLarger:]):
3773         (-[WebView canMakeTextStandardSize]):
3774         (-[WebView makeTextStandardSize:]):
3775
3776 2008-03-17  Eric Seidel  <eric@webkit.org>
3777
3778         Reviewed by darin.
3779
3780         Export _NPN_IntFromIdentifier as part of our NPAPI interface
3781
3782         * Plugins/WebNetscapePluginPackage.m:
3783         (-[WebNetscapePluginPackage load]):
3784
3785 2008-03-14  Brady Eidson  <beidson@apple.com>
3786
3787         Reviewed by Brian Dash's rubberstamp
3788
3789         Remove a class declaration for a class that has never existed
3790
3791         * WebView/WebResource.h:
3792
3793 2008-03-14  David D. Kilzer  <ddkilzer@apple.com>
3794
3795         Unify concept of enabling the Mac Java bridge.
3796
3797         Reviewed by Darin and Anders.
3798
3799         * Plugins/WebPluginJava.h: Removed unused file.
3800         * WebCoreSupport/WebFrameLoaderClient.h:
3801         (WebFrameLoaderClient::javaApplet): Added #if ENABLE(MAC_JAVA_BRIDGE) guard.
3802         * WebCoreSupport/WebFrameLoaderClient.mm: Ditto for #import and NSView SPI method.
3803         (WebFrameLoaderClient::javaApplet): Ditto.
3804
3805 2008-03-13  Antti Koivisto  <antti@apple.com>
3806
3807         Reviewed by Darin.
3808
3809         * ForwardingHeaders/wtf/Deque.h: Added.
3810
3811 2008-03-13  Anders Carlsson  <andersca@apple.com>
3812
3813         Reviewed by Adam.
3814
3815         Call originalRequest, not initialRequest.
3816         
3817         * WebView/WebDataSource.mm:
3818         (-[WebDataSource initialRequest]):
3819
3820 2008-03-12  Darin Adler  <darin@apple.com>
3821
3822         Reviewed by John Sullivan.
3823
3824         - cleanup after removing the bridge
3825
3826         * DOM/WebDOMOperations.mm:
3827         (-[DOMDocument URLWithAttributeString:]): Call computeURL directly.
3828
3829         * Misc/WebCoreStatistics.mm:
3830         (-[WebFrame renderTreeAsExternalRepresentation]): Call externalRepresentation directly.
3831
3832         * Plugins/WebBaseNetscapePluginView.mm:
3833         (-[WebBaseNetscapePluginView loadPluginRequest:]): Use core function instead of
3834         _frameLoader method.
3835         (-[WebBaseNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
3836         Ditto.
3837         * Plugins/WebPluginController.mm:
3838         (-[WebPluginController webPlugInContainerLoadRequest:inFrame:]): Ditto.
3839
3840         * WebCoreSupport/WebFrameLoaderClient.mm:
3841         (WebFrameLoaderClient::frameLoaderDestroyed): Added a call to the new _clearCoreFrame
3842         method. Without this we could leave a stale frame pointer around.
3843         (WebFrameLoaderClient::dispatchDidReceiveIcon): Rewrote assertion so it's not the single
3844         caller of the _isMainFrame method.
3845         (WebFrameLoaderClient::transitionToCommittedForNewPage): Use core function instead of
3846         _frameLoader method.
3847         (WebFrameLoaderClient::createFrame): Moved code here from _addChild.
3848
3849         * WebView/WebFrame.mm: Removed lots of methods. Some were moved elsewhere, others
3850         turned out to be unused.
3851         (core): Added overload for DocumentFragment.
3852         (kit): Ditto.
3853         (-[WebFrame _loadURL:referrer:intoChild:]): Get to Frame using _private->coreFrame and
3854         to FrameLoader with _private->coreFrame->loader().
3855         (-[WebFrame _attachScriptDebugger]): Ditto.
3856         (-[WebFrame _clearCoreFrame]): Added.
3857         (-[WebFrame _updateBackground]): More of the same.
3858         (-[WebFrame _unmarkAllBadGrammar]): Ditto.
3859         (-[WebFrame _unmarkAllMisspellings]): Ditto.
3860         (-[WebFrame _hasSelection]): Ditto.
3861         (-[WebFrame _atMostOneFrameHasSelection]): Ditto.
3862         (-[WebFrame _findFrameWithSelection]): Ditto.
3863         (-[WebFrame _dataSource]): Ditto.
3864         (-[WebFrame _addData:]): Streamlined code a bit.
3865         (-[WebFrame _replaceSelectionWithText:selectReplacement:smartReplace:]): Ditto.
3866         (-[WebFrame _receivedData:textEncodingName:]): Ditto.
3867         (-[WebFrame _isDescendantOfFrame:]): Ditto.
3868         (-[WebFrame _bodyBackgroundColor]): Ditto.
3869         (-[WebFrame _isFrameSet]): Ditto.
3870         (-[WebFrame _firstLayoutDone]): Ditto.
3871         (-[WebFrame _loadType]): Ditto.
3872         (-[WebFrame _isDisplayingStandaloneImage]): Ditto.
3873         (-[WebFrame name]): Ditto.
3874         (-[WebFrame DOMDocument]): Ditto.
3875         (-[WebFrame frameElement]): Ditto.
3876         (-[WebFrame provisionalDataSource]): Ditto.
3877         (-[WebFrame dataSource]): Ditto.
3878         (-[WebFrame loadRequest:]): Ditto.
3879         (-[WebFrame _loadData:MIMEType:textEncodingName:baseURL:unreachableURL:]): Ditto.
3880         (-[WebFrame loadArchive:]): Ditto.
3881         (-[WebFrame stopLoading]): Ditto.
3882         (-[WebFrame reload]): Ditto.
3883         (-[WebFrame findFrameNamed:]): Ditto.
3884         (-[WebFrame parentFrame]): Ditto.
3885         (-[WebFrame childFrames]): Ditto.
3886         (-[WebFrame windowObject]): Ditto.
3887         (-[WebFrame globalContext]): Ditto.
3888
3889         * WebView/WebFrameInternal.h: Added overloads of core and kit.
3890         Removed method declarations.
3891
3892         * WebView/WebHTMLRepresentation.mm:
3893         (-[WebHTMLRepresentation documentSource]): Moved code here from WebFrame.
3894         (formElementFromDOMElement): Ditto.
3895         (-[WebHTMLRepresentation elementWithName:inForm:]): Ditto.
3896         (inputElementFromDOMElement): Ditto.
3897         (-[WebHTMLRepresentation elementDoesAutoComplete:]): Ditto.
3898         (-[WebHTMLRepresentation elementIsPassword:]): Ditto.
3899         (-[WebHTMLRepresentation formForElement:]): Ditto.
3900         (-[WebHTMLRepresentation currentForm]): Ditto.
3901         (-[WebHTMLRepresentation controlsInForm:]): Ditto.
3902         (-[WebHTMLRepresentation searchForLabels:beforeElement:]): Ditto.
3903         (-[WebHTMLRepresentation matchLabels:againstElement:]): Ditto.
3904
3905         * WebView/WebHTMLView.mm:
3906         (-[WebHTMLView _frameOrBoundsChanged]): Moved sendScrollEvent code here from WebFrame.
3907         (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]):
3908         Call createFragmentFromText directly instead of via WebFrame.
3909         (-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]):
3910         Moved layout calls here from WebFrame.
3911         (-[WebHTMLView adjustPageHeightNew:top:bottom:limit:]): Ditto.
3912         (-[WebHTMLView _updateFontPanel]): Ditto, but with fontForSelection.
3913         (-[WebHTMLView _canSmartCopyOrDelete]): Ditto, but with selectionGranularity.
3914         (-[WebHTMLView markedRange]): Moved code here from _markedTextNSRange.
3915         (-[WebHTMLView attributedSubstringFromRange:]): Tweaked code a bit.
3916         (-[WebHTMLView searchFor:direction:caseSensitive:wrap:startInSelection:]):
3917         Moved code here from WebFrame.
3918         (-[WebHTMLView elementAtPoint:allowShadowContent:]): Ditto.
3919         (-[WebHTMLView markAllMatchesForText:caseSensitive:limit:]): Ditto.
3920         (-[WebHTMLView setMarkedTextMatchesAreHighlighted:]): Ditto.
3921         (-[WebHTMLView markedTextMatchesAreHighlighted]): Ditto.
3922         (-[WebHTMLView unmarkAllTextMatches]): Ditto.
3923         (-[WebHTMLView rectsForTextMatches]): Ditto.
3924
3925         * WebView/WebHTMLViewInternal.h: Removed unused method declarations.
3926
3927         * WebView/WebPDFView.mm:
3928         (-[WebPDFView PDFViewWillClickOnLink:withURL:]): Use core function instead of
3929         _frameLoader method.
3930
3931         * WebView/WebRenderNode.mm:
3932         (copyRenderNode): Moved code here from WebFrame.
3933         (-[WebRenderNode initWithWebFrameView:]): Ditto.
3934
3935         * WebView/WebResource.mm:
3936         (-[WebResource _stringValue]): Moved code here from WebFrame.
3937
3938         * WebView/WebView.mm:
3939         (-[WebView _close]): Use core function intsead of _frameLoader method.
3940         (-[WebView setCustomTextEncodingName:]): Ditto.
3941         (-[WebView setHostWindow:]): Moved code here from WebFrame.
3942         (aeDescFromJSValue): Moved this here from WebFrame.
3943         (-[WebView aeDescByEvaluatingJavaScriptFromString:]): Moved code here from WebFrame.
3944
3945 2008-03-12  Darin Adler  <darin@apple.com>
3946
3947         Reviewed by Anders.
3948
3949         - http://bugs.webkit.org/show_bug.cgi?id=17640
3950           eliminate WebCoreFrameBridge
3951
3952         Moved all the code from the bridge into WebFrame. This need not be the final
3953         home of these methods -- they can be moved closer to their callers and improved
3954         further -- but it eliminates the bridge without requiring a rewrite of the code.
3955         It's a fairly mechanical process (just adding underscores to method names really).
3956
3957         There's even a chance that some of the methods are unused. Those we can remove
3958         after checking if that's so.
3959
3960         * DOM/WebDOMOperations.mm:
3961         (-[DOMNode markupString]): Use WebFrame rather than bridge.
3962         (-[DOMDocument webFrame]): Changed to use the core and kit functions
3963         instead of using the bridge.
3964         (-[DOMDocument URLWithAttributeString:]): Use WebFrame rather than bridge.
3965         (-[DOMRange markupString]): Ditto.
3966         * DOM/WebDOMOperationsPrivate.h: Removed _bridge methods.
3967
3968         * DefaultDelegates/WebDefaultContextMenuDelegate.mm: Removed unneeded import.
3969         * History/WebHistoryItem.mm: Ditto.
3970
3971         * MigrateHeaders.make: Added DOMDocumentFragmentInternal.h.
3972         * Misc/WebCoreStatistics.mm:
3973         (-[WebFrame renderTreeAsExternalRepresentation]): Use WebFrame rather than bridge.
3974
3975         * Misc/WebElementDictionary.mm: Removed unneeded import.
3976
3977         * Misc/WebKitStatistics.m:
3978         (+[WebKitStatistics bridgeCount]): Removed WebBridgeCount and just return 0.
3979         * Misc/WebKitStatisticsPrivate.h: Ditto.
3980
3981         * Misc/WebNSAttributedStringExtras.mm: Removed unneeded import.
3982         * Misc/WebNSPasteboardExtras.mm: Ditto.
3983
3984         * Plugins/WebBaseNetscapePluginView.mm:
3985         (-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]): Use WebFrame
3986         rather than bridge.
3987
3988         * Plugins/WebNetscapePluginEmbeddedView.mm: Removed unneeded import.
3989         * Plugins/WebNetscapePluginStream.mm: Ditto.
3990
3991         * Plugins/WebPluginContainerCheck.mm:
3992         (-[WebPluginContainerCheck _isForbiddenFileLoad]): Use WebFrame rather than
3993         bridge to get to the WebCore::Frame.
3994
3995         * Plugins/WebPluginController.h: Declare webFrame method and remove bridge method.
3996         * Plugins/WebPluginController.mm:
3997         (-[WebPluginController webPlugInContainerLoadRequest:inFrame:]): Use WebFrame
3998         rather than bridge.
3999
4000         * WebCoreSupport/WebEditorClient.mm:
4001         (selectorForKeyEvent): Tweaked comment.
4002
4003         * WebCoreSupport/WebFrameBridge.h: Removed.
4004         * WebCoreSupport/WebFrameBridge.mm: Removed.
4005
4006         * WebCoreSupport/WebFrameLoaderClient.mm:
4007         (WebFrameLoaderClient::frameLoaderDestroyed): Removed bridge assertion.
4008         (WebFrameLoaderClient::detachedFromParent4): Removed bridge teardown code.
4009         I could remove this function entirely, but it looks like the Qt port is using it.
4010
4011         * WebCoreSupport/WebViewFactory.mm: Removed unneeded import.
4012
4013         * WebView/WebArchiver.mm:
4014         (+[WebArchiver archiveRange:]): Use WebFrame rather than bridge.
4015         (+[WebArchiver archiveNode:]): Ditto.
4016         (+[WebArchiver archiveSelectionInFrame:]): Ditto.
4017
4018         * WebView/WebDataSource.mm:
4019         (-[WebDataSource _replaceSelectionWithArchive:selectReplacement:]): Ditto.
4020         (-[WebDataSource _documentFragmentWithArchive:]): Ditto.
4021         (-[WebDataSource subresources]): Ditto.
4022         (-[WebDataSource subresourceForURL:]): Ditto.
4023
4024         * WebView/WebDataSourceInternal.h: Removed _bridge method.
4025
4026         * WebView/WebFrame.mm:
4027         (-[WebFramePrivate dealloc]): Removed code to release the bridge.
4028         (core): Go directly to the core frame, not via the bridge.
4029         (+[WebFrame _createFrameWithPage:frameName:frameView:ownerElement:]):
4030         Remove the code to deal with the bridge.
4031         (-[WebFrame _initWithWebFrameView:webView:]): Ditto. Also added code to set the
4032         shouldCreateRenderers flag, formerly on the bridge.
4033         (-[WebFrame _updateBackground]): Change to call mehods on self, not bridge.
4034         (aeDescFromJSValue): Moved here from bridge.
4035         (-[WebFrame _domain]): Ditto.
4036         (-[WebFrame _addData:]): Ditto.
4037         (-[WebFrame _stringWithDocumentTypeStringAndMarkupString:]): Ditto.
4038         (-[WebFrame _nodesFromList:]): Ditto.
4039         (-[WebFrame _markupStringFromNode:nodes:]): Ditto.
4040         (-[WebFrame _markupStringFromRange:nodes:]): Ditto.
4041         (-[WebFrame _selectedString]): Ditto.
4042         (-[WebFrame _stringForRange:]): Ditto.
4043         (-[WebFrame _forceLayoutAdjustingViewSize:]): Ditto.
4044         (-[WebFrame _forceLayoutWithMinimumPageWidth:maximumPageWidth:adjustingViewSize:]): Ditto.
4045         (-[WebFrame _sendScrollEvent]): Ditto.
4046         (-[WebFrame _drawRect:]): Ditto.
4047         (-[WebFrame _computePageRectsWithPrintWidthScaleFactor:printHeight:]): Ditto.
4048         (-[WebFrame _adjustPageHeightNew:top:bottom:limit:]): Ditto.
4049         (-[WebFrame _copyRenderNode:copier:]): Ditto.
4050         (-[WebFrame _copyRenderTree:]): Ditto.
4051         (inputElementFromDOMElement): Ditto.
4052         (formElementFromDOMElement): Ditto.
4053         (-[WebFrame _elementWithName:inForm:]): Ditto.
4054         (-[WebFrame _elementDoesAutoComplete:]): Ditto.
4055         (-[WebFrame _elementIsPassword:]): Ditto.
4056         (-[WebFrame _formForElement:]): Ditto.
4057         (-[WebFrame _currentForm]): Ditto.
4058         (-[WebFrame _controlsInForm:]): Ditto.
4059         (-[WebFrame _searchForLabels:beforeElement:]): Ditto.
4060         (-[WebFrame _matchLabels:againstElement:]): Ditto.
4061         (-[WebFrame _URLWithAttributeString:]): Ditto.
4062         (-[WebFrame _searchFor:direction:caseSensitive:wrap:startInSelection:]): Ditto.
4063         (-[WebFrame _markAllMatchesForText:caseSensitive:limit:]): Ditto.
4064         (-[WebFrame _markedTextMatchesAreHighlighted]): Ditto.
4065         (-[WebFrame _setMarkedTextMatchesAreHighlighted:]): Ditto.
4066         (-[WebFrame _unmarkAllTextMatches]): Ditto.
4067         (-[WebFrame _rectsForTextMatches]): Ditto.
4068         (-[WebFrame _stringByEvaluatingJavaScriptFromString:]): Ditto.
4069         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]): Ditto.
4070         (-[WebFrame _aeDescByEvaluatingJavaScriptFromString:]): Ditto.
4071         (-[WebFrame _caretRectAtNode:offset:affinity:]): Ditto.
4072         (-[WebFrame _firstRectForDOMRange:]): Ditto.
4073         (-[WebFrame _scrollDOMRangeToVisible:]): Ditto.
4074         (-[WebFrame _baseURL]): Ditto.
4075         (-[WebFrame _stringWithData:]): Ditto.
4076         (+[WebFrame _stringWithData:textEncodingName:]): Ditto.
4077         (-[WebFrame _needsLayout]): Ditto.
4078         (-[WebFrame _renderTreeAsExternalRepresentation]): Ditto.
4079         (-[WebFrame _accessibilityTree]): Ditto.
4080         (-[WebFrame _setBaseBackgroundColor:]): Ditto.
4081         (-[WebFrame _setDrawsBackground:]): Ditto.
4082         (-[WebFrame _rangeByAlteringCurrentSelection:SelectionController::direction:SelectionController::granularity:]):
4083         Ditto.
4084         (-[WebFrame _selectionGranularity]): Ditto.
4085         (-[WebFrame _convertToNSRange:]): Ditto.
4086         (-[WebFrame _convertToDOMRange:]): Ditto.
4087         (-[WebFrame _convertNSRangeToDOMRange:]): Ditto.
4088         (-[WebFrame _convertDOMRangeToNSRange:]): Ditto.
4089         (-[WebFrame _markDOMRange]): Ditto.
4090         (-[WebFrame _markedTextNSRange]): Ditto.
4091         (-[WebFrame _smartDeleteRangeForProposedRange:]): Ditto.
4092         (-[WebFrame _smartInsertForString:replacingRange:beforeString:afterString:]): Ditto.
4093         (-[WebFrame _documentFragmentWithMarkupString:baseURLString:]): Ditto.
4094         (-[WebFrame _documentFragmentWithText:inContext:]): Ditto.
4095         (-[WebFrame _documentFragmentWithNodesAsParagraphs:]): Ditto.
4096         (-[WebFrame _replaceSelectionWithFragment:selectReplacement:smartReplace:matchStyle:]): Ditto.
4097         (-[WebFrame _replaceSelectionWithNode:selectReplacement:smartReplace:matchStyle:]): Ditto.
4098         (-[WebFrame _replaceSelectionWithMarkupString:baseURLString:selectReplacement:smartReplace:]): Ditto.
4099         (-[WebFrame _replaceSelectionWithText:selectReplacement:smartReplace:]): Ditto.
4100         (-[WebFrame _insertParagraphSeparatorInQuotedContent]): Ditto.
4101         (-[WebFrame _visiblePositionForPoint:]): Ditto.
4102         (-[WebFrame _characterRangeAtPoint:]): Ditto.
4103         (-[WebFrame _typingStyle]): Ditto.
4104         (-[WebFrame _setTypingStyle:withUndoAction:]): Ditto.
4105         (-[WebFrame _fontForSelection:]): Ditto.
4106         (-[WebFrame _dragSourceMovedTo:]): Ditto.
4107         (-[WebFrame _dragSourceEndedAt:operation:]): Ditto.
4108         (-[WebFrame _getData:andResponse:forURL:]): Ditto.
4109         (-[WebFrame _getAllResourceDatas:andResponses:]): Ditto.
4110         (-[WebFrame _canProvideDocumentSource]): Ditto.
4111         (-[WebFrame _canSaveAsWebArchive]): Ditto.
4112         (-[WebFrame _receivedData:textEncodingName:]): Ditto.
4113         (-[WebFrame _setShouldCreateRenderers:]): Put the code from the bridge in this preexisting
4114         function. Couldn't just keep the bridge method because this was already here with the same name.
4115         (-[WebFrame _selectedNSRange]): Ditto.
4116         (-[WebFrame _selectNSRange:]): Ditto.
4117         (-[WebFrame dealloc]): Remove bridge-related code.
4118         (-[WebFrame finalize]): Ditto.
4119
4120         * WebView/WebFrameInternal.h: Added all the method declarations from the bridge.
4121         Removed the bridge parameter from the init method. Removed the #if blocks that
4122         tried to make this header work in non-C++ ObjC files -- they were broken and unused.
4123         Removed the _bridge method.
4124
4125         * WebView/WebFrameView.mm: Removed the _bridge method.
4126
4127         * WebView/WebHTMLRepresentation.mm:
4128         (-[WebHTMLRepresentation setDataSource:]): Removed the code to set up the bridge
4129         field.
4130         (-[WebHTMLRepresentation receivedData:withDataSource:]): Use WebFrame instead of bridge.
4131         (-[WebHTMLRepresentation finishedLoadingWithDataSource:]): Ditto.
4132         (-[WebHTMLRepresentation canProvideDocumentSource]): Ditto.
4133         (-[WebHTMLRepresentation canSaveAsWebArchive]): Ditto.
4134         (-[WebHTMLRepresentation documentSource]): Ditto.
4135         (-[WebHTMLRepresentation DOMDocument]): Ditto.
4136         (-[WebHTMLRepresentation elementWithName:inForm:]): Ditto.
4137         (-[WebHTMLRepresentation elementDoesAutoComplete:]): Ditto.
4138         (-[WebHTMLRepresentation elementIsPassword:]): Ditto.
4139         (-[WebHTMLRepresentation formForElement:]): Ditto.
4140         (-[WebHTMLRepresentation currentForm]): Ditto.
4141         (-[WebHTMLRepresentation controlsInForm:]): Ditto.
4142         (-[WebHTMLRepresentation searchForLabels:beforeElement:]): Ditto.
4143         (-[WebHTMLRepresentation matchLabels:againstElement:]): Ditto.
4144
4145         * WebView/WebHTMLRepresentationPrivate.h: Removed the _bridge method.
4146
4147         * WebView/WebHTMLView.mm:
4148         (-[WebHTMLView _documentFragmentWithPaths:]): Use WebFrame instead of bridge.
4149         (-[WebHTMLView _pasteWithPasteboard:allowPlainText:]): Ditto.
4150         (-[WebHTMLView _pasteAsPlainTextWithPasteboard:]): Ditto.
4151         (-[WebHTMLView _updateTextSizeMultiplier]): Ditto.
4152         (-[WebHTMLView _frameOrBoundsChanged]): Ditto.
4153         (-[WebHTMLView _smartInsertForString:replacingRange:beforeString:afterString:]): Ditto.
4154         (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]): Ditto.
4155         (-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]): Ditto.
4156         (-[WebHTMLView drawSingleRect:]): Ditto.
4157         (-[WebHTMLView draggedImage:movedTo:]): Ditto.
4158         (-[WebHTMLView draggedImage:endedAt:operation:]): Ditto.
4159         (-[WebHTMLView adjustPageHeightNew:top:bottom:limit:]): Ditto.
4160         (-[WebHTMLView knowsPageRange:]): Ditto.
4161         (-[WebHTMLView accessibilityAttributeValue:]): Ditto.
4162         (-[WebHTMLView accessibilityFocusedUIElement]): Ditto.
4163         (-[WebHTMLView accessibilityHitTest:]): Ditto.
4164         (-[WebHTMLView _accessibilityParentForSubview:]): Ditto.
4165         (-[WebHTMLView changeDocumentBackgroundColor:]): Ditto.
4166         (-[WebHTMLView _changeWordCaseWithSelector:]): Ditto.
4167         (-[WebHTMLView _changeSpellingToWord:]): Ditto.
4168         (-[WebHTMLView startSpeaking:]): Ditto.
4169         (-[WebHTMLView _updateFontPanel]): Ditto.
4170         (-[WebHTMLView _canSmartCopyOrDelete]): Ditto.
4171         (-[WebHTMLView _layoutIfNeeded]): Ditto.
4172         (-[WebHTMLView characterIndexForPoint:]): Ditto.
4173         (-[WebHTMLView firstRectForCharacterRange:]): Ditto.
4174         (-[WebHTMLView selectedRange]): Ditto.
4175         (-[WebHTMLView markedRange]): Ditto.
4176         (-[WebHTMLView attributedSubstringFromRange:]): Ditto.
4177         (-[WebHTMLView setMarkedText:selectedRange:]): Ditto.
4178         (-[WebHTMLView insertText:]): Ditto.
4179         (-[WebTextCompleteController _insertMatch:]): Ditto.
4180         (-[WebTextCompleteController doCompletion]): Ditto.
4181         (-[WebTextCompleteController endRevertingChange:moveLeft:]): Ditto.
4182         (-[WebHTMLView string]): Ditto.
4183         (-[WebHTMLView selectedString]): Ditto.
4184         (-[WebHTMLView searchFor:direction:caseSensitive:wrap:startInSelection:]): Ditto.
4185         (-[WebHTMLView markAllMatchesForText:caseSensitive:limit:]): Ditto.
4186         (-[WebHTMLView setMarkedTextMatchesAreHighlighted:]): Ditto.
4187         (-[WebHTMLView markedTextMatchesAreHighlighted]): Ditto.
4188         (-[WebHTMLView unmarkAllTextMatches]): Ditto.
4189         (-[WebHTMLView rectsForTextMatches]): Ditto.
4190         * WebView/WebRenderNode.mm:
4191         (-[WebRenderNode initWithWebFrameView:]): Ditto.
4192         * WebView/WebResource.mm:
4193         (-[WebResource _stringValue]): Ditto.
4194
4195         * WebView/WebScriptDebugDelegate.mm: Removed unneeded include.
4196
4197         * WebView/WebView.mm:
4198         (-[WebView _dashboardRegions]): Use WebFrame instead of bridge.
4199         (-[WebView setProhibitsMainFrameScrolling:]): Ditto.
4200         (-[WebView _setInViewSourceMode:]): Ditto.
4201         (-[WebView _inViewSourceMode]): Ditto.
4202         (-[WebView _executeCoreCommandByName:value:]): Ditto.
4203         (-[WebView stringByEvaluatingJavaScriptFromString:]): Ditto.
4204         (-[WebView aeDescByEvaluatingJavaScriptFromString:]): Ditto.
4205         (-[WebView scrollDOMRangeToVisible:]): Ditto.
4206         (-[WebView setSelectedDOMRange:affinity:]): Ditto.
4207         (-[WebView setEditable:]): Ditto.
4208         (-[WebView setTypingStyle:]): Dit