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