7233a4ec0680446dcdf4468ab92b9dc6c6dd62ae
[WebKit-https.git] / WebCore / ChangeLog
1 2006-12-14  Zack Rusin  <zack@kde.org>
2
3         Make it link with temporary stubs.
4
5         * loader/qt/DocumentLoaderQt.cpp:
6         (WebCore::DocumentLoader::originalRequest):
7         (WebCore::DocumentLoader::originalRequestCopy):
8         (WebCore::DocumentLoader::request):
9         (WebCore::DocumentLoader::initialRequest):
10         (WebCore::DocumentLoader::actualRequest):
11         (WebCore::DocumentLoader::URL):
12
13 2006-12-14  Zack Rusin  <zack@kde.org>
14
15         Compilation fixes for the Qt port after last nights
16         changes.
17
18         * loader/qt/DocumentLoaderQt.cpp:
19         (WebCore::DocumentLoader::URL):
20         (WebCore::DocumentLoader::unreachableURL):
21         * loader/qt/FrameLoaderQt.cpp:
22         (WebCore::PolicyCheck::call):
23         * platform/network/ResourceRequest.h:
24         (WebCore::ResourceRequest::setHTTPReferrer):
25
26 2006-12-14  Rob Buis  <buis@kde.org>
27
28         Reviewed by Oliver.
29
30         http://bugs.webkit.org/show_bug.cgi?id=11726
31         SVG Image do not take into account clip/overflow when hit testing
32
33         Take into account the overflowRect when hit-testing <svg> container.
34
35         * rendering/RenderSVGContainer.cpp:
36         (WebCore::RenderSVGContainer::viewportTransform):
37         (WebCore::RenderSVGContainer::nodeAtPoint):
38         * rendering/RenderSVGContainer.h:
39
40 2006-12-13  David Hyatt  <hyatt@apple.com>
41
42         Fix for bug 11825, dragging elements via -khtml-user-drag is broken (affects Dashboard).  Make sure
43         to clear the paintingRoot properly when recurring into children.  It would be nice to find a design
44         that prevented this mistake from being made and didn't require explicit clearing of the root.
45
46         Reviewed by olliej
47
48         * rendering/InlineFlowBox.cpp:
49         (WebCore::InlineFlowBox::paint):
50         * rendering/RenderBlock.cpp:
51         (WebCore::RenderBlock::paintChildren):
52         * rendering/RenderBox.cpp:
53         (WebCore::RenderBox::paint):
54         * rendering/RenderTable.cpp:
55         (WebCore::RenderTable::paint):
56
57 2006-12-13  Anders Carlsson  <acarlsson@apple.com>
58
59         * loader/FrameLoader.h:
60         id is mac-only.
61         
62 2006-12-13  Brady Eidson  <beidson@apple.com>
63
64         Implicitly reviewed by Darin, Hyatt, Maciej, and others!
65
66         Fixes a document tear down crash.
67         Changes a few long standing assertions to our new style
68
69         * dom/Document.cpp:
70         (WebCore::Document::~Document):
71         (WebCore::Document::topDocument):
72
73 2006-12-13  Maciej Stachowiak  <mjs@apple.com>
74
75         Reviewed by Anders.
76
77         - converted many places to use ResourceRequest instead of NSURLRequest
78
79         * WebCore.exp:
80         * loader/DocumentLoader.h:
81         * loader/FrameLoader.cpp:
82         (WebCore::FrameLoader::stopPolicyCheck):
83         * loader/FrameLoader.h:
84         (WebCore::PolicyCheck::request):
85         * loader/FrameLoaderClient.h:
86         * loader/MainResourceLoader.h:
87         * loader/mac/DocumentLoaderMac.mm:
88         (WebCore::DocumentLoader::DocumentLoader):
89         (WebCore::DocumentLoader::originalRequest):
90         (WebCore::DocumentLoader::originalRequestCopy):
91         (WebCore::DocumentLoader::request):
92         (WebCore::DocumentLoader::initialRequest):
93         (WebCore::DocumentLoader::actualRequest):
94         (WebCore::DocumentLoader::URL):
95         (WebCore::DocumentLoader::unreachableURL):
96         (WebCore::DocumentLoader::replaceRequestURLForAnchorScroll):
97         (WebCore::DocumentLoader::setRequest):
98         (WebCore::DocumentLoader::stopLoading):
99         (WebCore::DocumentLoader::setLastCheckedRequest):
100         (WebCore::DocumentLoader::lastCheckedRequest):
101         (WebCore::DocumentLoader::URLForHistory):
102         * loader/mac/FrameLoaderMac.mm:
103         (WebCore::FrameLoader::load):
104         (WebCore::FrameLoader::startLoadingMainResource):
105         (WebCore::FrameLoader::applyUserAgent):
106         (WebCore::FrameLoader::originalRequest):
107         (WebCore::FrameLoader::receivedMainResourceError):
108         (WebCore::FrameLoader::callContinueFragmentScrollAfterNavigationPolicy):
109         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
110         (WebCore::FrameLoader::commitProvisionalLoad):
111         (WebCore::FrameLoader::initialRequest):
112         (WebCore::FrameLoader::setRequest):
113         (WebCore::FrameLoader::checkNavigationPolicy):
114         (WebCore::FrameLoader::shouldReloadToHandleUnreachableURL):
115         (WebCore::FrameLoader::reloadAllowingStaleData):
116         (WebCore::FrameLoader::reload):
117         (WebCore::FrameLoader::checkNewWindowPolicy):
118         (WebCore::FrameLoader::continueAfterNewWindowPolicy):
119         (WebCore::FrameLoader::continueAfterNavigationPolicy):
120         (WebCore::FrameLoader::callContinueLoadAfterNavigationPolicy):
121         (WebCore::FrameLoader::continueLoadAfterNavigationPolicy):
122         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
123         (WebCore::FrameLoader::callContinueLoadAfterNewWindowPolicy):
124         (WebCore::FrameLoader::continueLoadAfterNewWindowPolicy):
125         (WebCore::FrameLoader::post):
126         (WebCore::FrameLoader::addExtraFieldsToRequest):
127         (WebCore::FrameLoader::isReloading):
128         (WebCore::FrameLoader::referrer):
129         (WebCore::FrameLoader::loadEmptyDocumentSynchronously):
130         (WebCore::FrameLoader::loadResourceSynchronously):
131         (WebCore::FrameLoader::originalRequestURL):
132         (WebCore::PolicyCheck::set):
133         (WebCore::PolicyCheck::call):
134         (WebCore::PolicyCheck::clearRequest):
135         * loader/mac/MainResourceLoaderMac.mm:
136         (WebCore::MainResourceLoader::callContinueAfterNavigationPolicy):
137         (WebCore::MainResourceLoader::continueAfterNavigationPolicy):
138         (WebCore::MainResourceLoader::isPostOrRedirectAfterPost):
139         * loader/mac/SubresourceLoaderMac.mm:
140         (WebCore::SubresourceLoader::create):
141         * loader/mac/WebDataProtocol.h:
142         * loader/mac/WebDataProtocol.mm:
143         * platform/KURL.cpp:
144         (WebCore::operator!=):
145         * platform/KURL.h:
146         * platform/mac/KURLMac.mm:
147         (WebCore::KURL::getNSURL):
148         * platform/network/FormData.h:
149         (WebCore::operator==):
150         (WebCore::operator!=):
151         * platform/network/ResourceRequest.cpp:
152         (WebCore::operator==):
153         * platform/network/ResourceRequest.h:
154         * platform/network/mac/ResourceRequestMac.mm:
155         (WebCore::ResourceRequest::doUpdatePlatformRequest):
156
157 2006-12-13  Geoffrey Garen  <ggaren@apple.com>
158
159         Reviewed by Darin Adler, Dave Hyatt.
160         
161         Beefed up FocusController to handle frame focus. Changed implementors to
162         use FocusController, rather than the widget hierarchy, to focus frames.
163
164         (WebCore::FocusController::focusedNode): Made a minor change to focus a frame
165         before focusing the element inside of it. This matches FF.
166         (WebCore::FocusController::focusedFrame):
167         * platform/Widget.h:
168
169 2006-12-13  Justin Garcia  <justin.garcia@apple.com>
170
171         Reviewed by adele
172
173         <rdar://problem/4818145>
174         Cannot setSelectedDOMRange to non-editable island unless it has editable content on both sides
175         
176         There are editable positions before/after a "non-editable island" if its 
177         a table, but the code in canonicalPosition was not using 
178         editableRootForPosition to find root editable elements.
179         
180         * editing/VisiblePosition.cpp:
181         (WebCore::VisiblePosition::canonicalPosition): Use editableRootForPosition
182         to fix the table case.
183
184 2006-12-13  Steve Falkenburg  <sfalken@apple.com>
185
186         Reviewed by Adam.
187
188         Added missing forwarding headers.        
189
190         * ForwardingHeaders/kjs/value.h: Added.
191         * ForwardingHeaders/wtf/HashTable.h: Added.
192
193 2006-12-13  Lars Knoll <lars@trolltech.com>
194
195         Reviewed by Maciej, Zack.
196
197         Make the Qt cbuild compile again.
198
199         * WebCore.pro:
200         * loader/qt/ResourceLoaderQt.cpp:
201         * platform/network/qt/ResourceHandleQt.cpp:
202         (WebCore::ResourceHandle::start):
203         (WebCore::ResourceHandle::loadsBlocked):
204         * platform/qt/FrameQtClient.cpp:
205         (WebCore::FrameQtClient::openURL):
206         (WebCore::FrameQtClient::submitForm):
207
208 2006-12-12  Adam Roben  <aroben@apple.com>
209
210         Reviewed by Anders.
211
212         Changed #import to #include to match the rest of our ForwardingHeaders.
213
214         * ForwardingHeaders/wtf/StringExtras.h:
215
216 2006-12-12  Justin Garcia  <justin.garcia@apple.com>
217
218         Reviewed by harrison
219         
220         <rdar://problem/4757667>
221         GoogleDocs: Style menu does not open
222
223         * bindings/js/kjs_window.cpp:
224         (KJS::Selection::getValueProperty): Added rangeCount.
225         * bindings/js/kjs_window.h:
226         (KJS::Selection::):
227         * editing/SelectionController.h:
228         (WebCore::SelectionController::rangeCount): Added.
229
230 2006-12-12  Alice Liu  <alice.liu@apple.com>
231
232         Reviewed by Oliver.
233
234         * bindings/js/JSSVGMatrixCustom.cpp:
235         added #ifdef SVG_SUPPORT
236
237 2006-12-12  Anders Carlsson  <acarlsson@apple.com>
238
239         Suggested by Darin.
240
241         * loader/ResourceLoader.cpp:
242         Move down include of ResourceHandle.h.
243
244 2006-12-12  Geoffrey Garen  <ggaren@apple.com>
245
246         Reviewed by Adam Roben, Dave Hyatt, Darin Adler.
247         
248         Factored focus control into a FocusController class. I inted to use this
249         class for handling window active state and the focused frame, as well.
250
251         Layout tests pass.
252
253         * WebCore.xcodeproj/project.pbxproj:
254         * dom/Document.cpp:
255         (WebCore::Document::view):
256         (WebCore::Document::page): New helper function.
257         * dom/Document.h: Moved setters before getters.
258         (WebCore::Document::hoverNode):
259         (WebCore::Document::activeNode):
260         * dom/Node.cpp:
261         (WebCore::Node::detach): Use the FocusController.
262         * page/FocusController.cpp: Added.
263         (WebCore::shouldFocus): renamed and refactored this helper function.
264         (WebCore::shouldUnfocus): ditto.
265         * page/FocusController.h: Added.
266
267 2006-12-12  Anders Carlsson  <acarlsson@apple.com>
268
269         Rubber Stamped by Geoff.
270
271         * platform/Base64.cpp:
272         * platform/Base64.h:
273         Put functions inside of the WebCore namespace.
274
275 2006-12-12  Anders Carlsson  <acarlsson@apple.com>
276
277         Try fixing the non-Mac builds.
278         
279         * loader/ResourceLoader.cpp:
280         (WebCore::ResourceLoader::willSendRequest):
281         (WebCore::ResourceLoader::didReceiveResponse):
282         (WebCore::ResourceLoader::didReceiveData):
283         (WebCore::ResourceLoader::didFinishLoading):
284         (WebCore::ResourceLoader::didFail):
285         * loader/SubresourceLoader.cpp:
286         (WebCore::SubresourceLoader::create):
287         * loader/SubresourceLoader.h:
288
289 2006-12-12  Anders Carlsson  <acarlsson@apple.com>
290
291         Reviewed by Darin.
292
293         Turn ResourceLoader into a ResourceHandleClient and stop using NSURLConnection in the loader.
294
295         * WebCore.exp:
296         Add new methods needed by WebKit.
297         
298         * WebCore.xcodeproj/project.pbxproj:
299         Make ResourceHandle.h a private header.
300         
301         * loader/FrameLoaderClient.h:
302         Change the download method to take a ResourceHandle instead of an NSURLConnection.
303         
304         * loader/MainResourceLoader.h:
305         Get rid of the proxy instance variable, that's handled by ResourceHandlw now.
306         
307         * loader/ResourceLoader.h:
308         (WebCore::ResourceLoader::didReceiveAuthenticationChallenge):
309         (WebCore::ResourceLoader::didCancelAuthenticationChallenge):
310         (WebCore::ResourceLoader::willStopBufferingData):
311         (WebCore::ResourceLoader::willCacheResponse):
312         (WebCore::ResourceLoader::receivedCredential):
313         (WebCore::ResourceLoader::receivedRequestToContinueWithoutCredential):
314         (WebCore::ResourceLoader::receivedCancellation):
315         (WebCore::ResourceLoader::handle):
316         * loader/SubresourceLoader.h:
317         Make ResourceLoader a ResourceHandleClient, moving the methods from SubresourceLoader.
318         
319         * loader/mac/MainResourceLoaderMac.mm:
320         (WebCore::MainResourceLoader::MainResourceLoader):
321         (WebCore::MainResourceLoader::continueAfterContentPolicy):
322         (WebCore::MainResourceLoader::loadNow):
323         (WebCore::MainResourceLoader::load):
324         Use a ResourceHandle instead of an NSURLConnection.
325         
326         * loader/mac/ResourceLoaderMac.mm:
327         (WebCore::ResourceLoader::~ResourceLoader):
328         (WebCore::ResourceLoader::releaseResources):
329         (WebCore::ResourceLoader::load):
330         (WebCore::ResourceLoader::setDefersLoading):
331         (WebCore::ResourceLoader::resourceData):
332         (WebCore::ResourceLoader::didReceiveAuthenticationChallenge):
333         (WebCore::ResourceLoader::didCancel):
334         (WebCore::ResourceLoader::willSendRequest):
335         (WebCore::ResourceLoader::didReceiveResponse):
336         (WebCore::ResourceLoader::didReceiveData):
337         (WebCore::ResourceLoader::didFinishLoading):
338         (WebCore::ResourceLoader::didFail):
339         Remove the WebCoreResourceLoaderAsDelegate class, use a ResourceHandle instead of an NSURLConnection.
340         
341         * loader/mac/SubresourceLoaderMac.mm:
342         Remove ResourceHandleClient methods.
343         
344         * platform/network/ResourceHandle.cpp:
345         (WebCore::ResourceHandle::ResourceHandle):
346         (WebCore::ResourceHandle::create):
347         * platform/network/ResourceHandle.h:
348         * platform/network/ResourceHandleInternal.h:
349         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
350         Add an extra argument denoting whether this ResourceHandle can possibly be "converted" into one used for downloads.
351         
352         * platform/network/mac/ResourceHandleMac.mm:
353         (WebCore::ResourceHandle::~ResourceHandle):
354         (WebCore::ResourceHandle::start):
355         (WebCore::ResourceHandle::releaseProxy):
356         (WebCore::ResourceHandle::connection):
357         New methods for creating a NSURLConnectionDelegateProxy which is used when creating a NSURLDownload from an existing
358         connection.
359
360 2006-12-12  Anders Carlsson  <acarlsson@apple.com>
361
362         Reviewed by Geoff.
363
364         * loader/mac/SubresourceLoaderMac.mm:
365         (WebCore::SubresourceLoader::load):
366         * platform/network/mac/ResourceHandleMac.mm:
367         (WebCore::ResourceHandle::start):
368         Move the didTellBridgeAboutLoad call to SubresourceLoader in preparation for getting rid of
369         the DocLoader parameter to ResourceHandle::create.
370
371 2006-12-12  George Staikos  <staikos@kde.org>
372
373         Make the last checkin compile.
374
375         * WebCore.pro:
376         * ksvg2/svg/SVGTransform.cpp:
377
378 2006-12-12  Nikolas Zimmermann  <zimmermann@kde.org>
379
380         Reviewed by Sam Weinig & Rob Buis.
381
382         Fixes: http://bugs.webkit.org/show_bug.cgi?id=11797
383
384         Remove SVGMatrix, replace it by AffineTransform usage everywhere.
385         Changed AffineTransform API to be able to be used within generation
386         (m11() -> a(), m12() -> b(), ...). Add some methods needed for SVG.
387
388         The actual SVGMatrix -> AffineTransformation patch has been created
389         by Rob - I just adapted it to the autogenerated POD style.
390
391         * WebCore.xcodeproj/project.pbxproj:
392         * bindings/js/JSSVGMatrixCustom.cpp: Added.
393         (WebCore::JSSVGMatrix::inverse):
394         (WebCore::JSSVGMatrix::rotateFromVector):
395         * bindings/objc/DOMInternal.h:
396         * bindings/scripts/CodeGeneratorJS.pm:
397         * bindings/scripts/CodeGeneratorObjC.pm:
398         * ksvg2/misc/KSVGTimeScheduler.cpp:
399         * ksvg2/misc/SVGImageLoader.cpp:
400         * ksvg2/svg/SVGAnimateTransformElement.cpp:
401         (WebCore::SVGAnimateTransformElement::handleTimerEvent):
402         (WebCore::SVGAnimateTransformElement::calculateRotationFromMatrix):
403         (WebCore::SVGAnimateTransformElement::initialMatrix):
404         (WebCore::SVGAnimateTransformElement::transformMatrix):
405         * ksvg2/svg/SVGAnimateTransformElement.h:
406         * ksvg2/svg/SVGClipPathElement.cpp:
407         (WebCore::SVGClipPathElement::canvasResource):
408         * ksvg2/svg/SVGFitToViewBox.cpp:
409         (WebCore::SVGFitToViewBox::viewBoxToViewTransform):
410         * ksvg2/svg/SVGFitToViewBox.h:
411         * ksvg2/svg/SVGLengthList.cpp:
412         * ksvg2/svg/SVGLinearGradientElement.cpp:
413         (WebCore::SVGLinearGradientElement::buildGradient):
414         * ksvg2/svg/SVGLocatable.cpp:
415         (WebCore::SVGLocatable::getCTM):
416         (WebCore::SVGLocatable::getScreenCTM):
417         (WebCore::SVGLocatable::getTransformToElement):
418         * ksvg2/svg/SVGLocatable.h:
419         * ksvg2/svg/SVGMarkerElement.cpp:
420         * ksvg2/svg/SVGMatrix.cpp: Removed.
421         * ksvg2/svg/SVGMatrix.h: Removed.
422         * ksvg2/svg/SVGMatrix.idl:
423         * ksvg2/svg/SVGNumberList.cpp:
424         * ksvg2/svg/SVGPatternElement.cpp:
425         (WebCore::SVGPatternElement::notifyAttributeChange):
426         (WebCore::SVGPatternElement::getCTM):
427         * ksvg2/svg/SVGPatternElement.h:
428         * ksvg2/svg/SVGPoint.idl:
429         * ksvg2/svg/SVGPreserveAspectRatio.cpp:
430         (WebCore::SVGPreserveAspectRatio::getCTM):
431         * ksvg2/svg/SVGPreserveAspectRatio.h:
432         * ksvg2/svg/SVGRadialGradientElement.cpp:
433         (WebCore::SVGRadialGradientElement::buildGradient):
434         * ksvg2/svg/SVGSVGElement.cpp:
435         (WebCore::SVGSVGElement::viewport):
436         (WebCore::SVGSVGElement::createSVGMatrix):
437         (WebCore::SVGSVGElement::createSVGTransformFromMatrix):
438         (WebCore::SVGSVGElement::getCTM):
439         (WebCore::SVGSVGElement::getScreenCTM):
440         * ksvg2/svg/SVGSVGElement.h:
441         * ksvg2/svg/SVGStyledElement.cpp:
442         * ksvg2/svg/SVGStyledLocatableElement.cpp:
443         (WebCore::SVGStyledLocatableElement::getCTM):
444         (WebCore::SVGStyledLocatableElement::getScreenCTM):
445         * ksvg2/svg/SVGStyledLocatableElement.h:
446         * ksvg2/svg/SVGStyledTransformableElement.cpp:
447         (WebCore::SVGStyledTransformableElement::localMatrix):
448         (WebCore::SVGStyledTransformableElement::getCTM):
449         (WebCore::SVGStyledTransformableElement::getScreenCTM):
450         (WebCore::SVGStyledTransformableElement::updateLocalTransform):
451         (WebCore::SVGStyledTransformableElement::attach):
452         * ksvg2/svg/SVGStyledTransformableElement.h:
453         * ksvg2/svg/SVGTextElement.cpp:
454         (WebCore::SVGTextElement::localMatrix):
455         (WebCore::SVGTextElement::updateLocalTransform):
456         (WebCore::SVGTextElement::attach):
457         (WebCore::SVGTextElement::getScreenCTM):
458         (WebCore::SVGTextElement::getCTM):
459         * ksvg2/svg/SVGTextElement.h:
460         * ksvg2/svg/SVGTransform.cpp:
461         (SVGTransform::SVGTransform):
462         (SVGTransform::matrix):
463         (SVGTransform::setMatrix):
464         (SVGTransform::setTranslate):
465         (SVGTransform::setScale):
466         (SVGTransform::setRotate):
467         (SVGTransform::setSkewX):
468         (SVGTransform::setSkewY):
469         * ksvg2/svg/SVGTransform.h:
470         * ksvg2/svg/SVGTransformList.cpp:
471         (SVGTransformList::createSVGTransformFromMatrix):
472         (SVGTransformList::concatenate):
473         * ksvg2/svg/SVGTransformList.h:
474         * ksvg2/svg/SVGTransformable.cpp:
475         (WebCore::SVGTransformable::getCTM):
476         (WebCore::SVGTransformable::getScreenCTM):
477         (WebCore::SVGTransformable::parseTransformAttribute):
478         * ksvg2/svg/SVGTransformable.h:
479         * platform/graphics/AffineTransform.cpp:
480         (WebCore::AffineTransform::multiply):
481         (WebCore::AffineTransform::scale):
482         (WebCore::AffineTransform::scaleNonUniform):
483         (WebCore::AffineTransform::rotateFromVector):
484         (WebCore::AffineTransform::flipX):
485         (WebCore::AffineTransform::flipY):
486         (WebCore::AffineTransform::skewX):
487         (WebCore::AffineTransform::skewY):
488         * platform/graphics/AffineTransform.h:
489         * platform/graphics/cairo/AffineTransformCairo.cpp:
490         (WebCore::AffineTransform::a):
491         (WebCore::AffineTransform::setA):
492         (WebCore::AffineTransform::b):
493         (WebCore::AffineTransform::setB):
494         (WebCore::AffineTransform::c):
495         (WebCore::AffineTransform::setC):
496         (WebCore::AffineTransform::d):
497         (WebCore::AffineTransform::setD):
498         (WebCore::AffineTransform::e):
499         (WebCore::AffineTransform::setE):
500         (WebCore::AffineTransform::f):
501         (WebCore::AffineTransform::setF):
502         (WebCore::AffineTransform::inverse):
503         * platform/graphics/cg/AffineTransformCG.cpp:
504         (WebCore::AffineTransform::a):
505         (WebCore::AffineTransform::setA):
506         (WebCore::AffineTransform::b):
507         (WebCore::AffineTransform::setB):
508         (WebCore::AffineTransform::c):
509         (WebCore::AffineTransform::setC):
510         (WebCore::AffineTransform::d):
511         (WebCore::AffineTransform::setD):
512         (WebCore::AffineTransform::e):
513         (WebCore::AffineTransform::setE):
514         (WebCore::AffineTransform::f):
515         (WebCore::AffineTransform::setF):
516         (WebCore::AffineTransform::inverse):
517         * platform/graphics/qt/AffineTransformQt.cpp:
518         (WebCore::AffineTransform::a):
519         (WebCore::AffineTransform::setA):
520         (WebCore::AffineTransform::b):
521         (WebCore::AffineTransform::setB):
522         (WebCore::AffineTransform::c):
523         (WebCore::AffineTransform::setC):
524         (WebCore::AffineTransform::d):
525         (WebCore::AffineTransform::setD):
526         (WebCore::AffineTransform::e):
527         (WebCore::AffineTransform::setE):
528         (WebCore::AffineTransform::f):
529         (WebCore::AffineTransform::setF):
530         (WebCore::AffineTransform::inverse):
531         * rendering/RenderForeignObject.cpp:
532         (WebCore::RenderForeignObject::paint):
533         (WebCore::RenderForeignObject::nodeAtPoint):
534         * rendering/RenderPath.cpp:
535         (WebCore::RenderPath::mapAbsolutePointToLocal):
536         * rendering/RenderSVGImage.cpp:
537         (WebCore::RenderSVGImage::paint):
538         (WebCore::RenderSVGImage::nodeAtPoint):
539         * rendering/RenderSVGText.cpp:
540         (WebCore::RenderSVGText::computeAbsoluteRepaintRect):
541         (WebCore::RenderSVGText::nodeAtPoint):
542         (WebCore::RenderSVGText::paint):
543         * rendering/SVGInlineFlowBox.cpp:
544         (WebCore::paintSVGInlineFlow):
545         * rendering/SVGRenderTreeAsText.cpp:
546         (WebCore::operator<<):
547
548 2006-12-12  George Staikos  <staikos@kde.org>
549
550         Reviewed by Alexey.
551
552         Fix the Qt build again.
553
554         * WebCore.pro:
555         * loader/qt/FrameLoaderQt.cpp:
556         (WebCore::FrameLoader::createFrame):
557         (WebCore::FrameLoader::load):
558         * platform/qt/PasteboardQt.cpp:
559         (WebCore::Pasteboard::writeSelection):
560         (WebCore::Pasteboard::writeURL):
561         (WebCore::Pasteboard::clear):
562
563 2006-12-12  Geoffrey Garen  <ggaren@apple.com>
564
565         Reviewed by Beth Dakin.
566         
567         Moved focus control to the page level. Fixed a minor bug where a node
568         would retain keyboard focus even when removed from the document.
569         
570         We should probably move this, along with hover and active, into a separate
571         FocusController. But I'm too tired right now.
572
573         * dom/Document.cpp: Migrated code to Page
574         (WebCore::Document::removedLastRef):
575         (WebCore::Document::detach):
576         (WebCore::Document::setFocusedNode):
577         (WebCore::Document::focusedNode):
578         * dom/Document.h:
579         * dom/Node.cpp:
580         (WebCore::Node::detach): Clear ourselves from keyboard focus. This fixes
581         the minor bug and was also necessary to prevent regressions caused by hanging
582         on to a focused node after the document was replaced.
583         * dom/Node.h:
584         (WebCore::Node::inDetach):
585         * page/Page.cpp: Migrated code from Document
586         (WebCore::shouldAcquireEditingFocus):
587         (WebCore::shouldRelinquishEditingFocus):
588         (WebCore::clearSelectionIfNeeded):
589         (WebCore::widgetForNode):
590         (WebCore::Page::setFocusedNode):
591         * page/Page.h:
592         (WebCore::Page::focusedNode):
593
594 2006-12-11  Alexey Proskuryakov  <ap@webkit.org>
595
596         Reviewed by Darin.
597
598         http://bugs.webkit.org/show_bug.cgi?id=11053
599         XMLHttpRequest should be an EventTarget
600
601         Test: http/tests/xmlhttprequest/event-target.html
602
603         * bindings/js/JSXMLHttpRequest.cpp:
604         (KJS::JSXMLHttpRequest::mark):
605         (KJS::JSXMLHttpRequest::~JSXMLHttpRequest):
606         (KJS::JSXMLHttpRequestProtoFunc::callAsFunction):
607         * bindings/js/JSXMLHttpRequest.h:
608         (KJS::JSXMLHttpRequest::):
609         * xml/xmlhttprequest.cpp:
610         (WebCore::XMLHttpRequest::addEventListener):
611         (WebCore::XMLHttpRequest::removeEventListener):
612         (WebCore::XMLHttpRequest::dispatchEvent):
613         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
614         * xml/xmlhttprequest.h:
615         (WebCore::XMLHttpRequest::eventListeners):
616         Implement EventTarget methods (except for NS variations, which Firefox doesn't have either).
617
618 2006-12-11  Darin Adler  <darin@apple.com>
619
620         Reviewed by Geoff.
621
622         - fix http://bugs.webkit.org/show_bug.cgi?id=11809
623           fast/dom/gc-8.html crash in alternate-thread marking code in ScriptInterpreter
624
625         DocumentType objects were getting filed under the wrong document in the
626         DOM objects structure.
627
628         * bindings/js/kjs_binding.h: Added a destructor for debugging purposes only.
629         * bindings/js/kjs_binding.cpp:
630         (KJS::wrapperSet): Added. Set of outstanding wrappers for debugging.
631         (KJS::addWrapper): Added.
632         (KJS::removeWrapper): Added.
633         (KJS::removeWrappers): Added.
634         (KJS::DOMObject::~DOMObject): Added. Asserts that there is no outstanding reference
635         to this wrapper since it's being destroyed.
636         (KJS::ScriptInterpreter::putDOMObject): Added a call to ADD_WRAPPER.
637         (KJS::ScriptInterpreter::forgetDOMObject): Added a call to REMOVE_WRAPPER.
638         (KJS::ScriptInterpreter::forgetDOMNodeForDocument): Added a call to REMOVE_WRAPPER.
639         (KJS::ScriptInterpreter::putDOMNodeForDocument): Added a call to ADD_WRAPPER.
640         (KJS::ScriptInterpreter::forgetAllDOMNodesForDocument): Added a call to REMOVE_WRAPPERS.
641         (KJS::ScriptInterpreter::updateDOMNodeDocument): Added calls to REMOVE_WRAPPER and
642         ADD_WRAPPER so the out-of-order transaction doesn't upset the assertions in the functions
643         we're calling. Another solution would be to reorder the two, but I think that would
644         create a race where another thread could garbage collect after the forget but before the put.
645         (KJS::ScriptInterpreter::wasRunByUserGesture): Tweaked formatting.
646
647         * dom/Document.cpp: (WebCore::Document::adoptNode): Removed call to updateDOMNodeDocument
648         since setDocument now takes care of that.
649         * dom/Node.cpp:
650         (WebCore::Node::setDocument): Added call to updateDOMNodeDocument here.
651         (WebCore::Node::checkAddChild): Removed call to updateDOMNodeDocument since setDocument
652         now takes care of that.
653
654 2006-12-11  Alexey Proskuryakov  <ap@nypop.com>
655
656         Reviewed by Darin.
657
658         http://bugs.webkit.org/show_bug.cgi?id=9673
659         Add support for window.atob() and window.btoa()
660
661         * WebCore.xcodeproj/project.pbxproj: Added Base64.{h,cpp}
662         * bindings/js/kjs_window.cpp:
663         (KJS::WindowFunc::callAsFunction):
664         * bindings/js/kjs_window.h:
665         (KJS::Window::):
666         * platform/Base64.cpp: Added.
667         (base64Encode):
668         (base64Decode):
669         * platform/Base64.h: Added.
670         * ForwardingHeaders/wtf/StringExtras.h: Added.
671         * platform/DeprecatedString.cpp: Use strncasecmp from StringExtras.
672
673 2006-12-11  Darin Adler  <darin@apple.com>
674
675         Reviewed by Brady.
676
677         - did some of the Mac-specific file moves mentioned in my recent mail to the WebKit list
678
679         * WebCore.xcodeproj/project.pbxproj: Updated project for file moves.
680
681         * bridge/mac/FrameMac.h: Moved to page/mac.
682         * bridge/mac/FrameMac.mm: Ditto.
683         * bridge/mac/WebCoreFrameBridge.h: Ditto.
684         * bridge/mac/WebCoreFrameBridge.mm: Ditto.
685         * bridge/mac/WebCoreFrameView.h: Ditto.
686         * bridge/mac/WebCoreViewFactory.h: Ditto.
687         * bridge/mac/WebCoreViewFactory.m: Ditto.
688         * bridge/mac/WebDashboardRegion.h: Ditto.
689         * bridge/mac/WebDashboardRegion.m: Ditto.
690
691         * bridge/mac/WebCoreKeyboardAccess.h: Moved to page/mac,
692         renamed WebCoreKeyboardUIMode.h, and made a C++ header.
693
694         * page/EventHandler.h: Updated for change to WebCoreKeyboardAccess.
695         * page/mac/EventHandlerMac.mm:
696         (WebCore::EventHandler::tabsToLinks): Ditto.
697         (WebCore::EventHandler::tabsToAllControls): Ditto.
698         (WebCore::EventHandler::keyboardUIMode): Ditto.
699
700 2006-12-11  Beth Dakin  <bdakin@apple.com>
701
702         Reviewed by Adam.
703
704         Primarily, this patch implements/hooks-up actions for the sub-menu
705         items in WebCore context menus. I fixed a few other things along
706         the way too:
707                 -Made BUILDING_ON_TIGER ifdef work within C++ as well as
708                  Obj-C
709                 -Fixed bug where we would throw and Obj-C exception and
710                  fail to pop up menus with more than one separator item.
711                 -Re-named some of the spelling/grammar tags since Tiger and
712                  Leopard share more of the actions than initially
713                  anticipated.
714
715         * WebCorePrefix.h: Make BUILDING_ON_TIGER available to C++
716         * bridge/EditorClient.h: New functions to toggle
717         spelling/grammar checking.
718         * editing/Editor.cpp:
719         (WebCore::Editor::toggleContinuousSpellChecking): Call into client.
720         (WebCore::Editor::toggleGrammarChecking): Same.
721         (WebCore::Editor::toggleBold): call execToggleBold()
722         (WebCore::Editor::toggleUnderline): Create appropriate underline
723         style and apply to selection.
724         (WebCore::Editor::setBaseWritingDirection): Create appropriate
725         writing direction and apply to selection.
726         * editing/Editor.h:
727         * editing/mac/EditorMac.mm: New functions to show spelling guesses,
728         fonts, styles, and color panels.
729         * page/ContextMenuClient.h: New functions for the speech sub-menu.
730         * page/ContextMenuController.cpp:
731         (WebCore::ContextMenuController::contextMenuItemSelected): Fill in
732         editing sub-menu actions.
733         * platform/ContextMenu.cpp:
734         (WebCore::separatorItem): Helper function to create a separator 
735         item.
736         (WebCore::createFontSubMenu): Put very mac-specific things within a
737         platform ifdef.
738         (WebCore::createSpellingAndGrammarSubMenu): Re-named some of the
739         spelling sub-menu tags.
740         (WebCore::createSpellingSubMenu): Same.
741         (WebCore::ContextMenu::populate): We can't share the separator
742         item. When we do, menus with more than one separator throw and obj-
743         c exception and fail to pop-up.
744         * platform/ContextMenuItem.h:
745         (WebCore::): Re-named some of the spelling sub-menu tags.
746
747 2006-12-11  Alice Liu  <alice.liu@apple.com>
748
749         Reviewed by Geoff, Adam.
750
751         Switch to use the Editor for copying URLs.  Also some Pasteboard and PlatformMouseEvent cleanup.
752
753         All layout tests pass as they would without this patch. 
754
755         * WebCore.exp:
756         added Editor::copyURL to be called from WebKit
757         
758         * editing/Editor.cpp:
759         (WebCore::Editor::tryDHTMLCopy):
760         (WebCore::Editor::tryDHTMLCut):
761         Pasteboard::clearTypes() changed to clear()
762
763         (WebCore::Editor::writeSelectionToPasteboard):        
764         (WebCore::Editor::cut):
765         (WebCore::Editor::copy):
766         Changed signature of writeSelection to take raw pointer instead of PassRefPtr
767
768         (WebCore::Editor::copyURL):
769         * editing/Editor.h:
770         Added copyURL.
771         
772         * page/ContextMenuClient.h:
773         * page/ContextMenuController.cpp:
774         (WebCore::ContextMenuController::contextMenuItemSelected):
775         Removed copyLinkToClipboard
776         
777         * platform/KURL.cpp:
778         (WebCore::KURL::lastPathComponent):
779         * platform/KURL.h:
780         Added lastPathComponent. 
781         
782         * platform/Pasteboard.h:
783         Changed some function names.
784         Moved some functions out of class to static.
785         
786         * platform/PlatformMouseEvent.h:
787         (WebCore::):
788         Removed MouseEventType enum, added NoButton to MouseButton without disturbing other button values.
789         
790         * platform/mac/PasteboardMac.mm:
791         Added writeURL, and moved some things around
792         
793         * platform/mac/WebCoreSystemInterface.h:
794         * platform/mac/WebCoreSystemInterface.mm:
795         Add some calls necessary for Pasteboard::writeURL to work
796
797 2006-12-11  Darin Adler  <darin@apple.com>
798
799         Reviewed by Brady.
800
801         - http://bugs.webkit.org/show_bug.cgi?id=11794
802           fix lifetime problems affecting Frame's ownerElement pointer
803
804         * CMakeLists.txt:
805         * WebCore.vcproj/WebCore/WebCore.vcproj:
806         * WebCore.xcodeproj/project.pbxproj:
807         * WebCoreSources.bkl:
808         Updated for new source files.
809
810         * WebCore.exp: Updated for changes to entry point names.
811
812         * bridge/mac/FrameMac.h:
813         * bridge/mac/FrameMac.mm: (WebCore::FrameMac::FrameMac):
814         * bridge/win/FrameWin.h:
815         * bridge/win/FrameWin.cpp: (WebCore::FrameWin::FrameWin):
816         * platform/qt/FrameQt.h:
817         * platform/qt/FrameQt.cpp: (WebCore::FrameQt::FrameQt):
818         Updated owner element type to HTMLFrameOwnerElement.
819
820         * bridge/mac/WebCoreFrameBridge.h: Removed non-C++ case since we don't
821         use that any more. Updated owner element type to HTMLFrameOwnerElement.
822
823         * dom/Document.cpp: Added include so that the ownerElement function can
824         compile (since it downcasts an HTMLFrameOwnerElement to an Element).
825
826         * html/HTMLFrameElement.cpp:
827         (WebCore::containingFrameSetElement): Moved this function in here; it
828         doesn't need to be a member function.
829         (WebCore::HTMLFrameElement::attach): Updated to call this.
830
831         * html/HTMLFrameElementBase.h:
832         * html/HTMLFrameElementBase.cpp:
833         (WebCore::HTMLFrameElementBase::HTMLFrameElementBase): Inherit from
834         HTMLFrameOwnerElement. Removed contentFrame, contentDocument, and
835         containingFrameSetElement. Removed friend classes.
836
837         * html/HTMLFrameOwnerElement.h: Added.
838         * html/HTMLFrameOwnerElement.cpp: Added.
839
840         * html/HTMLEmbedElement.h:
841         * html/HTMLEmbedElement.cpp:
842         * html/HTMLObjectElement.h:
843         * html/HTMLObjectElement.cpp:
844         Remove now-unneeded contentDocument functions.
845
846         * html/HTMLPlugInElement.h:
847         * html/HTMLPlugInElement.cpp:
848         (WebCore::HTMLPlugInElement::HTMLPlugInElement): Inherit from
849         HTMLFrameOwnerElement.
850
851         * loader/FormState.h:
852         * loader/FormState.cpp: Use HTMLFormElement instead of just Element.
853
854         * loader/FrameLoader.h:
855         * loader/FrameLoader.cpp:
856         (WebCore::FrameLoader::requestFrame): Use HTMLFormElement.
857         (WebCore::FrameLoader::loadSubframe): Ditto.
858         (WebCore::FrameLoader::requestObject): Don't pass an element parameter
859         to shouldUsePlugin, and remove now-unneeded type casts.
860         (WebCore::FrameLoader::shouldUsePlugin): Removed unneeded element parameter.
861         (WebCore::FrameLoader::handleFallbackContent): Use HTMLFrameOwnerElement.
862         (WebCore::FrameLoader::updateBaseURLForEmptyDocument): Ditto.
863         (WebCore::FrameLoader::isHostedByObjectElement): Ditto.
864         * loader/mac/FrameLoaderMac.mm:
865         (WebCore::FrameLoader::load): Use HTMLFormElement.
866         (WebCore::FrameLoader::post): Ditto.
867         (WebCore::FrameLoader::createFrame): Use HTMLFrameOwnerElement.
868
869         * page/Frame.h:
870         * page/FramePrivate.h:
871         * page/Frame.cpp:
872         (WebCore::parentFromOwnerElement): Use HTMLFrameOwnerElement.
873         (WebCore::Frame::Frame): Ditto. Also set m_contentFrame on the owner element.
874         (WebCore::Frame::ownerElement): Ditto.
875         (WebCore::Frame::ownerRenderer): Ditto.
876         (WebCore::Frame::disconnectOwnerElement): Clear m_contentFrame on the owner
877         element before disconnecting it.
878         (WebCore::FramePrivate::FramePrivate): Use HTMLFrameOwnerElement.
879
880         * page/mac/EventHandlerMac.mm: Include HTMLFrameOwnerElement.h so that
881         the code here will compile (no code changes needed).
882
883         * rendering/RenderFrame.cpp: (WebCore::RenderFrame::viewCleared):
884         Updated so that RenderFrame doesn't need to be a friend of HTMLFrameElementBase.
885
886         * rendering/RenderPart.h:
887         * rendering/RenderPart.cpp: (WebCore::RenderPart::RenderPart):
888         Use HTMLFrameOwnerElement.
889
890         * rendering/RenderPartObject.h:
891         * rendering/RenderPartObject.cpp:
892         (WebCore::RenderPartObject::RenderPartObject): Use HTMLFrameOwnerElement.
893         (WebCore::RenderPartObject::viewCleared): Updated so that RenderFrame doesn't
894         need to be a friend of HTMLFrameElementBase.
895
896         - other changes
897
898         * platform/network/ResourceHandleInternal.h: Added Noncopyable and
899         fixed indentation.
900
901 2006-12-11  David Hyatt  <hyatt@apple.com>
902
903         Fix failing layout test.  Remove WTF::Unicode::isSpace and just revert
904         the caller to the old behavior.
905
906         Reviewed by darin
907
908         * platform/StringImpl.cpp:
909         (WebCore::isSpace):
910
911 2006-12-11  Alexey Proskuryakov  <ap@webkit.org>
912
913         Reviewed by Adam.
914
915         http://bugs.webkit.org/show_bug.cgi?id=11807
916         Merge EventHandler::m_bMousePressed and EventHandler::m_mousePressed
917
918         * page/EventHandler.cpp:
919         (WebCore::EventHandler::EventHandler):
920         (WebCore::EventHandler::handleMousePressEvent):
921         (WebCore::EventHandler::handleMouseMoveEvent):
922         (WebCore::EventHandler::handleMouseReleaseEvent):
923         (WebCore::EventHandler::autoscrollTimerFired):
924         * page/EventHandler.h:
925         * page/mac/EventHandlerMac.mm:
926         (WebCore::EventHandler::handleDrag):
927         (WebCore::EventHandler::mouseMoved):
928         Merge EventHandler::m_bMousePressed and EventHandler::m_mousePressed
929
930         (WebCore::EventHandler::lastEventIsMouseUp):
931         Check that the "new" event is newer than the "old" one - that's not always the case 
932         when running in DRT, as [NSApp currentEvent] isn't updated by eventSender.
933
934 2006-12-11  Nikolas Zimmermann  <zimmermann@kde.org>
935
936         Reviewed by Sam Weinig.
937
938         Fixes: http://bugs.webkit.org/show_bug.cgi?id=11801
939
940         Autogenerate POD types for ObjC/JS.
941
942         This removes the need for the hand-written JSSVG*, DOMSVG* wrappers
943         in bindings/js, bindings/objc. Makes it much easier to convert more
944         SVG types to POD types (ie. SVGMatrix* -> AffineTransform etc.)
945
946         Affected test: svg/custom/SVGPoint-matrixTransform.svg
947
948         It's failing with this patch, as the SVGPoint matrixTransform() function
949         got disabled, until the SVGMatrix -> AffineTransform transition patch
950         is landed. Otherwhise we'd need to add special cases to both CodeGeneratorJS/ObjC.pm
951         which would be a waste of time, as SVGMatrix is about to die.
952
953         Temporarily updating layout test result, as suggested by John Sullivan, so
954         no-one notices that SVGPoint-matrixTransform.svg actually fails right now.
955
956         Expect that to be fixed again in the next hour(s).
957
958         * DerivedSources.make:
959         * WebCore.xcodeproj/project.pbxproj:
960         * bindings/js/JSSVGNumber.cpp: Removed.
961         * bindings/js/JSSVGNumber.h: Removed.
962         * bindings/js/JSSVGPoint.cpp: Removed.
963         * bindings/js/JSSVGPoint.h: Removed.
964         * bindings/js/JSSVGRect.cpp: Removed.
965         * bindings/js/JSSVGRect.h: Removed.
966         * bindings/objc/DOMSVGNumber.mm: Removed.
967         * bindings/objc/DOMSVGPoint.mm: Removed.
968         * bindings/objc/DOMSVGRect.mm: Removed.
969         * bindings/scripts/CodeGeneratorJS.pm:
970         * bindings/scripts/CodeGeneratorObjC.pm:
971         * ksvg2/svg/SVGNumber.idl:
972         * ksvg2/svg/SVGPoint.idl:
973         * ksvg2/svg/SVGRect.idl:
974
975 2006-12-10  Lars Knoll <lars@trolltech.com>
976
977         Reviewed by Zack
978
979         Fix another issue with frame loading
980
981         * platform/network/qt/ResourceHandleManagerQt.cpp:
982         (WebCore::ResourceHandleManager::cancel):
983         (WebCore::ResourceHandleManager::receivedData):
984         (WebCore::ResourceHandleManager::receivedFinished):
985         (WebCore::FileLoader::request):
986         * platform/qt/FrameQtClient.cpp:
987         (WebCore::FrameQtClient::openURL):
988
989 2006-12-10  George Staikos  <staikos@kde.org.
990
991         Reviewed by Zack.
992
993         Make the xpath grammar hack more specific (and work on OS X) until
994         it's cleaned up.
995
996         * WebCore.pro:
997
998 2006-12-10  Zack Rusin  <zack@kde.org>
999
1000         Set the widgetclient correctly. This code
1001         should be platform independent!
1002
1003         * platform/qt/WidgetQt.cpp:
1004         (WebCore::WidgetPrivate::WidgetPrivate):
1005         (WebCore::Widget::setClient):
1006         (WebCore::Widget::client):
1007         (WebCore::Widget::focusPolicy):
1008
1009 2006-12-11  Lars Knoll <lars@trolltech.com>
1010
1011         Reviewed by Zack
1012
1013         Fix loading of local files.
1014
1015         * platform/network/qt/ResourceHandleManagerQt.cpp:
1016         (WebCore::FileLoader::request):
1017
1018 2006-12-10  Zack Rusin  <zack@kde.org>
1019
1020        Don't use my QTransform magic, affine QMatrix is fine for
1021        SVG so use setMatrix.
1022
1023         * platform/graphics/svg/qt/SVGPaintServerLinearGradientQt.cpp:
1024         (WebCore::SVGPaintServerLinearGradient::setup):
1025         * platform/graphics/svg/qt/SVGPaintServerRadialGradientQt.cpp:
1026         (WebCore::setup):
1027
1028 2006-12-10  Lars Knoll <lars@trolltech.com>
1029
1030         Reviewed by Zack
1031
1032         Make sure we call checkCompleted() on the FrameLoader
1033         to get the regression tests running.
1034
1035         * WebCore.pro:
1036         * loader/qt/FrameLoaderQt.cpp:
1037         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
1038         (WebCore::FrameLoader::saveDocumentState):
1039         * page/qt/EventHandlerQt.cpp:
1040         (WebCore::EventHandler::handleDrag):
1041         * platform/qt/FrameQtClient.cpp:
1042         (WebCore::FrameQtClient::openURL):
1043         (WebCore::FrameQtClient::didReceiveResponse):
1044         (WebCore::FrameQtClient::didFinishLoading):
1045         (WebCore::FrameQtClient::didFail):
1046         * platform/qt/FrameQtClient.h:
1047
1048 2006-12-10  Zack Rusin  <zack@kde.org>
1049
1050         Enable the SVG build by default and make it build.
1051
1052         * WebCore.pro:
1053         * loader/qt/FrameLoaderQt.cpp: Output the method name
1054
1055 2006-12-10  Zack Rusin  <zack@kde.org>
1056
1057         Move the client classes to WebKitQt/WebCoreSupport.
1058
1059         * WebCore.pro:
1060         * loader/qt/FrameLoaderClientQt.cpp: Removed.
1061         * loader/qt/FrameLoaderClientQt.h: Removed.
1062         * platform/qt/ChromeClientQt.cpp: Removed.
1063         * platform/qt/ChromeClientQt.h: Removed.
1064         * platform/qt/ContextMenuClientQt.cpp: Removed.
1065         * platform/qt/ContextMenuClientQt.h: Removed.
1066         * platform/qt/EditorClientQt.cpp: Removed.
1067         * platform/qt/EditorClientQt.h: Removed.
1068
1069 2006-12-10  Lars Knoll <lars@trolltech.com>
1070
1071         Reviewed by Zack.
1072
1073         Add some stubs required to link.
1074
1075         * platform/qt/FrameQt.cpp:
1076         (WebCore::FrameQt::runJavaScriptAlert):
1077         (WebCore::FrameQt::runJavaScriptConfirm):
1078         (WebCore::FrameQt::runJavaScriptPrompt):
1079         (WebCore::FrameQt::bindingRootObject):
1080
1081 2006-12-10  Rob Buis  <buis@kde.org>
1082
1083         Reviewed by Darin.
1084
1085         http://bugs.webkit.org/show_bug.cgi?id=10996
1086         WebKit needs (possibly private) XML/SVG innerText support (for DumpRenderTree)
1087
1088         Create an internal method to create innerText functionality for non-HTML
1089         nodes. When called from DRT this omits CDATA nodes.
1090
1091         * dom/Element.cpp:
1092         (WebCore::Element::innerText):
1093         (WebCore::Element::outerText):
1094         * dom/Element.h:
1095         * dom/Element.idl:
1096         * html/HTMLElement.cpp:
1097         * html/HTMLElement.h:
1098
1099 2006-12-10  MorganL  <morganl.webkit@yahoo.com>
1100
1101         Reviewed by Maciej.
1102
1103         Fixes http://bugs.webkit.org/show_bug.cgi?id=11790
1104         No way to initialize ResourceResponse::m_httpHeaderFields
1105
1106         * platform/network/ResourceResponse.cpp: impl setHTTPHeaderField
1107         (WebCore::ResourceResponse::setHTTPHeaderField):
1108         * platform/network/ResourceResponse.h: decl setHTTPHeaderField
1109
1110 2006-12-10  Zack Rusin  <zack@kde.org>
1111
1112         Cleaning up the code after removals.
1113
1114         * platform/qt/FrameQt.cpp:
1115         * platform/qt/FrameQt.h: Remove virtual methods
1116         which have been moved to different objects
1117
1118 2006-12-10  Zack Rusin  <zack@kde.org>
1119
1120         Cleanup the FrameQtClient a little bit more. Remove
1121         unused methods.
1122
1123         * platform/qt/FrameQtClient.cpp:
1124         * platform/qt/FrameQtClient.h:
1125
1126 2006-12-09  Adam Roben  <aroben@apple.com>
1127
1128         Build fix.
1129
1130         * xml/XPathParser.cpp:
1131         (WebCore::XPath::charCat): Use C++ unsigned instead of uint.
1132
1133 2006-12-09  George Staikos  <staikos@kde.org>
1134
1135         Reviewed by Zack.
1136
1137         Make it not crash, and make it set the title on Qt platform.
1138
1139         * loader/qt/FrameLoaderClientQt.cpp:
1140         (WebCore::FrameLoaderClientQt::hasWebView):
1141         (WebCore::FrameLoaderClientQt::hasFrameView):
1142         (WebCore::FrameLoaderClientQt::didChangeTitle):
1143         * loader/qt/FrameLoaderQt.cpp:
1144         (WebCore::FrameLoader::setTitle):
1145         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
1146
1147 2006-12-10  Zack Rusin  <zack@kde.org>
1148
1149         Renaming FrameQtClientDefault to FrameQtClient.
1150         Removing FrameQtClient. Adding FrameLoaderClient
1151         as an argument. Clenaing up the code a bit.
1152
1153         * platform/qt/FrameQt.cpp:
1154         (WebCore::FrameQt::FrameQt):
1155         * platform/qt/FrameQt.h:
1156         * platform/qt/FrameQtClient.cpp:
1157         (WebCore::FrameQtClient::FrameQtClient):
1158         (WebCore::FrameQtClient::~FrameQtClient):
1159         (WebCore::FrameQtClient::setFrame):
1160         (WebCore::FrameQtClient::openURL):
1161         (WebCore::FrameQtClient::submitForm):
1162         (WebCore::FrameQtClient::checkLoaded):
1163         (WebCore::FrameQtClient::runJavaScriptAlert):
1164         (WebCore::FrameQtClient::runJavaScriptConfirm):
1165         (WebCore::FrameQtClient::runJavaScriptPrompt):
1166         (WebCore::FrameQtClient::menubarVisible):
1167         (WebCore::FrameQtClient::toolbarVisible):
1168         (WebCore::FrameQtClient::statusbarVisible):
1169         (WebCore::FrameQtClient::personalbarVisible):
1170         (WebCore::FrameQtClient::locationbarVisible):
1171         (WebCore::FrameQtClient::loadFinished):
1172         (WebCore::FrameQtClient::didReceiveResponse):
1173         (WebCore::FrameQtClient::didFinishLoading):
1174         (WebCore::FrameQtClient::didFail):
1175         (WebCore::FrameQtClient::didReceiveData):
1176         (WebCore::FrameQtClient::traverseNextFrameStayWithin):
1177         (WebCore::FrameQtClient::numPendingOrLoadingRequests):
1178         (WebCore::FrameQtClient::receivedAllData):
1179         (WebCore::FrameQtClient::setTitle):
1180         * platform/qt/FrameQtClient.h:
1181
1182 2006-12-10  Zack Rusin  <zack@kde.org>
1183
1184         Fixes compilation after the last removals.
1185
1186         * WebCore.pro:
1187
1188 2006-12-10  Lars Knoll <lars@trolltech.com>
1189
1190         Reviewed by Zack.
1191
1192         Implement a decent network loader using QHttp.
1193
1194         * loader/qt/FrameLoaderQt.cpp:
1195         (WebCore::FrameLoader::load):
1196         * platform/network/ResourceHandle.cpp:
1197         (WebCore::ResourceHandle::request):
1198         * platform/network/ResourceHandle.h:
1199         * platform/network/ResourceHandleInternal.h:
1200         * platform/network/qt/ResourceHandleManager.cpp: Removed.
1201         * platform/network/qt/ResourceHandleManager.h: Removed.
1202         * platform/network/qt/ResourceHandleManagerKDE.cpp: Added.
1203         (WebCore::ResourceHandleManager::self):
1204         (WebCore::ResourceHandleManager::ResourceHandleManager):
1205         (WebCore::ResourceHandleManager::~ResourceHandleManager):
1206         (WebCore::ResourceHandleManager::slotData):
1207         (WebCore::ResourceHandleManager::slotMimetype):
1208         (WebCore::ResourceHandleManager::slotResult):
1209         (WebCore::ResourceHandleManager::remove):
1210         (WebCore::ResourceHandleManager::add):
1211         (WebCore::ResourceHandleManager::cancel):
1212         * platform/network/qt/ResourceHandleManagerKDE.h: Added.
1213         * platform/network/qt/ResourceHandleManagerQt.cpp: Added.
1214         (WebCore::ResourceHandleManager::ResourceHandleManager):
1215         (WebCore::ResourceHandleManager::~ResourceHandleManager):
1216         (WebCore::ResourceHandleManager::self):
1217         (WebCore::RequestQt::RequestQt):
1218         (WebCore::ResourceHandleManager::add):
1219         (WebCore::ResourceHandleManager::cancel):
1220         (WebCore::ResourceHandleManager::receivedResponse):
1221         (WebCore::ResourceHandleManager::receivedData):
1222         (WebCore::ResourceHandleManager::receivedFinished):
1223         (WebCore::LoaderThread::LoaderThread):
1224         (WebCore::LoaderThread::run):
1225         (WebCore::FileLoader::FileLoader):
1226         (WebCore::FileLoader::request):
1227         (WebCore::FileLoader::cancel):
1228         (WebCore::WebCoreHttp::WebCoreHttp):
1229         (WebCore::WebCoreHttp::~WebCoreHttp):
1230         (WebCore::WebCoreHttp::request):
1231         (WebCore::WebCoreHttp::scheduleNextRequest):
1232         (WebCore::WebCoreHttp::getConnection):
1233         (WebCore::WebCoreHttp::onResponseHeaderReceived):
1234         (WebCore::WebCoreHttp::onReadyRead):
1235         (WebCore::WebCoreHttp::onRequestFinished):
1236         (WebCore::WebCoreHttp::onStateChanged):
1237         (WebCore::WebCoreHttp::cancel):
1238         (WebCore::qHash):
1239         (WebCore::operator==):
1240         (WebCore::HostInfo::HostInfo):
1241         (WebCore::NetworkLoader::NetworkLoader):
1242         (WebCore::NetworkLoader::~NetworkLoader):
1243         (WebCore::NetworkLoader::request):
1244         (WebCore::NetworkLoader::connectionClosed):
1245         (WebCore::NetworkLoader::cancel):
1246         * platform/network/qt/ResourceHandleManagerQt.h: Added.
1247         (WebCore::LoaderThread::):
1248         (WebCore::LoaderThread::waitForSetup):
1249         * platform/network/qt/ResourceHandleQt.cpp:
1250         (WebCore::ResourceHandle::start):
1251         * platform/qt/FrameQt.cpp:
1252         (WebCore::FrameQt::FrameQt):
1253         (WebCore::FrameQt::keyEvent):
1254         * platform/qt/FrameQt.h:
1255         * platform/qt/FrameQtClient.cpp:
1256         (WebCore::FrameQtClientDefault::FrameQtClientDefault):
1257         (WebCore::FrameQtClientDefault::openURL):
1258         (WebCore::FrameQtClientDefault::submitForm):
1259         (WebCore::FrameQtClientDefault::didReceiveResponse):
1260         (WebCore::FrameQtClientDefault::didFinishLoading):
1261         (WebCore::FrameQtClientDefault::didFail):
1262         (WebCore::FrameQtClientDefault::didReceiveData):
1263         (WebCore::FrameQtClientDefault::receivedAllData):
1264         (WebCore::FrameQtClientDefault::setTitle):
1265         * platform/qt/FrameQtClient.h:
1266
1267 2006-12-09  George Staikos  <staikos@kde.org>
1268
1269         Reviewed by Zack.
1270
1271         Fix bison again on qmake build.
1272
1273         * WebCore.pro:
1274
1275 2006-12-09  Zack Rusin  <zack@kde.org>
1276
1277         Reviewed by Zack.
1278
1279         Use the correct filename.
1280
1281         * WebCore.pro: it's PasteboardQt.cpp
1282
1283 2006-12-09  Zack Rusin  <zack@kde.org>
1284
1285         Reviewed by Lars.
1286
1287         Correctly set the font on widgets.
1288
1289         * platform/qt/WidgetQt.cpp:
1290         (WebCore::Widget::setFont):
1291
1292 2006-12-09  Adam Treat  <treat@kde.org>
1293
1294         Reviewed by Zack
1295
1296         No more nil renderer warnings
1297
1298         * platform/qt/ScrollViewCanvasQt.cpp:
1299         (WebCore::ScrollViewCanvasQt::paintEvent):
1300
1301 2006-12-09  Friedemann Kleint  <fkleint@trolltech.com>
1302
1303         Reviewed by Zack
1304
1305         Removed compiler warnings about rounding issues
1306
1307         * platform/qt/FontPlatformDataQt.cpp:
1308         (WebCore::FontPlatformData::FontPlatformData):
1309         * platform/qt/FontQt.cpp:
1310         (WebCore::Font::drawComplexText):
1311
1312 2006-12-09  George Staikos <staikos@kde.org>
1313
1314         Reviewed by Zack.
1315
1316         Qt 4.1 (especially Qtopia) build fixes
1317
1318         * platform/qt/FrameQtClient.cpp:
1319         * platform/qt/GraphicsContextQt.cpp:
1320         * platform/qt/PlatformKeyboardEventQt.cpp:
1321         * platform/qt/CursorQt.cpp:
1322         * platform/qt/WidgetQt.cpp:
1323         * platform/Cursor.h:
1324         * platform/Arena.h:
1325
1326 2006-12-09  Lars Knoll <lars@trolltech.com>
1327
1328         Reviewed by Zack
1329
1330         Make it possible to build WebKit with qmake.
1331
1332         * WebCore.pro: Added.
1333         * platform/graphics/qt/GraphicsContextQt.cpp:
1334
1335 2006-12-10  Lars Knoll <lars@trolltech.com>
1336
1337         Reviewed by Zack.
1338
1339         Compile after latest WebKit changes and don't depend
1340         on deprecated methods in Qt.
1341
1342         * platform/network/qt/ResourceHandleManager.cpp:
1343         (WebCore::ResourceHandleManager::remove):
1344         (WebCore::ResourceHandleManager::deliverJobData):
1345         * platform/network/qt/ResourceHandleQt.cpp:
1346         (WebCore::ResourceHandle::extractCharsetFromHeaders):
1347         * platform/qt/PlatformKeyboardEventQt.cpp:
1348         (WebCore::windowsKeyCodeForKeyEvent):
1349
1350 2006-12-10  Lars Knoll <lars@trolltech.com>
1351
1352         Reviewed by Zack.
1353
1354         Use the Qt image loading framework.
1355
1356         * CMakeLists.txt:
1357         * platform/graphics/ImageSource.h:
1358         * platform/graphics/qt/GraphicsContextQt.cpp:
1359         * platform/graphics/qt/ImageDecoderQt.cpp: Added.
1360         (WebCore::ImageDecoderQt::ImageData::ImageData):
1361         (WebCore::ImageDecoderQt::ReadContext::):
1362         (WebCore::ImageDecoderQt::ReadContext::ReadContext):
1363         (WebCore::ImageDecoderQt::ReadContext::read):
1364         (WebCore::ImageDecoderQt::ReadContext::readImageLines):
1365         (WebCore::ImageDecoderQt::ImageDecoderQt):
1366         (WebCore::ImageDecoderQt::~ImageDecoderQt):
1367         (WebCore::ImageDecoderQt::hasFirstImageHeader):
1368         (WebCore::ImageDecoderQt::reset):
1369         (WebCore::ImageDecoderQt::setData):
1370         (WebCore::ImageDecoderQt::isSizeAvailable):
1371         (WebCore::ImageDecoderQt::frameCount):
1372         (WebCore::ImageDecoderQt::repetitionCount):
1373         (WebCore::ImageDecoderQt::ImageDecoderQt::supportsAlpha):
1374         (WebCore::ImageDecoderQt::duration):
1375         (WebCore::ImageDecoderQt::frameBufferAtIndex):
1376         (WebCore::ImageDecoderQt::imageAtIndex):
1377         * platform/graphics/qt/ImageDecoderQt.h: Added.
1378         (WebCore::ImageDecoderQt::):
1379         * platform/graphics/qt/ImageSourceQt.cpp:
1380         (WebCore::):
1381         (WebCore::detectImageFormat):
1382         (WebCore::createDecoder):
1383         (WebCore::ImageSource::setData):
1384         (WebCore::ImageSource::createFrameAtIndex):
1385         (WebCore::ImageSource::frameDurationAtIndex):
1386         (WebCore::ImageSource::frameHasAlphaAtIndex):
1387
1388 2006-12-09  Lars Knoll  <lars@trolltech.com>
1389
1390         Reviewed by Maciej.
1391
1392         Remove an explicit ICU dependency.
1393
1394         * xml/XPathParser.cpp:
1395         (WebCore::XPath::charCat):
1396
1397 2006-12-09  Zack Rusin  <zack@kde.org>
1398
1399         Adjusting the build after the icu changes.
1400
1401         * CMakeLists.txt:
1402
1403 2006-12-09  Adam Roben  <aroben@apple.com>
1404
1405         Reviewed by Darin.
1406
1407         Changed all ForwardingHeaders to use #include instead of #import.
1408
1409         * ForwardingHeaders/kjs/JSLock.h:
1410         * ForwardingHeaders/kjs/SavedBuiltins.h:
1411         * ForwardingHeaders/kjs/collector.h:
1412         * ForwardingHeaders/kjs/dtoa.h:
1413         * ForwardingHeaders/kjs/internal.h:
1414         * ForwardingHeaders/kjs/interpreter.h:
1415         * ForwardingHeaders/kjs/lookup.h:
1416         * ForwardingHeaders/kjs/object.h:
1417         * ForwardingHeaders/kjs/property_map.h:
1418         * ForwardingHeaders/kjs/protect.h:
1419         * ForwardingHeaders/wtf/AlwaysInline.h:
1420         * ForwardingHeaders/wtf/Assertions.h:
1421         * ForwardingHeaders/wtf/FastMalloc.h:
1422         * ForwardingHeaders/wtf/GetPtr.h:
1423         * ForwardingHeaders/wtf/HashCountedSet.h:
1424         * ForwardingHeaders/wtf/HashMap.h:
1425         * ForwardingHeaders/wtf/HashSet.h:
1426         * ForwardingHeaders/wtf/HashTraits.h:
1427         * ForwardingHeaders/wtf/MathExtras.h:
1428         * ForwardingHeaders/wtf/Noncopyable.h:
1429         * ForwardingHeaders/wtf/OwnArrayPtr.h:
1430         * ForwardingHeaders/wtf/OwnPtr.h:
1431         * ForwardingHeaders/wtf/PassRefPtr.h:
1432         * ForwardingHeaders/wtf/Platform.h:
1433         * ForwardingHeaders/wtf/RefPtr.h:
1434         * ForwardingHeaders/wtf/Vector.h:
1435
1436 2006-12-09  Rob Buis  <buis@kde.org>
1437
1438         Reviewed by Darin.
1439
1440         http://bugs.webkit.org/show_bug.cgi?id=11625
1441         Investigate possibility to share code between HTMLStyleElement and SVGStyleElement
1442
1443         Add a class shared by both HTMLStyleElement and SVGStyleElement that
1444         encapsulates the common logic.
1445
1446         * CMakeLists.txt:
1447         * WebCore.xcodeproj/project.pbxproj:
1448         * dom/Document.cpp:
1449         (WebCore::Document::recalcStyleSelector):
1450         Generalize stylesheet processing of svg and html.
1451
1452         * dom/StyleElement.cpp: Added.
1453         (WebCore::StyleElement::StyleElement):
1454         (WebCore::StyleElement::sheet):
1455         (WebCore::StyleElement::insertedIntoDocument):
1456         (WebCore::StyleElement::removedFromDocument):
1457         (WebCore::StyleElement::childrenChanged):
1458         * dom/StyleElement.h: Added.
1459         (WebCore::StyleElement::~StyleElement):
1460         (WebCore::StyleElement::isLoading):
1461         Common base class for SVGStyleElement and HTMLStyleElement.
1462
1463         * html/HTMLStyleElement.cpp:
1464         (WebCore::HTMLStyleElement::HTMLStyleElement):
1465         (WebCore::HTMLStyleElement::parseMappedAttribute):
1466         (WebCore::HTMLStyleElement::insertedIntoDocument):
1467         (WebCore::HTMLStyleElement::removedFromDocument):
1468         (WebCore::HTMLStyleElement::childrenChanged):
1469         (WebCore::HTMLStyleElement::media):
1470         (WebCore::HTMLStyleElement::setMedia):
1471         (WebCore::HTMLStyleElement::type):
1472         (WebCore::HTMLStyleElement::setType):
1473         * html/HTMLStyleElement.h:
1474         Use new common class.
1475
1476         * ksvg2/svg/SVGElement.cpp:
1477         * ksvg2/svg/SVGElement.h:
1478         * ksvg2/svg/SVGSVGElement.cpp:
1479         (WebCore::SVGSVGElement::contentScriptType):
1480         (WebCore::SVGSVGElement::contentStyleType):
1481         * ksvg2/svg/SVGSVGElement.h:
1482         Do not use tryGetAttribute(NS) anymore.
1483
1484         * ksvg2/svg/SVGStyleElement.cpp:
1485         (WebCore::SVGStyleElement::SVGStyleElement):
1486         (WebCore::SVGStyleElement::xmlspace):
1487         (WebCore::SVGStyleElement::type):
1488         (WebCore::SVGStyleElement::media):
1489         (WebCore::SVGStyleElement::title):
1490         (WebCore::SVGStyleElement::insertedIntoDocument):
1491         (WebCore::SVGStyleElement::removedFromDocument):
1492         (WebCore::SVGStyleElement::childrenChanged):
1493         * ksvg2/svg/SVGStyleElement.h:
1494         Use new common class.
1495
1496 2006-12-08  David Hyatt  <hyatt@apple.com>
1497
1498         Land the new ICU abstraction layer (WTF::Unicode).  Patch
1499         by Lars with a couple of fixes thrown in by me.
1500
1501         Reviewed by hyatt
1502
1503         * ForwardingHeaders/wtf/icu/UnicodeIcu.h: Added.
1504         * ForwardingHeaders/wtf/unicode/Unicode.h: Added.
1505         * WebCore.xcodeproj/project.pbxproj:
1506         * css/cssparser.cpp:
1507         (WebCore::ParseString::lower):
1508         * dom/Document.cpp:
1509         (WebCore::isValidNameStart):
1510         (WebCore::isValidNamePart):
1511         * editing/TextIterator.cpp:
1512         (WebCore::CircularSearchBuffer::append):
1513         * html/HTMLFontElement.cpp:
1514         (WebCore::parseFontSizeNumber):
1515         * html/HTMLInputElement.cpp:
1516         (WebCore::numGraphemeClusters):
1517         (WebCore::numCharactersInGraphemeClusters):
1518         * html/HTMLSelectElement.cpp:
1519         (WebCore::stripLeadingWhiteSpace):
1520         * page/Frame.h:
1521         * platform/DeprecatedString.h:
1522         (WebCore::DeprecatedChar::isSpace):
1523         (WebCore::DeprecatedChar::lower):
1524         (WebCore::DeprecatedChar::upper):
1525         * platform/Font.cpp:
1526         (WebCore::WidthIterator::advance):
1527         (WebCore::WidthIterator::normalizeVoicingMarks):
1528         * platform/FontCache.h:
1529         * platform/FontData.h:
1530         * platform/GlyphMap.cpp:
1531         * platform/GlyphMap.h:
1532         * platform/GlyphWidthMap.h:
1533         * platform/KURL.cpp:
1534         (WebCore::encodeHostname):
1535         * platform/StringHash.h:
1536         (WTF::):
1537         * platform/StringImpl.cpp:
1538         (WebCore::isSpace):
1539         (WebCore::parseLength):
1540         (WebCore::StringImpl::isLower):
1541         (WebCore::StringImpl::lower):
1542         (WebCore::StringImpl::upper):
1543         (WebCore::StringImpl::secure):
1544         (WebCore::StringImpl::foldCase):
1545         (WebCore::StringImpl::capitalize):
1546         (WebCore::StringImpl::toInt):
1547         (WebCore::equalIgnoringCase):
1548         (WebCore::StringImpl::find):
1549         * platform/StringImpl.h:
1550         * platform/TextBoundaries.h:
1551         * platform/TextBreakIterator.h: Added.
1552         (WebCore::):
1553         * platform/TextBreakIteratorICU.cpp: Added.
1554         (WebCore::wordBreakIterator):
1555         (WebCore::characterBreakIterator):
1556         (WebCore::textBreakFirst):
1557         (WebCore::textBreakNext):
1558         (WebCore::textBreakPreceding):
1559         (WebCore::textBreakFollowing):
1560         (WebCore::textBreakCurrent):
1561         * platform/TextCodec.h:
1562         * platform/TextCodecLatin1.cpp:
1563         * platform/TextEncoding.cpp:
1564         (WebCore::TextEncoding::encode):
1565         * platform/TextEncoding.h:
1566         * platform/TextEncodingRegistry.cpp:
1567         (WebCore::buildTextEncodingNameMap):
1568         (WebCore::buildTextCodecMap):
1569         * platform/TextEncodingRegistry.h:
1570         * platform/UChar.h: Removed.
1571         * platform/graphics/GraphicsContext.h:
1572         * platform/qt/GlyphMapQt.cpp:
1573         * platform/qt/TextBreakIteratorQt.cpp: Added.
1574         (WebCore::TextBreakIterator::following):
1575         (WebCore::TextBreakIterator::preceding):
1576         (WebCore::WordBreakIteratorQt::first):
1577         (WebCore::WordBreakIteratorQt::next):
1578         (WebCore::WordBreakIteratorQt::previous):
1579         (WebCore::CharBreakIteratorQt::first):
1580         (WebCore::CharBreakIteratorQt::next):
1581         (WebCore::CharBreakIteratorQt::previous):
1582         (WebCore::wordBreakIterator):
1583         (WebCore::characterBreakIterator):
1584         (WebCore::textBreakFirst):
1585         (WebCore::textBreakNext):
1586         (WebCore::textBreakPreceding):
1587         (WebCore::textBreakFollowing):
1588         (WebCore::textBreakCurrent):
1589         * platform/qt/TextCodecQt.cpp: Added.
1590         (WebCore::getAtomicName):
1591         (WebCore::TextCodecQt::registerEncodingNames):
1592         (WebCore::newTextCodecQt):
1593         (WebCore::TextCodecQt::registerCodecs):
1594         (WebCore::TextCodecQt::TextCodecQt):
1595         (WebCore::TextCodecQt::~TextCodecQt):
1596         (WebCore::TextCodecQt::decode):
1597         (WebCore::TextCodecQt::encode):
1598         * platform/qt/TextCodecQt.h: Added.
1599         * rendering/RenderBlock.cpp:
1600         (WebCore::RenderBlock::updateFirstLetter):
1601         * rendering/RenderText.cpp:
1602         (WebCore::RenderText::previousOffset):
1603         (WebCore::RenderText::nextOffset):
1604         (WebCore::RenderText::widthFromCache):
1605         * rendering/RenderText.h:
1606         * rendering/bidi.cpp:
1607         (WebCore::BidiState::BidiState):
1608         (WebCore::BidiContext::BidiContext):
1609         (WebCore::bidiNext):
1610         (WebCore::bidiFirst):
1611         (WebCore::BidiIterator::direction):
1612         (WebCore::appendRun):
1613         (WebCore::embed):
1614         (WebCore::RenderBlock::computeHorizontalPositionsForLine):
1615         (WebCore::RenderBlock::bidiReorderLine):
1616         (WebCore::RenderBlock::layoutInlineChildren):
1617         * rendering/bidi.h:
1618         (WebCore::BidiStatus::BidiStatus):
1619         (WebCore::BidiContext::dir):
1620         (WebCore::BidiContext::basicDir):
1621         (WebCore::BidiRun::BidiRun):
1622         * rendering/break_lines.h:
1623
1624 2006-12-08  Adam Roben  <aroben@apple.com>
1625
1626         Rolling out r17865 because it caused a performance regression.
1627
1628         * loader/TextResourceDecoder.cpp:
1629         (WebCore::findXMLEncoding):
1630         * platform/CString.cpp:
1631         (WebCore::CString::data):
1632         * platform/CString.h:
1633         * platform/TextStream.cpp:
1634         (WebCore::TextStream::operator<<):
1635         * platform/TextStream.h:
1636
1637 2006-12-08  Zack Rusin  <zack@kde.org>
1638
1639         Reviewed by Maciej.
1640
1641         Fix the Qt/KDE build after all the API changes.
1642
1643         * CMakeLists.txt:
1644         * editing/qt/EditorQt.cpp: Added.
1645         (WebCore::Editor::newGeneralClipboard):
1646         (WebCore::Editor::ignoreSpelling):
1647         (WebCore::Editor::learnSpelling):
1648         (WebCore::Editor::advanceToNextMisspelling):
1649         (WebCore::Editor::isSelectionMisspelled):
1650         (WebCore::Editor::isSelectionUngrammatical):
1651         (WebCore::Editor::guessesForUngrammaticalSelection):
1652         (WebCore::Editor::guessesForMisspelledSelection):
1653         (WebCore::Editor::markMisspellingsInAdjacentWords):
1654         (WebCore::Editor::markMisspellings):
1655         * loader/NavigationAction.h:
1656         * loader/qt/FrameLoaderClientQt.cpp:
1657         (WebCore::FrameLoaderClientQt::frameLoaderDestroyed):
1658         (WebCore::FrameLoaderClientQt::canHandleRequest):
1659         * loader/qt/FrameLoaderClientQt.h:
1660         * loader/qt/FrameLoaderQt.cpp:
1661         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
1662         (WebCore::FrameLoader::load):
1663         * loader/qt/ResourceLoaderQt.cpp:
1664         * platform/ContextMenu.h:
1665         * platform/graphics/qt/GraphicsContextQt.cpp:
1666         * platform/graphics/qt/PathQt.cpp:
1667         (WebCore::Path::addArc):
1668         * platform/graphics/svg/qt/SVGPaintServerLinearGradientQt.cpp:
1669         (WebCore::SVGPaintServerLinearGradient::setup):
1670         * platform/graphics/svg/qt/SVGPaintServerRadialGradientQt.cpp:
1671         (WebCore::setup):
1672         * platform/network/ResourceHandle.h:
1673         (WebCore::ResourceHandle::getInternal):
1674         * platform/network/ResourceHandleInternal.h:
1675         * platform/network/qt/ResourceHandleManager.cpp:
1676         (WebCore::ResourceHandleManager::slotData):
1677         (WebCore::ResourceHandleManager::remove):
1678         * platform/network/qt/ResourceHandleQt.cpp:
1679         (WebCore::ResourceHandle::~ResourceHandle):
1680         (WebCore::ResourceHandle::start):
1681         * platform/qt/ChromeClientQt.cpp:
1682         (WebCore::ChromeClientQt::addMessageToConsole):
1683         (WebCore::ChromeClientQt::chromeDestroyed):
1684         * platform/qt/ChromeClientQt.h:
1685         * platform/qt/ContextMenuClientQt.cpp:
1686         (WebCore::ContextMenuClientQt::copyLinkToClipboard):
1687         (WebCore::ContextMenuClientQt::downloadURL):
1688         (WebCore::ContextMenuClientQt::copyImageToClipboard):
1689         (WebCore::ContextMenuClientQt::contextMenuDestroyed):
1690         (WebCore::ContextMenuClientQt::contextMenuItemSelected):
1691         * platform/qt/ContextMenuClientQt.h:
1692         * platform/qt/ContextMenuItemQt.cpp: Added.
1693         (WebCore::ContextMenuItem::ContextMenuItem):
1694         (WebCore::ContextMenuItem::~ContextMenuItem):
1695         (WebCore::ContextMenuItem::platformDescription):
1696         (WebCore::ContextMenuItem::action):
1697         (WebCore::ContextMenuItem::title):
1698         (WebCore::ContextMenuItem::setAction):
1699         (WebCore::ContextMenuItem::setTitle):
1700         (WebCore::ContextMenuItem::setSubMenu):
1701         * platform/qt/ContextMenuQt.cpp:
1702         (WebCore::ContextMenu::ContextMenu):
1703         (WebCore::ContextMenu::~ContextMenu):
1704         (WebCore::ContextMenu::appendItem):
1705         (WebCore::ContextMenu::itemCount):
1706         (WebCore::ContextMenu::insertItem):
1707         (WebCore::ContextMenu::setPlatformDescription):
1708         * platform/qt/CursorQt.cpp:
1709         (WebCore::copyCursor):
1710         * platform/qt/EditorClientQt.cpp:
1711         (WebCore::EditorClientQt::shouldInsertNode):
1712         (WebCore::WebCore::EditorClientQt::pageDestroyed):
1713         (WebCore::EditorClientQt::smartInsertDeleteEnabled):
1714         * platform/qt/EditorClientQt.h:
1715         * platform/qt/FrameQt.cpp:
1716         (WebCore::FrameQt::FrameQt):
1717         (WebCore::FrameQt::keyEvent):
1718         * platform/qt/FrameQt.h:
1719         * platform/qt/FrameQtClient.cpp:
1720         (WebCore::FrameQtClientDefault::openURL):
1721         (WebCore::FrameQtClientDefault::submitForm):
1722         * platform/qt/LoaderFunctionsQt.cpp:
1723         * platform/qt/PasteboardQt.cpp: Added.
1724         (WebCore::Pasteboard::Pasteboard):
1725         (WebCore::Pasteboard::generalPasteboard):
1726         (WebCore::Pasteboard::clearTypes):
1727         (WebCore::Pasteboard::writeSelection):
1728         (WebCore::Pasteboard::canSmartReplace):
1729         (WebCore::Pasteboard::plainText):
1730         (WebCore::Pasteboard::documentFragment):
1731
1732 === Safari-521.32 ===
1733
1734 2006-12-08  Rob Buis  <buis@kde.org>
1735
1736         Reviewed by Maciej.
1737
1738         http://bugs.webkit.org/show_bug.cgi?id=10188
1739         Form elements added via appendChild() are not accessible via form.element
1740
1741         Make sure looking up form elements works when the form is not appended
1742         to the document.
1743
1744         * html/HTMLFormElement.cpp:
1745         (WebCore::HTMLFormElement::registerFormElement):
1746
1747 2006-12-08  Rob Buis  <buis@kde.org>
1748
1749         Reviewed by Adele.
1750
1751         http://bugs.webkit.org/show_bug.cgi?id=11765
1752         REGRESSION: Clicking on a select with size other than 1 and no children results in a crash
1753
1754         Make sure returned value is -1 for selects without children.
1755
1756         * rendering/RenderListBox.cpp:
1757         (WebCore::RenderListBox::listIndexAtOffset):
1758
1759 2006-12-08  Adam Roben  <aroben@apple.com>
1760
1761         Reviewed by Anders.
1762
1763         This is a mo' better fix for ensuring we don't use macro definitions
1764         of min/max.
1765
1766         * config.h:
1767
1768 2006-12-08  Don Gibson  <dgibson77@gmail.com>
1769
1770         Reviewed and landed by Alexey.
1771
1772         http://bugs.webkit.org/show_bug.cgi?id=11759:
1773         Windows build bustage
1774
1775         * WebCore.vcproj/WebCore/WebCore.vcproj:
1776         * bridge/win/ContextMenuClientWin.h:
1777         * bridge/win/FrameWin.h:
1778         * loader/win/FrameLoaderWin.cpp:
1779         (WebCore::FrameLoader::submitForm):
1780         * platform/network/win/ResourceHandleWin.cpp:
1781         (WebCore::ResourceHandle::onRequestComplete):
1782         (WebCore::ResourceHandle::fileLoadTimer):
1783         (WebCore::ResourceHandle::cancel):
1784         * platform/win/MouseEventWin.cpp:
1785         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
1786         * platform/win/TemporaryLinkStubs.cpp:
1787         (WebCore::fileButtonChooseFileLabel):
1788         (WebCore::inputElementAltText):
1789         (WebCore::copyCursor):
1790         (WebCore::resetButtonDefaultLabel):
1791         (WebCore::ContextMenuClientWin::contextMenuItemSelected):
1792         (WebCore::ContextMenuClientWin::copyLinkToClipboard):
1793         (WebCore::ContextMenuClientWin::downloadURL):
1794         (WebCore::ContextMenuClientWin::copyImageToClipboard):
1795         (WebCore::Editor::ignoreSpelling):
1796         (WebCore::Editor::learnSpelling):
1797         (WebCore::Editor::isSelectionUngrammatical):
1798         (WebCore::Editor::isSelectionMisspelled):
1799         (WebCore::Editor::guessesForMisspelledSelection):
1800         (WebCore::Editor::guessesForUngrammaticalSelection):
1801         (WebCore::Editor::markMisspellingsInAdjacentWords):
1802         (WebCore::FrameLoader::load):
1803         (WebCore::FrameWin::scheduleClose):
1804         (WebCore::FrameWin::respondToChangedSelection):
1805
1806 2006-12-08  Sam Weinig  <sam@webkit.org>
1807
1808         Reviewed by Geoff.
1809
1810         Fix for http://bugs.webkit.org/show_bug.cgi?id=11777
1811         Crash when using XMLSerializer.serializeToString() on
1812         documentless, DocumentType nodes.
1813
1814         Test: fast/dom/XMLSerializer-doctype.html
1815         Test: fast/dom/XMLSerializer-doctype2.html
1816
1817         * dom/DOMImplementation.cpp:
1818         (WebCore::DOMImplementation::createDocument): set the document of the 
1819         DocumentType node to the new document.
1820         * xml/XMLSerializer.cpp: Cleanup.
1821         (WebCore::XMLSerializer::serializeToString): now throws an exception
1822         for documentless nodes. 
1823         * xml/XMLSerializer.h: cleanup
1824         * xml/XMLSerializer.idl: add exception
1825
1826 2006-12-07  Justin Garcia  <justin.garcia@apple.com>
1827
1828         Reviewed by john
1829
1830         <rdar://problem/4836287>
1831         Cannot expand selection out of editable element when containing element is non-editable.
1832
1833         * editing/Selection.cpp:
1834         (WebCore::Selection::adjustForEditableContent): Restrict the selection endpoints
1835         to the same *highest* editable root.  This bug only happened when creating selections
1836         based in an editable region and extending into a higher editable root, so this change 
1837         doesn't expose any new kinds of deletions, but we should start thinking about how
1838         those deletions should behave.
1839         * editing/SelectionController.cpp:
1840         (WebCore::SelectionController::selectAll): Ditto.
1841
1842 2006-12-08  Beth Dakin  <bdakin@apple.com>
1843
1844         Reviewed by Maciej.
1845
1846         Add a new member variable to ContextMenuItem to hold on to the sub-
1847         menu. The new member variable is an OwnPtr<ContextMenu>
1848
1849         * platform/ContextMenu.cpp: Because of the OwnPtr in
1850         ContextMenuItem, we have to separate the declaration of
1851         ContextMenuItems away from the calls to appendItem(). Not doing so
1852         causes a build failure because OwnPtr inherits from Noncopyable.
1853         (WebCore::createFontSubMenu): Same.
1854         (WebCore::createSpellingAndGrammarSubMenu): Same.
1855         (WebCore::createSpellingSubMenu): Same.
1856         (WebCore::createSpeechSubMenu): Same.
1857         (WebCore::createWritingDirectionSubMenu): Same.
1858         (WebCore::ContextMenu::populate): Same.
1859         * platform/ContextMenuItem.h:  New member variable m_subMenu.
1860         * platform/mac/ContextMenuItemMac.mm: Take care of setting
1861         m_subMenu in addition to setting the submenu of the NSMenuItem when
1862         we have a sub-menu.
1863         (WebCore::menuToArray):
1864         (WebCore::ContextMenuItem::ContextMenuItem): Same.
1865         (WebCore::ContextMenuItem::platformSubMenu): Same.
1866         (WebCore::ContextMenuItem::setSubMenu): Same.
1867
1868 2006-12-08  MorganL  <morganl.webkit@yahoo.com>
1869
1870         Reviewed by Darin.
1871
1872         http://bugs.webkit.org/show_bug.cgi?id=11778
1873         CString::data() should be documented as returning a null terminated char array
1874
1875         * platform/CString.h:
1876         Add some basic documentation to CString.h
1877
1878 2006-12-08  Alexey Proskuryakov  <ap@webkit.org>
1879
1880         Reviewed by Geoff.
1881
1882         http://bugs.webkit.org/show_bug.cgi?id=11718
1883         REGRESSION: When I mouse up after dragging a selection outside of a iframe, the iframe
1884         continues to scroll automatically.
1885
1886         Test: manual-tests/autoscroll.html
1887
1888         * manual-tests/autoscroll.html: Added.
1889
1890         * page/EventHandler.cpp:
1891         (WebCore::EventHandler::handleMousePressEvent):
1892         Assign to m_mousePressNode earlier, so that it is available in the superframe as well.
1893         Reset m_mouseDownWasInSubframe to false when starting to handle a mousedown - previously, its value
1894         was only defined if the event was passed down to a widget or a subframe.
1895
1896         (WebCore::EventHandler::stopAutoscrollTimer):
1897         If the mouse down event was in a subframe, stop the subframe's timer.
1898
1899 2006-12-08  Alexey Proskuryakov  <ap@webkit.org>
1900
1901         Reviewed by Geoff.
1902
1903         http://bugs.webkit.org/show_bug.cgi?id=6275
1904         XMLHttpRequest.getResponseHeader should return a null string for non-existent headers
1905
1906         * bindings/js/JSXMLHttpRequest.cpp:
1907         (KJS::JSXMLHttpRequestProtoFunc::callAsFunction):
1908         Convert null getResponseHeader strings to JS null, rather than undefined.
1909
1910 2006-12-08  Alexey Proskuryakov  <ap@webkit.org>
1911
1912         Reviewed by Darin.
1913
1914         http://bugs.webkit.org/show_bug.cgi?id=9854
1915         HTTP Refresh header with quotes is parsed incorrectly
1916
1917         Test: http/tests/misc/redirect-with-quotes.php
1918
1919         * WebCore.xcodeproj/project.pbxproj:
1920         Added HTTPParsers.{h,cpp}. I intend to move Content-Type parsing here, as well.
1921
1922         * dom/Document.cpp:
1923         (WebCore::Document::processHttpEquiv):
1924         * loader/FrameLoader.cpp:
1925         (WebCore::FrameLoader::receivedFirstData):
1926         Use the new implementation in HTTPHeaders.
1927
1928         * platform/network/HTTPParsers.cpp: Added.
1929         (WebCore::skipWhiteSpace):
1930         (WebCore::parseHTTPRefresh):
1931         * platform/network/HTTPParsers.h: Added.
1932         Merged and rewrote existing implementations for better Firefox compatibility.
1933
1934 2006-12-08  Alexey Proskuryakov  <ap@webkit.org>
1935
1936         Reviewed by Tim H.
1937
1938         http://bugs.webkit.org/show_bug.cgi?id=11772
1939         REGRESSION: XMLSerializer.serializeToString incorrect value for CDATA nodes
1940
1941         Test: fast/dom/serialize-cdata.html
1942
1943         * editing/markup.cpp:
1944         (WebCore::startMarkup): Dump CDATA sections, too.
1945
1946 2006-12-08  Mitz Pettel  <mitz@webkit.org>
1947
1948         Reviewed by hyatt.
1949
1950         Deleted misplaced comment.
1951
1952         * rendering/RenderWidget.cpp:
1953
1954 2006-12-08  Rob Buis  <buis@kde.org>
1955
1956         Reviewed by Darin.
1957
1958         http://bugs.webkit.org/show_bug.cgi?id=6074
1959         WebKit+SVG and FireFox disagree on invalid "transform" handling
1960
1961         Test for parsing failure on transform attribute and clear the transform
1962         list upon failure to match FF behaviour.
1963
1964         * ksvg2/svg/SVGGradientElement.cpp:
1965         (WebCore::SVGGradientElement::parseMappedAttribute):
1966         * ksvg2/svg/SVGPatternElement.cpp:
1967         (WebCore::SVGPatternElement::parseMappedAttribute):
1968         * ksvg2/svg/SVGStyledTransformableElement.cpp:
1969         (WebCore::SVGStyledTransformableElement::parseMappedAttribute):
1970         * ksvg2/svg/SVGTextElement.cpp:
1971         (WebCore::SVGTextElement::parseMappedAttribute):
1972         * ksvg2/svg/SVGTransformable.cpp:
1973         (WebCore::SVGTransformable::parseTransformAttribute):
1974         * ksvg2/svg/SVGTransformable.h:
1975
1976 2006-12-07  Geoffrey Garen  <ggaren@apple.com>
1977
1978         Reviewed by Beth Dakin.
1979
1980         Fixed <rdar://problem/4870551> 9A320: <input type="text"> no longer 
1981         dispatches onchange event in response to enter key
1982         
1983         To match our old behavior and FF, we need to dispatch onchange in response to the
1984         ENTER key. The strategy here is just to dispatch a blur event, since that's how
1985         the search field always worked, and the DOM spec says onchange only fires
1986         as a precursor to blur.
1987
1988         * ChangeLog:
1989         * html/HTMLInputElement.cpp:
1990         (WebCore::HTMLInputElement::defaultEventHandler):
1991
1992 2006-12-07  Adam Roben  <aroben@apple.com>
1993
1994         Reviewed by Oliver.
1995
1996         Some small context menu-related fixes.
1997
1998         * html/HTMLFrameSetElement.cpp:
1999         (WebCore::HTMLFrameSetElement::defaultEventHandler): Don't try to
2000         resize on a contextmenuEvent.
2001         * html/HTMLInputElement.cpp:
2002         (WebCore::HTMLInputElement::defaultEventHandler): Only pass the event
2003         off to HTMLGenericFormElement if we haven't handled it.
2004
2005 2006-12-07  Anders Carlsson  <acarlsson@apple.com>
2006
2007         Reviewed by Darin.
2008
2009         <rdar://problem/4838778>
2010         Title: DashboardClient crashing in WebCore::SubresourceLoader::didFail
2011         
2012         * loader/SubresourceLoader.cpp:
2013         (WebCore::SubresourceLoader::stopLoading):
2014         * loader/SubresourceLoader.h:
2015         Add stopLoading method which currently just clears the client. This isn't the ideal fix,
2016         since it doesn't actually stop the load.
2017         
2018         * loader/mac/SubresourceLoaderMac.mm:
2019         (WebCore::SubresourceLoader::willSendRequest):
2020         (WebCore::SubresourceLoader::didReceiveResponse):
2021         (WebCore::SubresourceLoader::didReceiveData):
2022         (WebCore::SubresourceLoader::didFinishLoading):
2023         (WebCore::SubresourceLoader::didFail):
2024         (WebCore::SubresourceLoader::didCancel):
2025         Add null-checks.
2026         
2027         * xml/xmlhttprequest.cpp:
2028         (WebCore::XMLHttpRequest::abort):
2029         Call stopLoading.
2030
2031 2006-12-07  Kevin McCullough  <kmccullough@apple.com>
2032
2033         Reviewed by Geof.
2034
2035         - added the ability to set the auto repeating variable to force a keyPressed
2036         event from a keyDown event.
2037
2038         * platform/PlatformKeyboardEvent.h:
2039         (WebCore::PlatformKeyboardEvent::setIsAutoRepeat):
2040
2041 2006-12-07  Don Gibson  <dgibson77@gmail.com>
2042
2043         Reviewed by Darin.
2044
2045         http://bugs.webkit.org/show_bug.cgi?id=11749
2046         Don't call updateThumbProportion() unnecessarily.
2047
2048         * platform/ScrollBar.cpp:
2049         (WebCore::Scrollbar::setProportion):
2050
2051 2006-12-07  Beth Dakin  <bdakin@apple.com>
2052
2053         Reviewed by Brady.
2054
2055         Fixes "Open in new Window" item in WebCore ContextMenus. It wasn't 
2056         doing anything before, and now it works! Also some formatting 
2057         changes, etc.
2058
2059         * page/ContextMenuClient.h: Several of the parameters to several of 
2060         the functions here should be const or const references. And now 
2061         they are!
2062         * page/ContextMenuController.cpp:
2063         (WebCore::openNewWindow): Moved the open new window functionality 
2064         into a helper function since it is used by several menu item tags. 
2065         Now after calling chrome()->createWindow() we call chrome()->show() 
2066         on the new window, and so it appears!
2067         (WebCore::ContextMenuController::contextMenuItemSelected): Call new 
2068         openNewWindow function to do the right thing. Shift some 
2069         formatting, use local variable for HitTestResult. Implement action 
2070         for ContextMenuItemTagOpenLink.
2071
2072 2006-12-06  Kevin McCullough  <KMcCullough@apple.com>
2073
2074         Reviewed by.
2075
2076         - Removed a conflict marker
2077
2078         * ChangeLog:
2079
2080 2006-12-06  Justin Garcia  <justin.garcia@apple.com>
2081
2082         Reviewed by darin
2083         
2084         <rdar://problem/4818134>
2085         Crash in WebCore::selectRange when invoking WebView:insertNewLine in any empty content editable DIV.
2086
2087         * WebCore.vcproj/WebCore/WebCore.vcproj: Removed RebalanceWhitespaceCommand.*.
2088         * editing/visible_units.cpp:
2089         (WebCore::startOfLine): There are VisiblePositions at offset 0 in blocks without
2090         RootInlineBoxes, like empty editable blocks and bordered blocks.
2091         (WebCore::endOfLine): Ditto.
2092         
2093 2006-12-06  Kevin McCullough  <KMcCullough@apple.com>
2094
2095         Reviewed by.
2096
2097         - Removed a conflict marker
2098
2099         * ChangeLog:
2100
2101 2006-12-06  Justin Garcia  <justin.garcia@apple.com>
2102
2103         Reviewed by john
2104         
2105         <rdar://problem/4854869>
2106         Inserting a new line in a contenteditable=true SPAN whose parent is a DIV asserts
2107
2108         * editing/htmlediting.cpp:
2109         (WebCore::enclosingBlock): Use enclosingNodeWithType to prevent escape
2110         from editable content.
2111         * editing/markup.cpp:
2112         (WebCore::createMarkup): A null commonAncestorBlock will happen
2113         if commonAncestor is inside an inline editable root that doesn't
2114         contain any blocks.  Removed an early return for this case: the 
2115         code below the early return can and must handle it.
2116
2117 2006-12-06  Timothy Hatcher  <timothy@apple.com>
2118
2119         Reviewed by Mark Rowe.
2120
2121         <rdar://problem/4843505> Fix cross-library ivar use for 64-bit Objective-C
2122
2123         Adds a new WebCore.LP64.exp file that gets appended to the normal export file.
2124         This new file will have 64-bit only symbols we need to export.
2125
2126         * WebCore.LP64.exp: Added.
2127         * WebCore.xcodeproj/project.pbxproj:
2128
2129 2006-12-06  Anders Carlsson  <acarlsson@apple.com>
2130
2131         Reviewed by Maciej.
2132         
2133         Change SubresourceLoader to use a ResourceHandle, and change ResourceHandle to use a NSURLConnection.
2134         
2135         * loader/ResourceLoader.h:
2136         * loader/SubresourceLoader.cpp:
2137         (WebCore::SubresourceLoader::create):
2138         (WebCore::SubresourceLoader::didReceiveData):
2139         (WebCore::SubresourceLoader::didFinishLoading):
2140         (WebCore::SubresourceLoader::didFail):
2141         * loader/SubresourceLoader.h:
2142         (WebCore::SubresourceLoader::didReceiveAuthenticationChallenge):
2143         (WebCore::SubresourceLoader::didCancelAuthenticationChallenge):
2144         (WebCore::SubresourceLoader::willStopBufferingData):
2145         (WebCore::SubresourceLoader::willCacheResponse):
2146         (WebCore::SubresourceLoader::receivedCredential):
2147         (WebCore::SubresourceLoader::receivedRequestToContinueWithoutCredential):
2148         (WebCore::SubresourceLoader::receivedCancellation):
2149         * loader/SubresourceLoaderClient.h:
2150         (WebCore::SubresourceLoaderClient::didFail):
2151         * loader/icon/IconLoader.cpp:
2152         (WebCore::IconLoader::didFail):
2153         * loader/icon/IconLoader.h:
2154         * loader/loader.cpp:
2155         (WebCore::Loader::didFail):
2156         * loader/loader.h:
2157         * loader/mac/ResourceLoaderMac.mm:
2158         (WebCore::ResourceLoader::ResourceLoader):
2159         (WebCore::ResourceLoader::addData):
2160         (WebCore::ResourceLoader::resourceData):
2161         * loader/mac/SubresourceLoaderMac.mm:
2162         (WebCore::SubresourceLoader::SubresourceLoader):
2163         (WebCore::SubresourceLoader::setDefersLoading):
2164         (WebCore::SubresourceLoader::resourceData):
2165         (WebCore::SubresourceLoader::load):
2166         (WebCore::SubresourceLoader::create):
2167         (WebCore::SubresourceLoader::willSendRequest):
2168         (WebCore::SubresourceLoader::didReceiveResponse):
2169         (WebCore::SubresourceLoader::didReceiveData):
2170         (WebCore::SubresourceLoader::didFinishLoading):
2171         (WebCore::SubresourceLoader::didFail):
2172         (WebCore::SubresourceLoader::didCancel):
2173         * platform/network/ResourceHandle.cpp:
2174         (WebCore::ResourceHandle::ResourceHandle):
2175         (WebCore::ResourceHandle::create):
2176         * platform/network/ResourceHandle.h:
2177         * platform/network/ResourceHandleClient.h:
2178         (WebCore::ResourceHandleClient::didReceiveData):
2179         (WebCore::ResourceHandleClient::didFail):
2180         (WebCore::ResourceHandleClient::didReceiveAuthenticationChallenge):
2181         (WebCore::ResourceHandleClient::didCancelAuthenticationChallenge):
2182         (WebCore::ResourceHandleClient::willStopBufferingData):
2183         (WebCore::ResourceHandleClient::willCacheResponse):
2184         (WebCore::ResourceHandleClient::receivedCredential):
2185         (WebCore::ResourceHandleClient::receivedRequestToContinueWithoutCredential):
2186         (WebCore::ResourceHandleClient::receivedCancellation):
2187         * platform/network/ResourceHandleInternal.h:
2188         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
2189         * platform/network/mac/ResourceHandleMac.mm:
2190         (WebCore::ResourceHandle::~ResourceHandle):
2191         (WebCore::ResourceHandle::start):
2192         (WebCore::ResourceHandle::cancel):
2193         (WebCore::ResourceHandle::setDefersLoading):
2194         (WebCore::ResourceHandle::delegate):
2195         (WebCore::ResourceHandle::releaseDelegate):
2196         (WebCore::ResourceHandle::supportsBufferedData):
2197         (WebCore::ResourceHandle::bufferedData):
2198         (-[WebCoreResourceHandleAsDelegate initWithHandle:]):
2199         (-[WebCoreResourceHandleAsDelegate detachHandle]):
2200         (-[WebCoreResourceHandleAsDelegate connection:willSendRequest:redirectResponse:]):
2201         (-[WebCoreResourceHandleAsDelegate connection:didReceiveAuthenticationChallenge:]):
2202         (-[WebCoreResourceHandleAsDelegate connection:didCancelAuthenticationChallenge:]):
2203         (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
2204         (-[WebCoreResourceHandleAsDelegate connection:didReceiveData:lengthReceived:]):
2205         (-[WebCoreResourceHandleAsDelegate connection:willStopBufferingData:]):
2206         (-[WebCoreResourceHandleAsDelegate connectionDidFinishLoading:]):
2207         (-[WebCoreResourceHandleAsDelegate connection:didFailWithError:]):
2208         (-[WebCoreResourceHandleAsDelegate connection:willCacheResponse:]):
2209         (-[WebCoreResourceHandleAsDelegate useCredential:forAuthenticationChallenge:]):
2210         (-[WebCoreResourceHandleAsDelegate continueWithoutCredentialForAuthenticationChallenge:]):
2211         (-[WebCoreResourceHandleAsDelegate cancelAuthenticationChallenge:]):
2212         * xml/xmlhttprequest.cpp:
2213         (WebCore::XMLHttpRequest::didFail):
2214         * xml/xmlhttprequest.h:
2215
2216 2006-12-06  Beth Dakin  <bdakin@apple.com>
2217
2218         Reviewed by Adam.
2219
2220         There are two bugs with WebCore ContextMenus due to the static 
2221         ContextMenuItems. One bug is that we often crashed in 
2222         NSAutoreleasePool upon quitting the browser. The other bug is that 
2223         we were adding static NSMenuItems to multiple NSMenus, which is 
2224         disallowed. To fix these bugs, the MenuItems are no longer static. 
2225         This is in line with the current design in WebKit anyway. I made 
2226         some re-arrangements in the code because I also removed the macro 
2227         that was used to create the menu items since it was a bit 
2228         confusing.
2229
2230         * platform/ContextMenu.cpp:
2231         (WebCore::createFontSubMenu):
2232         (WebCore::createSpellingAndGrammarSubMenu):
2233         (WebCore::createSpellingSubMenu):
2234         (WebCore::createSpeechSubMenu):
2235         (WebCore::createWritingDirectionSubMenu):
2236         (WebCore::ContextMenu::populate):
2237         * platform/ContextMenuItem.h:
2238         * platform/mac/ContextMenuItemMac.mm:
2239         (WebCore::ContextMenuItem::ContextMenuItem): Use the NSMenuItem 
2240         global separator item if we have SeparatorType.
2241         * platform/mac/ContextMenuMac.mm:
2242         (WebCore::setMenuItemTarget):  Change name of getNSMenuItem since 
2243         that is no longer accurate.
2244         (WebCore::ContextMenu::appendItem): Above name change.
2245         (WebCore::ContextMenu::insertItem): Same.
2246
2247 2006-12-06  Kevin McCullough  <kmccullough@apple.com>
2248
2249         Reviewed by Geof.
2250
2251         - Returned the semantic meaning of the mask to be the actual repeat count,
2252         and changed auto_repeat to correctly differnetiate between keypressed and keydown.
2253
2254         * platform/win/KeyEventWin.cpp:
2255         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
2256
2257 2006-12-06  Justin Garcia  <justin.garcia@apple.com>
2258
2259         Reviewed by harrison
2260         
2261         <rdar://problem/4753545>
2262         REGRESSION: Edited whitespace sequences are all nbsps (10636)
2263
2264         * WebCore.xcodeproj/project.pbxproj: Removed RebalanceWhitespaceCommand.* from the project.
2265         * editing/CompositeEditCommand.cpp:
2266         (WebCore::isWhitespace): Moved from htmlediting.
2267         (WebCore::CompositeEditCommand::rebalanceWhitespaceAt): Moved the work that was
2268         once done in its own command here.  
2269         (WebCore::CompositeEditCommand::prepareWhitespaceAtPositionForSplit): Prevents
2270         whitespace around a position from collapsing when it's pushed apart during Paste.
2271         This function can eventually be deployed to eliminate the need for leading/trailing 
2272         whitespace handling in InsertParagraphSeparator, InsertLineBreak, Delete, and BreakBlockquote.
2273         (WebCore::CompositeEditCommand::rebalanceWhitespace): Cleaned up.
2274         * editing/CompositeEditCommand.h:
2275         * editing/DeleteSelectionCommand.cpp:
2276         (WebCore::DeleteSelectionCommand::doApply): Do rebalanceWhitespaceAt *before*
2277         saving the typing style, because whitespace rebalancing is no longer it's own
2278         command that claims to preserve the typing style.
2279         * editing/RebalanceWhitespaceCommand.cpp: Removed.
2280         * editing/RebalanceWhitespaceCommand.h: Removed.
2281         * editing/ReplaceSelectionCommand.cpp:
2282         (WebCore::ReplaceSelectionCommand::doApply): Moved the code to prepare whitespace
2283         arond a position for being pushed aparat to its own method.
2284         * editing/htmlediting.cpp:
2285         (WebCore::stringWithRebalancedWhitespace): Added.  Returns a rebalanced string.
2286         Takes in whether or not the beginning of that string will be at the start of
2287         a paragraph, because a space at such a position must have be nbsp, even if
2288         that doesn't follow the nbsp/space pattern used.  Similar stuff for the end 
2289         of a paragraph.
2290         * editing/htmlediting.h:
2291         * editing/markup.cpp:
2292         (WebCore::fillContainerFromString): Call stringWithRelabacedWhitespace.  Pass 
2293         it the startOfParagraph/endOfParagraph bools.
2294
2295 2006-12-05  John Sullivan  <sullivan@apple.com>
2296
2297         Reviewed by Beth
2298
2299         Moved spelling and grammar code from Frame to Editor
2300
2301         * WebCore.exp:
2302         updated for these changes
2303
2304         * page/Frame.h:
2305         removed declarations of spelling and grammar functions
2306
2307         * bridge/mac/FrameMac.h:
2308         removed declarations of spelling and grammar functions
2309
2310         * bridge/mac/FrameMac.mm:
2311         moved implementation of spelling and grammar functions from here
2312         (WebCore::FrameMac::respondToChangedSelection):
2313         updated for moved functions
2314
2315         * editing/Editor.h:
2316         moved declarations of spelling and grammar functions to here
2317
2318         * editing/mac/EditorMac.mm:
2319         moved implementation of spelling and grammar functions to here; changed
2320         only to make it compile (e.g. removing "editor()->" and adding "frame()->"
2321         where appropraite.
2322         (WebCore::findFirstMisspellingInRange):
2323         (WebCore::paragraphAlignedRangeForRange):
2324         (WebCore::findFirstGrammarDetailInRange):
2325         (WebCore::findFirstBadGrammarInRange):
2326         (WebCore::Editor::advanceToNextMisspelling):
2327         (WebCore::Editor::isSelectionMisspelled):
2328         (WebCore::isRangeUngrammatical):
2329         (WebCore::Editor::isSelectionUngrammatical):
2330         (WebCore::Editor::guessesForUngrammaticalSelection):
2331         (WebCore::core):
2332         (WebCore::Editor::guessesForMisspelledSelection):
2333         (WebCore::Editor::markMisspellingsInAdjacentWords):
2334         (WebCore::markAllMisspellingsInRange):
2335         (WebCore::markAllBadGrammarInRange):
2336         (WebCore::Editor::markMisspellings):
2337
2338         * platform/ContextMenu.cpp:
2339         (WebCore::ContextMenu::populate):
2340         updated for moved functions
2341
2342         * editing/TypingCommand.cpp:
2343         (WebCore::TypingCommand::markMisspellingsAfterTyping):
2344         updated for moved functions
2345
2346 2006-12-05  Anders Carlsson  <acarlsson@apple.com>
2347
2348         Reviewed by Maciej.
2349
2350         General cleanup, get rid of PlatformResponse (we have ResourceResponse now)
2351         and remove a couple of functions that were unused.
2352
2353         * loader/CachedResource.h:
2354         * loader/LoaderFunctions.h:
2355         * loader/mac/LoaderFunctionsMac.mm:
2356         * platform/network/ResourceHandle.h:
2357         * platform/network/ResourceHandleClient.h:
2358         * platform/network/mac/ResourceHandleMac.mm:
2359         (WebCore::ResourceHandle::~ResourceHandle):
2360
2361 2006-12-05  Kevin McCullough  <kmccullough@apple.com>
2362
2363         Reviewed by John.
2364
2365         - keydown is now a keydown event instead of a keypress event.
2366           Fixes some form submission oddities.
2367
2368         * platform/win/KeyEventWin.cpp:
2369
2370 2006-12-05  John Sullivan  <sullivan@apple.com>
2371
2372         Tiger build fix
2373
2374         * editing/mac/EditorMac.mm:
2375         declare -[NSSpellChecker learnWord:], on Tiger only (it's API on Leopard)
2376
2377 2006-12-05  John Sullivan  <sullivan@apple.com>
2378
2379         Reviewed by Geoff Garen
2380
2381         * page/Frame.h:
2382         remove declarations of ignoreSpelling() and learnSpelling()
2383
2384         * bridge/mac/FrameMac.h:
2385         remove declarations of ignoreSpelling() and learnSpelling()
2386         * bridge/mac/FrameMac.mm:
2387         moved implementations of ignoreSpelling() and learnSpelling() from here
2388
2389         * editing/Editor.h:
2390         added declarations of ignoreSpelling() and learnSpelling()
2391
2392         * editing/mac/EditorMac.mm:
2393         (WebCore::Editor::ignoreSpelling):
2394         moved here from FrameMac.mm
2395         (WebCore::Editor::learnSpelling):
2396         ditto
2397
2398         * page/ContextMenuController.cpp:
2399         (WebCore::ContextMenuController::contextMenuItemSelected):
2400         updated callers to use frame()->editor() rather than frame()
2401
2402 2006-12-05  John Sullivan  <sullivan@apple.com>
2403
2404         Reviewed by Adam
2405
2406         New context-menu mechanism fix for:
2407         <rdar://problem/4864351> Should leave out "No Guesses Found" from context menu for bad grammar
2408
2409         * platform/ContextMenu.cpp:
2410         (WebCore::ContextMenu::populate):
2411         Leave out "No Guesses Found" and separator for grammar-checking case.
2412
2413 2006-12-05  Rob Buis  <buis@kde.org>
2414
2415         Reviewed by Mitz.
2416
2417         http://bugs.webkit.org/show_bug.cgi?id=11686
2418         WebKit draws Carto.net tabgroup example completely incorrectly (ff does fine)
2419
2420         Make sure the SVG render objects are laid out before measuring their 
2421         dimensions using relativeBBox.
2422
2423         * ksvg2/svg/SVGLocatable.cpp:
2424         (WebCore::SVGLocatable::getBBox):
2425
2426 2006-12-05  John Sullivan  <sullivan@apple.com>
2427
2428         Reviewed by Darin
2429
2430         Grammar/Spelling code re-homing, baby step one: put isGrammarCheckingEnabled in Editor
2431         since that's where isContinousSpellCheckingEnabled lives.
2432
2433         * editing/Editor.h:
2434         * editing/Editor.cpp:
2435         (WebCore::Editor::isGrammarCheckingEnabled):
2436         new method, calls through to client a la isContinuousSpellCheckingEnabled
2437
2438         * bridge/mac/FrameMac.mm:
2439         (WebCore::FrameMac::advanceToNextMisspelling):
2440         call editor() rather than editor()->client()
2441         (WebCore::FrameMac::markMisspellings):
2442         ditto
2443
2444         * platform/ContextMenu.cpp:
2445         (WebCore::ContextMenu::populate):
2446         ditto
2447
2448 2006-12-05  Darin Adler  <darin@apple.com>
2449
2450         Reviewed by Geoff.
2451
2452         - a little cleanup
2453
2454         * html/HTMLInputElement.h: Removed unneeded includes of RenderObject.h
2455         and RenderStyle.h.
2456         * html/HTMLSelectElement.h: Removed unneeded include of RenderStyle.h.
2457         * ksvg2/svg/SVGStyledElement.h: Removed unneeded include of RenderStyle.h.
2458
2459         * ksvg2/svg/SVGSVGElement.h: Remove unneeded parameter to createSVGPoint.
2460         * ksvg2/svg/SVGSVGElement.cpp: (WebCore::SVGSVGElement::createSVGPoint):
2461         Ditto.
2462
2463         * ksvg2/scripts/generateJSBindings.pl: Removed unused script.
2464
2465 2006-12-05  Darin Adler  <darin@apple.com>
2466
2467         * doc: Removed empty directory. It's not clear this is a good place for
2468         documentation, so lets add it back later if we actually start using it.
2469
2470 2006-12-05  Anders Carlsson  <acarlsson@apple.com>
2471
2472         Reviewed by Brady, Darin.
2473
2474         * loader/loader.cpp:
2475         (WebCore::Loader::receivedAllData):
2476         Remove ref() call that was left around by mistake.
2477
2478 2006-12-05  Sam Weinig  <sam@webkit.org>
2479
2480         Reviewed by Tim H.
2481
2482         Fix for http://bugs.webkit.org/show_bug.cgi?id=11758
2483         Don't compile custom SVG and XSLT bindings in non-svg build
2484
2485         * bindings/js/JSSVGNumber.cpp:
2486         * bindings/js/JSSVGNumber.h:
2487         * bindings/js/JSSVGPoint.cpp:
2488         * bindings/js/JSSVGPoint.h:
2489         * bindings/js/JSSVGRect.cpp:
2490         * bindings/js/JSSVGRect.h:
2491         * bindings/js/JSXSLTProcessor.cpp:
2492         * bindings/js/JSXSLTProcessor.h:
2493
2494 2006-12-04  John Sullivan  <sullivan@apple.com>
2495
2496         Reviewed by Darin
2497
2498         WebCore part of fix for:
2499         <rdar://problem/4817188> Context menu for bad grammar should include suggestions and "Ignore Grammar"
2500
2501         The context menu mechanism is currently in flux; the old mechanism is still in place, but an
2502         up-and-coming new mechanism is waiting in the wings. I updated both of them, but couldn't
2503         test the new mechanism because it doesn't work well enough yet. Also, some of this code 
2504         should move from Frame to Editor, but that will wait for another checkin.
2505
2506         * page/Frame.h:
2507         added pure virtual function declarations for isSelectionUngrammatical() and guessesForUngrammaticalSelection()
2508
2509         * bridge/mac/FrameMac.h:
2510         added virtual functions declarations for isSelectionUngrammatical() and guessesForUngrammaticalSelection()
2511
2512         * bridge/mac/FrameMac.mm:
2513         (WebCore::FrameMac::isSelectionMisspelled):
2514         now updates spelling panel (whether or not it's showing), since this is now needed to make -[NSSSpellChecker
2515         ignoreWord:inSpellDocumentWithTag:] work correctly
2516         (WebCore::isRangeUngrammatical):
2517         new function, helper used by both isSelectionUngrammatical() and guessesForUngrammaticalSelection()
2518         (WebCore::FrameMac::isSelectionUngrammatical):
2519         new function, calls isRangeUngrammatical
2520         (WebCore::FrameMac::guessesForUngrammaticalSelection):
2521         ditto
2522
2523         * platform/ContextMenu.cpp:
2524         (WebCore::ContextMenu::populate):
2525         now considers bad grammar as well as misspellings
2526         
2527         * platform/ContextMenuItem.h:
2528         added ContextMenuItemTagIgnoreGrammar
2529         
2530 2006-12-05  Kirby White  <KWhiteRight@gmail.com>
2531
2532         Reviewed, tweaked and landed by Alexey.
2533
2534         <http://bugs.webkit.org/show_bug.cgi?id=11639> Form buttons don't look different when clicked
2535
2536         * rendering/RenderThemeWin.cpp:
2537         (WebCore::RenderThemeWin::determineState): Moved test for active 
2538         state before test for hover state, since active should override hover 
2539         when both are true.
2540
2541         * platform/gdk/RenderThemeGdk.cpp: 
2542         (WebCore::RenderThemeGdk::determineState): Same fix.
2543
2544 2006-12-05  Kirby White  <KWhiteRight@gmail.com>
2545
2546         Reviewed and landed by Alexey.
2547
2548         http://bugs.webkit.org/show_bug.cgi?id=11681
2549         Don't select the first option when resetting a listbox-style form 
2550         control (i.e., a multi-select control or one with size > 1) that
2551         has no default selection.
2552
2553         Test: fast/dom/HTMLSelectElement/listbox-select-reset.html
2554
2555         * html/HTMLSelectElement.cpp:
2556         (WebCore::HTMLSelectElement::reset):
2557
2558 2006-12-05  Lars Naesbye Christensen  <larsnaesbye@stud.ku.dk>
2559
2560         Reviewed and landed by Alexey.
2561
2562         http://bugs.webkit.org/show_bug.cgi?id=11752
2563         [CSS 3] missing support for cursor selector 'copy'
2564
2565         * Resources/copyCursor.png: Added.
2566         * WebCore.xcodeproj/project.pbxproj:
2567         * css/CSSComputedStyleDeclaration.cpp:
2568         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2569         * css/CSSValueKeywords.in:
2570         * manual-tests/cursor.html:
2571         * page/EventHandler.cpp:
2572         (WebCore::selectCursor):
2573         * platform/Cursor.h:
2574         * platform/mac/CursorMac.mm:
2575         (WebCore::copyCursor):
2576         * rendering/RenderStyle.h:
2577         (WebCore::):
2578
2579 2006-12-04  Beth Dakin  <bdakin@apple.com>
2580
2581         Reviewed by Geoff.
2582
2583         Fix from last check-in. This line was badbad.
2584
2585         * platform/mac/ContextMenuMac.mm:
2586         (WebCore::ContextMenu::~ContextMenu):
2587
2588 2006-12-04  Beth Dakin  <bdakin@apple.com>
2589
2590         Reviewed by Geoff.
2591
2592         With the new changes to ContextMenuItems, WebCore context menus 
2593         stopped appearing at all. And then when I got them to appear, they 
2594         crashed. This fixes both of these problems.
2595
2596         * platform/mac/ContextMenuItemMac.mm:
2597         (WebCore::ContextMenuItem::ContextMenuItem): keyEquivalent cannot 
2598         be nil. This was causing Obj-C to throw an exception preventing the 
2599         menus from popping up at all. 
2600         * platform/mac/ContextMenuMac.mm:
2601         (+[WebCoreMenuTarget sharedMenuTarget]): Re-name our static 
2602         MenuTarget so that it is more clear that it is a static and shared 
2603         WebCoreMenuTarget.
2604         (WebCore::ContextMenu::ContextMenu): Initialize the 
2605         WebCoreMenuTarget's controller in the ContextMenu constructor 
2606         instead of in getNSMenuItem since the controller will only possibly 
2607         change when a new ContextMenu has been created.
2608         (WebCore::ContextMenu::~ContextMenu): Set the target's controller 
2609         to 0.
2610         (WebCore::getNSMenuItem): A lot of this work is being done other 
2611         places now. Call new class method on WebCoreMenuTarget to get the 
2612         shared target.
2613         (WebCore::ContextMenu::appendItem): We should not be releasing the 
2614         menuItem here! This caused the crashes I saw.
2615         (WebCore::ContextMenu::insertItem): Same.
2616
2617 2006-12-04  Anders Carlsson  <acarlsson@apple.com>
2618
2619         Fix the build.
2620         
2621         * loader/mac/SubresourceLoaderMac.mm:
2622         (WebCore::SubresourceLoader::~SubresourceLoader):
2623         Add back the destructor.
2624
2625 2006-12-04  Anders Carlsson  <acarlsson@apple.com>
2626
2627         Reviewed by Darin.
2628         
2629         Change all ResourceHandleClients to be SubresourceLoaderClients instead. Also,
2630         make SubresourceLoader a ResourceHandleClient. This is a first step towards turning ResourceHandle into a 
2631         standalone class which doesn't need to know about SubresourceLoader.
2632
2633         * WebCore.xcodeproj/project.pbxproj:
2634         * loader/ResourceLoader.cpp:
2635         (WebCore::ResourceLoader::~ResourceLoader):
2636         (WebCore::ResourceLoader::ResourceLoader):
2637         (WebCore::ResourceLoader::setDefersLoading):
2638         * loader/SubresourceLoader.cpp:
2639         (WebCore::SubresourceLoader::SubresourceLoader):
2640         (WebCore::SubresourceLoader::~SubresourceLoader):
2641         (WebCore::SubresourceLoader::create):
2642         (WebCore::SubresourceLoader::willSendRequest):
2643         (WebCore::SubresourceLoader::didReceiveResponse):
2644         (WebCore::SubresourceLoader::didReceiveData):
2645         (WebCore::SubresourceLoader::didFinishLoading):
2646         (WebCore::SubresourceLoader::didFailWithError):
2647         (WebCore::SubresourceLoader::receivedAllData):
2648         * loader/SubresourceLoader.h:
2649         (WebCore::SubresourceLoader::loaderAsResourceHandleClient):
2650         (WebCore::SubresourceLoader::handle):
2651         * loader/SubresourceLoaderClient.h: Added.
2652         (WebCore::SubresourceLoaderClient::~SubresourceLoaderClient):
2653         (WebCore::SubresourceLoaderClient::willSendRequest):
2654         (WebCore::SubresourceLoaderClient::didReceiveResponse):
2655         (WebCore::SubresourceLoaderClient::didReceiveData):
2656         (WebCore::SubresourceLoaderClient::didFinishLoading):
2657         (WebCore::SubresourceLoaderClient::didFailWithError):
2658         (WebCore::SubresourceLoaderClient::receivedAllData):
2659         * loader/icon/IconLoader.cpp:
2660         (WebCore::IconLoader::startLoading):
2661         (WebCore::IconLoader::stopLoading):
2662         (WebCore::IconLoader::didReceiveResponse):
2663         (WebCore::IconLoader::didReceiveData):
2664         (WebCore::IconLoader::didFailWithError):
2665         (WebCore::IconLoader::didFinishLoading):
2666         (WebCore::IconLoader::clearLoadingState):
2667         * loader/icon/IconLoader.h:
2668         * loader/loader.cpp:
2669         (WebCore::Loader::servePendingRequests):
2670         (WebCore::Loader::receivedAllData):
2671         (WebCore::Loader::didFailWithError):
2672         (WebCore::Loader::didReceiveResponse):
2673         (WebCore::Loader::didReceiveData):
2674         (WebCore::Loader::cancelRequests):
2675         * loader/loader.h:
2676         * loader/mac/SubresourceLoaderMac.mm:
2677         (WebCore::SubresourceLoader::SubresourceLoader):
2678         (WebCore::SubresourceLoader::create):
2679         (WebCore::SubresourceLoader::willSendRequest):
2680         (WebCore::SubresourceLoader::didReceiveResponse):
2681         (WebCore::SubresourceLoader::didReceiveData):
2682         (WebCore::SubresourceLoader::didFinishLoading):
2683         (WebCore::SubresourceLoader::didFail):
2684         (WebCore::SubresourceLoader::didCancel):
2685         * platform/network/ResourceHandle.cpp:
2686         (WebCore::ResourceHandle::ResourceHandle):
2687         (WebCore::ResourceHandle::create):
2688         * platform/network/ResourceHandle.h:
2689         * platform/network/ResourceHandleClient.h:
2690         * platform/network/ResourceHandleInternal.h:
2691         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
2692         * platform/network/mac/ResourceHandleMac.mm:
2693         (WebCore::ResourceHandle::start):
2694         (WebCore::ResourceHandle::finishJobAndHandle):
2695         (WebCore::ResourceHandle::loader):
2696         * xml/xmlhttprequest.cpp:
2697         (WebCore::XMLHttpRequest::send):
2698         (WebCore::XMLHttpRequest::didFailWithError):
2699         (WebCore::XMLHttpRequest::didFinishLoading):
2700         (WebCore::XMLHttpRequest::willSendRequest):
2701         (WebCore::XMLHttpRequest::didReceiveResponse):
2702         (WebCore::XMLHttpRequest::didReceiveData):
2703         * xml/xmlhttprequest.h:
2704
2705 2006-12-04  Darin Adler  <darin@apple.com>
2706
2707         Reviewed by Adele.
2708
2709         - fix another part of http://bugs.webkit.org/show_bug.cgi?id=11628
2710           REGRESSION (r17597): Command-return in text fields doesn't open a new tab or window
2711
2712         This fixes command-return when the focus is on a link.
2713         Despite the title of the bug, Mitz wanted me to fix both, and I will not
2714         say no to him!
2715
2716         Test: fast/events/simulated-key-state.html
2717
2718         * dom/EventTargetNode.cpp:
2719         (WebCore::EventTargetNode::dispatchSimulatedMouseEvent): Instead of always passing
2720         false for all the key state in simulated mouse events, pass the state from the
2721         first underlying event in the chain that has key state; in the case in the bug,
2722         the keyboard event will be the underlying event itself and we'll propagate the
2723         alt key modifier to the mouse event, resulting in the effect we want. It's nice
2724         that JavaScript also gets to see the proper modifiers in the mouse event.
2725
2726         * html/HTMLAnchorElement.cpp: (WebCore::HTMLAnchorElement::defaultEventHandler):
2727         Added code to pass in an underlying event to dispatchSimulatedClick. After looking
2728         at all the other callers, this seems to be the only one that needs to pass an
2729         event that is currently passing 0. Also removed the code that only simulated a
2730         click when the event has a PlatformKeyboardEvent -- no reason for that and it
2731         prevented me from writing a layout test for the fix. 
2732
2733         * dom/UIEventWithKeyState.h: Added findEventWithKeyState function that walks the
2734         underlyingEvent chain to find the first event that has key state. This already
2735         existed in WebKit, but I wanted to use it in dispatchSimulatedMouseEvent.
2736         * dom/UIEventWithKeyState.cpp: Added.
2737
2738         * CMakeLists.txt: Added UIEventWithKeyState.cpp.
2739         * WebCore.vcproj/WebCore/WebCore.vcproj: Added UIEventWithKeyState.cpp.
2740         * WebCore.xcodeproj/project.pbxproj: Added UIEventWithKeyState.cpp.
2741         * WebCoreSources.bkl: Added UIEventWithKeyState.cpp.
2742
2743         * WebCore.exp: Added findEventWithKeyState, used by WebKit.
2744
2745 2006-12-04  Kevin McCullough  <KMcCullough@apple.com>
2746
2747         Reviewed by Darin.
2748
2749         - removed the guards for the "multiple forms submission" issue, which may not be
2750           an issue anymore and the guards prevent perfectly legitimate websites from
2751           working correctly.
2752
2753         * bridge/mac/FrameMac.mm:
2754         (WebCore::FrameMac::setView):
2755         * bridge/mac/WebCoreAXObject.mm:
2756         (-[WebCoreAXObject accessibilityPerformAction:]):
2757         * bridge/win/FrameWin.cpp:
2758         (WebCore::FrameWin::keyPress):
2759         * config.h:
2760         * loader/FrameLoader.cpp:
2761         (WebCore::FrameLoader::submitForm):
2762         * loader/FrameLoader.h:
2763         * loader/mac/FrameLoaderMac.mm:
2764         (WebCore::FrameLoader::receivedMainResourceError):
2765         * loader/qt/FrameLoaderQt.cpp:
2766         (WebCore::FrameLoader::submitForm):
2767         * page/Frame.cpp:
2768         (WebCore::Frame::setView):
2769         * page/mac/EventHandlerMac.mm:
2770         (WebCore::EventHandler::keyEvent):
2771         (WebCore::EventHandler::mouseDown):
2772         * platform/qt/FrameQt.cpp:
2773         (WebCore::FrameQt::keyEvent):
2774
2775 2006-12-02  Geoffrey Garen  <ggaren@apple.com>
2776
2777         Reviewed by Darin Adler.
2778         
2779         Added support for Dashboard backward compatibility mode.
2780         
2781         * html/CanvasRenderingContext2D.cpp:
2782         (WebCore::CanvasRenderingContext2D::stroke): Added support for old behavior
2783         of automatically clearing the stroke path buffer after a call to stroke().
2784         * html/HTMLCanvasElement.cpp: Added supoprt for old behavior of the canvas
2785         tag being self-closing.
2786         (WebCore::HTMLCanvasElement::endTagRequirement):
2787         (WebCore::HTMLCanvasElement::tagPriority):
2788         * html/HTMLCanvasElement.h:
2789         * html/HTMLParser.cpp: Ditto.
2790         (WebCore::HTMLParser::canvasCreateErrorCheck):
2791         * xml/xmlhttprequest.cpp: Added support for old behavior of silently ignoring
2792         a call to setRequestHeader() if it preceded a call to open() or followed a call
2793         to send().
2794         (WebCore::XMLHttpRequest::setRequestHeader):
2795
2796 2006-12-04  Darin Adler  <darin@apple.com>
2797
2798         Reviewed by Alice.
2799
2800         * bridge/EditorClient.h: Removed "_web_" prefix from
2801         C++ userVisibleString member function. Alice will probably change
2802         this so it's not on the editor client any more later.
2803
2804         * editing/Editor.h: Removed "_web_" prefix from
2805         C++ userVisibleString member function.
2806         * editing/Editor.cpp: Tweaked formatting a bit. Removed Mac-specific
2807         code from this file.
2808
2809         * editing/mac/EditorMac.mm:
2810         (WebCore::Editor::newGeneralClipboard): Removed unnneded local variable.
2811         (WebCore::Editor::userVisibleString): Moved this function here.
2812
2813         * platform/Pasteboard.h: Added some FIXMEs. Removed unneeded includes.
2814         Made Pasteboard noncopyable. Removed use of "protected" where we should
2815         be using "private". Removed s_generalPasteboard.
2816         * platform/mac/PasteboardMac.mm: Added some FIXMEs. Removed the
2817         s_generalPasteboard global. Removed the unused destructor. Updated call
2818         to userVisibleString for name change. Tweaked formatting.
2819
2820 2006-12-04  Alice Liu  <alice.liu@apple.com>
2821
2822         Reviewed by Oliver.
2823
2824         Moved some constants from EventHandlerMac.mm to EventHandler.cpp
2825         Added some platform-specific data members and functions.
2826
2827         * page/EventHandler.cpp:
2828         * page/EventHandler.h:
2829         * page/mac/EventHandlerMac.mm:
2830         * platform/PlatformMouseEvent.h:
2831         (WebCore::):
2832         (WebCore::PlatformMouseEvent::timestamp):
2833         (WebCore::PlatformMouseEvent::activatedWebView):
2834         (WebCore::PlatformMouseEvent::type):
2835
2836 2006-12-04  Anders Carlsson  <acarlsson@apple.com>
2837
2838         Reviewed by Darin, Geoff.
2839
2840         Get rid of ResourceHandle::kill(), all it did was to balance out a ref() in ResourceHandle::start().
2841         We use RefPtrs to ResourceHandle instead.
2842
2843         * loader/icon/IconLoader.cpp:
2844         (WebCore::IconLoader::~IconLoader):
2845         (WebCore::IconLoader::stopLoading):
2846         (WebCore::IconLoader::didReceiveResponse):
2847         * loader/loader.cpp:
2848         (WebCore::Loader::servePendingRequests):
2849         (WebCore::Loader::cancelRequests):
2850         (WebCore::Loader::jobForRequest):
2851         * loader/loader.h:
2852         * platform/network/ResourceHandle.cpp:
2853         * platform/network/ResourceHandle.h:
2854         * platform/network/mac/ResourceHandleMac.mm:
2855         (WebCore::ResourceHandle::start):
2856         (WebCore::ResourceHandle::finishJobAndHandle):
2857         (WebCore::ResourceHandle::reportError):
2858         * xml/xmlhttprequest.cpp:
2859         (WebCore::XMLHttpRequest::abort):
2860         (WebCore::XMLHttpRequest::didFinishLoading):
2861
2862 2006-12-04  Oliver Hunt  <oliver@apple.com>
2863
2864         Build fix for non-SVG builds
2865
2866         * bindings/js/JSSVGPoint.cpp:
2867         (WebCore::JSSVGPointProtoFunc::callAsFunction):
2868
2869 2006-12-04  Darin Adler  <darin@apple.com>
2870
2871         Reviewed by Beth.
2872
2873         - fix http://bugs.webkit.org/show_bug.cgi?id=11632
2874           AKA <rdar://problem/4858866> REGRESSION (r17770): Overflow areas' scrollbars don't work
2875
2876         No test case added at the moment, but Beth said she'd investigate
2877         adding one after the fact.
2878
2879         * page/mac/EventHandlerMac.mm:
2880         (WebCore::EventHandler::passMousePressEventToScrollbar):
2881         Fix obvious-in-retrospect copy and paste error -- call
2882         passMouseDownEventToWidget instead of passWheelEventToWidget.
2883
2884 2006-12-04  Don Gibson  <dgibson77@gmail.com>
2885
2886         Reviewed and landed by Alexey.
2887
2888         http://bugs.webkit.org/show_bug.cgi?id=11738:
2889         Make link clicking work again on Windows.
2890
2891         This re-implements a few functions that used to be part of FrameWin in
2892         their new loader-based locations, and copies a few things from the Mac
2893         and Qt event handling code that aren't strictly necessary but are
2894         pretty simple.
2895
2896         * WebCore.vcproj/WebCore/WebCore.vcproj:
2897         * bridge/win/ChromeClientWin.h:
2898         * bridge/win/ContextMenuClientWin.h:
2899         * bridge/win/EditorClientWin.h:
2900         * bridge/win/FrameWin.cpp:
2901         (WebCore::FrameWin::client):
2902         * bridge/win/FrameWin.h:
2903         * loader/win/DocumentLoaderWin.cpp: Added.
2904         (WebCore::DocumentLoader::setTitle):
2905         * loader/win/FrameLoaderClientWin.cpp: Added.
2906         (WebCore::FrameLoaderClientWin::userAgent):
2907         * loader/win/FrameLoaderClientWin.h:
2908         * loader/win/FrameLoaderWin.cpp: Added.
2909         (WebCore::FrameLoader::urlSelected):
2910         (WebCore::FrameLoader::submitForm):
2911         (WebCore::FrameLoader::setTitle):
2912         * page/win/EventHandlerWin.cpp: Added.
2913         (WebCore::EventHandler::passMousePressEventToSubframe):
2914         (WebCore::EventHandler::passMouseMoveEventToSubframe):
2915         (WebCore::EventHandler::passMouseReleaseEventToSubframe):
2916         (WebCore::EventHandler::passWheelEventToSubframe):
2917         (WebCore::EventHandler::passMousePressEventToScrollbar):
2918         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
2919         * platform/win/TemporaryLinkStubs.cpp:
2920         (WebCore::EventHandler::tabsToLinks):
2921         (WebCore::EventHandler::tabsToAllControls):
2922         (WebCore::EventHandler::lastEventIsMouseUp):
2923         (WebCore::EventHandler::passSubframeEventToSubframe):
2924         (WebCore::EventHandler::passMouseDownEventToWidget):
2925         (WebCore::EventHandler::passWheelEventToWidget):
2926         (WebCore::FrameLoader::getHistoryLength):
2927         (WebCore::FrameLoader::historyURL):
2928         (WebCore::FrameLoader::createFrame):
2929         (WebCore::FrameLoaderClientWin::setTitle):
2930
2931 2006-12-04  Don Gibson  <dgibson77@gmail.com>
2932
2933         Reviewed by Mitz.
2934
2935         http://bugs.webkit.org/show_bug.cgi?id=11748:
2936         Windows build bustage.
2937
2938         * WebCore.vcproj/WebCore/WebCore.vcproj:
2939         * platform/ContextMenuItem.h:
2940         * platform/win/TemporaryLinkStubs.cpp:
2941         (WebCore::ContextMenuItem::ContextMenuItem):
2942         (WebCore::ContextMenuItem::platformDescription):
2943         (WebCore::ContextMenuItem::action):
2944         (WebCore::ContextMenuItem::setAction):
2945         (WebCore::ContextMenuItem::title):
2946         (WebCore::ContextMenuItem::setTitle):
2947         (WebCore::ContextMenuItem::platformSubMenu):
2948         (WebCore::ContextMenuItem::setSubMenu):
2949
2950 2006-12-04  John Sullivan  <sullivan@apple.com>
2951
2952         Reviewed by Anders
2953
2954         Moved EditorMac.mm to its appropriate location
2955
2956         * platform/mac/EditorMac.mm: Removed.
2957         * editing/mac/EditorMac.mm: Added
2958
2959         * WebCore.xcodeproj/project.pbxproj:
2960         updated for this change
2961
2962 2006-12-04  Rob Buis  <buis@kde.org>
2963
2964         Reviewed by dhyatt.
2965
2966         Patch by pmax.
2967
2968         http://bugs.webkit.org/show_bug.cgi?id=3280
2969         With LEGEND element, align=right value is not supported
2970         http://bugs.webkit.org/show_bug.cgi?id=11544
2971         <legend> rendering doesn't take align into account
2972
2973         Allow aligning for legends in both RTL and LTR mode.
2974
2975         * rendering/RenderFieldset.cpp:
2976         (WebCore::RenderFieldset::layoutLegend):
2977
2978 2006-12-03  Mark Rowe  <bdash@webkit.org>
2979
2980         Reviewed by Alexey.
2981
2982         http://bugs.webkit.org/show_bug.cgi?id=11730
2983         Bug 11730: Meta HTTP Refresh that contains a fraction / decimal get ignored.
2984
2985         * dom/Document.cpp:
2986         (WebCore::Document::processHttpEquiv): Parse the refresh interval as a double rather than an integer.
2987
2988 2006-12-03  Nikolas Zimmermann  <zimmermann@kde.org>
2989
2990         Reviewed by Oliver.
2991
2992         Fix following bugs:
2993         http://bugs.webkit.org/show_bug.cgi?id=11734
2994         http://bugs.webkit.org/show_bug.cgi?id=11685
2995
2996         SVGPoint/SVGRect/SVGNumber were missing put() support.
2997         SVGPoint.matrixTransform() was missing.
2998
2999         In SVG DOM there are no cases where a readwrite property
3000         exists of type SVGRect/SVGNumber/SVGPoint. Only function
3001         calls returns instances of these objects. It would make
3002         no sense to be able to write "someObj.getBbox().x = 100", and
3003         modify the actual stored internal value of "someObj".
3004
3005         The only cases where these modification makes sense, is
3006         when these SVGPoint/SVGRect/SVGNumber objects are created
3007         via document.rootElement.createSVGPoint/Rect/Number (SVGSVGElement interface).
3008
3009         Result: The current implementation, where we just modify the stored FloatPoint/FloatRect/double
3010         values in the JSSVGPoint/Rect/Number wrappers directly, is sufficient.
3011
3012         Patch created by Rob & me - co production.
3013         Long live the great carto.next examples! :-)
3014
3015         * CMakeLists.txt:
3016         * DerivedSources.make:
3017         * bindings/js/JSSVGNumber.cpp:
3018         (WebCore::):
3019         (WebCore::JSSVGNumber::getOwnPropertySlot):
3020         (WebCore::JSSVGNumber::getValueProperty):
3021         (WebCore::JSSVGNumber::put):
3022         (WebCore::JSSVGNumber::putValueProperty):
3023         * bindings/js/JSSVGNumber.h:
3024         (WebCore::JSSVGNumber::):
3025         (WebCore::JSSVGNumber::impl):
3026         * bindings/js/JSSVGPoint.cpp:
3027         (WebCore::JSSVGPoint::JSSVGPoint):
3028         (WebCore::JSSVGPoint::put):
3029         (WebCore::JSSVGPoint::putValueProperty):
3030         (WebCore::JSSVGPointProtoFunc::callAsFunction):
3031         * bindings/js/JSSVGPoint.h:
3032         (WebCore::JSSVGPoint::):
3033         * bindings/js/JSSVGRect.cpp:
3034         (WebCore::JSSVGRect::put):
3035         (WebCore::JSSVGRect::putValueProperty):
3036         * bindings/js/JSSVGRect.h:
3037         * bindings/objc/DOMSVGPoint.mm:
3038         (-[DOMSVGPoint matrixTransform:]):
3039         * platform/graphics/FloatPoint.cpp:
3040         (WebCore::FloatPoint::matrixTransform):
3041         * platform/graphics/FloatPoint.h:
3042
3043 2006-12-03  Nikolas Zimmermann  <zimmermann@kde.org>
3044
3045         Reviewed by Dave.
3046
3047         Another missing piece in the platform/graphics move.
3048
3049         * WebCore.xcodeproj/project.pbxproj:
3050         * platform/ImageAnimationObserver.h: Moved to platform/graphics.
3051
3052 2006-12-03  Rob Buis  <buis@kde.org>
3053
3054         Reviewed by Oliver.
3055
3056         http://bugs.webkit.org/show_bug.cgi?id=11667
3057         SVG: method .getTransformToElement(elt) in SVGLocatable not implemented
3058
3059         Implement getTransformToElement functionality. Introduce virtual
3060         baseclass SVGLocatable to allow one implementation of the functionality.
3061         Finally cleanup some code.
3062
3063         * ksvg2/svg/SVGLocatable.cpp:
3064         (WebCore::SVGLocatable::getTransformToElement):
3065         * ksvg2/svg/SVGLocatable.h:
3066         * ksvg2/svg/SVGStyledLocatableElement.cpp:
3067         (WebCore::SVGStyledLocatableElement::SVGStyledLocatableElement):
3068         (WebCore::SVGStyledLocatableElement::nearestViewportElement):
3069         (WebCore::SVGStyledLocatableElement::farthestViewportElement):
3070         (WebCore::SVGStyledLocatableElement::getCTM):
3071         (WebCore::SVGStyledLocatableElement::getScreenCTM):
3072         * ksvg2/svg/SVGStyledLocatableElement.h:
3073         * ksvg2/svg/SVGStyledTransformableElement.cpp:
3074         (WebCore::SVGStyledTransformableElement::SVGStyledTransformableElement):
3075         (WebCore::SVGStyledTransformableElement::localMatrix):
3076         (WebCore::SVGStyledTransformableElement::getCTM):
3077         (WebCore::SVGStyledTransformableElement::getScreenCTM):
3078         (WebCore::SVGStyledTransformableElement::updateLocalTransform):
3079         (WebCore::SVGStyledTransformableElement::parseMappedAttribute):
3080         (WebCore::SVGStyledTransformableElement::nearestViewportElement):
3081         (WebCore::SVGStyledTransformableElement::farthestViewportElement):
3082         * ksvg2/svg/SVGStyledTransformableElement.h:
3083         * ksvg2/svg/SVGTextElement.h:
3084         * ksvg2/svg/SVGTransformable.h:
3085
3086 2006-12-03  Nikolas Zimmermann  <zimmermann@kde.org>
3087
3088         Reviewed by Rob.
3089
3090         Move some files around, which have been forgotton in the platform/graphics move.
3091
3092         * CMakeLists.txt:
3093         * WebCore.xcodeproj/project.pbxproj:
3094         * platform/mac/GraphicsContextMac.mm: Moved to platform/graphics/mac.
3095         * platform/qt/GraphicsContextQt.cpp: Moved to platform/grahpics/qt.
3096
3097 2006-12-03  Nikolas Zimmermann  <zimmermann@kde.org>
3098
3099         Reviewed by Mitz.
3100
3101         Fix non-svg build.
3102
3103         * platform/graphics/GraphicsContext.h:
3104         * platform/mac/GraphicsContextMac.mm:
3105
3106 2006-12-02  John Sullivan  <sullivan@apple.com>
3107
3108         Reviewed by Tim Omernick
3109
3110         Removed a couple of big chunks of duplicated code from the spelling and grammar stuff by merging
3111         the find-next-instance functions with the mark-all-instances functions.
3112
3113         * bridge/mac/FrameMac.mm:
3114         (WebCore::findFirstMisspellingInRange):
3115         added markAll parameter, and reworked loop so that if markAll parameter is true, this function loops
3116         through the entire range and marks each misspelling
3117         (WebCore::findFirstGrammarDetailInRange):
3118         extracted from findFirstBadGrammarInRange; loops through the potentially-multiple details in a given
3119         ungrammatical phrase (e.g., multiple grammar errors in one sentence). Has a markAll parameter akin
3120         to the one in findFirstMisspellingInRange.
3121         (WebCore::findFirstBadGrammarInRange):
3122         added markAll parameter like the one in findFirstMisspellingInRange, and extracted findFirstGrammarDetailInRange
3123         (WebCore::FrameMac::advanceToNextMisspelling):
3124         pass "false" for new markAll parameters
3125         (WebCore::markAllMisspellingsInRange):
3126         now just calls findFirstMisspellingInRange with markAll = true, thus removing a big hunk of duplicated code
3127         (WebCore::markAllBadGrammarInRange):
3128         now just calls findFirstBadGrammarInRange with markAll = true, thus removing a big hunk of duplicated code
3129
3130 2006-12-02  Mitz Pettel  <mitz@webkit.org>
3131
3132         Reviewed by Hyatt.
3133
3134         - fix http://bugs.webkit.org/show_bug.cgi?id=11672
3135           REGRESSION (r17068): Repro crash due to painting without layout
3136
3137         Test: fast/dynamic/containing-block-change.html
3138
3139         * rendering/RenderObject.cpp:
3140         (WebCore::RenderObject::setStyle): Changed the logic used
3141         to find absolutely positioned descendant's current containing block to
3142         match the changes made to containingBlock() in the fix for bug 9347.
3143
3144 2006-12-02  MorganL  <morganl.webkit@yahoo.com>
3145
3146         Reviewed by Darin.
3147
3148         http://bugs.webkit.org/show_bug.cgi?id=11709
3149         DeprecatedString::format is broken on Windows
3150
3151         Use _vscprintf on Windows to compute the length of the buffer that
3152         vsnprintf would need.
3153
3154         * platform/DeprecatedString.cpp:
3155         (WebCore::DeprecatedString::format):
3156         * platform/String.cpp:
3157         (WebCore::String::format):
3158
3159 2006-12-01  Beth Dakin  <bdakin@apple.com>
3160
3161         Reviewed by Adam.
3162
3163         Support for sub-menus in WebCore context menus. This also re-
3164         architects the ContextMenuItem class so that it is more like
3165         ContextMenu in that the class is now really just a wrapper for the
3166         platformDescription
3167
3168         * WebCore.exp:
3169         * WebCore.xcodeproj/project.pbxproj:
3170         * page/ContextMenuController.cpp:
3171         (WebCore::ContextMenuController::contextMenuItemSelected): Add
3172         place-holders for new tags for the sub-menu items. I will flesh
3173         these out in a separate check-in.
3174         * platform/ContextMenu.cpp:
3175         (WebCore::createFontSubMenu):
3176         (WebCore::createSpellingAndGrammarSubMenu):
3177         (WebCore::createSpellingSubMenu):
3178         (WebCore::createSpeechSubMenu):
3179         (WebCore::createWritingDirectionSubMenu):
3180         (WebCore::ContextMenu::populate): Call the above functions to add
3181         the appropriate sub-menus to editing context menus.
3182         * platform/ContextMenu.h:
3183         * platform/ContextMenuItem.h:
3184         (WebCore::): New tags in the ContextMenuAction enumeration.
3185         (WebCore::ContextMenuItem::parentMenu):
3186         (WebCore::ContextMenuItem::setType):
3187         * platform/PlatformMenuDescription.h: Added. This defines
3188         PlatformMenuDesciption. It needs to be its own header because we
3189        have to include it from ContextMenu.h and ContextMenuItem.h
3190         * platform/mac/ContextMenuItemMac.mm: Lots of adjustments here to
3191         make this class basically just be a wrapper for NSMenuItem.
3192         (WebCore::ContextMenuItem::ContextMenuItem):
3193         (WebCore::ContextMenuItem::~ContextMenuItem):
3194         (WebCore::ContextMenuItem::platformDescription):
3195         (WebCore::ContextMenuItem::action):
3196         (WebCore::ContextMenuItem::title):
3197         (WebCore::ContextMenuItem::platformSubMenu):
3198         (WebCore::ContextMenuItem::setAction):
3199         (WebCore::ContextMenuItem::setTitle):
3200         (WebCore::ContextMenuItem::setSubMenu):
3201         * platform/mac/ContextMenuMac.mm:
3202         (WebCore::ContextMenu::ContextMenu):
3203         (WebCore::getNSMenuItem): Now we only have to get the
3204         platformDescription of the ContextMenuItem and then set its target
3205         and action.
3206         (WebCore::ContextMenu::itemCount):
3207
3208 2006-12-01  Kevin McCullough  <KMcCullough@apple.com>
3209
3210         Reviewed by .
3211
3212         - accidentally checked in with previous checkin
3213
3214         * platform/qt/FrameQt.cpp:
3215         (WebCore::FrameQt::keyEvent):
3216
3217 2006-12-01  Kevin McCullough  <KMcCullough@apple.com>
3218
3219         Reviewed by Adam.
3220
3221         - better solution to the ambiguous reference
3222
3223         * platform/Widget.h:
3224         (WebCore::Widget::handleMouseMoveEvent):
3225         (WebCore::Widget::handleMouseReleaseEvent):
3226         * platform/qt/FrameQt.cpp:
3227         (WebCore::FrameQt::keyEvent):
3228         * platform/win/PlatformScrollBar.h:
3229         * platform/win/TemporaryLinkStubs.cpp:
3230         (WebCore::PlatformScrollbar::handleMouseMoveEvent):
3231         (WebCore::PlatformScrollbar::handleMouseReleaseEvent):
3232
3233 2006-12-01  Justin Garcia  <justin.garcia@apple.com>
3234
3235         Reviewed by john
3236         
3237         <rdar://problem/4826940>
3238         Selection change performed even when delete delegate replies NO (11415)
3239
3240         No layout test for the bug fix, because there's no way to register a custom
3241         editing delegate from a layout test.  Layout tests are effected by the change
3242         to avoid sending unnecessary shouldChangeSelections, however. 
3243
3244         * editing/Editor.cpp:
3245         (WebCore::Editor::appliedEditing): Don't bother sending shouldChangeSelection
3246         if the editing operation didn't change the selection.  Still call
3247         setSelection though, because it does work in this case that's necessary,
3248         like clearing the typing style.
3249         (WebCore::Editor::unappliedEditing): Ditto.
3250         (WebCore::Editor::reappliedEditing): Ditto.
3251         * editing/TypingCommand.cpp:
3252         (WebCore::TypingCommand::deleteKeyPressed): Don't set the starting
3253         selection if the editing delegate returns NO from shouldDeleteRange.
3254         Notice we now call setStartingSelection in the case where
3255         the current selection was a range selection.  This is fine because
3256         it's a no-op (the starting selection is already the current selection).
3257         (WebCore::TypingCommand::forwardDeleteKeyPressed): Ditto.
3258
3259 2006-12-01  John Sullivan  <sullivan@apple.com>
3260
3261         Reviewed by Darin
3262         
3263         Move subrange helper function from spellchecking code to TextIterator
3264
3265         * editing/TextIterator.h:
3266         added TextIterator::subrange
3267         * editing/TextIterator.cpp:
3268         (WebCore::CharacterIterator::advance):
3269         early return if count is <= 0; assert that it's not < 0
3270         (WebCore::TextIterator::subrange):
3271         new function, moved from FrameMac.mmm
3272
3273         * bridge/mac/FrameMac.mm:
3274         moved subrange() function to TextIterator
3275         (WebCore::FrameMac::advanceToNextMisspelling):
3276         use TextIterator::subrange
3277         (WebCore::markAllMisspellingsInRange):
3278         ditto
3279         (WebCore::markAllBadGrammarInRange):
3280         ditto
3281
3282 2006-12-01  Darin Adler  <darin@apple.com>
3283
3284         Reviewed by Mitz.
3285
3286         - fix http://bugs.webkit.org/show_bug.cgi?id=11628
3287           REGRESSION (r17597): Command-return in native text fields doesn't open a new tab or window
3288
3289         I couldn't think of an easy way to make a regression test for this, but maybe
3290         I'll get an idea later about how to do it.
3291
3292         The main thing I did was add a concept of a DOM event having an "underlying event".
3293         That allows the DOM activate event to contain inside it the original keyboard event
3294         that triggered the form submission, and thus allows WebKit to see the modifier keys
3295         from that original event. The code that uses the underlying event is in WebKit, but
3296         the code to set it up is here in WebCore.
3297
3298         - also do some clean-up to related event handling code
3299
3300         * bindings/js/kjs_events.cpp: (KJS::DOMEvent::getValueProperty): Updated for the
3301         name change of cancelBubble.
3302
3303         * dom/Event.h: Removed a useless comment. Fixed some whitespace and formatting.
3304         Renamed getCancelBubble to cancelBubble to match the DOM -- I suspect the old
3305         name predated the use of the m_ prefix on data members. Added the underlying event,
3306         and a getter and setter.
3307         * dom/Event.cpp:
3308         (WebCore::Event::setTarget): Updated to take a PassRefPtr.
3309         (WebCore::Event::setUnderlyingEvent): Added.
3310
3311         * dom/EventTargetNode.h: Added an optional underlyingEvent parameter to
3312         dispatchUIEvent, one of the overloads of dispatchMouseEvent, and
3313         dispatchSimulatedMouseEvent. Added a new dispatchSimulatedClick function here that
3314         mostly replaces the click function in HTMLElement.
3315         * dom/EventTargetNode.cpp:
3316         (WebCore::EventTargetNode::dispatchGenericEvent): Updated for the name change
3317         of cancelBubble.
3318         (WebCore::EventTargetNode::dispatchUIEvent): Added an underlying event parameter,
3319         which gets attached to the UIEvent object after it's created.
3320         (WebCore::EventTargetNode::dispatchMouseEvent): Tweaked formatting and parameter
3321         name for the version that creates a mouse event for a real platform mouse event.
3322         Added an underlying event parameter to the main version, and attached it to all
3323         three of the events that can be dispatched.
3324         (WebCore::EventTargetNode::dispatchSimulatedMouseEvent): Added an underlying
3325         event parameter, passed it along to dispatchMouseEvent.
3326         (WebCore::EventTargetNode::dispatchSimulatedClick): Moved this here from HTMLElement
3327         and renamed it from click. Added an underlyingEvent parameter, and passed that along
3328         in all three of the calls to dispatchSimulatedMouseEvent.
3329
3330         * bridge/mac/FrameMac.mm: (WebCore::FrameMac::shouldClose): Updated call to
3331         setTarget that no longer needs a get().
3332         * ksvg2/svg/SVGElement.cpp: (WebCore::SVGElement::sendSVGLoadEventIfPossible): Ditto.
3333
3334         * html/HTMLAnchorElement.cpp:
3335         (WebCore::HTMLAnchorElement::defaultEventHandler): Converted a call to click
3336         to a call to dispatchSimulatedClick.
3337         (WebCore::HTMLAnchorElement::accessKeyAction): Ditto.
3338         * html/HTMLButtonElement.cpp:
3339         (WebCore::HTMLButtonElement::accessKeyAction): Ditto.
3340         * html/HTMLElement.h: Removed the parameters to click and made it non-virtual.
3341         We could move it down to the input and button elements, now that it's just
3342         a single function call, but it's also OK to just leave it here.
3343         * html/HTMLElement.cpp:
3344         (WebCore::HTMLElement::click): Removed the parameters and changed this to just
3345         call dispatchSimulatedClick. The real work is now in dispatchSimulatedClick.
3346         (WebCore::HTMLElement::accessKeyAction): Converted a call to click to a call to
3347         dispatchSimulatedClick.
3348         * html/HTMLFormElement.cpp:
3349         (WebCore::HTMLFormElement::submitClick): Ditto. But unlike accessKeyAction callers,
3350         pass the event along as the underlying event.
3351         * html/HTMLInputElement.h:
3352         * html/HTMLInputElement.cpp: Removed override of virtual click function. The
3353         special cases for the file control and hidden input elements aren't needed.
3354         (WebCore::HTMLInputElement::accessKeyAction): Converted a call to click to a call to
3355         dispatchSimulatedClick.
3356         (WebCore::HTMLInputElement::defaultEventHandler): Converted calls to click to calls to
3357         dispatchSimulatedClick, passing along the event as the underlying event.
3358         * html/HTMLLabelElement.cpp:
3359         (WebCore::HTMLLabelElement::defaultEventHandler): Converted a call to click to a call
3360         to dispatchSimulatedClick, passing the event along as the underlying event. Also
3361         changed the local variable for the element to a RefPtr since the code assumes it's
3362         still around after calling arbitrary JavaScript code.
3363         * html/HTMLSelectElement.cpp:
3364         (WebCore::HTMLSelectElement::accessKeyAction): Converted a call to click to a call to
3365         dispatchSimulatedClick.
3366
3367         * rendering/RenderFileUploadControl.h:
3368         * rendering/RenderFileUploadControl.cpp: (WebCore::RenderFileUploadControl::click):
3369         Removed unneeded ignored parameter to the click function, and also made it non-virtual.
3370
3371         * loader/NavigationAction.h: Removed unneeded includes.
3372         * loader/NavigationAction.cpp: Moved all the code here from NavigationActionMac.mm,
3373         since none of it is Mac-specific any more.
3374         * loader/mac/NavigationActionMac.mm: Removed.
3375         * WebCore.xcodeproj/project.pbxproj: Updated for removed file.
3376
3377         * ksvg2/svg/SVGAElement.cpp: Removed an unnecessary include.
3378
3379         * loader/FrameLoader.cpp: Added a newly-needed incluude.
3380         * loader/mac/DocumentLoaderMac.mm: Ditto.
3381         * loader/mac/FrameLoaderMac.mm: Ditto.
3382         * rendering/RenderWidget.cpp: Ditto.
3383
3384 2006-12-01  John Sullivan  <sullivan@apple.com>
3385
3386         Reviewed by Darin
3387
3388         - fixed <rdar://problem/4811175> Many false reports of bad grammar appear, caused by 
3389           insufficient context passed to grammar checker
3390
3391         * bridge/mac/FrameMac.mm:
3392         (WebCore::markAllMisspellingsInRange):
3393         new function, extracted from markMisspellings -- ignores grammar
3394         (WebCore::markAllBadGrammarInRange):
3395         new function, extracted from markMisspellings -- ignores spelling, and operates on
3396         appropriately-sized chunks of text
3397         (WebCore::FrameMac::markMisspellings):
3398         now calls markAllMisspellingsInRange and (optionally) markAllBadGrammarInRange rather
3399         than trying to interweave the spelling and grammar logic
3400
3401 2006-12-01  John Sullivan  <sullivan@apple.com>
3402
3403         Reviewed by Darin
3404
3405         With these changes, grammar checking works correctly for the one-by-one case.
3406         It still doesn't work correctly for the check-as-you-type case; I need to make these
3407         same kinds of changes in markMisspellings, and refactor to share more code between
3408         the two cases, but I wanted to get this working code in before modifying it further.
3409
3410         The major change here is that advanceToNextMisspelling used to look at small chunks of
3411         text at a time, checking each one for both misspellings and questionable grammar. But
3412         grammar checking needs at least paragraph-sized chunks of text to have enough context
3413         to work correctly, so the old mechanism was causing many spurious complaints of bad
3414         grammar (e.g., almost every word seemed to be at the start of a sentence so the checker
3415         would complain about missing capitalization). So now the spell checker runs in the
3416         specified range first. Then the grammar checker runs on the same range (stopping at the
3417         next misspelling, if any), but expanded to paragraph-aligned boundaries.
3418
3419         * bridge/mac/FrameMac.mm:
3420         (WebCore::findFirstMisspellingInRange):
3421         new function, extracted from advanceToNextMisspelling, and ignores grammar
3422         (WebCore::paragraphAlignedRangeForRange):
3423         new function, used by findNextBadGrammarInRange
3424         (WebCore::findFirstBadGrammarInRange):
3425         new function, extracted from advanceToNextMisspelling, and rewritten to use paragraph-aligned
3426         chunks, and ignores spelling
3427         (WebCore::subrange):
3428         new helper function, used by advanceToNextMisspelling
3429         (WebCore::FrameMac::advanceToNextMisspelling):
3430         now calls out to both findFirstMisspellingInRange and findFirstBadGrammarInRange separately
3431         instead of trying to interweave the spelling and grammar logic
3432
3433 2006-12-01  Don Gibson  <dgibson77@gmail.com>
3434
3435         Reviewed by Mitz.
3436
3437         http://bugs.webkit.org/show_bug.cgi?id=11732:
3438         Windows build bustage.
3439
3440         * WebCore.vcproj/WebCore/WebCore.vcproj:
3441         * bridge/win/ChromeClientWin.h:
3442         * bridge/win/ContextMenuClientWin.h:
3443         * bridge/win/EditorClientWin.h:
3444         * bridge/win/FrameWin.cpp:
3445         (WebCore::FrameWin::FrameWin):
3446         (WebCore::FrameWin::keyPress):
3447         * bridge/win/FrameWin.h:
3448         * loader/win/FrameLoaderClientWin.h:
3449         * platform/ContextMenu.h:
3450         * platform/Widget.h:
3451         * platform/win/PlatformScrollBar.h:
3452         * platform/win/TemporaryLinkStubs.cpp:
3453         (WebCore::ChromeClientWin::chromeDestroyed):
3454         (WebCore::ChromeClientWin::addMessageToConsole):
3455         (WebCore::ContextMenu::ContextMenu):
3456         (WebCore::ContextMenu::~ContextMenu):
3457         (WebCore::ContextMenu::appendItem):
3458         (WebCore::ContextMenuClientWin::contextMenuDestroyed):
3459         (WebCore::ContextMenuClientWin::contextMenuItemSelected):
3460         (WebCore::ContextMenuItem::~ContextMenuItem):
3461         (WebCore::Editor::newGeneralClipboard):
3462         (WebCore::EditorClientWin::pageDestroyed):
3463         (WebCore::EditorClientWin::smartInsertDeleteEnabled):
3464         (WebCore::EditorClientWin::shouldInsertNode):
3465         (WebCore::FrameLoader::createPlugin):
3466         (WebCore::FrameLoaderClientWin::frameLoaderDestroyed):
3467         (WebCore::FrameLoaderClientWin::hasWebView):
3468         (WebCore::FrameLoaderClientWin::canHandleRequest):
3469         (WebCore::FrameWin::unfocusWindow):
3470         (WebCore::FrameWin::bindingRootObject):
3471         (WebCore::FrameWin::issueCopyCommand):
3472         (WebCore::FrameWin::markMisspellings):
3473         (WebCore::FrameWin::issueTransposeCommand):
3474         (WebCore::FrameWin::markedTextRange):
3475         (WebCore::FrameWin::respondToChangedSelection):
3476         (WebCore::FrameWin::markMisspellingsInAdjacentWords):
3477         (WebCore::FrameWin::isSelectionMisspelled):
3478         (WebCore::FrameWin::guessesForMisspelledSelection):
3479         (WebCore::Pasteboard::generalPasteboard):
3480         (WebCore::Pasteboard::writeSelection):
3481         (WebCore::Pasteboard::clearTypes):
3482         (WebCore::Pasteboard::canSmartReplace):
3483         (WebCore::Pasteboard::documentFragment):
3484         (WebCore::Pasteboard::plainText):
3485         (WebCore::Pasteboard::Pasteboard):
3486         (WebCore::Pasteboard::~Pasteboard):
3487         (WebCore::Pasteboard::registerSelectionPasteboardTypes):
3488         (WebCore::Pasteboard::replaceNBSP):
3489         (WebCore::Pasteboard::createHandle):
3490         (WebCore::Pasteboard::createCF_HTMLFromRange):
3491
3492 2006-11-30  Geoffrey Garen  <ggaren@apple.com>
3493
3494         Rubber Stamped by Anders Carlsson.
3495
3496         Global rename of Document::focusNode to Document::focusedNode. 'focusNode'
3497         suggested a command, and conflicted with a different meaning for 'focusNode'
3498         in the Mozilla selection API.
3499
3500 2006-11-30  John Sullivan  <sullivan@apple.com>
3501
3502         Reviewed by Justin
3503
3504         With Darin, fixed a problem in the Range constructors found while implementing grammar checking.
3505         That revealed another problem in the layout tests involving bad parameters passed to the Range
3506         constructors.
3507         
3508         With these fixes in place, one layout test (editing/execCommand/create-list-from-range-selection.html)
3509         no longer works as intended. This is apparently due to yet another bug being flushed out somewhere.
3510         I'm going to update the results for that test and file a separate radar about it, which Justin will
3511         investigate.
3512
3513         * dom/Position.h:
3514         removed equivalentRangeCompliantPosition(), which was declared but not implemented or called.
3515         
3516         * dom/Range.cpp:
3517         (WebCore::Range::Range):
3518         Call setStart and setEnd in the two Range constructors that take parameters, rather than just 
3519         directly setting the instance variables. This makes Range perform the boundary checks and
3520         compensations that the DOM spec requires.
3521         
3522         * editing/CompositeEditCommand.cpp:
3523         (WebCore::CompositeEditCommand::moveParagraphs):
3524         Use rangeCompliantEquivalent() on "editing-style" Positions before creating Ranges from them.
3525         
3526         * editing/TextIterator.cpp:
3527         (WebCore::TextIterator::TextIterator):
3528         Assert that the boundary points of the range are valid.
3529
3530 2006-11-30  Lou Amadio  <lamadio@apple.com>
3531
3532         Reviewed by Dave Hyatt
3533         Cleaned up generated files.
3534
3535         * html/HTMLElement.cpp:
3536         (WebCore::HTMLElement::isRecognizedTagName):
3537                 Uses the new method for retrieving the list of supported tags
3538         * ksvg2/scripts/make_names.pl:
3539                 Generates tag lists without using macros.
3540
3541 2006-11-30  Adam Roben  <aroben@apple.com>
3542
3543         Reviewed by Beth.
3544
3545         Store ContextMenu's NSMutableArray inside a RetainPtr so that we
3546         will retain/release it correctly.
3547
3548         * WebCore.exp:
3549         * platform/ContextMenu.cpp:
3550         (WebCore::ContextMenu::populate): Added a FIXME.
3551         * platform/ContextMenu.h:
3552         * platform/mac/ContextMenuMac.mm: 
3553         (WebCore::ContextMenu::ContextMenu):
3554         (WebCore::ContextMenu::~ContextMenu):
3555         (WebCore::getNSMenuItem):
3556         (WebCore::ContextMenu::appendItem):
3557         (WebCore::ContextMenu::itemCount):
3558         (WebCore::ContextMenu::insertItem):
3559         (WebCore::ContextMenu::setPlatformDescription):
3560         (WebCore::ContextMenu::platformDescription):
3561
3562 2006-11-30  Nikolas Zimmermann  <zimmermann@kde.org>
3563
3564         Reviewed by Eric. Rubber stamped by Oliver.
3565
3566         Fixes: http://bugs.webkit.org/show_bug.cgi?id=10383
3567      
3568         This is the final patch after the long "die kcanvas" journey.
3569
3570         All old kcanvas code is gone now, and properly integrated within
3571         WebCore (stuff like GraphicsContext changes etc.). It shares
3572         the platform/ design concept: no subclassing, but instead
3573         implementing parts of the classes/methods per-platform.
3574
3575         This commit removes the last pieces: KRenderingDevice & KRenderingDeviceContext.
3576         This layer was just obsolete, given the powerful GraphicsContext API we have
3577         since quite a while now. All the ugly pushContext/popContext stuff is gone now.
3578
3579         LayoutTests affected: svg/W3C-SVG-1.1/pservers-grad-11-b.svg
3580         Radial gradients as fill color for texts, work again!
3581         Though "Gradient on text stroke" remains broken. Funny thing:
3582         With this patch, if you "select" the text using the mouse, as
3583         soon as the selection rectangle is drawn, you see the correct
3584         gradient on stroke rendering - at least a hint where it breaks!
3585
3586         All svg layout tests have subtle text rendering changes - with and without this
3587         patch, it seems it was forgotton to update svg pixel test baseline, a while ago.
3588
3589         * CMakeLists.txt:
3590