c3ea24ac049cce17f63f3aadfb347e2ad94399e8
[WebKit-https.git] / WebCore / ChangeLog
1 2008-05-06  Brady Eidson  <beidson@apple.com>
2
3         Rubberstamped by David Kilzer
4
5         * WebCore.base.exp:  Sort this mess!
6
7 2008-05-05  Mark Rowe  <mrowe@apple.com>
8
9         Reviewed by Dan Bernstein.
10
11         Fix 60 crashes seen on the buildbots that were misreported as hangs.
12
13         * dom/Document.cpp:
14         (WebCore::Document::detachNodeIterator): Null-check page() before dereferencing it.
15         (WebCore::Document::nodeWillBeRemoved): Ditto.
16         (WebCore::Document::textInserted): Ditto.
17         (WebCore::Document::textNodesMerged): Ditto.
18         (WebCore::Document::textRemoved): Ditto.
19
20 2008-05-05  Brady Eidson  <beidson@apple.com>
21
22         Reviewed by Mitz Pettel RTL
23
24         Preparation for upcoming work making LocalStorage persistent.
25
26         The other half of the StorageMap::importItem() addition.
27
28         * storage/StorageArea.cpp:
29         (WebCore::StorageArea::importItem):
30         * storage/StorageArea.h:
31
32 2008-05-05  Brady Eidson  <beidson@apple.com>
33
34         Reviewed by Mitz Pettel RTL
35
36         Preparation for upcoming work making LocalStorage persistent.
37
38         - Create the LocalStorage object for a PageGroup the moment the first Page is added to it
39           The Settings of the first Page define what persistent path the LocalStorage will use
40         - Add a Frame argument for the LocalStorageArea request - this will allow a client object
41           to be queried before the LocalStorageArea is established
42
43         * page/DOMWindow.cpp:
44         (WebCore::DOMWindow::localStorage):
45
46         * page/PageGroup.cpp:
47         (WebCore::PageGroup::addPage):
48         (WebCore::PageGroup::localStorage):
49
50         * storage/LocalStorage.cpp:
51         (WebCore::LocalStorage::LocalStorage): Take the path as a constructor argument.  Deep copy
52           the path as it will be used from another thread.
53         (WebCore::LocalStorage::storageArea):
54         * storage/LocalStorage.h:
55         (WebCore::LocalStorage::create):
56
57 2008-05-05  Brady Eidson  <beidson@apple.com>
58
59         Reviewed by Mitz Pettel RTL
60
61         Preparation for upcoming work making LocalStorage persistent.
62
63         StorageMaps normally have copy-on-write semantics to help support SessionStorage.
64         For LocalStorage, we never want this behavior.  When we forcefully import items into 
65         a StorageMap from the LocalStorage background thread, this new import method will be used.
66
67         * storage/StorageMap.cpp:
68         (WebCore::StorageMap::importItem): Add a deep-copy of the item to the map without worrying
69           about copy-on-write.
70         * storage/StorageMap.h:
71
72 2008-05-05  Kevin McCullough  <kmccullough@apple.com>
73
74         Reviewed by Tim.
75
76         -<rdar://problem/5770054> JavaScript profiler (10928)
77         -Begininings of a UI for the Profiler in the WebInspector.
78
79         * English.lproj/InspectorLocalizedStrings.js: Add new strings to be
80         localized.
81         * page/inspector/DatabasesPanel.js: Changed the name of the Databae's
82         results table to be more generic as it is now also used by the profiler.
83         * page/inspector/Images/glossySelected.png: Added.
84         * page/inspector/Images/profilesIcon.png: Added.
85         * page/inspector/Images/treeUpTriangleBlack.png: Added.
86         * page/inspector/Images/treeUpTriangleWhite.png: Added.
87         * page/inspector/ProfileView.js: Added. Sets up the header of the table.
88         * page/inspector/ProfilesPanel.js: Added.
89         * page/inspector/ProfilesPanel.js: Added. Sets up the containers of the
90         profiler's content.
91         * page/inspector/inspector.css: Change database-result-table to be more
92         generic as well as add the styles needed by the profiler.
93         * page/inspector/inspector.html: Add profiler support.
94
95 2008-05-05  Brady Eidson  <beidson@apple.com>
96
97         Change by Darin, reviewed by Brady
98
99         Small efficiency improvement Darin just spotted
100
101         * storage/StorageMap.cpp:
102         (WebCore::StorageMap::setItem):
103
104 2008-05-05  Antti Koivisto  <antti@apple.com>
105
106         Reviewed by Anders.
107
108         Fix https://bugs.webkit.org/show_bug.cgi?id=18899
109         Bug 18899: REGRESSION (r32871): Non-Safari crash in WTF::HashTable on startup
110
111         * loader/loader.cpp:
112         (WebCore::Loader::Loader):
113
114 2008-05-05  Brady Eidson  <beidson@apple.com>
115
116         Reviewed by Sam Weinig
117
118         Fix a bug in StorageMap iterator tracking where the iterator was not successfully
119         invalidated at an appropriate time.
120
121         * storage/StorageMap.cpp:
122         (WebCore::StorageMap::setItem): ALWAYS invalidate it here
123
124 2008-05-05  Justin Garcia  <justin.garcia@apple.com>
125
126         Reviewed by Darin.
127
128         <rdar://problem/5865171> REGRESSION: Creating a new quote places caret at beginning of quote instead of the end
129         
130         Disable Range mutation on document modifications in Tiger and Leopard Mail,
131         since they do their own mutation which interferes with ours.
132
133         * WebCore.base.exp:
134         * dom/Document.cpp:
135         (WebCore::Document::nodeChildrenChanged):
136         (WebCore::Document::nodeWillBeRemoved):
137         (WebCore::Document::textInserted):
138         (WebCore::Document::textRemoved):
139         (WebCore::Document::textNodesMerged):
140         (WebCore::Document::textNodeSplit):
141         * page/Settings.cpp:
142         (WebCore::Settings::Settings):
143         (WebCore::Settings::disableRangeMutationForOldAppleMail):
144         * page/Settings.h:
145         (WebCore::Settings::rangeMutationDisabledForOldAppleMail):
146
147 2008-05-05  Sam Weinig  <sam@webkit.org>
148
149         Reviewed by Tim Hatcher.
150
151         Make the Inspector's localizable strings file match the format used by Dashboard widgets.
152
153         * English.lproj/InspectorLocalizedStrings.js: Removed.
154         * English.lproj/localizedStrings.js: Added.
155         * WebCore.vcproj/WebCore.vcproj:
156         * WebCore.xcodeproj/project.pbxproj:
157         * page/inspector/inspector.js:
158
159 2008-05-05  Steve Falkenburg  <sfalken@apple.com>
160
161         Add support for default button appearance.
162         Add WebCore setting for app chrome mode.
163         
164         Reviewed by Dave Hyatt.
165
166         * css/CSSPrimitiveValueMappings.h:
167         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
168         * css/CSSValueKeywords.in: Added default-button value keyword.
169         * page/Settings.cpp:
170         (WebCore::Settings::Settings):
171         (WebCore::Settings::setApplicationChromeMode):
172         * page/Settings.h:
173         (WebCore::Settings::inApplicationChromeMode):
174         * rendering/RenderButton.cpp:
175         (WebCore::RenderButton::RenderButton):
176         (WebCore::RenderButton::setStyle):
177         (WebCore::RenderButton::timerFired):
178         * rendering/RenderButton.h:
179         * rendering/RenderStyle.h:
180         (WebCore::):
181         * rendering/RenderTheme.cpp:
182         (WebCore::RenderTheme::adjustStyle):
183         (WebCore::RenderTheme::paint):
184         (WebCore::RenderTheme::paintBorderOnly):
185         (WebCore::RenderTheme::paintDecorations):
186         (WebCore::RenderTheme::isControlStyled):
187         (WebCore::RenderTheme::isDefault):
188         * rendering/RenderTheme.h:
189         (WebCore::):
190         * rendering/RenderThemeSafari.cpp:
191         (WebCore::RenderThemeSafari::determineState):
192         (WebCore::RenderThemeSafari::adjustRepaintRect):
193         (WebCore::RenderThemeSafari::adjustButtonStyle):
194         * rendering/RenderThemeWin.cpp:
195         (WebCore::RenderThemeWin::supportsFocus):
196
197 2008-05-05  Alexey Proskuryakov  <ap@webkit.org>
198
199         Reviewed by Darin.
200
201         https://bugs.webkit.org/show_bug.cgi?id=11947
202         nbsps should be converted to entities in innerHTML
203
204         https://bugs.webkit.org/show_bug.cgi?id=18769
205         replacing &nbsp; with spaces using regexp creates inconsistent result
206
207         Tests: fast/dom/innerHTML-nbsp.html
208                fast/dom/innerHTML-escaping-attribute.html
209
210         * editing/markup.cpp:
211         (WebCore::appendAttributeValue):
212         (WebCore::escapeContentText):
213         (WebCore::appendEscapedContent):
214         Added U+00a0/nbsp to the list of characters to escape.
215
216 2008-05-05  David Hyatt  <hyatt@apple.com>
217
218         Fix for https://bugs.webkit.org/show_bug.cgi?id=18821.  Fix some bugs in both get/PutImageData of <canvas>.
219
220         Reviewed by Eric
221
222         New tests added in fast/canvas/
223
224         * platform/graphics/cg/ImageBufferCG.cpp:
225         (WebCore::ImageBuffer::getImageData):
226         (WebCore::ImageBuffer::putImageData):
227
228 2008-05-05  Dan Bernstein  <mitz@apple.com>
229
230         Reviewed by Dave Hyatt.
231
232         - fix https://bugs.webkit.org/show_bug.cgi?id=18809
233           Forms with block level generated content and absolutely positioned labels break inline layout (fixed on reflow)
234
235         Test: fast/block/basic/adding-near-anonymous-block.html
236
237         * rendering/RenderBlock.cpp:
238         (WebCore::RenderBlock::addChildToFlow): When adding a floating or
239         positioned object, if it follows an anonymous block, put it
240         inside the anonymous block. When adding an inline, check if it comes
241         after an anonymous block and put it in the anonymous block.
242
243 2008-05-05  Antti Koivisto  <antti@apple.com>
244
245         Reviewed by Darin.
246
247         Speculative fix for <rdar://problem/5906790> 
248         Crash in Loader::servePendingRequests() due to hash table being modified during iteration
249         
250         I don't know how to reproduce this. It would require the load to fail (or succeed)
251         synchronously, something that should not usually happen.
252
253         * loader/loader.cpp:
254         (WebCore::Loader::Loader):
255         (WebCore::Loader::load):
256         (WebCore::Loader::servePendingRequests):
257         (WebCore::Loader::cancelRequests):
258         (WebCore::Loader::Host::Host):
259         * loader/loader.h:
260         (WebCore::Loader::Host::name):
261
262 2008-05-05  Ariya Hidayat  <ariya.hidayat@trolltech.com>
263
264         Reviewed by Simon.
265
266         Disable SVG As Image support in the Qt port again, as it
267         requires more work. Right now the chrome client is
268         assumed to be a ChromeClientQt, which the SVG Image support
269         changes.
270
271         * WebCore.pro:
272
273 2008-05-02  Antti Koivisto  <antti@apple.com>
274
275         Reviewed by Mitz.
276
277         Fix <rdar://problem/5840475>
278         CrashTracer: [USER] 2 crashes in Safari at com.apple.WebCore: WebCore::RenderBlock::insertPositionedObject
279         
280         Non-block objects can have transforms so containingBlock() could end up returning null. 
281         RenderObject::container() needs to match.
282
283         Test: fast/transforms/container-transform-crash.html
284
285         * rendering/RenderObject.cpp:
286         (WebCore::RenderObject::containingBlock):
287         (WebCore::RenderObject::container):
288
289 2008-05-04  Sam Weinig  <sam@webkit.org>
290
291         Roll out r32851.  It broke tiger builds.
292
293         * bindings/objc/DOMUtility.mm:
294         (KJS::createDOMWrapper):
295         (WebCore::createDOMWrapper):
296
297 2008-05-04  Dan Bernstein  <mitz@apple.com>
298
299         Reviewed by Sam Weinig.
300
301         - fix https://bugs.webkit.org/show_bug.cgi?id=18879
302           <rdar://problem/5909481> Reproducible crash when removing a gradient
303
304         Test: fast/gradients/crash-on-remove.html
305
306         * css/CSSImageGeneratorValue.cpp:
307         (WebCore::CSSImageGeneratorValue::CSSImageGeneratorValue):
308         (WebCore::CSSImageGeneratorValue::addClient): Added a call to ref() the
309         value.
310         (WebCore::CSSImageGeneratorValue::removeClient): Added code to deref()
311         the value.
312
313 2008-05-03  Sam Weinig  <sam@webkit.org>
314
315         Reviewed by Mark Rowe.
316
317         Move createDOMWrapper(JSObject* object) out of the KJS namespace and into
318         the WebCore namespace now that the required compilers don't freak out about
319         this anymore.
320
321         * bindings/objc/DOMUtility.mm:
322         (WebCore::createDOMWrapper):
323
324 2008-05-03  Rob Buis  <buis@kde.org>
325
326         Reviewed by Sam.
327
328         https://bugs.webkit.org/show_bug.cgi?id=18652
329         onchange events don't seem to fire for input[type=range] controls.
330
331         Fire changeEvent when clicking the slider outside the current
332         thumb position.
333
334         * rendering/RenderSlider.cpp:
335         (WebCore::RenderSlider::setValueForPosition):
336
337 2008-05-03  Sam Weinig  <sam@webkit.org>
338
339         Reviewed by Mark Rowe.
340
341         Remove unused enums from JSDOMWindowBase.
342
343         * bindings/js/JSDOMWindowBase.h:
344         (WebCore::JSDOMWindowBase::):
345
346 2008-05-03  Sam Weinig  <sam@webkit.org>
347
348         Real build fix.
349
350         * WebCore.xcodeproj/project.pbxproj:
351
352 2008-05-03  Sam Weinig  <sam@webkit.org>
353
354         Build fix.
355
356         * bindings/js/kjs_events.cpp:
357         (WebCore::JSAbstractEventListener::handleEvent):
358
359 2008-05-03  Sam Weinig  <sam@webkit.org>
360
361         Rubber-stamped by Geoffrey Garen.
362
363         Rename JSDOMWindowWrapper to JSDOMWindowShell.
364
365 2008-05-01  Rob Buis  <buis@kde.org>
366
367         Reviewed by Eric.
368
369         https://bugs.webkit.org/show_bug.cgi?id=18568
370         background: currentColor fails
371
372         Implement currentColor from CSS3 color module.
373
374         Tests: fast/css/background-currentcolor.html
375
376         * css/CSSParser.cpp:
377         (WebCore::CSSParser::parseValue):
378         (WebCore::CSSParser::parseBackgroundColor):
379         * css/CSSStyleSelector.cpp:
380         (WebCore::CSSStyleSelector::getColorFromPrimitiveValue):
381         * css/CSSValueKeywords.in:
382         * css/SVGCSSValueKeywords.in:
383
384 2008-05-02  Anders Carlsson  <andersca@apple.com>
385
386         Reviewed by Mark.
387
388         Turns out calling locationInWindow on keyboard events will not throw an exception,
389         but the point returned is completely bogus, so remove coordinates from the keyboard event struct.
390         
391         * bridge/npapi.h:
392         (_NPCocoaEvent::):
393
394 2008-05-02  Benjamin Otte  <otte@gnome.org>
395
396         Reviewed by Alp Toker.
397
398         http://bugs.webkit.org/show_bug.cgi?id=18856
399         [GTK] variable initialization missing
400
401         Not initializing the m_needsXEmbed variable could have very funny
402         results. Most often those results would be crashes.
403
404         * plugins/PluginView.cpp:
405         (WebCore::PluginView::PluginView):
406
407 2008-05-02  Jan Michael Alonzo  <jmalonzo@unpluggable.com>
408
409         Reviewed by Eric.
410
411         https://bugs.webkit.org/show_bug.cgi?id=18811
412         Enable dashboard and offline web apps in autotools
413
414         * GNUmakefile.am:
415
416 2008-05-02  Anders Carlsson  <andersca@apple.com>
417
418         Reviewed by Sam.
419
420         Name the event union so it will work in plain C.
421
422         * bridge/npapi.h:
423         (_NPCocoaEvent::):
424
425 2008-05-02  Dan Bernstein  <mitz@apple.com>
426
427         Reviewed by John Sullivan.
428
429         - render text shadows with zero offset, as the shadow can be seen behind
430           the text if the text is translucent
431
432         Test: fast/text/shadow-no-blur.html
433
434         * platform/graphics/mac/FontMac.mm:
435         (WebCore::Font::drawComplexText): Removed the isEmpty() condition on the
436         shadow offset. Since isEmpty() is also true for sizes that have one or
437         more non-positive components, this also ensures that subpixel
438         antialiasing of the text is maintained with shadows in all directions.
439         (WebCore::Font::drawGlyphs): Ditto.
440         * platform/graphics/win/FontCGWin.cpp:
441         (WebCore::Font::drawGlyphs): Ditto.
442
443 2008-05-02  Ariya Hidayat  <ariya.hidayat@trolltech.com>
444
445         Reviewed by Simon.
446
447         Build the Qt port with SVG Use and As Image support.
448
449         * WebCore.pro:
450
451 2008-05-02  Ariya Hidayat  <ariya.hidayat@trolltech.com>
452
453         Reviewed by Simon.
454
455         Fixed potential crash on SVG animation (added more checks to the assert).
456
457         * svg/SVGUseElement.cpp:
458         (WebCore::SVGUseElement::associateInstancesWithShadowTreeElements):
459
460 2008-05-02  Alexey Proskuryakov  <ap@webkit.org>
461
462         Rubber-stamped by John Sullivan.
463
464         Fix a debug-only crash in layout tests.
465
466         * loader/CachedResource.cpp:
467         (WebCore::CachedResource::~CachedResource): Don't call resourceForURL() for null URLs.
468
469 2008-05-02  Simon Hausmann  <shausman@trolltech.com>
470
471         Fix the Qt build on Windows when Phonon is enabled for Audio/Video support
472
473         * WebCore.pro: Don't use QT += phonon as it prepends the phonon
474         includes to the include paths. Instead add it manually and make sure
475         phonon comes last, to avoid the conflict of phonon's path.h with
476         WebCore's Path.h on case-insensitive filesystems.
477
478 2008-05-02  Simon Hausmann  <hausmann@webkit.org>
479
480         Fix the Qt build. Add ExecState where necessary.
481
482         * bridge/qt/qt_class.cpp:
483         (KJS::Bindings::QtClass::fallbackObject):
484         * bridge/qt/qt_instance.cpp:
485         (KJS::Bindings::QtRuntimeObjectImp::construct):
486         (KJS::Bindings::QtInstance::getRuntimeObject):
487         (KJS::Bindings::QtInstance::invokeDefaultMethod):
488         (KJS::Bindings::QtInstance::defaultValue):
489         (KJS::Bindings::QtInstance::stringValue):
490         * bridge/qt/qt_instance.h:
491         (KJS::Bindings::QtInstance::getObject):
492         * bridge/qt/qt_runtime.cpp:
493         (KJS::Bindings::convertValueToQVariant):
494         (KJS::Bindings::convertQVariantToValue):
495         (KJS::Bindings::QtRuntimeMetaMethod::lengthGetter):
496         (KJS::Bindings::QtRuntimeMetaMethod::connectGetter):
497         (KJS::Bindings::QtRuntimeMetaMethod::disconnectGetter):
498         (KJS::Bindings::QtRuntimeConnectionMethod::lengthGetter):
499         (KJS::Bindings::QtConnectionObject::execute):
500         * bridge/runtime.cpp:
501         (KJS::Bindings::Instance::createRuntimeObject):
502
503 2008-05-02  Simon Hausmann  <shausman@trolltech.com>
504
505         Fix the Qt/Win build.
506
507         * WebCore.pro:
508         * platform/qt/TemporaryLinkStubs.cpp:
509         (PluginDatabase::getPluginPathsInDirectories):
510         (PluginDatabase::defaultPluginDirectories):
511         (PluginDatabase::isPreferredPluginDirectory):
512         (PluginView::setNPWindowRect):
513         (PluginView::userAgent):
514         (PluginView::invalidateRect):
515         (PluginView::invalidateRegion):
516         (PluginView::forceRedraw):
517         (PluginView::setFocus):
518         (PluginView::show):
519         (PluginView::hide):
520         (PluginView::paint):
521         (PluginView::setParent):
522         (PluginView::attachToWindow):
523         (PluginView::detachFromWindow):
524         (PluginView::updateWindow):
525         (PluginView::handleKeyboardEvent):
526         (PluginView::handleMouseEvent):
527         (PluginView::handlePostReadFile):
528         (PluginView::getValue):
529         * plugins/qt/PluginPackageQt.cpp:
530         (WebCore::PluginPackage::load):
531
532 2008-05-02  Alexey Proskuryakov  <ap@webkit.org>
533
534         Reviewed by Geoffrey Garen.
535
536         https://bugs.webkit.org/show_bug.cgi?id=18826
537         Make JavaScript heap per-thread
538
539         This is mostly adaptation for JSC changes. The most prominent one is that JSObject
540         allocator now takes ExecState, e.g. "new (exec) JSXMLHttpRequestConstructor(...)". It is
541         OK to pass either the current or global one, whichever is faster to get hold of, as both
542         have the same reference to a per-thread JS heap.
543
544         * bindings/scripts/CodeGeneratorJS.pm: Pass ExecState to functions that now need it.
545         JSDOMWindow, JSDOMWindowPrototype and JSDOMWindowWrapper are special, because they are
546         constructed before any ExecState comes into existence, so they use Heap::threadHeap()
547         directly for allocation.
548
549         * bindings/js/JSDOMWindowWrapper.cpp:
550         (WebCore::JSDOMWindowWrapper::operator new):
551         * bindings/js/JSDOMWindowWrapper.h:
552         Added a custom operator new to use per-thread heap when there's no ExecState around.
553
554         * bindings/js/JSAudioConstructor.cpp:
555         (WebCore::JSAudioConstructor::JSAudioConstructor):
556         * bindings/js/JSCSSRuleCustom.cpp:
557         (WebCore::toJS):
558         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
559         (WebCore::JSCSSStyleDeclaration::nameGetter):
560         * bindings/js/JSCSSValueCustom.cpp:
561         (WebCore::toJS):
562         * bindings/js/JSCanvasPixelArrayCustom.cpp:
563         (WebCore::JSCanvasPixelArray::indexGetter):
564         (WebCore::toJS):
565         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
566         (WebCore::toJS):
567         * bindings/js/JSClipboardCustom.cpp:
568         (WebCore::JSClipboard::types):
569         (WebCore::JSClipboard::getData):
570         * bindings/js/JSCustomXPathNSResolver.cpp:
571         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
572         * bindings/js/JSDOMApplicationCacheCustom.cpp:
573         (WebCore::JSDOMApplicationCache::addEventListener):
574         (WebCore::JSDOMApplicationCache::removeEventListener):
575         (WebCore::JSDOMApplicationCache::setOnchecking):
576         (WebCore::JSDOMApplicationCache::setOnerror):
577         (WebCore::JSDOMApplicationCache::setOnnoupdate):
578         (WebCore::JSDOMApplicationCache::setOndownloading):
579         (WebCore::JSDOMApplicationCache::setOnprogress):
580         (WebCore::JSDOMApplicationCache::setOnupdateready):
581         (WebCore::JSDOMApplicationCache::setOncached):
582         * bindings/js/JSDOMWindowBase.cpp:
583         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
584         (WebCore::JSDOMWindowBase::getValueProperty):
585         (WebCore::JSDOMWindowBase::setListener):
586         (WebCore::JSDOMWindowBase::findOrCreateJSEventListener):
587         (WebCore::JSDOMWindowBase::findJSUnprotectedEventListener):
588         (WebCore::JSDOMWindowBase::findOrCreateJSUnprotectedEventListener):
589         (WebCore::windowProtoFuncAToB):
590         (WebCore::windowProtoFuncBToA):
591         (WebCore::windowProtoFuncSetTimeout):
592         (WebCore::windowProtoFuncSetInterval):
593         (WebCore::windowProtoFuncAddEventListener):
594         * bindings/js/JSDOMWindowBase.h:
595         * bindings/js/JSDocumentCustom.cpp:
596         (WebCore::toJS):
597         * bindings/js/JSEventCustom.cpp:
598         (WebCore::toJS):
599         * bindings/js/JSEventTargetBase.cpp:
600         (WebCore::jsEventTargetAddEventListener):
601         * bindings/js/JSEventTargetBase.h:
602         (WebCore::JSEventTargetPrototype::self):
603         * bindings/js/JSEventTargetNode.cpp:
604         (WebCore::JSEventTargetNode::setListener):
605         * bindings/js/JSHTMLCollectionCustom.cpp:
606         (WebCore::getNamedItems):
607         (WebCore::toJS):
608         * bindings/js/JSHTMLElementWrapperFactory.cpp:
609         (WebCore::createJSHTMLWrapper):
610         * bindings/js/JSHTMLFormElementCustom.cpp:
611         (WebCore::JSHTMLFormElement::nameGetter):
612         * bindings/js/JSHTMLInputElementBase.cpp:
613         (WebCore::JSHTMLInputElementBase::getValueProperty):
614         * bindings/js/JSHTMLOptionElementConstructor.cpp:
615         (WebCore::JSHTMLOptionElementConstructor::JSHTMLOptionElementConstructor):
616         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
617         (WebCore::JSHTMLOptionsCollection::length):
618         * bindings/js/JSInspectedObjectWrapper.cpp:
619         (WebCore::JSInspectedObjectWrapper::wrap):
620         * bindings/js/JSInspectorCallbackWrapper.cpp:
621         (WebCore::JSInspectorCallbackWrapper::wrap):
622         * bindings/js/JSLocationCustom.cpp:
623         (WebCore::JSLocation::toString):
624         * bindings/js/JSNamedNodesCollection.cpp:
625         (WebCore::JSNamedNodesCollection::lengthGetter):
626         * bindings/js/JSNavigatorCustom.cpp:
627         (WebCore::JSNavigator::appVersion):
628         * bindings/js/JSNodeCustom.cpp:
629         (WebCore::toJS):
630         * bindings/js/JSNodeFilterCustom.cpp:
631         (WebCore::JSNodeFilter::acceptNode):
632         * bindings/js/JSRGBColor.cpp:
633         (WebCore::getJSRGBColor):
634         * bindings/js/JSSQLResultSetRowListCustom.cpp:
635         (WebCore::JSSQLResultSetRowList::item):
636         * bindings/js/JSSVGElementWrapperFactory.cpp:
637         (WebCore::createJSSVGWrapper):
638         * bindings/js/JSSVGLazyEventListener.cpp:
639         (WebCore::JSSVGLazyEventListener::eventParameterName):
640         * bindings/js/JSStorageCustom.cpp:
641         (WebCore::JSStorage::nameGetter):
642         * bindings/js/JSStyleSheetCustom.cpp:
643         (WebCore::toJS):
644         * bindings/js/JSXMLHttpRequestConstructor.cpp:
645         (WebCore::JSXMLHttpRequestConstructor::construct):
646         * bindings/js/JSXMLHttpRequestCustom.cpp:
647         (WebCore::JSXMLHttpRequest::setOnreadystatechange):
648         (WebCore::JSXMLHttpRequest::setOnload):
649         (WebCore::JSXMLHttpRequest::setOnprogress):
650         (WebCore::JSXMLHttpRequest::getResponseHeader):
651         (WebCore::JSXMLHttpRequest::addEventListener):
652         (WebCore::JSXMLHttpRequest::removeEventListener):
653         * bindings/js/JSXSLTProcessor.cpp:
654         (WebCore::jsXSLTProcessorPrototypeFunctionGetParameter):
655         (WebCore::JSXSLTProcessorConstructor::construct):
656         * bindings/js/kjs_binding.cpp:
657         (WebCore::jsStringOrNull):
658         (WebCore::jsOwnedStringOrNull):
659         (WebCore::jsStringOrUndefined):
660         (WebCore::jsStringOrFalse):
661         (WebCore::nonCachingStaticFunctionGetter):
662         (WebCore::objectToStringFunctionGetter):
663         * bindings/js/kjs_binding.h:
664         (WebCore::DOMObject::DOMObject):
665         (WebCore::cacheDOMObject):
666         (WebCore::cacheSVGDOMObject):
667         * bindings/js/kjs_events.cpp:
668         (WebCore::JSLazyEventListener::eventParameterName):
669         (WebCore::JSLazyEventListener::parseCode):
670         * bindings/js/kjs_html.cpp:
671         (WebCore::getRuntimeObject):
672         * bridge/c/c_instance.cpp:
673         (KJS::Bindings::CInstance::defaultValue):
674         (KJS::Bindings::CInstance::stringValue):
675         (KJS::Bindings::CInstance::numberValue):
676         (KJS::Bindings::CInstance::valueOf):
677         * bridge/c/c_instance.h:
678         * bridge/c/c_utility.cpp:
679         (KJS::Bindings::convertNPVariantToValue):
680         * bridge/jni/jni_instance.cpp:
681         (JavaInstance::stringValue):
682         (JavaInstance::numberValue):
683         (JavaInstance::invokeMethod):
684         (JavaInstance::defaultValue):
685         (JavaInstance::valueOf):
686         * bridge/jni/jni_instance.h:
687         * bridge/jni/jni_jsobject.h:
688         * bridge/jni/jni_jsobject.mm:
689         (JavaJSObject::call):
690         (JavaJSObject::setMember):
691         (JavaJSObject::setSlot):
692         (JavaJSObject::convertJObjectToValue):
693         (JavaJSObject::getListFromJArray):
694         * bridge/jni/jni_objc.mm:
695         (KJS::Bindings::dispatchJNICall):
696         * bridge/jni/jni_runtime.cpp:
697         (JavaArray::convertJObjectToArray):
698         (JavaField::dispatchValueFromInstance):
699         (JavaField::valueFromInstance):
700         (JavaField::dispatchSetValueToInstance):
701         (JavaArray::valueAt):
702         * bridge/jni/jni_utility.h:
703         * bridge/objc/objc_class.mm:
704         (KJS::Bindings::ObjcClass::fallbackObject):
705         * bridge/objc/objc_instance.h:
706         * bridge/objc/objc_instance.mm:
707         (ObjcInstance::defaultValue):
708         (ObjcInstance::stringValue):
709         (ObjcInstance::numberValue):
710         (ObjcInstance::valueOf):
711         * bridge/objc/objc_utility.h:
712         * bridge/objc/objc_utility.mm:
713         (KJS::Bindings::convertNSStringToString):
714         (KJS::Bindings::convertObjcValueToValue):
715         * bridge/runtime.cpp:
716         (KJS::Bindings::Instance::createRuntimeObject):
717         * bridge/runtime.h:
718         (KJS::Bindings::Instance::valueOf):
719         * bridge/runtime_array.cpp:
720         (RuntimeArray::lengthGetter):
721         * bridge/runtime_method.cpp:
722         (RuntimeMethod::lengthGetter):
723         * bridge/runtime_object.cpp:
724         (RuntimeObjectImp::RuntimeObjectImp):
725         (RuntimeObjectImp::methodGetter):
726         (RuntimeObjectImp::defaultValue):
727         * xml/XMLHttpRequest.cpp:
728         (WebCore::XMLHttpRequest::dropProtection):
729         * bindings/js/GCController.cpp:
730         (WebCore::GCController::gcTimerFired):
731         (WebCore::GCController::garbageCollectNow):
732         Adapted to JSC changes. Pass ExecState to functions that now need it. Removed
733         collectOnMainThreadOnly, as this is the only way to collect now. Replaced calls to static
734         Collector methods with calls to per-thread Heap ones.
735
736 2008-05-02  Ariya Hidayat  <ariya.hidayat@trolltech.com>
737
738         Reviewed by Simon.
739
740         Build the Qt port with SVG Animation support.
741
742         * WebCore.pro:
743
744 2008-05-02  Simon Hausmann  <hausmann@webkit.org>
745
746         Build fix for Qt/Gtk. Don't declare NP_InitializeFuncPtr twice
747         with different signatures.
748
749         * plugins/npfunctions.h:
750
751 2008-05-01  Robin Dunn  <robin@alldunn.com>
752
753         Reviewed by Kevin Ollivier.
754
755         Explicitly set the pen style in wx port to keep pen style changes from 
756         affecting URL underline or text field drawing.
757         
758         https://bugs.webkit.org/show_bug.cgi?id=18775
759
760         * platform/graphics/wx/GraphicsContextWx.cpp:
761         (WebCore::GraphicsContext::fillRect):
762         (WebCore::GraphicsContext::drawLineForText):
763         * platform/wx/RenderThemeWx.cpp:
764         (WebCore::RenderThemeWx::paintTextField):
765
766 2008-05-01  Robin Dunn  <robin@alldunn.com>
767
768         Reviewed by Kevin Ollivier.
769
770         Implement popup menu support for wx port.
771         
772         https://bugs.webkit.org/show_bug.cgi?id=18776
773
774         * platform/PopupMenu.h:
775         * platform/wx/PopupMenuWx.cpp: Added.
776         (WebCore::PopupMenu::PopupMenu):
777         (WebCore::PopupMenu::~PopupMenu):
778         (WebCore::PopupMenu::show):
779         (WebCore::PopupMenu::OnMenuItemSelected):
780         (WebCore::PopupMenu::hide):
781         (WebCore::PopupMenu::updateFromElement):
782         (WebCore::PopupMenu::itemWritingDirectionIsNatural):
783         * platform/wx/TemporaryLinkStubs.cpp:
784         * webcore-wx.bkl:
785
786 2008-05-01  Kevin Ollivier  <kevino@theolliviers.com>
787
788         Reviewed by Eric Seidel.
789
790         Make sure we properly set the button for all mouse events,
791         not just mouse down, set the click count to 0
792         for non-click events, and finally set the timestamp.
793         
794         https://bugs.webkit.org/show_bug.cgi?id=18464
795
796         * platform/wx/MouseEventWx.cpp:
797         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
798
799 2008-05-01  Sam Weinig  <sam@webkit.org>
800
801         Reviewed by Mark Rowe (in his infinite wisdom).
802
803         Auto-generate the JSXSLTProcessor binding.
804
805         * DerivedSources.make:
806         * GNUmakefile.am:
807         * WebCore.pro:
808         * WebCore.vcproj/WebCore.vcproj:
809         * WebCore.xcodeproj/project.pbxproj:
810         * WebCoreSources.bkl:
811         * bindings/js/JSDOMWindowBase.cpp:
812         (WebCore::JSDOMWindowBase::getValueProperty):
813         * bindings/js/JSDOMWindowBase.h:
814         (WebCore::JSDOMWindowBase::):
815         * bindings/js/JSXSLTProcessor.cpp: Removed.
816         * bindings/js/JSXSLTProcessor.h: Removed.
817         * xml/XSLTProcessor.h:
818
819 2008-05-01  Sam Weinig  <sam@webkit.org>
820
821         Reviewed by Geoffrey Garen.
822
823         Fixes:
824           - https://bugs.webkit.org/show_bug.cgi?id=17249
825             Incorrect lexical scope after navigation leads to UXSS
826             <rdar://problem/5738497>
827
828           - https://bugs.webkit.org/show_bug.cgi?id=16824
829             Script authorization should follow lexical (not dynamic) scope
830             <rdar://problem/5683032>
831
832         This patch changes us to perform same-origin checks based on the lexical global object) 
833         rather than dynamic global object, which is now possible we don't re-use the window on 
834         navigations, but rather switch in a new one and re-use the outer shell.  This is both
835         more secure and conforms with the HTML5 specification.  Now that all the checks are
836         done based on the lexical global object, we can remove the SecurityOrigin::Reason
837         concept, as it was only around to work around an ebay.com bug that required the check to
838         be done that way.
839
840         An important thing to note is that we currently implement a stricter than necessary policy
841         and perform the same-origin check based on the currently active global object to avoid leaking
842         the document in cases when the target frame is navigated before access.  This will be fixed in
843         an upcoming patch.
844
845         * bindings/js/JSDOMWindowBase.cpp:
846         (WebCore::JSDOMWindowBase::allowsAccessFrom):
847         (WebCore::JSDOMWindowBase::allowsAccessFromNoErrorMessage):
848         (WebCore::JSDOMWindowBase::allowsAccessFromPrivate):
849         (WebCore::JSDOMWindowBase::crossDomainAccessErrorMessage):
850         (WebCore::JSDOMWindowBase::printErrorMessage):
851         (WebCore::asJSDOMWindow):
852         * bindings/js/JSDOMWindowBase.h:
853         * html/CanvasRenderingContext2D.cpp:
854         (WebCore::CanvasRenderingContext2D::checkOrigin):
855         (WebCore::CanvasRenderingContext2D::createPattern):
856         * loader/FrameLoader.cpp:
857         (WebCore::FrameLoader::begin):
858         (WebCore::FrameLoader::write):
859         (WebCore::FrameLoader::setOpener):
860         (WebCore::FrameLoader::shouldAllowNavigation):
861         * page/DOMWindow.h:
862         (WebCore::DOMWindow::setSecurityOrigin):
863         (WebCore::DOMWindow::securityOrigin):
864         (WebCore::DOMWindow::setURL):
865         (WebCore::DOMWindow::url):
866         * platform/SecurityOrigin.cpp:
867         (WebCore::SecurityOrigin::canAccess):
868         (WebCore::SecurityOrigin::isSecureTransitionTo):
869         * platform/SecurityOrigin.h:
870
871 2008-05-01  Anders Carlsson  <andersca@apple.com>
872
873         Reviewed by Mark.
874
875         Enable 64-bit NPAPI plugins.
876         
877         * WebCore.xcodeproj/project.pbxproj:
878         Don't remove NPAPI related symbols from the 64-bit .exp file.
879         
880         * bridge/npruntime.h:
881         Remove now unnecessary #error.
882
883 2008-05-01  Maciej Stachowiak  <mjs@apple.com>
884
885         Reviewed by Oliver (a while ago)
886
887         - just a wee bit more bindings speedup
888         
889         Store the per-document Node --> JS wrapper cache in the document
890         instead of an external hashtable.
891
892         * bindings/js/kjs_binding.cpp:
893         (WebCore::ScriptInterpreter::getDOMNodeForDocument):
894         (WebCore::ScriptInterpreter::forgetDOMNodeForDocument):
895         (WebCore::ScriptInterpreter::putDOMNodeForDocument):
896         (WebCore::ScriptInterpreter::forgetAllDOMNodesForDocument):
897         (WebCore::ScriptInterpreter::markDOMNodesForDocument):
898         * dom/Document.h:
899         (WebCore::Document::wrapperCache):
900
901 2008-05-01  Anders Carlsson  <andersca@apple.com>
902
903         Reviewed by Tim.
904
905         Remove duplicate npfunctions.h header from WebKit.
906         
907         * WebCore.xcodeproj/project.pbxproj:
908         Add npfunctions.h and set its role to private.
909         
910         * plugins/npfunctions.h:
911         Merge Mac specific changes.
912
913 2008-05-01  Sam Weinig  <sam@webkit.org>
914
915         Reviewed by Geoffrey Garen.
916
917         Rename toJSDOMWindow(KJS::JSGlobalObject) to asJSDOMWindow, as all it does is
918         cast.
919
920         * bindings/js/JSCustomVoidCallback.cpp:
921         (WebCore::toVoidCallback):
922         * bindings/js/JSCustomXPathNSResolver.cpp:
923         (WebCore::JSCustomXPathNSResolver::create):
924         * bindings/js/JSDOMApplicationCacheCustom.cpp:
925         (WebCore::JSDOMApplicationCache::add):
926         (WebCore::JSDOMApplicationCache::remove):
927         * bindings/js/JSDOMWindowBase.cpp:
928         (WebCore::allowPopUp):
929         (WebCore::createWindow):
930         (WebCore::windowProtoFuncOpen):
931         (WebCore::asJSDOMWindow):
932         * bindings/js/JSDOMWindowBase.h:
933         * bindings/js/JSDOMWindowCustom.cpp:
934         (WebCore::JSDOMWindow::setLocation):
935         (WebCore::JSDOMWindow::postMessage):
936         * bindings/js/JSDatabaseCustom.cpp:
937         (WebCore::JSDatabase::changeVersion):
938         (WebCore::JSDatabase::transaction):
939         * bindings/js/JSDocumentCustom.cpp:
940         (WebCore::JSDocument::setLocation):
941         * bindings/js/JSLocationCustom.cpp:
942         (WebCore::navigateIfAllowed):
943         (WebCore::JSLocation::setHref):
944         (WebCore::JSLocation::replace):
945         (WebCore::JSLocation::reload):
946         (WebCore::JSLocation::assign):
947         * bindings/js/JSSQLTransactionCustom.cpp:
948         (WebCore::JSSQLTransaction::executeSql):
949         * bindings/js/JSXMLHttpRequestCustom.cpp:
950         (WebCore::JSXMLHttpRequest::open):
951         * page/JavaScriptDebugServer.cpp:
952         (WebCore::toPage):
953
954 2008-05-01  Anatoli Papirovski  <apapirovski@mac.com>
955
956         Reviewed by Dave Hyatt.
957
958         - fix https://bugs.webkit.org/show_bug.cgi?id=18347
959           Absolutely positioned image percentage width does not respect container's padding
960
961         Test: fast/replaced/absolute-position-percentage-width.html
962
963         * rendering/RenderBox.cpp:
964         (WebCore::RenderBox::calcReplacedWidthUsing):
965
966 2008-05-01  Dan Bernstein  <mitz@apple.com>
967
968         - Windows build fix
969
970         * platform/graphics/win/FontCGWin.cpp:
971         (WebCore::Font::drawGlyphs):
972
973 2008-05-01  Dan Bernstein  <mitz@apple.com>
974
975         Reviewed by Darin Adler.
976
977         - make synthetic bold and synthetic italics work in GDI text
978         - account for synthetic bold in complex text on Windows
979
980         * platform/graphics/win/FontCGWin.cpp:
981         (WebCore::Font::drawGlyphs): Adjusted the text rectangle's x coordinates
982         to fit italics. Added a skew transform for synthetic italics and a
983         second paint pass for synthetic bold.
984         * platform/graphics/win/SimpleFontDataWin.cpp:
985         (WebCore::SimpleFontData::widthForGDIGlyph): Added the synthetic bold
986         offset.
987         * platform/graphics/win/UniscribeController.cpp:
988         (WebCore::UniscribeController::shapeAndPlaceItem): Added the synthetic
989         bold offset.
990
991 2008-05-01  Alp Toker  <alp@nuanti.com>
992
993         Qt/Win build fix attempt following plugin changes. Add missing return
994         statements.
995
996         Also fixes some newly introduced coding style issues in the Qt port.
997
998         * platform/qt/FileSystemQt.cpp:
999         (WebCore::openTemporaryFile):
1000         (WebCore::closeFile):
1001         (WebCore::writeToFile):
1002         (WebCore::unloadModule):
1003
1004 2008-05-01  Anders Carlsson  <andersca@apple.com>
1005
1006         Reviewed by Adam.
1007
1008         Export methods needed to subclass Widget.  (See r32770.)
1009
1010         * WebCore.base.exp:
1011
1012 2008-05-01  Marc Ordinas i Llopis  <marc.ordinasillopis@collabora.co.uk>
1013
1014         Reviewed by Alp Toker.
1015         Qt parts OK'ed by Simon Hausmann.
1016
1017         https://bugs.webkit.org/show_bug.cgi?id=14750
1018         Added support for NPAPI plugins on Gtk and Qt-x11 ports.
1019
1020         * GNUmakefile.am: Added Gtk plugin files.
1021         * WebCore.pro: Added Qt plugins files, defined XP_UNIX and
1022         ENABLE_NETSCAPE_PLUGIN_API
1023         * bridge/npruntime_internal.h: Additional undefs that conflict
1024         with Qt headers.
1025         * page/gtk/FrameGtk.cpp: Create js bindings for PluginView.
1026         (WebCore::Frame::createScriptInstanceForWidget):
1027         * page/qt/FrameQt.cpp: Create js bindings for PluginView.
1028         (WebCore::Frame::createScriptInstanceForWidget):
1029         (WebCore::Frame::clearPlatformScriptObjects):
1030         (WebCore::Frame::disconnectPlatformScriptObjects):
1031         * platform/FileSystem.h: Qt FileSystem implementation.
1032         * platform/Widget.h: Members to differentiate between Qt plugins and
1033         NPAPI ones.
1034         * platform/gtk/ScrollViewGtk.cpp:
1035         (WebCore::ScrollView::addChild): Set containing window before calling setParent.
1036         * platform/gtk/TemporaryLinkStubs.cpp: Removed implemented functions.
1037         (PluginView::invalidateRegion):
1038         * platform/qt/FileSystemQt.cpp: Implemented functions necessary for
1039         NPAPI plugins.
1040         (WebCore::openTemporaryFile):
1041         (WebCore::closeFile):
1042         (WebCore::writeToFile):
1043         (WebCore::unloadModule): Delete module if unloaded.
1044         * platform/qt/TemporaryLinkStubs.cpp: Removed implemented functions.
1045         * platform/qt/WidgetQt.cpp: Differentiate between Qt plugins and
1046         NPAPI ones.
1047         (WebCore::WidgetPrivate::WidgetPrivate):
1048         (WebCore::Widget::isNPAPIPlugin):
1049         (WebCore::Widget::setIsNPAPIPlugin):
1050         * plugins/PluginPackage.cpp:
1051         (WebCore::PluginPackage::~PluginPackage): Unload the module before
1052         destruction.
1053         (WebCore::PluginPackage::compare): Moved here as it's platform
1054         independent.
1055         * plugins/PluginView.cpp: Moved platform-independent functions here.
1056         (WebCore::PluginView::PluginView): Initialize m_npWindow.ws_info on
1057         Unix platforms.
1058         (WebCore::PluginView::freeStringArray):
1059         (WebCore::startsWithBlankLine):
1060         (WebCore::locationAfterFirstBlankLine):
1061         (WebCore::findEOL):
1062         (WebCore::capitalizeRFC822HeaderFieldName):
1063         (WebCore::parseRFC822HeaderFields):
1064         (WebCore::PluginView::handlePost):
1065         * plugins/PluginView.h: Moved platform-independent functions here.
1066         Added member to signal plugin needs XEmbed extension.
1067         * plugins/gtk/PluginDataGtk.cpp: Added.
1068         (WebCore::PluginData::initPlugins):
1069         (WebCore::PluginData::refresh):
1070         * plugins/gtk/PluginDatabaseGtk.cpp:
1071         (WebCore::PluginDatabase::defaultPluginDirectories):
1072         (WebCore::PluginDatabase::isPreferredPluginDirectory):
1073         * plugins/gtk/PluginPackageGtk.cpp: Added.
1074         (WebCore::PluginPackage::determineQuirks):
1075         (WebCore::PluginPackage::fetchInfo):
1076         (WebCore::PluginPackage::load):
1077         (WebCore::PluginPackage::hash):
1078         (WebCore::PluginPackage::equal):
1079         (WebCore::PluginPackage::compareFileVersion):
1080         * plugins/gtk/PluginViewGtk.cpp: Added.
1081         (WebCore::PluginView::updateWindow):
1082         (WebCore::PluginView::setFocus):
1083         (WebCore::PluginView::show):
1084         (WebCore::PluginView::hide):
1085         (WebCore::PluginView::paint):
1086         (WebCore::PluginView::handleKeyboardEvent):
1087         (WebCore::PluginView::handleMouseEvent):
1088         (WebCore::PluginView::setParent):
1089         (WebCore::PluginView::setNPWindowRect):
1090         (WebCore::PluginView::attachToWindow):
1091         (WebCore::PluginView::detachFromWindow):
1092         (WebCore::PluginView::stop):
1093         (WebCore::PluginView::userAgent):
1094         (WebCore::PluginView::handlePostReadFile):
1095         (WebCore::PluginView::getValue):
1096         (WebCore::PluginView::invalidateRect):
1097         (WebCore::PluginView::forceRedraw):
1098         (WebCore::PluginView::~PluginView):
1099         (WebCore::plug_removed_cb): Added callback to handle plug removal.
1100         (WebCore::PluginView::init):
1101         * plugins/gtk/xembed.h: Added.
1102         * plugins/npapi.cpp:
1103         (NPN_GetValue): Return error if no view present.
1104         * plugins/qt/PluginDataQt.cpp:
1105         (WebCore::PluginData::initPlugins):
1106         (WebCore::PluginData::refresh):
1107         * plugins/qt/PluginDatabaseQt.cpp: Added.
1108         (WebCore::PluginDatabase::getPluginPathsInDirectories):
1109         (WebCore::addQtWebKitPluginDirectories):
1110         (WebCore::addMozillaPluginDirectories):
1111         (WebCore::PluginDatabase::defaultPluginDirectories):
1112         (WebCore::PluginDatabase::isPreferredPluginDirectory):
1113         * plugins/qt/PluginPackageQt.cpp: Added.
1114         (WebCore::PluginPackage::determineQuirks):
1115         (WebCore::PluginPackage::fetchInfo):
1116         (WebCore::PluginPackage::load):
1117         (WebCore::PluginPackage::hash):
1118         (WebCore::PluginPackage::equal):
1119         (WebCore::PluginPackage::compareFileVersion):
1120         * plugins/qt/PluginViewQt.cpp: Added.
1121         (WebCore::PluginView::updateWindow):
1122         (WebCore::PluginView::setFocus):
1123         (WebCore::PluginView::show):
1124         (WebCore::PluginView::hide):
1125         (WebCore::PluginView::paint):
1126         (WebCore::PluginView::handleKeyboardEvent):
1127         (WebCore::PluginView::handleMouseEvent):
1128         (WebCore::PluginView::setParent):
1129         (WebCore::PluginView::setNPWindowRect):
1130         (WebCore::PluginView::attachToWindow):
1131         (WebCore::PluginView::detachFromWindow):
1132         (WebCore::PluginView::stop):
1133         (WebCore::PluginView::userAgent):
1134         (WebCore::PluginView::handlePostReadFile):
1135         (WebCore::PluginView::getValue):
1136         (WebCore::PluginView::invalidateRect):
1137         (WebCore::PluginView::invalidateRegion):
1138         (WebCore::PluginView::forceRedraw):
1139         (WebCore::PluginView::~PluginView):
1140         (WebCore::PluginView::init):
1141         * plugins/win/PluginPackageWin.cpp: Moved platform-independent code
1142         to plugins/PluginPackage.cpp
1143         * plugins/win/PluginViewWin.cpp: Moved platform-independent code to
1144         plugins/PluginView.cpp
1145         (WebCore::PluginView::stop):
1146         (WebCore::PluginView::handlePostReadFile):
1147         (WebCore::PluginView::getValue): Moved this function to each platform.
1148
1149 2008-05-01  Sam Weinig  <sam@webkit.org>
1150
1151         Fix build.
1152
1153         * ForwardingHeaders/wtf/StrHash.h: Added.
1154
1155 2008-05-01  Anders Carlsson  <andersca@apple.com>
1156
1157         Reviewed by Darin.
1158
1159         Move management of cache groups to ApplicationCacheStorage. Also,
1160         application caches now start out with a null group and will have their group set
1161         when the cache has finished loading. 
1162
1163         * loader/appcache/ApplicationCache.cpp:
1164         (WebCore::ApplicationCache::ApplicationCache):
1165         Initialize m_group to 0.
1166         
1167         (WebCore::ApplicationCache::~ApplicationCache):
1168         Null check the group.
1169         
1170         (WebCore::ApplicationCache::setGroup):
1171         New method for setting the group.
1172         
1173         * loader/appcache/ApplicationCache.h:        
1174         (WebCore::ApplicationCache::create):
1175         Remove the group argument.
1176         
1177         * loader/appcache/ApplicationCacheGroup.cpp:
1178         (WebCore::ApplicationCacheGroup::~ApplicationCacheGroup):
1179         Let the storage know that the cache group has been destroyed.
1180         
1181         (WebCore::ApplicationCacheGroup::cacheForMainRequest):
1182         Call into the storage.
1183         
1184         (WebCore::ApplicationCacheGroup::selectCache):
1185         Call into the storage.
1186         
1187         (WebCore::ApplicationCacheGroup::documentLoaderDestroyed):
1188         When there are no document loaders associated with the cache group,
1189         set the newest cache to 0.
1190         
1191         (WebCore::ApplicationCacheGroup::cacheDestroyed):
1192         Delete the group if there are no associated caches.
1193         
1194         (WebCore::ApplicationCacheGroup::setNewestCache):
1195         New method that will set the newest cache and associate the group with the cache.
1196         
1197         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
1198         Call setNewestCache instead.
1199         
1200         * loader/appcache/ApplicationCacheStorage.cpp:
1201         (WebCore::urlHostHash):
1202         Move host hash method here.
1203         
1204         (WebCore::ApplicationCacheStorage::findOrCreateCacheGroup):
1205         New method that finds a cache group with a given manifest URL or creates a new one.
1206
1207         (WebCore::ApplicationCacheStorage::cacheGroupForURL):
1208         New method that returns a cache group for a given URL.
1209         
1210         (WebCore::ApplicationCacheStorage::cacheGroupDestroyed):
1211         When the cache group has been destroyed, remove it from the hash map.
1212         
1213         * loader/appcache/ApplicationCacheStorage.h:
1214         Add new methods.I b
1215
1216 2008-05-01  Dan Winship  <danw@gnome.org>
1217
1218         Reviewed by Alp Toker.
1219
1220         http://bugs.webkit.org/show_bug.cgi?id=18490
1221         Add mostly-working file: support and mostly-broken ftp: support to
1222         the soup backend.
1223
1224         * platform/network/soup/ResourceHandleSoup.cpp (start): after
1225         doing basic checks, delegate to one of three submethods
1226         (startData): handles data: URLs
1227         (startHttp): handles http: and https: URLs, via libsoup
1228         (startGio, etc): handles file: and ftp: URLs, via gio. Lots of
1229         FIXMEs detailing the parts that don't fully work yet.
1230
1231         * platform/network/ResourceHandle.h:
1232         * platform/network/ResourceHandleInternal.h: add new member
1233         variables for gio-based loading
1234
1235 2008-05-01  Alp Toker  <alp@nuanti.com>
1236
1237         Rubber-stamped by Anders.
1238
1239         GTK+ build fix for changes in r32752. Use int32, not int32_t types in
1240         npapi.h.
1241
1242         Additional fix to use same signedness in npapi.h and Mac for the
1243         interval parameter.
1244
1245         * bridge/npapi.h:
1246
1247 2008-04-30  Anders Carlsson  <andersca@apple.com>
1248
1249         Reviewed by Adam.
1250
1251         Add new Cocoa event model type declarations.
1252         
1253         * bridge/npapi.h:
1254
1255 2008-04-30  Beth Dakin  <bdakin@apple.com>
1256
1257         Reviewed by Sam Weinig.
1258
1259         This patch does three things:
1260         1. Adds support for the "img" ARIA role
1261         2. Switches over to a HashMap for converting ARIA role attributes 
1262         to WebCore's AccessibilityRole type. 
1263         3. Fixes a crash in the new ARIA code that I ran into while 
1264         browsing with VoiceOver enabled.
1265
1266         * page/AccessibilityObject.cpp:
1267         (WebCore::AccessibilityObject::headingLevel): This is the crash 
1268         fix. Make sure the node's renderer is not null before looking up 
1269         its corresponding AccessibilityObject in the cache.
1270         (WebCore::AccessibilityObject::accessibilityIsIgnored): Account for 
1271         ARIA images.
1272         (WebCore::createARIARoleMap): Switch to HashMap, and add "img" to 
1273         the Map.
1274         (WebCore::RoleEntry::): Same.
1275         (WebCore::ariaRoleToWebCoreRole): Same.
1276         (WebCore::AccessibilityObject::ariaRoleAttribute): Same.
1277
1278 2008-04-30  Rob Buis  <buis@kde.org>
1279
1280         Reviewed by Nikolas.
1281
1282         https://bugs.webkit.org/show_bug.cgi?id=16447
1283         onload called too many times for <svg:image>
1284         https://bugs.webkit.org/show_bug.cgi?id=12282
1285         SVG wastes time in malloc to send loadEvents to non-existent listeners
1286
1287         Postpone load event dispatching for image when externalResourcesRequired
1288         is true, delaying parents but not siblings, and make sure the load event
1289         is sent once for image in all cases.
1290
1291         * svg/SVGElement.cpp:
1292         (WebCore::hasLoadListener):
1293         (WebCore::SVGElement::sendSVGLoadEventIfPossible):
1294         * svg/SVGImageElement.cpp:
1295         (WebCore::SVGImageElement::haveLoadedRequiredResources):
1296         * svg/SVGImageLoader.cpp:
1297         (WebCore::SVGImageLoader::dispatchLoadEvent):
1298
1299 2008-04-30  David Hyatt  <hyatt@apple.com>
1300
1301         Fix crashes when dynamically removing <video> elements with layers that establish stacking contexts.  This
1302         won't typically crash release builds because of arena recycling.
1303
1304         Reviewed by Dan Bernstein
1305         
1306         * rendering/RenderLayer.cpp:
1307         (WebCore::RenderLayer::~RenderLayer):
1308         Make sure to remove the reflection's child layer from its parent.
1309
1310         * rendering/RenderMedia.cpp:
1311         (WebCore::RenderMedia::~RenderMedia):
1312         (WebCore::RenderMedia::destroy):
1313         (WebCore::RenderMedia::removeChild):
1314         * rendering/RenderMedia.h:
1315         Adjust the teardown of RenderMedia so that it does all of its teardown inside destroy() (this makes it more
1316         like other renderers and doesn't leave you staring at a trashed layer hierarchy in the RenderMedia
1317         destructor).
1318
1319 2008-04-30  Rémi Zara  <remi_zara@mac.com>
1320
1321         Reviewed by Dave Hyatt.
1322
1323         fix https://bugs.webkit.org/show_bug.cgi?id=18618
1324         <rdar://problem/5876063> REGRESSION (r31823-r31847): Patterns are upside down
1325
1326         * svg/graphics/cg/SVGPaintServerPatternCg.cpp:
1327         (WebCore::patternCallback): flip the y axis when drawing the tile
1328
1329 2008-04-30  Timothy Hatcher  <timothy@apple.com>
1330
1331         Fixes an undefined type exception that fires when adding a resource to the inspector
1332         that has a MIME type warning.
1333
1334         Reviewed by Adam Roben.
1335
1336         * page/inspector/Resource.js:
1337         (WebInspector.Resource.prototype._addTip): Call WebInspector.console instead of
1338         WebInspector.consolePanel.
1339         (WebInspector.Resource.prototype._checkWarning): Ditto.
1340
1341 2008-04-30  Timothy Hatcher  <timothy@apple.com>
1342
1343         Fixes the bug where the selected resource would be deselected after
1344         changing the sort order in the Resources panel.
1345
1346         Reviewed by Dan Bernstein.
1347
1348         * page/inspector/ResourcesPanel.js:
1349         (WebInspector.ResourcesPanel.prototype._sortResourcesIfNeeded):
1350         Rememebr if the tree element that we are sorting was selected, so
1351         the selection can be restored after it is re-inserted. The onSelect
1352         is suppressed since we don't need to show the resource again.
1353
1354 2008-04-29  Timothy Hatcher  <timothy@apple.com>
1355
1356         Fixes the regression where error bubbles in source views always show
1357         "undefined" for the content because the message property on
1358         ConsoleMessage was removed. Adds support for a plain text formated
1359         message that is stored in the message proeprty.
1360
1361         Reviewed by Adam Roben.
1362
1363         * page/inspector/Console.js:
1364         (WebInspector.Console.prototype._format): Add a plainText argument that is passed to
1365         the formatters.
1366         (WebInspector.Console.prototype._formatvalue): Add a plainText argument, and a comment
1367         about needing to honor it if the textContent of the output doesn't make sense.
1368         (WebInspector.Console.prototype._formatvalue): Ditto.
1369         (WebInspector.Console.prototype._formatstring): Ditto.
1370         (WebInspector.Console.prototype._formatregexp): Ditto.
1371         (WebInspector.Console.prototype._formatarray): Ditto.
1372         (WebInspector.Console.prototype._formatnode): Ditto.
1373         (WebInspector.Console.prototype._formatobject): Ditto.
1374         (WebInspector.Console.prototype._formaterror): Ditto.
1375         (WebInspector.ConsoleMessage): Call _format passing true for plainText. Get the 
1376         textContnet of the result and assign to the message proeprty. This property is 
1377         referenced from the SourceView.
1378         (WebInspector.ConsoleMessage.prototype._format): Add a plainText argument. Build the 
1379         result element as a local and return it, instead of using formatedMessage directly.
1380
1381 2008-04-30  Timothy Hatcher  <timothy@apple.com>
1382
1383         Adds a helper function to convert a JSValueRef to a String.
1384
1385         Reviewed by Adam Roben.
1386
1387         * page/InspectorController.cpp:
1388         (WebCore::toString): Converts a JSValueRef to a String.
1389         (WebCore::search): Use toString.
1390         (WebCore::InspectorController::handleException): Ditto.
1391
1392 2008-04-30  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1393
1394         Reviewed by Simon.
1395         
1396         Build the Qt port with SVG Foreign Object support.
1397
1398         * WebCore.pro:
1399
1400 2008-04-30  Simon Hausmann  <hausmann@webkit.org>
1401
1402         Reviewed by Holger.
1403
1404         Fix null pointer deference triggered by
1405         LayoutTests/fast/loader/cancel-load-during-port-block-timer.html
1406
1407         * platform/network/qt/ResourceHandleQt.cpp:
1408         (WebCore::ResourceHandle::cancel): Check m_job before dereferencing.
1409
1410 2008-04-29  David Hyatt  <hyatt@apple.com>
1411
1412         Improve the performance of masks by adding code to set more precise clips on the transparency layers
1413         used to paint the content under the mask, and then also avoid creating transparency layers for the masks
1414         themselves in common cases.
1415
1416         Reviewed by Dan Bernstein
1417
1418         * platform/graphics/GraphicsContext.cpp:
1419         (WebCore::GraphicsContext::drawTiledImage):
1420         Fix a bug in drawTiledImage where the composite mode got lost in the double stretch case for nine piece
1421         images.
1422
1423         * rendering/InlineFlowBox.cpp:
1424         (WebCore::InlineFlowBox::paintFillLayers):
1425         (WebCore::InlineFlowBox::paintFillLayer):
1426         (WebCore::InlineFlowBox::paintMask):
1427         Optimize to only push a transparency layer for the mask if multiple images are combining.  Add a new
1428         composite operator argument for use when painting fill layers to do direct destination-in compositing while
1429         painting images.
1430
1431
1432         * rendering/InlineFlowBox.h:
1433         * rendering/RenderBox.cpp:
1434         (WebCore::RenderBox::paintMask):
1435         (WebCore::RenderBox::paintMaskImages):
1436         Optimize to only push a transparency layer for the mask if multiple images are combining.
1437
1438         (WebCore::RenderBox::maskClipRect):
1439         A new method that attempts to compute a precise clip rect for the mask images.
1440
1441         (WebCore::RenderBox::paintFillLayers):
1442         (WebCore::RenderBox::paintFillLayer):
1443         (WebCore::RenderBox::paintFillLayerExtended):
1444         * rendering/RenderBox.h:
1445         Added the composite operator argument to the paintFillLayer methods.
1446
1447         * rendering/RenderFieldset.cpp:
1448         (WebCore::RenderFieldset::paintMask):
1449         Call the new base class paintMaskImages method for optimized mask painting.
1450
1451         * rendering/RenderLayer.cpp:
1452         (WebCore::transparencyClipBox):
1453         Fix a coordinate space issue with transparencyClipBox when masks were used.  The border box was in the
1454         wrong coordinate space.  Moved the code into the layer's boundingBox() method instead.
1455
1456         (WebCore::RenderLayer::paintLayer):
1457         Removed the code that always pushed a transparency layer before painting masks.
1458
1459         (WebCore::RenderLayer::boundingBox):
1460         Call maskClipRect to shrink the bounding box of the layer to fit the mask clip.
1461
1462         * rendering/RenderObject.cpp:
1463         (WebCore::RenderObject::paintNinePieceImage):
1464         Added a composite operator argument for direct destination-in painting of nine piece images.
1465
1466         * rendering/RenderObject.h:
1467         (WebCore::RenderObject::maskClipRect):
1468         (WebCore::RenderObject::paintFillLayerExtended):
1469         Base class stubs for RenderBox-implemented methods.
1470
1471         * rendering/RenderTable.cpp:
1472         (WebCore::RenderTable::paintMask):
1473         * rendering/RenderTableCell.cpp:
1474         (WebCore::RenderTableCell::paintMask):
1475         Modified to call the new paintMaskImages function.
1476
1477         * svg/graphics/SVGImage.cpp:
1478         (WebCore::SVGImage::draw):
1479         SVG images now respect composite modes by pushing a transparency layer when the composite mode
1480         is anything other than source-over.
1481
1482 2008-04-30  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1483
1484         Rubber-stamped by Rob Buis.
1485
1486         Fixed crash or assertion if SVG_FOREIGN_OBJECT is not enabled
1487
1488         * svg/SVGUseElement.cpp:
1489         (WebCore::SVGUseElement::associateInstancesWithShadowTreeElements):
1490
1491 2008-04-30  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1492
1493         Rubber-stamped by Rob Buis.
1494
1495         Fixed compile, due to API change in XMLSerializer
1496
1497         * svg/SVGUseElement.cpp:
1498         (WebCore::SVGUseElement::buildPendingResource):
1499
1500 2008-04-30  Rob Buis  <buis@kde.org>
1501
1502         Reviewed by Eric.
1503
1504         https://bugs.webkit.org/show_bug.cgi?id=11939
1505         Quirksmode: Ignores media types in stylesheet PIs
1506
1507         Transfer the xml-stylesheet pseudo attribute media to the css
1508         stylesheet created from the ProcessingInstruction.
1509
1510         Tests: fast/css/xml-stylesheet-media-processing.xhtml
1511
1512         * css/StyleSheet.cpp:
1513         (WebCore::StyleSheet::setMedia):
1514         * css/StyleSheet.h:
1515         * dom/ProcessingInstruction.cpp:
1516         (WebCore::ProcessingInstruction::checkStyleSheet):
1517         (WebCore::ProcessingInstruction::setCSSStyleSheet):
1518         * dom/ProcessingInstruction.h:
1519
1520 2008-04-29  David D. Kilzer  <ddkilzer@apple.com>
1521
1522         BUILD FIX for export of WTF::RefCounted<WebCore::FormData>::deref()
1523
1524         On the buildbot, this is a fatal error:
1525
1526         ld: symbols names listed in -exported_symbols_list: WebKitBuild/Release/DerivedSources/WebCore/WebCore.exp not in linked objects
1527         __ZN3WTF10RefCountedIN7WebCore8FormDataEE5derefEv
1528         /usr/bin/libtool: internal link edit command failed
1529
1530         Newer dev tools only produce a warning:
1531
1532         ld warning: cannot export hidden symbol __ZN3WTF10RefCountedIN7WebCore8FormDataEE5derefEv from WebKitBuild/WebCore.build/Release/WebCore.build/Objects-normal/i386/DocumentLoader.o
1533
1534         * WebCore.base.exp: Remove hidden symbol from export list.
1535
1536 2008-04-29  David Kilzer  <ddkilzer@apple.com>
1537
1538         Another BUILD FIX for ENABLE(DASHBOARD_SUPPORT)
1539
1540         * dom/make_names.pl: Added #if ENABLE(DASHBOARD_SUPPORT) to Dashboard code.
1541
1542 2008-04-29  David Kilzer  <ddkilzer@apple.com>
1543
1544         BUILD FIX for ENABLE(DASHBOARD_SUPPORT)
1545
1546         * DerivedSources.make: Removed duplication of targets for
1547         generating CSSPropertyNames.h and CSSValueKeywords.h.
1548         * GNUmakefile.am: Ditto.  Added support for ENABLE_DASHBOARD_SUPPORT.
1549         * WebCore.pro: Added support for ENABLE_DASHBOARD_SUPPORT.
1550         Made both SVG and non-SVG variables of GENERATOR 6-A use new
1551         DASHBOARDSUPPORTCSSPROPERTIES variable.
1552
1553 2008-04-29  Ada Chan  <adachan@apple.com>
1554
1555         Added missing return.        
1556
1557         * platform/win/COMPtr.h:
1558         (WTF::):
1559
1560 2008-04-29  Alp Toker  <alp@nuanti.com>
1561
1562         GTK+ build fix attempt following breakage in r32700 which
1563         conditionalised dashboard support.
1564
1565         * GNUmakefile.am:
1566
1567 2008-04-29  Adam Roben  <aroben@apple.com>
1568
1569         Restore the beloved COMPtr::operator&
1570
1571         * platform/win/COMPtr.h: Removed the HashTableDeletedValueType
1572         constructor and isHashTableDeletedValue and hashTableDeletedValue
1573         functions.
1574         (WTF::): Changed constructDeletedValue to play nicely with
1575         COMPtr::operator&.
1576
1577 2008-04-29  Adam Roben  <aroben@apple.com>
1578
1579         Fix assertion on launch on Windows
1580
1581         * platform/graphics/win/FontPlatformData.h: Pass
1582         WTF::HashTableDeletedValue to the m_font constructor instead of a
1583         bogus -1 value. This is needed because m_font is a RefPtr.
1584
1585 2008-04-29  Greg Bolsinga  <bolsinga@apple.com>
1586
1587         Reviewed by Darin.
1588
1589         Wrapped Dashboard code with ENABLE(DASHBOARD_SUPPORT)
1590
1591         * DerivedSources.make:
1592         * WebCore.DashboardSupport.exp: Added.
1593         * WebCore.base.exp:
1594         * WebCore.xcodeproj/project.pbxproj:
1595         * bindings/js/JSDOMWindowCustom.cpp:
1596         (WebCore::JSDOMWindow::setLocation):
1597         * css/CSSComputedStyleDeclaration.cpp:
1598         (WebCore::):
1599         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1600         * css/CSSParser.cpp:
1601         (WebCore::CSSParser::parseValue):
1602         * css/CSSPrimitiveValue.cpp:
1603         (WebCore::CSSPrimitiveValue::cleanup):
1604         (WebCore::CSSPrimitiveValue::cssText):
1605         * css/CSSPropertyNames.in:
1606         * css/CSSStyleSelector.cpp:
1607         (WebCore::CSSStyleSelector::applyProperty):
1608         * css/DashboardRegion.h:
1609         * css/DashboardSupportCSSPropertyNames.in: Added.
1610         * dom/DOMImplementation.cpp:
1611         (WebCore::DOMImplementation::createDocument):
1612         * dom/Document.cpp:
1613         (WebCore::Document::Document):
1614         (WebCore::Document::importNode):
1615         * dom/Document.h:
1616         * html/CanvasRenderingContext2D.cpp:
1617         (WebCore::CanvasRenderingContext2D::fill):
1618         (WebCore::CanvasRenderingContext2D::stroke):
1619         (WebCore::CanvasRenderingContext2D::clip):
1620         * html/CanvasRenderingContext2D.h:
1621         * html/HTMLCanvasElement.cpp:
1622         * html/HTMLCanvasElement.h:
1623         * page/Chrome.cpp:
1624         * page/ChromeClient.h:
1625         * page/Frame.cpp:
1626         (WebCore::Frame::paint):
1627         * page/Frame.h:
1628         * page/FrameView.cpp:
1629         (WebCore::FrameView::layout):
1630         * page/FrameView.h:
1631         * page/Settings.cpp:
1632         (WebCore::Settings::Settings):
1633         * page/Settings.h:
1634         * page/mac/EventHandlerMac.mm:
1635         (WebCore::EventHandler::needsKeyboardEventDisambiguationQuirks):
1636         * page/mac/FrameMac.mm:
1637         * page/mac/WebDashboardRegion.h:
1638         * page/mac/WebDashboardRegion.m:
1639         * rendering/RenderLayer.cpp:
1640         (WebCore::RenderLayer::scrollToOffset):
1641         (WebCore::RenderLayer::setHasHorizontalScrollbar):
1642         (WebCore::RenderLayer::setHasVerticalScrollbar):
1643         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
1644         * rendering/RenderObject.cpp:
1645         (WebCore::RenderObject::setStyle):
1646         * rendering/RenderObject.h:
1647         * rendering/RenderStyle.cpp:
1648         (WebCore::StyleRareNonInheritedData::operator==):
1649         (WebCore::RenderStyle::diff):
1650         * rendering/RenderStyle.h:
1651         * xml/XMLHttpRequest.cpp:
1652         (WebCore::XMLHttpRequest::send):
1653         (WebCore::XMLHttpRequest::setRequestHeader):
1654
1655 2008-04-29  Adam Roben  <aroben@apple.com>
1656
1657         Windows build fix
1658
1659         This removes COMPtr::operator&, which didn't jive with HashTable. It
1660         is replaced by COMPtr::adoptionPointer.
1661
1662         Discussed with Darin Adler and Anders Carlsson.
1663
1664         * platform/win/COMPtr.h: Replaced operator& with adoptionPointer.
1665
1666 2008-04-29  David Hyatt  <hyatt@apple.com>
1667
1668         Implement the new box-reflect property in CSS.  This property enables real-time reflections on
1669         objects (yes you can reflect <video>!).
1670
1671         Reviewed by Dan Bernstein
1672
1673         Test cases added in fast/reflections/
1674
1675         * GNUmakefile.am:
1676         * WebCore.pro:
1677         * WebCore.xcodeproj/project.pbxproj:
1678         * WebCoreSources.bkl:
1679         * css/CSSComputedStyleDeclaration.cpp:
1680         (WebCore::):
1681         (WebCore::valueForReflection):
1682         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1683         * css/CSSParser.cpp:
1684         (WebCore::CSSParser::parseValue):
1685         (WebCore::CSSParser::parseReflect):
1686         (WebCore::BorderImageParseContext::commitBorderImage):
1687         (WebCore::CSSParser::parseBorderImage):
1688         (WebCore::parseGradientColorStop):
1689         (WebCore::CSSParser::parseTransform):
1690         * css/CSSParser.h:
1691         * css/CSSPropertyNames.in:
1692         * css/CSSReflectValue.cpp: Added.
1693         (WebCore::CSSReflectValue::cssText):
1694         * css/CSSReflectValue.h: Added.
1695         (WebCore::):
1696         (WebCore::CSSReflectValue::CSSReflectValue):
1697         (WebCore::CSSReflectValue::direction):
1698         (WebCore::CSSReflectValue::offset):
1699         (WebCore::CSSReflectValue::mask):
1700         (WebCore::CSSReflectValue::setDirection):
1701         (WebCore::CSSReflectValue::setOffset):
1702         (WebCore::CSSReflectValue::setMask):
1703         * css/CSSStyleSelector.cpp:
1704         (WebCore::CSSStyleSelector::adjustRenderStyle):
1705         (WebCore::CSSStyleSelector::applyProperty):
1706         (WebCore::CSSStyleSelector::mapNinePieceImage):
1707         * css/CSSStyleSelector.h:
1708         * rendering/InlineFlowBox.cpp:
1709         (WebCore::InlineFlowBox::placeBoxesVertically):
1710         (WebCore::InlineFlowBox::paintMask):
1711         * rendering/Length.h:
1712         (WebCore::Length::calcFloatValue):
1713         * rendering/RenderBlock.cpp:
1714         (WebCore::RenderBlock::overflowHeight):
1715         (WebCore::RenderBlock::overflowWidth):
1716         (WebCore::RenderBlock::overflowLeft):
1717         (WebCore::RenderBlock::overflowTop):
1718         (WebCore::RenderBlock::overflowRect):
1719         (WebCore::RenderBlock::layoutBlock):
1720         * rendering/RenderBox.cpp:
1721         (WebCore::RenderBox::setStyle):
1722         (WebCore::RenderBox::paintMask):
1723         (WebCore::RenderBox::imageChanged):
1724         (WebCore::RenderBox::computeAbsoluteRepaintRect):
1725         * rendering/RenderFlexibleBox.cpp:
1726         (WebCore::RenderFlexibleBox::layoutBlock):
1727         * rendering/RenderLayer.cpp:
1728         (WebCore::RenderLayer::RenderLayer):
1729         (WebCore::RenderLayer::~RenderLayer):
1730         (WebCore::RenderLayer::updateLayerPositions):
1731         (WebCore::RenderLayer::enclosingPositionedAncestor):
1732         (WebCore::RenderLayer::enclosingTransformedAncestor):
1733         (WebCore::RenderLayer::isTransparent):
1734         (WebCore::transparencyClipBox):
1735         (WebCore::RenderLayer::operator delete):
1736         (WebCore::RenderLayer::destroy):
1737         (WebCore::RenderLayer::removeOnlyThisLayer):
1738         (WebCore::RenderLayer::insertOnlyThisLayer):
1739         (WebCore::RenderLayer::paintLayer):
1740         (WebCore::RenderLayer::updateZOrderLists):
1741         (WebCore::RenderLayer::updateOverflowList):
1742         (WebCore::RenderLayer::collectLayers):
1743         (WebCore::RenderLayer::shouldBeOverflowOnly):
1744         (WebCore::RenderLayer::styleChanged):
1745         (WebCore::RenderLayer::reflectionLayer):
1746         (WebCore::RenderLayer::createReflection):
1747         (WebCore::RenderLayer::updateReflectionStyle):
1748         * rendering/RenderLayer.h:
1749         (WebCore::RenderLayer::hasReflection):
1750         (WebCore::RenderLayer::reflection):
1751         (WebCore::RenderLayer::paintingInsideReflection):
1752         * rendering/RenderObject.cpp:
1753         (WebCore::RenderObject::RenderObject):
1754         (WebCore::RenderObject::requiresLayer):
1755         (WebCore::RenderObject::setStyle):
1756         (WebCore::RenderObject::updateImage):
1757         (WebCore::RenderObject::reflectionBox):
1758         (WebCore::RenderObject::reflectionOffset):
1759         * rendering/RenderObject.h:
1760         (WebCore::RenderObject::hasTransform):
1761         (WebCore::RenderObject::setHasReflection):
1762         (WebCore::RenderObject::hasReflection):
1763         * rendering/RenderReplica.cpp: Added.
1764         (WebCore::RenderReplica::RenderReplica):
1765         (WebCore::RenderReplica::~RenderReplica):
1766         (WebCore::RenderReplica::layout):
1767         (WebCore::RenderReplica::calcPrefWidths):
1768         (WebCore::RenderReplica::paint):
1769         * rendering/RenderReplica.h: Added.
1770         (WebCore::RenderReplica::renderName):
1771         (WebCore::RenderReplica::requiresLayer):
1772         * rendering/RenderStyle.cpp:
1773         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1774         (WebCore::StyleRareNonInheritedData::operator==):
1775         (WebCore::StyleRareNonInheritedData::reflectionDataEquivalent):
1776         (WebCore::RenderStyle::diff):
1777         (WebCore::RenderStyle::applyTransform):
1778         * rendering/RenderStyle.h:
1779         (WebCore::TranslateTransformOperation::apply):
1780         (WebCore::StyleReflection::StyleReflection):
1781         (WebCore::StyleReflection::operator==):
1782         (WebCore::StyleReflection::operator!=):
1783         (WebCore::StyleReflection::direction):
1784         (WebCore::StyleReflection::offset):
1785         (WebCore::StyleReflection::mask):
1786         (WebCore::StyleReflection::setDirection):
1787         (WebCore::StyleReflection::setOffset):
1788         (WebCore::StyleReflection::setMask):
1789         (WebCore::RenderStyle::boxReflect):
1790         (WebCore::RenderStyle::setBoxReflect):
1791         (WebCore::RenderStyle::initialBoxReflect):
1792         * rendering/RenderTable.cpp:
1793         (WebCore::RenderTable::layout):
1794         (WebCore::RenderTable::paintMask):
1795         * rendering/RenderTableCell.cpp:
1796         (WebCore::RenderTableCell::requiresLayer):
1797         (WebCore::RenderTableCell::paintMask):
1798
1799 2008-04-29  Beth Dakin  <bdakin@apple.com>
1800
1801         Reviewed by Alice.
1802
1803         Initial implementation of the following ARIA roles: button, 
1804         checkbox, heading, link, radio, textbox.
1805
1806         * html/HTMLAttributeNames.in: Add 'role' to list of attributes.
1807
1808         * page/AccessibilityObject.cpp:
1809          When an ARIA role is set, the role overrides whatever the actual 
1810 element is when the element reports itself to the screen reader. So all of these isBlah functions report based on their roleValue now.
1811         (WebCore::AccessibilityObject::isWebArea):
1812         (WebCore::AccessibilityObject::isImageButton):
1813         (WebCore::AccessibilityObject::isAnchor):
1814         (WebCore::AccessibilityObject::isTextControl):
1815         (WebCore::AccessibilityObject::isImage):
1816         (WebCore::AccessibilityObject::isAttachment):
1817         (WebCore::AccessibilityObject::isPasswordField):
1818         (WebCore::AccessibilityObject::isCheckboxOrRadio):
1819         (WebCore::AccessibilityObject::isHeading):
1820         (WebCore::AccessibilityObject::isLink):
1821
1822         Check for ARIA information:
1823         (WebCore::AccessibilityObject::headingLevel):
1824         (WebCore::AccessibilityObject::anchorElement):
1825         (WebCore::AccessibilityObject::actionElement):
1826         (WebCore::AccessibilityObject::hasIntValue):
1827         (WebCore::AccessibilityObject::intValue):
1828         (WebCore::AccessibilityObject::stringValue):
1829         (WebCore::AccessibilityObject::title):
1830         (WebCore::AccessibilityObject::accessibilityIsIgnored):
1831         (WebCore::AccessibilityObject::roleValue):
1832
1833         There are a few places in the code where it is important to identify the difference between ARIA and non-ARIA.
1834         (WebCore::AccessibilityObject::isNativeImage):
1835         (WebCore::AccessibilityObject::isNativeTextControl):
1836         (WebCore::isARIAInput):
1837         (WebCore::isARIAControl):
1838
1839         A lot of spots in the code used to cast to RenderTextControl to get information about the text inside the element. Now that non-native text controls can run this code with the ARIA role 'textbox', it needs to be as general as possible. 
1840         (WebCore::AccessibilityObject::text): Still calls into 
1841         RenderTextControl's text() for native text controls. Uses Element's 
1842         innerText() for ARIA textboxes.
1843         (WebCore::AccessibilityObject::textLength): Call 
1844         AccessibilityObject's text() instead of RenderTextControl's.
1845         (WebCore::AccessibilityObject::ariaSelectedTextDOMRange):
1846         (WebCore::AccessibilityObject::selectedText):
1847         (WebCore::AccessibilityObject::selectedTextRange):
1848         (WebCore::AccessibilityObject::selectionStart):
1849         (WebCore::AccessibilityObject::selectionEnd):
1850         (WebCore::AccessibilityObject::setSelectedTextRange):
1851         (WebCore::AccessibilityObject::setValue):
1852         (WebCore::AccessibilityObject::visiblePositionForIndex):
1853         (WebCore::AccessibilityObject::indexForVisiblePosition):
1854         (WebCore::AccessibilityObject::textMarkerRangeForRange):
1855         (WebCore::AccessibilityObject::textMarkerForIndex):
1856         (WebCore::AccessibilityObject::indexForTextMarker):
1857         (WebCore::AccessibilityObject::doAXRangeForLine):
1858         (WebCore::AccessibilityObject::doAXRangeForIndex):
1859         (WebCore::AccessibilityObject::doAXStringForRange):
1860         (WebCore::AccessibilityObject::doAXBoundsForRange):
1861         
1862         Reports ARIA role. If the role is not valid or simply not set, return UnknownRole.
1863         (WebCore::AccessibilityObject::ariaRoleAttribute):
1864         
1865         Added several new functions. Most of them existed before but were static, or have been added to reduce the dependency on RenderTextControl for a lot of the text functionality.
1866         * page/AccessibilityObject.h:
1867
1868         Eliminated dependency on RenderTextControl cast. The information is generalized now and available directly through the AccessibilityObject.
1869         * page/mac/AccessibilityObjectWrapper.mm:
1870         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
1871         (-[AccessibilityObjectWrapper doAXAttributedStringForRange:]):
1872
1873 2008-04-29  Timothy Hatcher  <timothy@apple.com>
1874
1875         Make the exceptions that the InspectorController catches log the
1876         original file and line number, if present on the exception object.
1877
1878         Reviewed by Adam Roben.
1879
1880         * page/InspectorController.cpp:
1881         (WebCore::InspectorController::callFunction): Pass the context to HANDLE_EXCEPTION.
1882         (WebCore::InspectorController::~InspectorController): Ditto.
1883         (WebCore::InspectorController::scriptObjectReady): Ditto.
1884         (WebCore::InspectorController::addScriptResource): Ditto.
1885         (WebCore::InspectorController::updateScriptResourceRequest): Ditto.
1886         (WebCore::InspectorController::updateScriptResourceResponse): Ditto.
1887         (WebCore::InspectorController::updateScriptResource): Ditto.
1888         (WebCore::InspectorController::addDatabaseScriptResource): Ditto.
1889         (WebCore::InspectorController::addScriptConsoleMessage): Ditto.
1890         (WebCore::InspectorController::handleException): Take a context. Pull the line
1891         and sourceURL properties off the exception if it is an object.
1892         * page/InspectorController.h: Change handleException to take a context.
1893
1894 2008-04-29  Timothy Hatcher  <timothy@apple.com>
1895
1896         Fixes a regression where the Page's debugger would not be reattached
1897         when a new JSDOMWindow is created.
1898
1899         Reviewed by Sam Weinig.
1900
1901         * bindings/js/kjs_proxy.cpp:
1902         (WebCore::KJSProxy::clear): Call attachDebugger after creating the JSDOMWindow.
1903         * history/CachedPage.cpp:
1904         (WebCore::CachedPage::restore): For the case where the CachedPage doesn't
1905         contain a window, reattach the debugger to the new JSDOMWindow by calling
1906         proxy->attachDebugger. Also restore the setPageGroupIdentifier.
1907
1908 2008-04-29  Anatoli Papirovski  <apapirovski@mac.com>
1909
1910         Reviewed by Darin Adler.
1911
1912         Fix for https://bugs.webkit.org/show_bug.cgi?id=18355
1913         Fixed RGB and RGBA parsing to ignore the declaration when the value is not
1914         "either three integer values or three percentage values."
1915
1916         * css/CSSParser.cpp:
1917         (WebCore::CSSParser::parseColorParameters):
1918
1919 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
1920
1921         Reviewed by Simon.
1922
1923         Fix crash when setHtml gets called from slots connected to QWebPage::unsupportedContent
1924
1925         Ben found this crash in the demo browser.
1926
1927         In void MainResourceLoader::continueAfterContentPolicy(PolicyAction contentPolicy,
1928
1929         case PolicyDownload:
1930         frameLoader()->client()->download(m_handle.get(), request(), m_handle.get()->request(), r);
1931         receivedError(interruptionForPolicyChangeError());
1932
1933         We are in a policy check, the download() call will call setHtml, which will start loading
1934         the data into a frame. The loading will cancel all policy checks and call ResourceLoader::releaseResources
1935         which will set m_frame to 0. Then we return and invoke interruptionForPolicyChangeError() which
1936         will use the m_frame->loader() but it is gone. Do not call into receivedError and
1937         interruptionForPolicyChangeError if we are gone anyway...
1938
1939         * loader/MainResourceLoader.cpp:
1940         (WebCore::MainResourceLoader::continueAfterContentPolicy):
1941
1942 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
1943
1944         Reviewed by Simon.
1945
1946         Rely on auto-boxing of C++ for the QCursor c'tor
1947
1948         * platform/qt/CursorQt.cpp:
1949
1950 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
1951
1952         Reviewed by Simon.
1953
1954         Add the remaining cursors that defaulted to PointerCursor
1955
1956         * Resources/WebKitResources.qrc:
1957         * platform/qt/CursorQt.cpp:
1958         (WebCore::verticalTextCursor):
1959         (WebCore::cellCursor):
1960         (WebCore::contextMenuCursor):
1961         (WebCore::copyCursor):
1962         (WebCore::progressCursor):
1963         (WebCore::aliasCursor):
1964
1965 2008-04-29  Alice Liu  <alice.liu@apple.com>
1966
1967         Reviewed by Beth Dakin.
1968
1969         Comply with HTML5 spec about parsing tabindex property according to
1970         integer parsing rules
1971
1972         Test: fast/parser/tabindex-parsing.html
1973
1974         * html/HTMLElement.cpp:
1975         (WebCore::HTMLElement::parseMappedAttribute):
1976
1977 2008-04-29  Tor Arne Vestbø  <tavestbo@trolltech.com>
1978
1979         Reviewed by Simon.
1980
1981         Fixes: Fix timing problem where scrollbars in subframes were sometimes not property repainted.
1982
1983         https://bugs.webkit.org/show_bug.cgi?id=18482
1984
1985         We need to repaint scrollbars after a geometry change, and also make sure
1986         the computed clipping rect for the corners between scrollbars is propagated
1987         to the chrome client without beeing intersected by the visible content rect
1988         of the frame.
1989
1990         * platform/ScrollView.h:
1991         * platform/qt/ScrollViewQt.cpp:
1992         (WebCore::ScrollView::geometryChanged):
1993         (WebCore::ScrollView::suppressScrollbars):
1994         (WebCore::ScrollView::invalidateScrollbars):
1995
1996 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
1997
1998         Reviewed by Simon.
1999
2000         Calling QWebView::setCursor will override the WebCore Cursor.
2001         Calling QWebView::setCursor will override the WebCore Cursor using
2002         QWidget::unsetCursor will revert to the WebCore Cursor.
2003
2004         For detecting the unset we have to compare the shape of the
2005         cursor to the default arrow. Qt::WA_SetCursor can not be used
2006         as it is set unconditionally but conditionally removed.
2007
2008         Calling QWidget::setCursor will immediately send the CursorChange
2009         event. We listen to this event to decide if we currently use a
2010         WebCore cursor, got a cursor from outside, or revert to the default.
2011
2012         This should be race free and work reliable, the manual test for this
2013         is WebCore/manual-tests/cursor.html
2014
2015         * platform/qt/WidgetQt.cpp:
2016         (WebCore::Widget::setCursor):
2017
2018 2008-04-28  Dan Bernstein  <mitz@apple.com>
2019
2020         Reviewed by Maciej Stachowiak.
2021
2022         - fix https://bugs.webkit.org/show_bug.cgi?id=18795
2023           REGRESSION (r32660): Text heavier with text-shadow
2024
2025         * rendering/InlineTextBox.cpp:
2026         (WebCore::paintTextWithShadows): The loop was doing one extra pass
2027         without shadow even in cases where the last pass with a shadow was
2028         painting the text at the right position (rather than outside the clip).
2029         Fixed that. The only case where a separate pass without shadow is needed
2030         is when there is text-stroke, since in that case all shadow passes
2031         paint the text outside the clip.
2032
2033 2008-04-28  Brady Eidson <beidson@apple.com>
2034
2035         Reviewed by Sam Weinig
2036
2037         Add Storage.clear(), per updates to HTML5
2038
2039         Tests: storage/domstorage/localstorage/clear.html
2040                storage/domstorage/sessionstorage/clear.html
2041
2042         * storage/LocalStorageArea.cpp:
2043         (WebCore::LocalStorageArea::areaCleared):
2044         * storage/LocalStorageArea.h:
2045
2046         * storage/SessionStorageArea.cpp:
2047         (WebCore::SessionStorageArea::areaCleared):
2048         * storage/SessionStorageArea.h:
2049
2050         * storage/Storage.cpp:
2051         (WebCore::Storage::clear):
2052         * storage/Storage.h:
2053         * storage/Storage.idl:
2054
2055         * storage/StorageArea.cpp:
2056         (WebCore::StorageArea::internalClear):
2057         * storage/StorageArea.h:
2058         (WebCore::StorageArea::clear):
2059
2060 2008-04-28  Adele Peterson  <adele@apple.com>
2061
2062         Reviewed by Dan Bernstein, Tim Hatcher, Anders Carlsson, and Darin Adler.
2063
2064         WebCore part of fix for <rdar://problem/3709505>
2065         Safari should have a way to upload bundles from the file upload control (as zip)
2066
2067         * WebCore.base.exp: Added symbols.
2068
2069         * html/HTMLFormElement.cpp: (WebCore::HTMLFormElement::formData): Ask the application if a file will need to be replaced before it's uploaded.
2070           It will also give the replacement filename which is used to determine the correct mime-type and to construct the correct header.
2071
2072         * loader/FrameLoader.cpp:
2073         (WebCore::FrameLoader::submitForm): Asks the application to generate any files for the form data before a form submission starts.
2074         (WebCore::FrameLoader::loadItem): ditto.
2075         * loader/ResourceLoader.cpp:
2076         (WebCore::ResourceLoader::didReceiveResponse): Tells the FormData from the request to remove any generated files if it needs to.
2077         (WebCore::ResourceLoader::didCancel): ditto.
2078         (WebCore::ResourceLoader::didFail): ditto.
2079
2080         * platform/network/FormData.cpp:
2081         (WebCore::FormData::FormData): Initializes m_hasGeneratedFiles, which keeps track of whether there are files that will need to be removed.
2082         (WebCore::FormData::~FormData): Added.  Assert that there are no files that need to be removed, but if there are, release builds will still remove them here.
2083         (WebCore::FormData::appendFile): Passes along a shouldGenerateFile flag to the FormDataElement.
2084         (WebCore::FormData::generateFiles): Added. Iterates through the FormDataElements, and using the ChromeClient pointer, asks the application to
2085          create any compressed files so the FormDataElements can store the paths.
2086         (WebCore::FormData::removeGeneratedFilesIfNeeded): Added.  Removes generated files and their directories (if empty).
2087         * platform/network/FormData.h:
2088         (WebCore::FormDataElement::FormDataElement): Added a boolean to track whether the file will need to be generated,
2089          and a string to hold the path of the generated file.
2090
2091         * platform/network/mac/FormDataStreamMac.mm:
2092         (WebCore::advanceCurrentStream): Uses the generated file path instead of the original file path when streaming the file.
2093         (WebCore::setHTTPBody): Uses the generated file path when determining the size of the file to be uploaded.
2094
2095         * platform/FileSystem.h: Added directoryName.
2096         * platform/posix/FileSystemPOSIX.cpp: (WebCore::directoryName): Added.
2097         * platform/gtk/FileSystemGtk.cpp: (WebCore::directoryName): Added empty implementation.
2098         * platform/qt/FileSystemQt.cpp: (WebCore::directoryName): ditto.
2099         * platform/win/FileSystemWin.cpp: (WebCore::directoryName): ditto.
2100         * platform/wx/FileSystemWx.cpp: (WebCore::directoryName): ditto.
2101
2102         Added new ChromeClient methods to give the application control over the file compression for uploading.
2103         * page/Chrome.cpp:
2104         (WebCore::ChromeClient::shouldReplaceWithGeneratedFileForUpload): Added a default implementation.
2105         (WebCore::ChromeClient::generateReplacementFile): ditto.
2106         * page/ChromeClient.h:
2107
2108 2008-04-28  Anders Carlsson  <andersca@apple.com>
2109
2110         Reviewed by Sam, Mark, Adele and Darin.
2111
2112         Add a (currently not called) method for opening the application cache database.
2113         
2114         * WebCore.base.exp:
2115         * loader/appcache/ApplicationCacheStorage.cpp:
2116         (WebCore::ApplicationCacheStorage::setCacheDirectory):
2117         (WebCore::ApplicationCacheStorage::openDatabase):
2118         * loader/appcache/ApplicationCacheStorage.h:
2119
2120 2008-04-28  Alice Liu  <alice.liu@apple.com>
2121
2122         Reviewed by Darin.
2123
2124         Fix <rdar://problem/4911289> Add tabindex property to all children 
2125         of HTMLElement (7138)
2126         http://bugs.webkit.org/show_bug.cgi?id=7138
2127
2128         Test: fast/events/tabindex-focus-blur-all.html
2129
2130         * WebCore.xcodeproj/project.pbxproj:
2131         * bindings/objc/DOMPrivate.h:
2132         -DOMHTMLLabelElementPrivate.h and DOMHTMLLegendElementPrivate.h are no
2133          longer needed
2134
2135         * bindings/objc/PublicDOMInterfaces.h:
2136         -Moving focus, blur, tabindex to HTMLElement from its descendants.
2137
2138         * dom/Node.cpp:
2139         (WebCore::Node::Node):
2140         (WebCore::Node::isFocusable):
2141         (WebCore::Node::isKeyboardFocusable):
2142         -The concept of being focusable now needs to account for tabindex
2143         attribute.
2144
2145         * dom/Node.h:
2146         -Need to use a bit to keep track of whether tabindex was explicitly set
2147          to 0 or was just initialized to 0.
2148         (WebCore::Node::tabIndex):
2149         -Make this virtual so that Anchors and GenericFormElements can determine
2150          tabindex without accounting for focusability
2151         (WebCore::Node::setTabIndexExplicitly):
2152         -Renamed setTabIndex() to setTabIndexExplicitly() so as not to hide
2153          behind and/or be confused for HTMLElement::setTabIndex
2154
2155         * html/HTMLAnchorElement.cpp:
2156         * html/HTMLAnchorElement.h:
2157         (WebCore::HTMLAnchorElement::tabIndex):
2158         * html/HTMLGenericFormElement.cpp:
2159         * html/HTMLGenericFormElement.h:
2160         (WebCore::HTMLGenericFormElement::tabIndex):
2161         -Anchors and form elements are normally focusable, and need to avert the
2162          check for focusability in HTMLElement::tabIndex
2163          because tabIndex could be queried before a first layout happens.
2164
2165         * html/HTMLElement.cpp:
2166         (WebCore::HTMLElement::parseMappedAttribute):
2167         -Function Node::setTabIndex changed to Node::setTabIndexExplicitly
2168         (WebCore::HTMLElement::isFocusable):
2169         -The concept of being focusable now needs to account for tabindex
2170          attribute.
2171         (WebCore::HTMLElement::tabIndex):
2172         -HTML5 specifies that querying tabindex for elements that aren't
2173          focusable shall return -1
2174         (WebCore::HTMLElement::setTabIndex):
2175         -New default implementation
2176         * html/HTMLElement.h:
2177
2178         * html/HTMLLegendElement.cpp:
2179         (WebCore::HTMLLegendElement::focus):
2180         -Now with HTML5's enhanced specification of tabindex, legend elements
2181          themselves shall focus (if they should), and not the first form element 
2182          they encapsulate.  This matches Firefox behavior.  HTMLLabelElements
2183          still forward focus to the encapsulated element.  This also matches
2184          other browsers. 
2185
2186         * html/HTMLAreaElement.cpp:
2187         (WebCore::HTMLAreaElement::isFocusable):
2188         * html/HTMLAreaElement.h:
2189         -HTMLAreaElement isn't subject to the same focusability requirements as
2190          its parent, HTMLAnchorElement. Default HTMLElement implementation is
2191          desired.  
2192
2193         * html/HTMLFieldSetElement.cpp:
2194         (WebCore::HTMLFieldSetElement::isFocusable):
2195         * html/HTMLLegendElement.cpp:
2196         (WebCore::HTMLLegendElement::isFocusable):
2197         * html/HTMLOptGroupElement.cpp:
2198         (WebCore::HTMLOptGroupElement::isFocusable):
2199         * html/HTMLOptionElement.cpp:
2200         (WebCore::HTMLOptionElement::isFocusable):
2201         -These elements aren't subject to the same focusability requirements as
2202          their parent, HTMLGenericFormElement. Default HTMLElement 
2203          implementation is desired.  
2204
2205         * html/HTMLAnchorElement.idl:
2206         * html/HTMLAreaElement.idl:
2207         * html/HTMLButtonElement.idl:
2208         * html/HTMLElement.idl:
2209         * html/HTMLInputElement.idl:
2210         * html/HTMLLabelElement.idl:
2211         * html/HTMLLegendElement.idl:
2212         * html/HTMLObjectElement.idl:
2213         * html/HTMLSelectElement.idl:
2214         * html/HTMLTextAreaElement.idl:
2215         -Moving tabindex attribute, focus and blur methods from descendants of
2216          HTMLElement to HTMLElement
2217
2218 2008-04-28  Dan Bernstein  <mitz@apple.com>
2219
2220         Reviewed by Dave Hyatt.
2221
2222         - support multiple box- and text-shadows
2223
2224         Tests: fast/css/shadow-multiple.html
2225                fast/repaint/shadow-multiple-horizontal.html
2226                fast/repaint/shadow-multiple-strict-horizontal.html
2227                fast/repaint/shadow-multiple-strict-vertical.html
2228                fast/repaint/shadow-multiple-vertical.html
2229
2230         * css/CSSComputedStyleDeclaration.cpp:
2231         (WebCore::valueForShadow): Changed to account for reversing the order
2232         of the shadow values in the ShadowData list.
2233
2234         * css/CSSValueList.cpp:
2235         (WebCore::CSSValueList::prepend): Added.
2236         * css/CSSValueList.h:
2237
2238         * rendering/InlineFlowBox.cpp:
2239         (WebCore::InlineFlowBox::placeBoxesHorizontally): Changed to account for
2240         all shadows in overflow calculation.
2241         (WebCore::InlineFlowBox::placeBoxesVertically): Ditto.
2242         (WebCore::InlineFlowBox::paint): Changed to account for all shadows
2243         when testing for intersection with the damage rect.
2244         (WebCore::InlineFlowBox::paintTextDecorations): Changed to paint all
2245         shadows.
2246
2247         * rendering/InlineTextBox.cpp:
2248         (WebCore::paintTextWithShadows): Factored out from paint() and changed
2249         to paint all shadows.
2250         (WebCore::InlineTextBox::paint): Moved the text painting code out to
2251         paintTextWithShadows(). Changed to not paint shadows for markers and
2252         composition underlines and in "force black text" mode.
2253         (WebCore::InlineTextBox::paintSelection):
2254         (WebCore::InlineTextBox::paintCompositionBackground):
2255         (WebCore::InlineTextBox::paintDecoration): Changed to paint all shadows.
2256         * rendering/InlineTextBox.h: Changed some public methods to private
2257         or protected.
2258
2259         * rendering/RenderBlock.cpp:
2260         (WebCore::RenderBlock::overflowHeight): Changed to account for all
2261         shadows.
2262         (WebCore::RenderBlock::overflowWidth): Ditto.
2263         (WebCore::RenderBlock::overflowLeft): Ditto.
2264         (WebCore::RenderBlock::overflowTop): Ditto.
2265         (WebCore::RenderBlock::overflowRect): Ditto.
2266         (WebCore::RenderBlock::layoutBlock): Ditto.
2267
2268         * rendering/RenderFlexibleBox.cpp:
2269         (WebCore::RenderFlexibleBox::layoutBlock): Ditto.
2270
2271         * rendering/RenderLayer.cpp:
2272         (WebCore::RenderLayer::calculateRects): Ditto.
2273
2274         * rendering/RenderObject.cpp:
2275         (WebCore::RenderObject::paintBoxShadow): Changed to paint all shadows.
2276         Changed to avoid clipping out the box if it has a fully opaque
2277         background.
2278         (WebCore::RenderObject::repaintAfterLayoutIfNeeded): Changed to account
2279         for all shadows.
2280         (WebCore::RenderObject::selectionForegroundColor): Cleaned up.
2281         (WebCore::RenderObject::adjustRectForOutlineAndShadow): Changed to
2282         account for all shadows.
2283
2284         * rendering/RenderReplaced.cpp:
2285         (WebCore::RenderReplaced::adjustOverflowForBoxShadow): Ditto.
2286
2287         * rendering/RenderStyle.cpp:
2288         (WebCore::RenderStyle::setTextShadow): Changed to prepend when adding
2289         so that the stacking order of shadows when painting will be "first o
2290         top".
2291         (WebCore::RenderStyle::setBoxShadow): Ditto.
2292
2293         * rendering/RenderTable.cpp:
2294         (WebCore::RenderTable::layout): Changed to account for all shadows.
2295
2296 2008-04-28  Adam Roben  <aroben@apple.com>
2297
2298         Fix some more Windows build errors in COMPtr
2299
2300         * platform/win/COMPtr.h:
2301         (WTF::): Define DefaultHash<COMPtr<P> > by using PtrHash<COMPtr<P> >,
2302         which is just a copy of PtrHash<RefPtr<P> >.
2303
2304 2008-04-28  Adam Roben  <aroben@apple.com>
2305
2306         Fix some Windows build errors in COMPtr
2307
2308         * platform/win/COMPtr.h: Explicitly name the WTF namespace when using
2309         HashTableDeletedValueType.
2310
2311 2008-04-28  Adam Roben  <aroben@apple.com>
2312
2313         Fix some Windows build errors in FontPlatfomrData
2314
2315         * platform/graphics/win/FontPlatformData.h: Removed the Deleted
2316         constructor and replaced it with a HashTableDeletedValueType
2317         constructor. Also added isHashTableDeletedValue() and
2318         hashTableDeletedFontValue().
2319
2320 2008-04-28  David Hyatt  <hyatt@apple.com>
2321
2322         https://bugs.webkit.org/show_bug.cgi?id=18780
2323
2324         Canvas can't draw itself into its own buffer.  Make sure the dirtying call comes after the image()
2325         has been accessed.  Technically willDraw should be renamed to didDraw and all calls should be moved
2326         to after draws have occurred (since if the draw op itself wants to reference the image it shouldn't get
2327         a dirty copy either), but I'll take that up with olliej when he wakes up. :)
2328
2329         Reviewed by Dan Bernstein
2330
2331         Added fast/canvas/canvasDrawsIntoSelf.html
2332
2333         * html/CanvasRenderingContext2D.cpp:
2334         (WebCore::CanvasRenderingContext2D::drawImage):
2335
2336 2008-04-28  Alexey Proskuryakov  <ap@webkit.org>
2337
2338         Reviewed by Geoff Garen.
2339
2340         <rdar://problem/5825192> Replace use of Gestalt with BSD sysctl
2341
2342         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2343         (WebCore::MediaPlayerPrivate::isAvailable): There is no need to check QuickTime version post-Tiger,
2344         as it will never be below 7.3 again. This change may make library loading happen earlier in
2345         some cases, hopefully, that's not a big deal.
2346
2347 2008-04-25  Alexey Proskuryakov  <ap@webkit.org>
2348
2349         Reviewed by Darin.
2350
2351         Fix run-webkit-tests --threading
2352         and provisionally fix <https://bugs.webkit.org/show_bug.cgi?id=18661>
2353         Proxy server issue in Sunday's Nightly
2354
2355         Adjusted for JavaScriptCore changes: added a new member to ClassInfo objects, turned
2356         ClassInfo::propHashTable into a function, made getPropertyAttributes() take an ExecState pointer.
2357
2358         * bindings/js/JSAudioConstructor.cpp:
2359         (WebCore::):
2360         * bindings/js/JSDOMWindowBase.cpp:
2361         (WebCore::):
2362         * bindings/js/JSDOMWindowCustom.cpp:
2363         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
2364         * bindings/js/JSDOMWindowWrapper.cpp:
2365         (WebCore::):
2366         (WebCore::JSDOMWindowWrapper::getPropertyAttributes):
2367         * bindings/js/JSDOMWindowWrapper.h:
2368         * bindings/js/JSEventTargetBase.h:
2369         (WebCore::JSEventTargetPrototype::classInfo):
2370         * bindings/js/JSHTMLInputElementBase.cpp:
2371         (WebCore::):
2372         * bindings/js/JSHTMLOptionElementConstructor.cpp:
2373         (WebCore::):
2374         * bindings/js/JSHistoryCustom.cpp:
2375         (WebCore::JSHistory::customGetOwnPropertySlot):
2376         * bindings/js/JSImageConstructor.cpp:
2377         (WebCore::):
2378         * bindings/js/JSInspectedObjectWrapper.cpp:
2379         (WebCore::):
2380         * bindings/js/JSInspectorCallbackWrapper.cpp:
2381         (WebCore::):
2382         * bindings/js/JSLocationCustom.cpp:
2383         (WebCore::JSLocation::customGetOwnPropertySlot):
2384         (WebCore::JSLocation::customPut):
2385         * bindings/js/JSNamedNodesCollection.cpp:
2386         (WebCore::):
2387         * bindings/js/JSQuarantinedObjectWrapper.cpp:
2388         (WebCore::):
2389         * bindings/js/JSRGBColor.cpp:
2390         (WebCore::):
2391         * bindings/js/JSStorageCustom.cpp:
2392         (WebCore::JSStorage::customPut):
2393         * bindings/js/JSXMLHttpRequestConstructor.cpp:
2394         (WebCore::):
2395         * bindings/js/JSXSLTProcessor.cpp:
2396         (WebCore::):
2397         * bindings/scripts/CodeGeneratorJS.pm:
2398         * bridge/objc/objc_runtime.mm:
2399         * bridge/runtime_array.cpp:
2400         * bridge/runtime_object.cpp:
2401
2402 2008-04-28  David Hyatt  <hyatt@apple.com>
2403
2404         https://bugs.webkit.org/show_bug.cgi?id=18779
2405
2406         The arguments in drawImage were reversed when I switched away from the image buffer method.
2407
2408         Reviewed by Tim Hatcher
2409
2410         Added fast/canvas/drawImage.html
2411
2412         * html/CanvasRenderingContext2D.cpp:
2413         (WebCore::CanvasRenderingContext2D::drawImage):
2414
2415 2008-04-28  Holger Hans Peter Freyther  <zecke@selfish.org>
2416
2417         Reviewed by Simon.
2418
2419         Fix the crash on http://www.orad.pl. We called end too early.
2420
2421         1. we need a ::write that will pause the parser due a pending
2422         script
2423         2. we need a second write to queue data (tricky part)
2424         3. we need to get a finish call (document loaded)
2425         4. we resume the script and parse, schedule loading of a new script
2426         and have called end
2427         5. we resume the new script and we get a crash
2428
2429         This bug is hard to trigger, e.g. if the web server is only allowing
2430         one connection per client/IP. This is why we need to sleep in the scripts. We
2431         want to make sure that the page is first fully received before serving the
2432         scripts.
2433
2434         Test: http/tests/misc/xmltokenizer-do-not-crash.pl
2435
2436         * dom/XMLTokenizer.cpp:
2437
2438 2008-04-28  Ariya Hidayat  <ahidayat@trolltech.com>
2439
2440         Reviewed by Simon.
2441
2442         Fix rounded corner on combo box with CSS border
2443
2444         * platform/qt/RenderThemeQt.cpp:
2445         (WebCore::RenderThemeQt::adjustMenuListButtonStyle):
2446
2447 2008-04-28  Ariya Hidayat  <ahidayat@trolltech.com>
2448
2449         Reviewed by Simon.
2450
2451         Fix CSS border does not show up for combo boxes
2452
2453         Do not clear the border when painting the combo box for 'select' form element
2454
2455         * platform/qt/RenderThemeQt.cpp:
2456
2457 2008-04-28  Olivier Goffart  <ogoffart@trolltech.com>
2458
2459         Reviewed by Simon.
2460
2461         Avoid comparing to 0 in qFuzzyCompare for increased
2462         numeric stability.
2463
2464         * platform/graphics/qt/PathQt.cpp:
2465         (WebCore::Path::addArc):
2466
2467 2008-04-28  Benjamin Meyer  <bmeyer@trolltech.com>
2468
2469         Reviewed by Simon.
2470
2471         Fixes: Pages returning 404 with content are not displayed.
2472
2473         A web page that returns 404 can still have content.
2474
2475         * platform/network/qt/QNetworkReplyHandler.cpp:
2476         (WebCore::QNetworkReplyHandler::finish):
2477
2478 2008-04-28  Paul Olav Tvete  <paul@trolltech.com>
2479
2480         Reviewed by Simon.
2481
2482         Fix compiler warning; Avoid the implicity QString(const char *)
2483         constructor
2484
2485         * platform/qt/RenderThemeQt.cpp:
2486         (WebCore::RenderThemeQt::fallbackStyle):
2487
2488 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
2489
2490         Reviewed by Simon.
2491
2492         Prevent middle-click from triggering open URL from clipboard when the event has already been accepted.
2493
2494         * platform/qt/PlatformScrollBarQt.cpp:
2495         (WebCore::PlatformScrollbar::handleMousePressEvent):
2496
2497 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
2498
2499         Reviewed by Simon.
2500
2501         Fix scrollbar behavior in QtWebKit to match QScrollBar.
2502
2503         Right click context menu is now supported, along with
2504         middle click to center slider thumb over mouse cursor.
2505
2506         * platform/qt/PlatformScrollBar.h:
2507         * platform/qt/PlatformScrollBarQt.cpp:
2508         (tr):
2509         (WebCore::PlatformScrollbar::pixelPosToRangeValue):
2510         (WebCore::PlatformScrollbar::handleMousePressEvent):
2511         (WebCore::PlatformScrollbar::handleMouseReleaseEvent):
2512         (WebCore::PlatformScrollbar::handleContextMenuEvent):
2513
2514 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
2515
2516         Reviewed by Simon.
2517
2518         Implemented channel-based logging for QtWebKit.
2519
2520         Comma-separated log channels are read from the QT_WEBKIT_LOG environment variable.
2521         Warnings for notImplemented() is still output by default, but can be disabled
2522         by setting DISABLE_NI_WARNINGS=1.
2523
2524         * WebCore.pro:
2525         * platform/NotImplemented.h:
2526         * platform/qt/LoggingQt.cpp: Added.
2527         (WebCore::getChannelFromName):
2528         (WebCore::InitializeLoggingChannelsIfNecessary):
2529
2530 2008-04-28  Simon Hausmann  <shausman@trolltech.com>
2531
2532         Reviewed by Holger.
2533
2534         Fixes: Popups/Context menu in WebKit appearing at the wrong location when embedded in the graphics view or using multiple screens
2535
2536         Give the popups the right parent widget and the right coordinates relative within the parent.
2537
2538         * platform/qt/PopupMenuQt.cpp:
2539         (WebCore::PopupMenu::show):
2540
2541 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
2542
2543         Reviewed by Simon.
2544
2545         Fixes: Tabbing to a checkbox/button doesn't work on Win/X11
2546
2547         Respect platform settings for tabbing to all controls.
2548
2549         * page/qt/EventHandlerQt.cpp:
2550
2551 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
2552
2553         Reviewed by Simon.
2554
2555         First part of the fix for tabbing to a checkbox/button doesn't work on Win/X11
2556
2557         Draw controls instead of pimitive elements, to get focus rects for free.
2558
2559         * platform/qt/RenderThemeQt.cpp:
2560         (WebCore::RenderThemeQt::paintButton):
2561
2562 2008-04-28  Lincoln Ramsay  <lincoln.ramsay@trolltech.com>
2563
2564         Reviewed by Simon.
2565
2566         Compile when QT_NO_CLIPBOARD is defined.
2567
2568         * platform/qt/ClipboardQt.cpp:
2569         (WebCore::ClipboardQt::ClipboardQt):
2570         (WebCore::ClipboardQt::clearData):
2571         (WebCore::ClipboardQt::clearAllData):
2572         (WebCore::ClipboardQt::setData):
2573         (WebCore::ClipboardQt::declareAndWriteDragImage):
2574         (WebCore::ClipboardQt::writeURL):
2575         (WebCore::ClipboardQt::writeRange):
2576         * platform/qt/PasteboardQt.cpp:
2577         (WebCore::Pasteboard::writeSelection):
2578         (WebCore::Pasteboard::plainText):
2579         (WebCore::Pasteboard::documentFragment):
2580         (WebCore::Pasteboard::writeURL):
2581         (WebCore::Pasteboard::writeImage):
2582
2583 2008-04-28  Ariya Hidayat  <ariya.hidayat@trolltech.com>
2584
2585         Reviewed by Simon.
2586
2587         Draw the arrow button on the styled combo box using the fallback ("Windows") style
2588
2589         * platform/qt/RenderThemeQt.cpp:
2590         (WebCore::RenderThemeQt::RenderThemeQt):
2591         (WebCore::RenderThemeQt::~RenderThemeQt):
2592         (WebCore::RenderThemeQt::fallbackStyle):
2593         (WebCore::RenderThemeQt::paintMenuListButton):
2594         (WebCore::RenderThemeQt::adjustMenuListButtonStyle):
2595         * platform/qt/RenderThemeQt.h:
2596
2597 2008-04-28  Simon Hausmann  <hausmann@webkit.org>
2598
2599         Reviewed by Holger.
2600
2601         Fix positioning of native widgets (plugins).
2602
2603         Correctly convert the coordinates of the Widget in Widget::setFrameGeometry()
2604         to be relative to the containing toplevel QWidget using convertToContainingWindow().
2605
2606         Note: convertToContainingWindow() takes child coordinates.
2607
2608         * platform/qt/WidgetQt.cpp:
2609         (WebCore::Widget::frameGeometry):
2610         (WebCore::Widget::setFrameGeometry):
2611
2612 2008-04-28  Holger Hans Peter Freyther  <zecke@selfish.org>
2613
2614         Reviewed by Simon.
2615
2616         plugins: fix scrolling issues
2617
2618         When scrolling you can see artefacts that remain on the screen, they
2619         seem to originate from the backingstore handling. I'm not entirely sure
2620         where they come from, my workarounds involved a
2621         data->m_widget->parentWidget()->update() call in Widget::geometryChanged or
2622         handling widgets with a native QWidget embedded like web pages with a
2623         static background. This needs more investigations, I think the ScrollView
2624         change is cleaner than the brute force in Widget::geometryChanged
2625
2626         Focus handling seems to be broken as well and needs further work, we don't
2627         clip plugin QWidgets and they can draw out of their bounds, e.g. on the ScrollBar,
2628         the z-order is likely not honored as well.
2629
2630         * platform/ScrollView.h:
2631         * platform/qt/ScrollViewQt.cpp:
2632         (WebCore::ScrollView::ScrollViewPrivate::ScrollViewPrivate):
2633         (WebCore::ScrollView::ScrollViewPrivate::scrollBackingStore):
2634         (WebCore::ScrollView::addChild):
2635         (WebCore::ScrollView::removeChild):
2636         (WebCore::ScrollView::incrementNativeWidgetCount):
2637         (WebCore::ScrollView::decrementNativeWidgetCount):
2638         (WebCore::ScrollView::hasNativeWidgets):
2639
2640 2008-04-28  Holger Hans Peter Freyther  <zecke@selfish.org>
2641
2642         Reviewed by Simon.
2643
2644         Add manual test to test placement of QWidgets in iframe's
2645
2646         * manual-tests/qt/main.html: Added.
2647         * manual-tests/qt/qtplugin.html: Added.
2648
2649 2008-04-28  Simon Hausmann  <hausmann@webkit.org>
2650
2651         Fix the build with ENABLE_DATABASE=0 (Qt/Windows) by including
2652         SecurityOrigin.h. It's used in the file and also implicitly included
2653         through the database headers.
2654
2655         * page/DOMWindow.cpp:
2656
2657 2008-04-28  Simon Hausmann  <hausmann@webkit.org>
2658
2659         Prospective Wx build fix.
2660
2661         * platform/graphics/wx/FontPlatformData.h:
2662
2663 2008-04-28  Simon Hausmann  <hausmann@webkit.org>
2664
2665         Reviewed by Alp.
2666
2667         Gtk build fix, similar to the changes done in r32609.
2668
2669         * platform/graphics/gtk/FontPlatformData.h:
2670         (WebCore::FontPlatformData::FontPlatformData):
2671         (WebCore::FontPlatformData::isHashTableDeletedValue):
2672         (WebCore::FontPlatformData::hashTableDeletedFontValue):
2673
2674 2008-04-28  Simon Hausmann  <hausmann@webkit.org>
2675
2676         Prospective build fix. After r32609 it seems the workaround here
2677         is not needed anymore. With gcc 4.2/4.3 before 32609 the workaround
2678         is needed for compilation, after 32609 compilation only succeeds
2679         without the workaround.
2680
2681         * plugins/PluginPackage.h: Removed workaround of extra StorageTraits
2682         specification for the custom hash function of PluginPackage used in
2683         PluginSet.
2684
2685 2008-04-28  Tor Arne Vestbø  <tavestbo@trolltech.com>
2686
2687         Reviewed by Simon.
2688
2689         https://bugs.webkit.org/show_bug.cgi?id=18713
2690
2691         Fix scrollbar painting issues in QtWebKit.
2692
2693         Hovering and click-draging outside of the scrollbar would
2694         produce unexpected and inconcistent results. We also didn't
2695         pass on leave-events to the underlying WebKit code, which
2696         was nessecary to implement the paint fix.
2697
2698         * platform/qt/PlatformScrollBarQt.cpp:
2699         (WebCore::PlatformScrollbar::handleMouseMoveEvent):
2700         (WebCore::PlatformScrollbar::handleMouseOutEvent):
2701         (WebCore::PlatformScrollbar::handleMouseReleaseEvent):
2702
2703 2008-04-27  Oliver Hunt  <oliver@apple.com>
2704
2705         Reviewed by Maciej.
2706
2707         Bug 17173: HTML5 Canvas API requires us to ignore certain operations
2708         <https://bugs.webkit.org/show_bug.cgi?id=17173>
2709
2710         This fixes the semantics of a number of Canvas functions to match
2711         the new HTML5 non-throwing semantics.
2712
2713         Test: fast/canvas/canvas-path-with-inf-nan-dimensions.html
2714
2715         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2716         (WebCore::JSCanvasRenderingContext2D::strokeRect):
2717         * html/CanvasRenderingContext2D.cpp:
2718         (WebCore::CanvasRenderingContext2D::moveTo):
2719         (WebCore::CanvasRenderingContext2D::lineTo):
2720         (WebCore::CanvasRenderingContext2D::quadraticCurveTo):
2721         (WebCore::CanvasRenderingContext2D::bezierCurveTo):
2722         (WebCore::CanvasRenderingContext2D::arcTo):
2723         (WebCore::CanvasRenderingContext2D::arc):
2724         (WebCore::validateRectForCanvas):
2725         (WebCore::CanvasRenderingContext2D::rect):
2726         (WebCore::CanvasRenderingContext2D::clearRect):
2727         (WebCore::CanvasRenderingContext2D::fillRect):
2728         (WebCore::CanvasRenderingContext2D::strokeRect):
2729         * html/CanvasRenderingContext2D.h:
2730         * html/CanvasRenderingContext2D.idl:
2731
2732 2008-04-27  Rob Buis  <buis@kde.org>
2733
2734         Reviewed by Adele.
2735
2736         https://bugs.webkit.org/show_bug.cgi?id=18652
2737         onchange events don't seem to fire for input[type=range] controls.
2738
2739         Fire changeEvent when dragging the slider.
2740
2741         Test: fast/forms/slider-onchange-event.html
2742
2743         * rendering/RenderSlider.cpp:
2744         (WebCore::RenderSlider::valueChanged):
2745
2746 2008-04-25  Darin Adler  <darin@apple.com>
2747
2748         Reviewed by Maciej.
2749
2750         - update for compatibility with HashTable that no longer has optimization to share
2751           implementation between hash tables with integers, pointers, RefPtr, and String
2752           objects as keys
2753
2754         * bindings/js/JSSVGPODTypeWrapper.h:
2755         (WebCore::PODTypeReadWriteHashInfo::PODTypeReadWriteHashInfo): Added constructor
2756         for HashTableDeletedValue.
2757         (WebCore::PODTypeReadWriteHashInfo::isHashTableDeletedValue): Added.
2758         (WebCore::PODTypeReadWriteHashInfoTraits::constructDeletedValue): Added.
2759         (WebCore::PODTypeReadWriteHashInfoTraits::isDeletedValue): Added.
2760
2761         * dom/Document.cpp: Made changedDocuments internal to the file rather than a
2762         static data member of Document.
2763         (WebCore::FormElementKey::ref): Removed unneeded check for deleted value -- this
2764         will never be called on a deleted element.
2765         (WebCore::FormElementKey::deref): Ditto.
2766
2767         * dom/Document.h: Added HashTableDeletedValue constructor and isHashTableDeletedValue
2768         to FormElementKey. Changed FormElementKeyHashTraits to use construct/isDeletedValue.
2769         Got rid of the changedDocuments data member. Changed iconURL to be an inline that
2770         returns a const String&.
2771
2772         * dom/StyledElement.cpp: Changed MappedAttributeKeyTraits to use
2773         construct/isDeletedValue.
2774
2775         * page/mac/AXObjectCacheMac.mm:
2776         (WebCore::AXObjectCache::getAXID): Call isDeletedValue instead of deletedValue.
2777
2778         * platform/SecurityOriginHash.h: Added overload so that SecurityOriginHash can work
2779         with raw pointers as well as RefPt (helpful with the new RefPtrHashMap). Eliminated
2780         SecurityOriginTraits, since we can now use the default traits. Changed the value of
2781         safeToCompareToEmptyOrDeleted to false, since it's not safe to compare a deleted
2782         value using this hash function. I don't think it was safe before either; I'm not sure
2783         why it didn't cause a problem before.
2784
2785         * platform/cf/SchedulePair.h: Removed SchedulePairTraits -- custom traits are no
2786         longer needed.
2787
2788         * platform/graphics/FontCache.cpp:
2789         (WebCore::FontPlatformDataCacheKey::FontPlatformDataCacheKey): Added constructor
2790         for HashTableDeletedValue.
2791         (WebCore::FontPlatformDataCacheKey::isHashTableDeletedValue): Added.
2792         (WebCore::FontPlatformDataCacheKey::hashTableDeletedSize): Added.
2793         (WebCore::FontPlatformDataCacheKeyTraits::constructDeletedValue): Added.
2794         (WebCore::FontPlatformDataCacheKeyTraits::isDeletedValue): Added.
2795         (WebCore::FontDataCacheKeyTraits::constructDeletedValue): Added.
2796         (WebCore::FontDataCacheKeyTraits::isDeletedValue): Added.
2797
2798         * platform/graphics/IntSizeHash.h: Changed HashTraits<IntSize> to use
2799         construct/isDeletedValue.
2800
2801         * platform/graphics/mac/FontPlatformData.h:
2802         (WebCore::FontPlatformData::FontPlatformData): Added constructor for
2803         HashTableDeletedValue.
2804         (WebCore::FontPlatformData::isHashTableDeletedValue): Added.
2805         (WebCore::FontPlatformData::hashTableDeletedFontValue): Added.
2806
2807         * platform/text/PlatformString.h:
2808         (WebCore::String::swap): Added. Avoids any refcount churn when swapping two strings.
2809         (WebCore::String::String): Added constructor for HashTableDeletedValue.
2810         (WebCore::String::isHashTableDeletedValue): Added.
2811         (WebCore::swap): Added. Avoids any refcount churn when swapping two strings.
2812
2813         * platform/text/StringHash.h: Changed specialization of HashTraits for
2814         WebCore::String to use the deleted value now defined in that class and removed
2815         the code to do ref/deref. Removed HashKeyStorageTraits specializations.
2816         
2817         * platform/win/COMPtr.h: Changed specialization of HashTraits for
2818         COMPtr to use the deleted value now defined in that class and removed
2819         the code to do ref/deref. Removed HashKeyStorageTraits specializations.
2820         (COMPtr::COMPtr): Added constructor for HashTableDeletedValue.
2821         (COMPtr::isHashTableDeletedValue): Added.
2822         (COMPtr::query): Removed inline keyword not needed since functions defined in the
2823         class definition are automatically marked inline.
2824         (COMPtr::hashTableDeletedValue): Added.
2825
2826         * storage/DatabaseTracker.h: Removed now-unneeded SecurityOriginTraits.
2827         * storage/LocalStorage.h: Ditto.
2828         * storage/OriginQuotaManager.h: Ditto.
2829         * storage/SessionStorage.h: Ditto.
2830
2831         * svg/SVGAnimatedTemplate.h:
2832         (WebCore::SVGAnimatedTypeWrapperKey::SVGAnimatedTypeWrapperKey): Added constructor
2833         for HashTableDeletedValue.
2834         (WebCore::SVGAnimatedTypeWrapperKey::isHashTableDeletedValue): Added.
2835         (WebCore::SVGAnimatedTypeWrapperKeyHashTraits::constructDeletedValue): Added.
2836         (WebCore::SVGAnimatedTypeWrapperKeyHashTraits::isDeletedValue): Added.
2837
2838 2008-04-27  Mark Rowe  <mrowe@apple.com>
2839
2840         Reviewed by Tim Hatcher.
2841
2842         Initialize the extra member of the xmlEntity struct when using libxml2 >= 2.6.27.
2843
2844         * dom/XMLTokenizer.cpp:
2845         (WebCore::):
2846
2847 2008-04-27  Dan Bernstein  <mitz@apple.com>
2848
2849         Reviewed by Darin Adler.
2850
2851         - fix https://bugs.webkit.org/show_bug.cgi?id=3729
2852           <rdar://problem/4036353> REGRESSION: arrow keys move insertion bar backwards in RTL text
2853
2854         Test: editing/selection/move-left-right.html
2855
2856         * editing/SelectionController.cpp:
2857         (WebCore::SelectionController::modifyMovingRight): Added. Currently
2858         implemented for character granularity, all other being treated as
2859         "forward".
2860         (WebCore::SelectionController::modifyMovingForward): Renamed
2861         modifyMovingRightForward() to this.
2862         (WebCore::SelectionController::modifyMovingLeft): Added. Currently
2863         implemented for character granularity, all other being treated as
2864         "backward".
2865         (WebCore::SelectionController::modifyMovingBackward): Renamed
2866         modifyMovingLeftBackward() to this.
2867         (WebCore::SelectionController::modify): Changed to call either the
2868         visual (left/right) or logical (backward/forward) methods depending on
2869         the 'dir' argument for moves.
2870         * editing/SelectionController.h:
2871         * editing/VisiblePosition.cpp:
2872         (WebCore::VisiblePosition::leftVisuallyDistinctCandidate): Added.
2873         (WebCore::VisiblePosition::left): Added.
2874         (WebCore::VisiblePosition::rightVisuallyDistinctCandidate): Added.
2875         (WebCore::VisiblePosition::right): Added.
2876         * editing/VisiblePosition.h:
2877
2878 2008-04-27  Sam Weinig  <sam@webkit.org>
2879
2880         Reviewed by Maciej Stachowiak.
2881
2882         Fix for <rdar://problem/5893385> Need to provide access to the CanvasRenderingContext2D prototype
2883         Add a JS constructor for CanvasRenderingContext2D.
2884
2885         * html/CanvasRenderingContext2D.idl:
2886         * page/DOMWindow.idl:
2887
2888 2008-04-26  Adam Barth  <hk9565@gmail.com>
2889
2890         Reviewed by Adam Roben and Sam Weinig.
2891
2892         Fixes bug http://bugs.webkit.org/show_bug.cgi?id=17331
2893         Fixes bug http://bugs.webkit.org/show_bug.cgi?id=16848
2894         
2895         Updates postMessage implementation to match HTML 5 specification:
2896         1) Adds origin parameter to postMessage.
2897         2) Removes domain and uri attributes of MessageEvent in favor of
2898            origin attribute.
2899
2900         In order to do this correctly, we need to distinguish between hosts and domains
2901         in the SecurityOrigin class. There are now three ways to compare security origins:
2902         1) isSameSchemeHostPort compares scheme, host, and port, and is used for postMessage
2903         2) equal compares all aspects of the security origin, and is used for hash keys
2904         3) canAccess understands the semantics of schemes such as file:// and data:// URLs,
2905            and should be used for scripting access checks.
2906
2907         Changed SecurityOrigin::toString() to generate identifiers that are suitable for 
2908         being used as a MessageEvent's origin property. In the future, they could be used 
2909         as database string identifiers as well. Re-used KURL parser to parse serialized 
2910         SecurityOrigins.
2911
2912         Collin Jackson <collinj-webkit@collinjackson.com> also contributed to this patch.
2913         
2914         Tests: http/tests/security/postMessage/invalid-origin-throws-exception.html
2915                http/tests/security/postMessage/javascript-page-still-sends-origin.html
2916                http/tests/security/postMessage/origin-unaffected-by-base-tag.html
2917                http/tests/security/postMessage/origin-unaffected-by-document-domain.html
2918                http/tests/security/postMessage/target-origin.html
2919
2920         * WebCore.base.exp:
2921         * bindings/js/JSDOMWindowCustom.cpp:
2922         (WebCore::JSDOMWindow::postMessage):
2923         * dom/Document.cpp:
2924         (WebCore::Document::domain):
2925         * dom/MessageEvent.cpp:
2926         (WebCore::MessageEvent::MessageEvent):
2927         (WebCore::MessageEvent::initMessageEvent):
2928         * dom/MessageEvent.h:
2929         (WebCore::MessageEvent::origin):
2930         * dom/MessageEvent.idl:
2931         * html/CanvasRenderingContext2D.cpp:
2932         (WebCore::CanvasRenderingContext2D::checkOrigin):
2933         (WebCore::CanvasRenderingContext2D::createPattern):
2934         * page/DOMWindow.cpp:
2935         (WebCore::DOMWindow::postMessage):
2936         * page/DOMWindow.h:
2937         * page/DOMWindow.idl:
2938         * platform/SecurityOrigin.cpp:
2939         (WebCore::SecurityOrigin::SecurityOrigin):
2940         (WebCore::SecurityOrigin::create):
2941         (WebCore::SecurityOrigin::createForFrame):
2942         (WebCore::SecurityOrigin::copy):
2943         (WebCore::SecurityOrigin::setDomainFromDOM):
2944         (WebCore::SecurityOrigin::canAccess):
2945         (WebCore::SecurityOrigin::isSecureTransitionTo):
2946         (WebCore::SecurityOrigin::toString):
2947         (WebCore::SecurityOrigin::createFromString):
2948         (WebCore::SecurityOrigin::createFromDatabaseIdentifier):
2949         (WebCore::SecurityOrigin::databaseIdentifier):
2950         (WebCore::SecurityOrigin::equal):
2951         (WebCore::SecurityOrigin::isSameSchemeHostPort):
2952         * platform/SecurityOrigin.h:
2953         (WebCore::SecurityOrigin::host):
2954         (WebCore::SecurityOrigin::domain):
2955         * platform/SecurityOriginHash.h:
2956         (WebCore::SecurityOriginTraits::deletedValue):
2957         * storage/DatabaseTracker.cpp:
2958         (WebCore::DatabaseTracker::hasEntryForDatabase):
2959         (WebCore::DatabaseTracker::originPath):
2960         (WebCore::DatabaseTracker::fullPathForDatabase):
2961         (WebCore::DatabaseTracker::populateOrigins):
2962         (WebCore::DatabaseTracker::databaseNamesForOrigin):
2963         (WebCore::DatabaseTracker::detailsForNameAndOrigin):
2964         (WebCore::DatabaseTracker::setDatabaseDetails):
2965         (WebCore::DatabaseTracker::setQuota):
2966         (WebCore::DatabaseTracker::addDatabase):
2967         (WebCore::DatabaseTracker::deleteOrigin):
2968         (WebCore::DatabaseTracker::deleteDatabase):
2969
2970 2008-04-26  Kevin Ollivier  <kevino@theolliviers.com>
2971
2972         wx build fix. Add the AX*ActionVerb functions to the wx build.
2973         
2974         * platform/wx/LocalizedStringsWx.cpp:
2975         (WebCore::AXButtonActionVerb):
2976         (WebCore::AXRadioButtonActionVerb):
2977         (WebCore::AXTextFieldActionVerb):
2978         (WebCore::AXCheckedCheckBoxActionVerb):
2979         (WebCore::AXUncheckedCheckBoxActionVerb):
2980         (WebCore::AXLinkActionVerb):
2981
2982 2008-04-26  Robin Dunn  <robin@alldunn.com>
2983
2984         Reviewed by Kevin Ollivier.
2985
2986         wx build fix. Add needed wx includes for compilation.
2987
2988         https://bugs.webkit.org/show_bug.cgi?id=18758
2989
2990         * platform/wx/FileSystemWx.cpp:
2991
2992 2008-04-26  Anatoli Papirovski  <apapirovski@mac.com>
2993
2994         Reviewed by Dave Hyatt.
2995
2996         Fix for https://bugs.webkit.org/show_bug.cgi?id=18583
2997         WebKit should ignore declarations with a negative value for
2998         line-height and font-size, including in the shorthand font form.
2999
3000         Tests: fast/css/font-size-negative.html
3001                fast/css/line-height-negative.html
3002
3003         * css/CSSParser.cpp:
3004         (WebCore::CSSParser::parseValue):
3005         (WebCore::CSSParser::parseFont):
3006
3007 2008-04-25  Anders Carlsson  <andersca@apple.com>
3008
3009         Reviewed by Sam.
3010
3011         Add empty ApplicationCacheStorage class.
3012         
3013         * WebCore.vcproj/WebCore.vcproj:
3014         * WebCore.xcodeproj/project.pbxproj:
3015         * loader/appcache/ApplicationCacheStorage.cpp: Added.
3016         (WebCore::cacheStorage):
3017         * loader/appcache/ApplicationCacheStorage.h: Added.
3018
3019 2008-04-24  Sam Weinig  <sam@webkit.org>
3020
3021         Reviewed by Geoffrey Garen.
3022
3023         Replace the JSDOMWindow with a new one instead of clearing it.
3024
3025         * bindings/js/JSDOMWindowBase.cpp:
3026         (WebCore::JSDOMWindowBase::clear):
3027         Don't reset the window.
3028
3029         * bindings/js/kjs_proxy.cpp:
3030         (WebCore::KJSProxy::clear):
3031         Replace the current JSDOMWindow stored in the wrapper window
3032         with a new one.
3033
3034         * history/CachedPage.cpp:
3035         (WebCore::CachedPage::CachedPage):
3036         (WebCore::CachedPage::restore):
3037         (WebCore::CachedPage::clear):
3038         * history/CachedPage.h:
3039         Instead of storing the builtins, properties and localstorage in
3040         special holding structs, store the entire JSDOMWindow.
3041
3042         For the case of a page that has no JSDOMWindow before it's first
3043         navigation, has one created while it is in the cache and is then
3044         navigated back, create a new JSDOMWindow to keep the assumption
3045         in JSDOMWindowWrapper that it always has the correct window.
3046
3047         * loader/FrameLoader.cpp:
3048         (WebCore::FrameLoader::clear):
3049         We must clear the DOMWindow first, so that we create a new JSDOMWindow,
3050         it gets a new one.
3051
3052         * page/Frame.cpp:
3053         (WebCore::Frame::clearDOMWindow):
3054         Null out the domWindow so that on the next access, a new one is
3055         created.
3056
3057 2008-04-25  Sam Weinig  <sam@webkit.org>
3058
3059         Reviewed by Mark Rowe.
3060
3061         The EventListeners need to operate and store JSDOMWindows, not JSDOMWrapperWindows.
3062
3063         * bindings/js/JSDOMWindowBase.cpp:
3064         (WebCore::JSDOMWindowBase::~JSDOMWindowBase):
3065         (WebCore::JSDOMWindowBase::findOrCreateJSEventListener):
3066         (WebCore::JSDOMWindowBase::findOrCreateJSUnprotectedEventListener):
3067         * bindings/js/JSSVGLazyEventListener.cpp:
3068         (WebCore::JSSVGLazyEventListener::JSSVGLazyEventListener):
3069         * bindings/js/JSSVGLazyEventListener.h:
3070         * bindings/js/kjs_events.cpp:
3071         (WebCore::JSAbstractEventListener::handleEvent):
3072         (WebCore::JSUnprotectedEventListener::JSUnprotectedEventListener):
3073         (WebCore::JSUnprotectedEventListener::~JSUnprotectedEventListener):
3074         (WebCore::JSUnprotectedEventListener::window):
3075         (WebCore::JSUnprotectedEventListener::clearWindow):
3076         (WebCore::JSEventListener::JSEventListener):
3077         (WebCore::JSEventListener::~JSEventListener):
3078         (WebCore::JSEventListener::window):
3079         (WebCore::JSEventListener::clearWindow):
3080         (WebCore::JSLazyEventListener::JSLazyEventListener):
3081         (WebCore::JSLazyEventListener::parseCode):
3082         * bindings/js/kjs_events.h:
3083         * bindings/js/kjs_proxy.cpp:
3084         (WebCore::KJSProxy::createHTMLEventHandler):
3085         (WebCore::KJSProxy::createSVGEventHandler):
3086
3087 2008-04-25  Mark Rowe  <mrowe@apple.com>
3088
3089         Rubber-stamped by Sam Weinig.
3090
3091         Add some content to an empty ICU header file to prevent verification errors.
3092
3093         * icu/unicode/utf_old.h:
3094
3095 2008-04-25  Anders Carlsson  <andersca@apple.com>
3096
3097         Fix tyop.
3098         
3099         * loader/DocumentLoader.cpp:
3100         (WebCore::DocumentLoader::scheduleApplicationCacheLoad):
3101
3102 2008-04-25  Anders Carlsson  <andersca@apple.com>
3103
3104         Reviewed by Sam.
3105
3106         Add and honor offlineWebApplicationCacheEnabled setting.
3107         
3108         * WebCore.base.exp:
3109         * loader/DocumentLoader.cpp:
3110         (WebCore::DocumentLoader::scheduleApplicationCacheLoad):
3111         * loader/MainResourceLoader.cpp:
3112         (WebCore::MainResourceLoader::load):
3113         * loader/appcache/ApplicationCacheGroup.cpp:
3114         (WebCore::ApplicationCacheGroup::selectCache):
3115         (WebCore::ApplicationCacheGroup::selectCacheWithoutManifestURL):
3116         * page/Settings.cpp:
3117         (WebCore::Settings::Settings):
3118         (WebCore::Settings::setOfflineWebApplicationCacheEnabled):
3119         * page/Settings.h:
3120         (WebCore::Settings::offlineWebApplicationCacheEnabled):
3121
3122 2008-04-25  Anders Carlsson  <andersca@apple.com>
3123
3124         Reviewed by Adam.
3125
3126         <rdar://problem/5629139>
3127         PluginInfoStoreWin needs to implement pluginNameForMIMEType().
3128         
3129         * plugins/PluginInfoStore.cpp:
3130         (WebCore::PluginInfoStore::pluginNameForMIMEType):
3131
3132 2008-04-25  Tor Arne Vestbø  <tavestbo@trolltech.com>
3133
3134         Reviewed by Simon.
3135
3136         Respect antialiasing hint when drawing focus rects.
3137
3138         * platform/graphics/qt/GraphicsContextQt.cpp:
3139         (WebCore::GraphicsContext::drawFocusRing):
3140
3141 2008-04-25  Holger Hans Peter Freyther  <zecke@selfish.org>
3142
3143         Reviewed by Simon.
3144
3145         networking: Use Qt::QueuedConnection in QNetworkReplyHandler
3146
3147         Make sure we leave the networking backend before calling
3148         into WebCore. Otheriwse we might return to the networking
3149         backend when it is already deleted.
3150
3151         * platform/network/qt/QNetworkReplyHandler.cpp:
3152         (WebCore::FormDataIODevice::setParent):
3153         (WebCore::QNetworkReplyHandler::start):
3154
3155 2008-04-25  Tor Arne Vestbø  <tavestbo@trolltech.com>
3156
3157         Reviewed by Simon.
3158
3159         Fix propagation of mouse double click events.
3160
3161         Treat a mouse double click as a regular mouse press with just a different click count.
3162
3163         * platform/qt/PlatformMouseEventQt.cpp:
3164         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
3165
3166 2008-04-25  Tor Arne Vestbø  <tavestbo@trolltech.com>
3167
3168         Reviewed by Simon.
3169
3170         Fixes: Fix strange button sizes (push, radio, and check) in QtWebKit.
3171
3172         We now use pixel metrics instead of fixed sizes for the
3173         button margins, or if the style supports layout rects we
3174         use the delta between the content rect and the layout rect.
3175
3176         In adition we compensate for the difference between the size
3177         for content and the actual layout rect (if supported) by
3178         reporting back the layout rect to WebKit for page layout,
3179         and then inflating the rect we actually paint to.
3180
3181         * platform/qt/RenderThemeQt.cpp:
3182         (WebCore::StylePainter::StylePainter):
3183         (WebCore::StylePainter::~StylePainter):
3184         (WebCore::RenderThemeQt::RenderThemeQt):
3185         (WebCore::inflateButtonRect):
3186         (WebCore::RenderThemeQt::adjustRepaintRect):
3187         (WebCore::RenderThemeQt::isControlStyled):
3188         (WebCore::computeSizeBasedOnStyle):
3189         (WebCore::RenderThemeQt::setCheckboxSize):
3190         (WebCore::RenderThemeQt::paintCheckbox):
3191         (WebCore::RenderThemeQt::setRadioSize):
3192         (WebCore::RenderThemeQt::adjustButtonStyle):
3193         (WebCore::RenderThemeQt::setButtonSize):
3194         (WebCore::RenderThemeQt::setButtonPadding):
3195         (WebCore::RenderThemeQt::paintButton):
3196         (WebCore::RenderThemeQt::adjustMenuListStyle):
3197         (WebCore::RenderThemeQt::setPopupPadding):
3198         (WebCore::RenderThemeQt::paintMenuList):
3199         * platform/qt/RenderThemeQt.h:
3200
3201 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
3202
3203         Reviewed by Holger.
3204
3205         Fixes: Valgrind warnings about uninitilized variables used in jumps
3206
3207         * rendering/RenderText.cpp:
3208         (WebCore::RenderText::trimmedPrefWidths):
3209
3210 2008-04-25  Warwick Allison  <warwick@trolltech.com>
3211
3212         Reviewed by Simon.
3213
3214         Added simple getter function to PlatformScrollBar to return the
3215         maximum value. Needed in the WebKit/qt API.
3216
3217         * platform/qt/PlatformScrollBar.h:
3218
3219 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
3220
3221         Reviewed by Holger, Simon.
3222
3223         Implement NoDrop, ZoomIn, and ZoomOut cursors
3224
3225         * Resources/WebKitResources.qrc:
3226         * platform/qt/CursorQt.cpp:
3227         (WebCore::noDropCursor):
3228         (WebCore::notAllowedCursor):
3229         (WebCore::zoomInCursor):
3230         (WebCore::zoomOutCursor):
3231
3232 2008-04-25  Holger Hans Peter Freyther  <zecke@selfish.org>
3233
3234         Reviewed by Simon.
3235
3236         Handle the ListboxAppearance as 'TextField' as well. We are mainly interested in the background.
3237
3238         RenderBox will call us to paint the outline/background, it is handled the same as a
3239         TextAreaAppearance in RenderTheme, handle it the same in the RenderThemeQt
3240
3241         * platform/qt/RenderThemeQt.cpp:
3242         (WebCore::RenderThemeQt::paintTextField):
3243
3244 2008-04-25  Holger Hans Peter Freyther  <zecke@selfish.org>
3245
3246         Reviewed by Simon.
3247
3248         No reason to exit the application when we can not paint something. Replace the Q_ASSERT
3249         with a runtime check. Return true to indicate that we did not handle the painting
3250         of this element.
3251
3252         * platform/qt/RenderThemeQt.cpp:
3253         (WebCore::RenderThemeQt::paintTextField):
3254
3255 2008-04-25  Holger Hans Peter Freyther  <zecke@selfish.org>
3256
3257         Reviewed by Simon.
3258
3259         Correct the comment. We are in painTextField and don't paint a button.
3260
3261         * platform/qt/RenderThemeQt.cpp:
3262         (WebCore::RenderThemeQt::paintTextField):
3263
3264 2008-04-25  Holger Hans Peter Freyther  <zecke@selfish.org>
3265
3266         Reviewed by Simon.
3267
3268         Allow ListboxAppearance to take focus as well. Stolen from Tor Arne
3269
3270         * platform/qt/RenderThemeQt.cpp:
3271         (WebCore::RenderThemeQt::supportsFocus):
3272
3273 2008-04-25  Simon Hausmann  <hausmann@webkit.org>
3274
3275         Reviewed by Holger.
3276
3277         Remove debug output.
3278
3279         * platform/network/qt/ResourceHandleQt.cpp:
3280         (WebCore::ResourceHandle::loadResourceSynchronously):
3281
3282 2008-04-25  Holger Hans Peter Freyther  <zecke@selfish.org>
3283
3284         Reviewed by Simon.
3285
3286         Change the string for searchableIndexIntroduction() to match the mac
3287         and pass http/tests/misc/isindex-formdata.html
3288
3289         * platform/qt/Localizations.cpp:
3290
3291 2008-04-25  Simon Hausmann  <hausmann@webkit.org>
3292
3293         Reviewed by Holger.
3294
3295         When we encounter a new/unknown HTTP request type report it back to WebCore as loading error.
3296
3297         * platform/network/qt/QNetworkReplyHandler.cpp:
3298         (WebCore::QNetworkReplyHandler::start):
3299
3300 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
3301
3302         Reviewed by Simon.
3303
3304         Fix crash in the networking layer.
3305
3306         Set the m_reply to null right after calling deleteLater().
3307
3308         * platform/network/qt/QNetworkReplyHandler.cpp:
3309         (WebCore::QNetworkReplyHandler::finish):
3310
3311 2008-04-24  Mark Rowe  <mrowe@apple.com>
3312
3313         Rubber-stamped by Oliver Hunt.
3314
3315         * WebCore.base.exp: Remove two symbols from the export list that don't need to be exported.
3316
3317 2008-04-24  Dan Bernstein  <mitz@apple.com>
3318
3319         Reviewed by Dave Hyatt.
3320
3321         - fix https://bugs.webkit.org/show_bug.cgi?id=18722
3322           <rdar://problem/5888360> REGRESSION (3.1 -> TOT): Webkit Nightly Build crashes when visiting i has a hotdog
3323
3324         Test: fast/dynamic/float-remove-above-line.html
3325
3326         * rendering/bidi.cpp:
3327         (WebCore::RenderBlock::layoutInlineChildren): Avoid adding floats that
3328         do not intrude into the line to its floats vector. When such floats go
3329         away, they do not dirty the line (because they do not intersect with it)
3330         and having it keep them in its floats vector is what caused the crash.
3331
3332 2008-04-24  Justin Garcia  <justin.garcia@apple.com>
3333
3334         Reviewed by John Sullivan.
3335         
3336         It is possible, despite our safeguards, for createMarkup to iterate past the end of the Range
3337         that is passed to it.  Added a null check to prevent crashes in this situation (we won't crash but
3338         we will create too much markup), and added an ASSERT to hopefully catch the scenario in a debugger 
3339         and help us understand what's going on.
3340
3341         * editing/markup.cpp:
3342         (WebCore::createMarkup):
3343
3344 2008-04-24  Mark Rowe  <mrowe@apple.com>
3345
3346         Reviewed by Sam Weinig.
3347
3348         Remove code for calculating the glyph cache size.
3349
3350         * WebCore.base.exp: Remove unused symbol.
3351         * platform/graphics/mac/FontCacheMac.mm: Remove code that is unused now that we do not compute the glyph cache size.
3352         * platform/mac/WebCoreSystemInterface.h: Remove unused symbol.
3353         * platform/mac/WebCoreSystemInterface.mm: Ditto.
3354
3355 2008-04-24  Mark Rowe  <mrowe@apple.com>
3356
3357         Reviewed by Sam Weinig.
3358
3359         Add a definition of BUILDING_ON_LEOPARD to complement BUILDING_ON_TIGER.
3360
3361         * WebCorePrefix.h:
3362
3363 2008-04-24  Cameron McCormack  <cam@mcc.id.au>
3364
3365         Reviewed by Maciej Stachowiak.
3366
3367         Ensure that changes to rx="" and ry="" attributes on an SVG <rect>
3368         element cause a relayout.
3369
3370         Test: svg/dom/SVGRectElement/rect-modify-rx.svg
3371
3372         * svg/SVGRectElement.cpp:
3373         (WebCore::SVGRectElement::svgAttributeChanged): Call needsLayout()
3374         when the attribute is rx or ry.
3375         (WebCore::SVGRectElement::hasRelativeValues): Return true when the
3376         attribute is rx or ry, since they also can have relative values.
3377
3378 2008-04-24  Adam Barth  <hk9565@gmail.com>
3379
3380         Reviewed by Sam Weinig.
3381
3382         Update the XMLHttpRequest header black list to match the spec.
3383
3384         * xml/XMLHttpRequest.cpp:
3385         (WebCore::isSafeRequestHeader):
3386
3387 2008-04-22  Feng Qian  <ian.eng.webkit@gmail.com>
3388
3389         Reviewed by Geoff Garen.
3390
3391         Fix https://bugs.webkit.org/show_bug.cgi?id=18677
3392         Bug 18677: Synchronous event dispatch confuses the popup blocker into incorrectly blocking chat popups in gmail.com.
3393
3394         Test: fast/events/nested-window-event.html
3395
3396         * bindings/js/kjs_events.cpp:
3397         (WebCore::JSAbstractEventListener::handleEvent): Save and restore the current event around the event dispatch.
3398
3399 2008-04-24  Brady Eidson  <beidson@apple.com>
3400
3401         Reviewed by Teh Mitzpettel
3402
3403         Make it so PageGroups know what their own name is.
3404
3405         * WebCore.base.exp:
3406
3407         * page/Page.cpp:
3408         (WebCore::Page::setGroupName):
3409         (WebCore::Page::groupName):
3410         * page/Page.h:
3411
3412         * page/PageGroup.cpp: Move the PageGroupMap into the PageGroup class.
3413         (WebCore::PageGroup::PageGroup): Added a c'tor that takes the group name as an argument instead of
3414           the initial Page.
3415         (WebCore::PageGroup::pageGroup): Handles creating and mapping names to groups
3416         * page/PageGroup.h:
3417         (WebCore::PageGroup::name):
3418
3419 2008-04-24  Adele Peterson  <adele@apple.com>
3420
3421         Reviewed by Darin.
3422
3423         Consolidate two versions of pathGetFileName.
3424
3425         * html/HTMLFormElement.cpp: (WebCore::HTMLFormElement::formData): Call FileSystem.h version of pathGetFileName and removed the static helper function.
3426         * platform/posix/FileSystemPOSIX.cpp: (WebCore::pathGetFileName): Moved general case from HTMLFormElement version here.
3427           If other platforms relied on that default they should implement this function for their platform specific version of FileSystem.cpp
3428         * platform/win/FileSystemWin.cpp: (WebCore::pathGetFileName): Moved win implementation from HTMLFormElement here.
3429         * platform/wx/FileSystemWx.cpp: (WebCore::pathGetFileName): Moved wx implementation from HTMLFormElement here.
3430
3431 2008-04-24  Anders Carlsson  <andersca@apple.com>
3432
3433         Windows build fix.
3434         
3435         * html/HTMLFormElement.cpp:
3436         (WebCore::pathGetFilename):
3437
3438 2008-04-24  Anders Carlsson  <andersca@apple.com>
3439
3440         Don't crash when the string is empty.
3441         
3442         * html/HTMLMediaElement.cpp:
3443         (WebCore::parseTimeOffset):
3444
3445 2008-04-24  Dan Bernstein  <mitz@apple.com>
3446
3447         Reviewed by Darin Adler.
3448
3449         - preparation for https://bugs.webkit.org/show_bug.cgi?id=3729
3450           <rdar://problem/4036353> REGRESSION: arrow keys move insertion bar backwards in RTL text
3451
3452         The three main changes in this patch are:
3453
3454         1) Making all inline boxes know their bidi level, instead of just text
3455            boxes knowing whether their bidi level is odd or even. This is
3456            required for the next change.
3457
3458         2) Replacing RenderObject::inlineBox() with
3459            Position::getInlineBoxAndOffset() in recognition of the fact that the
3460            inline box containing the primary caret for a position in a given
3461            node may belong to a different node's renderer.
3462
3463         3) Changing RenderObject::caretRect() to take an InlineBox parameter,
3464            and changing callers to call VisiblePosition::caretRect(), which
3465            locates the inline box, then calls caretRect() on the renderer for
3466            that box. This, combined with the previous change, ensures that the
3467            primary caret is rendered at the right place for positions that
3468            lie on a directionality boundary.
3469
3470         Test: platform/mac/editing/input/caret-primary-bidi.html
3471
3472         * WebCore.base.exp: Added the VisiblePosition(Node*, int, EAffinity)
3473         constructor and VisiblePosition::caretRect(), and sorted.
3474
3475         * dom/Position.cpp:
3476         (WebCore::nextRenderedEditable): Adjusted for the removal of
3477         RenderObject::inlineBox().
3478         (WebCore::previousRenderedEditable): Ditto.
3479         (WebCore::Position::rendersInDifferentPosition): Ditto.
3480         (WebCore::Position::getInlineBoxAndOffset): Added. Gets the inline box
3481         and the offset within that box at which the primary caret for this
3482         position should render.
3483
3484         * dom/Position.h:
3485
3486         * editing/DeleteSelectionCommand.cpp:
3487         (WebCore::DeleteSelectionCommand::mergeParagraphs): Changed to call
3488         VisiblePosition::caretRect() instead of calling the RenderObject method.
3489
3490         * editing/SelectionController.cpp:
3491         (WebCore::caretY): Ditto.
3492         (WebCore::SelectionController::xPosForVerticalArrowNavigation): Ditto.
3493         (WebCore::SelectionController::layout): Ditto.
3494
3495         * editing/VisiblePosition.cpp:
3496         (WebCore::VisiblePosition::caretRect): Changed to call
3497         getInlineBoxAndOffset() to get the correct inline box and call the
3498         renderer for that box.
3499
3500         * editing/VisiblePosition.h:
3501         (WebCore::VisiblePosition::getInlineBoxAndOffset): Added convenience
3502         methods for getting the inline box and caret offset for a visible
3503         position, accounting for its affinity.
3504
3505         * editing/visible_units.cpp:
3506         (WebCore::rootBoxForLine): Changed to use getInlineBoxAndOffset()
3507         instead of RenderObject::inlineBox().
3508         (WebCore::startPositionForLine):
3509         (WebCore::endPositionForLine):
3510         (WebCore::previousLinePosition): Ditto.
3511         (WebCore::nextLinePosition): Ditto.
3512
3513         * page/AccessibilityObject.cpp:
3514         (WebCore::updateAXLineStartForVisiblePosition): Ditto.
3515
3516         * page/Frame.cpp:
3517         (WebCore::Frame::firstRectForRange): Ditto.
3518
3519         * rendering/InlineBox.cpp:
3520         (WebCore::InlineBox::caretMinOffset): Changed to forward to the
3521         renderer.
3522         (WebCore::InlineBox::caretMaxOffset): Ditto.
3523         * rendering/InlineBox.h: Replaced the m_reversed bit, intended for use
3524         in InlineTextBox only, with six bits of the bidi level of the box,
3525         intended for use in all leaf inline boxes.
3526         (WebCore::InlineBox::InlineBox): Added missing initializer for
3527         m_dirOverride and initialized the bidi level.
3528         (WebCore::InlineBox::bidiLevel): Added this accessor.
3529         (WebCore::InlineBox::setBidiLevel): Ditto.
3530         (WebCore::InlineBox::direction): Ditto.
3531         (WebCore::InlineBox::caretLeftmostOffset): Added this convenience
3532         method.
3533         (WebCore::InlineBox::caretRightmostOffset): Ditto.
3534
3535         * rendering/InlineTextBox.cpp: Replaced all references to m_reversed
3536         with checking of direction().
3537         (WebCore::InlineTextBox::selectionRect):
3538         (WebCore::InlineTextBox::placeEllipsisBox):
3539         (WebCore::InlineTextBox::paint):
3540         (WebCore::InlineTextBox::paintSelection):
3541         (WebCore::InlineTextBox::paintCompositionBackground):
3542         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
3543         (WebCore::InlineTextBox::paintTextMatchMarker):
3544         (WebCore::InlineTextBox::textPos):
3545         (WebCore::InlineTextBox::offsetForPosition):
3546         (WebCore::InlineTextBox::positionForOffset):
3547
3548         * rendering/RenderBR.cpp: Removed inlineBox().
3549         * rendering/RenderBR.h: Ditto.
3550
3551         * rendering/RenderBox.cpp:
3552         (WebCore::RenderBox::caretRect): Changed to take an inline box and
3553         account for the direction of the box (or the renderer) in positioning
3554         the caret: in right-to-left boxes, the "before" position is to the right
3555         while "after" is to the left.
3556         * rendering/RenderBox.h:
3557
3558         * rendering/RenderFlow.cpp:
3559         (WebCore::RenderFlow::caretRect): Updated the signature.
3560         * rendering/RenderFlow.h:
3561
3562         * rendering/RenderObject.cpp:
3563         (WebCore::RenderObject::caretRect): Updated the signature.
3564         (WebCore::RenderObject::caretMaxOffset): Changed to return the child
3565         node count (or 1 if there are no children) for replaced elements, such
3566         as <select>s.
3567         * rendering/RenderObject.h:
3568
3569         * rendering/RenderReplaced.cpp: Removed caretMinOffset() and
3570         caretMaxOffset() because the base class implementation does the right
3571         thing for replaced objects now.
3572         * rendering/RenderReplaced.h:
3573
3574         * rendering/RenderSVGInlineText.cpp:
3575         (WebCore::RenderSVGInlineText::caretRect): Updated the signature.
3576         (WebCore::RenderSVGInlineText::positionForCoordinates): Updated for
3577         the change from m_reversed to direction().
3578         * rendering/RenderSVGInlineText.h:
3579
3580         * rendering/RenderText.cpp:
3581         (WebCore::RenderText::caretRect): Changed to take an inline box and
3582         removed the code that used to find the inline for the given position.
3583         Changed use of m_reversed to use direction().
3584         (WebCore::RenderText::position): Changed use of m_reversed to use
3585         direction().
3586         * rendering/RenderText.h:
3587
3588         * rendering/RenderTextControl.cpp:
3589         (WebCore::RenderTextControl::textWithHardLineBreaks): Adjusted for the
3590         removal of RenderObject::inlineBox().
3591
3592         * rendering/RenderTreeAsText.cpp:
3593         (WebCore::writeTextRun): Changed to use direction() instead of
3594         m_reversed.
3595
3596         * rendering/SVGInlineTextBox.cpp: Ditto.
3597         (WebCore::SVGInlineTextBox::calculateGlyphBoundaries):
3598         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::chunkPortionCallback):
3599         (WebCore::SVGInlineTextBox::svgCharacterHitsPosition):
3600
3601         * rendering/SVGRenderTreeAsText.cpp: Ditto.
3602         (WebCore::writeSVGInlineTextBox):
3603
3604         * rendering/SVGRootInlineBox.cpp: Ditto.
3605         (WebCore::svgTextRunForInlineTextBox):
3606         (WebCore::cummulatedWidthOrHeightOfTextChunk):
3607         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
3608
3609         * rendering/bidi.cpp:
3610         (WebCore::RenderBlock::constructLine): Made this function set the
3611         bidi level on all leaf boxes.
3612
3613         * svg/SVGTextContentElement.cpp: Changed to use direction() instead of
3614         m_reversed.
3615         (WebCore::cumulativeCharacterRangeLength):
3616         (WebCore::SVGInlineTextBoxQueryWalker::chunkPortionCallback):
3617
3618 2008-04-24  Sam Weinig  <sam@webkit.org>
3619
3620         Fix the world.
3621
3622         * bindings/js/kjs_proxy.cpp:
3623         (WebCore::KJSProxy::clear):
3624
3625 2008-04-24  Darin Adler  <darin@apple.com>
3626
3627         Reviewed by Geoff.
3628
3629         - fix crash in regression test where we'd ask a frame for a user agent string
3630           after the WebView was already closed
3631
3632         * loader/FrameLoader.cpp:
3633         (WebCore::FrameLoader::scheduleHTTPRedirection): Quietly do nothing if this is
3634         called on a frame that's already detached from its page.
3635         (WebCore::FrameLoader::scheduleLocationChange): Ditto.
3636         (WebCore::FrameLoader::scheduleRefresh): Ditto.
3637         (WebCore::FrameLoader::scheduleHistoryNavigation): Ditto.
3638         (WebCore::FrameLoader::redirectionTimerFired): Assert that this is never called
3639         for a frame that's already detached from its page.
3640         (WebCore::FrameLoader::scheduleRedirection): Ditto.
3641         (WebCore::FrameLoader::startRedirectionTimer): Ditto.
3642
3643 2008-04-23  Timothy Hatcher  <timothy@apple.com>
3644
3645         Add a new callFunction helper function to remove duplicate code
3646         for calling JavaScript functions with arguments.
3647
3648         Reviewed by Darin Adler.
3649
3650         * page/InspectorController.cpp:
3651         (WebCore::InspectorController::callSimpleFunction): Call callFunction.
3652         (WebCore::InspectorController::callFunction): Extended version of the original
3653         callSimpleFunction, with script function arguments and an exception argument.
3654         (WebCore::InspectorController::focusNode): Use callFunction.
3655         (WebCore::InspectorController::addScriptResource): Ditto.
3656         (WebCore::InspectorController::removeScriptResource): Ditto.
3657         (WebCore::InspectorController::addDatabaseScriptResource): Ditto.
3658         (WebCore::InspectorController::removeDatabaseScriptResource): Ditto.
3659         (WebCore::InspectorController::addScriptConsoleMessage): Ditto.
3660         * page/InspectorController.h: Add callFunction.
3661
3662 2008-04-24  Anders Carlsson  <andersca@apple.com>
3663
3664         Reviewed by Sam.
3665
3666         Change some String arguments to be const references instead.
3667         
3668         * css/CSSRule.cpp:
3669         (WebCore::CSSRule::setCssText):
3670         * css/CSSRule.h:
3671         * html/HTMLFormElement.cpp:
3672         (WebCore::pathGetFilename):
3673         * html/HTMLMediaElement.cpp:
3674         (WebCore::parseTimeOffset):
3675         * page/EditorClient.h:
3676         * platform/SecurityOrigin.cpp:
3677         (WebCore::isDefaultPortForProtocol):
3678         * platform/graphics/MediaPlayer.cpp:
3679         (WebCore::MediaPlayer::load):
3680         * platform/graphics/MediaPlayer.h:
3681         * rendering/MediaControlElements.cpp:
3682         (WebCore::MediaControlInputElement::MediaControlInputElement):
3683         * rendering/MediaControlElements.h:
3684         * svg/animation/SVGSMILElement.cpp:
3685         (WebCore::SVGSMILElement::Condition::Condition):
3686         * svg/animation/SVGSMILElement.h:
3687         * svg/graphics/SVGImageEmptyClients.h:
3688         (WebCore::SVGEmptyEditorClient::shouldInsertText):
3689         * xml/XSLTProcessor.cpp:
3690         (WebCore::createFragmentFromSource):
3691
3692 2008-04-24  Justin Garcia  <justin.garcia@apple.com>
3693
3694         Reviewed by Darin Adler.
3695
3696         <rdar://problem/5604313> FormatBlock to apply an h1 also inserts a style span around the first letter (16004)
3697         
3698         * editing/TextIterator.cpp:
3699         (WebCore::TextIterator::advance): We emit an extra newline when leaving a
3700         block element that has atypical margin/padding. When we emit the extra newline, 
3701         it needs to be positioned after that block's contents, not after the block. 
3702         This is how we position the first newline, too, since the range for emitted newlines 
3703         should start where the line break begins visually.
3704
3705 2008-04-24  Anders Carlsson  <andersca@apple.com>
3706
3707         Reviewed by Adam.
3708
3709         Only avoid implicit entries when doing the initial caching.
3710         
3711         * loader/appcache/ApplicationCacheGroup.cpp:
3712         (WebCore::ApplicationCacheGroup::didReceiveResponse):
3713         (WebCore::ApplicationCacheGroup::startLoadingEntry):
3714
3715 2008-04-24  Kevin McCullough  <kmccullough@apple.com>
3716
3717         Reviewed by Adam and Sam.
3718
3719         -<rdar://problem/5770054> JavaScript profiler (10928)
3720         -Only profile the page group that starts profiling to avoid profiling
3721         tools that shouldn't be profiled unless explicitly requested to.
3722
3723         * bindings/js/kjs_proxy.cpp: When a new global object is created set its
3724         page group identifier.
3725         (WebCore::KJSProxy::clear):
3726         (WebCore::KJSProxy::initScript):
3727         * page/Console.cpp: When calling console.profile set the identifier of
3728         the page group being profiled.
3729         (WebCore::Console::profile):
3730         * page/PageGroup.cpp: Implement unique identifiers.
3731         (WebCore::getUniqueIdentifier):
3732         (WebCore::PageGroup::PageGroup):
3733         * page/PageGroup.h: Ditto.
3734         (WebCore::PageGroup::identifier):
3735
3736 2008-04-24  John Sullivan  <sullivan@apple.com>
3737
3738         Mac buid fix
3739
3740         * page/mac/WebCoreViewFactory.h:
3741         add declarations of six new AX methods that were added to LocalizedStrings.h
3742         
3743         * platform/mac/LocalizedStringsMac.mm:
3744         (WebCore::AXButtonActionVerb):
3745         implement by calling through to WebCoreViewFactory as we do with the other functions here
3746         (WebCore::AXRadioButtonActionVerb):
3747         ditto
3748         (WebCore::AXTextFieldActionVerb):
3749         ditto
3750         (WebCore::AXCheckedCheckBoxActionVerb):
3751         ditto
3752         (WebCore::AXUncheckedCheckBoxActionVerb):
3753         ditto
3754         (WebCore::AXLinkActionVerb):
3755         ditto
3756
3757 2008-04-24  Simon Hausmann  <hausmann@webkit.org>
3758
3759         Rubber-stamped by Lars
3760
3761         Fix text rendering in -reverse mode on Qt/Mac.
3762
3763         For Font::width() don't use a plain QFontMetrics object but also the properly
3764         setup QTextLayout that has the RTL/LTR force flags set.
3765
3766         * platform/graphics/qt/FontQt.cpp:
3767         (WebCore::Font::width):
3768
3769 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
3770
3771         Reviewed by Simon.
3772
3773         Don't do anti-aliasing for arcs, lines and rects, but continue to anti-alias
3774         all drawing primitives in the HTML Canvas element.
3775
3776         This speeds up drawing of dashed outlines significantly.
3777
3778         Also preserve the anti-aliasing renderhint for transparency layers and
3779         get rid of the mostly unused device pointer.
3780
3781         * platform/graphics/qt/GraphicsContextQt.cpp:
3782         (WebCore::TransparencyLayer::TransparencyLayer):
3783         (WebCore::GraphicsContextPlatformPrivate::p):
3784         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
3785         (WebCore::GraphicsContext::beginTransparencyLayer):
3786         (WebCore::GraphicsContext::drawRect):
3787         (WebCore::GraphicsContext::drawLine):
3788         (WebCore::GraphicsContext::strokeArc):
3789
3790 2008-04-24  Paul Olav Tvete <paul@trolltech.com>
3791
3792         Reviewed by Simon.
3793
3794         Fix various compiler warnings related to QString(const char *)
3795         construction by using QLatin1String.
3796
3797         * bridge/qt/qt_instance.cpp:
3798         (KJS::Bindings::QtField::valueFromInstance):
3799         (KJS::Bindings::QtField::setValueToInstance):
3800         * dom/XMLTokenizer.cpp:
3801         (WebCore::):
3802         * platform/graphics/qt/PathQt.cpp:
3803         (WebCore::Path::debugString):
3804
3805 2008-04-24  Morten Johan Sørvig  <msorvig@trolltech.com>
3806
3807         Reviewed by Simon.
3808
3809         Work around QMacStyle bug in repainting the vertical scrollbar.
3810
3811         We draw the scrollbar using HITheme but somehow the translation and the
3812         clipping we previously set using ClipCGContextToRegion is ignored. Drawing
3813         without the translation fixes the clip.
3814
3815         * platform/qt/PlatformScrollBarQt.cpp:
3816         (WebCore::PlatformScrollbar::paint):
3817
3818 2008-04-24  Holger Hans Peter Freyther  <zecke@selfish.org>
3819
3820         Reviewed by Simon.
3821
3822         * Set an expiration date for local files as we do not know what will happen
3823         to these files (in contrast to a http server with max-age and other headers)
3824         * Remember the time when we started the job and use that for the expiration date
3825         * QNetworkManager does not handle expiration at all, we might want to set the
3826         expiration for all downloads but this will be a performance nightmare.
3827
3828         * platform/network/qt/QNetworkReplyHandler.cpp:
3829         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
3830         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
3831         (WebCore::QNetworkReplyHandler::start):
3832         * platform/network/qt/QNetworkReplyHandler.h:
3833
3834 2008-04-24  Simon Hausmann  <hausmann@webkit.org>
3835
3836         Fix the Gtk and Qt builds.
3837
3838         Added missing localization stubs for accessibility.
3839
3840         * platform/gtk/LocalizedStringsGtk.cpp:
3841         (WebCore::AXButtonActionVerb):
3842         (WebCore::AXRadioButtonActionVerb):
3843         (WebCore::AXTextFieldActionVerb):
3844         (WebCore::AXCheckedCheckBoxActionVerb):
3845         (WebCore::AXUncheckedCheckBoxActionVerb):
3846         (WebCore::AXLinkActionVerb):
3847         * platform/qt/Localizations.cpp:
3848         (WebCore::AXButtonActionVerb):
3849         (WebCore::AXRadioButtonActionVerb):
3850         (WebCore::AXTextFieldActionVerb):
3851         (WebCore::AXCheckedCheckBoxActionVerb):
3852         (WebCore::AXUncheckedCheckBoxActionVerb):
3853         (WebCore::AXLinkActionVerb):
3854
3855 2008-04-24  Olivier Goffart  <ogoffart@trolltech.com>
3856
3857         Reviewed by Simon
3858
3859         Fix various compiler warnings in the Qt port.
3860
3861         * platform/graphics/qt/ImageQt.cpp:
3862         (loadResourcePixmap):
3863         * platform/qt/CookieJarQt.cpp:
3864         (WebCore::cookies):
3865         * platform/qt/ScrollViewQt.cpp:
3866         (WebCore::ScrollView::wheelEvent):
3867         * plugins/qt/PluginDataQt.cpp:
3868         (WebCore::PluginData::initPlugins):
3869
3870 2008-04-24  Andre Poenitz  <andre.poenitz@trolltech.com>
3871
3872         Reviewed by Simon.
3873
3874         Removed spurious QHideEvent forward declaration.
3875
3876         * platform/qt/QWebPopup.h:
3877
3878 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
3879
3880         Reviewed by Simon.
3881
3882         Render text areas using Qt (ensures proper style).
3883
3884         * platform/qt/RenderThemeQt.cpp:
3885         (WebCore::RenderThemeQt::paintTextField):
3886         (WebCore::RenderThemeQt::adjustTextFieldStyle):
3887         (WebCore::RenderThemeQt::paintTextArea):
3888         (WebCore::RenderThemeQt::supportsFocus):
3889         * platform/qt/RenderThemeQt.h:
3890
3891 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
3892
3893         Reviewed by Simon.
3894
3895         Make mouse wheel events over scrollbars behave the same as in Qt, i.e. both
3896         horizontal and vertical wheel events will scroll the view in the orientation
3897         of the scrollbar underneath the cursor.
3898
3899         * platform/qt/ScrollViewQt.cpp:
3900         (WebCore::ScrollView::paint):
3901         (WebCore::ScrollView::wheelEvent):
3902
3903 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
3904
3905         Reviewed by Brady.
3906
3907         * page/AccessibilityObject.cpp:
3908         (WebCore::AccessibilityObject::press): Return false if this object
3909         doesn't have an action element associated with it.
3910         * page/AccessibilityObject.h: Added a performDefaultAction() method,
3911         which just calls press(). Marked press() const and changed its return
3912         type to bool.
3913
3914 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
3915
3916         Reviewed by Adam.
3917
3918         Don't allow a hit test to return an AccessibilityObject that should be
3919         ignored.
3920
3921         * page/AccessibilityObject.cpp:
3922         (WebCore::AccessibilityObject::doAccessibilityHitTest): If this result
3923         object's accessibility is ignored, return the parent unignored object.
3924
3925 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
3926
3927         Reviewed by Adam.
3928
3929         Fix a crash when performing a hit test on an AccessibilityObject with
3930         no layer (e.g., an AccessibilityObject for a RenderText object).
3931
3932         * page/AccessibilityObject.cpp:
3933         (WebCore::AccessibilityObject::doAccessibilityHitTest): Added a null
3934         check for layer. Removed a null check for m_renderer, which shouldn't
3935         occur.
3936
3937 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
3938
3939         * page/AccessibilityObject.cpp:
3940         (WebCore::AccessibilityObject::boundingBoxRect): Added FIXME about this
3941         method not working correctly for objects with CSS transforms applied.
3942
3943 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
3944
3945         Reviewed by Adam.
3946
3947         Implement contentsToScreen() and screenToContents() on Windows.
3948
3949         * platform/ScrollView.h: Make these declarations conditional on
3950         HAVE(ACCESSIBILITY) instead of PLATFORM(MAC).
3951         * platform/win/ScrollViewWin.cpp:
3952         (WebCore::ScrollView::contentsToScreen): Translate from coordinates
3953         relative to the ScrollView to coordinates relative to the screen. Do
3954         this by getting the offset of the ScrollView in screen coordinates and
3955         moving the rect by this amount.
3956         (WebCore::ScrollView::screenToContents): Translate from coordinates
3957         relative to the screen to coordinates relative to the ScrollView.
3958
3959 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
3960
3961         Reviewed by Oliver.
3962
3963         Add a method to get a localized, human-readable string stating this
3964         object's default action, e.g., a button's default action is "press."
3965
3966         * page/AccessibilityObject.cpp:
3967         (WebCore::AccessibilityObject::actionVerb): Added.
3968         * page/AccessibilityObject.h: Added declaration for actionVerb().
3969         * platform/LocalizedStrings.h: Added declarations for:
3970             AXButtonActionVerb()
3971             AXRadioButtonActionVerb()
3972             AXTextFieldActionVerb()
3973             AXCheckedCheckBoxActionVerb()
3974             AXUncheckedCheckBoxActionVerb()
3975             AXLinkActionVerb()
3976
3977 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
3978
3979         Reviewed by Simon.
3980
3981         Cleaned up copyright headers in the Qt port (removed misplaced class
3982         descriptions and fixed inconsistent whitespace and indentation).
3983
3984         * platform/graphics/qt/FontQt.cpp:
3985         * platform/qt/WheelEventQt.cpp:
3986
3987 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
3988
3989         Reviewed by Simon.
3990
3991         Disable vanlilla focus rings since Qt provides this as part of the style.
3992
3993         * platform/qt/RenderThemeQt.cpp:
3994
3995 2008-04-24  George Staikos  <george@staikos.net>
3996
3997         Reviewed by Simon.
3998
3999         This optimization in BitmapImage::drawPattern for the identity
4000         transform is bogus and causes incorrect results on sites like youtube.
4001
4002         * platform/graphics/qt/ImageQt.cpp:
4003         (WebCore::BitmapImage::drawPattern):
4004
4005 2008-04-23  Brady Eidson  <beidson@apple.com>
4006
4007         Reviewed by Jon Honeycutt
4008
4009         Preparing for making LocalStorageAreas persistent.
4010
4011         Since LocalStorageAreas will need to do a lot of additional work for each of the basic
4012         operations a Storage object supports, this patch makes the API entry points virtual so
4013         LocalStorageArea can override them.  The behavior for both Local and Session StorageAreas
4014         is unchanged with this patch, but LocalStorageArea will override them in the future.
4015
4016         * storage/StorageArea.cpp: Rename the implementations to internalFoo
4017         (WebCore::StorageArea::internalLength):
4018         (WebCore::StorageArea::internalKey):
4019         (WebCore::StorageArea::internalGetItem):
4020         (WebCore::StorageArea::internalSetItem):
4021         (WebCore::StorageArea::internalRemoveItem):
4022         (WebCore::StorageArea::internalContains):
4023
4024         * storage/StorageArea.h: Call internalFoo variants
4025         (WebCore::StorageArea::length):
4026         (WebCore::StorageArea::key):
4027         (WebCore::StorageArea::getItem):
4028         (WebCore::StorageArea::setItem):
4029         (WebCore::StorageArea::removeItem):
4030         (WebCore::StorageArea::contains):
4031
4032 2008-04-23  David Hyatt  <hyatt@apple.com>
4033
4034         Implement getComputedStyle for border-image.
4035
4036         Reviewed by Dan Bernstein
4037
4038         Added fast/css/getComputedStyle-border-image.html
4039
4040         * css/CSSComputedStyleDeclaration.cpp:
4041         (WebCore::):
4042         (WebCore::valueForRepeatRule):
4043         (WebCore::valueForNinePieceImage):
4044         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
4045
4046 2008-04-22  Darin Adler  <darin@apple.com>
4047
4048         Reviewed by Anders.
4049
4050         - simplify use of HashTraits to prepare for some upcoming hash table changes
4051
4052         * page/AXObjectCache.h: Removed uneeded AXIDHashTraits, which are no different
4053         from the default hash traits for unsigned.
4054         * page/mac/AXObjectCacheMac.mm:
4055         (WebCore::AXObjectCache::removeAXID): Remove assertion that's already done
4056         by HashTable that the value is not the deleted value.
4057
4058         * platform/graphics/StringTruncator.cpp: Removed unneeded include.
4059         * svg/SVGFontFaceElement.cpp: Removed unneeded include.
4060
4061 2008-04-23  Kevin Ollivier  <kevino@theolliviers.com>
4062
4063         wx build fixes. Changing BackgroundLayer -> FillLayer and adding
4064         Frame::disconnectPlatformScriptObjects().
4065
4066         * platform/wx/RenderThemeWx.cpp:
4067         (WebCore::RenderThemeWx::isControlStyled):
4068         * platform/wx/TemporaryLinkStubs.cpp:
4069         (Frame::disconnectPlatformScriptObjects):
4070
4071 2008-04-23  David Hyatt  <hyatt@apple.com>
4072
4073         Add support for mask-box-image (similar to border-image).  This property enables a single image
4074         to overlay the entire mask area (with nine-piece slicing rules similar to border image).
4075
4076         Reviewed by Dan Bernstein
4077
4078         Added inline-mask-overlay.html, block-mask-overlay.html
4079
4080         * css/CSSComputedStyleDeclaration.cpp:
4081         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
4082         * css/CSSParser.cpp:
4083         (WebCore::CSSParser::parseValue):
4084         (WebCore::CSSParser::parseBorderImage):
4085         * css/CSSPropertyNames.in:
4086         * css/CSSStyleSelector.cpp:
4087         (WebCore::CSSStyleSelector::applyProperty):
4088         * rendering/InlineFlowBox.cpp:
4089         (WebCore::InlineFlowBox::paintMask):
4090         * rendering/RenderBox.cpp:
4091         (WebCore::RenderBox::paintMask):
4092         * rendering/RenderFlow.cpp:
4093         (WebCore::RenderFlow::paintLines):
4094         * rendering/RenderObject.cpp:
4095         (WebCore::RenderObject::paintNinePieceImage):
4096         (WebCore::RenderObject::paintBorder):
4097         * rendering/RenderObject.h:
4098         * rendering/RenderStyle.cpp:
4099         (WebCore::NinePieceImage::operator==):
4100         * rendering/RenderStyle.h:
4101         (WebCore::):
4102         (WebCore::NinePieceImage::m_verticalRule):
4103         (WebCore::NinePieceImage::horizontalRule):
4104         (WebCore::NinePieceImage::verticalRule):
4105         (WebCore::RenderStyle::borderImage):
4106         (WebCore::RenderStyle::maskOverlayImage):
4107         (WebCore::RenderStyle::hasMask):
4108         (WebCore::RenderStyle::resetBorderImage):
4109         (WebCore::RenderStyle::setBorderImage):
4110         (WebCore::RenderStyle::setMaskOverlayImage):
4111         (WebCore::RenderStyle::initialNinePieceImage):
4112         * rendering/RenderTable.cpp:
4113         (WebCore::RenderTable::paintMask):
4114         * rendering/RenderTableCell.cpp:
4115         (WebCore::RenderTableCell::paintMask):
4116
4117 2008-04-23  Justin Garcia  <justin.garcia@apple.com>
4118
4119         Reviewed by Darin Adler.
4120
4121         <rdar://problem/5825350> OWA: Caret disappears when navigating with arrows keys in contenteditable div
4122
4123         * editing/htmlediting.cpp:
4124         (WebCore::firstEditablePositionAfterPositionInRoot): Return a null VisiblePosition if
4125         this function moves out of highestRoot.  Re-wrote so as to not duplicate code inside
4126         and outside of the while loop.
4127         (WebCore::lastEditablePositionBeforePositionInRoot): Ditto.
4128
4129 2008-04-23  Daniel Zucker  <zucker@wake3.com>
4130
4131         Reviewed by Adam Roben.
4132
4133         Fix build errors needed to compile Curl in Cairo build.  Add stubs for
4134         didReceiveAuthenticationChallenge, receivedCredential,
4135         receivedRequestToContinueWithoutCredential, and receivedCancellation.
4136         <https://bugs.webkit.org/show_bug.cgi?id=18468>
4137
4138         * platform/network/ResourceHandle.h:  
4139         * platform/network/curl/ResourceHandleCurl.cpp:
4140         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge):
4141         (WebCore::ResourceHandle::receivedCredential):
4142         (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential):
4143         (WebCore::ResourceHandle::receivedCancellation):
4144
4145 2008-04-23  Dan Bernstein  <mitz@apple.com>
4146
4147         Reviewed by Darin Adler.
4148
4149         - fix a bug where moving forward in bidirectional text skips over the
4150           position after the end of the line
4151
4152         Test: editing/selection/move-past-trailing-space.html
4153
4154         * dom/Position.cpp:
4155         (WebCore::Position::upstream): Changed the logic for identifying when a
4156         position is after the last character of a text box of a text node that
4157         continues on the next line, to make it work correctly when boxes are not
4158         laid out in logical order.
4159         (WebCore::Position::downstream): Ditto.
4160
4161 2008-04-23  Brad Hughes  <bhughes@trolltech.com>
4162
4163         Reviewed by Simon.
4164
4165         Fix release build with the intel compiler
4166
4167         Intel compiler can't compile qtwebkit with -O2 or -O1, so we're left with -O0
4168
4169         * WebCore.pro:
4170
4171 2008-04-22  Dan Bernstein  <mitz@apple.com>
4172
4173         Reviewed by Anders Carlsson.
4174
4175         - remove unused calls to Position::upstream()
4176
4177         * editing/InsertLineBreakCommand.cpp:
4178         (WebCore::InsertLineBreakCommand::insertNodeAfterPosition):
4179         (WebCore::InsertLineBreakCommand::insertNodeBeforePosition):
4180
4181 2008-04-22  Jon Honeycutt  <jhoneycutt@apple.com>
4182
4183         Reviewed by Sam.
4184
4185         Add a method to query which modifier keys the platform uses for access
4186         key actions.
4187
4188         * page/EventHandler.cpp:
4189         (WebCore::EventHandler::handleAccessKey): Bitwise and the event's
4190         modifier keys with the platform's access key modifier mask to determine
4191         whether this event can perform an access key action.
4192         * page/EventHandler.h: Added s_accessKeyModifiers, a platform-defined
4193         mask of modifier keys used for access key actions, and a getter.
4194         * page/mac/EventHandlerMac.mm: Use PlatformKeyboardEvent::CtrlKey for
4195         access key actions.
4196         * page/qt/EventHandlerQt.cpp: Same.
4197         * page/gtk/EventHandlerGtk.cpp: Use AltKey.
4198         * page/win/EventHandlerWin.cpp: Same.
4199         * page/wx/EventHandlerWx.cpp: Same.
4200         * platform/PlatformKeyboardEvent.h: Added an enum, ModifierKey.
4201         (WebCore::PlatformKeyboardEvent::):
4202         (WebCore::PlatformKeyboardEvent::modifiers): Return which modifier keys
4203         were active, a combination of ModifierKey values.
4204
4205 2008-04-22  Sam Weinig  <sam@webkit.org>
4206
4207         Reviewed by Maciej Stachowiak.
4208
4209         Make the KJSProxy and FrameLoader member variables instead of pointers
4210         in FramePrivate in a bid to do a little clean up before the last of the
4211         split window patches.  Also, make the KJSProxy not lazily created, as the
4212         real benefit comes from lazily creating the JSDOMWindowWrapper, which we
4213         still do.
4214
4215         * page/Frame.cpp:
4216         (WebCore::Frame::~Frame):
4217         (WebCore::Frame::init):
4218         (WebCore::Frame::loader):
4219         (WebCore::Frame::scriptProxy):
4220         (WebCore::Frame::document):
4221         (WebCore::Frame::setDocument):
4222         (WebCore::Frame::clearScriptProxy):
4223         (WebCore::Frame::pageDestroyed):
4224         (WebCore::FramePrivate::FramePrivate):
4225         (WebCore::FramePrivate::~FramePrivate):
4226         * page/FramePrivate.h:
4227
4228 2008-04-22  Anatoli Papirovski  <apapirovski@mac.com>
4229
4230         Reviewed by Dan Bernstein.
4231
4232         - fix https://bugs.webkit.org/show_bug.cgi?id=18584
4233         border-color, outline-color, column-color, -webkit-text-stroke-color,
4234         and -webkit-text-fill-color inheritance to correctly use parent's color
4235         if the parent's corresponding (border, outline, etc.)-color property
4236         wasn't set.
4237
4238         Test: fast/borders/border-color-inherit.html
4239
4240         * css/CSSStyleSelector.cpp:
4241         (WebCore::CSSStyleSelector::applyProperty):
4242
4243 2008-04-22  Alp Toker  <alp@nuanti.com>
4244
4245         Rubber-stamped by Dave Hyatt.
4246
4247         Move GraphicsContext::clipToImageBuffer() notImplemented() stub to
4248         GraphicsContextCairo.
4249
4250         * platform/graphics/GraphicsContext.cpp:
4251         * platform/graphics/cairo/GraphicsContextCairo.cpp:
4252         (WebCore::GraphicsContext::clipToImageBuffer):
4253
4254 2008-04-22  David Hyatt  <hyatt@apple.com>
4255
4256         Add support for mask-composite to match background-composite.
4257
4258         Reviewed by Sam Weinig
4259
4260         Added fast/backgrounds/mask-composite.html
4261
4262         * css/CSSComputedStyleDeclaration.cpp:
4263         (WebCore::):
4264         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
4265         * css/CSSParser.cpp:
4266         (WebCore::CSSParser::parseValue):
4267         (WebCore::CSSParser::parseFillProperty):
4268         * css/CSSPropertyNames.in:
4269