WebCore:
[WebKit-https.git] / WebCore / ChangeLog
1 2008-03-04  Darin Adler  <darin@apple.com>
2
3         Reviewed by Adam.
4
5         - remove WebCoreFrameBridge reapplyStyles method
6
7         * WebCore.base.exp: Added exports.
8         * page/mac/WebCoreFrameBridge.h: Removed WebCoreDeviceType and
9         reapplyStylesForDeviceType: method.
10         * page/mac/WebCoreFrameBridge.mm: Ditto.
11
12 2008-03-04  Darin Adler  <darin@apple.com>
13
14         Reviewed by Adam.
15
16         - eliminate WebCoreFrameBridge createFrameViewWithNSView
17
18         * WebCore.base.exp: Added some more exports.
19         * page/mac/WebCoreFrameBridge.h: Deleted createFrameViewWithNSView.
20         * page/mac/WebCoreFrameBridge.mm: Ditto.
21
22 2008-03-04  Darin Adler  <darin@apple.com>
23
24         Reviewed by Adam.
25
26         - removed WebCoreFrameBridge scrollOverflowInDirection
27
28         * WebCore.base.exp: Export function needed by WebKit.
29         * page/mac/WebCoreFrameBridge.h: Removed WebScrollDirection, WebScrollGranularity,
30         and scrollOverflowInDirection.
31         * page/mac/WebCoreFrameBridge.mm: Removed method.
32
33 2008-03-04  Darin Adler  <darin@apple.com>
34
35         Reviewed by Adam.
36
37         - remove WebCoreFrameBridge installInFrame: method
38
39         * WebCore.base.exp: Export a few symbols.
40         * WebCore.xcodeproj/project.pbxproj: Export a few files.
41         * page/mac/WebCoreFrameBridge.h: Remove installInFrame:.
42         * page/mac/WebCoreFrameBridge.mm: Ditto.
43
44 2008-03-04  Darin Adler  <darin@apple.com>
45
46         Reviewed by Adam.
47
48         - remove WebCoreFrameBridge window method
49
50         * page/mac/EventHandlerMac.mm:
51         (WebCore::EventHandler::sendFakeEventsAfterWidgetTracking): Get the window by calling
52         window on the NSView instead of using the bridge. The WebKit side wasn't doing anything
53         special, so a call to -[NSView window] is fine.
54
55         * page/mac/WebCoreFrameBridge.h: Removed the window method.
56
57 2008-03-04  Darin Adler  <darin@apple.com>
58
59         Reviewed by Adam.
60
61         - remove -[WebCoreFrameBridge dashboardRegionsChanged:]
62
63         * WebCore.base.exp: Updated.
64         * page/Chrome.cpp:
65         (WebCore::ChromeClient::dashboardRegionsChanged): Added.
66         * page/ChromeClient.h: Added virtual function for dashboardRegionsChanged.
67         * page/Frame.h: Removed dashboardRegionsChanged function.
68         * page/FrameView.cpp:
69         (WebCore::FrameView::updateDashboardRegions): Changed to call dashboardRegionsChanged
70         on ChromeClient and to only call it when the regions actually changed.
71         * page/mac/FrameMac.mm: Removed dashboardRegionsChanged function.
72         * page/mac/WebCoreFrameBridge.h: Removed dashboardRegionsChanged: method.
73
74 2008-03-04  Darin Adler  <darin@apple.com>
75
76         Reviewed by Adam.
77
78         - remove WebCoreFrameBridge issuePasteComand method
79
80         * editing/Editor.cpp:
81         (WebCore::Editor::paste): Moved the Mac-specific part of this to EditorMac.
82         * editing/mac/EditorMac.mm:
83         (WebCore::Editor::paste): Added. Calls paste: on the document view (normally a
84         WebHTMLView). We should get rid of this eventually.
85         * page/Frame.h: Removed issuePasteCommand.
86         * page/mac/FrameMac.mm: Ditto.
87         * page/mac/WebCoreFrameBridge.h: Ditto.
88
89 2008-03-04  Alexey Proskuryakov  <ap@webkit.org>
90
91         Suggested by Darin, rubber-stamped by Mark.
92
93         http://bugs.webkit.org/show_bug.cgi?id=17569
94         REGRESSION (r30571): Buzzword.com doesn't load
95
96         Rolling out r30571, as determining what is wrong with it proved tricky.
97
98         * loader/FrameLoader.cpp:
99         (WebCore::FrameLoader::load):
100         (WebCore::FrameLoader::tokenizerProcessedData):
101         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
102
103 2008-03-04  Sam Weinig  <sam@webkit.org>
104
105         Build fix.
106
107         * bindings/js/kjs_events.cpp:
108
109 2008-03-03  Sam Weinig  <sam@webkit.org>
110
111         Reviewed by Mark Rowe.
112
113         Move JSClipboard into its own file.
114
115         * DerivedSources.make:
116         * GNUmakefile.am:
117         * WebCore.pro:
118         * WebCore.vcproj/WebCore.vcproj:
119         * WebCore.xcodeproj/project.pbxproj:
120         * WebCoreSources.bkl:
121         * bindings/js/JSAttrCustom.cpp:
122         * bindings/js/JSClipboardCustom.cpp: Added.
123         (WebCore::JSClipboard::types):
124         (WebCore::JSClipboard::clearData):
125         (WebCore::JSClipboard::getData):
126         (WebCore::JSClipboard::setData):
127         (WebCore::JSClipboard::setDragImage):
128         * bindings/js/JSElementCustom.cpp:
129         * bindings/js/JSEventCustom.cpp:
130         * bindings/js/JSHTMLFrameElementCustom.cpp:
131         * bindings/js/JSHTMLIFrameElementCustom.cpp:
132         * bindings/js/kjs_events.cpp:
133         * bindings/js/kjs_events.h:
134         * bindings/js/kjs_window.cpp:
135         * bindings/scripts/CodeGeneratorJS.pm:
136         * dom/Clipboard.cpp:
137         (WebCore::Clipboard::setDropEffect):
138         (WebCore::Clipboard::setEffectAllowed):
139         * dom/Clipboard.idl: Added.
140
141 2008-03-03  Sam Weinig  <sam@webkit.org>
142
143         Windows build-fix.
144
145         * page/Chrome.cpp:
146         * plugins/win/PluginViewWin.cpp:
147
148 2008-03-03  Sam Weinig  <sam@webkit.org>
149
150         Reviewed by Darin Adler.
151
152         Cleanup and plumbing in preparation for the great Window split.
153
154         - Rename KJS::Window to WebCore::JSDOMWindowBase.
155         - Remove KJS::Window::retrieve() and KJS::Window::retrieveWindow() and replace
156           with the new toJSDOMWindow().
157         - Remove KJS::Window::retrieveActive() and replace with explicit call to 
158           exec->dynamicGlobalObject() and toJSDOMWindow().
159
160         * bindings/js/JSCustomVoidCallback.cpp:
161         (WebCore::toVoidCallback):.
162         * bindings/js/JSCustomXPathNSResolver.cpp:
163         (WebCore::JSCustomXPathNSResolver::create):
164         * bindings/js/JSDatabaseCustom.cpp:
165         (WebCore::JSDatabase::changeVersion):
166         (WebCore::JSDatabase::transaction):
167         * bindings/js/JSDocumentCustom.cpp:
168         (WebCore::JSDocument::location):
169         (WebCore::toJS):
170         * bindings/js/JSEventTargetBase.cpp:
171         (WebCore::jsEventTargetAddEventListener):
172         (WebCore::jsEventTargetRemoveEventListener):
173         * bindings/js/JSEventTargetNode.cpp:
174         (WebCore::JSEventTargetNode::setListener):
175         * bindings/js/JSHTMLDocumentCustom.cpp:
176         (WebCore::JSHTMLDocument::nameGetter):
177         (WebCore::JSHTMLDocument::open):
178         * bindings/js/JSHTMLFrameSetElementCustom.cpp:
179         (WebCore::JSHTMLFrameSetElement::nameGetter):
180         * bindings/js/JSLocation.cpp:
181         (WebCore::JSLocation::put):
182         (WebCore::jsLocationProtoFuncReplace):
183         (WebCore::jsLocationProtoFuncReload):
184         (WebCore::jsLocationProtoFuncAssign):
185         * bindings/js/JSLocation.h:
186         * bindings/js/JSSQLTransactionCustom.cpp:
187         (WebCore::JSSQLTransaction::executeSql):
188         * bindings/js/JSSVGLazyEventListener.cpp:
189         (WebCore::JSSVGLazyEventListener::JSSVGLazyEventListener):
190         (WebCore::JSSVGLazyEventListener::eventParameterName):
191         * bindings/js/JSSVGLazyEventListener.h:
192         * bindings/js/JSXMLHttpRequest.cpp:
193         (WebCore::JSXMLHttpRequest::putValueProperty):
194         (WebCore::jsXMLHttpRequestPrototypeFunctionOpen):
195         (WebCore::jsXMLHttpRequestPrototypeFunctionAddEventListener):
196         (WebCore::jsXMLHttpRequestPrototypeFunctionRemoveEventListener):
197         * bindings/js/ScheduledAction.cpp:
198         (WebCore::ScheduledAction::execute):
199         * bindings/js/ScheduledAction.h:
200         * bindings/js/kjs_binding.cpp:
201         (WebCore::allowsAccessFromFrame):
202         (WebCore::printErrorMessageForFrame):
203         * bindings/js/kjs_events.cpp:
204         (WebCore::JSAbstractEventListener::handleEvent):
205         (WebCore::JSUnprotectedEventListener::JSUnprotectedEventListener):
206         (WebCore::JSUnprotectedEventListener::~JSUnprotectedEventListener):
207         (WebCore::JSUnprotectedEventListener::windowObj):
208         (WebCore::JSEventListener::JSEventListener):
209         (WebCore::JSEventListener::~JSEventListener):
210         (WebCore::JSEventListener::windowObj):
211         (WebCore::JSLazyEventListener::JSLazyEventListener):
212         (WebCore::JSLazyEventListener::parseCode):
213         * bindings/js/kjs_events.h:
214         * bindings/js/kjs_navigator.cpp:
215         (WebCore::MimeType::getValueProperty):
216         * bindings/js/kjs_proxy.cpp:
217         (WebCore::KJSProxy::evaluate):
218         (WebCore::KJSProxy::createHTMLEventHandler):
219         (WebCore::KJSProxy::createSVGEventHandler):
220         * bindings/js/kjs_window.cpp:
221         (WebCore::JSDOMWindowBasePrivate::JSDOMWindowBasePrivate):
222         (WebCore::DOMWindowTimer::DOMWindowTimer):
223         (WebCore::DOMWindowTimer::action):
224         (WebCore::DOMWindowTimer::takeAction):
225         (WebCore::):
226         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
227         (WebCore::JSDOMWindowBase::~JSDOMWindowBase):
228         (WebCore::JSDOMWindowBase::location):
229         (WebCore::JSDOMWindowBase::mark):
230         (WebCore::allowPopUp):
231         (WebCore::createWindow):
232         (WebCore::showModalDialog):
233         (WebCore::JSDOMWindowBase::getValueProperty):
234         (WebCore::JSDOMWindowBase::childFrameGetter):
235         (WebCore::JSDOMWindowBase::indexGetter):
236         (WebCore::JSDOMWindowBase::namedItemGetter):
237         (WebCore::JSDOMWindowBase::getOwnPropertySlot):
238         (WebCore::JSDOMWindowBase::put):
239         (WebCore::JSDOMWindowBase::allowsAccessFrom):
240         (WebCore::JSDOMWindowBase::allowsAccessFromNoErrorMessage):
241         (WebCore::JSDOMWindowBase::allowsAccessFromPrivate):
242         (WebCore::JSDOMWindowBase::crossDomainAccessErrorMessage):
243         (WebCore::JSDOMWindowBase::printErrorMessage):
244         (WebCore::JSDOMWindowBase::globalExec):
245         (WebCore::JSDOMWindowBase::shouldInterruptScript):
246         (WebCore::JSDOMWindowBase::setListener):
247         (WebCore::JSDOMWindowBase::getListener):
248         (WebCore::JSDOMWindowBase::findJSEventListener):
249         (WebCore::JSDOMWindowBase::findOrCreateJSEventListener):
250         (WebCore::JSDOMWindowBase::findJSUnprotectedEventListener):
251         (WebCore::JSDOMWindowBase::findOrCreateJSUnprotectedEventListener):
252         (WebCore::JSDOMWindowBase::clearHelperObjectProperties):
253         (WebCore::JSDOMWindowBase::clear):
254         (WebCore::JSDOMWindowBase::setCurrentEvent):
255         (WebCore::JSDOMWindowBase::currentEvent):
256         (WebCore::windowProtoFuncAToB):
257         (WebCore::windowProtoFuncBToA):
258         (WebCore::windowProtoFuncOpen):
259         (WebCore::windowProtoFuncSetTimeout):
260         (WebCore::windowProtoFuncClearTimeout):
261         (WebCore::windowProtoFuncSetInterval):
262         (WebCore::windowProtoFuncAddEventListener):
263         (WebCore::windowProtoFuncRemoveEventListener):
264         (WebCore::windowProtoFuncShowModalDialog):
265         (WebCore::windowProtoFuncNotImplemented):
266         (WebCore::JSDOMWindowBase::setReturnValueSlot):
267         (WebCore::JSDOMWindowBase::clearAllTimeouts):
268         (WebCore::JSDOMWindowBase::installTimeout):
269         (WebCore::JSDOMWindowBase::pauseTimeouts):
270         (WebCore::JSDOMWindowBase::resumeTimeouts):
271         (WebCore::JSDOMWindowBase::clearTimeout):
272         (WebCore::JSDOMWindowBase::timerFired):
273         (WebCore::JSDOMWindowBase::disconnectFrame):
274         (WebCore::JSDOMWindowBase::jsEventListeners):
275         (WebCore::JSDOMWindowBase::jsHTMLEventListeners):
276         (WebCore::JSDOMWindowBase::jsUnprotectedEventListeners):
277         (WebCore::JSDOMWindowBase::jsUnprotectedHTMLEventListeners):
278         (WebCore::toJS):
279         (WebCore::toJSDOMWindow):
280         (WebCore::toJSDOMWindow):
281         * bindings/js/kjs_window.h:
282         (WebCore::JSDOMWindowBase::impl):
283         (WebCore::JSDOMWindowBase::classInfo):
284         (WebCore::JSDOMWindowBase::):
285         * bindings/objc/DOMUtility.mm:
286         (KJS::createDOMWrapper):
287         * bindings/scripts/CodeGeneratorJS.pm:
288         * history/CachedPage.cpp:
289         (WebCore::CachedPage::CachedPage):
290         (WebCore::CachedPage::restore):
291         * page/Chrome.cpp:
292         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
293         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
294         * page/DOMWindow.idl:
295         * page/Frame.cpp:
296         (WebCore::Frame::~Frame):
297         (WebCore::Frame::windowScriptNPObject):
298         (WebCore::Frame::pageDestroyed):
299         * page/InspectorController.cpp:
300         (WebCore::inspectedWindow):
301         * page/mac/FrameMac.mm:
302         (WebCore::Frame::windowScriptObject):
303         * page/mac/WebCoreFrameBridge.mm:
304         (updateRenderingForBindings):
305         * platform/SecurityOrigin.cpp:
306         (WebCore::SecurityOrigin::canAccess):
307
308 2008-03-03  Kevin Ollivier  <kevino@theolliviers.com>
309
310         wx build fixes after recent Frame-related changes.
311
312         * platform/wx/PasteboardWx.cpp:
313         * platform/wx/TemporaryLinkStubs.cpp:
314
315 2008-03-03  Dan Bernstein  <mitz@apple.com>
316
317         Reviewed by Darin Adler.
318
319         - make :first-letter apply to the first letter in normal flow, skipping
320           floats and positioned objects
321
322         Test: fast/css/first-letter-skip-out-of-flow.html
323
324         * rendering/RenderBlock.cpp:
325         (WebCore::RenderBlock::updateFirstLetter):
326
327 2008-03-03  Ada Chan  <adachan@apple.com>
328
329         Fix build.
330
331         * plugins/win/PluginViewWin.cpp:
332
333 2008-03-03  Mark Rowe  <mrowe@apple.com>
334
335         Reviewed by Dan Bernstein.
336
337         Fix http://bugs.webkit.org/show_bug.cgi?id=17313
338         Bug 17313: querySelectorAll() causing crashes when called via dojo.query() wrapper
339
340         Node::querySelector and SelectorNodeList were not sufficiently initializing the CSSStyleSelector
341         before using it to resolve styles, which lead to it having a stale m_style member in some situations.
342         This stale m_style member resulted in a wild store that would write over whatever object now resided
343         at the location m_style pointed to.
344
345         Test: fast/dom/SelectorAPI/bug-17313.html
346
347         * dom/Node.cpp:
348         (WebCore::Node::querySelector): Call initForStyleResolve to further initialize the CSSStyleSelector.
349         * dom/SelectorNodeList.cpp:
350         (WebCore::SelectorNodeList::SelectorNodeList): Ditto.
351
352 2008-03-03  Anders Carlsson  <andersca@apple.com>
353
354         Reviewed by Darin and Sam.
355
356         Include fixes, in preparation of using the headers in WebCore/bridge.
357         
358         * bindings/js/kjs_binding.h:
359         * bindings/js/kjs_dom.cpp:
360         * bindings/objc/DOMInternal.mm:
361         * bindings/objc/DOMUtility.mm:
362         * bindings/objc/WebScriptObject.mm:
363         * bindings/objc/WebScriptObjectPrivate.h:
364         * bridge/objc/objc_class.h:
365         * bridge/objc/objc_instance.h:
366         * bridge/objc/objc_runtime.h:
367         * bridge/objc/objc_utility.h:
368         * bridge/runtime.h:
369         * bridge/runtime_object.h:
370         * bridge/runtime_root.h:
371         * html/HTMLAppletElement.cpp:
372         * html/HTMLAppletElement.h:
373         * html/HTMLEmbedElement.cpp:
374         * html/HTMLEmbedElement.h:
375         * html/HTMLObjectElement.cpp:
376         * html/HTMLPlugInElement.cpp:
377         * html/HTMLPlugInElement.h:
378         * page/mac/FrameMac.mm:
379         * page/mac/WebCoreFrameBridge.h:
380         * page/mac/WebCoreFrameBridge.mm:
381         * page/mac/WebCoreScriptDebugger.mm:
382
383 2008-03-03  David Hyatt  <hyatt@apple.com>
384
385         Full page zoom plumbing.  Add a notion of whether or not a zoom is text only or a full zoom to the
386         Frame.  setTextSizeMultiplier does a text only zoom.
387
388         Reviewed by Tim H.
389
390         * page/Frame.cpp:
391         (WebCore::Frame::zoomFactor):
392         (WebCore::Frame::isZoomFactorTextOnly):
393         (WebCore::Frame::setZoomFactor):
394         (WebCore::FramePrivate::FramePrivate):
395         * page/Frame.h:
396         * page/FramePrivate.h:
397         * page/mac/WebCoreFrameBridge.mm:
398         (-[WebCoreFrameBridge setTextSizeMultiplier:]):
399         * svg/SVGSVGElement.cpp:
400         (WebCore::SVGSVGElement::setCurrentScale):
401
402 2008-03-03  David Hyatt  <hyatt@apple.com>
403
404         Fix for <rdar://problem/5776161> REGRESSION: Google Docs Spreadsheet crash
405
406         This is also http://bugs.webkit.org/show_bug.cgi?id=17543, fixed table layout corrupts heap.
407
408         Make sure not to access position -1 of the size 0 vectors.
409
410         Reviewed by ggaren
411
412         * rendering/FixedTableLayout.cpp:
413         (WebCore::FixedTableLayout::layout):
414
415 2008-03-03  David D. Kilzer  <ddkilzer@webkit.org>
416
417         Dynamically inserting CSS rule with @media query fails with DOM Exception 12
418         <http://bugs.webkit.org/show_bug.cgi?id=15986>
419
420         Reviewed by Darin.
421
422         Allow any valid rule (@font-face, @import, @media, @page or style) to be
423         parsed when using CSSStyleSheet.insertRule().  Previously only import and
424         style rules were allowed.  Note that @page rules always throw an exception
425         because they're not implemented yet, so no test case was added for them.
426
427         Tests: fast/css/insertRule-font-face.html
428                fast/css/insertRule-media.html
429
430         * css/CSSGrammar.y: Extracted 'valid_rule' out of 'rule'.  Renamed
431         'ruleset_or_import' to 'valid_rule_or_import' and changed its definition.
432
433 2008-03-03  Anders Carlsson  <andersca@apple.com>
434
435         Reviewed by Sam.
436
437         Copy JSC bindings directory over to WebCore/bridge.
438
439         * bridge: Copied from ../JavaScriptCore/bindings.
440
441 2008-03-03  Dan Bernstein  <mitz@apple.com>
442
443         Reviewed by Darin Adler.
444
445         - remove CSSMutableStyleDeclaration::setChanged()'s change type
446           parameter
447
448         * css/CSSMutableStyleDeclaration.cpp:
449         (WebCore::CSSMutableStyleDeclaration::setChanged): Removed the change
450         type parameter and made this function determine the correct change type
451         based on whether this is an inline style declaration.
452         (WebCore::CSSMutableStyleDeclaration::setProperty):
453         * css/CSSMutableStyleDeclaration.h:
454         (WebCore::CSSMutableStyleDeclaration::clear): Removed this unused
455         method.
456         (WebCore::CSSMutableStyleDeclaration::setChanged): Made private.
457
458 2008-03-03  Darin Adler  <darin@apple.com>
459
460         Reviewed by Adam.
461
462         - some "cleanup" on the path to removing WebCoreFrameBridge
463
464         * WebCore.base.exp: Exported some stuff we either already use or
465         I am about to use in an upcoming patch.
466
467         * WebCore.xcodeproj/project.pbxproj: Made FileChooser.h private rather
468         than project, for future use in WebKit.
469
470         * bindings/objc/WebScriptObject.mm: Removed some dead code.
471
472         * dom/ContainerNode.cpp: Added a now-needed or soon-to-be-needed include.
473         * editing/Editor.cpp: Ditto.
474
475         * editing/Editor.h: Removed many unneeded declarations and includes.
476         Removed the unused userVisibleString function.
477
478         * editing/EditorCommand.cpp:
479         (WebCore::executeYank): Added parameter for triggeringEvent, which no
480         longer has a default value.
481         (WebCore::executeYankAndSelect): Ditto.
482
483         * editing/mac/EditorMac.mm: Removed userVisibleString.
484
485         * page/mac/EventHandlerMac.mm:
486         (WebCore::isKeyboardOptionTab): Tweaked formattin.
487
488         * page/mac/WebCoreFrameBridge.mm:
489         (-[WebCoreFrameBridge dragSourceMovedTo:]): Get window from -[NSView window]
490         rather than from the bridge. There's no special value in the bridge's window
491         method and we can use NSView directly.
492         (-[WebCoreFrameBridge dragSourceEndedAt:operation:]): Ditto.
493
494         * platform/graphics/mac/ImageMac.mm:
495         (WebCore::Image::loadPlatformResource): Use a new WebCoreBundleFinder class to
496         find the bundle rather than using WebCoreFrameBridge.
497
498         * platform/mac/ClipboardMac.mm: Added a now-needed or soon-to-be-needed include.
499         * platform/mac/PasteboardMac.mm: Ditto.
500
501         * rendering/RenderObject.h:
502         (WebCore::DashboardRegionValue::operator==): Fixed mistake where this wasn't
503         comparing the clip rectangle.
504         (WebCore::DashboardRegionValue::operator!=): Added. Needed by my future work.
505
506 2008-03-03  Oliver Hunt  <oliver@apple.com>
507
508         Reviewed by Mark Rowe.
509
510         Bug 17620: getImageData lies
511         http://bugs.webkit.org/show_bug.cgi?id=17620
512
513         Correct logic to actually iterate over the source row
514
515         * platform/graphics/cg/ImageBufferCG.cpp:
516         (WebCore::ImageBuffer::getImageData):
517
518 2008-03-03  Oliver Hunt  <oliver@apple.com>
519
520         Reviewed by Mark Rowe.
521
522         Correct incorrect assertion
523
524         * platform/graphics/cg/ImageBufferCG.cpp:
525         (WebCore::ImageBuffer::putImageData):
526
527 2008-03-02  Alp Toker  <alp@atoker.com>
528
529         Another fix for non-database builds after changes in r30331.
530
531         Conditionalize a stopDatabases() call.
532
533         * loader/FrameLoader.cpp:
534         (WebCore::FrameLoader::stopLoading):
535
536 2008-03-02  Kevin Ollivier  <kevino@theolliviers.com>
537
538         Reviewed by Alp Toker.
539
540         Scrolling fixes. Implement page scrolling, initialize mouse wheel
541         event variables, and remove duplicate event binding for TOP
542         scrolling event.
543
544         http://bugs.webkit.org/show_bug.cgi?id=17643
545
546         * platform/wx/MouseWheelEventWx.cpp:
547         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
548         * platform/wx/ScrollViewWx.cpp:
549         (WebCore::ScrollView::ScrollViewPrivate::bindEvents):
550         (WebCore::ScrollView::ScrollViewPrivate::OnScrollWinEvents):
551
552 2008-03-02  Alp Toker  <alp@atoker.com>
553
554         Fix building without database support after changes in r30331.
555
556         * dom/Document.cpp:
557
558 2008-03-02  Kevin Ollivier  <kevino@theolliviers.com>
559
560         wx build fix for Windows after PageWin.cpp move.
561
562         * webcore-wx.bkl:
563
564 2008-03-02  Kevin Ollivier  <kevino@theolliviers.com>
565
566         Reviewed by Dave Hyatt.
567
568         Gracefully handle a CSS rule containing an invalid value.
569         (Fixes http://bugs.webkit.org/show_bug.cgi?id=16898)
570
571         * css/CSSGrammar.y:
572
573 2008-03-02  Alp Toker  <alp@atoker.com>
574
575         Reviewed by Mark Rowe.
576
577         Improve the Cairo Path::isEmpty() function
578
579         Use cairo_has_current_point() where available.
580
581         * platform/graphics/cairo/PathCairo.cpp:
582         (WebCore::Path::isEmpty):
583
584 2008-03-01  Mark Rowe  <mrowe@apple.com>
585
586         Reviewed by Tim Hatcher.
587
588         Update Xcode configuration to support building debug and release from the mysterious future.
589
590         * Configurations/DebugRelease.xcconfig:
591
592 2008-03-01  Oliver Hunt  <oliver@apple.com>
593
594         Reviewed by Sam Weinig.
595
596         Bug 16954: Support putImageData
597         
598         Implement support for HTML5's putImageData for the CG port.  All other ports
599         are currently just using stubs for the final blit.
600
601         Test: fast/canvas/canvas-putImageData.html
602
603         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
604         (WebCore::JSCanvasRenderingContext2D::putImageData):
605         * html/CanvasRenderingContext2D.cpp:
606         (WebCore::CanvasRenderingContext2D::putImageData):
607         * html/CanvasRenderingContext2D.h:
608         * platform/graphics/ImageBuffer.h:
609         * platform/graphics/cairo/ImageBufferCairo.cpp:
610         * platform/graphics/cg/ImageBufferCG.cpp:
611         (WebCore::ImageBuffer::putImageData):
612         * platform/graphics/qt/ImageBufferQt.cpp:
613         * platform/graphics/wx/ImageBufferWx.cpp:
614
615 2008-03-01  Jon Honeycutt  <jhoneycutt@apple.com>
616
617         Reviewed by Darin.
618
619         <rdar://problem/5772987> Crashing viewing page with two VLC plug-in
620         instances
621
622         The VLC Netscape plug-in crashes if more than one instance is created.
623
624         Added a quirk that disallows a plug-in from having more than one
625         instance and set this for the VLC plug-in.
626
627         In addition, we now sort plug-ins that handle the same MIME
628         type to choose the most appropriate one. This sorting first sorts by
629         whether a plug-in has an issue that should put it at the end of the
630         list, then whether it appears in a "preferred" plug-in directory.
631
632         * plugins/PluginQuirkSet.h: Added PluginQuirkDontAllowMultipleInstances.
633         * plugins/PluginDatabase.cpp:
634         (WebCore::PluginDatabase::preferredPluginCompare): Comparator for
635         sorting plug-ins; calls PluginPackage::compare().
636         (WebCore::PluginDatabase::pluginForMIMEType): Add all of the plug-ins
637         that handle this MIME type to a list, sort the list, and return the
638         first item.
639         (WebCore::PluginDatabase::MIMETypeForExtension): Add all of the plug-ins
640         that handle this extension to a list, sort the list, and return the MIME
641         type used by the plug-in at the beginning of the list.
642         * plugins/PluginDatabase.h:
643         * plugins/PluginPackage.h:
644         (WebCore::PluginPackage::version): Added; returns the module version.
645         * plugins/win/PluginDatabaseWin.cpp:
646         (WebCore::PluginDatabase::isPreferredPluginPath): Made static; removed
647         const.
648         * plugins/win/PluginPackageWin.cpp:
649         (WebCore::PluginPackage::compare): Sorts plug-ins with known issues to
650         the end, then plug-ins in preferred directories to the beginning, then
651         alphabetically by file name, numerically by version, and alphabetically
652         by parent directory.
653         (WebCore::PluginPackage::determineQuirks): Set the "don't allow multiple
654         instances" quirk for VLC.
655         (WebCore::PluginPackage::load): Return false if the plug-in library has
656         already been loaded and the "don't allow multiple instances" quirk is
657         set.
658         * platform/gtk/TemporaryLinkStubs.cpp:
659         (PluginPackage::compare): Added stub.
660         (PluginDatabase::IsPreferredPluginPath): Update the GTK stub.
661         * platform/qt/TemporaryLinkStubs.cpp:
662         (PluginPackage::compare): Added stub.
663         (PluginDatabase::IsPreferredPluginPath): Update the Qt stub.
664         * platform/wx/TemporaryLinkStubs.cpp:
665         (PluginPackage::compare): Added stub.
666         (PluginDatabase::IsPreferredPluginPath): Update the wx stub.
667
668 2008-03-01  Sam Weinig  <sam@webkit.org>
669
670         Rubber-stamped by Mark Rowe.
671
672         Remove reference to the now non-existent bridge directory.
673
674         * WebCore.xcodeproj/project.pbxproj:
675
676 2008-03-01  Sam Weinig  <sam@webkit.org>
677
678         Reviewed by Darin Adler.
679
680         Search the entire prototype chain when doing early prototype lookup in
681         the Window's getOwnPropertySlot method.
682
683         Makes fast/dom/Window/window-function-name-getter-precedence.html pass all tests.
684
685         * bindings/js/kjs_window.cpp:
686         (KJS::Window::getOwnPropertySlot):
687
688 2008-03-01  Nikolas Zimmermann  <zimmermann@kde.org>
689
690         Reviewed by Oliver.
691
692         Fixes: http://bugs.webkit.org/show_bug.cgi?id=17568 (SVGForeignObjectElement can't react to width/height SVG DOM changes)
693
694         As the bug title says, fix all dynamic update problems that occour with SVGForeignObjectElement.
695
696         Tests: svg/dynamic-updates/SVGForeignObjectElement-dom-height-attr.html
697                svg/dynamic-updates/SVGForeignObjectElement-dom-width-attr.html
698                svg/dynamic-updates/SVGForeignObjectElement-dom-x-attr.html
699                svg/dynamic-updates/SVGForeignObjectElement-dom-y-attr.html
700                svg/dynamic-updates/SVGForeignObjectElement-svgdom-height-prop.html
701                svg/dynamic-updates/SVGForeignObjectElement-svgdom-width-prop.html
702                svg/dynamic-updates/SVGForeignObjectElement-svgdom-x-prop.html
703                svg/dynamic-updates/SVGForeignObjectElement-svgdom-y-prop.html
704
705         * svg/SVGForeignObjectElement.cpp:
706         (WebCore::SVGForeignObjectElement::parseMappedAttribute):
707         (WebCore::addCSSPropertyAndNotifyAttributeMap):
708         (WebCore::SVGForeignObjectElement::svgAttributeChanged):
709         * svg/SVGForeignObjectElement.h:
710
711 2008-02-29  Brady Eidson  <beidson@apple.com>
712
713         Reviewed by build-fix karma
714
715         Bonehead mistake.  Revert function to previous version for all non-Windows+CFNetwork platforms
716
717         * platform/network/ProtectionSpace.cpp:
718         (WebCore::ProtectionSpace::receivesCredentialSecurely): Make my previous change conditionally
719
720 2008-02-29  Brady Eidson  <beidson@apple.com>
721
722         Reviewed by Darin
723         
724         <rdar://problem/5771227> - Incorrect password handling text in credential sheet
725
726         * platform/network/ProtectionSpace.cpp:
727         (WebCore::ProtectionSpace::receivesCredentialSecurely): Call functional CFNetwork method to
728           get "secureness" of the auth challenge instead of figuring it out ourselves
729
730 2008-02-29  Brent Fulgham  <bfulgham@gmail.com>
731
732         http://bugs.webkit.org/show_bug.cgi?id=17483
733         Implement scrollbars on Windows (Cairo)
734
735         Reviewed by Adam Roben.
736
737         * platform/win/PlatfromScrollBarWin.cpp: Duplicate implementation
738           from PlatformScrollBarWinSafari.cpp, then modify to use the
739           native Windows theme engine.  Use SOFT_LINK.  Use platform
740           'GetSystemMetrics' call to decide size of scrollbars and buttons.
741
742 2008-02-29  Adam Roben  <aroben@apple.com>
743
744         Windows build fix
745
746         * WebCore.vcproj/WebCore.vcproj: Remove bridge/* from the include path
747         and the post-build event, and add page/win to each. Also let VS have
748         its way with the order of the files.
749         * page/win/PageWin.cpp: Copied from bridge/win/PageWin.cpp in r30673
750         * page/win/GlobalHistoryWin.cpp: Copied from
751         bridge/win/GlobalHistoryWin.cpp in r30673
752
753 2008-02-29  Anders Carlsson  <andersca@apple.com>
754
755         Build fix.
756
757         * WebCore.xcodeproj/project.pbxproj:
758
759 2008-02-29  Mark Rowe  <mrowe@apple.com>
760
761         Reviewed by Tim Hatcher.
762
763         64-bit build fix.
764
765         * platform/graphics/mac/SimpleFontDataMac.mm:
766         (WebCore::pathFromFont): Provide stub implementation of pathFromFont for 64-bit as
767         FMGetATSFontRefFromFont is not available.
768
769 2008-02-29  Mark Rowe  <mrowe@apple.com>
770
771         Build fix.  Only declare pathFromFont in debug builds as it is unused in release builds.
772
773         * platform/graphics/mac/SimpleFontDataMac.mm:
774
775 2008-02-29  Anders Carlsson  <andersca@apple.com>
776
777         Reviewed by Adam.
778         
779         Copy the remaining files in bridge/ over to page/
780
781         * WebCore.vcproj/WebCore.vcproj:
782         * WebCore.xcodeproj/project.pbxproj:
783         * bridge: Removed.
784         * bridge/AXObjectCache.h: Removed.
785         * bridge/EditorClient.h: Removed.
786         * bridge/GlobalHistory.h: Removed.
787         * bridge/win: Removed.
788         * bridge/win/FrameCGWin.cpp: Removed.
789         * bridge/win/FrameCairoWin.cpp: Removed.
790         * bridge/win/FrameWin.cpp: Removed.
791         * bridge/win/FrameWin.h: Removed.
792         * bridge/win/GlobalHistoryWin.cpp: Removed.
793         * bridge/win/PageWin.cpp: Removed.
794         * page/AXObjectCache.h: Copied from bridge/AXObjectCache.h.
795         * page/EditorClient.h: Copied from bridge/EditorClient.h.
796         * page/GlobalHistory.h: Copied from bridge/GlobalHistory.h.
797         * page/win/FrameCGWin.cpp: Copied from bridge/win/FrameCGWin.cpp.
798         * page/win/FrameCairoWin.cpp: Copied from bridge/win/FrameCairoWin.cpp.
799         * page/win/FrameWin.cpp: Copied from bridge/win/FrameWin.cpp.
800         * page/win/FrameWin.h: Copied from bridge/win/FrameWin.h.
801
802 2008-02-29  Robert Blaut  <webkit@blaut.biz>
803
804         Reviewed by Darin Adler.
805
806         - fix http://bugs.webkit.org/show_bug.cgi?id=17532
807           Webkit imports styles from <link> element which doesn't have rel=stylesheet defined
808
809         Test: fast/html/link-rel-stylesheet.html
810
811         * html/HTMLLinkElement.cpp:
812         (WebCore::HTMLLinkElement::process):
813
814 2008-02-29  Mark Rowe  <mrowe@apple.com>
815
816         Reviewed by Anders Carlsson.
817
818         Replace use of WKPathFromFont with implementation in terms of public API.
819
820         * WebCore.base.exp: Remove unused symbol.
821         * platform/graphics/mac/SimpleFontDataMac.mm:
822         (WebCore::initFontData):
823         (WebCore::pathFromFont): Implement pathFromFont in terms of public API.
824         (WebCore::SimpleFontData::platformInit):
825         * platform/mac/WebCoreSystemInterface.h: Remove unused symbol.
826         * platform/mac/WebCoreSystemInterface.mm: Ditto.
827
828 2008-02-29  Anders Carlsson  <andersca@apple.com>
829
830         Reviewed by Adam.
831
832         Move a bunch of files from bridge/mac to page/mac.
833         
834         * WebCore.xcodeproj/project.pbxproj:
835         * bridge/mac: Removed.
836         * bridge/mac/AXObjectCacheMac.mm: Removed.
837         * bridge/mac/GlobalHistoryMac.mm: Removed.
838         * bridge/mac/WebCoreAXObject.h: Removed.
839         * bridge/mac/WebCoreAXObject.mm: Removed.
840         * bridge/mac/WebCoreScriptDebugger.h: Removed.
841         * bridge/mac/WebCoreScriptDebugger.mm: Removed.
842         * page/mac/AXObjectCacheMac.mm: Copied from bridge/mac/AXObjectCacheMac.mm.
843         * page/mac/GlobalHistoryMac.mm: Copied from bridge/mac/GlobalHistoryMac.mm.
844         * page/mac/WebCoreAXObject.h: Copied from bridge/mac/WebCoreAXObject.h.
845         * page/mac/WebCoreAXObject.mm: Copied from bridge/mac/WebCoreAXObject.mm.
846         * page/mac/WebCoreScriptDebugger.h: Copied from bridge/mac/WebCoreScriptDebugger.h.
847         * page/mac/WebCoreScriptDebugger.mm: Copied from bridge/mac/WebCoreScriptDebugger.mm.
848
849 2008-02-29  David Hyatt  <hyatt@apple.com>
850
851         Fix for http://bugs.webkit.org/show_bug.cgi?id=17559, media query tests crashing under
852         guard malloc.  Pass along the style selector so it can be accessed, since it has not yet
853         been assigned into the document's member variable.
854
855         Reviewed by aroben
856
857         * css/CSSStyleSelector.cpp:
858         (WebCore::CSSRuleSet::addRulesFromSheet):
859         * css/MediaQueryEvaluator.cpp:
860         (WebCore::MediaQueryEvaluator::eval):
861         * css/MediaQueryEvaluator.h:
862
863 2008-02-29  David Hyatt  <hyatt@apple.com>
864
865         <rdar://problem/5755916> REGRESSION: Loading HTML5 spec is 5x slower on TOT than in 3.0.4
866
867         Improve the performance of dynamic sibling and CSS3 selectors so that there is no slowdown any more.
868         Be more precise in terms of what nodes we mark dirty.
869
870         Reviewed by Beth
871
872         * css/CSSStyleSelector.cpp:
873         (WebCore::CSSStyleSelector::checkSelector):
874         * dom/Element.cpp:
875         (WebCore::Element::recalcStyle):
876         (WebCore::checkForSiblingStyleChanges):
877         (WebCore::Element::childrenChanged):
878         (WebCore::Element::finishParsingChildren):
879         * rendering/RenderStyle.cpp:
880         (WebCore::RenderStyle::RenderStyle):
881         * rendering/RenderStyle.h:
882         (WebCore::RenderStyle::childrenAffectedByPositionalRules):
883         (WebCore::RenderStyle::childrenAffectedByDirectAdjacentRules):
884         (WebCore::RenderStyle::setChildrenAffectedByDirectAdjacentRules):
885
886 2008-02-29  Alexey Proskuryakov  <ap@webkit.org>
887
888         Reviewed by Darin.
889
890         <rdar://problem/5766352> REGRESSION (r27151): XMLHttpRequest.abort() resets response status
891
892         Test: http/tests/xmlhttprequest/status-after-abort.html
893
894         * xml/XMLHttpRequest.cpp:
895         (WebCore::XMLHttpRequest::getStatus):
896         (WebCore::XMLHttpRequest::getStatusText):
897         Changed to match Firefox more closely (IE just raises an exception in most of those cases).
898
899 2008-02-29  Dan Bernstein  <mitz@apple.com>
900
901         Reviewed by Darin Adler.
902
903         - fix a bug where explicit embedding past the end of a line could
904           affect text that line
905
906         Test: fast/text/embed-at-end-of-pre-wrap-line.html
907
908         * rendering/bidi.cpp:
909         (WebCore::RenderBlock::skipWhitespace): Removed calls to
910         setAdjustEmbedding().
911         (WebCore::RenderBlock::findNextLineBreak): Added calls to
912         setAdjustEmbedding() around skipWhitespace() only where needed.
913
914 2008-02-29  Mark Rowe  <mrowe@apple.com>
915
916         Reviewed by Oliver Hunt.
917
918         Don't use WKSupportsMultipartXMixedReplace on Leopard as multipart/x-mixed-replace is always handled by NSURLRequest.
919
920         * platform/mac/WebCoreSystemInterface.h: Don't declare WKSupportsMultipartXMixedReplace on Leopard.
921         * platform/mac/WebCoreSystemInterface.mm: Ditto.
922         * platform/network/mac/ResourceRequestMac.mm:
923         (WebCore::ResourceRequest::doUpdatePlatformRequest): Don't call WKSupportsMultipartXMixedReplace on Leopard.
924         * WebCore.Tiger.exp: Move Tiger-only symbol here.
925         * WebCore.base.exp:
926
927 2008-02-29  Mark Rowe  <mrowe@apple.com>
928
929         Rubber-stamped by Eric Seidel.
930
931         Remove unneeded includes of WebCoreSystemInterface.h.
932
933         * loader/mac/LoaderNSURLExtras.m:
934         * page/mac/FrameMac.mm:
935         * page/mac/WebCoreFrameBridge.mm:
936         * platform/MIMETypeRegistry.cpp:
937         * platform/graphics/mac/ImageMac.mm:
938         * platform/mac/PasteboardMac.mm:
939
940 2008-02-29  Mark Rowe  <mrowe@apple.com>
941
942         Reviewed by Oliver Hunt and Oliver Hunt.
943
944         <rdar://problem/4753845> WebKit should use CGEventSourceSecondsSinceLastEventType in place of WKSecondsSinceLastInputEvent SPI.
945
946         * platform/mac/SystemTimeMac.cpp:  Replace use of WKSecondsSinceLastInputEvent with CGEventSourceSecondsSinceLastEventType.
947         * platform/mac/WebCoreSystemInterface.h:  Remove unused symbol.
948         * platform/mac/WebCoreSystemInterface.mm:  Ditto.
949         * WebCore.base.exp:  Ditto.
950
951 2008-02-28  Mark Rowe  <mrowe@apple.com>
952
953         Reviewed by Dave Hyatt.
954
955         Make use of new CGFont APIs on Leopard rather than making a WebKitSystemInterface call.
956
957         * DerivedSources.make:  Add Tiger-only symbols to the export file when running on Tiger.
958         * WebCore.Tiger.exp:  Added.  Move Tiger-only symbol here from WebCore.base.exp.
959         * WebCore.base.exp:
960         * platform/graphics/mac/SimpleFontDataMac.mm:
961         (WebCore::SimpleFontData::platformInit):  Use Leopard APIs when building on Leopard.
962         * platform/mac/WebCoreSystemInterface.h:  Don't declare wkGetFontMetrics on Leopard as it is unused.
963         * platform/mac/WebCoreSystemInterface.mm:  Ditto.
964
965 2008-02-28  Matt Lilek  <webkit@mattlilek.com>
966
967         Reviewed by Tim Hatcher.
968
969         Bug 16535: Stylesheets loaded with @import are not editable
970         http://bugs.webkit.org/show_bug.cgi?id=16535
971         <rdar://problem/5712899>
972
973         Sheets loaded using @import were incorrectly being flagged as non-editable
974         user agent sheets because their parent sheet doesn't have an ownerNode. We now
975         check to make sure sheets also don't have a href before restricting their editability.
976
977         * page/inspector/StylesSidebarPane.js:
978
979 2008-02-28  Rodney Dawes  <dobey@wayofthemonkey.com>
980
981         Reviewed by Adam Roben.
982
983         Copy PluginPackageWin.cpp to shared PluginPackage.cpp.
984         Add PluginPackage.cpp to build configurations.
985         Remove PluginPackage destructor from TemporaryLinkStubs.cpp.
986         Use cross-platform pathGetFilename method.
987         Remove platform-specific code from shared PluginPackage implementation.
988         Remove shared code from PluginPackageWin.cpp.
989
990         * GNUmakefile.am:
991         * WebCore.pro:
992         * WebCoreSources.bkl:
993         * WebCore.vcproj/WebCore.vcproj:
994         * platform/gtk/TemporaryLinkStubs.cpp:
995         * platform/qt/TemporaryLinkStubs.cpp:
996         * platform/wx/TemporaryLinkStubs.cpp:
997         * plugins/PluginPackage.cpp:
998         * plugins/win/PluginPackageWin.cpp:
999
1000 2008-02-28  Justin Garcia  <justin.garcia@apple.com>
1001
1002         Reviewed by Darin Adler.
1003
1004         <rdar://problem/4930986> REGRESSION: Paste As Quotation pastes black text instead of blue
1005         
1006         Add a second style span at copy time to hold document default styles.  This helps us
1007         differentiate between those and user applied styles at paste time, where we'll want
1008         to let Mail's Paste As Quotation blockquote override document default styles, but
1009         not others.
1010
1011         * css/CSSComputedStyleDeclaration.cpp:
1012         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Changed the unit type used 
1013         for -webkit-text-stroke-width from CSS_NUMBER to CSS_PX, to match other properties that 
1014         are thick | medium | thin | <length>.  Before, there was a mismatch between the unit 
1015         type of -webkit-text-stroke-width property values in a CSSComputedStyleDeclaration for 
1016         an element and that element's inlineStyleDecl(), causing identical values to always appear 
1017         different to diff().
1018         * editing/ReplaceSelectionCommand.cpp:
1019         (WebCore::ReplaceSelectionCommand::handlePasteAsQuotationNode): Fixed.  Don't just change
1020         the class to an empty string, completely remove it, it's no longer needed.
1021         (WebCore::handleStyleSpansBeforeInsertion): Moved the optimization from doApply here.
1022         (WebCore::ReplaceSelectionCommand::handleStyleSpans): 
1023         Added, replaces removeRedundantStyles.
1024         We aren't (yet) removing all redundant styles, just those on style spans, so I removed the
1025         unused code and renamed the function.
1026         There won't be more than two style spans that we need to consider, the one with the 
1027         source document's default styles and styles on the commonAncestor of the copied Range, 
1028         so don't look for more than two.
1029         Let elements that wrap the incoming fragment override the source document's styles.
1030         (WebCore::ReplaceSelectionCommand::doApply): Moved code to handleStyleSpansBeforeInsertion
1031         and call the renamed handleStyleSpans.
1032         * editing/ReplaceSelectionCommand.h:
1033         * editing/markup.cpp:
1034         (WebCore::removeDefaultStyles): Added.  Don't add document defaults to the style span
1035         that holds user applied styles, since they'll be added to their own style span.
1036         (WebCore::createMarkup):
1037         Add a second style span that holds just the document defaults. This lets us differentiate
1038         between those and user applied styles at paste time.
1039         Mail blockquotes are just another type of special element, moved their handling there. This
1040         also lets paste code make assumptions about the position of the two style spans (they are 
1041         *always* parent-child).
1042
1043 2008-02-28  Brent Fulgham <bfulgham@gmail.com>
1044
1045         http://bugs.webkit.org/show_bug.cgi?id=17576
1046         Modify RenderThemeWin to use SOFT_LINK
1047
1048         Reviewed by Adam Roben.
1049
1050         * rendering/RenderThemeWin.h: Remove unneeded library handle
1051         * rendering/RenderThemeWin.cpp: Change to use SOFT_LINK
1052           rather than hand-coded load library calls.
1053
1054 2008-02-28  Dan Bernstein  <mitz@apple.com>
1055
1056         Reviewed by Darin Adler.
1057
1058         - fix http://bugs.webkit.org/show_bug.cgi?id=17590
1059           ASSERTION FAILED: subject in jsRegExpExecute()
1060
1061         * page/mac/FrameMac.mm:
1062         (WebCore::Frame::matchLabelsAgainstElement): Added an early return in
1063         case the element name is empty.
1064
1065 2008-02-28  Justin Garcia  <justin.garcia@apple.com>
1066
1067         Reviewed by Dan Bernstein
1068         
1069         Small editing speed up.
1070         
1071         * dom/Position.cpp:
1072         (WebCore::Position::upstream): Don't check for a change in editability
1073         if the current node hasn't changed.
1074         (WebCore::Position::downstream): Ditto.
1075
1076 2008-02-27  Dan Bernstein  <mitz@apple.com>
1077
1078         Reviewed by John Sullivan.
1079
1080         - fix <rdar://problem/5607547> Single letter surrounded by soft hyphens can disappear
1081
1082         Test: fast/text/soft-hyphen-2.html
1083
1084         * rendering/bidi.cpp:
1085         (WebCore::chopMidpointsAt): Changed to iterate midpoints backwards, so
1086         that if there are two midpoints at the given position, only the last one
1087         will be chopped off.
1088
1089 2008-02-27  Dan Bernstein  <mitz@apple.com>
1090
1091         Reviewed by Darin Adler.
1092
1093         - make centered text in right-to-left blocks spill over to the left
1094
1095         Test: fast/text/align-center-rtl-spill.html
1096
1097         * rendering/bidi.cpp:
1098         (WebCore::RenderBlock::computeHorizontalPositionsForLine):
1099
1100 2008-02-27  Dan Bernstein  <mitz@apple.com>
1101
1102         Reviewed by Darin Adler.
1103
1104         - more bidi.cpp cleanup
1105
1106         * platform/text/BidiResolver.h:
1107         (WebCore::BidiCharacterRun::destroy): Added. Overridden by BidiRun .
1108         (WebCore::BidiResolver<Iterator, Run>::addRun): Moved BidiState::addRun()
1109         here.
1110         (WebCore::BidiResolver<Iterator, Run>::appendRun): Changed to use
1111         addRun().
1112         (WebCore::BidiResolver<Iterator, Run>::deleteRuns): Changed to use
1113         destroy(), avoiding the need to specialize this method in BidiState.
1114         * rendering/bidi.cpp:
1115         (WebCore::BidiRun::destroy): Removed the RenderArena parameter.
1116         (WebCore::BidiState::deleteRuns): Removed now-unnecessary specialization.
1117         (WebCore::BidiState::addRun): Removed now-unnecessary specialization.
1118         (WebCore::RenderBlock::createLineBoxes): 
1119         (WebCore::RenderBlock::constructLine):
1120         (WebCore::RenderBlock::computeHorizontalPositionsForLine): Added a FIXME.
1121         (WebCore::RenderBlock::computeVerticalPositionsForLine):
1122         (WebCore::buildCompactRuns):
1123         (WebCore::RenderBlock::layoutInlineChildren):
1124         (WebCore::RenderBlock::determineStartPosition):
1125         (WebCore::RenderBlock::determineEndPosition):
1126         (WebCore::RenderBlock::matchedEndLine):
1127         (WebCore::skipNonBreakingSpace):
1128         (WebCore::RenderBlock::skipWhitespace):
1129         (WebCore::shouldSkipWhitespaceAfterStartObject):
1130         * rendering/bidi.h:
1131         (WebCore::BidiRun): Added m_ prefixes to several member variables. 
1132
1133 2008-02-27  Sam Weinig  <sam@webkit.org>
1134
1135         Reviewed by Darin.
1136
1137         Fix for <rdar://problem/5768769>
1138
1139         - Don't allow cross-origin calls using window.functionName.call(otherFrame)
1140           syntax.
1141
1142         * bindings/js/JSLocation.cpp:
1143         (WebCore::jsLocationProtoFuncToString): Do same-origin check.
1144         * bindings/js/kjs_window.cpp:
1145         (KJS::windowProtoFuncAToB): Ditto.
1146         (KJS::windowProtoFuncBToA): Ditto.
1147         (KJS::windowProtoFuncOpen): Ditto.
1148         (KJS::windowProtoFuncClearTimeout): Ditto.
1149         * bindings/scripts/CodeGeneratorJS.pm: Ditto.
1150
1151 2008-02-27  David Hyatt  <hyatt@apple.com>
1152
1153         More cleanup in preparation for fixing the HTML5 spec performance regression.
1154
1155         Reviewed by Sam Weinig
1156
1157         * dom/Attr.cpp:
1158         (WebCore::Attr::childrenChanged):
1159         * dom/Attr.h:
1160         * dom/ContainerNode.cpp:
1161         (WebCore::ContainerNode::insertBefore):
1162         (WebCore::ContainerNode::replaceChild):
1163         (WebCore::ContainerNode::removeChild):
1164         (WebCore::ContainerNode::removeChildren):
1165         (WebCore::ContainerNode::appendChild):
1166         (WebCore::ContainerNode::addChild):
1167         (WebCore::ContainerNode::childrenChanged):
1168         * dom/ContainerNode.h:
1169         * dom/Document.cpp:
1170         (WebCore::Document::childrenChanged):
1171         * dom/Document.h:
1172         * dom/Element.cpp:
1173         (WebCore::Element::childrenChanged):
1174         * dom/Element.h:
1175         * dom/Node.h:
1176         (WebCore::Node::childrenChanged):
1177         * html/HTMLObjectElement.cpp:
1178         (WebCore::HTMLObjectElement::childrenChanged):
1179         * html/HTMLObjectElement.h:
1180         * html/HTMLOptGroupElement.cpp:
1181         (WebCore::HTMLOptGroupElement::childrenChanged):
1182         * html/HTMLOptGroupElement.h:
1183         * html/HTMLOptionElement.cpp:
1184         (WebCore::HTMLOptionElement::childrenChanged):
1185         * html/HTMLOptionElement.h:
1186         * html/HTMLScriptElement.cpp:
1187         (WebCore::HTMLScriptElement::childrenChanged):
1188         * html/HTMLScriptElement.h:
1189         * html/HTMLSelectElement.cpp:
1190         (WebCore::HTMLSelectElement::childrenChanged):
1191         * html/HTMLSelectElement.h:
1192         * html/HTMLStyleElement.cpp:
1193         (WebCore::HTMLStyleElement::childrenChanged):
1194         * html/HTMLStyleElement.h:
1195         * html/HTMLTextAreaElement.cpp:
1196         (WebCore::HTMLTextAreaElement::childrenChanged):
1197         * html/HTMLTextAreaElement.h:
1198         * html/HTMLTitleElement.cpp:
1199         (WebCore::HTMLTitleElement::childrenChanged):
1200         * html/HTMLTitleElement.h:
1201         * svg/SVGClipPathElement.cpp:
1202         (WebCore::SVGClipPathElement::childrenChanged):
1203         * svg/SVGClipPathElement.h:
1204         * svg/SVGDefinitionSrcElement.cpp:
1205         (WebCore::SVGDefinitionSrcElement::childrenChanged):
1206         * svg/SVGDefinitionSrcElement.h:
1207         * svg/SVGFontFaceElement.cpp:
1208         (WebCore::SVGFontFaceElement::childrenChanged):
1209         * svg/SVGFontFaceElement.h:
1210         * svg/SVGFontFaceFormatElement.cpp:
1211         (WebCore::SVGFontFaceFormatElement::childrenChanged):
1212         * svg/SVGFontFaceFormatElement.h:
1213         * svg/SVGFontFaceSrcElement.cpp:
1214         (WebCore::SVGFontFaceSrcElement::childrenChanged):
1215         * svg/SVGFontFaceSrcElement.h:
1216         * svg/SVGFontFaceUriElement.cpp:
1217         (WebCore::SVGFontFaceUriElement::childrenChanged):
1218         * svg/SVGFontFaceUriElement.h:
1219         * svg/SVGGElement.cpp:
1220         (WebCore::SVGGElement::childrenChanged):
1221         * svg/SVGGElement.h:
1222         * svg/SVGGradientElement.cpp:
1223         (WebCore::SVGGradientElement::childrenChanged):
1224         * svg/SVGGradientElement.h:
1225         * svg/SVGMarkerElement.cpp:
1226         (WebCore::SVGMarkerElement::childrenChanged):
1227         * svg/SVGMarkerElement.h:
1228         * svg/SVGMaskElement.cpp:
1229         (WebCore::SVGMaskElement::childrenChanged):
1230         * svg/SVGMaskElement.h:
1231         * svg/SVGPatternElement.cpp:
1232         (WebCore::SVGPatternElement::childrenChanged):
1233         * svg/SVGPatternElement.h:
1234         * svg/SVGStyleElement.cpp:
1235         (WebCore::SVGStyleElement::childrenChanged):
1236         * svg/SVGStyleElement.h:
1237         * svg/SVGStyledElement.cpp:
1238         (WebCore::SVGStyledElement::childrenChanged):
1239         * svg/SVGStyledElement.h:
1240         * svg/SVGTitleElement.cpp:
1241         (WebCore::SVGTitleElement::childrenChanged):
1242         * svg/SVGTitleElement.h:
1243         * svg/SVGUseElement.cpp:
1244         (WebCore::SVGUseElement::childrenChanged):
1245         * svg/SVGUseElement.h:
1246
1247 2008-02-27  Julien Chaffraix <julien.chaffraix@gmail.com>
1248
1249         Reviewed by Alexey.
1250
1251         http://bugs.webkit.org/show_bug.cgi?id=17481
1252         Several consecutive calls to XMLHttpRequest::open should dispatch only one readyState event
1253
1254         Test: http/tests/xmlhttprequest/xmlhttprequest-multiple-open.html
1255
1256         * xml/XMLHttpRequest.cpp:
1257         (WebCore::XMLHttpRequest::open):
1258
1259 2008-02-27  Sriram Neelakandan  <sriram.neelakandan@gmail.com>
1260
1261         Reviewed, tweaked and landed by ap.
1262
1263         http://bugs.webkit.org/show_bug.cgi?id=17487
1264         HTMLInput mysteriously fails to work if ICU dat file is missing
1265
1266         * platform/text/TextBreakIteratorICU.cpp: (WebCore::setUpIterator): Assert that the iterator
1267         has been opened.
1268
1269 2008-02-27  Adam Roben  <aroben@apple.com>
1270
1271         Windows build fix after r30616
1272
1273         * platform/win/ClipboardWin.cpp:
1274
1275 2008-02-27  Nikolas Zimmermann  <zimmermann@kde.org>
1276
1277         Reviewed by Simon.
1278
1279         Small style cleanup, and obvious fix: SVGGElement reacted on
1280         'clipPathUnits' changes, which is a funny copy&paste error.
1281
1282         * svg/SVGGElement.cpp:
1283         (WebCore::SVGGElement::parseMappedAttribute):
1284         (WebCore::SVGGElement::svgAttributeChanged):
1285         (WebCore::SVGGElement::createRenderer):
1286
1287 2008-02-27  Nikolas Zimmermann  <zimmermann@kde.org>
1288
1289         Reviewed by Simon.
1290
1291         Cleanup coding style. Still on my way to fix dynamic updates of all SVG elements.
1292         Currently at SVGF*. SVGDefs/DescElement don't need any dyn update fixes but cleanups.
1293
1294         * svg/SVGDefsElement.cpp:
1295         (WebCore::SVGDefsElement::createRenderer):
1296         * svg/SVGDefsElement.h:
1297         * svg/SVGDescElement.h:
1298
1299 2008-02-26  Antti Koivisto  <antti@apple.com>
1300
1301         Reviewed by Darin.
1302
1303         Fix <rdar://problem/5761326>
1304         REGRESSION: 1.5% -2% Sunspider regression from r30009 (ebay photo upload hang)
1305         
1306         Generate better code with VS:
1307         - Use ALWAYS_INLINE macro to guarantee versions of allowsAccessFrom() are reduced to single functions
1308         - Refactor error reporting so that there is no need to construct/destruct Strings in common cases
1309         - Add a separate version of the function for cases where error messages are not wanted
1310
1311         * bindings/js/JSDOMWindowCustom.cpp:
1312         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
1313         * bindings/js/kjs_window.cpp:
1314         (KJS::Window::allowsAccessFrom):
1315         (KJS::Window::allowsAccessFromNoErrorMessage):
1316         (KJS::Window::allowsAccessFromPrivate):
1317         (KJS::Window::crossDomainAccessErrorMessage):
1318         * bindings/js/kjs_window.h:
1319
1320 2008-02-26  Sam Weinig  <sam@webkit.org>
1321
1322         Reviewed by Dave Hyatt.
1323
1324         - remove DeprecatedCString, DeprecatedArray, and ArrayImpl.
1325
1326         * GNUmakefile.am:
1327         * WebCore.pro:
1328         * WebCore.vcproj/WebCore.vcproj:
1329         * WebCore.xcodeproj/project.pbxproj:
1330         * WebCoreSources.bkl:
1331         * platform/ArrayImpl.cpp: Removed.
1332         * platform/ArrayImpl.h: Removed.
1333         * platform/DeprecatedArray.h: Removed.
1334         * platform/DeprecatedCString.cpp: Removed.
1335         * platform/DeprecatedCString.h: Removed.
1336         * platform/text/CString.cpp:
1337         (WebCore::CString::length):
1338         * platform/text/CString.h:
1339
1340 2008-02-26  David Hyatt  <hyatt@apple.com>
1341
1342         Cleanup of childrenChanged in preparation for fixing the HTML5 spec slowdown.
1343
1344         Reviewed by Sam Weinig
1345
1346         * dom/Attr.cpp:
1347         (WebCore::Attr::childrenChanged):
1348         * dom/ContainerNode.cpp:
1349         (WebCore::ContainerNode::insertBefore):
1350         (WebCore::ContainerNode::replaceChild):
1351         (WebCore::ContainerNode::removeChild):
1352         (WebCore::ContainerNode::removeChildren):
1353         (WebCore::ContainerNode::appendChild):
1354         (WebCore::ContainerNode::addChild):
1355         (WebCore::ContainerNode::childrenChanged):
1356         * dom/ContainerNode.h:
1357         * dom/EventTargetNode.cpp:
1358         (WebCore::EventTargetNode::dispatchSubtreeModifiedEvent):
1359         * dom/EventTargetNode.h:
1360         * dom/NamedAttrMap.cpp:
1361         (WebCore::NamedAttrMap::addAttribute):
1362         (WebCore::NamedAttrMap::removeAttribute):
1363
1364 2008-02-26  Darin Adler  <darin@apple.com>
1365
1366         Reviewed by Sam.
1367
1368         - remove use of DeprecatedCString from Windows pasteboard code
1369
1370         * platform/win/ClipboardUtilitiesWin.cpp:
1371         (WebCore::createGlobalData): Added an overload for Vector<char>.
1372         Streamlined the logic a bit.
1373         (WebCore::append): Added. Helper functions for appending to a
1374         Vector<char>.
1375         (WebCore::markupToCF_HTML): Rewrote to use Vector<char> instead
1376         of DeprecatedCString. Also simplified the logic a bit and used
1377         macros to handle the integer width.
1378         (WebCore::urlToMarkup): Use Vector<UChar> instead of String.
1379         (WebCore::replaceNewlinesWithWindowsStyleNewlines): Tweaked.
1380         * platform/win/ClipboardUtilitiesWin.h: Update type of return
1381         value from markupToCF_HTML. Did a bit of streamlining too.
1382         * platform/win/ClipboardWin.cpp:
1383         (WebCore::writeURL): Update for above changes.
1384         (WebCore::ClipboardWin::declareAndWriteDragImage): Ditto.
1385         (WebCore::ClipboardWin::writeRange): Ditto.
1386         * platform/win/PasteboardWin.cpp:
1387         (WebCore::Pasteboard::writeSelection): Ditto.
1388         (WebCore::Pasteboard::writeURL): Ditto.
1389
1390 2008-02-26  Timothy Hatcher  <timothy@apple.com>
1391
1392         Reviewed by Adam Roben.
1393
1394         <rdar://problem/5712777> REGRESSION: Arrow up/down in inspector
1395         source list does not scroll when item at edge is reached (16572)
1396
1397         Use scrollIntoViewIfNeeded() instead of the hand-rolled scrollToElement
1398         we were using in utilities.js.
1399
1400         * page/inspector/DocumentPanel.js: Use scrollIntoViewIfNeeded instead of scrollToElement.
1401         * page/inspector/Resource.js: Ditto.
1402         * page/inspector/inspector.js: Ditto.
1403         * page/inspector/SourcePanel.js: Use scrollIntoViewIfNeeded instead
1404         of scrollIntoView, so the source line is centered in the view if needed.
1405         * page/inspector/utilities.js: Removed scrollToElement().
1406
1407 2008-02-26  David Hyatt  <hyatt@apple.com>
1408
1409         Reviewed by Dan
1410
1411         http://bugs.webkit.org/show_bug.cgi?id=17485
1412
1413         Refine our behavior for empty inlines so that they work more correctly with margins/borders/padding.
1414         Fixes a regression on huffingtonpost.com.
1415
1416         New tests added to fast/inline
1417
1418         * rendering/InlineFlowBox.cpp:
1419         (WebCore::InlineFlowBox::computeLogicalBoxHeights):
1420         (WebCore::InlineFlowBox::placeBoxesVertically):
1421         (WebCore::InlineFlowBox::shrinkBoxesWithNoTextChildren):
1422         * rendering/RenderFlow.cpp:
1423         (WebCore::RenderFlow::calcMargins):
1424         * rendering/RenderFlow.h:
1425         * rendering/RenderObject.h:
1426         (WebCore::RenderObject::hasHorizontalBordersPaddingOrMargin):
1427         (WebCore::RenderObject::hasHorizontalBordersOrPadding):
1428         * rendering/bidi.cpp:
1429         (WebCore::getBorderPaddingMargin):
1430         (WebCore::RenderBlock::layoutInlineChildren):
1431         (WebCore::inlineFlowRequiresLineBox):
1432
1433 2008-02-26  Sam Weinig  <sam@webkit.org>
1434
1435         Fix Windows build.
1436
1437         * platform/text/PlatformString.h:
1438         (WebCore::reverseFind):
1439
1440 2008-02-26  Dan Bernstein  <mitz@apple.com>
1441
1442         Reviewed by Darin Adler.
1443
1444         - fix http://bugs.webkit.org/show_bug.cgi?id=17555
1445           <rdar://problem/5766016> REGRESSION (r27351): Thumbnails positioned wrong on Getty Images results page
1446
1447         Test: fast/dynamic/subtree-table-cell-height.html
1448
1449         * rendering/RenderObject.cpp:
1450         (WebCore::objectIsRelayoutBoundary): Exclude table cells, since their
1451         height depends on their contents even if the CSS height property is
1452         fixed.
1453
1454 2008-02-25  Sam Weinig  <sam@webkit.org>
1455
1456         Reviewed by Dan Bernstein.
1457
1458         Make the cleanPath function in CSSStyleSelector more efficient by using
1459         a Vector<UChar>.
1460
1461         * css/CSSStyleSelector.cpp:
1462         (WebCore::cleanPath): Make this function work on a Vector<UChar> instead
1463         of a String.  Also remove unnecessary reverseFind call that could be acomplished
1464         with two compares.
1465         (WebCore::checkPseudoState): Remove reserveCapacity calls now that we are using
1466         a stack buffer.
1467         * platform/text/PlatformString.h:
1468         (WebCore::find): Make this find generic enough that it can be used for
1469         String::find.
1470         (WebCore::reverseFind): Implement reverseFind so that it can be used
1471         for with a UChar* and length.
1472         * platform/text/StringImpl.cpp:
1473         (WebCore::StringImpl::find): Use implementation in PlatformString.cpp
1474         (WebCore::StringImpl::reverseFind): Ditto,
1475
1476 2008-02-26  Satoshi Nakagawa  <artension@gmail.com>
1477
1478         Reviewed by Darin. Tweaked and landed by Alexey.
1479
1480         http://bugs.webkit.org/show_bug.cgi?id=17411
1481         Ideographic comma and full stop should be treated as line-breakable characters
1482
1483         Test: fast/text/line-breaks-after-ideographic-comma-or-full-stop.html
1484
1485         * platform/text/CharacterNames.h: Added ideographicComma and ideographicFullStop.
1486         * rendering/break_lines.cpp: (WebCore::shouldBreakAfter): Added a workaround for an issue in
1487         Unicode 5.0 that is causing this.
1488
1489 2008-02-26  MorganL  <morganl.webkit@yahoo.com>
1490
1491         Reviewed by eseidel.  Landed by eseidel
1492
1493         Fix improperly initialized m_isUpToDate member variable.
1494         Fixs 50+ layout tests when run on Tiger.
1495         http://bugs.webkit.org/show_bug.cgi?id=17549
1496
1497         * platform/network/cf/ResourceResponse.h:
1498         (WebCore::ResourceResponse::ResourceResponse):
1499         * platform/network/mac/ResourceResponse.h:
1500         (WebCore::ResourceResponse::ResourceResponse):
1501
1502 2008-02-25  Dan Bernstein  <mitz@apple.com>
1503
1504         Reviewed by Sam Weinig.
1505
1506         - fix http://bugs.webkit.org/show_bug.cgi?id=17152
1507           Paragraphs indented with :first-letter and text-align CSS render incorrectly
1508
1509         Test: fast/text/apply-start-width-after-skipped-text.html
1510
1511         * rendering/bidi.cpp:
1512         (WebCore::RenderBlock::findNextLineBreak): Improved the logic for when
1513         to figure in the padding, border and margin before a text node when the
1514         line begins inside a text node.
1515
1516 2008-02-25  Kevin Ollivier  <kevino@theolliviers.com>
1517
1518         Windows build fix for wx port.
1519
1520         * loader/FTPDirectoryDocument.cpp:
1521
1522 2008-02-25  Mark Rowe  <mrowe@apple.com>
1523
1524         Windows build fix.
1525
1526         * platform/network/cf/ResourceResponseCFNet.cpp:
1527         (WebCore::ResourceResponse::platformCompare):  Implement platformCompare for ResourceResponseCFNet.cpp.
1528
1529 2008-02-25  Beth Dakin  <bdakin@apple.com>
1530
1531         Reviewed by Geoff.
1532
1533         Fixed for <rdar://problem/5760530> REGRESSION: Assertion failure in 
1534         Document::removePendingSheet() from r30438
1535
1536         r30438 added a call to CachedResource::error() from inside 
1537         Loader::didReceiveData() if a CSS file 4xxs. There was an 
1538         assumption in the loader, though, that either error() would be 
1539         called, or didFinishLoading() would be called, so some work is 
1540         duplicated in each. Now that we are calling an error() on files 
1541         that will also make it to didFinishLoading() (since they succeeded 
1542         in the network layer), we need to make sure we do not duplicate the 
1543         work. CachedCSSStyleSheet::error() calls checkNotify, which ends up 
1544         decrementing the document's pending style sheet counter. 
1545         checkNotify() was still getting called, though, through the normal  
1546         didFinishLoading code path, and the counter was being decremented 
1547         twice. Bad!
1548
1549         * loader/loader.cpp:
1550         (WebCore::Loader::didFinishLoading):
1551         (WebCore::Loader::didReceiveData):
1552
1553 2008-02-25  Mark Rowe  <mrowe@apple.com>
1554
1555         Fix the Gtk, wx and Qt builds.
1556
1557         * GNUmakefile.am: Add new files.
1558         * WebCore.pro: Ditto.
1559         * WebCoreSources.bkl: Ditto.
1560         * platform/network/AuthenticationChallengeBase.h: Fix up argument types.
1561
1562 2008-02-25  MorganL  <morganl.webkit@yahoo.com>
1563
1564         Reviewed by Darin Adler.
1565
1566         Eliminate some #ifdefs from headers in platform/network.
1567         http://bugs.webkit.org/show_bug.cgi?id=17210
1568
1569         * WebCore.base.exp:
1570         * WebCore.order:
1571         * WebCore.vcproj/WebCore.vcproj:
1572         * WebCore.xcodeproj/project.pbxproj:
1573         * dom/XMLTokenizer.cpp:
1574         * loader/ResourceLoader.h:
1575         * platform/network/AuthenticationChallenge.cpp: Removed.
1576         * platform/network/AuthenticationChallenge.h: Removed.
1577         * platform/network/AuthenticationChallengeBase.cpp: Copied from platform/network/AuthenticationChallenge.cpp.
1578         (WebCore::AuthenticationChallengeBase::AuthenticationChallengeBase):
1579         (WebCore::AuthenticationChallengeBase::previousFailureCount):
1580         (WebCore::AuthenticationChallengeBase::proposedCredential):
1581         (WebCore::AuthenticationChallengeBase::protectionSpace):
1582         (WebCore::AuthenticationChallengeBase::failureResponse):
1583         (WebCore::AuthenticationChallengeBase::error):
1584         (WebCore::AuthenticationChallengeBase::isNull):
1585         (WebCore::AuthenticationChallengeBase::nullify):
1586         (WebCore::AuthenticationChallengeBase::compare):
1587         * platform/network/AuthenticationChallengeBase.h: Copied from platform/network/AuthenticationChallenge.h.
1588         (WebCore::AuthenticationChallengeBase::platformCompare):
1589         (WebCore::operator==):
1590         (WebCore::operator!=):
1591         * platform/network/ResourceError.cpp: Removed.
1592         * platform/network/ResourceError.h: Removed.
1593         * platform/network/ResourceErrorBase.cpp: Copied from platform/network/ResourceError.cpp.
1594         (WebCore::ResourceErrorBase::lazyInit):
1595         (WebCore::ResourceErrorBase::compare):
1596         * platform/network/ResourceErrorBase.h: Copied from platform/network/ResourceError.h.
1597         (WebCore::ResourceErrorBase::isNull):
1598         (WebCore::ResourceErrorBase::domain):
1599         (WebCore::ResourceErrorBase::errorCode):
1600         (WebCore::ResourceErrorBase::failingURL):
1601         (WebCore::ResourceErrorBase::localizedDescription):
1602         (WebCore::ResourceErrorBase::ResourceErrorBase):
1603         (WebCore::ResourceErrorBase::platformLazyInit):
1604         (WebCore::ResourceErrorBase::platformCompare):
1605         (WebCore::operator==):
1606         * platform/network/ResourceResponseBase.cpp:
1607         (WebCore::ResourceResponseBase::isHTTP):
1608         (WebCore::ResourceResponseBase::url):
1609         (WebCore::ResourceResponseBase::setUrl):
1610         (WebCore::ResourceResponseBase::mimeType):
1611         (WebCore::ResourceResponseBase::setMimeType):
1612         (WebCore::ResourceResponseBase::expectedContentLength):
1613         (WebCore::ResourceResponseBase::setExpectedContentLength):
1614         (WebCore::ResourceResponseBase::textEncodingName):
1615         (WebCore::ResourceResponseBase::setTextEncodingName):
1616         (WebCore::ResourceResponseBase::suggestedFilename):
1617         (WebCore::ResourceResponseBase::setSuggestedFilename):
1618         (WebCore::ResourceResponseBase::httpStatusCode):
1619         (WebCore::ResourceResponseBase::setHTTPStatusCode):
1620         (WebCore::ResourceResponseBase::httpStatusText):
1621         (WebCore::ResourceResponseBase::setHTTPStatusText):
1622         (WebCore::ResourceResponseBase::httpHeaderField):
1623         (WebCore::ResourceResponseBase::setHTTPHeaderField):
1624         (WebCore::ResourceResponseBase::httpHeaderFields):
1625         (WebCore::ResourceResponseBase::isAttachment):
1626         (WebCore::ResourceResponseBase::setExpirationDate):
1627         (WebCore::ResourceResponseBase::expirationDate):
1628         (WebCore::ResourceResponseBase::setLastModifiedDate):
1629         (WebCore::ResourceResponseBase::lastModifiedDate):
1630         (WebCore::ResourceResponseBase::lazyInit):
1631         (WebCore::ResourceResponseBase::compare):
1632         * platform/network/ResourceResponseBase.h:
1633         (WebCore::ResourceResponseBase::ResourceResponseBase):
1634         (WebCore::ResourceResponseBase::platformLazyInit):
1635         (WebCore::ResourceResponseBase::platformCompare):
1636         (WebCore::operator==):
1637         * platform/network/cf/AuthenticationCF.cpp:
1638         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
1639         (WebCore::AuthenticationChallenge::platformCompare):
1640         * platform/network/cf/AuthenticationChallenge.h: Added.
1641         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
1642         (WebCore::AuthenticationChallenge::sourceHandle):
1643         (WebCore::AuthenticationChallenge::cfURLAuthChallengeRef):
1644         * platform/network/cf/ResourceError.h: Added.
1645         (WebCore::ResourceError::ResourceError):
1646         * platform/network/cf/ResourceErrorCF.cpp:
1647         (WebCore::ResourceError::ResourceError):
1648         (WebCore::ResourceError::platformLazyInit):
1649         (WebCore::ResourceError::platformCompare):
1650         (WebCore::ResourceError::operator CFStreamError):
1651         * platform/network/cf/ResourceResponse.h:
1652         (WebCore::ResourceResponse::ResourceResponse):
1653         * platform/network/cf/ResourceResponseCFNet.cpp:
1654         (WebCore::ResourceResponse::platformLazyInit):
1655         * platform/network/curl/AuthenticationChallenge.h: Added.
1656         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
1657         * platform/network/curl/ResourceError.h: Added.
1658         (WebCore::ResourceError::ResourceError):
1659         * platform/network/curl/ResourceResponse.h:
1660         (WebCore::ResourceResponse::ResourceResponse):
1661         * platform/network/mac/AuthenticationChallenge.h: Added.
1662         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
1663         (WebCore::AuthenticationChallenge::sender):
1664         (WebCore::AuthenticationChallenge::nsURLAuthenticationChallenge):
1665         * platform/network/mac/AuthenticationMac.mm:
1666         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
1667         (WebCore::AuthenticationChallenge::platformCompare):
1668         * platform/network/mac/ResourceError.h: Added.
1669         (WebCore::ResourceError::ResourceError):
1670         * platform/network/mac/ResourceErrorMac.mm:
1671         (WebCore::ResourceError::platformLazyInit):
1672         (WebCore::ResourceError::platformCompare):
1673         * platform/network/mac/ResourceResponse.h:
1674         (WebCore::ResourceResponse::ResourceResponse):
1675         * platform/network/mac/ResourceResponseMac.mm:
1676         (WebCore::ResourceResponse::platformLazyInit):
1677         (WebCore::ResourceResponse::platformCompare):
1678         * platform/network/qt/AuthenticationChallenge.h: Added.
1679         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
1680         * platform/network/qt/ResourceError.h: Added.
1681         (WebCore::ResourceError::ResourceError):
1682         * platform/network/qt/ResourceResponse.h:
1683         (WebCore::ResourceResponse::ResourceResponse):
1684         * xml/XSLTProcessor.cpp:
1685
1686 2008-02-25  Anders Carlsson  <andersca@apple.com>
1687
1688         Reviewed by Darin.
1689
1690         Move remaining render style objects over to start with a refcount of 1 and get
1691         rid of DeprecatedDataRef.
1692         
1693         * rendering/DataRef.h:
1694         (WebCore::DataRef::operator*):
1695         (WebCore::DataRef::operator->):
1696         * rendering/RenderStyle.h:
1697         * rendering/SVGRenderStyle.cpp:
1698         (WebCore::SVGRenderStyle::SVGRenderStyle):
1699         * rendering/SVGRenderStyle.h:
1700         (WebCore::SVGRenderStyle::create):
1701         (WebCore::SVGRenderStyle::copy):
1702         * rendering/SVGRenderStyleDefs.cpp:
1703         (StyleFillData::StyleFillData):
1704         (StyleStrokeData::StyleStrokeData):
1705         (StyleStopData::StyleStopData):
1706         (StyleTextData::StyleTextData):
1707         (StyleClipData::StyleClipData):
1708         (StyleMaskData::StyleMaskData):
1709         (StyleMarkerData::StyleMarkerData):
1710         (StyleMiscData::StyleMiscData):
1711         * rendering/SVGRenderStyleDefs.h:
1712         (WebCore::StyleFillData::create):
1713         (WebCore::StyleFillData::copy):
1714         (WebCore::StyleStrokeData::create):
1715         (WebCore::StyleStrokeData::copy):
1716         (WebCore::StyleStopData::create):
1717         (WebCore::StyleStopData::copy):
1718         (WebCore::StyleTextData::create):
1719         (WebCore::StyleTextData::copy):
1720         (WebCore::StyleClipData::create):
1721         (WebCore::StyleClipData::copy):
1722         (WebCore::StyleMaskData::create):
1723         (WebCore::StyleMaskData::copy):
1724         (WebCore::StyleMarkerData::create):
1725         (WebCore::StyleMarkerData::copy):
1726         (WebCore::StyleMiscData::create):
1727         (WebCore::StyleMiscData::copy):
1728
1729 2008-02-25  Dan Bernstein  <mitz@apple.com>
1730
1731         Reviewed by Dave Hyatt.
1732
1733         - remove file-static BidiRun variables from bidi.cpp
1734
1735         * platform/text/BidiResolver.h:
1736         (WebCore::BidiResolver::): Initialize m_logicallyLastRun.
1737         (WebCore::BidiResolver::logicallyLastRun): Added.
1738         (WebCore::BidiResolver::runCount): Made unsigned.
1739         (WebCore::::reverseRuns): Changed ints to unsigned.
1740         (WebCore::::createBidiRunsForLine): Made this function set
1741         m_logicallyLastRun.
1742         * rendering/RenderBlock.h:
1743         * rendering/bidi.cpp:
1744         (WebCore::BidiState::addRun): Removed setting of sLogicallyLastBidiRun.
1745         (WebCore::RenderBlock::constructLine): Removed unused start parameter
1746         and added run count and first and last run parameters. Replaced end
1747         parameter with lastLine boolean and endObject pointer.
1748         (WebCore::RenderBlock::computeHorizontalPositionsForLine): Added first
1749         and logically last run parameters.
1750         (WebCore::RenderBlock::computeVerticalPositionsForLine): Added firstRun
1751         parameter.
1752         (WebCore::RenderBlock::bidiReorderLine): Removed setting of static
1753         variables.
1754         (WebCore::RenderBlock::layoutInlineChildren): Changed to use BidiState
1755         accessors instead of file statics.
1756
1757 2008-02-25  Rodney Dawes  <dobey@wayofthemonkey.com>
1758
1759         Reviewed by Jon Honeycutt.
1760
1761         http://bugs.webkit.org/show_bug.cgi?id=16924
1762         Bug 16924: Shared PluginDatabase, PluginPackage, and PlugInInfoStore implementations
1763
1764         Add PluginInfoStore.cpp and new PluginDatabase.cpp to GTK+ and Qt ports.
1765         Remove old PlugInInfoStoreQt.cpp as it is obsoleted by shared code.
1766         Add PluginInfoStore, PluginDatabase, and PluginStream files to Wx build.
1767         Add new PluginDatabase.cpp to Windows build.
1768         Add temporary stubs for new PluginDatabase and PluginPackage.
1769         shared classes to GTK+, Qt, and Wx ports.
1770         Copy PluginDatabaseWin.cpp to PluginDatabase.cpp to preserve history.
1771         Remove shared code from PluginDatabaseWin.cpp.
1772         Remove Windows-specific code from PluginDatabase.cpp.
1773         Use PlatformModule and PlatformFileTime instead of HMODULE and FILETIME.
1774         Remove extraneous PluginPackage:: from hash() class method prototype.
1775         Subsume storeFileVersion into PluginPackage::fetchInfo.
1776         Add cross-platform PlatformModuleVersion type definition.
1777         Use PlatformModuleVersion to store the module version.
1778         Rename m_fileVersion[ML]S to m_moduleVersion.
1779         Change compareFileVersion to use PlatformModuleVersion as the argument.
1780         Move PluginView::determineQuirks and m_quirks to PluginPackage.
1781         Updated determineQuirks for the PlatformModuleVersion.
1782
1783         * GNUmakefile.am:
1784         * WebCore.pro:
1785         * WebCoreSources.bkl:
1786         * webcore-base.bkl:
1787         * WebCore.vcproj/WebCore.vcproj:
1788         * Platform/FileSystem.h:
1789         * platform/qt/PlugInInfoStoreQt.cpp:
1790         * platform/gtk/TemporaryLinkStubs.cpp:
1791         * platform/qt/TemporaryLinkStubs.cpp:
1792         * platform/wx/TemporaryLinkStubs.cpp:
1793         * plugins/PluginDatabase.cpp:
1794         * plugins/PluginDatabase.h:
1795         * plugins/win/PluginDatabaseWin.cpp:
1796         * plugins/PluginPackage.h:
1797         * plugins/win/PluginPackageWin.cpp:
1798         * plugins/PluginView.h:
1799         * plugins/win/PluginViewWin.cpp:
1800
1801 2008-02-25  Anders Carlsson  <andersca@apple.com>
1802
1803         Reviewed by Darin.
1804
1805         Make more style objects start out with a refcount of 1.
1806         
1807         * rendering/RenderStyle.cpp:
1808         (WebCore::StyleSurroundData::StyleSurroundData):
1809         (WebCore::StyleBoxData::StyleBoxData):
1810         (WebCore::StyleVisualData::StyleVisualData):
1811         (WebCore::StyleBackgroundData::StyleBackgroundData):
1812         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1813         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
1814         (WebCore::StyleInheritedData::StyleInheritedData):
1815         * rendering/RenderStyle.h:
1816         (WebCore::StyleSurroundData::create):
1817         (WebCore::StyleSurroundData::copy):
1818         (WebCore::StyleBoxData::create):
1819         (WebCore::StyleBoxData::copy):
1820         (WebCore::StyleVisualData::create):
1821         (WebCore::StyleVisualData::copy):
1822         (WebCore::StyleBackgroundData::create):
1823         (WebCore::StyleBackgroundData::copy):
1824         (WebCore::StyleBackgroundData::~StyleBackgroundData):
1825         (WebCore::StyleRareNonInheritedData::create):
1826         (WebCore::StyleRareNonInheritedData::copy):
1827         (WebCore::StyleRareInheritedData::create):
1828         (WebCore::StyleRareInheritedData::copy):
1829         (WebCore::StyleInheritedData::create):
1830         (WebCore::StyleInheritedData::copy):
1831
1832 2008-02-25  Anders Carlsson  <andersca@apple.com>
1833
1834         Reviewed by Darin.
1835
1836         Make some of the refcounted style objects start out with a refcount of 1.
1837
1838         * rendering/DataRef.h:
1839         Make a DeprecatedDataRef class which is just a copy of the old DataRef class.
1840         Change DataRef to use ::create() and ::copy() instead of the constructors.
1841         Change DataRef's pointer to be a RefPtr instead.
1842
1843         * rendering/RenderStyle.cpp:
1844         (WebCore::StyleMarqueeData::StyleMarqueeData):
1845         (WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
1846         (WebCore::StyleMultiColData::StyleMultiColData):
1847         (WebCore::StyleTransformData::StyleTransformData):
1848         Start with a RefCount of 1.
1849         
1850         * rendering/RenderStyle.h:
1851         * rendering/SVGRenderStyle.h:
1852         Add ::create() and ::copy() methods. Make not yet converted classes use DeprecatedDataRef.
1853
1854 2008-02-25  Darin Adler  <darin@apple.com>
1855
1856         Reviewed by Anders.
1857         Based on a patch by Tim Steele <timsteele41@gmail.com>.
1858
1859         - fix http://bugs.webkit.org/show_bug.cgi?id=17186
1860           Fragment navigation within a page permanently cancels meta refresh
1861
1862         Test: fast/loader/meta-refresh-anchor-click.html
1863
1864         * loader/FrameLoader.cpp:
1865         (WebCore::FrameLoader::load): When load type is FrameLoadTypeRedirectWithLockedHistory,
1866         always do a real load. This makes sure that meta refresh loads are treated as real loads
1867         rather than anchor scrolls. Also tweaked formatting a bit.
1868         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy): This function is
1869         an alternate way to complete a load, so it needs to start the redirection timer if
1870         redirection has already been scheduled.
1871
1872 2008-02-25  Dan Bernstein  <mitz@apple.com>
1873
1874         Reviewed by Darin Adler.
1875
1876         - avoid counting spaces in non-justified text
1877
1878         * rendering/bidi.cpp:
1879         Removed file-static numSpaces.
1880         (WebCore::BidiState::addRun): Removed space counting.
1881         (WebCore::RenderBlock::computeHorizontalPositionsForLine): Added space
1882         counting, conditional on the block having the text-align: justify
1883         property value.
1884         (WebCore::RenderBlock::bidiReorderLine): Removed initialization of
1885         numSpaces.
1886
1887 2008-02-25  Darin Adler  <darin@apple.com>
1888
1889         Requested by Steve.
1890
1891         * platform/graphics/cg/ImageSourceCG.cpp:
1892         (WebCore::ImageSource::createFrameAtIndex): Put the string into a global
1893         variable (because CFSTR is inefficient on Windows).
1894
1895 2008-02-25  Darin Adler  <darin@apple.com>
1896
1897         Reviewed by Adam.
1898
1899         * WebCore.base.exp: Export blankURL, and sort the file.
1900
1901 2008-02-25  Simon Hausmann  <hausmann@webkit.org>
1902
1903         Reviewed by Mark Rowe.
1904
1905         Fix compilation with gcc 4.3, added stdio.h and unistd.h inclusions.
1906
1907         * dom/Position.cpp:
1908         * dom/Range.cpp:
1909         * editing/Selection.cpp:
1910         * editing/SelectionController.cpp:
1911         * editing/VisiblePosition.cpp:
1912         * history/HistoryItem.cpp:
1913         * loader/Cache.cpp:
1914         * loader/FTPDirectoryParser.cpp:
1915         * platform/KURL.cpp:
1916         * platform/gtk/FileSystemGtk.cpp:
1917         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
1918         * platform/text/TextCodecLatin1.cpp:
1919         * platform/text/TextCodecUserDefined.cpp:
1920         * rendering/CounterNode.cpp:
1921         * rendering/RenderObject.cpp:
1922
1923 2008-02-25  Johnny Ding  <johnnyding.webkit@gmail.com>
1924
1925         Reviewed by Darin Adler.
1926
1927         - fix http://bugs.webkit.org/show_bug.cgi?id=17444
1928
1929         In HTMLTokenizer::write, the code checks 'pendingScripts.isEmpty()' to decide
1930         whether to save prependingSrc or not. However, in HTMLTokenizer::scriptHandler
1931         and HTMLTokenizer::scriptExecution, the code checks testBit:LoadingExtScript
1932         to decide whether to save prependingSrc or not. The later behavior is not right
1933         because, in scriptHandler and scriptExecution, even the pendingScripts queue is
1934         empty, the testBit:LoadingExtScript might be TRUE.
1935
1936         Test: fast/tokenizer/nested-multiple-scripts.html
1937
1938         * html/HTMLTokenizer.cpp:
1939         (WebCore::HTMLTokenizer::scriptHandler): check pendingScripts.isEmpty() instead of
1940         checking state.loadingExtScript().
1941         (WebCore::HTMLTokenizer::scriptExecution): check pendingScripts.isEmpty() instead of
1942         checking state.loadingExtScript().
1943
1944 2008-02-24  Darin Adler  <darin@apple.com>
1945
1946         * dom/Document.h: Removed stray duplicate declaration of
1947         RegisteredEventListenerList.
1948
1949 2008-02-24  Darin Adler  <darin@apple.com>
1950
1951         * dom/Range.cpp:
1952         (WebCore::Range::surroundContents): Removed incorrect comment.
1953         I added it a while ago, and I was just mixed up.
1954
1955 2008-02-24  Darin Adler  <darin@apple.com>
1956
1957         - quick follow-up to that last check-in
1958
1959         * platform/graphics/cg/ImageSourceCG.cpp:
1960         (WebCore::ImageSource::createFrameAtIndex): Use CFEqual instead of
1961         WebCore::String's == for speed.
1962
1963 2008-02-24  Michael Knaup  <michael.knaup@mac.com>
1964
1965         Reviewed by Darin.
1966
1967         Bug 8749: XBM rendered incorrectly as black on white
1968
1969         xbm images are now created and rendered using black on a
1970         transparent background (same behavior as in Firefox)
1971
1972         Test: platform/mac/fast/canvas/canvas-draw-xbm-image.html
1973
1974         * platform/graphics/cg/ImageSourceCG.cpp:
1975         (WebCore::ImageSource::createFrameAtIndex):
1976
1977 2008-02-24  Dan Bernstein  <mitz@apple.com>
1978
1979         Reviewed by Darin Adler.
1980
1981         - fix http://bugs.webkit.org/show_bug.cgi?id=17471
1982           REGRESSION (r30438): Crash in deleteLineBoxes in cursor-adjusting code browsing Acid3
1983
1984         Test: http/tests/misc/object-image-error.html
1985
1986         * html/HTMLObjectElement.cpp:
1987         (WebCore::HTMLObjectElement::attach): Added an early return in case
1988         updateFromElement() has changed the object to use fallback content.
1989
1990 2008-02-24  Dan Bernstein  <mitz@apple.com>
1991
1992         Reviewed by Darin Adler.
1993
1994         - fix float positioning when a float that does not fit on the line is
1995           followed by a float that does
1996
1997         Test: fast/block/float/narrow-after-wide.html
1998
1999         * rendering/bidi.cpp:
2000         (WebCore::RenderBlock::findNextLineBreak): Changed to not position any
2001         more floats on the line once a float that does not fit is encountered.
2002         That float should be pushed to the next line, and so should all floats
2003         that follow, regardless of whether they can fit on the current line.
2004
2005 2008-02-24  Darin Adler  <darin@apple.com>
2006
2007         Reviewed by Sam.
2008
2009         - fix http://bugs.webkit.org/show_bug.cgi?id=16770
2010           Acid3 expects :visited styled links to restyle on iframe load
2011
2012         Disentangle global history updating from the back/forward history.
2013         There are many cases where we don't want to create a new back/forward
2014         item, but we do still want to add to the global history (used for visited
2015         link coloring) in those cases.
2016
2017         Test: fast/history/subframe-is-visited.html
2018
2019         * loader/FrameLoader.cpp:
2020         (WebCore::FrameLoader::updateGlobalHistory): Renamed from
2021         addHistoryForCurrentLocation and removed the back/forward handling.
2022         (WebCore::FrameLoader::updateHistoryForStandardLoad): Streamlined logic a
2023         bit. Replaced call to addHistoryForCurrentLocation with a call to
2024         addBackForwardItemClippedAtTarget. Added an unconditional call to
2025         updateGlobalHistory.
2026         (WebCore::FrameLoader::updateHistoryForClientRedirect): Added a FIXME;
2027         why doesn't this function update global history?
2028         (WebCore::FrameLoader::updateHistoryForBackForwardNavigation): Ditto.
2029         (WebCore::FrameLoader::updateHistoryForReload): Replaced the direct call
2030         the client with a call to the new updateGlobalHistory function.
2031         (WebCore::FrameLoader::updateHistoryForRedirectWithLockedHistory): Did
2032         the same changes as for updateHistoryForStandardLoad.
2033         * loader/FrameLoader.h: More of the same.
2034
2035         * loader/FrameLoaderClient.h: Removed updateGlobalHistoryForReload and
2036         renamed updateGlobalHistoryForStandardLoad to updateGlobalHistory.
2037
2038         * svg/graphics/SVGImageEmptyClients.h:
2039         (WebCore::SVGEmptyFrameLoaderClient::updateGlobalHistory): Updated to
2040         match the above.
2041
2042 2008-02-23  Darin Adler  <darin@apple.com>
2043
2044         Reviewed by Sam.
2045
2046         - fix http://bugs.webkit.org/show_bug.cgi?id=17508
2047           REGRESSION (r30535): mailto regression tests failing
2048
2049         * html/HTMLFormElement.cpp:
2050         (WebCore::HTMLFormElement::submit): Restore the old logic, with its unpleasant
2051         trip through String do to the replace operation. It's inefficient, but there's
2052         no real reason to worry about the efficiency of mailto forms, since that feature
2053         is nearly obsolete.
2054
2055 2008-02-23  Darin Adler  <darin@apple.com>
2056
2057         Reviewed by Sam.
2058
2059         - replace SegmentedString's use of DeprecatedValueList with Deque
2060
2061         Testing indicates this is a slight speed-up for page loading.
2062
2063         * platform/text/SegmentedString.cpp:
2064         (WebCore::SegmentedString::length): Update to use Deque.
2065         (WebCore::SegmentedString::setExcludeLineNumbers): Ditto.
2066         (WebCore::SegmentedString::append): Ditto.
2067         (WebCore::SegmentedString::prepend): Ditto.
2068         (WebCore::SegmentedString::advanceSubstring): Ditto.
2069         (WebCore::SegmentedString::toString): Ditto.
2070         * platform/text/SegmentedString.h: Tweak formatting. Don't bother making an entire
2071         class private with a single friend. Change m_sbstrings from a DeprecatedValueList
2072         to a Deque.
2073
2074 2008-02-23  Darin Adler  <darin@apple.com>
2075
2076         Reviewed by Anders.
2077
2078         - fix http://bugs.webkit.org/show_bug.cgi?id=17506
2079           REGRESSION (r30535): ASSERTION FAILED: i < size()
2080
2081         * loader/TextResourceDecoder.cpp:
2082         (WebCore::findTextEncoding): Fix off-by-one in code that null-terminates
2083         the C string here.
2084
2085 2008-02-23  Matt Lilek  <webkit@mattlilek.com>
2086
2087         Not reviewed, build fix.
2088
2089         * platform/network/cf/FormDataStreamCFNet.cpp:
2090         (WebCore::httpBodyFromRequest):
2091         * plugins/win/PluginViewWin.cpp:
2092         (WebCore::PluginView::handlePost):
2093
2094 2008-02-23  Dan Bernstein  <mitz@apple.com>
2095
2096         - fix a typo
2097
2098         * platform/graphics/win/GlyphPageTreeNodeCGWin.cpp:
2099         (WebCore::GlyphPage::fill):
2100         * platform/graphics/win/GlyphPageTreeNodeCairoWin.cpp:
2101         (WebCore::GlyphPage::fill):
2102
2103 2008-02-23  Dan Bernstein  <mitz@apple.com>
2104
2105         Reviewed by Anders Carlsson.
2106
2107         - fix GlyphPage::fill() logic for partial page fills
2108
2109         * platform/graphics/win/GlyphPageTreeNodeCGWin.cpp:
2110         (WebCore::GlyphPage::fill): Changed the test for non-BMP characters to
2111         work correctly when the length parameter is less than a full page size.
2112         Also updated the comment.
2113         * platform/graphics/win/GlyphPageTreeNodeCairoWin.cpp:
2114         (WebCore::GlyphPage::fill): Ditto.
2115
2116 2008-02-23  Kevin Ollivier  <kevino@theolliviers.com>
2117
2118         Reviewed by Darin Adler.
2119
2120         Move text drawing into wxcode, as we need platform-dependent
2121         APIs for drawing non-kerned text, which wx doesn't yet have.
2122         (But hopefully will, once these APIs are fleshed out on all
2123         platforms!)
2124
2125         http://bugs.webkit.org/show_bug.cgi?id=17396
2126
2127         * platform/graphics/wx/FontWx.cpp:
2128         (WebCore::Font::drawGlyphs):
2129         * platform/wx/wxcode/gtk/non-kerned-drawing.cpp: Added.
2130         * platform/wx/wxcode/mac/carbon/non-kerned-drawing.cpp: Added.
2131         * platform/wx/wxcode/non-kerned-drawing.h: Added.
2132         * platform/wx/wxcode/win/non-kerned-drawing.cpp: Added.
2133         * webcore-wx.bkl:
2134
2135 2008-02-23  Darin Adler  <darin@apple.com>
2136
2137         Pointed out by Mitz.
2138
2139         * loader/TextResourceDecoder.cpp:
2140         (WebCore::find): Fix a "==" that was supposed to be ">".
2141         (WebCore::findIgnoringCase): Ditto.
2142
2143 2008-02-23  Darin Adler  <darin@apple.com>
2144
2145         Reviewed by Sam.
2146
2147         * html/HTMLFormElement.cpp:
2148         (WebCore::appendEncodedString): Fix buffer overrun in the code I just landed.
2149
2150 2008-02-23  Darin Adler  <darin@apple.com>
2151
2152         Reviewed by Sam.
2153
2154         - remove all but 1 remaining use of DeprecatedCString
2155         - change FormData to start refcount at 1
2156
2157         * html/HTMLFormElement.cpp:
2158         (WebCore::appendString): Added. Helpers for Vector<char>.
2159         (WebCore::appendEncodedString): Renamed from encodeCString and changed to
2160         append to an existing Vector<char> to cut down a bit on memory allocation.
2161         (WebCore::HTMLFormElement::formData): Replace the DeprecatedCString called
2162         enc_string with a Vector<char> called encodedData. Change to use the new
2163         FormData::create function.
2164         (WebCore::HTMLFormElement::submit): Same thing, for the mailto form code.
2165
2166         * loader/TextResourceDecoder.cpp:
2167         (WebCore::find): Added. Helper for searching in char* with length.
2168         (WebCore::findIgnoringCase): Ditto.
2169         (WebCore::findTextEncoding): Added. Helper for looking up a text encoding
2170         when we have a char* with length rather than a null-terminated char*.
2171         (WebCore::findXMLEncoding): Changed to use char* and length rather than
2172         DeprecatedCString. Also fixed some things that would be one-character
2173         buffer overruns in a string that's not null-terminated.
2174         (WebCore::TextResourceDecoder::checkForCSSCharset): Change to use
2175         findTextEncoding rather than constructing a CString to pass to the
2176         TextEncodingconstructor.
2177         (WebCore::TextResourceDecoder::checkForHeadCharset): Ditto.
2178
2179         * platform/network/FormData.cpp:
2180         (WebCore::FormData::FormData): Changed to start refcount at 1.
2181         (WebCore::FormData::create): Added.
2182         (WebCore::FormData::copy): Call adoptRef since refcount starts at 1.
2183         * platform/network/FormData.h: Made constructor private. Added create functions.
2184
2185         * platform/network/mac/ResourceRequestMac.mm:
2186         (WebCore::ResourceRequest::doUpdateResourceRequest): Call FormData::create.
2187         * xml/XMLHttpRequest.cpp:
2188         (WebCore::XMLHttpRequest::send): Ditto.
2189
2190 2008-02-23  Darin Adler  <darin@apple.com>
2191
2192         Reviewed by Anders.
2193
2194         - http://bugs.webkit.org/show_bug.cgi?id=17067
2195           eliminate attributes parameter from JSObject::put for speed/clarity
2196
2197         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
2198         (WebCore::JSCSSStyleDeclaration::customPut): Remove attributes argument.
2199
2200         * bindings/js/JSCanvasPixelArrayCustom.cpp:
2201         (WebCore::JSCanvasPixelArray::indexGetter): Use early exit idiom.
2202         (WebCore::JSCanvasPixelArray::indexSetter): Moved length check into the
2203         CanvasPixelArray object, for consistency with the getter. Removed attributes
2204         argument.
2205
2206         * bindings/js/JSDOMWindowCustom.cpp:
2207         (WebCore::JSDOMWindow::customPut): Removed special case for variable
2208         initialization, which is not needed since that does use put any more.
2209         Removed attributes argument.
2210
2211         * bindings/js/JSEventTargetBase.h:
2212         (WebCore::JSEventTargetBase::putValueProperty): Removed attributes argument.
2213         (WebCore::JSEventTargetBase::put): Ditto.
2214         (WebCore::JSEventTargetPrototype::self): Removed Internal flag.
2215         * bindings/js/JSEventTargetNode.cpp:
2216         (WebCore::JSEventTargetNode::put): Removed attributes argument.
2217         (WebCore::JSEventTargetNode::putValueProperty): Ditto.
2218         * bindings/js/JSEventTargetNode.h: Ditto.
2219         * bindings/js/JSHTMLAppletElementCustom.cpp:
2220         (WebCore::JSHTMLAppletElement::customPut): Ditto.
2221         * bindings/js/JSHTMLEmbedElementCustom.cpp:
2222         (WebCore::JSHTMLEmbedElement::customPut): Ditto.
2223         * bindings/js/JSHTMLInputElementBase.cpp:
2224         (WebCore::JSHTMLInputElementBase::put): Ditto.
2225         (WebCore::JSHTMLInputElementBase::putValueProperty): Ditto.
2226         * bindings/js/JSHTMLInputElementBase.h: Ditto.
2227         * bindings/js/JSHTMLObjectElementCustom.cpp:
2228         (WebCore::JSHTMLObjectElement::customPut): Ditto.
2229         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
2230         (WebCore::JSHTMLOptionsCollection::indexSetter): Ditto.
2231         * bindings/js/JSHTMLSelectElementCustom.cpp:
2232         (WebCore::JSHTMLSelectElement::indexSetter): Ditto.
2233         * bindings/js/JSHistoryCustom.cpp:
2234         (WebCore::JSHistory::customPut): Ditto.
2235         * bindings/js/JSLocation.cpp:
2236         (WebCore::JSLocation::put): Ditto.
2237         * bindings/js/JSLocation.h: Ditto.
2238         * bindings/js/JSXMLHttpRequest.cpp:
2239         (WebCore::JSXMLHttpRequest::put): Ditto.
2240         (WebCore::JSXMLHttpRequest::putValueProperty): Ditto.
2241         * bindings/js/JSXMLHttpRequest.h: Ditto.
2242
2243         * bindings/js/kjs_dom.cpp:
2244         (WebCore::getRuntimeObject): Changed return type to JSObject*.
2245         * bindings/js/kjs_dom.h: Ditto.
2246
2247         * bindings/js/kjs_events.cpp:
2248         (WebCore::JSClipboard::put): Removed attributes argument.
2249         (WebCore::JSClipboard::putValueProperty): Ditto.
2250         * bindings/js/kjs_events.h: Ditto.
2251
2252         * bindings/js/kjs_html.cpp:
2253         (WebCore::runtimeObjectGetter): Updated for change to getRuntimeObject to
2254         return a JSObject. Used early exit idiom.
2255         (WebCore::runtimeObjectPropertyGetter): Ditto.
2256         (WebCore::runtimeObjectCustomGetOwnPropertySlot): Ditto.
2257         (WebCore::runtimeObjectCustomPut): Use hasProperty to check for properties
2258         that we should put with the property syntax instead of canPut.
2259         (WebCore::runtimeObjectImplementsCall): Ditto.
2260         (WebCore::runtimeObjectCallAsFunction): Ditto.
2261         * bindings/js/kjs_html.h: Removed attributes argument to runtimeObjectCustomPut.
2262
2263         * bindings/js/kjs_window.cpp:
2264         (KJS::Window::put): Removed attributes argument.
2265         * bindings/js/kjs_window.h: Ditto.
2266
2267         * bindings/scripts/CodeGeneratorJS.pm: Removed attributes argument from put,
2268         putValueProperty, customPut, and indexSetter.
2269
2270         * html/CanvasPixelArray.h:
2271         (WebCore::CanvasPixelArray::set): Added index checking here, as in the get
2272         function. Before, the checking was done in the JavaScript bindings for set.
2273
2274 2008-02-23  Brent Fulgham  <bfulgham@gmail.com>
2275
2276         Reviewed by Adam and Darin.
2277
2278         http://bugs.webkit.org/show_bug.cgi?id=17442
2279         Correct the Windows Cairo implementation of GraphicsContext so
2280         that Windows 'WorldTransform' is kept in sync with the Cairo
2281         transormations.
2282
2283         Also corrects an uninitialized variable in the Cairo Windows
2284         image drag handler.
2285
2286         WARNING: NO TEST CASES ADDED OR CHANGED
2287
2288         * platform/graphics/cairo/GraphicsContextCairo.cpp:  Modify
2289           methods to call GraphicsContextPlatformPrivate calls, just
2290           as is done for the CoreGraphics version.  These calls are
2291           nop's for everything but Windows.
2292         (WebCore::GraphicsContext::savePlatformState):
2293         (WebCore::GraphicsContext::restorePlatformState):
2294         (WebCore::GraphicsContext::clip):
2295         (WebCore::GraphicsContext::drawLineForMisspellingOrBadGrammar):
2296         (WebCore::GraphicsContext::translate):
2297         (WebCore::GraphicsContext::concatCTM): Re-enable for Windows
2298         (WebCore::GraphicsContext::beginTransparencyLayer):
2299         (WebCore::GraphicsContext::endTransparencyLayer):
2300         (WebCore::GraphicsContext::rotate):
2301         (WebCore::GraphicsContext::scale):
2302         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
2303         * platform/graphics/win/GraphicsContextCGWin.cpp:  Move common
2304           code for handling WorldTransform calls to parent class.
2305         * platform/graphics/win/GraphicsContextCairoWin.cpp:  Add common
2306           code for handling WorldTransform calls.
2307           (WebCore::GraphicsContextPlatformPrivate::concatCTM):  Change
2308           implementation so that it only handles WorldTransform.  The
2309           Cairo update is done in GraphicsContextCairo.cpp
2310         * platform/graphics/win/GraphicsContextWin.cpp:  Call platform-private
2311           methods to keep WorldTransform in sync.
2312         (WebCore::GraphicsContextPlatformPrivate::save):
2313         (WebCore::GraphicsContextPlatformPrivate::restore):
2314         (WebCore::GraphicsContextPlatformPrivate::clip):
2315         (WebCore::GraphicsContextPlatformPrivate::scale):
2316         (WebCore::GraphicsContextPlatformPrivate::rotate):
2317         (WebCore::GraphicsContextPlatformPrivate::translate):
2318         * platform/win/DragImageCairoWin.cpp:
2319         (WebCore::createDragImageFromImage):  Correct uninitialized value
2320
2321 2008-02-23  Dan Bernstein  <mitz@apple.com>
2322
2323         Reviewed by Dave Hyatt.
2324
2325         - make non-autowrapping text clear floats
2326
2327         Test: fast/text/whitespace/nowrap-clear-float.html
2328
2329         * rendering/RenderBlock.cpp:
2330         (WebCore::RenderBlock::nextFloatBottomBelow): Renamed nearestFloat() to
2331         this and changed to avoid comparing bottom to 0 in each iteration.
2332         (WebCore::RenderBlock::getClearDelta): Updated comment for the rename.
2333         * rendering/RenderBlock.h:
2334         * rendering/bidi.cpp:
2335         (WebCore::RenderBlock::fitBelowFloats): Added. Factored out of
2336         findNextLineBreak() and simplified.
2337         (WebCore::RenderBlock::findNextLineBreak): Changed to call
2338         fitBelowFloats(). Fixed the bug by trying to fit below floats in the
2339         case of non-wrapping text. Removed some redundancy.
2340
2341 2008-02-23  Sam Weinig  <sam@webkit.org>
2342
2343         Reviewed by Oliver Hunt.
2344
2345         Fix for http://bugs.webkit.org/show_bug.cgi?id=17504
2346         Speed up DOM lists array subscription syntax by using the fast 
2347         getOwnPropertySlot and set paths
2348
2349         - 6x speed improvement on Oliver's ImageData put test.
2350
2351         * bindings/scripts/CodeGeneratorJS.pm: Add fast path for getOwnPropertySlot
2352         and put when an indexGetter or indexSetter is used.  We can not use the fast
2353         path if an overridingNameGetter is used as there would be no way to override.
2354
2355 2008-02-23  Kevin Ollivier  <kevino@theolliviers.com>
2356
2357         wx build fix after JSImageData.cpp was added.
2358
2359         * WebCoreSources.bkl:
2360
2361 2008-02-23  Alexey Proskuryakov  <ap@webkit.org>
2362
2363         Windows build fix - move ThreadCondition implementation from WebCore to WTF.
2364
2365         * WebCore.vcproj/WebCore.vcproj:
2366         * platform/win/ThreadConditionWin.cpp: Removed.
2367
2368 2008-02-23  Alexey Proskuryakov  <ap@webkit.org>
2369
2370         Reviewed by Darin.
2371
2372         Move basic threading support from WebCore to WTF.
2373
2374         One call that remains in WebCore is callOnMainThread(), and it has its own header now.
2375
2376         * ForwardingHeaders/wtf/Locker.h: Added.
2377         * ForwardingHeaders/wtf/MessageQueue.h: Added.
2378         * ForwardingHeaders/wtf/Threading.h: Added.
2379         * GNUmakefile.am:
2380         * WebCore.pro:
2381         * WebCore.vcproj/WebCore.vcproj:
2382         * WebCore.xcodeproj/project.pbxproj:
2383         * WebCoreSources.bkl:
2384         * bindings/js/JSCustomSQLTransactionCallback.cpp:
2385         * dom/XMLTokenizer.cpp:
2386         * loader/icon/IconDatabase.cpp:
2387         (WebCore::iconDatabase):
2388         * loader/icon/IconDatabase.h:
2389         * platform/Locker.h: Removed.
2390         * platform/MainThread.h: Copied from WebCore/platform/Threading.h.
2391         (WebCore::initializeThreadingAndMainThread):
2392         * platform/MessageQueue.h: Removed.
2393         * platform/SecurityOrigin.h:
2394         * platform/Threading.h: Removed.
2395         * platform/ThreadingNone.cpp: Removed.
2396         * platform/gtk/MainThreadGtk.cpp: Copied from WebCore/platform/gtk/ThreadingGtk.cpp.
2397         * platform/gtk/ThreadingGtk.cpp: Removed.
2398         * platform/mac/MainThreadMac.mm: Copied from WebCore/platform/mac/Threading.mm.
2399         * platform/mac/Threading.mm: Removed.
2400         * platform/pthreads: Removed.
2401         * platform/pthreads/ThreadingPthreads.cpp: Removed.
2402         * platform/qt/MainThreadQt.cpp: Copied from WebCore/platform/qt/ThreadingQt.cpp.
2403         * platform/qt/ThreadingQt.cpp: Removed.
2404         * platform/sql/SQLValue.h:
2405         * platform/sql/SQLiteAuthorizer.h:
2406         * platform/sql/SQLiteDatabase.h:
2407         * platform/win/MainThreadWin.cpp: Copied from WebCore/platform/win/ThreadingWin.cpp.
2408         (WebCore::initializeThreadingAndMainThread):
2409         * platform/win/MutexWin.cpp: Removed.
2410         * platform/win/ThreadingWin.cpp: Removed.
2411         * platform/wx/MainThreadWx.cpp: Copied from WebCore/platform/wx/ThreadingWx.cpp.
2412         * platform/wx/ThreadingWx.cpp: Removed.
2413         * storage/Database.cpp:
2414         (WebCore::Database::Database):
2415         * storage/Database.h:
2416         * storage/DatabaseTask.h:
2417         * storage/DatabaseThread.h:
2418         * storage/DatabaseTracker.cpp:
2419         * storage/OriginQuotaManager.h:
2420         * storage/SQLError.h:
2421         * storage/SQLResultSet.h:
2422         * storage/SQLStatement.h:
2423         * storage/SQLStatementCallback.h:
2424         * storage/SQLStatementErrorCallback.h:
2425         * storage/SQLTransaction.h:
2426         * storage/SQLTransactionCallback.h:
2427         * storage/SQLTransactionErrorCallback.h:
2428         * webcore-wx.bkl:
2429
2430 2008-02-23  David Kilzer  <ddkilzer@apple.com>
2431
2432         Please clarify licensing for some files
2433         <http://bugs.webkit.org/show_bug.cgi?id=14970>
2434
2435         Reviewed by Darin.
2436
2437         * bindings/objc/WebScriptObject.h: Added Apple BSD-style license.
2438         * bindings/objc/WebScriptObjectPrivate.h: Ditto.
2439         * platform/text/mac/ShapeArabic.c: Added ICU license from WebCore/icu/LICENSE.
2440
2441 2008-02-22  Justin Garcia  <justin.garcia@apple.com>
2442
2443         Reviewed by Anders Carlsson.
2444
2445         <rdar://problem/5714333> Add document.getSelection()
2446         
2447         Add a synonym for window.getSelection() that FF supports.  There were requests in
2448         this bugs dupes to also support the IE only document.selection, but IE's Selection
2449         object is too different than ours currently for that to be safe (specifically, we
2450         don't support enough of IE's TextRange methods on our DOM Range object yet). I
2451         filed <rdar://problem/5761233> to cover that.
2452
2453         * dom/Document.cpp:
2454         (WebCore::Document::getSelection): Added.
2455         * dom/Document.h:
2456         * dom/Document.idl: Ditto.  JS only since this is about web compatibility.
2457
2458 2008-02-22  Oliver Hunt  <oliver@apple.com>
2459
2460         WX build fixes
2461
2462         * WebCoreSources.bkl:
2463
2464 2008-02-22  Oliver Hunt  <oliver@apple.com>
2465
2466         Once more with the cairo/qt/wx build fixing
2467
2468         * platform/graphics/cairo/ImageBufferCairo.cpp:
2469         * platform/graphics/qt/ImageBufferQt.cpp:
2470         * platform/graphics/wx/ImageBufferWx.cpp:
2471
2472 2008-02-22  Mark Rowe  <mrowe@apple.com>
2473
2474         Windows build fix.  Add missing include of DeprecatedCString.h and sort existing includes.
2475
2476         * platform/win/PasteboardWin.cpp:
2477
2478 2008-02-22  Mark Rowe  <mrowe@apple.com>
2479
2480         Speculative Windows build fix.
2481
2482         * platform/win/ClipboardUtilitiesWin.cpp:  Add missing include of DeprecatedCString.h and sort existing includes.
2483         * platform/win/ClipboardWin.cpp:  Ditto.
2484
2485 2008-02-22  Oliver Hunt  <oliver@apple.com>
2486
2487         Build fix for windows, wx and qt
2488
2489         * html/CanvasPixelArray.h:
2490         (WebCore::CanvasPixelArray::set):
2491
2492 2008-02-22  Oliver Hunt  <oliver@apple.com>
2493
2494         Unbreak windows vcproj
2495
2496         * WebCore.vcproj/WebCore.vcproj:
2497
2498 2008-02-22  Oliver Hunt  <oliver@apple.com>
2499
2500         Reviewed by Sam W.
2501
2502         Support Canvas.getImageData and Canvas.createImageData
2503         
2504         This patch adds support for all the pixel reading portions
2505         of the HTML5 Canvas spec.  There are two new types ImageData
2506         and CanvasPixelArray which are used to provide the HTML5
2507         ImageData object, and the required semantics for assignment
2508         to the ImageData data array.
2509         
2510         We only implement the CG version of ImageBuffer::getImageData,
2511         but the logic is null safe, so this will not introduce any
2512         crashes into other platforms, unfortunately it will result in
2513         JS Object detection "lying" on non-CG platforms.
2514
2515         Tests: fast/canvas/canvas-ImageData-behaviour.html
2516                fast/canvas/canvas-getImageData.html
2517
2518         * DerivedSources.make:
2519         * GNUmakefile.am:
2520         * WebCore.pro:
2521         * WebCore.vcproj/WebCore.vcproj:
2522         * WebCore.xcodeproj/project.pbxproj:
2523         * bindings/js/JSCanvasPixelArrayCustom.cpp: Added.
2524         (WebCore::JSCanvasPixelArray::indexGetter):
2525         (WebCore::JSCanvasPixelArray::indexSetter):
2526         (WebCore::toJS):
2527         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2528         * bindings/scripts/CodeGeneratorJS.pm:
2529         * html/CanvasPixelArray.cpp: Added.
2530         (WebCore::CanvasPixelArray::create):
2531         * html/CanvasPixelArray.h: Added.
2532         (WebCore::CanvasPixelArray::data):
2533         (WebCore::CanvasPixelArray::length):
2534         (WebCore::CanvasPixelArray::set):
2535         (WebCore::CanvasPixelArray::get):
2536         * html/CanvasPixelArray.idl: Added.
2537         * html/CanvasRenderingContext2D.cpp:
2538         (WebCore::createEmptyImageData):
2539         (WebCore::CanvasRenderingContext2D::createImageData):
2540         (WebCore::CanvasRenderingContext2D::getImageData):
2541         * html/CanvasRenderingContext2D.h:
2542         * html/CanvasRenderingContext2D.idl:
2543         * html/HTMLCanvasElement.cpp:
2544         (WebCore::HTMLCanvasElement::convertLogicalToDevice):
2545         (WebCore::HTMLCanvasElement::createImageBuffer):
2546         * html/HTMLCanvasElement.h:
2547         * html/ImageData.cpp: Added.
2548         (WebCore::ImageData::create):
2549         (WebCore::ImageData::ImageData):
2550         * html/ImageData.h: Added.
2551         (WebCore::ImageData::width):
2552         (WebCore::ImageData::height):
2553         (WebCore::ImageData::data):
2554         * html/ImageData.idl: Added.
2555         * platform/graphics/ImageBuffer.h:
2556         * platform/graphics/cairo/ImageBufferCairo.cpp:
2557         (WebCore::ImageBuffer::getImageData):
2558         * platform/graphics/cg/ImageBufferCG.cpp:
2559         (WebCore::ImageBuffer::getImageData):
2560         * platform/graphics/qt/ImageBufferQt.cpp:
2561         (WebCore::ImageBuffer::getImageData):
2562         * platform/graphics/wx/ImageBufferWx.cpp:
2563         (WebCore::ImageBuffer::getImageData):
2564
2565 2008-02-22  Sam Weinig  <sam@webkit.org>
2566
2567         Rubber-stamped by Adam Roben.
2568
2569         Rid the project of the Devil known as DeprecatedString!
2570
2571         * GNUmakefile.am:
2572         * WebCore.base.exp:
2573         * WebCore.pro:
2574         * WebCore.vcproj/WebCore.vcproj:
2575         * WebCore.xcodeproj/project.pbxproj:
2576         * WebCoreSources.bkl:
2577         * dom/Node.h:
2578         * html/HTMLFormElement.cpp:
2579         * platform/DeprecatedString.cpp: Removed.
2580         * platform/DeprecatedString.h: Removed.
2581         * platform/graphics/qt/IconQt.cpp:
2582         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
2583         * platform/gtk/CookieJarGtk.cpp:
2584         * platform/gtk/CursorGtk.cpp:
2585         * platform/gtk/KeyEventGtk.cpp:
2586         * platform/mac/DeprecatedStringMac.mm: Removed.
2587         * platform/network/qt/ResourceHandleQt.cpp:
2588         * platform/network/win/CookieJarWin.cpp:
2589         (WebCore::cookies):
2590         * platform/qt/ClipboardQt.cpp:
2591         * platform/qt/CookieJarQt.cpp:
2592         * platform/qt/CursorQt.cpp:
2593         * platform/symbian/DeprecatedStringSymbian.cpp: Removed.
2594         * platform/text/AtomicString.cpp:
2595         * platform/text/AtomicString.h:
2596         * platform/text/PlatformString.h:
2597         * platform/text/String.cpp:
2598         * platform/text/StringImpl.cpp:
2599         * platform/text/qt/StringQt.cpp:
2600         (WebCore::String::String):
2601         * platform/text/wx/StringWx.cpp:
2602         * platform/win/BString.cpp:
2603         * platform/win/BString.h:
2604         * platform/win/PasteboardWin.cpp:
2605
2606 2008-02-22  Sam Weinig  <sam@webkit.org>
2607
2608         Reviewed by Geoff Garen.
2609
2610         - Remove use of DeprecatedString in CSSStyleSelector.
2611
2612         * css/CSSStyleSelector.cpp:
2613         (WebCore::findHash): Removed.  Use find instead.
2614         (WebCore::findSlashDotDotSlash): Changed to take a UChar* and a length.
2615         (WebCore::findSlashSlash): Ditto.
2616         (WebCore::findSlashDotSlash): Ditto.
2617         (WebCore::containsColonSlashSlash): Ditto.
2618         (WebCore::cleanPath): Change to operate on a String.
2619         (WebCore::checkPseudoState): Changed to use a Vector as a buffer.
2620
2621 2008-02-22  Geoffrey Garen  <ggaren@apple.com>
2622
2623         Reviewed by Sam Weinig.
2624         
2625         Fixed <rdar://problem/5057509> Repro leak of JSXMLHttpRequest and
2626         associated objects @ www.viamichelin.it, which was probably an underlying
2627         cause of <rdar://problem/5744037> Gmail out of memory (17455)
2628         
2629         If SubresourceLoader::create returned NULL, we would ref() / gcProtect()
2630         the XMLHttpRequest but think we hadn't, therefore never
2631         calling deref() / gcUnprotect().
2632         
2633         This could happen at gmail.com, since gmail.com attempts to send
2634         XMLHttpRequests from unload handlers in order to gather usage statistics.
2635         (According to comments in the code, SubresourceLoader::create returns
2636         NULL when called from an unload handler.)
2637
2638         The solution is to ref() / gcProtect() only if SubresourceLoader::create
2639         doesn't return NULL. This make sense, since we only need to protect the
2640         request as long as it has an outstanding network transaction.
2641         
2642         * xml/XMLHttpRequest.cpp:
2643         (WebCore::XMLHttpRequest::XMLHttpRequest):
2644         (WebCore::XMLHttpRequest::send):
2645
2646 2008-02-22  Darin Adler  <darin@apple.com>
2647
2648         Reviewed, tweaked and landed by Sam.
2649
2650         - Make RegularExpression operate on Strings instead of DeprecatedStrings.
2651
2652         * dom/DOMImplementation.cpp:
2653         (WebCore::DOMImplementation::isXMLMIMEType): Use string instead of DeprecatedString
2654         to build up the RegularExpression.
2655         * page/Frame.cpp:
2656         (WebCore::createRegExpForLabels): Use String instead of DeprecatedString.
2657         (WebCore::Frame::searchForLabelsAboveCell): Ditto.
2658         (WebCore::Frame::searchForLabelsBeforeElement): Ditto.
2659         (WebCore::Frame::matchLabelsAgainstElement): Ditto.
2660         * page/Frame.h:
2661         * page/mac/FrameMac.mm:
2662         (WebCore::regExpForLabels): Ditto.
2663         (WebCore::Frame::searchForNSLabelsAboveCell): Ditto.
2664         (WebCore::Frame::searchForLabelsBeforeElement): Ditto.
2665         (WebCore::Frame::matchLabelsAgainstElement): Ditto.
2666
2667         * platform/text/RegularExpression.cpp:
2668         (WebCore::RegularExpression::Private::Private):
2669         (WebCore::RegularExpression::Private::compile):
2670         (WebCore::RegularExpression::RegularExpression):
2671         (WebCore::RegularExpression::operator=):
2672         (WebCore::RegularExpression::pattern):
2673         (WebCore::RegularExpression::match):
2674         (WebCore::RegularExpression::search):
2675         (WebCore::RegularExpression::searchRev):
2676         (WebCore::replace): Added.
2677         * platform/text/RegularExpression.h:
2678         Change functions to take Strings as input instead of DeprecatedStrings and
2679         reduce the complexity of the class by removing unneeded globbing support.
2680
2681 2008-02-22  Jon Honeycutt  <jhoneycutt@apple.com>
2682
2683         Reviewed by Anders.
2684
2685         <rdar://problem/5760360> REGRESSION(r30376): Crash loading plugin page
2686         during stress test (after only 5 min) - null dereference
2687
2688         Full-frame plug-ins create PluginStream objects without loaders, as the
2689         PluginView receives the loading callbacks. We were trying to call
2690         setDefersLoading on these null pointers.
2691
2692         * plugins/PluginStream.cpp:
2693         (WebCore::PluginStream::startStream): Add null check.
2694         (WebCore::PluginStream::destroyStream): Same.
2695         (WebCore::PluginStream::deliverData): Same.
2696
2697 2008-02-22  Darin Adler  <darin@apple.com>
2698
2699         Reviewed and tweaked by Jon Honeycutt. Reviewed and landed by Sam.
2700
2701         - Remove uses of DeprecatedString in Windows plugin code.
2702
2703         * plugins/win/PluginPackageWin.cpp:
2704         (WebCore::getVersionInfo): Cleanup formatting.
2705         (WebCore::PluginPackage::freeLibraryTimerFired): Remove un-needed variable name.
2706         (WebCore::PluginPackage::storeFileVersion): Move casts.
2707         (WebCore::PluginPackage::fetchInfo): Use OwnArrayPtr and switch to more efficient
2708         use of Vectors.
2709         (WebCore::PluginPackage::load): Fix whitespace.
2710         (WebCore::PluginPackage::hash): Make the hashCodes const
2711         * plugins/win/PluginViewWin.cpp:
2712         (WebCore::makeURL): Use String instead of DeprecatedString.
2713         (WebCore::parseRFC822HeaderFields): Ditto.
2714         (WebCore::PluginView::handlePost): Ditto.
2715         (WebCore::PluginView::status): Ditto.
2716
2717 2008-02-22  Darin Adler  <darin@apple.com>
2718
2719         Reviewed, tweaked and landed by Sam.
2720
2721         - Don't use DeprecatedString in HTMLTokenizer.
2722
2723         * html/HTMLTokenizer.cpp:
2724         (WebCore::HTMLTokenizer::finish):
2725         * platform/text/PlatformString.h:
2726         (WebCore::find):
2727
2728 2008-02-21  Sam Weinig  <sam@webkit.org>
2729
2730         Reviewed by Anders Carlsson.
2731
2732         Fix for <rdar://problem/5757946>
2733
2734         - Parse URLs before checking whether they are javascript: urls
2735           (which require security checks).
2736
2737         * bindings/js/JSAttrCustom.cpp:
2738         (WebCore::JSAttr::setValue):
2739         * bindings/js/JSElementCustom.cpp:
2740         (WebCore::allowSettingSrcToJavascriptURL):
2741         * bindings/js/JSHTMLFrameElementCustom.cpp:
2742         (WebCore::allowSettingJavascriptURL):
2743         * bindings/js/JSHTMLIFrameElementCustom.cpp:
2744         (WebCore::JSHTMLIFrameElement::setSrc):
2745
2746 2008-02-21  Ada Chan  <adachan@apple.com>
2747
2748         <rdar://problem/5757873> Buffer overrun in DeprecatedCString::find() in WebCore
2749         We could get a buffer overrun in DeprecatedCString::find() if the end of the
2750         string matches a beginning portion of the substring, for example, if string is
2751         "a" but the substring is "ab".
2752         The code as is also will not match things correctly under certain situations
2753         since the inner while loop increments the index. For example, we wouldn't find
2754         a match if the string is "aab..." and the substring is "ab".  Changed the 
2755         inner while loop to increment a temporary index into str.
2756         
2757         Test: fast/loader/charset-parse.html
2758
2759         Reviewed by Dan Berstein.
2760
2761         * platform/DeprecatedCString.cpp:
2762         (WebCore::DeprecatedCString::find):
2763
2764 2008-02-21  David Hyatt  <hyatt@apple.com>
2765
2766         Fix for bug 17301.  CSS media queries need to use the correct viewport
2767         when contained in documents inside iframes (rather than always using the
2768         top-level document's viewport).  CSS media queries based on the viewport
2769         also needed to be dynamic and update as you resize the window (this is
2770         a HOT feature). :)
2771
2772         This patch gets Acid3 up to 86/100 with 3 colored boxes filled in.
2773
2774         Reviewed by olliej
2775
2776         Added fast/media/viewport-media-query.html
2777
2778         * css/CSSStyleSelector.cpp:
2779         (WebCore::CSSStyleSelector::CSSStyleSelector):
2780         (WebCore::CSSStyleSelector::addViewportDependentMediaQueryResult):
2781         (WebCore::CSSStyleSelector::affectedByViewportChange):
2782         * css/CSSStyleSelector.h:
2783         (WebCore::MediaQueryResult::MediaQueryResult):
2784         * css/MediaQueryEvaluator.cpp:
2785         (WebCore::MediaQueryEvaluator::MediaQueryEvaluator):
2786         (WebCore::MediaQueryEvaluator):
2787         (WebCore::MediaQueryEvaluator::eval):
2788         (WebCore::colorMediaFeatureEval):
2789         (WebCore::monochromeMediaFeatureEval):
2790         (WebCore::device_aspect_ratioMediaFeatureEval):
2791         (WebCore::device_pixel_ratioMediaFeatureEval):
2792         (WebCore::gridMediaFeatureEval):
2793         (WebCore::device_heightMediaFeatureEval):
2794         (WebCore::device_widthMediaFeatureEval):
2795         (WebCore::heightMediaFeatureEval):
2796         (WebCore::widthMediaFeatureEval):
2797         (WebCore::min_colorMediaFeatureEval):
2798         (WebCore::max_colorMediaFeatureEval):
2799         (WebCore::min_monochromeMediaFeatureEval):
2800         (WebCore::max_monochromeMediaFeatureEval):
2801         (WebCore::min_device_aspect_ratioMediaFeatureEval):
2802         (WebCore::max_device_aspect_ratioMediaFeatureEval):
2803         (WebCore::min_device_pixel_ratioMediaFeatureEval):
2804         (WebCore::max_device_pixel_ratioMediaFeatureEval):
2805         (WebCore::min_heightMediaFeatureEval):
2806         (WebCore::max_heightMediaFeatureEval):
2807         (WebCore::min_widthMediaFeatureEval):
2808         (WebCore::max_widthMediaFeatureEval):
2809         (WebCore::min_device_heightMediaFeatureEval):
2810         (WebCore::max_device_heightMediaFeatureEval):
2811         (WebCore::min_device_widthMediaFeatureEval):
2812         (WebCore::max_device_widthMediaFeatureEval):
2813         * css/MediaQueryEvaluator.h:
2814         * css/MediaQueryExp.cpp:
2815         (WebCore::MediaQueryExp::~MediaQueryExp):
2816         * css/MediaQueryExp.h:
2817         (WebCore::MediaQueryExp::value):
2818         (WebCore::MediaQueryExp::isViewportDependent):
2819         * html/HTMLMediaElement.cpp:
2820         (WebCore::HTMLMediaElement::pickMedia):
2821         * page/FrameView.cpp:
2822         (WebCore::FrameView::layout):
2823
2824 2008-02-21  Anders Carlsson  <andersca@apple.com>
2825
2826         Reviewed by Sam.
2827
2828         Make more classes start out with a refcount of 1.
2829
2830         * dom/QualifiedName.cpp:
2831         (WebCore::QNameComponentsTranslator::translate):
2832         (WebCore::QualifiedName::QualifiedName):
2833         * dom/QualifiedName.h:
2834         (WebCore::QualifiedName::QualifiedNameImpl::create):
2835         (WebCore::QualifiedName::QualifiedNameImpl::QualifiedNameImpl):
2836         * history/BackForwardList.cpp:
2837         (WebCore::BackForwardList::BackForwardList):
2838         * history/BackForwardList.h:
2839         (WebCore::BackForwardList::create):
2840         * page/Page.cpp:
2841         (WebCore::Page::Page):
2842         * platform/text/CString.cpp:
2843         (WebCore::CString::init):
2844         (WebCore::CString::newUninitialized):
2845         (WebCore::CString::copyBufferIfNeeded):
2846         * platform/text/CString.h:
2847         (WebCore::CStringBuffer::create):
2848         (WebCore::CStringBuffer::CStringBuffer):
2849
2850 2008-02-21  Kevin Ollivier  <kevino@theolliviers.com>
2851
2852         wx build fix for the domString() -> string() rename in r30443.
2853
2854         * platform/graphics/wx/FontPlatformDataWx.cpp:
2855         (WebCore::FontPlatformData::FontPlatformData):
2856
2857 2008-02-21  Antti Koivisto  <antti@apple.com>
2858
2859         Reviewed by Sam Weinig.
2860
2861         <rdar://problem/5753789>
2862         REGRESSION: 1.5% -2% Sunspider regression from r30009 (ebay photo upload hang)
2863         
2864         Ensure all versions of allowsAccessFrom are inlined to single functions. 
2865         This is a 2% win in browser hosted Sunspider. 
2866
2867         * bindings/js/kjs_window.cpp:
2868         (KJS::Window::allowsAccessFrom):
2869         (KJS::Window::allowsAccessFromPrivate):
2870         * bindings/js/kjs_window.h:
2871
2872 2008-02-21  Dan Bernstein  <mitz@apple.com>
2873
2874         Reviewed by Sam Weinig.
2875
2876         - minor cleanup
2877
2878         * rendering/bidi.cpp:
2879         (WebCore::bidiNext): Removed redundant isBR() check -- isText() returns
2880         true for RenderLineBreak.
2881         (WebCore::bidiFirst): Ditto.
2882         (WebCore::shouldSkipWhitespaceAfterStartObject):
2883         (WebCore::RenderBlock::findNextLineBreak):
2884
2885 2008-02-21  Geoffrey Garen  <ggaren@apple.com>
2886
2887         Reviewed by David Harrison.
2888         
2889         Fixed <rdar://problem/5756125> REGRESSION: A crash occurs at 
2890         WebCore::Frame::scriptProxy() when completing a search with Package Tracker widget
2891
2892         Test: fast/dom/script-element-without-frame-crash.html
2893
2894         * html/HTMLTokenizer.cpp:
2895         (WebCore::HTMLTokenizer::parseTag): Added back a NULL check that was
2896         accidentally removed in r30325.
2897
2898 2008-02-21  Rodney Dawes  <dobey@wayofthemonkey.com>
2899
2900         GTK+ build fix. s/domString()/string()/
2901
2902         * platform/graphics/gtk/FontPlatformDataGtk.cpp:
2903         (FontPlatformData::FontPlatformData):
2904
2905 2008-02-20  Dan Bernstein  <mitz@apple.com>
2906
2907         Reviewed by Dave Hyatt.
2908
2909         - fix http://bugs.webkit.org/show_bug.cgi?id=17465
2910           REGRESSION: <DIV> tokenized into Div if still searching for DOCTYPE
2911
2912         Test: fast/tokenizer/doctype-search-reset.html
2913
2914         * html/HTMLTokenizer.cpp:
2915         (WebCore::HTMLTokenizer::parseTag):
2916
2917 2008-02-20  Dan Bernstein  <mitz@apple.com>
2918
2919         Reviewed by Dave Hyatt.
2920
2921         - fix http://bugs.webkit.org/show_bug.cgi?id=17464
2922           REGRESSION: Crash in RenderBlock::findNextLineBreak reading r30444 commit email in GMail
2923
2924         Test: fast/text/wbr-in-pre-crash.html
2925
2926         * rendering/bidi.cpp:
2927         (WebCore::RenderBlock::findNextLineBreak):
2928
2929 2008-02-20  Oliver Hunt  <oliver@apple.com>
2930
2931         Reviewed by Hyatt.
2932
2933         Bug 17303: Canvas crash in ImageBuffer
2934
2935         We handle a null GraphicsContext everywhere, but we weren't checking for 
2936         a null ImageBuffer, which is what will result in a null GraphicsContext in
2937         the first place.
2938
2939         Test: fast/canvas/access-zero-sized-canvas.html
2940
2941         * html/HTMLCanvasElement.cpp:
2942
2943 2008-02-20  David Hyatt  <hyatt@apple.com>
2944
2945         Fix the layout test failure that never should have passed in the first
2946         place by making changes to media lists actually result in the recomputation
2947         of the style selector.  Now it passes for the right reasons and not because
2948         of dumb luck.
2949
2950         Reviewed by Sam Weinig
2951
2952         * css/MediaList.cpp:
2953         (WebCore::MediaList::deleteMedium):
2954         (WebCore::MediaList::setMediaText):
2955         (WebCore::MediaList::appendMedium):
2956         (WebCore::MediaList::notifyChanged):
2957         * css/MediaList.h:
2958         * dom/Document.cpp:
2959         (WebCore::Document::attach):
2960
2961 2008-02-20  Darin Adler  <darin@apple.com>
2962
2963         Reviewed, tweaked and landed by Sam.
2964
2965         - make markup functions not use DeprecatedString.
2966
2967         * editing/markup.cpp:
2968         (WebCore::append): Added.
2969         (WebCore::escapeContentText): Build up string using a Vector.
2970         (WebCore::appendStartMarkup): Use String instead of DeprecatedString.
2971
2972 2008-02-20  Darin Adler  <darin@apple.com>
2973
2974         Reviewed, tweaked and landed by Sam.
2975
2976         - make TextIterator use a Vector instead of a DeprecatedString.
2977
2978         * editing/TextIterator.cpp:
2979         (WebCore::CharacterIterator::string): Build up the String using a
2980         Vector.
2981         (WebCore::WordAwareIterator::advance): Switch to using Vector functions.
2982         (WebCore::WordAwareIterator::length): Ditto.
2983         (WebCore::WordAwareIterator::characters): Ditto.
2984         * editing/TextIterator.h: Use a Vector<UChar> for the buffer instead
2985         of DeprecatedString.
2986
2987 2008-02-20  Darin Adler  <darin@apple.com>
2988
2989         Reviewed, tweaked and landed by Sam.
2990
2991         - make HTMLInterchange return a String instead of a DeprecatedString
2992
2993         * editing/HTMLInterchange.cpp:
2994         (WebCore::): Return a String from convertedSpaceString.
2995         (WebCore::convertHTMLTextToInterchangeFormat): Use a Vector instead of
2996         a DeprecatedString to build up the return String.
2997         * editing/HTMLInterchange.h:
2998
2999 2008-02-20  Eric Seidel  <eric@webkit.org>
3000
3001         Reviewed by Oliver.
3002
3003         Remove m_drawingContext and change m_data to m_imageBuffer
3004
3005         * html/HTMLCanvasElement.cpp:
3006         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
3007         (WebCore::HTMLCanvasElement::reset):
3008         (WebCore::HTMLCanvasElement::paint):
3009         (WebCore::HTMLCanvasElement::createImageBuffer):
3010         (WebCore::HTMLCanvasElement::buffer):
3011         (WebCore::HTMLCanvasElement::createPlatformImage):
3012         * html/HTMLCanvasElement.h:
3013
3014 2008-02-20  Anders Carlsson  <andersca@apple.com>
3015
3016         Reviewed by Sam.
3017
3018         Rename AtomicString::domString() to AtomicString::string().
3019         
3020         * css/CSSComputedStyleDeclaration.cpp:
3021         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3022         * css/CSSFontSelector.cpp:
3023         (WebCore::CSSFontSelector::getFontData):
3024         * dom/Attr.cpp:
3025         (WebCore::Attr::createTextChild):
3026         * dom/Comment.cpp:
3027         (WebCore::Comment::nodeName):
3028         * dom/Document.cpp:
3029         (WebCore::Document::recalcStyleSelector):
3030         (WebCore::Document::setHTMLWindowEventListener):
3031         (WebCore::Document::formElementsState):
3032         * dom/StyledElement.cpp:
3033         (WebCore::StyledElement::parseMappedAttribute):
3034         * dom/Text.cpp:
3035         (WebCore::Text::nodeName):
3036         * editing/SelectionController.cpp:
3037         (WebCore::SelectionController::debugRenderer):
3038         * html/HTMLCollection.cpp:
3039         (WebCore::HTMLCollection::checkForNameMatch):
3040         * html/HTMLElement.cpp:
3041         (WebCore::HTMLElement::nodeName):
3042         (WebCore::HTMLElement::setHTMLEventListener):
3043         * html/HTMLFormCollection.cpp:
3044         (WebCore::HTMLFormCollection::getNamedFormItem):
3045         * html/HTMLImageElement.cpp:
3046         (WebCore::HTMLImageElement::parseMappedAttribute):
3047         (WebCore::HTMLImageElement::isURLAttribute):
3048         * html/HTMLLinkElement.cpp:
3049         (WebCore::HTMLLinkElement::parseMappedAttribute):
3050         (WebCore::HTMLLinkElement::tokenizeRelAttribute):
3051         * html/HTMLObjectElement.cpp:
3052         (WebCore::HTMLObjectElement::isURLAttribute):
3053         (WebCore::HTMLObjectElement::containsJavaApplet):
3054         * html/HTMLParamElement.cpp:
3055         (WebCore::HTMLParamElement::isURLAttribute):
3056         * html/HTMLParser.cpp:
3057         (WebCore::HTMLParser::handleIsindex):
3058         * html/HTMLScriptElement.cpp:
3059         (WebCore::HTMLScriptElement::insertedIntoDocument):
3060         (WebCore::HTMLScriptElement::shouldExecuteAsJavaScript):
3061         * html/HTMLStyleElement.cpp:
3062         (WebCore::HTMLStyleElement::parseMappedAttribute):
3063         * html/HTMLTokenizer.cpp:
3064         (WebCore::HTMLTokenizer::parseTag):
3065         * html/HTMLViewSourceDocument.cpp:
3066         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
3067         * loader/FrameLoader.cpp:
3068         (WebCore::FrameLoader::saveDocumentState):
3069         * page/FrameTree.cpp:
3070         (WebCore::FrameTree::uniqueChildName):
3071         * platform/text/AtomicString.h:
3072         (WebCore::AtomicString::string):
3073         (WebCore::AtomicString::contains):
3074         (WebCore::AtomicString::find):
3075         (WebCore::AtomicString::startsWith):
3076         (WebCore::AtomicString::endsWith):
3077         * rendering/RenderPartObject.cpp:
3078         (WebCore::RenderPartObject::updateWidget):
3079         * svg/SVGElement.cpp:
3080         (WebCore::SVGElement::addSVGEventListener):
3081         * svg/SVGSVGElement.cpp:
3082         (WebCore::SVGSVGElement::addSVGWindowEventListener):
3083         * xml/XPathFunctions.cpp:
3084         (WebCore::XPath::FunLocalName::evaluate):
3085         (WebCore::XPath::FunNamespaceURI::evaluate):
3086         (WebCore::XPath::FunName::evaluate):
3087
3088 2008-02-20  Brent Fulgham  <bfulgham@gmail.com>
3089
3090         Reviewed by Dan.
3091
3092         http://bugs.webkit.org/show_bug.cgi?id=17336
3093         Provide implementations for Windows (Cairo) build of WebKit that
3094         handles font formatting.
3095         - Split font implementation files to allow maximal code sharing
3096           between CG and Cairo back-ends. 
3097
3098         * WebCore.vcproj/WebCore.vcproj:
3099         * platform/graphics/SimpleFontData.h:   Add signatures for private win
3100           initialization functions.
3101         * platform/graphics/win/FontCacheWin.cpp:
3102         (WebCore::FontCache::platformInit):
3103         (WebCore::FontCache::createFontPlatformData):
3104         * platform/graphics/win/FontCairoWin.cpp: Removed.  Universal version
3105           is now part of platform/graphics/cairo.
3106         * platform/graphics/win/FontCustomPlatformDataCairo.cpp: Added.
3107         (WebCore::FontCustomPlatformDataCairo::~FontCustomPlatformDataCairo):
3108         (WebCore::FontCustomPlatformDataCairo::fontPlatformData):
3109         (WebCore::releaseData):
3110         (WebCore::createFontCustomPlatformData):
3111         * platform/graphics/win/FontCustomPlatformDataCairo.h: Added.
3112         (WebCore::FontCustomPlatformDataCairo::FontCustomPlatformDataCairo):
3113         * platform/graphics/win/FontPlatformData.h:
3114         (WebCore::FontPlatformData::FontPlatformData):
3115         (WebCore::FontPlatformData::fontFace):
3116         (WebCore::FontPlatformData::scaledFont):
3117         (WebCore::FontPlatformData::operator==):
3118         * platform/graphics/win/FontPlatformDataCGWin.cpp: Copied from WebCore/platform/graphics/win/FontPlatformDataWin.cpp.
3119         (WebCore::FontPlatformData::platformDataInit):
3120         * platform/graphics/win/FontPlatformDataCairoWin.cpp: Added.
3121         (WebCore::FontPlatformData::platformDataInit):
3122         (WebCore::FontPlatformData::FontPlatformData):
3123         (WebCore::FontPlatformData::setFont):
3124         * platform/graphics/win/FontPlatformDataWin.cpp:  Moved CG-specific
3125           code to FontPlatformDataCG.cpp.
3126         (WebCore::FontPlatformData::FontPlatformData):
3127         * platform/graphics/win/GlyphPageTreeNodeCGWin.cpp: Copied from WebCore/platform/graphics/win/GlyphPageTreeNodeWin.cpp.
3128         * platform/graphics/win/GlyphPageTreeNodeCairoWin.cpp: Copied from WebCore/platform/graphics/win/GlyphPageTreeNodeWin.cpp.
3129         (WebCore::GlyphPage::fill):
3130         * platform/graphics/win/GlyphPageTreeNodeWin.cpp: Removed.  Replaced
3131           with CG- and Cairo-specific versions.
3132         * platform/graphics/win/SimpleFontDataCGWin.cpp:
3133         (WebCore::SimpleFontData::platformInit):
3134         (WebCore::SimpleFontData::platformDestroy):
3135         (WebCore::SimpleFontData::platformWidthForGlyph):
3136         * platform/graphics/win/SimpleFontDataCairoWin.cpp:
3137         (WebCore::SimpleFontData::platformInit):
3138         (WebCore::SimpleFontData::platformDestroy):
3139         (WebCore::SimpleFontData::platformWidthForGlyph):
3140         (WebCore::SimpleFontData::setFont):
3141         * platform/graphics/win/SimpleFontDataWin.cpp:
3142         (WebCore::SimpleFontData::initGDIFont):
3143         (WebCore::SimpleFontData::platformCommonDestroy):
3144         (WebCore::SimpleFontData::widthForGDIGlyph):
3145
3146 2008-02-20  Darin Adler  <darin@apple.com>
3147
3148         Reviewed by Sam.
3149
3150         * dom/Node.h: Took out unneeded forward declaration of TextStream.
3151
3152 2008-02-20  Darin Adler  <darin@apple.com>
3153
3154         Reviewed by Sam.
3155
3156         * rendering/RenderObject.h: Took out unneeded forward declaration of TextStream.
3157
3158 2008-02-20  David Hyatt  <hyatt@apple.com>
3159
3160         Fix for bug 16760, incorrect <object> MIME type handling and fallback
3161         handling.
3162
3163         Reviewed by darin
3164
3165         * html/HTMLImageLoader.cpp:
3166         (WebCore::HTMLImageLoader::notifyFinished):
3167         If the image had an error, make sure to do <object> fallback.
3168
3169         * html/HTMLObjectElement.cpp:
3170         (WebCore::HTMLObjectElement::renderFallbackContent):
3171         Before doing fallback check if there is a MIME type mismatch between
3172         an image type and a non-image type.  If so, detach and re-attach after
3173         storing the correct MIME type.
3174
3175         * loader/loader.cpp:
3176         (WebCore::Loader::didReceiveData):
3177         Consider it an error when a 404 is encountered on a CachedResource load.
3178
3179 2008-02-20  Anders Carlsson  <andersca@apple.com>
3180
3181         Reviewed by Sam.
3182
3183         StringImpl constructors used by AtomicString should start with a refcount of 1.
3184         
3185         * platform/text/AtomicString.cpp:
3186         (WebCore::AtomicString::add):
3187         * platform/text/AtomicString.h:
3188         * platform/text/StringImpl.cpp:
3189         (WebCore::StringImpl::StringImpl):
3190
3191 2008-02-20  Darin Adler  <darin@apple.com>
3192
3193         * bindings/js/kjs_navigator.cpp:
3194         (WebCore::needsYouTubeQuirk): Tweak comments.
3195
3196 2008-02-20  Anders Carlsson  <andersca@apple.com>
3197
3198         Reviewed by Darin.
3199
3200         Change all refcounted classes in page/ to start with a refcount of 1.
3201
3202         * page/BarInfo.cpp:
3203         (WebCore::BarInfo::BarInfo):
3204         * page/BarInfo.h:
3205         (WebCore::BarInfo::create):
3206         * page/Console.cpp:
3207         (WebCore::Console::Console):
3208         * page/Console.h:
3209         (WebCore::Console::create):
3210         * page/DOMSelection.cpp:
3211         (WebCore::DOMSelection::DOMSelection):
3212         * page/DOMSelection.h:
3213         (WebCore::DOMSelection::create):
3214         * page/DOMWindow.cpp:
3215         (WebCore::DOMWindow::DOMWindow):
3216         (WebCore::DOMWindow::screen):
3217         (WebCore::DOMWindow::history):
3218         (WebCore::DOMWindow::locationbar):
3219         (WebCore::DOMWindow::menubar):
3220         (WebCore::DOMWindow::personalbar):
3221         (WebCore::DOMWindow::scrollbars):
3222         (WebCore::DOMWindow::statusbar):
3223         (WebCore::DOMWindow::toolbar):
3224         (WebCore::DOMWindow::console):
3225         (WebCore::DOMWindow::getSelection):
3226         * page/DOMWindow.h:
3227         (WebCore::DOMWindow::create):
3228         * page/Frame.cpp:
3229         (WebCore::Frame::domWindow):
3230         * page/History.cpp:
3231         (WebCore::History::History):
3232         * page/History.h:
3233         (WebCore::History::create):
3234         * page/InspectorController.cpp:
3235         (WebCore::InspectorResource::create):
3236         (WebCore::InspectorResource::InspectorResource):
3237         (WebCore::InspectorDatabaseResource::create):
3238         (WebCore::InspectorDatabaseResource::InspectorDatabaseResource):
3239         (WebCore::InspectorController::didLoadResourceFromMemoryCache):
3240         (WebCore::InspectorController::identifierForInitialRequest):
3241         (WebCore::InspectorController::didOpenDatabase):
3242         * page/Plugin.h:
3243         (WebCore::Plugin::create):
3244         (WebCore::Plugin::Plugin):
3245         * page/Screen.cpp:
3246         (WebCore::Screen::Screen):
3247         * page/Screen.h:
3248         (WebCore::Screen::create):
3249
3250 2008-02-20  Sam Weinig  <sam@webkit.org>
3251
3252         Reviewed by Darin and Geoff.
3253
3254         - <rdar://problem/5754378> work around missing video on YouTube front page with a site-specific hack
3255
3256         * WebCore.base.exp: Updated.
3257
3258         * bindings/js/kjs_navigator.cpp:
3259         (WebCore::needsYouTubeQuirk): Added. Return true on Windows only when the quirk is needed.
3260         (WebCore::Navigator::getValueProperty): For the appVersion property, if needsYouTubeQuirk
3261         return true, then return the empty string.
3262
3263         * page/Settings.cpp:
3264         (WebCore::Settings::Settings): Set m_needsSiteSpecificQuirks to false.
3265         (WebCore::Settings::setNeedsSiteSpecificQuirks): Added.
3266         * page/Settings.h: Added m_needsSiteSpecificQuirks.
3267         (WebCore::Settings::needsSiteSpecificQuirks): Added.
3268
3269 2008-02-20  David Hyatt  <hyatt@apple.com>
3270
3271         Fix for bug 12751, doctype nodes aren't part of the Document (Acid3).
3272
3273         Reviewed by Sam Weinig
3274
3275         Many tests added in fast/doctypes.
3276
3277         * dom/DOMImplementation.cpp:
3278         (WebCore::DOMImplementation::createDocument):
3279         (WebCore::DOMImplementation::createHTMLDocument):
3280         * dom/Document.cpp:
3281         (WebCore::Document::Document):
3282         (WebCore::Document::setDocType):
3283         (WebCore::Document::attach):
3284         (WebCore::Document::getImageMap):
3285         * dom/Document.h:
3286         (WebCore::Document::doctype):
3287         (WebCore::Document::):
3288         (WebCore::Document::determineParseMode):
3289         (WebCore::Document::setParseMode):
3290         (WebCore::Document::parseMode):
3291         (WebCore::Document::inCompatMode):
3292         (WebCore::Document::inAlmostStrictMode):
3293         (WebCore::Document::inStrictMode):
3294         * dom/DocumentType.cpp:
3295         (WebCore::DocumentType::cloneNode):
3296         (WebCore::DocumentType::insertedIntoDocument):
3297         (WebCore::DocumentType::removedFromDocument):
3298         * dom/DocumentType.h:
3299         * dom/Node.cpp:
3300         (WebCore::Node::childAllowed):
3301         * dom/StyledElement.cpp:
3302         (WebCore::StyledElement::attributeChanged):
3303         * dom/XMLTokenizer.cpp:
3304         (WebCore::XMLTokenizer::internalSubset):
3305         (WebCore::):
3306         * editing/markup.cpp:
3307         (WebCore::appendStartMarkup):
3308         * html/HTMLAppletElement.cpp:
3309         (WebCore::HTMLAppletElement::createRenderer):
3310         * html/HTMLDocument.cpp:
3311         (WebCore::HTMLDocument::HTMLDocument):
3312         (WebCore::HTMLDocument::childAllowed):
3313         (WebCore::HTMLDocument::determineParseMode):
3314         * html/HTMLDocument.h:
3315         * html/HTMLMapElement.cpp:
3316         (WebCore::HTMLMapElement::parseMappedAttribute):
3317         * html/HTMLParamElement.cpp:
3318         (WebCore::HTMLParamElement::parseMappedAttribute):
3319         * html/HTMLParser.cpp:
3320         (WebCore::HTMLParser::parseDoctypeToken):
3321         * html/HTMLParser.h:
3322         * html/HTMLTokenizer.cpp:
3323         (WebCore::HTMLTokenizer::reset):
3324         (WebCore::HTMLTokenizer::parseDoctype):
3325         (WebCore::HTMLTokenizer::parseTag):
3326         (WebCore::HTMLTokenizer::write):
3327         (WebCore::HTMLTokenizer::finish):
3328         (WebCore::HTMLTokenizer::processDoctypeToken):
3329         * html/HTMLTokenizer.h:
3330         (WebCore::):
3331         (WebCore::DoctypeToken::DoctypeToken):
3332         (WebCore::DoctypeToken::reset):
3333         (WebCore::DoctypeToken::state):
3334         (WebCore::DoctypeToken::setState):
3335         (WebCore::HTMLTokenizer::State::inDoctype):
3336         (WebCore::HTMLTokenizer::State::setInDoctype):
3337         (WebCore::HTMLTokenizer::State::needsSpecialWriteHandling):
3338         (WebCore::HTMLTokenizer::State::):
3339         * html/HTMLViewSourceDocument.cpp:
3340         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
3341         (WebCore::HTMLViewSourceDocument::addViewSourceDoctypeToken):
3342         * html/HTMLViewSourceDocument.h:
3343         * loader/FrameLoader.cpp:
3344         (WebCore::FrameLoader::write):
3345         (WebCore::FrameLoader::switchOutLowBandwidthDisplayIfReady):
3346         * page/Frame.cpp:
3347         (WebCore::Frame::documentTypeString):
3348         * page/inspector/utilities.js:
3349         * xml/XSLTProcessor.cpp:
3350         (WebCore::XSLTProcessor::createDocumentFromSource):
3351
3352 2008-02-20  Anders Carlsson  <andersca@apple.com>
3353
3354         Reviewed by Darin.
3355
3356         Change most SVG related classes to start out with a ref count of 1.
3357         
3358         * bindings/js/JSSVGPointListCustom.cpp:
3359         (WebCore::JSSVGPointList::initialize):
3360         (WebCore::JSSVGPointList::insertItemBefore):
3361         (WebCore::JSSVGPointList::replaceItem):
3362         (WebCore::JSSVGPointList::appendItem):
3363         * bindings/js/JSSVGTransformListCustom.cpp:
3364         (WebCore::JSSVGTransformList::initialize):
3365         (WebCore::JSSVGTransformList::insertItemBefore):
3366         (WebCore::JSSVGTransformList::replaceItem):
3367         (WebCore::JSSVGTransformList::appendItem):
3368         * rendering/SVGCharacterLayoutInfo.h:
3369         (WebCore::SVGCharOnPath::create):
3370         (WebCore::SVGCharOnPath::SVGCharOnPath):
3371         * rendering/SVGRootInlineBox.cpp:
3372         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
3373         * svg/SVGAnimationElement.cpp:
3374         (WebCore::SVGAnimationElement::parseBeginOrEndValue):
3375         * svg/SVGClipPathElement.cpp:
3376         (WebCore::SVGClipPathElement::canvasResource):
3377         * svg/SVGElementInstance.cpp:
3378         (WebCore::SVGElementInstance::childNodes):
3379         * svg/SVGElementInstanceList.cpp:
3380         (WebCore::SVGElementInstanceList::SVGElementInstanceList):
3381         * svg/SVGElementInstanceList.h:
3382         (WebCore::SVGElementInstanceList::create):
3383         * svg/SVGFitToViewBox.cpp:
3384         (WebCore::SVGFitToViewBox::SVGFitToViewBox):
3385         * svg/SVGGradientElement.cpp:
3386         (WebCore::SVGGradientElement::SVGGradientElement):
3387         (WebCore::SVGGradientElement::canvasResource):
3388         * svg/SVGImageElement.cpp:
3389         (WebCore::SVGImageElement::SVGImageElement):
3390         * svg/SVGLengthList.h:
3391         (WebCore::SVGLengthList::create):
3392         * svg/SVGList.h:
3393         (WebCore::SVGList::SVGList):
3394         (WebCore::SVGPODListItem::create):
3395         (WebCore::SVGPODListItem::copy):
3396         (WebCore::SVGPODListItem::SVGPODListItem):
3397         (WebCore::SVGPODList::initialize):
3398         (WebCore::SVGPODList::insertItemBefore):
3399         (WebCore::SVGPODList::replaceItem):
3400         (WebCore::SVGPODList::appendItem):
3401         (WebCore::SVGPODList::SVGPODList):
3402         * svg/SVGMarkerElement.cpp:
3403         (WebCore::SVGMarkerElement::canvasResource):
3404         * svg/SVGMaskElement.cpp:
3405         (WebCore::SVGMaskElement::canvasResource):
3406         * svg/SVGNumberList.h:
3407         (WebCore::SVGNumberList::create):
3408         * svg/SVGPathElement.cpp:
3409         (WebCore::SVGPathElement::createSVGPathSegClosePath):
3410         (WebCore::SVGPathElement::createSVGPathSegMovetoAbs):
3411         (WebCore::SVGPathElement::createSVGPathSegMovetoRel):
3412         (WebCore::SVGPathElement::createSVGPathSegLinetoAbs):
3413         (WebCore::SVGPathElement::createSVGPathSegLinetoRel):
3414         (WebCore::SVGPathElement::createSVGPathSegCurvetoCubicAbs):
3415         (WebCore::SVGPathElement::createSVGPathSegCurvetoCubicRel):
3416         (WebCore::SVGPathElement::createSVGPathSegCurvetoQuadraticAbs):
3417         (WebCore::SVGPathElement::createSVGPathSegCurvetoQuadraticRel):
3418         (WebCore::SVGPathElement::createSVGPathSegArcAbs):
3419         (WebCore::SVGPathElement::createSVGPathSegArcRel):
3420         (WebCore::SVGPathElement::createSVGPathSegLinetoHorizontalAbs):
3421         (WebCore::SVGPathElement::createSVGPathSegLinetoHorizontalRel):
3422         (WebCore::SVGPathElement::createSVGPathSegLinetoVerticalAbs):
3423         (WebCore::SVGPathElement::createSVGPathSegLinetoVerticalRel):
3424         (WebCore::SVGPathElement::createSVGPathSegCurvetoCubicSmoothAbs):
3425         (WebCore::SVGPathElement::createSVGPathSegCurvetoCubicSmoothRel):
3426         (WebCore::SVGPathElement::createSVGPathSegCurvetoQuadraticSmoothAbs):
3427         (WebCore::SVGPathElement::createSVGPathSegCurvetoQuadraticSmoothRel):
3428         (WebCore::SVGPathElement::pathSegList):
3429         * svg/SVGPathElement.h:
3430         * svg/SVGPathSeg.h:
3431         (WebCore::SVGPathSeg::SVGPathSeg):
3432         * svg/SVGPathSegArc.h:
3433         (WebCore::SVGPathSegArcAbs::create):
3434         (WebCore::SVGPathSegArcRel::create):
3435         * svg/SVGPathSegClosePath.h:
3436         (WebCore::SVGPathSegClosePath::create):
3437         * svg/SVGPathSegCurvetoCubic.h:
3438         (WebCore::SVGPathSegCurvetoCubicAbs::create):
3439         (WebCore::SVGPathSegCurvetoCubicRel::create):
3440         * svg/SVGPathSegCurvetoCubicSmooth.h:
3441         (WebCore::SVGPathSegCurvetoCubicSmoothAbs::create):
3442         (WebCore::SVGPathSegCurvetoCubicSmoothRel::create):
3443         * svg/SVGPathSegCurvetoQuadratic.h:
3444         (WebCore::SVGPathSegCurvetoQuadraticAbs::create):
3445         (WebCore::SVGPathSegCurvetoQuadraticRel::create):
3446         * svg/SVGPathSegCurvetoQuadraticSmooth.h:
3447         (WebCore::SVGPathSegCurvetoQuadraticSmoothAbs::create):
3448         (WebCore::SVGPathSegCurvetoQuadraticSmoothRel::create):
3449         * svg/SVGPathSegLineto.h:
3450         (WebCore::SVGPathSegLinetoAbs::create):
3451         (WebCore::SVGPathSegLinetoRel::create):
3452         * svg/SVGPathSegLinetoHorizontal.h:
3453         (WebCore::SVGPathSegLinetoHorizontalAbs::create):
3454         (WebCore::SVGPathSegLinetoHorizontalRel::create):
3455         * svg/SVGPathSegLinetoVertical.h:
3456         (WebCore::SVGPathSegLinetoVerticalAbs::create):
3457         (WebCore::SVGPathSegLinetoVerticalRel::create):
3458         * svg/SVGPathSegList.h:
3459         (WebCore::SVGPathSegList::create):
3460         * svg/SVGPathSegMoveto.h:
3461         (WebCore::SVGPathSegMovetoAbs::create):
3462         (WebCore::SVGPathSegMovetoRel::create):
3463         * svg/SVGPatternElement.cpp:
3464         (WebCore::SVGPatternElement::SVGPatternElement):
3465         (WebCore::SVGPatternElement::canvasResource):
3466         * svg/SVGPointList.h:
3467         (WebCore::SVGPointList::create):
3468         * svg/SVGPolyElement.cpp:
3469         (WebCore::SVGPolyElement::points):
3470         * svg/SVGPreserveAspectRatio.cpp:
3471         (WebCore::SVGPreserveAspectRatio::SVGPreserveAspectRatio):
3472         * svg/SVGPreserveAspectRatio.h:
3473         (WebCore::SVGPreserveAspectRatio::create):
3474         * svg/SVGRenderingIntent.h:
3475         (WebCore::SVGRenderingIntent::SVGRenderingIntent):
3476         * svg/SVGStringList.h:
3477         (WebCore::SVGStringList::create):
3478         * svg/SVGStyledTransformableElement.cpp:
3479         (WebCore::SVGStyledTransformableElement::SVGStyledTransformableElement):
3480         * svg/SVGTests.cpp:
3481         (WebCore::SVGTests::requiredFeatures):
3482         (WebCore::SVGTests::requiredExtensions):
3483         (WebCore::SVGTests::systemLanguage):
3484         * svg/SVGTextElement.cpp:
3485         (WebCore::SVGTextElement::SVGTextElement):
3486         * svg/SVGTextPositioningElement.cpp:
3487         (WebCore::SVGTextPositioningElement::SVGTextPositioningElement):
3488         * svg/SVGTransformList.h:
3489         (WebCore::SVGTransformList::create):
3490         * svg/SVGUnitTypes.h:
3491         (WebCore::SVGUnitTypes::SVGUnitTypes):
3492         * svg/SVGViewElement.cpp:
3493         (WebCore::SVGViewElement::viewTarget):
3494         * svg/SVGViewSpec.cpp:
3495         (WebCore::SVGViewSpec::SVGViewSpec):
3496         * svg/graphics/SVGPaintServer.cpp:
3497         (WebCore::SVGPaintServer::sharedSolidPaintServer):
3498         * svg/graphics/SVGPaintServer.h:
3499         * svg/graphics/SVGPaintServerGradient.h:
3500         (WebCore::SVGPaintServerGradient::SharedStopCache::create):
3501         (WebCore::SVGPaintServerGradient::SharedStopCache::SharedStopCache):
3502         * svg/graphics/SVGPaintServerLinearGradient.h:
3503         (WebCore::SVGPaintServerLinearGradient::create):
3504         * svg/graphics/SVGPaintServerPattern.h:
3505         (WebCore::SVGPaintServerPattern::create):
3506         * svg/graphics/SVGPaintServerRadialGradient.h:
3507         (WebCore::SVGPaintServerRadialGradient::create):
3508         * svg/graphics/SVGPaintServerSolid.h:
3509         (WebCore::SVGPaintServerSolid::create):
3510         * svg/graphics/SVGResource.cpp:
3511         (WebCore::SVGResource::SVGResource):
3512         * svg/graphics/SVGResource.h:
3513         * svg/graphics/SVGResourceClipper.h:
3514         (WebCore::SVGResourceClipper::create):
3515         * svg/graphics/SVGResourceMarker.h:
3516         (WebCore::SVGResourceMarker::create):
3517         * svg/graphics/SVGResourceMasker.h:
3518         (WebCore::SVGResourceMasker::create):
3519         * svg/graphics/cg/SVGPaintServerGradientCg.cpp:
3520         (WebCore::SVGPaintServerGradient::updateQuartzGradientStopsCache):
3521
3522 2008-02-20  Darin Adler  <darin@apple.com>
3523
3524         Reviewed by Sam.
3525
3526         - make conversion from CSS ParseString to String and AtomicString
3527           automatic and remove all the explicit calls to do the conversion
3528
3529         - fix CSS parsing to do fewer allocations, mostly by using the
3530           equalIgnoringCase function in CSSParser
3531
3532         * css/CSSGrammar.y: Take out all the explicit atomicString and
3533         domString calls now that ParseString knows how to convert itself.
3534
3535         * css/CSSParser.cpp:
3536         (WebCore::equal): Added.
3537         (WebCore::equalIgnoringCase): Allow non-lettters.
3538         (WebCore::ParseString::lower): Used charactersAreAllASCII.
3539         (WebCore::unitFromString): Use equal.
3540         (WebCore::CSSParser::parseValue): Removed unneeded call to domString.
3541         (WebCore::CSSParser::parseContent): Use equalIgnoringCase.
3542         (WebCore::CSSParser::parseBackgroundImage): Removed unneeded call to domString.
3543         (WebCore::CSSParser::parseTransitionTimingFunction): Use equalIgnoringCase.
3544         (WebCore::CSSParser::parseDashboardRegions): More of the same.
3545         (WebCore::CSSParser::parseCounterContent): Ditto.
3546         (WebCore::CSSParser::parseShape): Use equalIgnoringCase.
3547         (WebCore::CSSParser::parseFontFamily): Removed unneeded calls to domString.
3548         (WebCore::CSSParser::parseFontFaceSrc): More.
3549         (WebCore::CSSParser::parseFontFaceUnicodeRange): More.
3550         (WebCore::CSSParser::parseColor): Don't lowercase here -- setNamedColor now
3551         handles the case folding.
3552         (WebCore::CSSParser::parseColorFromValue): More.
3553         (WebCore::CSSParser::parseBorderImage): More.
3554         (WebCore::CSSParser::parseCounter): More.
3555         (WebCore::TransformOperationInfo::TransformOperationInfo): More.
3556         (WebCore::CSSParser::parseTransform): More.
3557         (WebCore::CSSParser::createCharsetRule): More.
3558         (WebCore::CSSParser::createImportRule): More.
3559
3560         * css/CSSParser.h: Removed domString and atomicString functions.
3561         (WebCore::ParseString::operator String): Added. Allows conversion to String
3562         without an explicit function call.
3563         (WebCore::ParseString::operator AtomicString): Ditto.
3564
3565         * css/MediaQueryExp.cpp:
3566         (WebCore::MediaQueryExp::MediaQueryExp): Removed a call to domString.
3567         * css/SVGCSSParser.cpp:
3568         (WebCore::CSSParser::parseSVGValue): Removed calls to domString.
3569
3570         * platform/graphics/Color.cpp:
3571         (WebCore::findNamedColor): Call toASCIILower on each character as we copy
3572         it into the 8-bit character buffer to make the operation fold case.
3573
3574 2008-02-20  Justin Garcia  <justin.garcia@apple.com>
3575
3576         Reviewed by Darin Adler.
3577
3578         <rdar://problem/5694920> Typing (esp. deleting) is slower due to TOT WebCore changes
3579
3580         * editing/DeleteSelectionCommand.cpp:
3581         (WebCore::DeleteSelectionCommand::initializeStartEnd): The common case here
3582         is where there are no special elements.  Avoid creating VisiblePositions in
3583         that case.  Additionally, this change postpones the more expensive creation
3584         of an upstream VisiblePosition until the last possible moment.
3585         (WebCore::DeleteSelectionCommand::saveTypingStyleState):
3586         (WebCore::DeleteSelectionCommand::calculateTypingStyleAfterDelete): Add an 
3587         early return for a common case: deleting characters that are all inside the 
3588         same text node. In that case the style at the start of the selection will 
3589         not change during the delete, so there is no need to save/recompute it.