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