2007-01-25 Mark Rowe <mrowe@apple.com>
[WebKit-https.git] / WebKit / ChangeLog
1 2007-01-25  Mark Rowe  <mrowe@apple.com>
2
3         Reviewed by Maciej.
4
5         * Info.plist: Update copyright string.
6
7 2007-01-24  Darin Adler  <darin@apple.com>
8
9         Reviewed by Mark Rowe.
10
11         * WebKit.xcodeproj/project.pbxproj: Changed to /usr/sbin/sysctl
12         so we don't rely on people's paths.
13
14 2007-01-24  Darin Adler  <darin@apple.com>
15
16         Reviewed by Adele.
17
18         - fix small regression and GC problems noticed by code inspection
19
20         * WebView/WebHTMLView.mm: Move global declarations to the start of the file.
21         (+[WebHTMLView _excludedElementsForAttributedStringConversion]):
22         Add a CFRetain here for GC compatibility.
23         (+[WebHTMLView _insertablePasteboardTypes]): Ditto.
24         (-[WebHTMLView performKeyEquivalent:]): Fix small logic mistake that prevents
25         super from being called if EventHandler::keyEvent returns false. Reformatted
26         the code a bit and added a local variable for the frame.
27         (-[WebHTMLView _interceptEditingKeyEvent:]): Added some comments.
28         (-[WebHTMLView validAttributesForMarkedText]): Add a CFRetain here for
29         GC compatibility.
30
31 2007-01-23  Adele Peterson  <adele@apple.com>
32
33         Reviewed by Adam.
34
35         Fixed 2 layout tests that I broke with my last checkin.
36
37         * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::handleKeyPress): Use the selected frame to get the WebHTMLView.
38         * WebView/WebHTMLView.mm:
39         (-[WebHTMLView performKeyEquivalent:]): Added global to keep track of NSEvent used here.
40         (-[WebHTMLView _interceptEditingKeyEvent:]): Check NSEvent against the event used in performKeyEquivalent.
41           We don't want to intercept these events.
42
43 2007-01-23  Adele Peterson  <adele@apple.com>
44
45         Reviewed by Darin.
46
47         WebKit part of fix for <rdar://problem/4946753>REGRESSION: Inserting tabs is broken in Mail
48         
49         In addition to this fix, I also reorganized some event handling code for keyPress events to
50         prepare for another fix.
51
52         * WebCoreSupport/WebEditorClient.h: Added handleKeyPress method.
53         * WebCoreSupport/WebEditorClient.mm:
54         (WebEditorClient::handleKeyPress): Added.  Code moved from WebHTMLView keyDown method.
55          This is called from the defaultEventHandler so that in the future, we can make the right 
56          decision about which selection the keyPress should apply to.
57         * WebView/WebHTMLView.mm:
58         (-[WebHTMLView keyDown:]): Moved _interceptEditingKeyEvent call to handleKeyPress.
59         (-[WebHTMLView _interceptEditingKeyEvent:]): Prevents intercepting keys for cmd-modified events. Removed tabCycling checks
60          since this is now handled in WebCore.
61         * WebView/WebHTMLViewInternal.h: Made _interceptEditingKeyEvent SPI.
62         * WebView/WebView.mm: Use new tabKeyCyclesThroughElements methods on the page.
63         (-[WebViewPrivate init]): ditto.
64         (-[WebView setTabKeyCyclesThroughElements:]): ditto.
65         (-[WebView tabKeyCyclesThroughElements]): ditto.
66         (-[WebView setEditable:]): ditto
67
68 2007-01-23  Lars Knoll <lars@trolltech.com>
69
70         Reviewed by Maciej
71
72         Make the last remaining pieces of the FrameLoader platform 
73         independent. Move most of the code over to WebFrameLoaderClient.
74         Some smaller cleanups in the WebFrameBridge, and moved some
75         platform independent functionality over to the shared code
76         in WebCore.
77
78         * Webcoresupport/WebFrameBridge.mm:
79         (-[WebFrameBridge finishInitializingWithPage:frameName:frameView:ownerElement:]):
80         (-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
81         (-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
82         * WebCoreSupport/WebFrameLoaderClient.h:
83         * WebCoreSupport/WebFrameLoaderClient.mm:
84         (WebFrameLoaderClient::setTitle):
85         (WebFrameLoaderClient::createFrame):
86         (WebFrameLoaderClient::objectContentType):
87         (nsArray):
88         (WebFrameLoaderClient::createPlugin):
89         (WebFrameLoaderClient::redirectDataToPlugin):
90         (nsMutableArray):
91         (WebFrameLoaderClient::createJavaAppletWidget):
92         (WebFrameLoaderClient::overrideMediaType):
93         (WebFrameLoaderClient::windowObjectCleared):
94
95 2007-01-23  Oliver Hunt  <oliver@apple.com>
96
97         Reviewed by Adam.
98
99         Drop logic bindings for WebKit
100
101         * WebCoreSupport/WebDragClient.h: Added.
102         * WebCoreSupport/WebDragClient.mm: Added.
103         (WebDragClient::WebDragClient):
104         (WebDragClient::actionMaskForDrag):
105         (WebDragClient::willPerformDragDestinationAction):
106           Standard client impl
107         * WebCoreSupport/WebFrameBridge.mm:
108         (-[WebFrameBridge startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
109           Updated to use DragController to track drag state
110     
111         * WebCoreSupport/WebPasteboardHelper.h: Added.
112         (WebPasteboardHelper::WebPasteboardHelper):
113           A *temporary* Helper class to access NSPasteboard access and 
114           manipulation functions present in WebKit
115         * WebCoreSupport/WebPasteboardHelper.mm: Added.
116         (WebPasteboardHelper::urlFromPasteboard):
117         (WebPasteboardHelper::plainTextFromPasteboard):
118         (WebPasteboardHelper::fragmentFromPasteboard):
119         (WebPasteboardHelper::insertablePasteboardTypes):
120           See header comment
121         * WebKit.xcodeproj/project.pbxproj:
122         * WebView/WebDocumentInternal.h:
123           Remove unnecessary protocol
124         * WebView/WebFrameView.mm:
125         (-[WebFrameView _setDocumentView:]):
126           Updating to use DragController to track drag state
127         * WebView/WebHTMLView.mm:
128         (-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
129           ditto
130         (-[WebHTMLView dragImage:at:offset:event:pasteboard:source:slideBack:]):
131           ditto
132         (-[WebHTMLView draggingSourceOperationMaskForLocal:]):
133           ditto
134         (-[WebHTMLView draggedImage:endedAt:operation:]):
135           ditto          
136         (-[WebHTMLView _documentFragmentForPasteboard:]):
137           Helper method to generate DocumentFragment from NSPasteboard without regressing 
138         (-[WebHTMLView _canProcessDragWithDraggingInfo:]):
139           Updating to use DragController to track drag state
140         (-[WebHTMLView _isMoveDrag:]):
141         (-[WebHTMLView _isNSColorDrag:]):
142         * WebView/WebHTMLViewInternal.h:
143           Removing unnecessary fields and methods
144         * WebView/WebView.mm:
145         (-[WebViewPrivate dealloc]):
146           Remove obsolete ASSERT
147         (-[WebView _setInitiatedDrag:]):
148           Now passes directly through to DragController
149         (-[WebView _commonInitializationWithFrameName:groupName:]):
150         (-[WebView _loadingDragOperationForDraggingInfo:]):
151           Removed
152         (-[WebView draggingEntered:]):
153           Updated to use DragController
154         (-[WebView draggingUpdated:]):
155           ditto
156         (-[WebView draggingExited:]):
157           ditto
158         (-[WebView performDragOperation:]):
159           ditto
160         (-[WebView _hitTest:dragTypes:]):
161         * WebView/WebViewInternal.h:
162           remove unnecessary method def
163
164 2007-01-22  John Sullivan  <sullivan@apple.com>
165
166         * WebView/WebHTMLView.mm:
167         (-[WebHTMLView _lookUpInDictionaryFromMenu:]):
168         Tiger build fix: remove unused variable for return value of dictionaryServiceWindowShow
169
170 2007-01-22  John Sullivan  <sullivan@apple.com>
171
172         Reviewed by Adam and Darin
173
174         - fixed <rdar://problem/4794320> "Look Up in Dictionary" does nothing in WebKit 
175         (need to adopt new API)
176
177         * Misc/WebNSURLExtras.m:
178         (-[NSString _web_isUserVisibleURL]):
179         random typo correction in comment
180
181         * English.lproj/StringsNotToBeLocalized.txt:
182         updated for these changes
183
184         * WebView/WebHTMLView.mm:
185         (coreGraphicsScreenPointForAppKitScreenPoint):
186         new function to convert an AppKit screen point to a CG screen point
187         (-[WebHTMLView _lookUpInDictionaryFromMenu:]):
188         on Leopard now uses new API. There's something of an impedance mismatch between
189         this API and WebKit, but that was true for the SPI we were using in Tiger also.
190         Bug 4945808 covers the ways in which this is not perfect.
191
192 2007-01-21  Darin Adler  <darin@apple.com>
193
194         Reviewed by Tim H.
195
196         * WebInspector/webInspector/inspector.css: Use row-resize for the splitter cursor
197         instead of move. It's a horizontal splitter resizer.
198
199 2007-01-19  Adam Roben  <aroben@apple.com>
200
201         Reviewed by Beth.
202
203         Fix <rdar://problem/4942294> REGRESSION: "Spelling and Grammar",
204         "Font", "Speech", and "Writing Direction" are missing from contextual
205         menu
206
207         * WebCoreSupport/WebContextMenuClient.mm:
208         (fixMenusForOldClients): Change our new SPI tags to
209         WebMenuItemTagOther because old clients aren't expecting the new tags.
210         (fixMenusFromOldClients): Use each menu item's title to figure out its
211         correct tag again.
212         (WebContextMenuClient::getCustomMenuFromDefaultItems): Call
213         fixMenusForOldClients before calling up to the delegate.
214         * WebView/WebUIDelegatePrivate.h: Define WEBMENUITEMTAG_SPI_START so
215         that we can use it in WebContextMenuClient.
216
217 2007-01-19  John Sullivan  <sullivan@apple.com>
218
219         Reviewed by Darin
220
221         - WebKit part of fix for: <rdar://problem/4451715> REGRESSION: On some sites, have to 
222           type a character before username/password autofill kicks in
223           
224         Added new webView:didFinishDocumentLoadForFrame: SPI and wired it up
225
226         * WebView/WebViewPrivate.h:
227         declare new delegate method
228
229         * WebCoreSupport/WebFrameLoaderClient.h:
230         declare dispatchDidFinishDocumentLoad()
231
232         * WebCoreSupport/WebFrameLoaderClient.mm:
233         (WebFrameLoaderClient::dispatchDidFinishDocumentLoad):
234         new method, calls new delegate method
235
236         * DefaultDelegates/WebDefaultFrameLoadDelegate.m:
237         (-[WebDefaultFrameLoadDelegate webView:didFinishDocumentLoadForFrame:]):
238         empty default implementation of new delegate method
239
240 2007-01-19  Anders Carlsson  <acarlsson@apple.com>
241
242         Reviewed by John Sullivan.
243
244         http://bugs.webkit.org/show_bug.cgi?id=12308
245         REGRESSION(r18910): Crash in WebBaseNetscapePluginStream cancelLoadAndDestroyStreamWithError
246         
247         * Plugins/WebBaseNetscapePluginView.mm:
248         (-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:DOMElement:]):
249         Move code from initWithFrame in here.
250
251 2007-01-19  Anders Carlsson  <acarlsson@apple.com>
252
253         Yet another build fix.
254         
255         * WebCoreSupport/WebChromeClient.h:
256         * WebCoreSupport/WebChromeClient.mm:
257         (WebChromeClient::setStatusbarText):
258
259 2007-01-18  Anders Carlsson  <acarlsson@apple.com>
260
261         Reviewed by Adam.
262
263         Move functions from the bridge to the chrome client.
264         
265         * WebCoreSupport/WebChromeClient.h:
266         * WebCoreSupport/WebChromeClient.mm:
267         (WebChromeClient::runJavaScriptAlert):
268         (WebChromeClient::runJavaScriptConfirm):
269         (WebChromeClient::runJavaScriptPrompt):
270         (WebChromeClient::setStatusBarText):
271         * WebCoreSupport/WebFrameBridge.mm:
272
273 2007-01-18  Adam Roben  <aroben@apple.com>
274
275         Reviewed by Beth.
276
277         Fix <rdar://problem/4939672> REGRESSION: With text selected that is
278         not a link, the "Remove Link" contextual menu item remains active
279
280         * WebView/WebHTMLView.mm:
281         (-[WebHTMLView menuForEvent:]): Leave autoenabling of menu items on so
282         that clients can implement validateMenuItem:.
283
284 2007-01-18  Brady Eidson  <beidson@apple.com>
285
286         Reviewed by Adele
287
288         <rdar://problem/4917290> - 
289         Null deref in WebFrameLoaderClient::restoreScrollPositionAndViewState() 
290         after regaining network connection
291
292         * WebCoreSupport/WebFrameLoaderClient.mm:
293         (WebFrameLoaderClient::restoreScrollPositionAndViewState): Bail early with a null currentItem, preventing 
294         a crash in release builds.  Leave the ASSERT to help find other cases where this might happen in debug builds.
295
296 2007-01-18  Kevin Decker  <kdecker@apple.com>
297
298         Reviewed by John.
299
300         <rdar://problem/4939511> WebKit should set the CG clip path for plug-ins that draw using CoreGraphics
301
302         * Plugins/WebBaseNetscapePluginView.mm:
303         (-[WebBaseNetscapePluginView drawRect:]):  Set the CG clip path to the plug-in dirty rect. This allows plug-ins to obtain their
304         dirty rect using functions like CGContextGetClipBoundingBox().
305
306 2007-01-17  Alice Liu  <alice.liu@apple.com>
307
308         Reviewed by Harrison.
309
310         Fix for <rdar://problem/4894155> REGRESSION: Extra line break is pasted with content into message body after choosing File - Paste
311
312         Migration of some editing code from WebHTMView to WebCore::Editor
313         resulted in not calling pasteboardTypesForSelection, which Mail was
314         overriding for the special purpose of adding a type to the
315         pasteboard after WebKit did.  This patch adds 2 separate code paths
316         for Tiger and Leopard.  On Tiger we give in and call the WebView's
317         pasteboardTypesForSelection.  On Leopard we call a delegate after
318         the pasteboard types are set. 
319
320         * DefaultDelegates/WebDefaultEditingDelegate.m:
321         (-[WebDefaultEditingDelegate webView:didSetSelectionTypesForPasteboard:]):
322         * WebCoreSupport/WebEditorClient.h:
323         * WebCoreSupport/WebEditorClient.mm:
324         (WebEditorClient::didSetSelectionTypesForPasteboard):
325         (WebEditorClient::pasteboardTypesForSelection):
326         * WebView/WebEditingDelegate.h:
327
328 2007-01-17  John Sullivan  <sullivan@apple.com>
329
330         Reviewed by Darin
331
332         - WebKit part of fix for <rdar://problem/4462420> REGRESSION: Mail hangs during 
333           Replace All if the replacement string contains the search string
334
335         * Misc/WebKitVersionChecks.h:
336         Added extern "C" so this can be used from .mm files. I don't need this change anymore for
337         this fix, but it's still worth fixing now so it doesn't bite anyone later.
338
339         * WebView/WebDocumentPrivate.h:
340         Invented new private protocol WebDocumentIncrementalSearching, that has one method. The one
341         method is just like the one WebDocumentSearching method, but with an additional parameter.
342         We hope to eliminate this dependence on protocols someday, but adding another one as SPI
343         seems like it won't make anything worse.
344         
345         * WebView/WebHTMLView.mm:
346         (-[WebHTMLView searchFor:direction:caseSensitive:wrap:]):
347         now calls through to new method that has one additional parameter, passing NO to match old behavior
348         (-[WebHTMLView searchFor:direction:caseSensitive:wrap:startInSelection:]):
349         pass new parameter to bridge
350         
351         * WebView/WebPDFView.h:
352         Declare conformance to WebDocumentIncrementalSearching protocol
353         
354         * WebView/WebPDFView.mm:
355         (-[WebPDFView searchFor:direction:caseSensitive:wrap:]):
356         now calls through to new method that has one additional parameter, passing NO to match old behavior
357         (-[WebPDFView searchFor:direction:caseSensitive:wrap:startInSelection:]):
358         new method, former guts of searchFor:direction:caseSensitive:wrap: but now handles startInSelection
359         parameter
360         
361         * WebView/WebViewPrivate.h:
362         Declare new searchFor:direction:caseSensitive:wrap:startInSelection: method, just like existing
363         method but with one additional parameter
364
365         * WebView/WebView.mm:
366         (-[WebView searchFor:direction:caseSensitive:wrap:]):
367         now calls through to new method that has one additional parameter, passing NO to match old behavior
368         (-[WebView searchFor:direction:caseSensitive:wrap:startInSelection:]):
369         new method, former guts of searchFor:direction:caseSensitive:wrap: but now handles startInSelection
370         parameter
371         
372 2007-01-17  Brady Eidson  <beidson@apple.com>
373
374         Reviewed by Deth Bakin and Brian Dash
375
376         Drop Panther Support (?!?) and change the comment explaining some SPI forward decls
377
378         * Misc/WebDownload.m:
379
380 2007-01-17  Darin Adler  <darin@apple.com>
381
382         Reviewed by Maciej.
383
384         - fix http://bugs.webkit.org/show_bug.cgi?id=12278
385           <rdar://problem/4928705> REGRESSION(r13070): Dragged image size includes padding (12278)
386
387         * Misc/WebElementDictionary.mm: (-[WebElementDictionary _imageRect]):
388         Call HitTestResult::imageRect, not HitTestResult::boundingBox.
389
390 2007-01-17  Anders Carlsson  <acarlsson@apple.com>
391
392         Reviewed by John Sullivan.
393         
394         Move all code in WebNetscapePluginEmbeddedView down to WebBaseNetscapePluginView.
395         
396         * Plugins/WebBaseNetscapePluginView.h:
397         * Plugins/WebBaseNetscapePluginView.mm:
398         (-[WebBaseNetscapePluginView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:DOMElement:]):
399         (-[WebBaseNetscapePluginView didStart]):
400         (-[WebBaseNetscapePluginView dataSource]):
401         (-[WebBaseNetscapePluginView dealloc]):
402         (-[WebBaseNetscapePluginView pluginView:receivedResponse:]):
403         (-[WebBaseNetscapePluginView pluginView:receivedData:]):
404         (-[WebBaseNetscapePluginView pluginView:receivedError:]):
405         (-[WebBaseNetscapePluginView pluginViewFinishedLoading:]):
406         (-[WebBaseNetscapePluginView _redeliverStream]):
407         * Plugins/WebNetscapePluginEmbeddedView.h:
408         * Plugins/WebNetscapePluginEmbeddedView.mm:
409
410 2007-01-17  Maciej Stachowiak  <mjs@apple.com>
411
412         Reviewed by Eric.
413         
414         <rdar://problem/4887781> Seed: Repro Safari crash in -[WebHTMLRepresentation receivedData:withDataSource:] (music.aol.com)
415
416         * WebView/WebDataSource.mm:
417         (-[WebDataSource _receivedData:]): Protect self against destruction partway through this method.
418
419 2007-01-16  Alice Liu  <alice.liu@apple.com>
420
421         Reviewed by harrison.
422
423         Fixed <rdar://problem/4921134> WebKit needs extensible cut/copy to allow additional types to be written to pasteboard
424
425         * DefaultDelegates/WebDefaultEditingDelegate.m:
426         (-[WebDefaultEditingDelegate webView:didWriteSelectionToPasteboard:]):
427         * WebCoreSupport/WebEditorClient.h:
428         * WebCoreSupport/WebEditorClient.mm:
429         (WebEditorClient::didWriteSelectionToPasteboard):
430         * WebKit.xcodeproj/project.pbxproj:
431         * WebView/WebEditingDelegate.h:
432
433 2007-01-15  Justin Garcia  <justin.garcia@apple.com>
434
435         Reviewed by mjs
436
437         <rdar://problem/4810960>
438         Gmail Editor: window.focus() called on keyDown (9640)
439
440         The window's keydown event handler was being called
441         instead of the editable subframe's if there was a key binding
442         for the key event.
443
444         * WebView/WebHTMLView.mm:
445         (-[WebHTMLView performKeyEquivalent:]): Don't send the event
446         to WebCore unless this WebHTMLView is the firstResponder.
447
448 2007-01-15  Anders Carlsson  <acarlsson@apple.com>
449
450         Reviewed by Darin.
451
452         Update to match WebCore.
453         
454         * WebCoreSupport/WebFrameLoaderClient.h:
455         * WebCoreSupport/WebFrameLoaderClient.mm:
456         (WebFrameLoaderClient::willChangeEstimatedProgress):
457         (WebFrameLoaderClient::didChangeEstimatedProgress):
458         (WebFrameLoaderClient::postProgressStartedNotification):
459         (WebFrameLoaderClient::postProgressEstimateChangedNotification):
460         (WebFrameLoaderClient::postProgressFinishedNotification):
461         Post the correct notifications.
462         
463         * WebView/WebView.mm:
464         (-[WebViewPrivate init]):
465         (-[WebViewPrivate dealloc]):
466         Get rid of all progress tracking code.
467         
468         (-[WebView estimatedProgress]):
469         Call ProgressTracker::estimatedProgress()
470
471 2007-01-15  Adam Roben  <aroben@apple.com>
472
473         Reviewed by Darin.
474
475         Fix: http://bugs.webkit.org/show_bug.cgi?id=12134
476         REGRESSION: Assertion failure and crash when right clicking selection
477         in forms
478
479         * WebCoreSupport/WebContextMenuClient.mm:
480         (fixMenusFromOldApps): Static helper to fix up menus from applications
481         compiled against Tiger WebKit.
482         (WebContextMenuClient::getCustomMenuFromDefaultItems): Call helper to
483         fix menus.
484         * WebView/WebUIDelegatePrivate.h: Fixed typo.
485
486 2007-01-14  David Kilzer  <ddkilzer@kilzer.net>
487
488         Reviewed by Darin.
489
490         - fix http://bugs.webkit.org/show_bug.cgi?id=12251
491           REGRESSION (r18822-r18823): Assertion failure opening document with non-existent resources
492           (dom/xhtml/level2/html/HTMLIFrameElement11.xhtml)
493
494         * WebView/WebView.mm:
495         (-[WebView _objectForIdentifier:]): Removed assertion.
496         (-[WebView _removeObjectForIdentifier:]): Removed assertion.
497
498 2007-01-12  Anders Carlsson  <acarlsson@apple.com>
499
500         Reviewed by Darin.
501
502         Add a HashMap between unsigned longs and Objective-C objects and use it for
503         the resource load delegate.
504         
505         * WebCoreSupport/WebFrameLoaderClient.h:
506         * WebCoreSupport/WebFrameLoaderClient.mm:
507         (WebFrameLoaderClient::assignIdentifierToInitialRequest):
508         (WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
509         (WebFrameLoaderClient::dispatchWillSendRequest):
510         (WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
511         (WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
512         (WebFrameLoaderClient::dispatchDidReceiveResponse):
513         (WebFrameLoaderClient::dispatchDidReceiveContentLength):
514         (WebFrameLoaderClient::dispatchDidFinishLoading):
515         (WebFrameLoaderClient::dispatchDidFailLoading):
516         (WebFrameLoaderClient::incrementProgress):
517         (WebFrameLoaderClient::completeProgress):
518         * WebView/WebView.mm:
519         (-[WebViewPrivate init]):
520         (-[WebViewPrivate dealloc]):
521         (-[WebView _addObject:forIdentifier:]):
522         (-[WebView _objectForIdentifier:]):
523         (-[WebView _removeObjectForIdentifier:]):
524         * WebView/WebViewInternal.h:
525
526 2007-01-11  Brady Eidson  <beidson@apple.com>
527
528         Reviewed by Anders
529
530         Rewrites HTTP Authentication setting up a more platform-independent structure
531
532         * WebCoreSupport/WebFrameLoaderClient.h:
533         * WebCoreSupport/WebFrameLoaderClient.mm:
534         (WebFrameLoaderClient::dispatchDidReceiveAuthenticationChallenge):
535         (WebFrameLoaderClient::dispatchDidCancelAuthenticationChallenge):
536         * WebKit.xcodeproj/project.pbxproj:
537
538 2007-01-11  Darin Adler  <darin@apple.com>
539
540         Reviewed by Mitz.
541
542         - fix http://bugs.webkit.org/show_bug.cgi?id=12180
543           REGRESSION: Double-clicking on JS exception in JS log crashes in -[SharedBufferData initWithSharedBuffer:]
544
545         * WebView/WebDataSource.mm: (-[WebDataSource data]): Added null check.
546
547 2007-01-11  Darin Adler  <darin@apple.com>
548
549         Reviewed by Hyatt.
550
551         - moved code from a couple WebCore bridging classes here instead
552
553         * Misc/WebNSPasteboardExtras.mm:
554         (-[NSPasteboard _web_writeImage:element:URL:title:archive:types:]):
555         Use MimeTypeRegistry instead of WebMimeTypeRegistryBridge.
556
557         * WebView/WebHTMLRepresentation.mm:
558         (stringArray): Added. Helper to convert a HashSet to an NSArray.
559         (concatenateArrays): Added. Helper to concatenate two NSArray objects.
560         (+[WebHTMLRepresentation supportedMIMETypes]): Use MimeTypeRegistry instead of
561         WebMimeTypeRegistryBridge. Also fix a potential GC problem by using a RetainPtr
562         instead of a [retain] on a global variable.
563         (+[WebHTMLRepresentation supportedNonImageMIMETypes]): Ditto.
564         (+[WebHTMLRepresentation supportedImageMIMETypes]): Ditto.
565
566         * WebView/WebHTMLView.mm:
567         (-[WebHTMLView _imageExistsAtPaths:]): Use MimeTypeRegistry instead of
568         WebMimeTypeRegistryBridge.
569         (-[WebHTMLView _documentFragmentWithPaths:]): Ditto.
570
571         * WebView/WebView.mm: (+[WebView _decodeData:]): Moved code here from
572         the old WebCoreEncodings class.
573
574         * WebKit.xcodeproj/project.pbxproj: Let Xcode have its way with this file.
575         Moved WebRenderNode into the appropriate group.
576
577 2007-01-10  Mitz Pettel  <mitz@webkit.org>
578
579         Reviewed by Darin.
580
581         - fix http://bugs.webkit.org/show_bug.cgi?id=11775
582           'Show URLs in Tool Tips' preference is ignored
583
584         * WebView/WebHTMLView.mm:
585         (-[WebHTMLView _resetCachedWebPreferences:]):
586         (-[WebHTMLView setDataSource:]): Added a call to _resetCachedWebPreferences:.
587         Added an assertion that the view is not closed, instead of reopening it.
588         Reopening should not occur, now that <http://bugs.webkit.org/show_bug.cgi?id=12087>
589         is fixed.
590
591 2007-01-10  Beth Dakin  <bdakin@apple.com>
592
593         Reviewed by John.
594
595         Fix for <rdar://problem/4914258> REGRESSION: Search in Google now 
596         operates on the current WebView instead of invoking Safari's 
597         service
598
599         * WebCoreSupport/WebContextMenuClient.h:
600         * WebCoreSupport/WebContextMenuClient.mm:
601         (WebContextMenuClient::searchWithGoogle): Call into WebView to 
602         search in Google.
603         * WebView/WebViewInternal.h: Make _searchWithGoogleFromMenu 
604         available.
605
606 2007-01-09  Timothy Hatcher  <timothy@apple.com>
607
608         Reviewed by Darin.
609
610         Rename the now ObjC++ files to be .mm and remove the explicit file types.
611
612         * DOM/WebDOMOperations.m: Removed.
613         * DefaultDelegates/WebDefaultContextMenuDelegate.m: Removed.
614         * English.lproj/StringsNotToBeLocalized.txt:
615         * Misc/WebCoreStatistics.m: Removed.
616         * Misc/WebElementDictionary.m: Removed.
617         * Misc/WebIconDatabase.m: Removed.
618         * Misc/WebNSAttributedStringExtras.m: Removed.
619         * Misc/WebNSPasteboardExtras.m: Removed.
620         * Plugins/WebNetscapePluginEmbeddedView.m: Removed.
621         * Plugins/WebNullPluginView.m: Removed.
622         * Plugins/WebPluginContainerCheck.m: Removed.
623         * WebCoreSupport/WebViewFactory.m: Removed.
624         * WebKit.xcodeproj/project.pbxproj:
625         * WebView/WebArchiver.m: Removed.
626         * WebView/WebHTMLRepresentation.m: Removed.
627         * WebView/WebHTMLView.m: Removed.
628         * WebView/WebRenderNode.m: Removed.
629         * WebView/WebResource.m: Removed.
630         * WebView/WebScriptDebugDelegate.m: Removed.
631
632 2007-01-09  Maciej Stachowiak  <mjs@apple.com>
633
634         Reviewed by Darin.
635         
636         - remove window display throttling code; no longer used
637
638         * Misc/WebNSWindowExtras.h:
639         * Misc/WebNSWindowExtras.m:
640         * WebView/WebFrameView.mm:
641         (-[WebFrameView initWithFrame:]):
642         * WebView/WebPreferenceKeysPrivate.h:
643
644 2007-01-08  Anders Carlsson  <acarlsson@apple.com>
645
646         Reviewed by Brady.
647
648         Remove bridge functions that are implemented directly in FrameLoader now.
649         
650         * WebCoreSupport/WebFrameBridge.mm:
651
652 2007-01-08  Sam Weinig  <sam@webkit.org>
653
654         Reviewed by Mark.
655
656         Adds default value for outline-color and fixes default
657         values of the recently fixed *-color properties.
658
659         * WebInspector/webInspector/inspector.js:
660
661 2007-01-08  Beth Dakin  <bdakin@apple.com>
662
663         Reviewed by Adam.
664
665         Fix for http://bugs.webkit.org/show_bug.cgi?id=12161 REGRESSION: 
666         Crash when control-clicking on an image for contextual menu
667
668         * WebView/WebHTMLView.m:
669         (-[WebHTMLView menuForEvent:]): We need to nil-check coreMenu since 
670         it will be nil if the DOM popped up a menu instead. I cleaned up 
671         the function to make all the nil checks early returns instead of 
672         nesting all of the content. Also moved the autorelease to be with 
673         the creation of the menu instead of at the return.
674
675 2007-01-08  Sam Weinig  <sam@webkit.org>
676
677         Reviewed by Tim H.
678
679         Adds default value for -webkit-box-shadow and fixes default
680         value of -webkit-column-count to be "auto".  Also sorts the
681         list of defaults.
682
683         * WebInspector/webInspector/inspector.js:
684
685 2007-01-08  Andrew Wellington  <proton@wiretapped.net>
686
687         Reviewed by Mark.
688
689         * WebInspector/webInspector/inspector.js: Hide default values of
690         -webkit-column styles in WebInspector.
691
692 2007-01-05  Darin Adler  <darin@apple.com>
693
694         Reviewed by Hyatt.
695
696         * Misc/WebNSAttributedStringExtras.m:
697         (+[NSAttributedString _web_attributedStringFromRange:]):
698         Updated to use new list marker text API that is String rather than
699         DeprecatedString. Also removed code to do text form of non-text list
700         markers since the list marker class now deals with that.
701
702 2007-01-05  Anders Carlsson  <acarlsson@apple.com>
703
704         Reviewed by Darin.
705
706         Fix build.
707         
708         * WebCoreSupport/WebFrameLoaderClient.h:
709         * WebCoreSupport/WebFrameLoaderClient.mm:
710         (WebFrameLoaderClient::dispatchCreatePage):
711
712 2007-01-05  Anders Carlsson  <acarlsson@apple.com>
713
714         Reviewed by Maciej.
715
716         The data returned is now a SharedBuffer so wrap it in an NSData object.
717         
718         * WebView/WebDataSource.mm:
719         (-[WebDataSource data]):
720
721 2007-01-04  Adam Roben  <aroben@apple.com>
722
723         Reviewed by Geoff, cheered by others.
724
725         Dead code elimination.
726
727         * WebView/WebHTMLView.m:
728
729 2007-01-04  Adam Roben  <aroben@apple.com>
730
731         Boo on me for undoing Beth's hard work.
732
733         * WebView/WebHTMLView.m:
734         (-[WebHTMLView menuForEvent:]): Undo a mistaken roll out of r18597.
735
736 2007-01-04  David Kilzer  <ddkilzer@webkit.org>
737
738         Reviewed by Brady.
739
740         - fix http://bugs.webkit.org/show_bug.cgi?id=12111
741           Uninitialized variable in -[WebDefaultPolicyDelegate webView:decidePolicyForMIMEType:request:frame:decisionListener:]
742
743         * DefaultDelegates/WebDefaultPolicyDelegate.m: Initialize isDirectory.
744
745 2007-01-04  Adam Roben  <aroben@apple.com>
746
747         Reviewed by Geoff.
748
749         Remove WebKit/AppKit from handling tabbing between subframes.
750
751         * WebCoreSupport/WebChromeClient.h: Added new ChromeClient methods for
752         moving focus out of the WebView.
753         * WebCoreSupport/WebChromeClient.mm: Ditto.
754         (WebChromeClient::canTakeFocus):
755         (WebChromeClient::takeFocus):
756         * WebCoreSupport/WebFrameBridge.mm:
757         (-[WebFrameBridge webView]): Added null-check of m_frame.
758         * WebView/WebHTMLView.m: Removed -[WebHTMLView nextValidKeyView].
759         (-[WebHTMLView _updateActiveState]): Changed to focus the frame if
760         WebCore believes it to be the focused frame.
761         (-[WebHTMLView becomeFirstResponder]): Rewrote to call into
762         FocusController to place focus correctly within the WebView.
763
764 2007-01-04  Anders Carlsson  <acarlsson@apple.com>
765
766         Reviewed by Brady.
767
768         FrameLoaderClient changed yet again.
769         
770         * WebCoreSupport/WebFrameLoaderClient.h:
771         * WebCoreSupport/WebFrameLoaderClient.mm:
772         (WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
773         (WebFrameLoaderClient::dispatchWillSendRequest):
774
775 2007-01-04  Anders Carlsson  <acarlsson@apple.com>
776
777         Reviewed by Adam.
778
779         FrameLoaderClient changed again.
780         
781         * WebCoreSupport/WebFrameLoaderClient.h:
782         * WebCoreSupport/WebFrameLoaderClient.mm:
783         (WebFrameLoaderClient::download):
784         (WebFrameLoaderClient::willUseArchive):
785
786 2007-01-04  Beth Dakin  <bdakin@apple.com>
787
788         Reviewed by Adam.
789
790         No need to hit test twice.
791
792         * WebView/WebHTMLView.m:
793         (-[WebHTMLView menuForEvent:]):
794
795 2007-01-04  Beth Dakin  <bdakin@apple.com>
796
797         Reviewed by Adam.
798
799         Turn on WebCore context menus. Delete a bunch of WebKit context 
800         menu code that is no longer needed.
801
802         * DefaultDelegates/WebDefaultContextMenuDelegate.m: Removed a lot 
803         of code from this class. This class only still needs to exist for 
804         PDF context menus, so we only need to deal with the menu items that 
805         might possibly be added to a PDF context menu.
806         (-[WebDefaultUIDelegate 
807         menuItemWithTag:target:representedObject:]): Same.
808         (-[WebDefaultUIDelegate 
809         webView:contextMenuItemsForElement:defaultMenuItems:]): Same.
810         * WebCoreSupport/WebContextMenuClient.h: Name change and have the 
811         former getCustomMenuFromDefaultItems function return the 
812         PlatformMenuDescription since it feels funny to have the client set 
813         the new platform description.
814         * WebCoreSupport/WebContextMenuClient.mm: Same.
815         (WebContextMenuClient::getCustomMenuFromDefaultItems): Same. Also 
816         move in some code that used to be in _menuForElement.
817         * WebView/WebHTMLView.m: Deleted a bunch of un-used functions
818         (-[WebHTMLView menuForEvent:]): Turn on menus, and append the 
819         Inspect Element item. 
820         * WebView/WebHTMLViewPrivate.h: Deleted a bunch of un-used 
821         functions.
822         * WebView/WebView.mm:
823         (-[WebView _menuForElement:defaultItems:]): Removed a lot of code 
824         from _menuForElement that now makes more sense elsewhere. Only PDF 
825         context menus use this function now. Hopefully we can just get rid 
826         of it soon, too.
827
828 2007-01-04  Anders Carlsson  <acarlsson@apple.com>
829
830         Reviewed by Brady.
831
832         Update for WebCore changes.
833         
834         * WebCoreSupport/WebFrameLoaderClient.h:
835         * WebCoreSupport/WebFrameLoaderClient.mm:
836         (WebFrameLoaderClient::download):
837         (WebFrameLoaderClient::dispatchDidLoadResourceFromMemoryCache):
838         (WebFrameLoaderClient::dispatchWillSendRequest):
839         (WebFrameLoaderClient::dispatchDidReceiveResponse):
840         (WebFrameLoaderClient::incrementProgress):
841
842 2007-01-04  Don Gibson  <dgibson77@gmail.com>
843
844         Reviewed by Alexey.
845
846         http://bugs.webkit.org/show_bug.cgi?id=11900:
847         Windows build bustage
848
849         * COM/ChromeClientWin.cpp:
850         (ChromeClientWin::addMessageToConsole):
851         (ChromeClientWin::runBeforeUnloadConfirmPanel):
852         * COM/ChromeClientWin.h:
853         * COM/ContextMenuClientWin.cpp:
854         (ContextMenuClientWin::contextMenuItemSelected):
855         * COM/ContextMenuClientWin.h:
856         * COM/WebFrameLoaderClient.cpp:
857         (WebFrameLoaderClient::setDocumentViewFromPageCache):
858         (WebFrameLoaderClient::forceLayout):
859         (WebFrameLoaderClient::forceLayoutForNonHTML):
860         (WebFrameLoaderClient::updateGlobalHistoryForStandardLoad):
861         (WebFrameLoaderClient::updateGlobalHistoryForReload):
862         (WebFrameLoaderClient::shouldGoToHistoryItem):
863         (WebFrameLoaderClient::saveScrollPositionAndViewStateToItem):
864         (WebFrameLoaderClient::restoreScrollPositionAndViewState):
865         (WebFrameLoaderClient::provisionalLoadStarted):
866         (WebFrameLoaderClient::saveDocumentViewToPageCache):
867         (WebFrameLoaderClient::canCachePage):
868         * COM/WebFrameLoaderClient.h:
869         * WebKit.vcproj/WebKit.vcproj:
870
871 2007-01-03  John Sullivan  <sullivan@apple.com>
872
873         * WebView/WebPDFView.mm:
874         (-[WebPDFView _openWithFinder:]):
875         Tiger build fix: use [NSNumber initWithInt:] rather than the new [NSNumber initWithInteger:]
876
877 2007-01-03  John Sullivan  <sullivan@apple.com>
878
879         Reviewed by Kevin Decker
880
881         - fixed <rdar://problem/4145714> WebKit's PDFView's "Open in Preview" puts the 
882           PDF in /tmp, both group and world-readable
883
884         * WebView/WebPDFView.mm:
885         (-[WebPDFView _openWithFinder:]):
886         Make the file only readable by the current user
887
888 2007-01-03  Beth Dakin  <bdakin@apple.com>
889
890         Reviewed by John.
891
892         Make localized strings for all of the context menu item titles that 
893         are accessible to WebCore.
894
895         * English.lproj/Localizable.strings:
896         * WebCoreSupport/WebViewFactory.m:
897         (-[WebViewFactory contextMenuItemTagOpenLinkInNewWindow]):
898         (-[WebViewFactory contextMenuItemTagDownloadLinkToDisk]):
899         (-[WebViewFactory contextMenuItemTagCopyLinkToClipboard]):
900         (-[WebViewFactory contextMenuItemTagOpenImageInNewWindow]):
901         (-[WebViewFactory contextMenuItemTagDownloadImageToDisk]):
902         (-[WebViewFactory contextMenuItemTagCopyImageToClipboard]):
903         (-[WebViewFactory contextMenuItemTagOpenFrameInNewWindow]):
904         (-[WebViewFactory contextMenuItemTagCopy]):
905         (-[WebViewFactory contextMenuItemTagGoBack]):
906         (-[WebViewFactory contextMenuItemTagGoForward]):
907         (-[WebViewFactory contextMenuItemTagStop]):
908         (-[WebViewFactory contextMenuItemTagReload]):
909         (-[WebViewFactory contextMenuItemTagCut]):
910         (-[WebViewFactory contextMenuItemTagPaste]):
911         (-[WebViewFactory contextMenuItemTagNoGuessesFound]):
912         (-[WebViewFactory contextMenuItemTagIgnoreSpelling]):
913         (-[WebViewFactory contextMenuItemTagLearnSpelling]):
914         (-[WebViewFactory contextMenuItemTagSearchInSpotlight]):
915         (-[WebViewFactory contextMenuItemTagSearchWeb]):
916         (-[WebViewFactory contextMenuItemTagLookUpInDictionary]):
917         (-[WebViewFactory contextMenuItemTagOpenLink]):
918         (-[WebViewFactory contextMenuItemTagIgnoreGrammar]):
919         (-[WebViewFactory contextMenuItemTagSpellingMenu]):
920         (-[WebViewFactory contextMenuItemTagShowSpellingPanel:]):
921         (-[WebViewFactory contextMenuItemTagCheckSpelling]):
922         (-[WebViewFactory contextMenuItemTagCheckSpellingWhileTyping]):
923         (-[WebViewFactory contextMenuItemTagCheckGrammarWithSpelling]):
924         (-[WebViewFactory contextMenuItemTagFontMenu]):
925         (-[WebViewFactory contextMenuItemTagShowFonts]):
926         (-[WebViewFactory contextMenuItemTagBold]):
927         (-[WebViewFactory contextMenuItemTagItalic]):
928         (-[WebViewFactory contextMenuItemTagUnderline]):
929         (-[WebViewFactory contextMenuItemTagOutline]):
930         (-[WebViewFactory contextMenuItemTagStyles]):
931         (-[WebViewFactory contextMenuItemTagShowColors]):
932         (-[WebViewFactory contextMenuItemTagSpeechMenu]):
933         (-[WebViewFactory contextMenuItemTagStartSpeaking]):
934         (-[WebViewFactory contextMenuItemTagStopSpeaking]):
935         (-[WebViewFactory contextMenuItemTagWritingDirectionMenu]):
936         (-[WebViewFactory contextMenuItemTagDefaultDirection]):
937         (-[WebViewFactory contextMenuItemTagLeftToRight]):
938         (-[WebViewFactory contextMenuItemTagRightToLeft]):
939
940 2007-01-03  Brady Eidson  <beidson@apple.com>
941
942         Reviewed by John Sullivan
943
944         In the Bookmarks View/History View, favicon may be the incorrect size
945
946         * History/WebHistoryItem.mm:
947         (-[WebHistoryItem icon]): Call to the WebIconDatabase until a WebCore issue is resolved
948
949 2007-01-03  Adele Peterson  <adele@apple.com>
950
951         Reviewed by Darin.
952
953         - Fix for <rdar://problem/4455147> Safari allows division slash character in URLs, which looks like slash character (not fixed by IDNScriptWhiteList.txt)
954
955         * Misc/WebNSURLExtras.m: (allCharactersInIDNScriptWhiteList): Always disallow the division slash character.
956
957 2007-01-02  Brady Eidson <beidson@apple.com>
958
959         Controversially reviewed by Tim H. and Maciej
960
961         Fixes http://bugs.webkit.org/show_bug.cgi?id=12086, http://bugs.webkit.org/show_bug.cgi?id=12088, 
962         possibly http://bugs.webkit.org/show_bug.cgi?id=12087, and probably a slew of others
963
964         WebHistoryItems returned from the WebBackForwardList accessors were being release/retained out-of-order
965         by the Safari app.  This bug never surfaced before because the WebBackForwardList had a retain on the 
966         item, preventing deallocation. Since the items are now just temporary wrappers, the list 
967         is no longer actually retaining them.
968
969         This solution is to simulate the ownership with a [[id retain] autorelease] - gross, but maybe the 
970         only solution for now...  =/
971
972         We can possibly consider reverting this fix at a later date - that task is marked by
973         <rdar://problem/4905705>
974
975         * History/WebBackForwardList.mm:
976         (-[WebBackForwardList backItem]):
977         (-[WebBackForwardList currentItem]):
978         (-[WebBackForwardList forwardItem]):
979         (-[WebBackForwardList itemAtIndex:]):
980
981 2007-01-02  Beth Dakin  <bdakin@apple.com>
982
983         Reviewed by Geoff.
984
985         Remove un-used function.
986
987         * WebCoreSupport/WebContextMenuClient.h:
988         * WebCoreSupport/WebContextMenuClient.mm:
989
990 2007-01-02  Brady Eidson  <beidson@apple.com>
991
992         Reviewed extensively and repeatedly by Darin
993
994         <rdar://problem/4887137> - WebCore Back/Forward Cache 
995         Most things not specifically commented on in the ChangeLog can be summed up as 
996         "Do things exactly the same way as we used to, but just stick in WebCore-land as much as possible"
997
998         * History/WebBackForwardList.mm:
999         (kitPrivate): Convenience functions to help with subbing "WebBackForwardListPrivate" for WebCore::BackForwardList
1000         (core):
1001         (backForwardListWrappers): A HashMap pattern used to map WebCore objects to their WebKit counterpart
1002         (kit):
1003         (+[WebBackForwardList setDefaultPageCacheSizeIfNecessary]):
1004         (-[WebBackForwardList initWithWebCoreBackForwardList:]):
1005         (-[WebBackForwardList init]):
1006         (-[WebBackForwardList dealloc]):
1007         (-[WebBackForwardList finalize]):
1008         (-[WebBackForwardList _close]):
1009         (-[WebBackForwardList addItem:]):
1010         (-[WebBackForwardList removeItem:]):
1011         (-[WebBackForwardList containsItem:]):
1012         (-[WebBackForwardList goBack]):
1013         (-[WebBackForwardList goForward]):
1014         (-[WebBackForwardList goToItem:]):
1015         (-[WebBackForwardList backItem]):
1016         (-[WebBackForwardList currentItem]):
1017         (-[WebBackForwardList forwardItem]):
1018         (vectorToNSArray):
1019         (-[WebBackForwardList backListWithLimit:]):
1020         (-[WebBackForwardList forwardListWithLimit:]):
1021         (-[WebBackForwardList capacity]):
1022         (-[WebBackForwardList setCapacity:]):
1023         (-[WebBackForwardList description]):
1024         (-[WebBackForwardList _clearPageCache]):
1025         (-[WebBackForwardList setPageCacheSize:]):
1026         (-[WebBackForwardList pageCacheSize]):
1027         (-[WebBackForwardList _usesPageCache]):
1028         (-[WebBackForwardList backListCount]):
1029         (-[WebBackForwardList forwardListCount]):
1030         (-[WebBackForwardList itemAtIndex:]):
1031         * History/WebBackForwardListInternal.h: Added.
1032
1033         * History/WebHistory.m: Removed.
1034         * History/WebHistory.mm: Added - Needed to be .mm to accept C++ header style
1035         (-[_WebCoreHistoryProvider containsItemForURLLatin1:length:]):
1036         (-[_WebCoreHistoryProvider containsItemForURLUnicode:length:]):
1037
1038         * History/WebHistoryItem.mm:
1039         (kitPrivate): Same pattern as WebBackForwardList
1040         (core):
1041         (historyItemWrappers):
1042         (WKNotifyHistoryItemChanged):
1043         (-[WebHistoryItem init]):
1044         (-[WebHistoryItem initWithURLString:title:lastVisitedTimeInterval:]):
1045         (-[WebHistoryItem dealloc]):
1046         (-[WebHistoryItem finalize]):
1047         (-[WebHistoryItem copyWithZone:]):
1048         (-[WebHistoryItem URLString]):
1049         (-[WebHistoryItem originalURLString]):
1050         (-[WebHistoryItem title]):
1051         (-[WebHistoryItem setAlternateTitle:]):
1052         (-[WebHistoryItem alternateTitle]):
1053         (-[WebHistoryItem icon]):
1054         (-[WebHistoryItem lastVisitedTimeInterval]):
1055         (-[WebHistoryItem hash]):
1056         (-[WebHistoryItem isEqual:]):
1057         (-[WebHistoryItem description]):
1058         (kit):
1059         (+[WebHistoryItem entryWithURL:]):
1060         (+[WebHistoryItem initWindowWatcherIfNecessary]):
1061         (-[WebHistoryItem initWithURL:target:parent:title:]):
1062         (-[WebHistoryItem initWithWebCoreHistoryItem:]):
1063         (-[WebHistoryItem setTitle:]):
1064         (-[WebHistoryItem setVisitCount:]):
1065         (-[WebHistoryItem setViewState:]):
1066         (-[WebHistoryItem _mergeAutoCompleteHints:]):
1067         (-[WebHistoryItem initFromDictionaryRepresentation:]):
1068         (-[WebHistoryItem scrollPoint]):
1069         (-[WebHistoryItem _transientPropertyForKey:]):
1070         (-[WebHistoryItem _setTransientProperty:forKey:]):
1071         (-[WebHistoryItem dictionaryRepresentation]):
1072         (-[WebHistoryItem target]):
1073         (-[WebHistoryItem isTargetItem]):
1074         (-[WebHistoryItem visitCount]):
1075         (-[WebHistoryItem RSSFeedReferrer]):
1076         (-[WebHistoryItem setRSSFeedReferrer:]):
1077         (-[WebHistoryItem children]):
1078         (-[WebHistoryItem setAlwaysAttemptToUsePageCache:]):
1079         (-[WebHistoryItem URL]):
1080         (-[WebHistoryItem _setLastVisitedTimeInterval:]):
1081         (-[WebHistoryItem _lastVisitedDate]):
1082         (-[WebHistoryItem targetItem]):
1083         (+[WebHistoryItem _releaseAllPendingPageCaches]):
1084         (-[WebWindowWatcher windowWillClose:]):
1085         * History/WebHistoryItemInternal.h:
1086         * History/WebHistoryItemPrivate.h:
1087
1088         * WebCoreSupport/WebFrameBridge.mm:
1089         * WebCoreSupport/WebFrameLoaderClient.h:
1090         * WebCoreSupport/WebFrameLoaderClient.mm:
1091         (WebFrameLoaderClient::setDocumentViewFromPageCache):
1092         (WebFrameLoaderClient::detachedFromParent1):
1093         (WebFrameLoaderClient::loadedFromPageCache):
1094         (WebFrameLoaderClient::updateGlobalHistoryForStandardLoad):
1095         (WebFrameLoaderClient::updateGlobalHistoryForReload):
1096         (WebFrameLoaderClient::shouldGoToHistoryItem):
1097         (WebFrameLoaderClient::frameLoadCompleted):
1098         (WebFrameLoaderClient::saveScrollPositionAndViewStateToItem):
1099         (WebFrameLoaderClient::restoreScrollPositionAndViewState):
1100         (WebFrameLoaderClient::provisionalLoadStarted):
1101         (WebFrameLoaderClient::setTitle):
1102         (WebFrameLoaderClient::saveDocumentViewToPageCache):
1103         (WebFrameLoaderClient::canCachePage):
1104
1105         * WebCoreSupport/WebSystemInterface.m:
1106         (InitWebCoreSystemInterface):
1107
1108         * WebKit.xcodeproj/project.pbxproj:
1109
1110         * WebView/WebDataSource.mm:
1111         * WebView/WebDataSourceInternal.h:
1112
1113         * WebView/WebFrame.mm:
1114         (-[WebFramePrivate dealloc]):
1115         (-[WebFrame _canCachePage]):
1116         (-[WebFrame _loadURL:referrer:intoChild:]):
1117         * WebView/WebFrameInternal.h:
1118
1119         * WebView/WebFrameView.mm:
1120         (-[WebFrameView initWithFrame:]):
1121         (-[WebFrameView keyDown:]):
1122
1123         * WebView/WebHTMLView.m:
1124         (-[WebHTMLView closeIfNotCurrentView]): Added for a dirty hack in WebCore that is marked with a FIXME Radar
1125         * WebView/WebHTMLViewInternal.h:
1126
1127         * WebView/WebView.mm:
1128         (-[WebViewPrivate init]):
1129         (-[WebViewPrivate dealloc]):
1130         (-[WebView _close]):
1131         (-[WebView _loadBackForwardListFromOtherView:]):
1132         (-[WebView _commonInitializationWithFrameName:groupName:]):
1133         (-[WebView initWithCoder:]):
1134         (-[WebView backForwardList]):
1135         (-[WebView goBack]):
1136         (-[WebView goForward]):
1137         (-[WebView goToBackForwardItem:]):
1138         (-[WebView canGoBack]):
1139         (-[WebView canGoForward]):
1140
1141 2007-01-02  John Sullivan  <sullivan@apple.com>
1142
1143         Reviewed by Kevin Decker
1144
1145         - fixed <rdar://problem/4892525> Cannot open PDF in Preview if you attempted to 
1146           open it in Preview while PDF was loading
1147
1148         * WebView/WebPDFView.mm:
1149         (-[WebPDFView menuForEvent:]):
1150         added comment
1151         (-[WebPDFView validateUserInterfaceItem:]):
1152         disable this menu item when there's no document yet
1153         (-[WebPDFView _openWithFinder:]):
1154         If this is invoked when there is no document yet (e.g. via the PDFKit delegate method), 
1155         just beep and return. I should make a nice error message here, but I'll do that separately.
1156
1157 2007-01-03  Nikolas Zimmermann  <zimmermann@kde.org>
1158
1159         Reviewed by Timothy.
1160
1161         Fix inspection of RenderSVGInlineText objects (#text nodes in SVG documents).
1162
1163         * WebInspector/WebInspector.m:
1164         (-[WebInspector _highlightNode:]):
1165
1166 2007-01-02  Beth Dakin  <bdakin@apple.com>
1167
1168         Reviewed by Darin.
1169
1170         Fix bug with WebCore context menu item "Copy Image."
1171
1172         * WebCoreSupport/WebContextMenuClient.mm:
1173         (WebContextMenuClient::copyImageToClipboard): We must call 
1174         declareTypes on the pasteboard.
1175
1176 2006-12-27  Mitz Pettel  <mitz@webkit.org>
1177
1178         Reviewed by Geoff.
1179
1180         - fix http://bugs.webkit.org/show_bug.cgi?id=9403
1181           Red outline from Web Inspector appears above all other OS X windows
1182
1183         Made the window containing the highlight a child window of the window
1184         containing the view.
1185
1186         * WebInspector/WebNodeHighlight.m:
1187         (-[WebNodeHighlight initWithBounds:andRects:forView:]):
1188         (-[WebNodeHighlight dealloc]):
1189         (-[WebNodeHighlight expire]):
1190
1191 2006-12-27  Matt Lilek  <pewtermoose@gmail.com>
1192
1193         Reviewed by Tim H.
1194         
1195         Bug 11993: REGRESSION(r18320): Web Inspector scroll bars not drawn
1196         http://bugs.webkit.org/show_bug.cgi?id=11993
1197         
1198         AppleVerticalScrollbar tries to set a NaN value as the scroll height which
1199         causes DOM Exceptions after r18320.  This overrides the _setObjectLength
1200         method and checks for NaN until a system update can fix this.  See rdar://4901491
1201
1202         * WebInspector/webInspector/inspector.html:
1203         * WebInspector/webInspector/inspector.js:
1204
1205 2006-12-27  Geoffrey Garen  <ggaren@apple.com>
1206
1207         Reviewed by Oliver Hunt.
1208         
1209         Fixed <rdar://problem/4901629> Crash occurs at WebCore::Frame::page() 
1210         after closing window containing flash content
1211         
1212         No testcase because we can't open and close windows in DRT.
1213         
1214         I can't reproduce this crash, but from the backtrace it's clear that it 
1215         occured because of a NULL frame object. Since it's valid for a frame to
1216         be NULL, I've added NULL checks.
1217
1218         * Plugins/WebBaseNetscapePluginView.mm:
1219         (-[WebBaseNetscapePluginView sendEvent:]):
1220         (-[WebBaseNetscapePluginView requestWithURLCString:]):
1221         (-[WebBaseNetscapePluginView getVariable:value:]):
1222
1223 2006-12-27  Geoffrey Garen  <ggaren@apple.com>
1224
1225         Reviewed by Darin Adler.
1226         
1227         Updated <rdar://problem/4871518> fix based on Darin's comments.
1228
1229         Instead of searching the frame tree to retrieve the new frame, put it in
1230         a RefPtr, and then explicitly check for its removal. This option is slightly
1231         more efficient, and it avoids problems that can occur due to frame name collision.
1232         
1233         * WebCoreSupport/WebFrameBridge.mm:
1234         (-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
1235
1236 2006-12-26  Geoffrey Garen  <ggaren@apple.com>
1237
1238         Reviewed by Eric Seidel.
1239
1240         Fixed <rdar://problem/4740328> Safari crash on quit in _NPN_ReleaseObject 
1241         from KJS::Bindings::CInstance::~CInstance
1242         
1243         The essence of this change is that WebKit shouldn't meddle in plug-in
1244         lifetime, since WebCore already manages it. The rest is details.
1245         
1246         * Plugins/WebBaseNetscapePluginView.mm:
1247         (-[WebBaseNetscapePluginView removeTrackingRect]): Autorelease our window
1248         instead of releasing it, since we might hold the last reference to our window,
1249         and releasing it immediately would crash AppKit.
1250         (-[WebBaseNetscapePluginView resetTrackingRect]):
1251
1252         * Plugins/WebNetscapePluginEmbeddedView.h:
1253         * Plugins/WebNetscapePluginEmbeddedView.m:
1254         (-[WebNetscapePluginEmbeddedView dataSource]): Use our DOMElement to access
1255         our WebFrame, since we don't keep around a direct pointer to our WebFrame
1256         anymore.
1257
1258         * Plugins/WebNullPluginView.h:
1259         * Plugins/WebNullPluginView.m:
1260         (-[WebNullPluginView initWithFrame:error:DOMElement:]):
1261         (-[WebNullPluginView dealloc]):
1262         (-[WebNullPluginView viewDidMoveToWindow]): Use our DOMElement to access
1263         our WebFrame, as above.
1264
1265         * WebCoreSupport/WebFrameBridge.mm: Don't call _addPlugInView because it
1266         doesn't exist anymore. Do pass a DOMElement to WebNullPluginView's initializer,
1267         so it can access its frame like WebNetscapePluginEmbeddedView does.
1268         (-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
1269         (-[WebFrameBridge viewForJavaAppletWithFrame:attributeNames:attributeValues:baseURL:DOMElement:]):
1270
1271         * WebCoreSupport/WebFrameLoaderClient.h:
1272         * WebCoreSupport/WebFrameLoaderClient.mm: Removed didCloseDocument. It had
1273         two purposes -- one unnecessary, one harmful:
1274         (1) NULL out plug-ins' weak references to their frames. Unnecessary. Having 
1275         plug-ins access their frames through their DOM elements solves this problem.
1276         (2) Unload plug-ins. Harmful. If a plug-in unloads before WebCore is done
1277         with it, WebCore will access unmapped memory. Also unnecessary. WebCore
1278         Widgets take care of calling -removeFromSuperview on their NSViews, which
1279         is sufficient for stopping plug-ins.
1280
1281         * WebKit.xcodeproj/project.pbxproj: Made WebNullPluginView.m ObjC++.
1282
1283         * WebView/WebFrame.mm: Removed _addPlugInView, since it was only used to
1284         call -setWebFrame, which is gone.
1285         (-[WebFramePrivate dealloc]):
1286         * WebView/WebFrameInternal.h: Removed plugInViews, since it was only used
1287         by _addPlugInView, which is gone.
1288
1289 2006-12-26  Geoffrey Garen  <ggaren@apple.com>
1290
1291         Reviewed by Eric Seidel.
1292
1293         Some cleanup in preparation for fixing <rdar://problem/4740328> Safari 
1294         crash on quit in _NPN_ReleaseObject from KJS::Bindings::CInstance::~CInstance
1295         
1296         Renamed "installedPlugins" to "sharedDatabase." This better follows 
1297         the Cocoa naming scheme, and calls out the key attribute that produced this 
1298         crash -- namely, that the database is shared throughout the process.
1299         
1300         -installedPlugins is actually a part of SPI, but a global search showed
1301         that it had no users.
1302
1303         * Plugins/WebPluginDatabase.h:
1304         * Plugins/WebPluginDatabase.m:
1305         (+[WebPluginDatabase sharedDatabase]):
1306         (-[WebPluginDatabase refresh]):
1307         (-[WebPluginDatabase _plugInPaths]):
1308         (-[WebPluginDatabase _removePlugin:]):
1309         * WebCoreSupport/WebViewFactory.m:
1310         (-[WebViewFactory pluginsInfo]):
1311         (-[WebViewFactory refreshPlugins:]):
1312         (-[WebViewFactory pluginSupportsMIMEType:]):
1313         * WebView/WebView.mm:
1314         (+[WebView _supportedMIMETypes]):
1315         (+[WebView _viewClass:andRepresentationClass:forMIMEType:]):
1316         (-[WebView _close]):
1317         (-[WebView _pluginForMIMEType:]):
1318         (-[WebView _pluginForExtension:]):
1319         (-[WebView _isMIMETypeRegisteredAsPlugin:]):
1320
1321 2006-12-25  Geoffrey Garen  <ggaren@apple.com>
1322
1323         Reviewed by Adam Roben.
1324         
1325         Fixed <rdar://problem/4778898> REGRESSION: crash in getInstanceForView() 
1326         when quitting from kcbs.com
1327
1328         No testcase because we can't open and close windows in DRT.
1329
1330         The crash was caused by deallocating plug-ins that were later referenced
1331         in the unload event handler.
1332
1333         * Plugins/WebBaseNetscapePluginView.mm: Don't call stop on ourselves because
1334         we may destroy our plugin before the unload handler fires. Also, we don't
1335         need to, since didCloseDocument will do it for us.
1336
1337         (-[WebBaseNetscapePluginView addWindowObservers]): We don't need to listen
1338         for windowWillClose anymore, since we don't want to call -stop on ourselves.
1339         (-[WebBaseNetscapePluginView removeWindowObservers]): ditto.
1340
1341         * WebCoreSupport/WebFrameLoaderClient.h:
1342         * WebCoreSupport/WebFrameLoaderClient.mm:
1343         (WebFrameLoaderClient::didCloseDocument): Renamed from "willCloseDocument."
1344
1345 2006-12-25  Geoffrey Garen  <ggaren@apple.com>
1346
1347         More "plugin" => "pluginPackage" renaming that I forgot to check in.
1348         
1349         * Plugins/WebBaseNetscapePluginView.h:
1350         * Plugins/WebBaseNetscapePluginView.mm:
1351         (-[WebBaseNetscapePluginView setPluginPackage:]):
1352         * Plugins/WebNetscapePluginEmbeddedView.h:
1353         * Plugins/WebNetscapePluginEmbeddedView.m:
1354         (-[WebNetscapePluginEmbeddedView initWithFrame:pluginPackage:URL:baseURL:MIMEType:attributeKeys:attributeValues:loadManually:DOMElement:]):
1355         * WebCoreSupport/WebFrameBridge.mm:
1356         (-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
1357         (-[WebFrameBridge viewForJavaAppletWithFrame:attributeNames:attributeValues:baseURL:DOMElement:]):
1358
1359 2006-12-25  Geoffrey Garen  <ggaren@apple.com>
1360
1361         Reviewed by Eric Seidel.
1362         
1363         Fixed crash when opening view source window.
1364
1365         * WebView/WebView.mm:
1366         (-[WebView initWithCoder:]): Don't use the WebView until calling
1367         _commonInitialization...
1368
1369 2006-12-25  Geoffrey Garen  <ggaren@apple.com>
1370
1371         Reviewed by Oliver Hunt.
1372         
1373         Removed WebCoreSettings, cleaned up WebCore::Settings.
1374
1375         * WebView/WebFrame.mm: Added helper functions for converting between
1376         WebKitEditableLinkBehavior and WebCore::EditableLinkBehavior. I'm not sure
1377         that this is the best place for these functions, but it's where all the
1378         other functions like them reside.
1379         (core):
1380         (kit):
1381         * WebView/WebFrameInternal.h:
1382
1383         * WebView/WebView.mm: Removed uses of WebCoreSettings. Replaced with direct
1384         use of underlying page's settings.
1385
1386 2006-12-25  Geoffrey Garen  <ggaren@apple.com>
1387
1388         Reviewed by Oliver Hunt.
1389         
1390         Some refactoring in preparation for fixing <rdar://problem/4778898> 
1391         REGRESSION: crash in getInstanceForView() when quitting from kcbs.com
1392         
1393         Two renames:
1394             - "plugin" => "pluginPackage" (since the type is WebNetscapePluginPackage *)
1395             - "instance" and/or "pluginPointer" => plugin (since NPP is an opaque handle to a plug-in)
1396         
1397         Removed braces around single-line 'if' statements.
1398         
1399         Made plugin a pointer instead of an inline ivar. This allows us to NULL
1400         it out once we call NPP_Destroy on it.
1401         
1402         Added helper functions for creating and destroying plugin. The destroy function
1403         NULLs out plugin, which helps with debugging.
1404             
1405         (-[WebBaseNetscapePluginView willCallPlugInFunction]): Added an ASSERT
1406         to catch attempts to call functions on destroyed plug-ins.
1407
1408         (-[WebBaseNetscapePluginView _createPlugin]): New helper function.
1409         (-[WebBaseNetscapePluginView _destroyPlugin]): New helper function.
1410
1411 2006-12-24  David Kilzer  <ddkilzer@webkit.org>
1412
1413         Removed empty directory.
1414
1415         * WebKit/Loader: Removed.
1416
1417 2006-12-22  Geoffrey Garen  <ggaren@apple.com>
1418
1419         Reviewed by Brady Eidson.
1420         
1421         Fixed <rdar://problem/4871518> Leopard9A321: Crash visiting www.audible.com 
1422         (WebCore::FrameLoader::loadSubframe)
1423
1424         * WebCoreSupport/WebFrameBridge.mm:
1425         (-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
1426         - The fix: 
1427             Changed to re-fetch the child frame we're trying to load before returning it,
1428             since its onload handler may have removed it from the document. This
1429             allows us to treat a removed frame like a frame that never loaded.
1430         
1431         - Plus some cleanup:
1432             - Changed to return a WebCore::Frame* instead of a WebFrameBridge *,
1433             to simplify some code.
1434             - Grouped ObjC objects by usage, and moved calls to -release so that they
1435             immediately follow the calls that retain.
1436
1437 2006-12-21  John Sullivan  <sullivan@apple.com>
1438
1439         Reviewed by Geoff Garen
1440
1441         - improved concept and implementation of my previous checkin after discussing with Darin
1442
1443         * WebView/WebViewPrivate.h:
1444         * WebView/WebView.mm:
1445         (-[WebView setHoverFeedbackSuspended:]):
1446         renamed from setIgnoresMouseMovedEvents, and now tells the main WebHTMLView (if any) that this state has
1447         changed. Telling just the main WebHTMLView is a bit of an implementation hack. Hopefully someday we can
1448         rework the document architecture and make this kind of thing less hacky (but this is following existing
1449         customs, so I don't feel too bad)
1450         (-[WebView isHoverFeedbackSuspended]):
1451         renamed from ignoresMouseMovedEvents
1452
1453         * WebView/WebHTMLViewInternal.h:
1454         declare _hoverFeedbackSuspendedChanged
1455
1456         * WebView/WebHTMLView.m:
1457         (-[WebHTMLView _updateMouseoverWithEvent:]):
1458         test the webView's state of the hit-tested WebHTMLView rather than self 
1459         (-[WebHTMLView _hoverFeedbackSuspendedChanged]):
1460         generate a fake mouse-moved event, which simulates the mouse moving away from
1461         the current element or back over it
1462
1463 2006-12-21  Darin Adler  <darin@apple.com>
1464
1465         Reviewed by Oliver.
1466
1467         * WebInspector/webInspector/inspector.js: Added default values for the new CSS
1468         properties so they don't appear in the inspector when their values are
1469         uninteresting.
1470
1471 2006-12-21  John Sullivan  <sullivan@apple.com>
1472
1473         Reviewed by Geoff Garen
1474
1475         - added WebKit support for making a web page temporarily ignore mouse movements
1476
1477         * WebView/WebViewPrivate.h:
1478         declare ignoresMouseMovedEvents and setIgnoresMouseMovedEvents:
1479
1480         * WebView/WebView.mm:
1481         added ignoresMouseMovedEvents boolean field to _private data structure
1482         (-[WebView setIgnoresMouseMovedEvents:]):
1483         set new boolean field
1484         (-[WebView ignoresMouseMovedEvents]):
1485         return new boolean field
1486
1487         * WebView/WebHTMLView.m:
1488         (-[WebHTMLView _updateMouseoverWithEvent:]):
1489         bail out right away if [[self _webView] ignoresMouseMovedEvents]
1490
1491 2006-12-21  Mark Rowe  <bdash@webkit.org>
1492
1493         Reviewed by Geoff.
1494
1495         http://bugs.webkit.org/show_bug.cgi?id=11888
1496         Bug 11888: REGRESSION (r18320): Web Inspector panes broken
1497
1498         * WebInspector/webInspector/inspector.js: Use removeProperty to reset a style property to its
1499         initial value.  Bail out early from updateNodePane if Inspector has not yet been set.
1500
1501 2006-12-19  John Sullivan  <sullivan@apple.com>
1502
1503         Reviewed by Darin
1504
1505         - fix for unrepro infinite recursion bug:
1506         <rdar://problem/4448181> CrashTracer: 154 crashes in Safari at com.apple.AppKit: 
1507         -[NSView isDescendantOf:] + 24; infinite recursion in makeFirstResponder logic
1508
1509         * WebView/WebView.mm:
1510         added becomingFirstResponder BOOL to private struct
1511         (-[WebView becomeFirstResponder]):
1512         use _private->becomingFirstResponder to guard against infinite recursion; complain on
1513         debug builds if we run into this problem
1514
1515 2006-12-19  Timothy Hatcher  <timothy@apple.com>
1516
1517         Reviewed by Darin.
1518
1519         <rdar://problem/4891774> Local WebCore/WebBrowser builds fail in 9A328 due to warning about ObjC-2.0 language features
1520
1521         * WebKit.xcodeproj/project.pbxproj:
1522
1523 2006-12-18  Ada Chan  <adachan@apple.com>
1524
1525         Reviewed by Adam.
1526         
1527         Moved canRunBeforeUnloadConfirmPanel, runBeforeUnloadConfirmPanel, and closeWindowSoon
1528         from WebCoreFrameBridge to Chrome.
1529
1530         * COM/ChromeClientWin.cpp:
1531         (ChromeClientWin::canRunBeforeUnloadConfirmPanel):
1532         (ChromeClientWin::runBeforeUnloadConfirmPanel):
1533         (ChromeClientWin::closeWindowSoon):
1534         * COM/ChromeClientWin.h:
1535         * WebCoreSupport/WebChromeClient.h:
1536         * WebCoreSupport/WebChromeClient.mm:
1537         (WebChromeClient::canRunBeforeUnloadConfirmPanel):
1538         (WebChromeClient::runBeforeUnloadConfirmPanel):
1539         (WebChromeClient::closeWindowSoon):
1540         * WebCoreSupport/WebFrameBridge.mm:
1541
1542 2006-12-18  Alice Liu  <alice.liu@apple.com>
1543
1544         Reviewed by Adam.
1545
1546         Have the Editor handle deletion instead of WebHTMLView
1547
1548         * WebKitPrefix.h:
1549         Turned on WebCore deletion
1550
1551         * WebView/WebHTMLViewInternal.h:
1552         Moved ownership of startNewKillRingSequence to the WebCore::Editor
1553
1554         * WebView/WebHTMLView.m:
1555         (-[NSArray becomeFirstResponder]):
1556         Use the Editor's startNewKillRingSequence flag
1557
1558         (-[NSArray deleteForward:]):
1559         (-[NSArray deleteBackward:]):
1560         (-[NSArray deleteWordForward:]):
1561         (-[NSArray deleteWordBackward:]):
1562         (-[NSArray deleteToBeginningOfLine:]):
1563         (-[NSArray deleteToEndOfLine:]):
1564         (-[NSArray deleteToBeginningOfParagraph:]):
1565         (-[NSArray deleteToEndOfParagraph:]):
1566         (-[NSArray deleteToMark:]):
1567         use Editor::deleteWithDirection instead of WebHTMLView's
1568
1569 2006-12-16  Adele Peterson  <adele@apple.com>
1570
1571         Reviewed by Adam.
1572
1573         WebKit part of fix for:
1574         <rdar://problem/4463829> Switch to use new search field implementation for <input type="search">
1575
1576         * WebCoreSupport/WebSystemInterface.m: (InitWebCoreSystemInterface): Initialize WKDrawTextFieldCellFocusRing.
1577         * WebInspector/webInspector/inspector.css: Set -webkit-user-select:text and text-shadow:none on the search field.
1578           These are both properties that we didn't honor in the old control, and the inherited values didn't work or look right.
1579
1580 2006-12-16  Beth Dakin  <bdakin@apple.com>
1581
1582         Reviewed by Adam.
1583
1584         WebKit side of making WebCore context menus support state and
1585         enabled/disabled.
1586
1587         * WebCoreSupport/WebContextMenuClient.h: contextMenuItemSelected
1588         takes a pointer to the parentMenu now since menu items no longer
1589         hold onto it.
1590         * WebCoreSupport/WebContextMenuClient.mm: Same.
1591         (WebContextMenuClient::contextMenuItemSelected): Same.
1592         * WebView/WebHTMLView.m: Must call setAutoenablesItems:NO on our
1593         menu.
1594         (-[NSArray menuForEvent:]):
1595         * WebView/WebUIDelegatePrivate.h: No need for if-def.
1596
1597 2006-12-15  Anders Carlsson  <acarlsson@apple.com>
1598
1599         Reviewed by Geoff.
1600
1601         Update for WebCore changes.
1602         
1603         * WebCoreSupport/WebFrameLoaderClient.h:
1604         * WebCoreSupport/WebFrameLoaderClient.mm:
1605         (WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
1606         * WebView/WebDataSource.mm:
1607         (-[WebDataSource response]):
1608
1609 2006-12-15  Anders Carlsson  <acarlsson@apple.com>
1610
1611         Reviewed by Darin.
1612
1613         Update for WebCore changes.
1614         
1615         * WebCoreSupport/WebFrameLoaderClient.h:
1616         * WebCoreSupport/WebFrameLoaderClient.mm:
1617         (WebFrameLoaderClient::willUseArchive):
1618         * WebView/WebDataSource.mm:
1619         (-[WebDataSource _URLForHistory]):
1620
1621 2006-12-15  Marvin Decker  <marv.decker@gmail.com>
1622
1623         Reviewed by Darin and Alexey.
1624
1625         Fix the Windows build, move various Client implementations out of
1626         WebCore and into WebKit.
1627
1628         * COM/ChromeClientWin.cpp: Added.
1629         (ChromeClientWin::~ChromeClientWin):
1630         (ChromeClientWin::chromeDestroyed):
1631         (ChromeClientWin::setWindowRect):
1632         (ChromeClientWin::windowRect):
1633         (ChromeClientWin::pageRect):
1634         (ChromeClientWin::scaleFactor):
1635         (ChromeClientWin::focus):
1636         (ChromeClientWin::unfocus):
1637         (ChromeClientWin::createWindow):
1638         (ChromeClientWin::createModalDialog):
1639         (ChromeClientWin::show):
1640         (ChromeClientWin::canRunModal):
1641         (ChromeClientWin::runModal):
1642         (ChromeClientWin::setToolbarsVisible):
1643         (ChromeClientWin::toolbarsVisible):
1644         (ChromeClientWin::setStatusbarVisible):
1645         (ChromeClientWin::statusbarVisible):
1646         (ChromeClientWin::setScrollbarsVisible):
1647         (ChromeClientWin::scrollbarsVisible):
1648         (ChromeClientWin::setMenubarVisible):
1649         (ChromeClientWin::menubarVisible):
1650         (ChromeClientWin::setResizable):
1651         (ChromeClientWin::addMessageToConsole):
1652         * COM/ChromeClientWin.h: Added.
1653         * COM/ContextMenuClientWin.cpp: Added.
1654         (ContextMenuClientWin::~ContextMenuClientWin):
1655         (ContextMenuClientWin::contextMenuDestroyed):
1656         (ContextMenuClientWin::addCustomContextMenuItems):
1657         (ContextMenuClientWin::contextMenuItemSelected):
1658         (ContextMenuClientWin::copyLinkToClipboard):
1659         (ContextMenuClientWin::downloadURL):
1660         (ContextMenuClientWin::copyImageToClipboard):
1661         (ContextMenuClientWin::lookUpInDictionary):
1662         (ContextMenuClientWin::speak):
1663         (ContextMenuClientWin::stopSpeaking):
1664         * COM/ContextMenuClientWin.h: Added.
1665         * COM/EditorClientWin.cpp: Added.
1666         (EditorClientWin::~EditorClientWin):
1667         (EditorClientWin::pageDestroyed):
1668         (EditorClientWin::shouldDeleteRange):
1669         (EditorClientWin::shouldShowDeleteInterface):
1670         (EditorClientWin::smartInsertDeleteEnabled):
1671         (EditorClientWin::isContinuousSpellCheckingEnabled):
1672         (EditorClientWin::toggleContinuousSpellChecking):
1673         (EditorClientWin::isGrammarCheckingEnabled):
1674         (EditorClientWin::toggleGrammarChecking):
1675         (EditorClientWin::spellCheckerDocumentTag):
1676         (EditorClientWin::selectWordBeforeMenuEvent):
1677         (EditorClientWin::isEditable):
1678         (EditorClientWin::shouldBeginEditing):
1679         (EditorClientWin::shouldEndEditing):
1680         (EditorClientWin::shouldInsertNode):
1681         (EditorClientWin::shouldInsertText):
1682         (EditorClientWin::shouldApplyStyle):
1683         (EditorClientWin::didBeginEditing):
1684         (EditorClientWin::respondToChangedContents):
1685         (EditorClientWin::didEndEditing):
1686         (EditorClientWin::registerCommandForUndo):
1687         (EditorClientWin::registerCommandForRedo):
1688         (EditorClientWin::clearUndoRedoOperations):
1689         (EditorClientWin::canUndo):
1690         (EditorClientWin::canRedo):
1691         (EditorClientWin::undo):
1692         (EditorClientWin::redo):
1693         * COM/EditorClientWin.h: Added.
1694         * COM/WebFrame.cpp:
1695         (WebFrame::WebFrame):
1696         (WebFrame::initWithName):
1697         * COM/WebFrame.h:
1698         * COM/WebFrameLoaderClient.cpp: Added.
1699         (WebFrameLoaderClient::WebFrameLoaderClient):
1700         (WebFrameLoaderClient::~WebFrameLoaderClient):
1701         (WebFrameLoaderClient::frameLoaderDestroyed):
1702         (WebFrameLoaderClient::hasWebView):
1703         (WebFrameLoaderClient::hasFrameView):
1704         (WebFrameLoaderClient::hasBackForwardList):
1705         (WebFrameLoaderClient::resetBackForwardList):
1706         (WebFrameLoaderClient::provisionalItemIsTarget):
1707         (WebFrameLoaderClient::loadProvisionalItemFromPageCache):
1708         (WebFrameLoaderClient::invalidateCurrentItemPageCache):
1709         (WebFrameLoaderClient::privateBrowsingEnabled):
1710         (WebFrameLoaderClient::makeDocumentView):
1711         (WebFrameLoaderClient::makeRepresentation):
1712         (WebFrameLoaderClient::forceLayout):
1713         (WebFrameLoaderClient::forceLayoutForNonHTML):
1714         (WebFrameLoaderClient::updateHistoryForCommit):
1715         (WebFrameLoaderClient::updateHistoryForBackForwardNavigation):
1716         (WebFrameLoaderClient::updateHistoryForReload):
1717         (WebFrameLoaderClient::updateHistoryForStandardLoad):
1718         (WebFrameLoaderClient::updateHistoryForInternalLoad):
1719         (WebFrameLoaderClient::updateHistoryAfterClientRedirect):
1720         (WebFrameLoaderClient::setCopiesOnScroll):
1721         (WebFrameLoaderClient::tokenForLoadErrorReset):
1722         (WebFrameLoaderClient::resetAfterLoadError):
1723         (WebFrameLoaderClient::doNotResetAfterLoadError):
1724         (WebFrameLoaderClient::willCloseDocument):
1725         (WebFrameLoaderClient::detachedFromParent1):
1726         (WebFrameLoaderClient::detachedFromParent2):
1727         (WebFrameLoaderClient::detachedFromParent3):
1728         (WebFrameLoaderClient::detachedFromParent4):
1729         (WebFrameLoaderClient::loadedFromPageCache):
1730         (WebFrameLoaderClient::dispatchDidHandleOnloadEvents):
1731         (WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
1732         (WebFrameLoaderClient::dispatchDidCancelClientRedirect):
1733         (WebFrameLoaderClient::dispatchWillPerformClientRedirect):
1734         (WebFrameLoaderClient::dispatchDidChangeLocationWithinPage):
1735         (WebFrameLoaderClient::dispatchWillClose):
1736         (WebFrameLoaderClient::dispatchDidReceiveIcon):
1737         (WebFrameLoaderClient::dispatchDidStartProvisionalLoad):
1738         (WebFrameLoaderClient::dispatchDidReceiveTitle):
1739         (WebFrameLoaderClient::dispatchDidCommitLoad):
1740         (WebFrameLoaderClient::dispatchDidFinishLoad):
1741         (WebFrameLoaderClient::dispatchDidFirstLayout):
1742         (WebFrameLoaderClient::dispatchShow):
1743         (WebFrameLoaderClient::cancelPolicyCheck):
1744         (WebFrameLoaderClient::dispatchWillSubmitForm):
1745         (WebFrameLoaderClient::dispatchDidLoadMainResource):
1746         (WebFrameLoaderClient::clearLoadingFromPageCache):
1747         (WebFrameLoaderClient::isLoadingFromPageCache):
1748         (WebFrameLoaderClient::revertToProvisionalState):
1749         (WebFrameLoaderClient::clearUnarchivingState):
1750         (WebFrameLoaderClient::progressStarted):
1751         (WebFrameLoaderClient::progressCompleted):
1752         (WebFrameLoaderClient::setMainFrameDocumentReady):
1753         (WebFrameLoaderClient::willChangeTitle):
1754         (WebFrameLoaderClient::didChangeTitle):
1755         (WebFrameLoaderClient::finishedLoading):
1756         (WebFrameLoaderClient::finalSetupForReplace):
1757         (WebFrameLoaderClient::setDefersLoading):
1758         (WebFrameLoaderClient::isArchiveLoadPending):
1759         (WebFrameLoaderClient::cancelPendingArchiveLoad):
1760         (WebFrameLoaderClient::clearArchivedResources):
1761         (WebFrameLoaderClient::canHandleRequest):
1762         (WebFrameLoaderClient::canShowMIMEType):
1763         (WebFrameLoaderClient::representationExistsForURLScheme):
1764         (WebFrameLoaderClient::generatedMIMETypeForURLScheme):
1765         (WebFrameLoaderClient::frameLoadCompleted):
1766         (WebFrameLoaderClient::restoreScrollPositionAndViewState):
1767         (WebFrameLoaderClient::provisionalLoadStarted):
1768         (WebFrameLoaderClient::shouldTreatURLAsSameAsCurrent):
1769         (WebFrameLoaderClient::addHistoryItemForFragmentScroll):
1770         (WebFrameLoaderClient::didFinishLoad):
1771         (WebFrameLoaderClient::prepareForDataSourceReplacement):
1772         (WebFrameLoaderClient::setTitle):
1773         (WebFrameLoaderClient::userAgent):
1774         * COM/WebFrameLoaderClient.h: Added.
1775         * COM/WebKitDLL.h:
1776         * WebKit.vcproj/WebKit.vcproj:
1777
1778 2006-12-15  Anders Carlsson  <acarlsson@apple.com>
1779
1780         Reviewed by Darin.
1781
1782         Include ResourceError.h.
1783         
1784         * Plugins/WebNetscapePluginStream.mm:
1785         * WebKit.xcodeproj/project.pbxproj:
1786
1787 2006-12-14  Anders Carlsson  <acarlsson@apple.com>
1788
1789         Reviewed by Maciej.
1790
1791         Update for WebCore changes.
1792         
1793         * WebCoreSupport/WebFrameLoaderClient.h:
1794         * WebCoreSupport/WebFrameLoaderClient.mm:
1795         (WebFrameLoaderClient::incrementProgress):
1796         (WebFrameLoaderClient::committedLoad):
1797         (WebFrameLoaderClient::deliverArchivedResources):
1798         * WebView/WebView.mm:
1799         (-[WebView _incrementProgressForIdentifier:length:]):
1800         * WebView/WebViewInternal.h:
1801
1802 2006-12-14  Timothy Hatcher  <timothy@apple.com>
1803
1804         Reviewed by Darin.
1805
1806         <rdar://problem/4827549> need NSRange-based selection support exposed.
1807
1808         * WebView/WebFrame.mm:
1809         (-[WebFrame _selectedNSRange]):
1810         (-[WebFrame _selectNSRange:]):
1811         * WebView/WebFramePrivate.h:
1812
1813 2006-12-14  Anders Carlsson  <acarlsson@apple.com>
1814
1815         Reviewed by John.
1816
1817         Update for WebCore changes.
1818         
1819         * WebCoreSupport/WebFrameLoaderClient.h:
1820         * WebCoreSupport/WebFrameLoaderClient.mm:
1821         (WebFrameLoaderClient::dispatchDidFailLoading):
1822         (WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
1823         (WebFrameLoaderClient::dispatchDidFailLoad):
1824         (WebFrameLoaderClient::dispatchUnableToImplementPolicy):
1825         (WebFrameLoaderClient::setMainDocumentError):
1826         (WebFrameLoaderClient::cancelledError):
1827         (WebFrameLoaderClient::cannotShowURLError):
1828         (WebFrameLoaderClient::interruptForPolicyChangeError):
1829         (WebFrameLoaderClient::cannotShowMIMETypeError):
1830         (WebFrameLoaderClient::fileDoesNotExistError):
1831         (WebFrameLoaderClient::shouldFallBack):
1832
1833 2006-12-13  Maciej Stachowiak  <mjs@apple.com>
1834
1835         Reviewed by Anders.
1836         
1837         - adjusted for changes from NSURLRequest to ResourceRequest
1838
1839         * Plugins/WebPluginController.mm:
1840         * WebCoreSupport/WebFrameLoaderClient.h:
1841         * WebCoreSupport/WebFrameLoaderClient.mm:
1842         (WebFrameLoaderClient::updateHistoryForReload):
1843         (WebFrameLoaderClient::dispatchIdentifierForInitialRequest):
1844         (WebFrameLoaderClient::dispatchDecidePolicyForMIMEType):
1845         (WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
1846         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
1847         (WebFrameLoaderClient::startDownload):
1848         (WebFrameLoaderClient::cannotShowURLError):
1849         (WebFrameLoaderClient::createDocumentLoader):
1850         * WebView/WebDataSource.mm:
1851         (-[WebDataSource _initWithDocumentLoader:]):
1852         (-[WebDataSource initialRequest]):
1853         (-[WebDataSource request]):
1854         * WebView/WebDocumentLoaderMac.h:
1855         * WebView/WebDocumentLoaderMac.mm:
1856         (WebDocumentLoaderMac::WebDocumentLoaderMac):
1857         * WebView/WebFrame.mm:
1858         (-[WebFrame _createItem:]):
1859         (-[WebFrame _loadItem:withLoadType:]):
1860         (-[WebFrame loadArchive:]):
1861
1862 2006-12-12  Anders Carlsson  <acarlsson@apple.com>
1863
1864         Reviewed by Darin.
1865
1866         * WebCoreSupport/WebFrameLoaderClient.h:
1867         * WebCoreSupport/WebFrameLoaderClient.mm:
1868         (WebFrameLoaderClient::download):
1869         Get the handle and proxy from the ResourceHandle now that they aren't passed to us.
1870         
1871 2006-12-11  Darin Adler  <darin@apple.com>
1872
1873         Reviewed by Brady.
1874
1875         - did some of the Mac-specific file moves mentioned in my recent mail to the WebKit list
1876
1877         * WebCoreSupport/WebFrameBridge.h: Updated for change to WebCoreKeyboardAccess.
1878         * WebCoreSupport/WebFrameBridge.mm:
1879         (-[WebFrameBridge _retrieveKeyboardUIModeFromPreferences:]): Ditto.
1880         (-[WebFrameBridge keyboardUIMode]): Ditto.
1881
1882 2006-12-11  Beth Dakin  <bdakin@apple.com>
1883
1884         Reviewed by Adam.
1885
1886         WebKit support for editing sub-menu actions.
1887
1888         * WebCoreSupport/WebContextMenuClient.h: New functions for the
1889         speech sub-menu.
1890         * WebCoreSupport/WebContextMenuClient.mm:
1891         (WebContextMenuClient::speak):
1892         (WebContextMenuClient::stopSpeaking):
1893         * WebCoreSupport/WebEditorClient.h: New functions to toggle
1894         spelling/grammar checking.
1895         * WebCoreSupport/WebEditorClient.mm:
1896         (WebEditorClient::toggleContinuousSpellChecking):
1897         (WebEditorClient::toggleGrammarChecking):
1898         * WebView/WebUIDelegatePrivate.h: Re-named some of the spelling
1899         sub-menu tags.
1900
1901 2006-12-11  Alice Liu  <alice.liu@apple.com>
1902
1903         Reviewed by Geoff, Adam.
1904         
1905         switch to use the Editor for copying URLs
1906
1907         * DefaultDelegates/WebDefaultContextMenuDelegate.m:
1908         (-[WebDefaultUIDelegate copyLinkToClipboard:]):
1909         Call down to the editor for this. 
1910         * WebCoreSupport/WebSystemInterface.m:
1911         (InitWebCoreSystemInterface):
1912         Add some calls necessary for Pasteboard::writeURL to work
1913
1914 2006-12-11  Darin Adler  <darin@apple.com>
1915
1916         Reviewed by Brady.
1917
1918         - http://bugs.webkit.org/show_bug.cgi?id=11794
1919           fix lifetime problems affecting Frame's ownerElement pointer
1920
1921         * WebCoreSupport/WebFrameBridge.mm:
1922         (-[WebFrameBridge finishInitializingWithPage:WebCore::frameName:frameView:ownerElement:]):
1923         (-[WebFrameBridge initSubframeWithOwnerElement:frameName:frameView:]):
1924         (-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
1925         Use HTMLFrameOwnerElement.
1926
1927         * WebCoreSupport/WebFrameLoaderClient.mm: Include the relevant headers for the
1928         HTMLFormElement class.
1929
1930         * WebKit.xcodeproj/project.pbxproj: Let Xcode have its way.
1931
1932         * WebView/WebFrame.mm: (-[WebFrame frameElement]): Update includes and types for the
1933         change in return type of ownerElement.
1934
1935 2006-12-11  David Harrison  <harrison@apple.com>
1936
1937         Fix previous checkin where I committed the wrong file.
1938
1939         <rdar://problem/4863611> Xyle Scope crashes at launch due to WebCore-521.29.3
1940
1941         * WebView/WebFrame.mm:
1942         (-[WebFrame frameElement]):
1943         Add nil check.
1944         
1945         * WebView/WebPreferences.m:
1946         (-[WebPreferences editableLinkBehavior]):
1947         Reverted to previous.
1948
1949 2006-12-08  David Hyatt  <hyatt@apple.com>
1950
1951         Land new ICU abstraction layer.  Patch by Lars.
1952
1953         Reviewed by me
1954
1955         * ForwardingHeaders/wtf/icu/UnicodeIcu.h: Added.
1956         * ForwardingHeaders/wtf/unicode/Unicode.h: Added.
1957         * WebKit.xcodeproj/project.pbxproj:
1958
1959 === Safari-521.32 ===
1960
1961 2006-12-08  Timothy Hatcher  <timothy@apple.com>
1962
1963         Rolling out a change that broke Mail stationary.
1964         <rdar://problem/4699166> REGRESSION: Background images in Mail stationery do not load
1965
1966         * WebView/WebUnarchivingState.m:
1967         (-[WebUnarchivingState archivedResourceForURL:]):
1968
1969 2006-12-08  Don Gibson  <dgibson77@gmail.com>
1970
1971         Reviewed and landed by Alexey.
1972
1973         http://bugs.webkit.org/show_bug.cgi?id=11759:
1974         Windows build bustage
1975
1976         * COM/WebFrame.cpp:
1977         (WebFrame::loadDataSource):
1978         * COM/WebFrame.h:
1979
1980 2006-12-08  David Harrison  <harrison@apple.com>
1981
1982         Reviewed by Brady.
1983
1984         <rdar://problem/4863611> Xyle Scope crashes at launch due to WebCore-521.29.3
1985
1986         * WebView/WebPreferences.m:
1987         (-[WebPreferences editableLinkBehavior]):
1988         Add nil check.
1989
1990 2006-12-07  Beth Dakin  <bdakin@apple.com>
1991
1992         Reviewed by Brady.
1993
1994         Build fix for WebCore ContextMenus. It got broken by r18046.
1995
1996         * WebView/WebHTMLView.m:
1997         (-[NSArray menuForEvent:]):
1998
1999 2006-12-07  Beth Dakin  <bdakin@apple.com>
2000
2001         Reviewed by Brady.
2002
2003         Make some parameters const and const references.
2004
2005         * WebCoreSupport/WebContextMenuClient.h:
2006         * WebCoreSupport/WebContextMenuClient.mm:
2007         (WebContextMenuClient::contextMenuItemSelected):
2008         (WebContextMenuClient::copyLinkToClipboard):
2009         (WebContextMenuClient::downloadURL):
2010         (WebContextMenuClient::copyImageToClipboard):
2011
2012 2006-12-06  Brady Eidson  <beidson@apple.com>
2013
2014         Reviewed by John Sullivan
2015
2016         Fixes http://bugs.webkit.org/show_bug.cgi?id=11675 and <rdar://4857669>
2017         Now we need to explicitly set the data source when loading from a page cache
2018
2019         * History/WebHistoryItem.mm:
2020         (-[WebHistoryItem _scheduleRelease]): Enhanced a logging message
2021         (+[WebHistoryItem _releasePageCache:]): Ditto
2022         (+[WebHistoryItem _releaseAllPendingPageCaches]): Ditto
2023         * WebCoreSupport/WebFrameLoaderClient.mm:
2024         (WebFrameLoaderClient::setDocumentViewFromPageCache): Reset the View's DataSource from the cache, effectively reopening it
2025         * WebView/WebHTMLView.m:
2026         (-[NSArray setDataSource:]): Properly Handle resetting the DataSource and "reopening" the view
2027
2028 2006-12-06  Brady Eidson  <beidson@apple.com>
2029
2030         Reviewed by Adam and Oliver
2031
2032         While working on http://bugs.webkit.org/show_bug.cgi?id=11675 I
2033         decided to fix much of the null-deref problems that creeped in via 
2034         the loader refactoring.  This isn't changing behavior, just reintroducing
2035         the free nil checking we used to have with pure ObjC
2036
2037         * WebView/WebHTMLView.m:
2038         (-[NSArray menuForEvent:]):  Explicitly check for null frames
2039         (-[NSArray mouseDown:]):  Ditto
2040         (-[NSArray mouseDragged:]):  Ditto
2041         (-[NSArray mouseUp:]):  Ditto
2042         (-[NSArray performKeyEquivalent:]):  Ditto
2043         (-[WebHTMLView elementAtPoint:allowShadowContent:]):  Ditto
2044
2045 2006-12-05  John Sullivan  <sullivan@apple.com>
2046
2047         Reviewed by Beth
2048
2049         Updated to match Frame -> Editor changes in WebCore
2050
2051         * DefaultDelegates/WebDefaultContextMenuDelegate.m:
2052         (-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
2053         guessesForUngrammaticalSelection() is now in Editor
2054
2055         * WebView/WebHTMLView.m:
2056         (-[WebHTMLView _isSelectionUngrammatical]):
2057         isSelectionUngrammatical() is now in Editor
2058         (-[WebHTMLView _isSelectionMisspelled]):
2059         isSelectionMisspelled() is now in Editor
2060
2061         (-[WebHTMLView checkSpelling:]):
2062         advanceToNextMisspelling() is now in Editor
2063         (-[WebHTMLView showGuessPanel:]):
2064         ditto
2065
2066 2006-12-05  John Sullivan  <sullivan@apple.com>
2067
2068         Reviewed by Adam
2069         
2070         Old context-menu mechanism fix for:
2071         <rdar://problem/4864351> Should leave out "No Guesses Found" from context menu for bad grammar
2072
2073         * DefaultDelegates/WebDefaultContextMenuDelegate.m:
2074         (-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
2075         Leave out "No Guesses Found" and separator for grammar-checking case.
2076
2077 2006-12-05  John Sullivan  <sullivan@apple.com>
2078
2079         build fix
2080
2081         * WebView/WebViewPrivate.h:
2082         * WebView/WebView.mm:
2083         (-[WebView isGrammarCheckingEnabled]):
2084         define isGrammarCheckingEnabled whether on Tiger or not (just return NO on Tiger)
2085
2086 2006-12-04  John Sullivan  <sullivan@apple.com>
2087
2088         Reviewed by Darin
2089
2090         WebKit part of fix for:
2091         <rdar://problem/4817188> Context menu for bad grammar should include suggestions and "Ignore Grammar"
2092
2093         The context menu mechanism is currently in flux; the old mechanism is still in place, but an
2094         up-and-coming new mechanism is waiting in the wings. I updated both of them, but couldn't
2095         test the new mechanism because it doesn't work well enough yet. Most of this WebKit code
2096         can be deleted when the new mechanism is in place.
2097
2098         * WebView/WebUIDelegatePrivate.h:
2099         added WebMenuItemTagIgnoreGrammar
2100
2101         * DefaultDelegates/WebDefaultContextMenuDelegate.m:
2102         (-[WebDefaultUIDelegate menuItemWithTag:target:representedObject:]):
2103         added case for WebMenuItemTagIgnoreGrammar
2104         (-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
2105         now considers adding grammar-related items as well as spelling-related items
2106         
2107         * WebView/WebHTMLViewPrivate.h:
2108         declared _isSelectionUngrammatical
2109
2110         * WebView/WebHTMLView.m:
2111         (-[WebHTMLView _isSelectionUngrammatical]):
2112         new method, calls through to WebCore
2113         (-[WebHTMLView _ignoreGrammarFromMenu:]):
2114         new method, calls _ignoreSpellingFromMenu: since NSSpellChecker has one method for both
2115
2116         * English.lproj/Localizable.strings:
2117         updated for "Ignore Grammar" menu item title
2118
2119 2006-12-04  Darin Adler  <darin@apple.com>
2120
2121         Reviewed by Adele.
2122
2123         * WebCoreSupport/WebFrameLoaderClient.mm:
2124         (WebFrameLoaderClient::actionDictionary): Changed to use the new
2125         findEventWithKeyState function in WebCore instead of a local function
2126         in this file.
2127
2128 2006-12-04  Geoffrey Garen  <ggaren@apple.com>
2129
2130         Rolled out the WebDashboardBehaviorUseBackwardCompatibilityModeEnabled
2131         part of my last checkin.
2132         
2133         We have to turn on support for backward compatibility mode to avoid Dashboard
2134         regressions in the short term.
2135
2136         * WebView/WebView.mm:
2137         (-[WebView _setDashboardBehavior:to:]):
2138
2139 2006-12-02  Geoffrey Garen  <ggaren@apple.com>
2140
2141         Reviewed by Darin Adler.
2142         
2143         Added SPI for enabling Dashboard backward compatibility mode. For now,
2144         we enable it unconditionally for Dashboard and Dashcode. Once they 
2145         implement specific support for the backward compatibility mode behavior,
2146         we can change that.
2147         
2148         Set the default WebDashboardBehaviorUseBackwardCompatibilityModeEnabled
2149         to YES in order to turn this code on.
2150
2151         * WebView/WebView.mm:
2152         (-[WebView _setDashboardBehavior:to:]):
2153         (-[WebView _dashboardBehavior:]):
2154         * WebView/WebViewPrivate.h:
2155
2156 2006-12-04  Darin Adler  <darin@apple.com>
2157
2158         Reviewed by Alice.
2159
2160         * WebCoreSupport/WebEditorClient.h: Removed "_web_" prefix from
2161         C++ userVisibleString member function.
2162         * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::userVisibleString):
2163         Ditto.
2164
2165         * WebView/WebView.mm: (-[WebView selectedFrame]): Removed extra return statement.
2166
2167 2006-12-04  Don Gibson  <dgibson77@gmail.com>
2168
2169         Reviewed and landed by Alexey.
2170
2171         http://bugs.webkit.org/show_bug.cgi?id=11738:
2172         Make link clicking work again on Windows.
2173
2174         The WebKit changes are to ignore WM_MOUSEMOVED messages when the mouse
2175         hasn't actually moved, which were preventing clicks from actually
2176         getting dispatched in many cases.  It's a peculiarity of Windows mouse
2177         handling that we receive these at all.
2178
2179         * COM/WebView.cpp:
2180         (WebView::WebView):
2181         (WebView::mouseMoved):
2182         * COM/WebView.h:
2183
2184 2006-12-04  John Sullivan  <sullivan@apple.com>
2185
2186         Reviewed by Anders
2187
2188         - fixed <rdar://problem/4857833> REGRESSION: When ctrl-clicking on a misspelled word, "Ignore Spelling" and "Learn Spelling" 
2189           menu items not displayed in the contextual menu
2190
2191         * WebView/WebHTMLView.m:
2192         (-[WebHTMLView _isSelectionMisspelled]):
2193         We were computing isSelectionMisspelled by calling WebCore, but then ignoring the result and always
2194         returning NO. D'oh!
2195
2196 2006-12-01  Beth Dakin  <bdakin@apple.com>
2197
2198         Reviewed by Adam.
2199
2200         Changes to support sub-menus in WebCore ContextMenus.
2201
2202         * WebCoreSupport/WebContextMenuClient.mm:
2203         (WebContextMenuClient::contextMenuItemSelected): 
2204         ContextMenuItem::menu() is now called parentMenu()
2205         * WebView/WebUIDelegatePrivate.h: New not-yet-API tags.
2206
2207 2006-12-01  Darin Adler  <darin@apple.com>
2208
2209         Reviewed by Mitz.
2210
2211         - fix http://bugs.webkit.org/show_bug.cgi?id=11628
2212           REGRESSION (r17597): Command-return in native text fields doesn't open a new tab or window
2213
2214         * WebCoreSupport/WebFrameLoaderClient.mm:
2215         (findKeyStateEvent): Added. Helper that finds the mouse or keyboard event in a chain
2216         of events and their underlying events.
2217         (findMouseEvent): Added. Same, but specifically for mouse events.
2218         (WebFrameLoaderClient::actionDictionary): Rewrote to use the above functions. This means we
2219         use the modifiers from the underlying events rather than just the one from the event itself.
2220         So if the event is a DOM activate event, we can still see the modifiers from the original
2221         keyboard event that triggered it. Has no effect if the event is already the right type or
2222         if there is no underlying event.
2223
2224         * WebView/WebFrame.mm: Added a newly-needed include.
2225
2226         * WebKit.xcodeproj/project.pbxproj: Xcode wants what it wants.
2227
2228 2006-12-01  Don Gibson  <dgibson77@gmail.com>
2229
2230         Reviewed by Mitz.
2231
2232         http://bugs.webkit.org/show_bug.cgi?id=11732:
2233         Windows build bustage.
2234
2235         * COM/WebFrame.cpp:
2236         (WebFrame::initWithName):
2237
2238 2006-12-01  Timothy Hatcher  <timothy@apple.com>
2239
2240         Reviewed by Adam.
2241
2242         <rdar://problem/4841432> 9A312: iWeb crashes on launch; _WebReportError missing from WebKit
2243
2244         Added back WebReportAssertionFailure and WebReportError for apps that still need these symbols.
2245
2246         * Misc/OldWebAssertions.c: Added.
2247         (WebReportAssertionFailure):
2248         (WebReportError):
2249         * WebKit.LP64.exp: added the new symbols, and sorted the file
2250         * WebKit.exp: added the new symbols, and sorted the file
2251         * WebKit.xcodeproj/project.pbxproj:
2252
2253 2006-11-30  Geoffrey Garen  <ggaren@apple.com>
2254
2255         Rubber Stamped by Anders Carlsson.
2256
2257         Global rename of Document::focusNode to Document::focusedNode. 'focusNode'
2258         suggested a command, and conflicted with a different meaning for 'focusNode'
2259         in the Mozilla selection API.
2260
2261         * WebView/WebHTMLView.m:
2262         (-[NSArray clearFocus]):
2263
2264 2006-11-30  Matt Lilek  <pewtermoose@gmail.com>
2265
2266         Reviewed by Mitz.
2267
2268         Bug 10698: Scroll wheel causes inspector to shift up
2269         http://bugs.webkit.org/show_bug.cgi?id=10698
2270
2271         Remove size attribute from the tree popup as a workaround for
2272         http://bugs.webkit.org/show_bug.cgi?id=11362 Bug 11362: Native popup with size="1" wraps options
2273
2274         * WebInspector/webInspector/inspector.css:
2275         * WebInspector/webInspector/inspector.html:
2276
2277 2006-11-30  Matt Lilek  <pewtermoose@gmail.com>
2278
2279         Reviewed by Tim H.
2280
2281         Move web inspector style markup to javascript to fix http://bugs.webkit.org/show_bug.cgi?id=6724
2282         Bug 6724: Text copied from Web Inspector is different from actual text
2283
2284         * WebInspector/webInspector/inspector.css:
2285         * WebInspector/webInspector/inspector.js:
2286
2287 2006-11-30  Adam Roben  <aroben@apple.com>
2288
2289         Reviewed by Beth.
2290
2291         Put code in place to use WebCore context menus when they are turned
2292         on.
2293
2294         * WebView/WebHTMLView.m:
2295         (-[NSArray menuForEvent:]):
2296
2297 2006-11-29  Timothy Hatcher  <timothy@apple.com>
2298
2299         Reviewed by Oliver.
2300
2301         Keep preferences separate from the rest of the client, making sure we are using expected preference values.
2302         This lets the inspector work when plugins are disabled for the WebView.
2303
2304         * WebInspector/WebInspector.m:
2305         (-[NSWindow window]):
2306
2307 2006-11-29  Anders Carlsson  <acarlsson@apple.com>
2308
2309         Reviewed by Tim.
2310
2311         Add back methods in WebCoreStatistics that are still used by Tiger Safari.
2312         
2313         * Misc/WebCoreStatistics.h:
2314         * Misc/WebCoreStatistics.m:
2315         (+[WebCoreStatistics emptyCache]):
2316         (+[WebCoreStatistics setCacheDisabled:]):
2317
2318 2006-11-28  Alice Liu  <alice.liu@apple.com>
2319
2320         Reviewed by Maciej.
2321
2322         A fix for a couple failing layout tests involving copy/cut in iframes.
2323
2324         * WebCoreSupport/WebEditorClient.h:
2325         * WebCoreSupport/WebEditorClient.mm:
2326         (WebEditorClient::dataForArchivedSelection):
2327         Use the frame parameter instead of using the webview's selectedFrame. 
2328
2329 2006-11-28  Beth Dakin  <bdakin@apple.com>
2330
2331         Reviewed by Geoffff.
2332
2333         Fix for http://bugs.webkit.org/show_bug.cgi?id=11691 REGRESSION 
2334         (r17399, r17511): WebElementDictionary no longer returns nil 
2335         NSStrings
2336
2337         String's NSString* operator converts null Strings to empty 
2338         NSStrings for compatibility with AppKit. We need to work around 
2339         that here.
2340
2341         * Misc/WebElementDictionary.m:
2342         (NSStringOrNil):
2343         (-[WebElementDictionary _altDisplayString]):
2344         (-[WebElementDictionary _spellingToolTip]):
2345         (-[WebElementDictionary _title]):
2346         (-[WebElementDictionary _titleDisplayString]):
2347         (-[WebElementDictionary _textContent]):
2348
2349 2006-11-28  Geoffrey Garen  <ggaren@apple.com>
2350
2351         Reviewed by Beth Dakin.
2352
2353         Fixed <rdar://problem/4844855> Should clarify when to create clients in 
2354         the WebCore client API
2355         
2356         All clients must now be supplied as constructor arguments. This clarifies 
2357         when you need to create clients, and also guarantees that objects can't 
2358         (for the most part) be in a clientless state.
2359
2360         Layout tests pass. No leaks reported.
2361         
2362         * WebCoreSupport/WebFrameBridge.mm: Shuffled around initialization and changed
2363         some arguments to resolve ciruclar dependencies at init time.
2364         (-[WebFrame _initWithWebFrameView:webView:bridge:]): We no longer call setClient
2365         here, because the client is set up at construction time.
2366
2367 2006-11-28  Anders Carlsson  <acarlsson@apple.com>
2368
2369         Reviewed by Maciej.
2370
2371         Update for changes to ResourceRequest.
2372         
2373         * WebCoreSupport/WebChromeClient.mm:
2374         (WebChromeClient::createWindow):
2375         (WebChromeClient::createModalDialog):
2376         * WebCoreSupport/WebFrameLoaderClient.mm:
2377         (WebFrameLoaderClient::canHandleRequest):
2378
2379 2006-11-28  Adam Roben  <aroben@apple.com>
2380
2381         Reviewed by Beth.
2382
2383         More WebCore context menu work.
2384
2385         * DefaultDelegates/WebDefaultUIDelegate.m: New stub delegate method implementation.
2386         (-[NSApplication webView:contextMenuItemSelected:forElement:]):
2387         * WebCoreSupport/WebContextMenuClient.h: Updated to match ContextMenuClient.h changes.
2388         * WebCoreSupport/WebContextMenuClient.mm:
2389         (WebContextMenuClient::addCustomContextMenuItems): Updated for method name changes.
2390         (WebContextMenuClient::contextMenuItemSelected): Added new client method.
2391         * WebView/WebUIDelegatePrivate.h: New private delegate method declaration.
2392
2393 2006-11-28  Alice Liu  <alice.liu@apple.com>
2394
2395         Reviewed by Justin and Adam.
2396
2397         * WebCoreSupport/WebEditorClient.h:
2398         * WebCoreSupport/WebEditorClient.mm:
2399         added the following        
2400         (WebEditorClient::smartInsertDeleteEnabled):
2401         (WebEditorClient::dataForArchivedSelectionInFrame):
2402         (WebEditorClient::_web_userVisibleString):
2403         (WebEditorClient::shouldInsertNode):
2404         
2405         * WebKitPrefix.h:
2406         Added flags to control whether WebCore cut/copy/paste is enabled.
2407         Turned on Cut and Copy, left Paste and Delete off
2408         
2409         * WebView/WebHTMLViewPrivate.h:
2410         * WebView/WebHTMLView.m:
2411         removed _can[Cut|Copy|Paste|Delete]
2412         (-[NSArray validateUserInterfaceItem:]):
2413         call the editor for canDHTML[C|C|P|D] and _can[C|C|P|D] instead 
2414         (-[NSArray delete:]):
2415         added code to call the editor's delete instead (not turned on)
2416         (-[WebHTMLView copy:]):
2417         added code to call the editor's copy (turned on)
2418         (-[WebHTMLView cut:]):
2419         added code to call the editor's cut (turned on)
2420         (-[WebHTMLView paste:]):
2421         added code to call the editor's paste (not turned on)
2422
2423 2006-11-28  Geoffrey Garen  <ggaren@apple.com>
2424
2425         Reviewed by Adam.
2426
2427         Fixed <rdar://problem/4844848> REGRESSION: extra cross-library ref/deref 
2428         calls cause .5% PLT regression.
2429         
2430         Changed ref/deref calls to a single 'xxxDestroyed' call. Moved EditorClient
2431         from the Frame to the Page, since it's only responsible for
2432         Webview-level delegate calls.
2433         
2434         I don't really love this design, but it fixes the regression and allows
2435         a single WebKit object to implement multiple client interfaces.
2436         
2437         Layout tests pass.
2438
2439 2006-11-27  Beth Dakin  <bdakin@apple.com>
2440
2441         Reviewed by Adam.
2442
2443         WebKit half of getting rid of the FixMes in ContextMenu.cpp
2444
2445         * WebCoreSupport/WebFrameLoaderClient.h: canHandleRequest takes a 
2446         ResourceRequest now.
2447         * WebCoreSupport/WebFrameLoaderClient.mm:
2448         (WebFrameLoaderClient::canHandleRequest): Same.
2449         * WebView/WebHTMLView.m:
2450         (-[WebHTMLView _isSelectionMisspelled]): Call into WebCore.
2451
2452 2006-11-27  Ada Chan  <adachan@apple.com>
2453
2454         Reviewed by Adam.
2455
2456         Part of the change to move WebCoreCache into WebKit:
2457         Added WebCache which handles emptying and enable/disabling the cache.
2458         emptyCache and setCacheDisabled have been removed from WebCoreStatistics.
2459
2460         * Misc/WebCache.h: Added.
2461         * Misc/WebCache.mm: Added.
2462         * Misc/WebCoreStatistics.h:
2463         * Misc/WebCoreStatistics.m:
2464         (+[WebCoreStatistics statistics]):
2465         * WebKit.exp:
2466         * WebKit.xcodeproj/project.pbxproj:
2467
2468 2006-11-27  Anders Carlsson  <acarlsson@apple.com>
2469
2470         Reviewed by Adam.
2471
2472         Move addMessageToConsole to Chrome.
2473
2474         * WebCoreSupport/WebChromeClient.h:
2475         * WebCoreSupport/WebChromeClient.mm:
2476         (WebChromeClient::addMessageToConsole):
2477         * WebCoreSupport/WebFrameBridge.mm:
2478
2479 2006-11-27  Brady Eidson  <beidson@apple.com>
2480
2481         Reviewed by Anders
2482
2483         Moved unused Private SPI to Internal and pruned other unused code
2484
2485         * Misc/WebIconDatabase.m:
2486         * Misc/WebIconDatabasePrivate.h:
2487
2488 2006-11-21  Darin Adler  <darin@apple.com>
2489
2490         Reviewed by Maciej.
2491
2492         - make the close method do a more-complete job to prevent world leaks seen when
2493           running some of the layout tests
2494
2495         * WebView/WebHTMLViewInternal.h: Added declaration of -[WebHTMLViewPrivate clear].
2496         * WebView/WebHTMLView.m:
2497         (-[WebHTMLViewPrivate clear]): Added method to drop references to other objects.
2498         We want to do this at "close" time, rather than waiting for deallocation time.
2499         This is especially important for the data source, which indirectly keeps a number of
2500         objects alive.
2501         (-[WebHTMLView close]): Added an explicit call to clear out the data source on the
2502         plug-in controller. Without this, we'd see the plug-in controller making calls to
2503         a deallocated data source during the layout tests. Added a call to the new clear method
2504         on the private object so that we release the objects at close time instead of waiting
2505         for deallocation time.
2506
2507         * WebKit.xcodeproj/project.pbxproj: Let Xcode have its way with the project file,
2508         because I can't fight the power.
2509
2510 2006-11-20  Samuel Weinig  <sam@webkit.org>
2511
2512         Reviewed by Alexey.
2513
2514         Fix for http://bugs.webkit.org/show_bug.cgi?id=11656
2515         Fix Windows build
2516
2517         * WebKit.vcproj/WebKit.vcproj: don't include directories that no
2518         longer exist.
2519
2520 2006-11-19  Beth Dakin  <bdakin@apple.com>
2521
2522         Reviewed by Adam.
2523
2524         WebKit side of new context menu actions.
2525
2526         * WebCoreSupport/WebContextMenuClient.h: These are for the 
2527         currently-WebKit-dependent menu actions.
2528         * WebCoreSupport/WebContextMenuClient.mm:
2529         (WebContextMenuClient::copyLinkToClipboard):
2530         (WebContextMenuClient::downloadURL):
2531         (WebContextMenuClient::copyImageToClipboard):
2532         (WebContextMenuClient::searchWithSpotlight):
2533         (WebContextMenuClient::lookUpInDictionary):
2534         * WebCoreSupport/WebEditorClient.h:
2535         * WebCoreSupport/WebEditorClient.mm:
2536         (core): These are to convert between WebViewInsertAction and 
2537         EditorInsertAction.
2538         (kit):
2539         (WebEditorClient::shouldInsertText): Added implementation for 
2540         shouldInsertText.
2541         * WebKit.xcodeproj/project.pbxproj:
2542         * WebView/WebHTMLView.m:
2543         (-[WebHTMLView _lookUpInDictionaryFromMenu:]): Moved 
2544         _lookUpInDictionary to be within the implementation of WebHTMLView 
2545         internal.
2546         * WebView/WebHTMLViewInternal.h: Add _lookUpInDictionaryFromMenu
2547         * WebView/WebViewInternal.h: Add _searchWithSpotlightFromMenu
2548
2549 2006-11-18  Don Gibson  <dgibson77@gmail.com>
2550
2551         Reviewed by Sam Weinig.
2552
2553         http://bugs.webkit.org/show_bug.cgi?id=11634:
2554         Fix segfault on startup for Windows build.  Also fix segfault when
2555         typing in a URL.
2556
2557         * COM/WebFrame.cpp:
2558         (WebFrame::initWithName):
2559
2560 === Safari-521.31 ===
2561
2562 2006-11-17  Timothy Hatcher  <timothy@apple.com>
2563
2564         Reviewed by Geoff.
2565
2566         <rdar://problem/4841044> Temporarily default Mail.app editable link clicking behavior, until they do it themselves
2567
2568         * WebKit.xcodeproj/project.pbxproj:
2569         * WebView/WebView.mm:
2570         (+[WebView initialize]):
2571         (-[WebView setPreferences:]):
2572
2573 2006-11-16  Don Gibson  <dgibson77@gmail.com>
2574
2575         Reviewed and landed by ap.
2576
2577         http://bugs.webkit.org/show_bug.cgi?id=11509:
2578         Windows build bustage.
2579
2580         * COM/WebFrame.cpp:
2581         (WebFrame::initWithName):
2582         (WebFrame::loadHTMLString):
2583         (WebFrame::stopLoading):
2584         (WebFrame::reload):
2585         (WebFrame::loadDataSource):
2586         (WebFrame::didReceiveData):
2587         (WebFrame::receivedResponse):
2588         (WebFrame::receivedAllData):
2589         * COM/WebFrame.h:
2590         * COM/WebView.cpp:
2591         (WebView::mouseMoved):
2592         (WebView::mouseDown):
2593         (WebView::mouseUp):
2594         (WebView::mouseDoubleClick):
2595         * WebKit.vcproj/WebKit.vcproj:
2596
2597 2006-11-16  Anders Carlsson  <acarlsson@apple.com>
2598
2599         Reviewed by Tim.
2600
2601         <rdar://problem/4841123>
2602         REGRESSION: Crash in WebCore::Range::boundaryPointsValid when replying to a mail Message
2603         
2604         * Misc/WebNSAttributedStringExtras.m:
2605         (+[NSAttributedString _web_attributedStringFromRange:]):
2606         If the range passed in is null, return null. When this function was in the bridge, it would never get called
2607         with a null range when nothing was selected. Instead, the range would just have invalid boundary points.
2608
2609 2006-11-15  Adam Roben  <aroben@apple.com>
2610
2611         Reviewed by Anders.
2612
2613         Added new WebContextMenuClient class to act as WebCore's ChromeClient,
2614         and moved context menu-related code there from WebChromeClient.
2615
2616         * WebCoreSupport/WebChromeClient.h:
2617         * WebCoreSupport/WebChromeClient.mm:
2618         * WebCoreSupport/WebContextMenuClient.h: Added.
2619         (WebContextMenuClient::webView):
2620         * WebCoreSupport/WebContextMenuClient.mm: Added.
2621         (WebContextMenuClient::create):
2622         (WebContextMenuClient::WebContextMenuClient):
2623         (WebContextMenuClient::ref):
2624         (WebContextMenuClient::deref):
2625         (WebContextMenuClient::addCustomContextMenuItems):
2626         * WebKit.xcodeproj/project.pbxproj: Added new files.
2627         * WebView/WebView.mm:
2628         (-[WebView _commonInitializationWithFrameName:groupName:]):
2629
2630 2006-11-15  Beth Dakin  <bdakin@apple.com>
2631         &   Adam Roben  <aroben@apple.com>
2632
2633         Reviewed by Adam & Beth.
2634
2635         WebKit side of first cut at engine context menus. Use the client to 
2636         call into the UIDelegate.
2637
2638         * WebCoreSupport/WebChromeClient.h:
2639         * WebCoreSupport/WebChromeClient.mm:
2640         (WebChromeClient::addCustomContextMenuItems):
2641         * WebKit.xcodeproj/project.pbxproj:
2642
2643 2006-11-15  Brady Eidson  <beidson@apple.com>
2644
2645         Reviewed by Maciej
2646
2647         Quick change of files to ObjC++ for BF cache re-write
2648
2649         * History/WebBackForwardList.m: Removed.
2650         * History/WebBackForwardList.mm: Added.
2651         * History/WebHistoryItem.m: Removed.
2652         * History/WebHistoryItem.mm: Added.
2653         * WebKit.xcodeproj/project.pbxproj:
2654
2655 2006-11-15  Brady Eidson  <beidson@apple.com>
2656
2657         Reviewed by Sarge
2658
2659         SPI addition
2660
2661         * WebView/WebFrame.mm:
2662         (-[WebFrame _recursive_resumeNullEventsForAllNetscapePlugins]):
2663         * WebView/WebFrameInternal.h:
2664         * WebView/WebFramePrivate.h:
2665
2666 2006-11-15  Brady Eidson  <beidson@apple.com>
2667
2668         Reviewed by Adele
2669
2670         <rdar://problem/4838729> - Replace mistakenly removed SPI
2671
2672         * WebView/WebHTMLView.m:
2673         (-[WebHTMLView _handleAutoscrollForMouseDragged:]):
2674         * WebView/WebHTMLViewPrivate.h:
2675
2676 2006-11-15  Anders Carlsson  <acarlsson@apple.com>
2677
2678         Reviewed by Adele.
2679
2680         isTargetItem is used by DRT, so make it private instead of internal.
2681         
2682         * History/WebHistoryItem.m:
2683         (-[WebHistoryItem isTargetItem]):
2684         * History/WebHistoryItemInternal.h:
2685         * History/WebHistoryItemPrivate.h:
2686         * WebCoreSupport/WebFrameLoaderClient.mm:
2687
2688 2006-11-15  Brady Eidson  <beidson@apple.com>
2689
2690         Reviewed by Maciej
2691
2692         Split much of unused WebHistoryItemPrivate.h SPI into WebHistoryItemInternal.h
2693
2694         * History/WebBackForwardList.m:
2695         * History/WebHistory.m:
2696         * History/WebHistoryItem.m:
2697         (-[WebHistoryItem initWithURLString:title:lastVisitedTimeInterval:]):
2698         (-[WebHistoryItem initWithURL:title:]):
2699         (-[WebHistoryItem visitCount]):
2700         (-[WebHistoryItem RSSFeedReferrer]):
2701         (-[WebHistoryItem setRSSFeedReferrer:]):
2702         (-[WebHistoryItem children]):
2703         (-[WebHistoryItem dictionaryRepresentation]):
2704         (-[WebHistoryItem setAlwaysAttemptToUsePageCache:]):
2705         (+[WebHistoryItem _releaseAllPendingPageCaches]):
2706         (-[WebHistoryItem URL]):
2707         (-[WebHistoryItem target]):
2708         (-[WebHistoryItem _setLastVisitedTimeInterval:]):
2709         (-[WebHistoryItem _lastVisitedDate]):
2710         (-[WebHistoryItem targetItem]):
2711         * History/WebHistoryItemInternal.h: Added.
2712         * History/WebHistoryItemPrivate.h:
2713         * WebCoreSupport/WebFrameBridge.mm:
2714         * WebCoreSupport/WebFrameLoaderClient.mm:
2715         * WebKit.xcodeproj/project.pbxproj:
2716         * WebView/WebFrame.mm:
2717         * WebView/WebView.mm:
2718
2719 2006-11-14  Beth Dakin  <bdakin@apple.com>
2720
2721         Reviewed by Geoff.
2722
2723         Moving things off the bridge and onto clients.
2724
2725         * WebCoreSupport/WebEditorClient.h:
2726         * WebCoreSupport/WebEditorClient.mm:
2727         (WebEditorClient::selectWordBeforeMenuEvent):
2728         (WebEditorClient::isEditable):
2729         * WebCoreSupport/WebFrameBridge.mm:
2730         * WebKit.xcodeproj/project.pbxproj:
2731
2732 2006-11-14  Timothy Hatcher  <timothy@apple.com>
2733
2734         Reviewed by Harrison.
2735
2736         <rdar://problem/4766635> Safari should never follow links in editable areas (add a WebKitEditableLinkNeverLive option)
2737
2738         Adds an Open Link, Open Link in New Window and Copy Link to the editing context menu.
2739         Adds a new WebKitEditableLinkNeverLive preference value that maps to WebCore's EditableLinkNeverLive.
2740
2741         * DefaultDelegates/WebDefaultContextMenuDelegate.m:
2742         (-[WebDefaultUIDelegate menuItemWithTag:target:representedObject:]):
2743         (-[WebDefaultUIDelegate contextMenuItemsForElement:defaultMenuItems:]):
2744         (-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
2745         (-[WebDefaultUIDelegate requestWithURL:includingReferrerFromFrame:]):
2746         (-[WebDefaultUIDelegate openNewWindowWithURL:element:]):
2747         (-[WebDefaultUIDelegate openLink:]):
2748         * English.lproj/Localizable.strings:
2749         * WebKit.exp:
2750         * WebView/WebPreferences.m:
2751         (-[WebPreferences editableLinkBehavior]):
2752         * WebView/WebPreferencesPrivate.h:
2753         * WebView/WebUIDelegatePrivate.h:
2754
2755 2006-11-14  Anders Carlsson  <acarlsson@apple.com>
2756
2757         Turns out I wasn't forcing DWARF on the world at all, 
2758         it's now the default!
2759
2760         * WebKit.xcodeproj/project.pbxproj:
2761
2762 2006-11-14  Anders Carlsson  <acarlsson@apple.com>
2763
2764         I must stop trying to force DWARF on the world.
2765
2766         * WebKit.xcodeproj/project.pbxproj:
2767
2768 2006-11-14  Darin Adler  <darin@apple.com>
2769
2770         Reviewed by Anders.
2771
2772         - update for creation of EventHandler
2773
2774         * WebCoreSupport/WebFrameLoaderClient.mm:
2775         (WebFrameLoaderClient::actionDictionary):
2776         * WebView/WebHTMLView.m:
2777         (-[WebHTMLView _updateMouseoverWithEvent:]):
2778         (-[NSArray menuForEvent:]):
2779         (-[NSArray scrollWheel:]):
2780         (-[NSArray acceptsFirstMouse:]):
2781         (-[NSArray shouldDelayWindowOrderingForEvent:]):
2782         (-[NSArray mouseDown:]):
2783         (-[NSArray mouseDragged:]):
2784         (-[NSArray mouseUp:]):
2785         (-[NSArray keyDown:]):
2786         (-[NSArray keyUp:]):
2787         (-[NSArray performKeyEquivalent:]):
2788         (-[WebHTMLView elementAtPoint:allowShadowContent:]):
2789
2790 2006-11-14  Anders Carlsson  <acarlsson@apple.com>
2791
2792         Fix build for real this time.
2793         
2794         * WebCoreSupport/WebEditorClient.mm:
2795         (-[WebEditCommand initWithEditCommand:WebCore::]):
2796         (-[WebEditCommand dealloc]):
2797         (-[WebEditCommand finalize]):
2798         (+[WebEditCommand commandWithEditCommand:]):
2799         (-[WebEditCommand command]):
2800
2801 2006-11-14  Anders Carlsson  <acarlsson@apple.com>
2802
2803         Try fixing the build.
2804         
2805         * WebCoreSupport/WebEditorClient.mm:
2806         (-[WebEditorUndoTarget undoEditing:]):
2807         (-[WebEditorUndoTarget redoEditing:]):
2808
2809 2006-11-14  Anders Carlsson  <acarlsson@apple.com>
2810
2811         Reviewed by Darin.
2812
2813         Move undo/redo handling into WebEditorClient.
2814         
2815         * WebCoreSupport/WebEditorClient.h:
2816         * WebCoreSupport/WebEditorClient.mm:
2817         (WebEditorClient::WebEditorClient):
2818         (WebEditorClient::~WebEditorClient):
2819         (-[WebEditCommand initWithEditCommand:WebCore::]):
2820         (-[WebEditCommand dealloc]):
2821         (-[WebEditCommand finalize]):
2822         (+[WebEditCommand commandWithEditCommand:]):
2823         (-[WebEditCommand command]):
2824         (-[WebEditorUndoTarget undoEditing:]):
2825         (-[WebEditorUndoTarget redoEditing:]):
2826         (undoNameForEditAction):
2827         (WebEditorClient::registerCommandForUndoOrRedo):
2828         (WebEditorClient::registerCommandForUndo):
2829         (WebEditorClient::registerCommandForRedo):
2830         (WebEditorClient::clearUndoRedoOperations):
2831         (WebEditorClient::canUndo):
2832         (WebEditorClient::canRedo):
2833         (WebEditorClient::undo):
2834         (WebEditorClient::redo):
2835         * WebCoreSupport/WebFrameBridge.mm:
2836         * WebKit.xcodeproj/project.pbxproj:
2837
2838 2006-11-14  Alexey Proskuryakov  <ap@webkit.org>
2839
2840         Reviewed by Tim H.
2841
2842         http://bugs.webkit.org/show_bug.cgi?id=3387
2843         Redundant keydown, keypress, keyup events sent for arrow keys
2844
2845         Added another layer of ugly hacks around AppKit event dispatching.
2846
2847         1. For arrow keys, keyDown: is invoked after performKeyEquivalent:, so had to store
2848         _private->keyDownEvent in both methods, and make it persist after leaving them.
2849
2850         2. For Esc, AppKit calls performKeyEquivalent: with a fake event of some kind,
2851         use [NSApp currentEvent] to check for this to prevent it from being passed to  WebCore.
2852
2853         Test: manual-tests/arrow-key-events.html
2854
2855         * WebView/WebHTMLView.m:
2856         (-[NSMutableDictionary dealloc]):
2857         (-[NSArray keyDown:]):
2858         (-[NSArray keyUp:]):
2859         (-[NSArray performKeyEquivalent:]):
2860         * WebView/WebHTMLViewInternal.h:
2861
2862 2006-11-12  Brady Eidson <beidson@apple.com>
2863
2864         Rubberstamped by Anders
2865
2866         Changed some #includes from <WebKit/foo.h> to "foo.h"
2867
2868         * History/WebBackForwardList.m:
2869         * History/WebHistory.m:
2870
2871 2006-11-11  Geoffrey Garen  <ggaren@apple.com>
2872
2873         Reviewed by Maciej Stachowiak.
2874         
2875         - Fixed loader crash by clarifying ownership of WebKit client objects. 
2876         WebCore objects own their WebKit clients, and ref and deref through 
2877         virtual methods, leaving WebKit free to use whatever client / reference-counting 
2878         implementation it likes.
2879         
2880         WebKit on Mac just uses the same refcounting class that WebCore uses (Shared),
2881         but other platforms may choose to do other things.
2882
2883         * WebCoreSupport/WebChromeClient.h:
2884         (WebChromeClient::ref):
2885         (WebChromeClient::deref):
2886         (WebChromeClient::refCount):
2887         * WebCoreSupport/WebEditorClient.h: Nixed commented-out function prototypes.
2888         The ones in WebCore make clear what remains to be implemented. Replaced constructor
2889         with factory function to avoid leaks.
2890         * WebCoreSupport/WebEditorClient.mm:
2891         (WebEditorClient::create):
2892         (WebEditorClient::WebEditorClient):
2893         (WebEditorClient::setWebFrame):
2894         * WebCoreSupport/WebFrameBridge.mm:
2895         (-[WebFrameBridge initMainFrameWithPage:WebCore::frameName:view:webView:]):
2896         (-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
2897         * WebCoreSupport/WebFrameLoaderClient.h: Replaced constructor with factory
2898         function to avoid leaks.
2899         (WebFrameLoaderClient::ref):
2900         (WebFrameLoaderClient::deref):
2901         (WebFrameLoaderClient::refCount):
2902         * WebCoreSupport/WebFrameLoaderClient.mm:
2903         (WebFrameLoaderClient::create):
2904         * WebView/WebFrame.mm:
2905         (-[WebFrame _initWithWebFrameView:webView:coreFrame:]):
2906
2907 === Safari-521.30 ===
2908
2909 2006-11-10  Maciej Stachowiak  <mjs@apple.com>
2910
2911         Reviewed by Anders.
2912         
2913         - remove some unnecessary uses of WebDataProtocol
2914
2915         * WebView/WebDataSource.mm: Remove the unneeded include.
2916         * WebView/WebView.mm:
2917         (+[WebView _canHandleRequest:]): Don't bother to check for unreachable URL here.
2918         Any request that has one will be an applewebdata: request, which will pass the check anyway.
2919
2920 2006-11-10  Anders Carlsson  <acarlsson@apple.com>
2921
2922         Reviewed by Geoff.
2923
2924         Update for changes to WebCore
2925         * WebView/WebHTMLView.m:
2926         (-[NSArray _applyStyleToSelection:withUndoAction:]):
2927         (-[NSArray _applyParagraphStyleToSelection:withUndoAction:]):
2928         (-[NSArray _toggleBold]):
2929         (-[NSArray _toggleItalic]):
2930
2931 2006-11-09  Anders Carlsson  <acarlsson@apple.com>
2932
2933         Reviewed by Maciej, Geoff.
2934
2935         Call execCommand directly here instead of going through the bridge.
2936         
2937         * WebView/WebHTMLView.m:
2938         (-[NSArray moveBackward:]):
2939         (-[NSArray moveBackwardAndModifySelection:]):
2940         (-[NSArray moveDown:]):
2941         (-[NSArray moveDownAndModifySelection:]):
2942         (-[NSArray moveForward:]):
2943         (-[NSArray moveForwardAndModifySelection:]):
2944         (-[NSArray moveLeft:]):
2945         (-[NSArray moveLeftAndModifySelection:]):
2946         (-[NSArray moveRight:]):
2947         (-[NSArray moveRightAndModifySelection:]):
2948         (-[NSArray moveToBeginningOfDocument:]):
2949         (-[NSArray moveToBeginningOfDocumentAndModifySelection:]):
2950         (-[NSArray moveToBeginningOfSentence:]):
2951         (-[NSArray moveToBeginningOfSentenceAndModifySelection:]):
2952         (-[NSArray moveToBeginningOfLine:]):
2953         (-[NSArray moveToBeginningOfLineAndModifySelection:]):
2954         (-[NSArray moveToBeginningOfParagraph:]):
2955         (-[NSArray moveToBeginningOfParagraphAndModifySelection:]):
2956         (-[NSArray moveToEndOfDocument:]):
2957         (-[NSArray moveToEndOfDocumentAndModifySelection:]):
2958         (-[NSArray moveToEndOfSentence:]):
2959         (-[NSArray moveToEndOfSentenceAndModifySelection:]):
2960         (-[NSArray moveToEndOfLine:]):
2961         (-[NSArray moveToEndOfLineAndModifySelection:]):
2962         (-[NSArray moveToEndOfParagraph:]):
2963         (-[NSArray moveToEndOfParagraphAndModifySelection:]):
2964         (-[NSArray moveParagraphBackwardAndModifySelection:]):
2965         (-[NSArray moveParagraphForwardAndModifySelection:]):
2966         (-[NSArray moveUp:]):
2967         (-[NSArray moveUpAndModifySelection:]):
2968         (-[NSArray moveWordBackward:]):
2969         (-[NSArray moveWordBackwardAndModifySelection:]):
2970         (-[NSArray moveWordForward:]):
2971         (-[NSArray moveWordForwardAndModifySelection:]):
2972         (-[NSArray moveWordLeft:]):
2973         (-[NSArray moveWordLeftAndModifySelection:]):
2974         (-[NSArray moveWordRight:]):
2975         (-[NSArray moveWordRightAndModifySelection:]):
2976
2977 2006-11-10  Brady Eidson  <beidson@apple.com>
2978
2979         Reviewed by Darin
2980   
2981         Took out WebIconDatabaseBridge and made WebKit call IconDatabase directly
2982
2983         * Misc/WebIconDatabase.m:
2984         (-[WebIconDatabase init]):
2985         (-[WebIconDatabase iconForURL:withSize:cache:]):
2986         (-[WebIconDatabase iconURLForURL:]):
2987         (-[WebIconDatabase defaultIconWithSize:]):
2988         (-[WebIconDatabase defaultIconForURL:withSize:]):
2989         (-[WebIconDatabase retainIconForURL:]):
2990         (-[WebIconDatabase releaseIconForURL:]):
2991         (-[WebIconDatabase setDelegate:]):
2992         (-[WebIconDatabase removeAllIcons]):
2993         (-[WebIconDatabase isIconExpiredForIconURL:]):
2994         (-[WebIconDatabase _isEnabled]):
2995         (-[WebIconDatabase _setIconData:forIconURL:]):
2996         (-[WebIconDatabase _setHaveNoIconForIconURL:]):
2997         (-[WebIconDatabase _setIconURL:forURL:]):
2998         (-[WebIconDatabase _hasEntryForIconURL:]):
2999         (-[WebIconDatabase _applicationWillTerminate:]):
3000         (-[WebIconDatabase _resetCachedWebPreferences:]):
3001         (-[WebIconDatabase _convertToWebCoreFormat]):
3002         (webGetNSImage):
3003         * Misc/WebIconDatabaseInternal.h: Added.
3004         * Misc/WebIconDatabasePrivate.h:
3005         * WebCoreSupport/WebFrameLoaderClient.h:
3006         * WebCoreSupport/WebFrameLoaderClient.mm:
3007         (WebFrameLoaderClient::dispatchDidReceiveIcon):
3008         * WebCoreSupport/WebIconDatabaseBridge.h: Removed.
3009         * WebCoreSupport/WebIconDatabaseBridge.m: Removed.
3010         * WebKit.xcodeproj/project.pbxproj:
3011
3012 2006-11-09  Oliver Hunt  <oliver@apple.com>
3013
3014         Reviewed by Brady.
3015         
3016         Updated to make use of MimeTypeRegistry/bridge
3017
3018         * Misc/WebNSPasteboardExtras.m:
3019         (-[NSPasteboard _web_writeImage:element:URL:title:archive:types:]):
3020         * WebCoreSupport/WebFrameBridge.mm:
3021         (-[WebFrameBridge determineObjectFromMIMEType:URL:]):
3022         * WebView/WebDataSource.mm:
3023         (-[WebDataSource _documentFragmentWithArchive:]):
3024         * WebView/WebHTMLRepresentation.m:
3025         (+[WebHTMLRepresentation supportedNonImageMIMETypes]):
3026         (+[WebHTMLRepresentation supportedImageMIMETypes]):
3027         * WebView/WebHTMLView.m:
3028         (-[WebHTMLView _imageExistsAtPaths:]):
3029         (-[WebHTMLView _documentFragmentWithPaths:]):
3030
3031 2006-11-09  Brady Eidson  <beidson@apple.com>
3032
3033         Reviewed by Darin
3034
3035         <rdar://problem/4829080>
3036         More loader re-factoring cleanup - WebFramePolicyListener was over-released
3037
3038         * WebCoreSupport/WebFrameLoaderClient.h: Changed vanilla ptr to a RetainPtr<> 
3039         * WebCoreSupport/WebFrameLoaderClient.mm:
3040         (WebFrameLoaderClient::dispatchDecidePolicyForMIMEType): Ditto
3041         (WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction): Ditto
3042         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction): Ditto
3043         (WebFrameLoaderClient::dispatchWillSubmitForm): Ditto
3044         (WebFrameLoaderClient::setUpPolicyListener): Ditto
3045         (-[WebFramePolicyListener receivedPolicyDecision:]): Ditto 
3046
3047 2006-11-08  Anders Carlsson  <acarlsson@apple.com>
3048
3049         Reviewed by Adam, Oliver.
3050
3051         Update for changes to WebCore. Pass a specific WebFrame to WebEditorClient
3052         instead of just passing the WebView.
3053         
3054         * WebCoreSupport/WebEditorClient.h:
3055         * WebCoreSupport/WebEditorClient.mm:
3056         (WebEditorClient::WebEditorClient):
3057         (WebEditorClient::setWebFrame):
3058         (WebEditorClient::isContinuousSpellCheckingEnabled):
3059         (WebEditorClient::spellCheckerDocumentTag):
3060         (WebEditorClient::shouldDeleteRange):
3061         (WebEditorClient::shouldShowDeleteInterface):
3062         (WebEditorClient::shouldApplyStyle):
3063         (WebEditorClient::shouldBeginEditing):
3064         (WebEditorClient::shouldEndEditing):
3065         (WebEditorClient::didBeginEditing):
3066         (WebEditorClient::respondToChangedContents):
3067         (WebEditorClient::didEndEditing):
3068         * WebCoreSupport/WebFrameBridge.mm:
3069         (-[WebFrameBridge initMainFrameWithPage:WebCore::frameName:view:webView:]):
3070         (-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
3071
3072 2006-11-08  Anders Carlsson  <acarlsson@apple.com>
3073
3074         Reviewed by Adam.
3075
3076         Move more code into editor.
3077
3078         * WebCoreSupport/WebEditorClient.h:
3079         * WebCoreSupport/WebEditorClient.mm:
3080         (WebEditorClient::shouldBeginEditing):
3081         (WebEditorClient::shouldEndEditing):
3082         (WebEditorClient::didBeginEditing):
3083         (WebEditorClient::didEndEditing):
3084         * WebCoreSupport/WebFrameBridge.mm:
3085         * WebView/WebHTMLView.m:
3086         (-[NSArray indent:]):
3087         (-[NSArray outdent:]):
3088         * WebView/WebView.mm:
3089         * WebView/WebViewInternal.h:
3090
3091 2006-11-08  Beth Dakin  <bdakin@apple.com>
3092
3093         Reviewed by Adam.
3094
3095         Add WebElementIsContentEditableKey to the WebElementDictionary, and 
3096         use it!
3097
3098         * DefaultDelegates/WebDefaultContextMenuDelegate.m:
3099         (-[WebDefaultUIDelegate 
3100         webView:contextMenuItemsForElement:defaultMenuItems:]): Use new 
3101         WebElementIsContentEditableKey.
3102         * Misc/WebElementDictionary.m:
3103         (+[WebElementDictionary initializeLookupTable]):
3104         (-[WebElementDictionary _isContentEditable]): Call into 
3105         HitTestResult::isContentEditable()
3106         * WebView/WebView.mm: Add new key.
3107         * WebView/WebViewPrivate.h: Add new key.
3108
3109 2006-11-08  Anders Carlsson  <acarlsson@apple.com>
3110
3111         Reviewed by Oliver.
3112
3113         Call into the WebCore editor object directly.
3114         
3115         * MigrateHeaders.make:
3116         * WebCoreSupport/WebEditorClient.h:
3117         * WebCoreSupport/WebEditorClient.mm:
3118         (WebEditorClient::shouldDeleteRange):
3119         (WebEditorClient::shouldShowDeleteInterface):
3120         (WebEditorClient::shouldApplyStyle):
3121         * WebView/WebFrame.mm:
3122         (core):
3123         (kit):
3124         * WebView/WebFrameInternal.h:
3125         * WebView/WebHTMLView.m:
3126         (-[NSArray _applyStyleToSelection:withUndoAction:]):
3127         (-[NSArray _applyParagraphStyleToSelection:withUndoAction:]):
3128         (-[NSArray _toggleBold]):
3129         (-[NSArray _toggleItalic]):
3130         (-[NSArray _changeCSSColorUsingSelector:inRange:]):
3131         (-[NSArray underline:]):
3132         (-[WebHTMLView concludeDragForDraggingInfo:actionMask:]):
3133         * WebView/WebView.mm:
3134         (-[WebView applyStyle:]):
3135
3136 2006-11-08  Anders Carlsson  <acarlsson@apple.com>
3137
3138         Reviewed by Oliver.
3139
3140         <rdar://problem/4825370>
3141         REGRESSION: Selecting "Look Up In Dictionary" from contextual menu fails to open the Dictionary app
3142         
3143         * WebView/WebHTMLView.m:
3144         (-[WebHTMLView _lookUpInDictionaryFromMenu:]):
3145         Initialize the framework pointer to 0.
3146         
3147 2006-11-07  Darin Adler  <darin@apple.com>
3148
3149         Reviewed by Geoff.
3150
3151         - udpated for changes to move from Frame/FrameMac to FrameLoader
3152
3153         * DefaultDelegates/WebDefaultContextMenuDelegate.m:
3154         (-[WebDefaultUIDelegate openNewWindowWithURL:element:]):
3155         * Misc/WebNSAttributedStringExtras.m:
3156         (+[NSAttributedString _web_attributedStringFromRange:]):
3157         * Plugins/WebBaseNetscapePluginView.mm:
3158         (-[WebBaseNetscapePluginView requestWithURLCString:]):
3159         * Plugins/WebNetscapePluginEmbeddedView.m:
3160         (-[WebNetscapePluginEmbeddedView didStart]):
3161         * Plugins/WebNetscapePluginStream.mm:
3162         * Plugins/WebPluginController.mm:
3163         (-[WebPluginController pluginView:receivedResponse:]):
3164         * WebCoreSupport/WebFrameBridge.mm:
3165         (-[WebFrameBridge viewForPluginWithURL:attributeNames:attributeValues:MIMEType:DOMElement:loadManually:]):
3166         * WebCoreSupport/WebFrameLoaderClient.mm:
3167         (WebFrameLoaderClient::provisionalLoadStarted):
3168         * WebView/WebFrame.mm:
3169         (-[WebFrame _canCachePage]):
3170         (+[WebFrame _timeOfLastCompletedLoad]):
3171         (-[WebFrame _loadItem:withLoadType:]):
3172         (-[WebFrame _reloadForPluginChanges]):
3173         (-[WebFrame stopLoading]):
3174
3175 2006-11-07  Anders Carlsson  <acarlsson@apple.com>
3176
3177         Reviewed by Geoff.
3178
3179         Use the WebCore editing enums.
3180         
3181         * WebCoreSupport/WebFrameBridge.mm:
3182         (-[WebFrameBridge undoNameForEditAction:]):
3183         * WebView/WebHTMLView.m:
3184         (-[WebHTMLView _deleteRange:killRing:prepend:smartDeleteOK:deletionAction:granularity:]):
3185         (-[WebHTMLView _deleteSelection]):
3186         (-[WebHTMLView moveBackward:]):
3187         (-[WebHTMLView moveBackwardAndModifySelection:]):
3188         (-[WebHTMLView moveDown:]):
3189         (-[WebHTMLView moveDownAndModifySelection:]):
3190         (-[WebHTMLView moveForward:]):
3191         (-[WebHTMLView moveForwardAndModifySelection:]):
3192         (-[WebHTMLView moveLeft:]):
3193         (-[WebHTMLView moveLeftAndModifySelection:]):
3194         (-[WebHTMLView moveRight:]):
3195         (-[WebHTMLView moveRightAndModifySelection:]):
3196         (-[WebHTMLView moveToBeginningOfDocument:]):
3197         (-[WebHTMLView moveToBeginningOfDocumentAndModifySelection:]):
3198         (-[WebHTMLView moveToBeginningOfSentence:]):
3199         (-[WebHTMLView moveToBeginningOfSentenceAndModifySelection:]):
3200         (-[WebHTMLView moveToBeginningOfLine:]):
3201         (-[WebHTMLView moveToBeginningOfLineAndModifySelection:]):
3202         (-[WebHTMLView moveToBeginningOfParagraph:]):
3203         (-[WebHTMLView moveToBeginningOfParagraphAndModifySelection:]):
3204         (-[WebHTMLView moveToEndOfDocument:]):
3205         (-[WebHTMLView moveToEndOfDocumentAndModifySelection:]):
3206         (-[WebHTMLView moveToEndOfSentence:]):
3207         (-[WebHTMLView moveToEndOfSentenceAndModifySelection:]):
3208         (-[WebHTMLView moveToEndOfLine:]):
3209         (-[WebHTMLView moveToEndOfLineAndModifySelection:]):
3210         (-[WebHTMLView moveToEndOfParagraph:]):
3211         (-[WebHTMLView moveToEndOfParagraphAndModifySelection:]):
3212         (-[WebHTMLView moveParagraphBackwardAndModifySelection:]):
3213         (-[WebHTMLView moveParagraphForwardAndModifySelection:]):
3214         (-[WebHTMLView moveUp:]):
3215         (-[WebHTMLView moveUpAndModifySelection:]):
3216         (-[WebHTMLView moveWordBackward:]):
3217         (-[WebHTMLView moveWordBackwardAndModifySelection:]):
3218         (-[WebHTMLView moveWordForward:]):
3219         (-[WebHTMLView moveWordForwardAndModifySelection:]):
3220         (-[WebHTMLView moveWordLeft:]):
3221         (-[WebHTMLView moveWordLeftAndModifySelection:]):
3222         (-[WebHTMLView moveWordRight:]):
3223         (-[WebHTMLView moveWordRightAndModifySelection:]):
3224         (-[WebHTMLView pageUp:]):
3225         (-[WebHTMLView pageDown:]):
3226         (-[WebHTMLView pageUpAndModifySelection:]):
3227         (-[WebHTMLView pageDownAndModifySelection:]):
3228         (-[WebHTMLView _expandSelectionToGranularity:]):
3229         (-[WebHTMLView selectParagraph:]):
3230         (-[WebHTMLView selectLine:]):
3231         (-[WebHTMLView selectSentence:]):
3232         (-[WebHTMLView selectWord:]):
3233         (-[WebHTMLView _applyStyleToSelection:withUndoAction:]):
3234         (-[WebHTMLView _applyParagraphStyleToSelection:withUndoAction:]):
3235         (-[WebHTMLView _toggleBold]):
3236         (-[WebHTMLView _toggleItalic]):
3237         (-[WebHTMLView pasteFont:]):
3238         (-[WebHTMLView changeFont:]):
3239         (-[WebHTMLView changeAttributes:]):
3240         (-[WebHTMLView _undoActionFromColorPanelWithSelector:]):
3241         (-[WebHTMLView changeColor:]):
3242         (-[WebHTMLView _alignSelectionUsingCSSValue:withUndoAction:]):
3243         (-[WebHTMLView alignCenter:]):
3244         (-[WebHTMLView alignJustified:]):
3245         (-[WebHTMLView alignLeft:]):
3246         (-[WebHTMLView alignRight:]):
3247         (-[WebHTMLView _deleteWithDirection:SelectionController::granularity:killRing:isTypingAction:]):
3248         (-[WebHTMLView deleteForward:]):
3249         (-[WebHTMLView deleteBackward:]):
3250         (-[WebHTMLView deleteWordForward:]):
3251         (-[WebHTMLView deleteWordBackward:]):
3252         (-[WebHTMLView deleteToBeginningOfLine:]):
3253         (-[WebHTMLView deleteToEndOfLine:]):
3254         (-[WebHTMLView deleteToBeginningOfParagraph:]):
3255         (-[WebHTMLView deleteToEndOfParagraph:]):
3256         (-[WebHTMLView subscript:]):
3257         (-[WebHTMLView superscript:]):
3258         (-[WebHTMLView unscript:]):
3259         (-[WebHTMLView underline:]):
3260         (-[WebHTMLView deleteToMark:]):
3261         (-[WebHTMLView toggleBaseWritingDirection:]):
3262         (-[WebHTMLView changeBaseWritingDirection:]):
3263         (-[WebHTMLView _canSmartCopyOrDelete]):
3264         (-[WebTextCompleteController doCompletion]):
3265         (-[WebHTMLView concludeDragForDraggingInfo:actionMask:]):
3266         * WebView/WebView.mm:
3267         (-[WebView setTypingStyle:]):
3268         (-[WebView applyStyle:]):
3269
3270 2006-11-06  Geoffrey Garen  <ggaren@apple.com>
3271
3272         Reviewed by Tim Hatcher.
3273
3274         Removed ScreenClient. It was highly unpopular, risking my midterm re-election.
3275         
3276         None of Screen's responsibilities require up-calls to WebKit or delegates, 
3277         so WebCore can handle it all.
3278
3279         * WebCoreSupport/WebChromeClient.mm:
3280         (WebChromeClient::setWindowRect):
3281         (WebChromeClient::windowRect):
3282         * WebCoreSupport/WebScreenClient.h: Removed.
3283         * WebCoreSupport/WebScreenClient.mm: Removed.
3284         * WebKit.xcodeproj/project.pbxproj:
3285         * WebView/WebView.mm:
3286         (-[WebView _commonInitializationWithFrameName:groupName:]):
3287
3288 2006-11-06  Geoffrey Garen  <ggaren@apple.com>
3289
3290         Reviewed by Darin.
3291         
3292         Accidentally rolled out this change when removing the WebPageBridge. Now
3293         putting it back.
3294
3295         * WebView/WebView.mm:
3296         (-[WebView _commonInitializationWithFrameName:groupName:]):
3297
3298 2006-11-05  Geoffrey Garen  <ggaren@apple.com>
3299
3300         Reviewed by Maciej, Darin, Anders.
3301
3302         Removed the Page bridge. Beefed up Chrome. Added Screen and ScreenClient.
3303         
3304         (WebChromeClient::pageRect): It may seem weird for the page to ask the Chrome/ChromeClient
3305         about its own dimensions. The idea here is that we're asking the Chrome how
3306         much space it has devoted to the page. We have API for this (-webViewContentRect), but 
3307         it was documented incorrectly (even Safari used it wrong), so we don't use 
3308         it anymore. Once we fix our API/documentation, we can return to making a
3309         delegate callback to ask for the page's size.
3310         (WebChromeClient::createWindow): Changed to take a FrameLoadRequest with
3311         an appropriate referrer, instead of making up its own.
3312         (WebChromeClient::createModalDialog): Changed to take a FrameLoadRequest with
3313         an appropriate referrer, instead of broken out parcels.
3314         * WebCoreSupport/WebPageBridge.h: Removed. Dead Code.
3315         * WebCoreSupport/WebPageBridge.mm: Removed. Dead Code.
3316         * WebCoreSupport/WebScreenClient.h: Added.
3317         * WebCoreSupport/WebScreenClient.mm: Added.
3318         * WebView/WebView.mm: Added NULL checks for new _private->page, since
3319         it's not NULL-safe like the bridge was, and it gets cleared before
3320         dealloc.
3321
3322 2006-11-06  Graham Dennis  <graham.dennis@gmail.com>
3323
3324         Reviewed by Tim Hatcher.
3325
3326         Part of patch for http://bugs.webkit.org/show_bug.cgi?id=11323
3327         Link dragging behaviour does not obey WebKitEditableLinkBehavior WebPref
3328
3329         * DefaultDelegates/WebDefaultUIDelegate.m:
3330         (-[NSApplication webView:dragSourceActionMaskForPoint:]): Logic moved to 
3331         WebHTMLView's _mayStartDragAtEventLocation
3332         * Misc/WebElementDictionary.m: added isLiveLink
3333         (+[WebElementDictionary initializeLookupTable]):
3334         (-[WebElementDictionary _isLiveLink]):
3335         * WebView/WebHTMLView.m: 
3336         (-[WebHTMLView _mayStartDragAtEventLocation:]): Editable links should
3337         only be followed if isLiveLink is true
3338         (-[WebHTMLView _isMoveDrag:]): A drag of a live editable link is not
3339         a move
3340         (-[WebHTMLView draggingUpdatedWithDraggingInfo:actionMask:]):
3341         (-[WebHTMLView concludeDragForDraggingInfo:actionMask:]):
3342         * WebView/WebView.mm: added WebElementLinkIsLiveKey
3343         * WebView/WebViewPrivate.h: ditto
3344
3345 2006-11-04  Maciej Stachowiak  <mjs@apple.com>
3346
3347         Reviewed by Oliver.
3348         
3349         - removed unneeded (and obsolete) header includes
3350
3351         * WebCoreSupport/WebFrameBridge.mm:
3352         * WebView/WebFrame.mm:
3353
3354 2006-11-05  Darin Adler  <darin@apple.com>
3355
3356         - WebKit part of Frame.h check-in (forgot to land it)
3357
3358         * WebCoreSupport/WebFrameBridge.h:
3359         * WebCoreSupport/WebFrameBridge.mm:
3360         (-[WebFrameBridge textViewWasFirstResponderAtMouseDownTime:]):
3361         (-[WebFrameBridge shouldInterruptJavaScript]):
3362         (-[WebFrameBridge saveDocumentState:]):
3363         (-[WebFrameBridge previousKeyViewOutsideWebFrameViews]):
3364         (-[WebFrameBridge valueForKey:keys:values:]):
3365         (-[WebFrameBridge getObjectCacheSize]):
3366         (-[WebFrameBridge startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
3367         (-[WebFrameBridge mayStartDragAtEventLocation:]):
3368         (-[WebFrameBridge canGoBackOrForward:]):
3369         (-[WebFrameBridge goBackOrForward:]):
3370         (-[WebFrameBridge print]):
3371         (-[WebFrameBridge getAppletInView:]):
3372         (-[WebFrameBridge pollForAppletInView:]):
3373         (-[WebFrameBridge respondToChangedContents]):
3374         (-[WebFrameBridge respondToChangedSelection]):
3375         (-[WebFrameBridge setIsSelected:forView:]):
3376
3377 2006-11-04  Darin Adler  <darin@apple.com>
3378
3379         Reviewed by Maciej.
3380
3381         - converted more of the loader machinery to work with cross-platform
3382           data structures instead of Macintosh-specific ones
3383
3384           store the computed user agent string as a WebCore::String instead
3385           of an NSString to avoid overhead converting it every time we get it
3386
3387         * COM/WebFrame.cpp:
3388         (WebFrame::initWithName):
3389         * ChangeLog:
3390         * Misc/WebElementDictionary.m:
3391         (-[WebElementDictionary _image]):
3392         (-[WebElementDictionary _targetWebFrame]):
3393         * WebCoreSupport/WebFrameLoaderClient.h:
3394         * WebCoreSupport/WebFrameLoaderClient.mm:
3395         (WebFrameLoaderClient::dispatchWillPerformClientRedirect):
3396         (WebFrameLoaderClient::shouldTreatURLAsSameAsCurrent):
3397         (WebFrameLoaderClient::setTitle):
3398         (WebFrameLoaderClient::userAgent):
3399         (WebFrameLoaderClient::actionDictionary):
3400         * WebCoreSupport/WebPageBridge.mm:
3401         (WebCore::if):
3402         * WebView/WebDataSource.mm:
3403         (-[WebDataSource _URL]):
3404         (-[WebDataSource _URLForHistory]):
3405         (-[WebDataSource unreachableURL]):
3406         * WebView/WebHTMLView.m:
3407         (-[WebHTMLView elementAtPoint:allowShadowContent:]):
3408         * WebView/WebPDFView.mm:
3409         (-[WebPDFView PDFViewWillClickOnLink:withURL:]):
3410         (-[WebPDFView _path]):
3411         * WebView/WebView.mm:
3412         (-[WebViewPrivate init]):
3413         (-[WebViewPrivate dealloc]):
3414         (-[WebViewPrivate finalize]):
3415         (-[WebView _preferencesChangedNotification:]):
3416         (-[WebView _cachedResponseForURL:]):
3417         (-[WebView setApplicationNameForUserAgent:]):
3418         (-[WebView setCustomUserAgent:]):
3419         (-[WebView customUserAgent]):
3420         (-[WebView userAgentForURL:]):
3421         (-[WebView _computeUserAgent]):
3422         (-[WebView WebCore::]):
3423         * WebView/WebViewInternal.h:
3424
3425 2006-11-04  Bertrand Guiheneuf <guiheneuf@gmail.com>
3426
3427         Reviewed by Maciej, tweaked and landed by Alexey (using a patch by Don Gibson).
3428
3429         http://bugs.webkit.org/show_bug.cgi?id=11433
3430         Fixes to get WebKit to run on Windows; implemented AffineTransformCairo.
3431
3432         * COM/WebFrame.cpp:
3433         (WebFrame::initWithName):
3434         (WebFrame::loadDataSource):
3435         (WebFrame::receivedRedirect):
3436         (WebFrame::receivedResponse):
3437         (WebFrame::didReceiveData):
3438         (WebFrame::receivedAllData):
3439         Use resource handles now. Do not start doc loader by hand anymore. 
3440         Handle didReceiveData() callback instead of receivedData() which 
3441         is deprecated in implementation of ResourceHandleClient        
3442
3443         * COM/WebFrame.h:
3444         * COM/WebView.cpp:
3445         Applied ResourceLoader --> ResourceHandle renaming
3446
3447         * WebKit.vcproj/WebKit.rc:
3448         Got rid of MFC dependencies (build fix for VCExpress).
3449
3450         * WebKit.vcproj/WebKit.vcproj:
3451         Added platform/graphics platform/network and platform/network/win 
3452         to headers search paths
3453
3454 2006-11-03  Geoffrey Garen  <ggaren@apple.com>
3455
3456         Forgot to add these two files. Oops.
3457
3458         * WebCoreSupport/WebChromeClient.h: Added.
3459         * WebCoreSupport/WebChromeClient.mm: Added.
3460
3461 2006-11-02  Geoffrey Garen  <ggaren@apple.com>
3462
3463         Reviewed by Darin, Beth.
3464
3465         First cut at factoring Page's UIDelegate-related functions into Chrome
3466         and ChromeClient.
3467
3468         Layout tests pass.
3469         
3470         * WebCoreSupport/WebEditorClient.h:
3471         * WebCoreSupport/WebPageBridge.mm:
3472         * WebKit.xcodeproj/project.pbxproj:
3473
3474 2006-11-02  Timothy Hatcher  <timothy@apple.com>
3475
3476         Reviewed by Brady.
3477
3478         Adding outdent to the WebView responder forwarding list.
3479         Also add outdent to WebHTMLView.h and WebViewPrivate.h.
3480
3481         * WebView/WebHTMLView.h:
3482         * WebView/WebViewPrivate.h:
3483         * WebView/WebView.mm:
3484
3485 2006-11-01  John Sullivan  <sullivan@apple.com>
3486
3487         Reviewed by Adam Roben
3488         
3489         - fixed <rdar://problem/4801351> Crash reloading PDF file in new Safari (or closing a window containing a PDF file)
3490
3491         * WebView/WebPDFView.mm:
3492         (-[WebPDFView initWithFrame:]):
3493         Retain the PDFSubview in the code path where we just obtain it by asking the PDFPreviewView for it. We were
3494         unconditionally releasing it in dealloc, but only retaining it in one of the two code paths.
3495
3496 2006-10-31  Mark Rowe  <bdash@webkit.org>
3497
3498         Reviewed by Maciej.
3499
3500         Fix null pointer dereference while running editing/pasteboard/drag-drop-modifies-page.html
3501
3502         * Misc/WebElementDictionary.m:
3503         (-[WebElementDictionary _image]): Add null check.
3504
3505 2006-10-31  Beth Dakin  <bdakin@apple.com>
3506
3507         Reviewed by Maciej.
3508
3509         This creates local functions for the remaining WebElementDictionary 
3510         members that calls into HitTestResult instead of doing magical 
3511         things with the Objective-C DOM classes.
3512
3513         * ChangeLog:
3514         * Misc/WebElementDictionary.m:
3515         (addLookupKey): The values of the dictionary are now just 
3516         selectors. They used to be WebElementMethods which were 
3517         WebElementTargetObjects associated with selectors, but none of that 
3518         is needed any more.
3519         (+[WebElementDictionary initializeLookupTable]): All selectors are 
3520         now local functions, no more WebElementTargetObjects.
3521         (-[WebElementDictionary objectForKey:]): No more target objects!
3522         (-[WebElementDictionary _domNode]): Call into HitTestResult member 
3523         variable.
3524         (-[WebElementDictionary _altDisplayString]): Same.
3525         (-[WebElementDictionary _image]): Same.
3526         (-[WebElementDictionary _absoluteImageURL]): Same.
3527         (-[WebElementDictionary _title]): Same.
3528         (-[WebElementDictionary _absoluteLinkURL]): Same.
3529         (-[WebElementDictionary _targetWebFrame]): Same.
3530         (-[WebElementDictionary _titleDisplayString]): Same.
3531         (-[WebElementDictionary _textContent]): Same.
3532
3533 2006-10-31  Geoffrey Garen  <ggaren@apple.com>
3534
3535         Reviewed by Alice.
3536         
3537         Moved some Editing code from WebKit, the bridge, and WebCore::Frame down 
3538         to WebCore::Editor.
3539
3540         * WebCoreSupport/WebFrameBridge.mm:
3541         * WebView/WebHTMLView.m:
3542         (-[WebHTMLView _shouldDeleteRange:]):
3543         (-[WebHTMLView _canCopy]):
3544         (-[WebHTMLView _canCut]):
3545         (-[WebHTMLView _canDelete]):
3546         (-[WebHTMLView _canPaste]):
3547         (-[WebHTMLView _canEdit]):
3548         (-[WebHTMLView _canEditRichly]):
3549         (-[WebHTMLView _isEditable]):
3550         (-[WebHTMLView _isSelectionInPasswordField]):
3551         (-[NSArray validateUserInterfaceItem:]):
3552         (-[NSArray _expandSelectionToGranularity:]):
3553
3554 2006-10-31  John Sullivan  <sullivan@apple.com>
3555
3556         Reviewed by Beth and Adam
3557         
3558         Display a tooltip when hovering over marked bad grammar.
3559
3560         * Misc/WebElementDictionary.m:
3561         (+[WebElementDictionary initializeLookupTable]):
3562         support spelling tool tip
3563         (-[WebElementDictionary _spellingToolTip]):
3564         new method, calls through to HitTestResult
3565         
3566         * WebView/WebHTMLView.m:
3567         (-[WebHTMLView _updateMouseoverWithEvent:]):
3568         Check for a spelling tool tip; if found, prefer it over the other possible tool tips.
3569         Check for empty strings instead of just nil strings being, since values from 
3570         WebElementDictionary are empty strings.
3571         
3572         * WebView/WebViewPrivate.h:
3573         declare new string constant WebElementSpellingToolTipKey
3574         * WebView/WebView.mm:
3575         define new string constant WebElementSpellingToolTipKey
3576         
3577 2006-10-31  Beth Dakin  <bdakin@apple.com>
3578
3579         Reviewed by Maciej.
3580
3581         Small tweaks to WebKit because of http://bugs.webkit.org/
3582         show_bug.cgi?id=11461 HitTestResult should be split into 
3583         HitTestRequest and HitTestResult
3584
3585         * WebKit.xcodeproj/project.pbxproj:
3586         * WebView/WebHTMLView.m:
3587         (-[WebHTMLView elementAtPoint:allowShadowContent:]): The 
3588         HitTestResult initializer now just takes a point.
3589
3590 2006-10-31  Darin Adler  <darin@apple.com>
3591
3592         Reviewed by Brady.
3593
3594         - got "action dictionary" code out of FrameLoader,
3595           replacing with a class called NavigationAction
3596
3597         * WebCoreSupport/WebFrameLoaderClient.h: Changed parameter types to NavigationAction.
3598         Made elementForEvent non-virtual. Added actionDictionary function.
3599         * WebCoreSupport/WebFrameLoaderClient.mm:
3600         (WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction): Changed parameter type,
3601         and used actionDictionary to make the action dictionary.
3602         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction): Ditto.
3603         (WebFrameLoaderClient::actionDictionary): Added. Code that was originally in WebCore
3604         that creates the action dictionary (from a NavigationAction).
3605
3606         * WebView/WebFrame.mm: (-[WebFrame _loadItem:withLoadType:]): Use NavigationAction
3607         instead of a dictionary for the action parameters.
3608
3609 2006-10-31  Marvin Decker  <marv.decker@gmail.com>
3610
3611         Reviewed by Maciej.