Breaks out ObjectPropertiesSection from PropertiesSidebarPane
[WebKit-https.git] / WebCore / ChangeLog
1 2008-05-13  Timothy Hatcher  <timothy@apple.com>
2
3         Breaks out ObjectPropertiesSection from PropertiesSidebarPane
4         so it can be used by the Scripts panel's Scope Chain pane.
5
6         Rubber-stamped by Adam Roben.
7
8         * page/inspector/ObjectPropertiesSection.js: Added.
9         * page/inspector/PropertiesSidebarPane.js: Moved ObjectPropertiesSection
10         to ObjectPropertiesSection.js.
11         * WebCore.vcproj/WebCore.vcproj: Add the new file.
12         * page/inspector/WebKit.qrc: Ditto.
13         * page/inspector/inspector.html: Ditto.
14
15 2008-05-13  Timothy Hatcher  <timothy@apple.com>
16
17         Add a helper function to the Inspector's Array prototype
18         that will remove any identical values/objects from the array.
19
20         Reviewed by Kevin McCullough.
21
22         * page/inspector/utilities.js:
23         (Array.prototype.remove): Iterate over the array and strict
24         compare to the passed in value. If they match, splice that index
25         out of the array. If onlyFirst is true, return after the first splice.
26
27 2008-05-13  Timothy Hatcher  <timothy@apple.com>
28
29         Adds a JavaScriptCallFrame object and JavaScript binding with an IDL.
30         This object will expose the stack to the Inspector's debugger.
31
32         Reviewed by Adam Roben.
33
34         * DerivedSources.make: Add JavaScriptCallFrame.
35         * bindings/js/JSJavaScriptCallFrameCustom.cpp: Added.
36         (WebCore::JSJavaScriptCallFrame::evaluate): Calls impl evaluate and returns the result.
37         (WebCore::JSJavaScriptCallFrame::scopeChain): Makes an array of the ScopeChain.
38         * page/JavaScriptCallFrame.cpp: Added.
39         (WebCore::JavaScriptCallFrame::JavaScriptCallFrame):
40         (WebCore::JavaScriptCallFrame::caller): Returns m_caller.
41         (WebCore::JavaScriptCallFrame::functionName): Returns the function
42         name from the ExecState if this is not global code or anonymous.
43         (WebCore::JavaScriptCallFrame::evaluate): Evaluates a script string
44         in the scope of the call frame.
45         * page/JavaScriptCallFrame.h: Added.
46         (WebCore::JavaScriptCallFrame::create): Call the ctor can return in a PassRefPtr.
47         (WebCore::JavaScriptCallFrame::invalidate): Sets m_mexec to 0. This prevents a
48         stale ExecState from being accessed after the lifetime of the ExecState.
49         (WebCore::JavaScriptCallFrame::isValid): Checks if m_exec is 0.
50         (WebCore::JavaScriptCallFrame::execState): Returns m_exec.
51         (WebCore::JavaScriptCallFrame::sourceIdentifier): Returns m_sourceID.
52         (WebCore::JavaScriptCallFrame::line): Returns m_line.
53         (WebCore::JavaScriptCallFrame::setLine): Sets m_line.
54         (WebCore::JavaScriptCallFrame::scopeChain): Returns by reference m_exec->scopeChain().
55         * page/JavaScriptCallFrame.idl: Added.
56         * WebCore.xcodeproj/project.pbxproj: Add new files.
57         * WebCore.vcproj/WebCore.vcproj: Ditto.
58
59 2008-05-13  Timothy Hatcher  <timothy@apple.com>
60
61         Add a new WebInspector.Object base class that will be used for
62         a few objects in the Web Inspector to support listeners on any
63         object. This will help add more abstraction to the Inspector.
64
65         Reviewed by Adam Roben.
66
67         * page/inspector/Object.js: Added.
68         (WebInspector.Object): Does nothing.
69         (WebInspector.Object.prototype.addEventListener): Adds the listener to
70         the _listeners map by type. Supports a this object argument, for easy
71         addition of listeners without the need for bind.
72         (WebInspector.Object.prototype.removeEventListener): Remove the listener
73         from the _listeners map. If the listener is null and the thisObject was
74         passed, remove any listener for that thisObject.
75         (WebInspector.Object.prototype.dispatchEventToListeners): Sends an event
76         for a type to all listeners for that type. Mimics some of the DOMEvent
77         methods and properties for the event object passed to the listeners.
78         * WebCore.vcproj/WebCore.vcproj: Add new files.
79         * page/inspector/WebKit.qrc: Ditto.
80         * page/inspector/inspector.html: Ditto.
81
82 2008-05-13  Timothy Hatcher  <timothy@apple.com>
83
84         Update the view source CSS to better match the new Inspector mock-ups.
85
86         Reviewed by Kevin McCullough.
87
88         * css/view-source.css:
89
90 2008-05-13  John Sullivan  <sullivan@apple.com>
91
92         Reviewed by Dan Bernstein and Kevin Decker
93         
94         - fixed <rdar://problem/5879597> reproducible crash in HTMLSelectElement::typeAheadFind
95
96         Test: fast/forms/select-type-ahead-list-box-no-selection.html
97
98         * html/HTMLSelectElement.cpp:
99         (WebCore::HTMLSelectElement::typeAheadFind):
100         When there's no initially-selected element, we were accessing index -1. Check for this
101         case and start at 0.
102
103 2008-05-13  Sam Weinig  <sam@webkit.org>
104
105         Reviewed by Dan Bernstein.
106
107         Small cleanup to XMLHttpRequest in preparation for Access Control changes.
108
109         * xml/XMLHttpRequest.cpp:
110         (WebCore::XMLHttpRequest::XMLHttpRequest):
111         (WebCore::XMLHttpRequest::~XMLHttpRequest):
112         (WebCore::XMLHttpRequest::open):
113         (WebCore::XMLHttpRequest::send):
114         (WebCore::XMLHttpRequest::internalAbort):
115         (WebCore::XMLHttpRequest::processSyncLoadResults):
116         (WebCore::XMLHttpRequest::didFinishLoading):
117         (WebCore::XMLHttpRequest::didReceiveResponse):
118         (WebCore::XMLHttpRequest::didReceiveData):
119         * xml/XMLHttpRequest.h:
120
121 2008-05-13  chris fleizach  <cfleizach@apple.com>
122
123         Beth Dakin
124
125         <rdar://problem/5701210> VO: If image is missing, VoiceOver does not speak the alternative text.
126
127         * page/AccessibilityRenderObject.cpp:
128         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
129
130 2008-05-13  chris fleizach  <cfleizach@apple.com>
131
132         Beth Dakin
133
134         <rdar://problem/5908446> AX: webkit needs to return blockquote information for all AX objects, not just in AXTextMarker info
135
136         * page/mac/AccessibilityObjectWrapper.mm:
137         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
138         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
139
140 2008-05-13  Alexey Proskuryakov  <ap@webkit.org>
141
142         Reviewed by John Sullivan.
143
144         <rdar://problem/4852077> REGRESSION: The content of the HTML file which is saved as Thai
145         (ISO 8859-11) disappear.
146
147         <rdar://problem/5842597> Thai ISO-8859-11 should be upgraded to Windows-874
148
149         Test: fast/encoding/char-decoding.html
150
151         * platform/text/TextCodecICU.cpp: (WebCore::TextCodecICU::registerExtendedEncodingNames):
152         Register ISO-8859-11, which doesn't have a standard IANA name, despite following
153         the usual 8859 naming scheme. Also, made TIS-620 map to windows-874-2000 explicitly.
154
155 2008-05-13  chris fleizach  <cfleizach@apple.com>
156
157         Reviewed by Beth Dakin
158
159         <rdar://problem/5471973> Some AXLinks are not getting AXTitles though there is title text
160
161         * page/AccessibilityRenderObject.cpp:
162         (WebCore::AccessibilityRenderObject::title):
163
164 2008-05-13  Alexey Proskuryakov  <ap@webkit.org>
165
166         Reviewed by Eric Seidel.
167
168         https://bugs.webkit.org/show_bug.cgi?id=18681
169         <rdar://problem/5888130> WebKit should not remove BOM characters from content.
170
171         We were only trying to match Firefox, and it doesn't do this any more.
172
173         Tests: fast/encoding/bom-in-content.html
174                fast/encoding/bom-in-content-utf16.html
175
176         * platform/text/TextDecoder.cpp: (WebCore::TextDecoder::checkForBOM): Skip the BOM if it's
177         at the start of input stream.
178
179         * platform/text/TextCodec.cpp:
180         * platform/text/TextCodec.h:
181         * platform/text/TextCodecICU.cpp:
182         (WebCore::TextCodecICU::decode):
183         * platform/text/TextCodecUTF16.cpp:
184         (WebCore::TextCodecUTF16::decode):
185         * platform/text/mac/TextCodecMac.cpp:
186         (WebCore::TextCodecMac::decode):
187         Don't remove the BOM.
188
189 2008-05-13  Anders Carlsson  <andersca@apple.com>
190
191         Reviewed by Darin.
192
193         Don't crash when a document loader is destroyed while an initial caching attempt
194         is in progress.
195
196         * loader/appcache/ApplicationCacheGroup.cpp:
197         (WebCore::ApplicationCacheGroup::~ApplicationCacheGroup):
198         Stop loading.
199         
200         (WebCore::ApplicationCacheGroup::stopLoading):
201         New method that stops a cache update.
202         
203         (WebCore::ApplicationCacheGroup::documentLoaderDestroyed):
204         Delete ourselves here.
205         
206         * loader/appcache/ApplicationCacheGroup.h:
207
208 2008-05-13  Alexey Proskuryakov  <ap@webkit.org>
209
210         Reviewed by Darin.
211
212         <rdar://problem/5841351> Turkish ISO 8859-9 encoding should be treated as windows-1254
213
214         Match IE and upgrade ISO-8859-9 to windows-1254, which is its strict superset.
215
216         Test: fast/encoding/char-decoding.html
217
218         * platform/text/TextCodecICU.cpp:
219         (WebCore::TextCodecICU::registerExtendedEncodingNames): Register the standard name
220         unconditionally. Previously, we registered windows-949-2000 as a special case that lacked 
221         an IANA standard name, and got away with not registering GBK because it happened
222         to be reported by ICU normally earlier than any encoding upgraded to it.
223
224 2008-05-13  Tor Arne Vestbø  <tavestbo@trolltech.com>
225
226         Reviewed by Simon
227
228         Fix QtWebKit build on Qt embedded.
229
230         * WebCore.pro:
231         * platform/FileSystem.h:
232         * platform/qt/FileSystemQt.cpp:
233
234 2008-05-13  Ariya Hidayat  <ariya.hidayat@trolltech.com>
235
236         Reviewed by Simon.
237
238         For Gtk/X11 and Qt/X11, use a more extensive plug-ins scan directories set
239
240         * plugins/PluginDatabase.cpp:
241         (WebCore::addMozillaPluginDirectories):
242         (WebCore::PluginDatabase::isPreferredPluginDirectory):
243
244 2008-05-12  Adam Roben  <aroben@apple.com>
245
246         Turn on warnings as errors in WebCore.vcproj
247
248         Rubberstamped by Anders Carlsson.
249
250         * WebCore.vcproj/WebCore.vcproj: Also let VS reformat the file as it
251         saw fit. The important part is the removal of the WarnAsError="false"
252         lines.
253
254 2008-05-09  Sam Weinig  <sam@webkit.org>
255
256         Reviewed by Mark Rowe.
257
258         Fix for https://bugs.webkit.org/show_bug.cgi?id=18958
259         NULL pointer dereference in NamedAttrMap::setNamedItem
260
261         Test: fast/dom/NamedNodeMap-setNamedItem-crash.html
262
263         * dom/NamedAttrMap.cpp:
264         (WebCore::NamedAttrMap::setNamedItem): Null check the argument.
265
266 2008-05-09  Kevin McCullough  <kmccullough@apple.com>
267
268         Build fix.
269
270         * page/Console.cpp:
271         (WebCore::Console::profile):
272
273 2008-05-09  Sam Weinig  <sam@webkit.org>
274
275         Rubber-stamped by Mark Rowe.
276
277         Remove the ENABLE_CROSS_DOCUMENT_MESSAGING #ifdefs.
278
279         * Configurations/WebCore.xcconfig:
280         * WebCore.vcproj/WebCore.vcproj:
281         * WebCore.vcproj/build-generated-files.sh:
282         * bindings/js/JSDOMWindowCustom.cpp:
283         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
284         (WebCore::JSDOMWindow::postMessage):
285         * bindings/js/JSEventCustom.cpp:
286         (WebCore::toJS):
287         * bindings/objc/DOMEvents.mm:
288         (+[DOMEvent _wrapEvent:WebCore::]):
289         * dom/Document.cpp:
290         (WebCore::Document::createEvent):
291         * dom/Event.cpp:
292         (WebCore::Event::isMessageEvent):
293         * dom/Event.h:
294         * dom/MessageEvent.cpp:
295         * dom/MessageEvent.h:
296         * dom/MessageEvent.idl:
297         * page/DOMWindow.cpp:
298         (WebCore::DOMWindow::postMessageTimerFired):
299         * page/DOMWindow.h:
300         * page/DOMWindow.idl:
301
302 2008-05-09  Adam Barth  <abarth-webkit@adambarth.com>
303
304         Reviewed by Sam Weinig.
305
306         https://bugs.webkit.org/show_bug.cgi?id=18771
307
308         Make postMessage generate an event on the window instead of the
309         document.
310
311         Test: http/tests/messaging/cross-domain-message-event-dispatch.html
312
313         * dom/EventTargetNode.cpp:
314         (WebCore::EventTargetNode::dispatchWindowEvent):
315         * dom/EventTargetNode.h:
316         * page/DOMWindow.cpp:
317         (WebCore::DOMWindow::postMessageTimerFired):
318
319 2008-05-09  Tor Arne Vestbø  <tavestbo@trolltech.com>
320
321         Reviewed by Simon.
322
323         Replaced all instances of qDebug() with LOG(Media, ...)
324         in MediaPlayerPrivatePhonon.
325
326         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
327         (WebCore::MediaPlayerPrivate::updateStates):
328
329 2008-05-09  Tor Arne Vestbø  <tavestbo@trolltech.com>
330
331         Reviewed by Simon
332
333         Fix the Qt/Mac build.
334
335         * platform/qt/FileSystemQt.cpp:
336
337 2008-05-08  Sam Weinig  <sam@webkit.org>
338
339         Reviewed by Anders Carlsson.
340
341         Rename the XMLHttpRequestState enum values to match the spec.
342
343         * xml/XMLHttpRequest.cpp:
344         (WebCore::XMLHttpRequest::responseXML):
345         (WebCore::XMLHttpRequest::XMLHttpRequest):
346         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
347         (WebCore::XMLHttpRequest::open):
348         (WebCore::XMLHttpRequest::send):
349         (WebCore::XMLHttpRequest::abort):
350         (WebCore::XMLHttpRequest::setRequestHeader):
351         (WebCore::XMLHttpRequest::getAllResponseHeaders):
352         (WebCore::XMLHttpRequest::getResponseHeader):
353         (WebCore::XMLHttpRequest::status):
354         (WebCore::XMLHttpRequest::statusText):
355         (WebCore::XMLHttpRequest::processSyncLoadResults):
356         (WebCore::XMLHttpRequest::didFinishLoading):
357         (WebCore::XMLHttpRequest::didReceiveData):
358         * xml/XMLHttpRequest.h:
359         (WebCore::):
360
361 2008-05-08  Dan Bernstein  <mitz@apple.com>
362
363         Reviewed by Mark Rowe.
364
365         - fix https://bugs.webkit.org/show_bug.cgi?id=18818
366           <rdar://problem/5901544> REGRESSION (3.1.1-TOT): Character order (float:left ordered after the first letter)
367
368         Test: fast/css/first-letter-float-after-float.html
369
370         * rendering/RenderBlock.cpp:
371         (WebCore::RenderBlock::updateFirstLetter): Changed to add the first
372         letter container right before the rest of the text it is taken from,
373         instead of at the beginning of the block.
374
375 2008-05-08  Chris Fleizach  <cfleizach@apple.com>
376
377         Reviewed by Darin Adler.
378
379         <rdar://problem/5921046> AX: list box options have wrong AXPosition
380
381         * page/AccessibilityObject.cpp:
382         (WebCore::AccessibilityObject::documentFrameView):
383         * page/AccessibilityObject.h:
384
385 2008-05-08  Julien Chaffraix  <jchaffraix@webkit.org>
386
387         Reviewed by Eric.
388
389         Bug 18916: make_names.pl --factory needs to support custom c++ guard
390
391         Add --guardFactoryWith to handle the cpp guard around generated factories.
392
393         * DerivedSources.make: Set the guardFactoryWith variable for SVG factory.
394         * GNUmakefile.am: Ditto.
395         * WebCore.pro: Ditto.
396         * dom/make_names.pl: Add guardFactoryWith option.
397
398 2008-05-08  Julien Chaffraix  <jchaffraix@webkit.org>
399
400         Reviewed by Adam Roben.
401
402         wx & Gtk build fix.
403
404         Should also fix the cURL backend for the Windows port.
405
406         * WebCore.vcproj/WebCore.vcproj: Add FormDataStreamCurl information.
407         * platform/network/curl/FormDataStreamCurl.h: Include stdio.h which
408         fixes the build on some machine.
409
410         * webcore-wx.bkl: Add FormDataStreamCurl.cpp.
411
412 2008-05-08  Timothy Hatcher  <timothy@apple.com>
413
414         Fixes the bug where the Web Inspector could not
415         find any localization strings.
416
417         Reviewed by Mark Rowe.
418
419         * WebCore.xcodeproj/project.pbxproj: Add the localizedStrings.js
420         file to the WebCore Copy Resources phase. Also removes an idl from
421         the Copy Resources phase.
422
423 2008-05-08  Dan Bernstein  <mitz@apple.com>
424
425         Reviewed by Adam Roben.
426
427         - fix <rdar://problem/5697957> "No recent searches" label in a narrow search field's history popup is truncated
428
429         * platform/win/PopupMenuWin.cpp:
430         (WebCore::PopupMenu::calculatePositionAndSize): Changed to use a bold
431         font for measuring labels.
432
433 2008-05-08  Dan Bernstein  <mitz@apple.com>
434
435         Reviewed by Geoffrey Garen.
436
437         - cross-platform fix for http://bugs.webkit.org/show_bug.cgi?id=17590 
438           ASSERTION FAILED: subject in jsRegExpExecute()
439
440         * page/Frame.cpp:
441         (WebCore::Frame::matchLabelsAgainstElement):
442
443 2008-05-08  Holger Hans Peter Freyther  <zecke@selfish.org>
444
445         Reviewed by Simon.
446
447         Simple ImageBuffer::image implementation.
448
449         In contrast to cg and cairo we do not use a special BitmapImage because
450         the ownership of the FrameData inside the BitmapImage is a bit backward
451         (actually owned by the ImageDecoderQt...). Further work is needed for image
452         and pixmap handling in the qt port...
453
454         * WebCore.pro:
455         * platform/graphics/ImageBuffer.h:
456         * platform/graphics/qt/ImageBufferQt.cpp:
457         (WebCore::ImageBuffer::image):
458         * platform/graphics/qt/ImageQt.cpp:
459         * platform/graphics/qt/StillImageQt.cpp: Added.
460         (WebCore::StillImage::StillImage):
461         (WebCore::StillImage::size):
462         (WebCore::StillImage::getPixmap):
463         (WebCore::StillImage::draw):
464         * platform/graphics/qt/StillImageQt.h: Added.
465
466 2008-05-08  Holger Hans Peter Freyther  <zecke@selfish.org>
467
468         Reviewed by Simon.
469
470         Update the WebKit.qrc of the inspector to be functional again
471
472         * page/inspector/WebKit.qrc:
473
474 2008-05-08  Tor Arne Vestbø  <tavestbo@trolltech.com>
475
476         Reviewed by Simon
477
478         Fix the Qt/Mac build.
479
480         * platform/FileSystem.h:
481
482 2008-05-08  Ariya Hidayat  <ariya.hidayat@trolltech.com>
483
484         Reviewed by Simon.
485
486         Use native Windows library handling (instead of QLibrary) 
487         for Qt/Win32's PlatformModule.
488
489         * platform/FileSystem.h:
490         (WebCore::PlatformModuleVersion::PlatformModuleVersion):
491         * platform/qt/FileSystemQt.cpp:
492         (WebCore::unloadModule):
493
494 2008-05-08  Simon Hausmann  <hausmann@webkit.org>
495
496         Reviewed and found by Holger.
497
498         Include .css in the list of extensions for text/css. Fixes
499         fast/loader/local-css-allowed-in-strict-mode.html.
500
501         * platform/qt/MIMETypeRegistryQt.cpp:
502
503 2008-05-08  Simon Hausmann  <hausmann@webkit.org>
504
505         Fix the Qt and Wx build when compiling without offline app support.
506
507         * loader/FrameLoader.cpp:
508         (WebCore::FrameLoader::canCachePage):
509
510 2008-05-07  Sam Weinig  <sam@webkit.org>
511
512         Reviewed by Adele Peterson
513
514         Update MessageEvent to match the latest version of the HTML5 spec,
515         adding the lastEventId attribute.
516
517         * dom/MessageEvent.cpp:
518         (WebCore::MessageEvent::MessageEvent):
519         (WebCore::MessageEvent::initMessageEvent):
520         * dom/MessageEvent.h:
521         (WebCore::MessageEvent::lastEventId):
522         * dom/MessageEvent.idl:
523         * page/DOMWindow.cpp:
524         (WebCore::DOMWindow::postMessage):
525
526 2008-05-07  Stephanie Lewis <slewis@apple.com>
527
528         Reviewed by Maciej.
529
530         remove non-functioning code.  If onunload should be fired from these nodes then
531         a WindowEventListener needs to be set.  However, Firefox and IE also do not
532         fire onunload events for these cases.
533
534         Test: fast/events/onunload-not-on-body.html 
535         
536         * html/HTMLFrameElementBase.cpp:
537         (WebCore::HTMLFrameElementBase::parseMappedAttribute):
538         * html/HTMLObjectElement.cpp
539         (WebCore::HTMLObjectElement::parseMappedAttribute):
540
541 2008-05-07  Dan Bernstein  <mitz@apple.com>
542
543         Reviewed by John Sullivan.
544
545         - fix https://bugs.webkit.org/show_bug.cgi?id=18909
546           <rdar://problem/5914165> REGRESSION (r31872-r31878): Viewed photos not closing completely at indycar.com
547
548         Test: fast/dynamic/positioned-movement-with-positioned-children.html
549
550         * rendering/RenderBlock.cpp:
551         (WebCore::RenderBlock::layoutOnlyPositionedObjects): Cover the case of
552         a positioned object that has only moved and has only positioned children
553         that have changed.
554         * rendering/RenderObject.h:
555         (WebCore::RenderObject::needsPositionedMovementLayout): Added this
556         accessor.
557
558 2008-05-07  Anders Carlsson  <andersca@apple.com>
559
560         Reviewed by John.
561
562         When no document loaders are associated with an application cache group,
563         release the reference to the newest cache group. This prevents reference cycles.
564         
565         * loader/appcache/ApplicationCacheGroup.cpp:
566         (WebCore::ApplicationCacheGroup::ApplicationCacheGroup):
567         (WebCore::ApplicationCacheGroup::documentLoaderDestroyed):
568         (WebCore::ApplicationCacheGroup::cacheDestroyed):
569         * loader/appcache/ApplicationCacheGroup.h:
570         
571         * loader/appcache/ApplicationCacheStorage.cpp:
572         (WebCore::ApplicationCacheStorage::cacheGroupForURL):
573         Return early if the datbase wasn't open.
574         
575         (WebCore::ApplicationCacheStorage::loadCache):
576         Add error.
577
578 2008-05-07  Anders Carlsson  <andersca@apple.com>
579
580         Reviewed by Adam.
581
582         Don't put pages with an application cache in the BF cache.
583         
584         * loader/FrameLoader.cpp:
585         (WebCore::FrameLoader::canCachePage):
586
587 2008-05-07  Justin Garcia  <justin.garcia@apple.com>
588
589         Reviewed by John Sullivan.
590
591         <rdar://problem/5666354> Crashes in Mail at WebCore::RemoveNodeCommand::doApply
592         
593         When a single tab or series of tabs was copied, we weren't putting them into a 
594         tab span.  On Paste, we would be given a text node with a single tab or series
595         of tabs in it, and we would crash when inserting it at the start of a block
596         (where that kind of text becomes completely unrendered).
597
598         * editing/ReplaceSelectionCommand.cpp:
599         (WebCore::ReplaceSelectionCommand::removeUnrenderedTextNodesAtEnds): Clean
600         up correctly and early return if we removed everything that was inserted.
601         * editing/markup.cpp:
602         (WebCore::createMarkup):  Include the tab span when the only thing copied
603         was a tab or a series of tabs.
604
605 2008-05-07  Julien Chaffraix  <jchaffraix@webkit.org>
606
607         Reviewed by Adam Roben.
608
609         wx & Gtk build fix.
610
611         * platform/network/curl/FormDataStreamCurl.cpp: Added stdint.h include. We need to define
612         __STDC_LIMIT_MACROS to have SIZE_MAX exported.
613         * platform/network/curl/FormDataStreamCurl.h: Removed cstdint include (replaced by stdint.h)
614         as it is not present on the build bots.
615         * plugins/gtk/PluginDatabaseGtk.cpp: Added missing #endif.
616
617 2008-05-07  David Kilzer  <ddkilzer@apple.com>
618
619         Bug 18900: Password field has focus but can't type text (i.rememberthemilk.com)
620         <https://bugs.webkit.org/show_bug.cgi?id=18900>
621         <rdar://problem/5912383>
622
623         Original patch by Aaron Golden and Tim Omernick.  Reviewed by Adele.
624
625         Test: fast/forms/textfield-to-password-on-focus.html
626
627         * html/HTMLInputElement.cpp:
628         (WebCore::HTMLInputElement::setInputType): If the current node has
629         focus, call updateFocusAppearance() to make sure its state is correct
630         after changing its type.
631
632 2008-05-07  Chris Fleizach  <cfleizach@apple.com>
633
634         Reviewed by Alice Liu
635
636         <rdar://problem/4867889> REGRESSION: "Choose File.." buttons are exposed as AXGroup instead of AXButton
637
638         * page/AccessibilityObject.h:
639         (WebCore::AccessibilityObject::isFileUploadButton):
640         * page/AccessibilityRenderObject.cpp:
641         (WebCore::AccessibilityRenderObject::isFileUploadButton):
642         (WebCore::AccessibilityRenderObject::actionElement):
643         (WebCore::AccessibilityRenderObject::textUnderElement):
644         (WebCore::AccessibilityRenderObject::stringValue):
645         (WebCore::AccessibilityRenderObject::roleValue):
646         * page/AccessibilityRenderObject.h:
647         * rendering/RenderFileUploadControl.cpp:
648         (WebCore::RenderFileUploadControl::buttonValue):
649         (WebCore::RenderFileUploadControl::fileTextValue):
650         * rendering/RenderFileUploadControl.h:
651
652 2008-05-07  Julien Chaffraix  <jchaffraix@webkit.org>
653
654         Reviewed by Eric.
655
656         Bug 17971: [Curl] FormData processing should be moved to its own class
657
658         Move FormData treatment into FormDataStream. The aim is to have FormDataStream behave like a stream that cURL
659         could manipulate.
660
661         First step into having complete file uploading facility in cURL.
662
663         No test case as it is only code refactoring.
664
665         * GNUmakefile.am: Add FormDataStreamCurl.cpp
666         * platform/network/ResourceHandleInternal.h: Move code to FormStreamDataCurl.h
667         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
668         * platform/network/curl/FormDataStreamCurl.cpp: Added.
669         (WebCore::FormDataStream::~FormDataStream):
670         (WebCore::FormDataStream::read):
671         * platform/network/curl/FormDataStreamCurl.h: Added.
672         (WebCore::FormDataStream::FormDataStream):
673         * platform/network/curl/ResourceHandleCurl.cpp:
674         (WebCore::ResourceHandleInternal::~ResourceHandleInternal):
675         * platform/network/curl/ResourceHandleManager.cpp:
676         (WebCore::readCallback): Move code to FormDataStreamCurl.cpp
677
678 2008-05-07  Adam Treat  <treat@kde.org>
679
680         Reviewed by Simon.
681
682         https://bugs.webkit.org/show_bug.cgi?id=18898
683
684         Fixed wrong transform being used for creating the pixmap for a new
685         transparency layer. This fixes the popup menus on dell.com.
686
687         * platform/graphics/qt/GraphicsContextQt.cpp:
688         (WebCore::GraphicsContext::beginTransparencyLayer):
689
690 2008-05-07  Ariya Hidayat  <ariya.hidayat@trolltech.com>
691
692         Reviewed by Simon.
693
694         Share the plug-in directories between Gtk and Qt/X11 port.
695
696         * platform/qt/FileSystemQt.cpp:
697         (WebCore::homeDirectoryPath): Implement it for Qt.
698         * plugins/PluginDatabase.cpp:
699         (WebCore::addMozillaPluginDirectories): Shared code.
700         (WebCore::PluginDatabase::defaultPluginDirectories):
701         (WebCore::PluginDatabase::isPreferredPluginDirectory): Shared code.
702         * plugins/gtk/PluginDatabaseGtk.cpp:
703         (WebCore::PluginDatabase::isPreferredPluginDirectory): Refactored.
704         * plugins/qt/PluginDatabaseQt.cpp: Refactored.
705
706 2008-05-07  Tor Arne Vestbø  <tavestbo@trolltech.com>
707
708         Reviewed by Simon
709
710         Fix build issues on Mac and refeactor the .pro file a bit.
711
712         * WebCore.pro:
713         * platform/qt/TemporaryLinkStubs.cpp:
714         (PluginPackage::fetchInfo):
715
716 2008-05-07  Tor Arne Vestbø  <tavestbo@trolltech.com>
717
718         Reviewed by Simon
719
720         Draw scrollview corners (between scrollbars) using the Qt style.
721
722         https://bugs.webkit.org/show_bug.cgi?id=18894
723
724         * platform/qt/ScrollViewQt.cpp:
725         (WebCore::drawScrollbarCorner):
726         (WebCore::ScrollView::paint):
727
728 2008-05-07  Simon Hausmann  <hausmann@webkit.org>
729
730         Fix the Qt build, added AccessibilityListBox and ListBoxOption.cpp to
731         the build.
732
733         * WebCore.pro:
734
735 2008-05-07  Ariya Hidayat  <ariya.hidayat@trolltech.com>
736
737         Rubber-stamped by Holger.
738
739         Fix building without storage support.
740
741         * page/PageGroup.cpp:
742         (WebCore::PageGroup::closeLocalStorage): proper #if
743
744 2008-05-07  Ariya Hidayat  <ariya.hidayat@trolltech.com>
745
746         Rubber-stamped by Oliver Hunt.
747
748         Fix building without accessibility.
749
750         * page/AXObjectCache.cpp:
751         (WebCore::AXObjectCache::selectedChildrenChanged): proper #if
752
753 2008-05-06  Dan Bernstein  <mitz@apple.com>
754
755         Reviewed by Darin Adler.
756
757         - fix <rdar://problem/5914544> Crash in layoutInlineChildren()
758
759         Test: fast/block/float/float-on-zero-height-line.html
760
761         * rendering/RenderBlock.cpp:
762         (WebCore::RenderBlock::markLinesDirtyInVerticalRange):
763
764 2008-05-06  Alice Liu  <alice.liu@apple.com>
765
766         Reviewed by Adele Peterson and John Sullivan.
767
768         changes needed to build on Windows after r32911 and r32927
769
770         * WebCore.vcproj/WebCore.vcproj:
771         * page/AXObjectCache.cpp:
772         (WebCore::AXObjectCache::selectedChildrenChanged):
773         * page/AccessibilityObject.h:
774         (WebCore::AccessibilityObject::document):
775         (WebCore::AccessibilityObject::topDocumentFrameView):
776         (WebCore::AccessibilityObject::documentFrameView):
777         * page/AccessibilityRenderObject.cpp:
778         (WebCore::AccessibilityRenderObject::document):
779         (WebCore::AccessibilityRenderObject::topDocumentFrameView):
780         (WebCore::AccessibilityRenderObject::documentFrameView):
781         * page/AccessibilityRenderObject.h:
782         * page/mac/AXObjectCacheMac.mm:
783         * page/mac/AccessibilityObjectWrapper.mm:
784         (-[AccessibilityObjectWrapper position]):
785         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
786
787 2008-05-06  Brady Eidson  <beidson@apple.com>
788
789         Reviewed by Sam Weinig
790
791         Fix a few bugs with the final sync'ing of LocalStorageAreas when the thread is shut down.
792         1 - A sync task actually needs to be scheduled for each LocalStorageArea when the shut down occurs.
793         2 - Pending sync timers all need to be cancelled.
794
795         * storage/LocalStorage.cpp:
796         (WebCore::LocalStorage::storageArea):
797         (WebCore::LocalStorage::close): Tell each LocalStorageArea to schedule it's final sync before scheduling
798           thread termination.
799         * storage/LocalStorage.h:  Change the map to be of LocalStorageAreas instead of StorageAreas
800
801         * storage/LocalStorageArea.cpp:
802         (WebCore::LocalStorageArea::LocalStorageArea):
803         (WebCore::LocalStorageArea::~LocalStorageArea): ASSERT the timer has been cancelled, but make SURE it is
804           in release builds.
805         (WebCore::LocalStorageArea::scheduleFinalSync): Cancel the sync timer, schedule the final sync, and set the
806           "final sync scheduled" flag
807         (WebCore::LocalStorageArea::scheduleItemForSync): ASSERT that the final sync hasn't already been scheduled
808         (WebCore::LocalStorageArea::scheduleClear): Ditto
809         * storage/LocalStorageArea.h:
810
811 2008-05-06  Kevin Ollivier  <kevino@theolliviers.com>
812
813         wx build fix. Adding files added in  r32925 to the bakefiles.
814
815         * WebCoreSources.bkl:
816
817 2008-05-06  Alp Toker  <alp@nuanti.com>
818
819         GTK+ build fix. Add empty stub to keep non-accessible ports building.
820
821         * page/AXObjectCache.h:
822         (WebCore::AXObjectCache::selectedChildrenChanged):
823
824 2008-05-06  Beth Dakin  <bdakin@apple.com>
825
826         Reviewed by Darin.
827
828         Fix for <rdar://problem/5907916> Implement 'aria-labeledby' and 
829         'aria-describedby' attributes.
830
831         * html/HTMLAttributeNames.in: Added new attributes. Added both the 
832         British spelling (since that is what is specified in the spec), and 
833         the American spelling (since the bug filer and I are two Americans 
834         who keep spelling it the American way by accident). 
835         * page/AccessibilityObject.cpp: Added empty wrappers. These 
836         functions can't do anything meaningful without a renderer.
837         (WebCore::AccessibilityObject::ariaAccessiblityName):
838         (WebCore::AccessibilityObject::ariaLabeledByAttribute):
839         (WebCore::AccessibilityObject::ariaDescribedByAttribute):
840         * page/AccessibilityObject.h:
841
842         Here is where the real work is done.
843         * page/AccessibilityRenderObject.h:
844         * page/AccessibilityRenderObject.cpp:
845         (WebCore::accessibleNameForNode): Takes a node and finds its 
846         contribution to the accessible name, as defined by the Mozilla ARIA 
847         Implementer's Guide. 
848         (WebCore::AccessibilityRenderObject::ariaAccessiblityName): Takes a 
849         string of space-separated IDs, fetches the corresponding element 
850         for each ID, and concatenates an accessible name based on the 
851         elements.
852         (WebCore::AccessibilityRenderObject::ariaLabeledByAttribute): 
853         Retrieve the labeledby attribute and send its contents to 
854         ariaAccessibilityName().
855         (WebCore::AccessibilityRenderObject::title): Return the ARIA 
856         labeledby value if one exists.
857         (WebCore::AccessibilityRenderObject::ariaDescribedByAttribute): 
858         Retrieve the describedby attribute and send its contents to 
859         ariaAccessibilityName().
860         (WebCore::AccessibilityRenderObject::accessibilityDescription): 
861         Return the ARIA describedby attribute if one exists. 
862
863         These are two bugs I spotted. 
864         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored): Don't 
865         ignore anything with an ARIA role.
866         (WebCore::AccessibilityRenderObject::roleValue): Button tags maps 
867         to ButtonRole.
868
869 2008-05-06  Anders Carlsson  <andersca@apple.com>
870
871         Reviewed by Brady.
872
873         Support reading back app caches from the database.
874     
875         * loader/appcache/ApplicationCache.cpp:
876         (WebCore::ApplicationCache::ApplicationCache):
877         Initialize m_storageID to 0.
878         
879         * loader/appcache/ApplicationCacheGroup.cpp:
880         (WebCore::ApplicationCacheGroup::cacheDestroyed):
881         If the cache being destroyed is not the newest cache, it should no longer be 
882         stored in the database. Remove it.
883         
884         (WebCore::ApplicationCacheGroup::setNewestCache):
885         Don't store the cache here.
886         
887         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
888         Store it here instead.
889         
890         * loader/appcache/ApplicationCacheStorage.cpp:
891         (WebCore::ApplicationCacheStorage::loadCacheGroup):
892         New method that loads a cache group with a given manifest URL (or returns 0 if the load fails).
893         
894         (WebCore::ApplicationCacheStorage::findOrCreateCacheGroup):
895         Search for the group in the database.
896         
897         (WebCore::ApplicationCacheStorage::loadManifestHostHashes):
898         New method that loads the host hashes from the database.
899         
900         (WebCore::ApplicationCacheStorage::cacheGroupForURL):
901         Search in the database for a cache that contains the resource.
902         
903         (WebCore::ApplicationCacheStorage::loadCache):
904         New method that loads a cache with a given ID.
905         
906         (WebCore::ApplicationCacheStorage::remove):
907         New method that removes a cache.
908         
909         * loader/appcache/ApplicationCacheStorage.h:
910         Add definitions.
911
912 2008-05-06  Alp Toker  <alp@nuanti.com>
913
914         Partial GTK+ build fix. Add files from r32925 to the build and replace
915         'nil' return with 0.
916
917         * GNUmakefile.am:
918         * page/AccessibilityListBoxOption.cpp:
919         (WebCore::AccessibilityListBoxOption::parentObject):
920
921 2008-05-06  Brady Eidson  <beidson@apple.com>
922
923         Reviewed by Anders
924
925         Make LocalStorage persistent using a SQLite database.
926
927         There's a few things going on here.  Whenever an item is changed, we add it to a set of
928         "items to be sync'ed."  Instead of immediately scheduling the sync'ing on the background
929         thread, we set a "sync timer" instead.  This is to shield against a series of rapid changes
930         to avoid thread churn.
931
932         When the sync timer fires, we move the "items to be sync'ed" set to a background thread set
933         and schedule the sync task which is where the items are actually committed to disk.
934
935         Current design for reading items back in from disk is to be as aggressive as possible.
936         When a page first accesses it's LocalStorage area, we begin to import all items in from disk so
937         they are immediately available.  A future enhancement will be to being this pre-fetching the
938         moment we start loading a page when we know that page has LocalStorage.
939
940         * storage/LocalStorageArea.cpp:
941         (WebCore::LocalStorageArea::LocalStorageArea):
942         (WebCore::LocalStorageArea::length): Return the length, or wait for the import to complete then return it.
943         (WebCore::LocalStorageArea::key): Return the key, or wait for the import to complete then return it.
944         (WebCore::LocalStorageArea::getItem): Return the item, or wait for the import to complete then return it.
945         (WebCore::LocalStorageArea::setItem): Set the item, or hold the import lock and set it.  The second case is
946           because if the item is set while the import is still in progress, the new value should override whatever
947           the imported value is.
948         (WebCore::LocalStorageArea::removeItem): Remove the item, or hold the import lock and remove it.  See the 
949           explanation for setItem()
950         (WebCore::LocalStorageArea::contains): Return whether or not the item is contained.  Do the same dance with
951           the import flag, import lock, and import condition that the above methods do.
952
953         (WebCore::LocalStorageArea::itemChanged): Schedule the item for sync'ing
954         (WebCore::LocalStorageArea::itemRemoved): Schedule the removal of the item for sync'ing
955         (WebCore::LocalStorageArea::areaCleared): Schedule the clear for sync'ing, and clear all previously 
956           scheduled items.
957
958         (WebCore::LocalStorageArea::scheduleItemForSync): Add an item to the sync set.
959         (WebCore::LocalStorageArea::scheduleClear): Set a bool flag denoting "All items removed."  If any
960           items are later set before the actual removal takes place, they will be written *after* the removal.
961         (WebCore::LocalStorageArea::syncTimerFired): Move the current sync-set to the background thread sync set, then 
962           schedule a sync task.  Also transfer the "items cleared" flag to the "background thread items cleared" flag
963         (WebCore::LocalStorageArea::performImport): Import all items from disk, then signal the import complete.
964         (WebCore::LocalStorageArea::markImported): Set the imported flag and signal the import complete
965         (WebCore::LocalStorageArea::performSync): If the clear flag is set then drop all items.  Then update or delete 
966           each item waiting to be sync'ed
967         * storage/LocalStorageArea.h:
968
969 2008-05-06  Brady Eidson  <beidson@apple.com>
970
971         Rubberstamped by Mitz Pettel RTL
972
973         * storage/LocalStorage.cpp:
974         (WebCore::LocalStorage::fullDatabaseFilename): Filename extensions for localstorage = all lowercase
975
976 2008-05-06  Brady Eidson  <beidson@apple.com>
977
978         Reviewed by Darin, Sam Weinig, and Anders
979
980         Preparation for upcoming work making LocalStorage persistent.
981
982         The final step before code that actually does storage and retrieval of LocalStorage items.
983
984         The LocalStorage set is responsible for controlling the path and filenames that individual
985         LocalStorageAreas will use for their persistent store.  This adds the ability to return that
986         filename.
987
988         Also, add the scheduling methods that LocalStorageArea will use for importing and syncing 
989         it's persistent items.
990
991         * storage/LocalStorage.cpp:
992         (WebCore::LocalStorage::storageArea):  Add some comments re: the future direction of this
993           method once we actually do quota tracking.
994         (WebCore::LocalStorage::fullDatabaseFilename):
995         (WebCore::LocalStorage::scheduleImport):
996         (WebCore::LocalStorage::scheduleSync):
997         * storage/LocalStorage.h:
998
999 2008-05-06  Chris Fleizach  <cfleizach@apple.com>
1000
1001         Reviewed by Beth Dakin.
1002
1003         rdar://problem/5408464> REGRESSION: Unable to use Voiceover on combo boxes (disneyjobs.com)
1004
1005         * WebCore.xcodeproj/project.pbxproj:
1006         * html/HTMLOptGroupElement.cpp:
1007         (WebCore::HTMLOptGroupElement::ownerSelectElement):
1008         (WebCore::HTMLOptGroupElement::accessKeyAction):
1009         * html/HTMLOptGroupElement.h:
1010         * html/HTMLOptionElement.cpp:
1011         (WebCore::HTMLOptionElement::accessKeyAction):
1012         (WebCore::HTMLOptionElement::index):
1013         (WebCore::HTMLOptionElement::setSelected):
1014         (WebCore::HTMLOptionElement::childrenChanged):
1015         (WebCore::HTMLOptionElement::ownerSelectElement):
1016         (WebCore::HTMLOptionElement::insertedIntoDocument):
1017         * html/HTMLOptionElement.h:
1018         * html/HTMLSelectElement.cpp:
1019         (WebCore::HTMLSelectElement::childrenChanged):
1020         (WebCore::HTMLSelectElement::accessKeySetSelectedIndex):
1021         * html/HTMLSelectElement.h:
1022         * page/AXObjectCache.cpp:
1023         (WebCore::AXObjectCache::get):
1024         * page/AccessibilityListBox.cpp: Added.
1025         (WebCore::AccessibilityListBox::AccessibilityListBox):
1026         (WebCore::AccessibilityListBox::~AccessibilityListBox):
1027         (WebCore::AccessibilityListBox::create):
1028         (WebCore::AccessibilityListBox::addChildren):
1029         (WebCore::AccessibilityListBox::selectedChildren):
1030         (WebCore::AccessibilityListBox::visibleChildren):
1031         (WebCore::AccessibilityListBox::listBoxOptionAccessibilityObject):
1032         (WebCore::AccessibilityListBox::doAccessibilityHitTest):
1033         * page/AccessibilityListBox.h: Added.
1034         (WebCore::AccessibilityListBox::accessibilityShouldUseUniqueId):
1035         (WebCore::AccessibilityListBox::isListBox):
1036         (WebCore::AccessibilityListBox::canSetFocusAttribute):
1037         (WebCore::AccessibilityListBox::roleValue):
1038         (WebCore::AccessibilityListBox::accessibilityIsIgnored):
1039         * page/AccessibilityListBoxOption.cpp: Added.
1040         (WebCore::AccessibilityListBoxOption::AccessibilityListBoxOption):
1041         (WebCore::AccessibilityListBoxOption::~AccessibilityListBoxOption):
1042         (WebCore::AccessibilityListBoxOption::create):
1043         (WebCore::AccessibilityListBoxOption::isEnabled):
1044         (WebCore::AccessibilityListBoxOption::isSelected):
1045         (WebCore::AccessibilityListBoxOption::elementRect):
1046         (WebCore::AccessibilityListBoxOption::title):
1047         (WebCore::AccessibilityListBoxOption::size):
1048         (WebCore::AccessibilityListBoxOption::actionElement):
1049         (WebCore::AccessibilityListBoxOption::parentObject):
1050         (WebCore::AccessibilityListBoxOption::listBoxOptionParentNode):
1051         (WebCore::AccessibilityListBoxOption::listBoxOptionIndex):
1052         * page/AccessibilityListBoxOption.h: Added.
1053         (WebCore::AccessibilityListBoxOption::setHTMLElement):
1054         (WebCore::AccessibilityListBoxOption::roleValue):
1055         (WebCore::AccessibilityListBoxOption::accessibilityIsIgnored):
1056         (WebCore::AccessibilityListBoxOption::isListBoxOption):
1057         * page/AccessibilityObject.h:
1058         (WebCore::AccessibilityObject::isListBox):
1059         * page/AccessibilityRenderObject.cpp:
1060         (WebCore::AccessibilityRenderObject::doAccessibilityHitTest):
1061         * page/mac/AccessibilityObjectWrapper.mm:
1062         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
1063         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
1064         * rendering/RenderListBox.cpp:
1065         (WebCore::RenderListBox::selectionChanged):
1066         * rendering/RenderListBox.h:
1067
1068 2008-05-06  Chris Fleizach  <cfleizach@apple.com>
1069
1070         Reviewed by Beth Dakin.
1071
1072          <rdar://problem/5455287> AXWebArea should include AXURL
1073
1074         * page/AccessibilityRenderObject.cpp:
1075         (WebCore::AccessibilityRenderObject::url):
1076         * page/mac/AccessibilityObjectWrapper.mm:
1077         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
1078
1079 2008-05-06  Alice Liu  <alice.liu@apple.com>
1080
1081         Rubber-stamped by Beth
1082         
1083         stab-in-the-dark attempt at fixing non-mac builds.
1084
1085         * GNUmakefile.am:
1086         * WebCore.pro:
1087         * WebCore.vcproj/WebCore.vcproj:
1088         * WebCoreSources.bkl:
1089
1090 2008-05-06  Anders Carlsson  <andersca@apple.com>
1091
1092         Reviewed by Adam.
1093
1094         Only use the toplevel application cache when loading subframes.
1095
1096         * loader/MainResourceLoader.cpp:
1097         (WebCore::MainResourceLoader::load):
1098
1099 2008-05-06  Adam Barth  <abarth-webkit@adambarth.com>
1100
1101         Reviewed by Sam Weinig.
1102
1103         https://bugs.webkit.org/show_bug.cgi?id=18725
1104         Implement asynchronous postMessage.
1105         MessageEvent no longer bubbles as per r1237 in the HTML 5 working draft.
1106
1107         Collin Jackson <collinj-webkit@collinjackson.com> also contributed to this patch.
1108
1109         Test: http/tests/security/postMessage/delivery-order.html
1110
1111         * dom/MessageEvent.cpp:
1112         (WebCore::MessageEvent::MessageEvent):
1113         * page/DOMWindow.cpp:
1114         (WebCore::PostMessageTimer::PostMessageTimer):
1115         (WebCore::PostMessageTimer::event):
1116         (WebCore::PostMessageTimer::targetOrigin):
1117         (WebCore::PostMessageTimer::fired):
1118         (WebCore::DOMWindow::postMessage):
1119         (WebCore::DOMWindow::postMessageTimerFired):
1120         * page/DOMWindow.h:
1121         * page/DOMWindow.idl:
1122         
1123 2008-05-06  Anders Carlsson  <andersca@apple.com>
1124
1125         Reviewed by Brady.
1126
1127         Store cache to the database.
1128
1129         * loader/appcache/ApplicationCache.cpp:
1130         (WebCore::ApplicationCache::addResource):
1131         If the cache has been saved to disk, save the resource as well.
1132         
1133         * loader/appcache/ApplicationCache.h:
1134         (WebCore::ApplicationCache::onlineWhitelist):
1135         New method which returns the online whitelist.
1136
1137         (WebCore::ApplicationCache::setStorageId):
1138         (WebCore::ApplicationCache::storageId):
1139         Setter/getter for the application cache storage ID.
1140
1141         * loader/appcache/ApplicationCacheGroup.cpp:
1142         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
1143         Save the cache/group to disk.
1144         
1145         * loader/appcache/ApplicationCacheGroup.h:
1146         (WebCore::ApplicationCacheGroup::setStorageID):
1147         (WebCore::ApplicationCacheGroup::storageID):
1148         Setter/getter for the application cache group storage ID.
1149         
1150         * loader/appcache/ApplicationCacheResource.cpp:
1151         (WebCore::ApplicationCacheResource::addType):
1152         We can't add a new type if the resource has been saved to disk.
1153         
1154         * loader/appcache/ApplicationCacheResource.h:
1155         (WebCore::ApplicationCacheResource::setStorageID):
1156         (WebCore::ApplicationCacheResource::storageID):
1157         Setter/getter for the application cache resource storage ID.
1158
1159         * loader/appcache/ApplicationCacheStorage.cpp:
1160         * loader/appcache/ApplicationCacheStorage.cpp:
1161         (WebCore::ApplicationCacheStorage::executeSQLCommand):
1162         New method for executing SQL and logging any errors.
1163         
1164         (WebCore::ApplicationCacheStorage::openDatabase):
1165         Create new tables.
1166         
1167         (WebCore::ApplicationCacheStorage::executeStatement):
1168         New method for executing an SQL statement and logging any errors.
1169         
1170         (WebCore::ApplicationCacheStorage::store):
1171         New methods for storing a cache group, cache and cache resource to the store.
1172
1173         (WebCore::ApplicationCacheStorage::storeNewestCache):
1174         New method which stores the newest cache and updates the newest cache field in the cache group.
1175         
1176         * loader/appcache/ApplicationCacheStorage.h:
1177         Add new methods.
1178         
1179         * platform/sql/SQLiteStatement.h:
1180         (WebCore::SQLiteStatement::query):
1181         Getter for the SQL query.
1182
1183 2008-05-06  Brady Eidson  <beidson@apple.com>
1184
1185         Reviewed by Darin Adler
1186
1187         Preparation for upcoming work making LocalStorage persistent.
1188
1189         Writing persistent values for LocalStorage will take place on a background thread.
1190         Here is that background thread, as well as most of the hooks that will be utilized to
1191         make the whole song and dance work.
1192
1193         The thread itself is very simple and MessageQueue based.  LocalStorageTasks are what 
1194         mark the work that needs to be done and come in 5 flavors:  Import and Sync a LocalStorage set,
1195         Import and Sync a LocalStorageArea, and terminate the thread.
1196
1197         This patch accomplished 2 things:
1198         
1199         1 - Each PageGroup has its own LocalStorage set.  Upon its creation its LocalStorageThread is 
1200             created and started.
1201
1202         2 - At application shutdown, each thread is synchronously terminated.
1203
1204         What happens between steps 1 and 2 will come later.
1205
1206         * GNUmakefile.am:
1207         * WebCore.pro:
1208         * WebCore.vcproj/WebCore.vcproj:
1209         * WebCore.xcodeproj/project.pbxproj:
1210         * WebCoreSources.bkl:
1211
1212         * storage/LocalStorage.cpp: Add some threading ASSERTs to make it clear which thread each
1213           method is meant to be called from.
1214         (WebCore::LocalStorage::LocalStorage):
1215         (WebCore::LocalStorage::storageArea):
1216         (WebCore::LocalStorage::performImport): Placeholder for importing known origins and quotas
1217         (WebCore::LocalStorage::performSync): Placeholder for writing out updated origins and quotas
1218         (WebCore::LocalStorage::close): Synchronously terminate the thread.
1219         * storage/LocalStorage.h:
1220
1221         * storage/LocalStorageArea.cpp: Add some threading ASSERTs to make it clear which thread each
1222           method is meant to be called from.
1223         (WebCore::LocalStorageArea::itemChanged):
1224         (WebCore::LocalStorageArea::itemRemoved):
1225         (WebCore::LocalStorageArea::areaCleared):
1226         (WebCore::LocalStorageArea::dispatchStorageEvent):
1227         (WebCore::LocalStorageArea::performImport): Placeholder for importing all items for this 
1228           LocalStorageArea to prime the page before the items are needed
1229         (WebCore::LocalStorageArea::performSync): Placeholder for writing out dirty items to disk
1230         * storage/LocalStorageArea.h:
1231
1232         * storage/LocalStorageTask.cpp: Added.
1233         (WebCore::LocalStorageTask::LocalStorageTask):
1234         (WebCore::LocalStorageTask::performTask):
1235         * storage/LocalStorageTask.h: Added.
1236         (WebCore::LocalStorageTask::):
1237         (WebCore::LocalStorageTask::createImport):
1238         (WebCore::LocalStorageTask::createSync):
1239         (WebCore::LocalStorageTask::createTerminate):
1240
1241         * storage/LocalStorageThread.cpp: Added.
1242         (WebCore::LocalStorageThread::create):
1243         (WebCore::LocalStorageThread::LocalStorageThread):
1244         (WebCore::LocalStorageThread::start):
1245         (WebCore::LocalStorageThread::localStorageThreadStart):
1246         (WebCore::LocalStorageThread::localStorageThread):
1247         (WebCore::LocalStorageThread::scheduleImport):
1248         (WebCore::LocalStorageThread::scheduleSync):
1249         (WebCore::LocalStorageThread::terminate): 
1250         (WebCore::LocalStorageThread::performTerminate):
1251         * storage/LocalStorageThread.h: Added.
1252
1253 2008-05-06  Anders Carlsson  <andersca@apple.com>
1254
1255         Reviewed by Darin.
1256
1257         Add NPN_PopUpContextMenu.
1258         
1259         * bridge/npapi.h:
1260         * plugins/npfunctions.h:
1261
1262 2008-05-06  Alp Toker  <alp@nuanti.com>
1263
1264         GTK+ build fix. Add file from r32911 to the build.
1265
1266         * GNUmakefile.am:
1267
1268 2008-05-06  Gwenole Beauchesne  <gbeauchesne@splitted-desktop.org>
1269
1270         Reviewed by Alp Toker.
1271
1272         http://bugs.webkit.org/show_bug.cgi?id=18906
1273         [GTK] Fix varargs terminator in g_build_filename()
1274
1275         * plugins/gtk/PluginDatabaseGtk.cpp:
1276         (WebCore::PluginDatabase::isPreferredPluginDirectory): Fix varargs
1277         terminator.
1278
1279 2008-05-06  Kevin McCullough  <kmccullough@apple.com>
1280
1281         - Forgot to update localized Strings from previous checkin.
1282
1283         * English.lproj/localizedStrings.js:
1284
1285 2008-05-06  Chris Fleizach  <cfleizach@apple.com>
1286
1287         Reviewed by Beth Dakin
1288
1289         <rdar://problem/5408464> REGRESSION: Unable to use Voiceover on combo boxes (disneyjobs.com)
1290         <rdar://problem/5895634> AX: AccessibilityObjectWrapper is being leaked all over the place
1291         <rdar://problem/5893907> CrashTracer: [REGRESSION] 44 crashes in Safari at com.apple.WebCore: WebCore::AccessibilityObject::clearChildren + 9
1292         
1293         Initial prep work to support accessibility objects that do not have renderers. 
1294
1295         * WebCore.xcodeproj/project.pbxproj:
1296         * page/AXObjectCache.cpp:
1297         (WebCore::AXObjectCache::~AXObjectCache):
1298         (WebCore::AXObjectCache::get):
1299         (WebCore::AXObjectCache::remove):
1300         (WebCore::AXObjectCache::getAXID):
1301         (WebCore::AXObjectCache::removeAXID):
1302         (WebCore::AXObjectCache::childrenChanged):
1303         * page/AXObjectCache.h:
1304         (WebCore::AXObjectCache::isIDinUse):
1305         * page/AccessibilityObject.cpp:
1306         (WebCore::AccessibilityObject::AccessibilityObject):
1307         (WebCore::AccessibilityObject::create):
1308         (WebCore::AccessibilityObject::detach):
1309         (WebCore::AccessibilityObject::firstChild):
1310         (WebCore::AccessibilityObject::lastChild):
1311         (WebCore::AccessibilityObject::previousSibling):
1312         (WebCore::AccessibilityObject::nextSibling):
1313         (WebCore::AccessibilityObject::parentObject):
1314         (WebCore::AccessibilityObject::layoutCount):
1315         (WebCore::AccessibilityObject::text):
1316         (WebCore::AccessibilityObject::helpText):
1317         (WebCore::AccessibilityObject::textUnderElement):
1318         (WebCore::AccessibilityObject::isARIAInput):
1319         (WebCore::AccessibilityObject::isARIAControl):
1320         (WebCore::AccessibilityObject::intValue):
1321         (WebCore::AccessibilityObject::stringValue):
1322         (WebCore::AccessibilityObject::title):
1323         (WebCore::AccessibilityObject::accessibilityDescription):
1324         (WebCore::AccessibilityObject::boundingBoxRect):
1325         (WebCore::AccessibilityObject::elementRect):
1326         (WebCore::AccessibilityObject::size):
1327         (WebCore::AccessibilityObject::linkedUIElement):
1328         (WebCore::AccessibilityObject::textLength):
1329         (WebCore::AccessibilityObject::ariaSelectedTextDOMRange):
1330         (WebCore::AccessibilityObject::selectedText):
1331         (WebCore::AccessibilityObject::accessKey):
1332         (WebCore::AccessibilityObject::selection):
1333         (WebCore::AccessibilityObject::selectedTextRange):
1334         (WebCore::AccessibilityObject::setSelectedTextRange):
1335         (WebCore::AccessibilityObject::url):
1336         (WebCore::AccessibilityObject::setFocused):
1337         (WebCore::AccessibilityObject::setValue):
1338         (WebCore::AccessibilityObject::axObjectCache):
1339         (WebCore::AccessibilityObject::getDocumentLinks):
1340         (WebCore::AccessibilityObject::widget):
1341         (WebCore::AccessibilityObject::widgetForAttachmentView):
1342         (WebCore::AccessibilityObject::anchorElement):
1343         (WebCore::AccessibilityObject::actionElement):
1344         (WebCore::AccessibilityObject::visiblePositionRange):
1345         (WebCore::AccessibilityObject::doAXTextMarkerRangeForLine):
1346         (WebCore::AccessibilityObject::visiblePositionForIndex):
1347         (WebCore::AccessibilityObject::indexForVisiblePosition):
1348         (WebCore::AccessibilityObject::doAXBoundsForTextMarkerRange):
1349         (WebCore::AccessibilityObject::doSetAXSelectedTextMarkerRange):
1350         (WebCore::AccessibilityObject::doAXTextMarkerForPosition):
1351         (WebCore::AccessibilityObject::textMarkerForIndex):
1352         (WebCore::AccessibilityObject::rangeForTextMarkerRange):
1353         (WebCore::AccessibilityObject::indexForTextMarker):
1354         (WebCore::AccessibilityObject::doAXRangeForLine):
1355         (WebCore::AccessibilityObject::doAXRangeForPosition):
1356         (WebCore::AccessibilityObject::doAXRangeForIndex):
1357         (WebCore::AccessibilityObject::doAXStyleRangeForIndex):
1358         (WebCore::AccessibilityObject::doAXStringForRange):
1359         (WebCore::AccessibilityObject::doAXBoundsForRange):
1360         (WebCore::AccessibilityObject::doAccessibilityHitTest):
1361         (WebCore::AccessibilityObject::focusedUIElement):
1362         (WebCore::AccessibilityObject::observableObject):
1363         (WebCore::AccessibilityObject::roleValue):
1364         (WebCore::AccessibilityObject::ariaRoleAttribute):
1365         (WebCore::AccessibilityObject::childrenChanged):
1366         (WebCore::AccessibilityObject::addChildren):
1367         (WebCore::AccessibilityObject::removeAXObjectID):
1368         * page/AccessibilityObject.h:
1369         (WebCore::):
1370         (WebCore::PlainTextRange::PlainTextRange):
1371         (WebCore::PlainTextRange::isNull):
1372         (WebCore::AccessibilityObject::isAccessibilityRenderObject):
1373         (WebCore::AccessibilityObject::isAnchor):
1374         (WebCore::AccessibilityObject::isAttachment):
1375         (WebCore::AccessibilityObject::isHeading):
1376         (WebCore::AccessibilityObject::isLink):
1377         (WebCore::AccessibilityObject::isImage):
1378         (WebCore::AccessibilityObject::isNativeImage):
1379         (WebCore::AccessibilityObject::isImageButton):
1380         (WebCore::AccessibilityObject::isPasswordField):
1381         (WebCore::AccessibilityObject::isTextControl):
1382         (WebCore::AccessibilityObject::isNativeTextControl):
1383         (WebCore::AccessibilityObject::isWebArea):
1384         (WebCore::AccessibilityObject::isCheckboxOrRadio):
1385         (WebCore::AccessibilityObject::isChecked):
1386         (WebCore::AccessibilityObject::isEnabled):
1387         (WebCore::AccessibilityObject::isSelected):
1388         (WebCore::AccessibilityObject::isFocused):
1389         (WebCore::AccessibilityObject::isHovered):
1390         (WebCore::AccessibilityObject::isIndeterminate):
1391         (WebCore::AccessibilityObject::isLoaded):
1392         (WebCore::AccessibilityObject::isMultiSelect):
1393         (WebCore::AccessibilityObject::isOffScreen):
1394         (WebCore::AccessibilityObject::isPressed):
1395         (WebCore::AccessibilityObject::isReadOnly):
1396         (WebCore::AccessibilityObject::isVisited):
1397         (WebCore::AccessibilityObject::canSetFocusAttribute):
1398         (WebCore::AccessibilityObject::canSetTextRangeAttributes):
1399         (WebCore::AccessibilityObject::canSetValueAttribute):
1400         (WebCore::AccessibilityObject::hasIntValue):
1401         (WebCore::AccessibilityObject::accessibilityShouldUseUniqueId):
1402         (WebCore::AccessibilityObject::accessibilityIsIgnored):
1403         (WebCore::AccessibilityObject::children):
1404         (WebCore::AccessibilityObject::hasChildren):
1405         (WebCore::AccessibilityObject::setWrapper):
1406         (WebCore::AccessibilityObject::isDetached):
1407         * page/AccessibilityRenderObject.cpp: Added.
1408         (WebCore::AccessibilityRenderObject::AccessibilityRenderObject):
1409         (WebCore::AccessibilityRenderObject::~AccessibilityRenderObject):
1410         (WebCore::AccessibilityRenderObject::create):
1411         (WebCore::AccessibilityRenderObject::detach):
1412         (WebCore::AccessibilityRenderObject::firstChild):
1413         (WebCore::AccessibilityRenderObject::lastChild):
1414         (WebCore::AccessibilityRenderObject::previousSibling):
1415         (WebCore::AccessibilityRenderObject::nextSibling):
1416         (WebCore::AccessibilityRenderObject::parentObject):
1417         (WebCore::AccessibilityRenderObject::isWebArea):
1418         (WebCore::AccessibilityRenderObject::isImageButton):
1419         (WebCore::AccessibilityRenderObject::isAnchor):
1420         (WebCore::AccessibilityRenderObject::isNativeTextControl):
1421         (WebCore::AccessibilityRenderObject::isTextControl):
1422         (WebCore::AccessibilityRenderObject::isNativeImage):
1423         (WebCore::AccessibilityRenderObject::isImage):
1424         (WebCore::AccessibilityRenderObject::isAttachment):
1425         (WebCore::AccessibilityRenderObject::isPasswordField):
1426         (WebCore::AccessibilityRenderObject::isCheckboxOrRadio):
1427         (WebCore::AccessibilityRenderObject::isPressed):
1428         (WebCore::AccessibilityRenderObject::isIndeterminate):
1429         (WebCore::AccessibilityRenderObject::isChecked):
1430         (WebCore::AccessibilityRenderObject::isHovered):
1431         (WebCore::AccessibilityRenderObject::isMultiSelect):
1432         (WebCore::AccessibilityRenderObject::isReadOnly):
1433         (WebCore::AccessibilityRenderObject::isOffScreen):
1434         (WebCore::AccessibilityRenderObject::headingLevel):
1435         (WebCore::AccessibilityRenderObject::isHeading):
1436         (WebCore::AccessibilityRenderObject::isLink):
1437         (WebCore::AccessibilityRenderObject::anchorElement):
1438         (WebCore::AccessibilityRenderObject::actionElement):
1439         (WebCore::AccessibilityRenderObject::mouseButtonListener):
1440         (WebCore::AccessibilityRenderObject::helpText):
1441         (WebCore::AccessibilityRenderObject::textUnderElement):
1442         (WebCore::AccessibilityRenderObject::hasIntValue):
1443         (WebCore::AccessibilityRenderObject::intValue):
1444         (WebCore::AccessibilityRenderObject::stringValue):
1445         (WebCore::labelForElement):
1446         (WebCore::AccessibilityRenderObject::title):
1447         (WebCore::AccessibilityRenderObject::accessibilityDescription):
1448         (WebCore::AccessibilityRenderObject::boundingBoxRect):
1449         (WebCore::AccessibilityRenderObject::elementRect):
1450         (WebCore::AccessibilityRenderObject::size):
1451         (WebCore::AccessibilityRenderObject::linkedUIElement):
1452         (WebCore::AccessibilityRenderObject::accessibilityShouldUseUniqueId):
1453         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
1454         (WebCore::AccessibilityRenderObject::isLoaded):
1455         (WebCore::AccessibilityRenderObject::layoutCount):
1456         (WebCore::AccessibilityRenderObject::text):
1457         (WebCore::AccessibilityRenderObject::textLength):
1458         (WebCore::AccessibilityRenderObject::ariaSelectedTextDOMRange):
1459         (WebCore::AccessibilityRenderObject::selectedText):
1460         (WebCore::AccessibilityRenderObject::accessKey):
1461         (WebCore::AccessibilityRenderObject::selection):
1462         (WebCore::AccessibilityRenderObject::selectedTextRange):
1463         (WebCore::AccessibilityRenderObject::setSelectedTextRange):
1464         (WebCore::AccessibilityRenderObject::url):
1465         (WebCore::AccessibilityRenderObject::isVisited):
1466         (WebCore::AccessibilityRenderObject::isSelected):
1467         (WebCore::AccessibilityRenderObject::isFocused):
1468         (WebCore::AccessibilityRenderObject::setFocused):
1469         (WebCore::AccessibilityRenderObject::setValue):
1470         (WebCore::AccessibilityRenderObject::isEnabled):
1471         (WebCore::AccessibilityRenderObject::topRenderer):
1472         (WebCore::AccessibilityRenderObject::widget):
1473         (WebCore::AccessibilityRenderObject::axObjectCache):
1474         (WebCore::AccessibilityRenderObject::getDocumentLinks):
1475         (WebCore::AccessibilityRenderObject::widgetForAttachmentView):
1476         (WebCore::AccessibilityRenderObject::frameViewIfRenderView):
1477         (WebCore::AccessibilityRenderObject::visiblePositionRange):
1478         (WebCore::AccessibilityRenderObject::doAXTextMarkerRangeForLine):
1479         (WebCore::AccessibilityRenderObject::visiblePositionForIndex):
1480         (WebCore::AccessibilityRenderObject::indexForVisiblePosition):
1481         (WebCore::AccessibilityRenderObject::doAXBoundsForTextMarkerRange):
1482         (WebCore::AccessibilityRenderObject::doSetAXSelectedTextMarkerRange):
1483         (WebCore::AccessibilityRenderObject::doAXTextMarkerForPosition):
1484         (WebCore::AccessibilityRenderObject::textMarkerForIndex):
1485         (WebCore::AccessibilityRenderObject::indexForTextMarker):
1486         (WebCore::AccessibilityRenderObject::doAXRangeForLine):
1487         (WebCore::AccessibilityRenderObject::doAXRangeForIndex):
1488         (WebCore::AccessibilityRenderObject::doAXStringForRange):
1489         (WebCore::AccessibilityRenderObject::doAXBoundsForRange):
1490         (WebCore::AccessibilityRenderObject::doAccessibilityHitTest):
1491         (WebCore::AccessibilityRenderObject::focusedUIElement):
1492         (WebCore::AccessibilityRenderObject::observableObject):
1493         (WebCore::createARIARoleMap):
1494         (WebCore::RoleEntry::):
1495         (WebCore::ariaRoleToWebCoreRole):
1496         (WebCore::AccessibilityRenderObject::ariaRoleAttribute):
1497         (WebCore::AccessibilityRenderObject::roleValue):
1498         (WebCore::AccessibilityRenderObject::canSetFocusAttribute):
1499         (WebCore::AccessibilityRenderObject::canSetValueAttribute):
1500         (WebCore::AccessibilityRenderObject::canSetTextRangeAttributes):
1501         (WebCore::AccessibilityRenderObject::childrenChanged):
1502         (WebCore::AccessibilityRenderObject::children):
1503         (WebCore::AccessibilityRenderObject::addChildren):
1504         (WebCore::AccessibilityRenderObject::removeAXObjectID):
1505         (WebCore::AccessibilityRenderObject::actionVerb):
1506         * page/AccessibilityRenderObject.h: Added.
1507         (WebCore::AccessibilityRenderObject::isAccessibilityRenderObject):
1508         (WebCore::AccessibilityRenderObject::areaElement):
1509         (WebCore::AccessibilityRenderObject::setRenderer):
1510         (WebCore::AccessibilityRenderObject::renderer):
1511         (WebCore::AccessibilityRenderObject::setRenderObject):
1512         (WebCore::AccessibilityRenderObject::isDetached):
1513         * page/mac/AXObjectCacheMac.mm:
1514         (WebCore::AXObjectCache::detachWrapper):
1515         (WebCore::AXObjectCache::selectedChildrenChanged):
1516         (WebCore::AXObjectCache::postNotification):
1517         * page/mac/AccessibilityObjectWrapper.mm:
1518         (textMarkerForVisiblePosition):
1519         (CreateCGColorIfDifferent):
1520         (AXAttributeStringSetHeadingLevel):
1521         (AXLinkElementForNode):
1522         (AXAttributeStringSetElement):
1523         (AXAttributedStringAppendText):
1524         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
1525         (-[AccessibilityObjectWrapper documentFrameView:]):
1526         (-[AccessibilityObjectWrapper position]):
1527         (RoleEntry::):
1528         (-[AccessibilityObjectWrapper roleDescription]):
1529         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
1530         (-[AccessibilityObjectWrapper accessibilityIsAttributeSettable:]):
1531         (-[AccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
1532         (-[AccessibilityObjectWrapper accessibilitySetValue:forAttribute:]):
1533         (-[AccessibilityObjectWrapper _accessibilityParentForSubview:]):
1534         (-[AccessibilityObjectWrapper doAXAttributedStringForRange:]):
1535         (-[AccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
1536
1537 2008-05-06  Jonathan Haas  <myrdred@gmail.com>
1538
1539         Reviewed by Rob Buis.
1540
1541         https://bugs.webkit.org/show_bug.cgi?id=18859\
1542         Prevented SVGRootInlineBox from static_casting a
1543         node to a class it doesn't inherit
1544         
1545         * rendering/SVGRootInlineBox.cpp:
1546         (WebCore::SVGRootInlineBox::buildTextChunks):
1547
1548 2008-05-06  Brady Eidson  <beidson@apple.com>
1549
1550         Reviewed by Darin Adler
1551
1552         Preparation for upcoming work making LocalStorage persistent.
1553
1554         When the application terminates, all pending local storage writes need to be
1555         sync'ed out to disk.
1556         This works n combination with platform specific code in WebKit that calls it.
1557
1558         * WebCore.base.exp:
1559
1560         * page/PageGroup.cpp:
1561         (WebCore::PageGroup::closeLocalStorage): Close all open LocalStorage objects
1562         * page/PageGroup.h:
1563
1564         * storage/LocalStorage.cpp:
1565         (WebCore::LocalStorage::close): Placeholder for what will sync and terminate the
1566           local storage thread in the future.
1567         * storage/LocalStorage.h:
1568
1569 2008-05-06  Brady Eidson  <beidson@apple.com>
1570
1571         Rubberstamped by David Kilzer
1572
1573         * WebCore.base.exp:  Sort this mess!
1574
1575 2008-05-05  Mark Rowe  <mrowe@apple.com>
1576
1577         Reviewed by Dan Bernstein.
1578
1579         Fix 60 crashes seen on the buildbots that were misreported as hangs.
1580
1581         * dom/Document.cpp:
1582         (WebCore::Document::detachNodeIterator): Null-check page() before dereferencing it.
1583         (WebCore::Document::nodeWillBeRemoved): Ditto.
1584         (WebCore::Document::textInserted): Ditto.
1585         (WebCore::Document::textNodesMerged): Ditto.
1586         (WebCore::Document::textRemoved): Ditto.
1587
1588 2008-05-05  Brady Eidson  <beidson@apple.com>
1589
1590         Reviewed by Mitz Pettel RTL
1591
1592         Preparation for upcoming work making LocalStorage persistent.
1593
1594         The other half of the StorageMap::importItem() addition.
1595
1596         * storage/StorageArea.cpp:
1597         (WebCore::StorageArea::importItem):
1598         * storage/StorageArea.h:
1599
1600 2008-05-05  Brady Eidson  <beidson@apple.com>
1601
1602         Reviewed by Mitz Pettel RTL
1603
1604         Preparation for upcoming work making LocalStorage persistent.
1605
1606         - Create the LocalStorage object for a PageGroup the moment the first Page is added to it
1607           The Settings of the first Page define what persistent path the LocalStorage will use
1608         - Add a Frame argument for the LocalStorageArea request - this will allow a client object
1609           to be queried before the LocalStorageArea is established
1610
1611         * page/DOMWindow.cpp:
1612         (WebCore::DOMWindow::localStorage):
1613
1614         * page/PageGroup.cpp:
1615         (WebCore::PageGroup::addPage):
1616         (WebCore::PageGroup::localStorage):
1617
1618         * storage/LocalStorage.cpp:
1619         (WebCore::LocalStorage::LocalStorage): Take the path as a constructor argument.  Deep copy
1620           the path as it will be used from another thread.
1621         (WebCore::LocalStorage::storageArea):
1622         * storage/LocalStorage.h:
1623         (WebCore::LocalStorage::create):
1624
1625 2008-05-05  Brady Eidson  <beidson@apple.com>
1626
1627         Reviewed by Mitz Pettel RTL
1628
1629         Preparation for upcoming work making LocalStorage persistent.
1630
1631         StorageMaps normally have copy-on-write semantics to help support SessionStorage.
1632         For LocalStorage, we never want this behavior.  When we forcefully import items into 
1633         a StorageMap from the LocalStorage background thread, this new import method will be used.
1634
1635         * storage/StorageMap.cpp:
1636         (WebCore::StorageMap::importItem): Add a deep-copy of the item to the map without worrying
1637           about copy-on-write.
1638         * storage/StorageMap.h:
1639
1640 2008-05-05  Kevin McCullough  <kmccullough@apple.com>
1641
1642         Reviewed by Tim.
1643
1644         -<rdar://problem/5770054> JavaScript profiler (10928)
1645         -Begininings of a UI for the Profiler in the WebInspector.
1646
1647         * English.lproj/InspectorLocalizedStrings.js: Add new strings to be
1648         localized.
1649         * page/inspector/DatabasesPanel.js: Changed the name of the Databae's
1650         results table to be more generic as it is now also used by the profiler.
1651         * page/inspector/Images/glossySelected.png: Added.
1652         * page/inspector/Images/profilesIcon.png: Added.
1653         * page/inspector/Images/treeUpTriangleBlack.png: Added.
1654         * page/inspector/Images/treeUpTriangleWhite.png: Added.
1655         * page/inspector/ProfileView.js: Added. Sets up the header of the table.
1656         * page/inspector/ProfilesPanel.js: Added.
1657         * page/inspector/ProfilesPanel.js: Added. Sets up the containers of the
1658         profiler's content.
1659         * page/inspector/inspector.css: Change database-result-table to be more
1660         generic as well as add the styles needed by the profiler.
1661         * page/inspector/inspector.html: Add profiler support.
1662
1663 2008-05-05  Brady Eidson  <beidson@apple.com>
1664
1665         Change by Darin, reviewed by Brady
1666
1667         Small efficiency improvement Darin just spotted
1668
1669         * storage/StorageMap.cpp:
1670         (WebCore::StorageMap::setItem):
1671
1672 2008-05-05  Antti Koivisto  <antti@apple.com>
1673
1674         Reviewed by Anders.
1675
1676         Fix https://bugs.webkit.org/show_bug.cgi?id=18899
1677         Bug 18899: REGRESSION (r32871): Non-Safari crash in WTF::HashTable on startup
1678
1679         * loader/loader.cpp:
1680         (WebCore::Loader::Loader):
1681
1682 2008-05-05  Brady Eidson  <beidson@apple.com>
1683
1684         Reviewed by Sam Weinig
1685
1686         Fix a bug in StorageMap iterator tracking where the iterator was not successfully
1687         invalidated at an appropriate time.
1688
1689         * storage/StorageMap.cpp:
1690         (WebCore::StorageMap::setItem): ALWAYS invalidate it here
1691
1692 2008-05-05  Justin Garcia  <justin.garcia@apple.com>
1693
1694         Reviewed by Darin.
1695
1696         <rdar://problem/5865171> REGRESSION: Creating a new quote places caret at beginning of quote instead of the end
1697         
1698         Disable Range mutation on document modifications in Tiger and Leopard Mail,
1699         since they do their own mutation which interferes with ours.
1700
1701         * WebCore.base.exp:
1702         * dom/Document.cpp:
1703         (WebCore::Document::nodeChildrenChanged):
1704         (WebCore::Document::nodeWillBeRemoved):
1705         (WebCore::Document::textInserted):
1706         (WebCore::Document::textRemoved):
1707         (WebCore::Document::textNodesMerged):
1708         (WebCore::Document::textNodeSplit):
1709         * page/Settings.cpp:
1710         (WebCore::Settings::Settings):
1711         (WebCore::Settings::disableRangeMutationForOldAppleMail):
1712         * page/Settings.h:
1713         (WebCore::Settings::rangeMutationDisabledForOldAppleMail):
1714
1715 2008-05-05  Sam Weinig  <sam@webkit.org>
1716
1717         Reviewed by Tim Hatcher.
1718
1719         Make the Inspector's localizable strings file match the format used by Dashboard widgets.
1720
1721         * English.lproj/InspectorLocalizedStrings.js: Removed.
1722         * English.lproj/localizedStrings.js: Added.
1723         * WebCore.vcproj/WebCore.vcproj:
1724         * WebCore.xcodeproj/project.pbxproj:
1725         * page/inspector/inspector.js:
1726
1727 2008-05-05  Steve Falkenburg  <sfalken@apple.com>
1728
1729         Add support for default button appearance.
1730         Add WebCore setting for app chrome mode.
1731         
1732         Reviewed by Dave Hyatt.
1733
1734         * css/CSSPrimitiveValueMappings.h:
1735         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1736         * css/CSSValueKeywords.in: Added default-button value keyword.
1737         * page/Settings.cpp:
1738         (WebCore::Settings::Settings):
1739         (WebCore::Settings::setApplicationChromeMode):
1740         * page/Settings.h:
1741         (WebCore::Settings::inApplicationChromeMode):
1742         * rendering/RenderButton.cpp:
1743         (WebCore::RenderButton::RenderButton):
1744         (WebCore::RenderButton::setStyle):
1745         (WebCore::RenderButton::timerFired):
1746         * rendering/RenderButton.h:
1747         * rendering/RenderStyle.h:
1748         (WebCore::):
1749         * rendering/RenderTheme.cpp:
1750         (WebCore::RenderTheme::adjustStyle):
1751         (WebCore::RenderTheme::paint):
1752         (WebCore::RenderTheme::paintBorderOnly):
1753         (WebCore::RenderTheme::paintDecorations):
1754         (WebCore::RenderTheme::isControlStyled):
1755         (WebCore::RenderTheme::isDefault):
1756         * rendering/RenderTheme.h:
1757         (WebCore::):
1758         * rendering/RenderThemeSafari.cpp:
1759         (WebCore::RenderThemeSafari::determineState):
1760         (WebCore::RenderThemeSafari::adjustRepaintRect):
1761         (WebCore::RenderThemeSafari::adjustButtonStyle):
1762         * rendering/RenderThemeWin.cpp:
1763         (WebCore::RenderThemeWin::supportsFocus):
1764
1765 2008-05-05  Alexey Proskuryakov  <ap@webkit.org>
1766
1767         Reviewed by Darin.
1768
1769         https://bugs.webkit.org/show_bug.cgi?id=11947
1770         nbsps should be converted to entities in innerHTML
1771
1772         https://bugs.webkit.org/show_bug.cgi?id=18769
1773         replacing &nbsp; with spaces using regexp creates inconsistent result
1774
1775         Tests: fast/dom/innerHTML-nbsp.html
1776                fast/dom/innerHTML-escaping-attribute.html
1777
1778         * editing/markup.cpp:
1779         (WebCore::appendAttributeValue):
1780         (WebCore::escapeContentText):
1781         (WebCore::appendEscapedContent):
1782         Added U+00a0/nbsp to the list of characters to escape.
1783
1784 2008-05-05  David Hyatt  <hyatt@apple.com>
1785
1786         Fix for https://bugs.webkit.org/show_bug.cgi?id=18821.  Fix some bugs in both get/PutImageData of <canvas>.
1787
1788         Reviewed by Eric
1789
1790         New tests added in fast/canvas/
1791
1792         * platform/graphics/cg/ImageBufferCG.cpp:
1793         (WebCore::ImageBuffer::getImageData):
1794         (WebCore::ImageBuffer::putImageData):
1795
1796 2008-05-05  Dan Bernstein  <mitz@apple.com>
1797
1798         Reviewed by Dave Hyatt.
1799
1800         - fix https://bugs.webkit.org/show_bug.cgi?id=18809
1801           Forms with block level generated content and absolutely positioned labels break inline layout (fixed on reflow)
1802
1803         Test: fast/block/basic/adding-near-anonymous-block.html
1804
1805         * rendering/RenderBlock.cpp:
1806         (WebCore::RenderBlock::addChildToFlow): When adding a floating or
1807         positioned object, if it follows an anonymous block, put it
1808         inside the anonymous block. When adding an inline, check if it comes
1809         after an anonymous block and put it in the anonymous block.
1810
1811 2008-05-05  Antti Koivisto  <antti@apple.com>
1812
1813         Reviewed by Darin.
1814
1815         Speculative fix for <rdar://problem/5906790> 
1816         Crash in Loader::servePendingRequests() due to hash table being modified during iteration
1817         
1818         I don't know how to reproduce this. It would require the load to fail (or succeed)
1819         synchronously, something that should not usually happen.
1820
1821         * loader/loader.cpp:
1822         (WebCore::Loader::Loader):
1823         (WebCore::Loader::load):
1824         (WebCore::Loader::servePendingRequests):
1825         (WebCore::Loader::cancelRequests):
1826         (WebCore::Loader::Host::Host):
1827         * loader/loader.h:
1828         (WebCore::Loader::Host::name):
1829
1830 2008-05-05  Ariya Hidayat  <ariya.hidayat@trolltech.com>
1831
1832         Reviewed by Simon.
1833
1834         Disable SVG As Image support in the Qt port again, as it
1835         requires more work. Right now the chrome client is
1836         assumed to be a ChromeClientQt, which the SVG Image support
1837         changes.
1838
1839         * WebCore.pro:
1840
1841 2008-05-02  Antti Koivisto  <antti@apple.com>
1842
1843         Reviewed by Mitz.
1844
1845         Fix <rdar://problem/5840475>
1846         CrashTracer: [USER] 2 crashes in Safari at com.apple.WebCore: WebCore::RenderBlock::insertPositionedObject
1847         
1848         Non-block objects can have transforms so containingBlock() could end up returning null. 
1849         RenderObject::container() needs to match.
1850
1851         Test: fast/transforms/container-transform-crash.html
1852
1853         * rendering/RenderObject.cpp:
1854         (WebCore::RenderObject::containingBlock):
1855         (WebCore::RenderObject::container):
1856
1857 2008-05-04  Sam Weinig  <sam@webkit.org>
1858
1859         Roll out r32851.  It broke tiger builds.
1860
1861         * bindings/objc/DOMUtility.mm:
1862         (KJS::createDOMWrapper):
1863         (WebCore::createDOMWrapper):
1864
1865 2008-05-04  Dan Bernstein  <mitz@apple.com>
1866
1867         Reviewed by Sam Weinig.
1868
1869         - fix https://bugs.webkit.org/show_bug.cgi?id=18879
1870           <rdar://problem/5909481> Reproducible crash when removing a gradient
1871
1872         Test: fast/gradients/crash-on-remove.html
1873
1874         * css/CSSImageGeneratorValue.cpp:
1875         (WebCore::CSSImageGeneratorValue::CSSImageGeneratorValue):
1876         (WebCore::CSSImageGeneratorValue::addClient): Added a call to ref() the
1877         value.
1878         (WebCore::CSSImageGeneratorValue::removeClient): Added code to deref()
1879         the value.
1880
1881 2008-05-03  Sam Weinig  <sam@webkit.org>
1882
1883         Reviewed by Mark Rowe.
1884
1885         Move createDOMWrapper(JSObject* object) out of the KJS namespace and into
1886         the WebCore namespace now that the required compilers don't freak out about
1887         this anymore.
1888
1889         * bindings/objc/DOMUtility.mm:
1890         (WebCore::createDOMWrapper):
1891
1892 2008-05-03  Rob Buis  <buis@kde.org>
1893
1894         Reviewed by Sam.
1895
1896         https://bugs.webkit.org/show_bug.cgi?id=18652
1897         onchange events don't seem to fire for input[type=range] controls.
1898
1899         Fire changeEvent when clicking the slider outside the current
1900         thumb position.
1901
1902         * rendering/RenderSlider.cpp:
1903         (WebCore::RenderSlider::setValueForPosition):
1904
1905 2008-05-03  Sam Weinig  <sam@webkit.org>
1906
1907         Reviewed by Mark Rowe.
1908
1909         Remove unused enums from JSDOMWindowBase.
1910
1911         * bindings/js/JSDOMWindowBase.h:
1912         (WebCore::JSDOMWindowBase::):
1913
1914 2008-05-03  Sam Weinig  <sam@webkit.org>
1915
1916         Real build fix.
1917
1918         * WebCore.xcodeproj/project.pbxproj:
1919
1920 2008-05-03  Sam Weinig  <sam@webkit.org>
1921
1922         Build fix.
1923
1924         * bindings/js/kjs_events.cpp:
1925         (WebCore::JSAbstractEventListener::handleEvent):
1926
1927 2008-05-03  Sam Weinig  <sam@webkit.org>
1928
1929         Rubber-stamped by Geoffrey Garen.
1930
1931         Rename JSDOMWindowWrapper to JSDOMWindowShell.
1932
1933 2008-05-01  Rob Buis  <buis@kde.org>
1934
1935         Reviewed by Eric.
1936
1937         https://bugs.webkit.org/show_bug.cgi?id=18568
1938         background: currentColor fails
1939
1940         Implement currentColor from CSS3 color module.
1941
1942         Tests: fast/css/background-currentcolor.html
1943
1944         * css/CSSParser.cpp:
1945         (WebCore::CSSParser::parseValue):
1946         (WebCore::CSSParser::parseBackgroundColor):
1947         * css/CSSStyleSelector.cpp:
1948         (WebCore::CSSStyleSelector::getColorFromPrimitiveValue):
1949         * css/CSSValueKeywords.in:
1950         * css/SVGCSSValueKeywords.in:
1951
1952 2008-05-02  Anders Carlsson  <andersca@apple.com>
1953
1954         Reviewed by Mark.
1955
1956         Turns out calling locationInWindow on keyboard events will not throw an exception,
1957         but the point returned is completely bogus, so remove coordinates from the keyboard event struct.
1958         
1959         * bridge/npapi.h:
1960         (_NPCocoaEvent::):
1961
1962 2008-05-02  Benjamin Otte  <otte@gnome.org>
1963
1964         Reviewed by Alp Toker.
1965
1966         http://bugs.webkit.org/show_bug.cgi?id=18856
1967         [GTK] variable initialization missing
1968
1969         Not initializing the m_needsXEmbed variable could have very funny
1970         results. Most often those results would be crashes.
1971
1972         * plugins/PluginView.cpp:
1973         (WebCore::PluginView::PluginView):
1974
1975 2008-05-02  Jan Michael Alonzo  <jmalonzo@unpluggable.com>
1976
1977         Reviewed by Eric.
1978
1979         https://bugs.webkit.org/show_bug.cgi?id=18811
1980         Enable dashboard and offline web apps in autotools
1981
1982         * GNUmakefile.am:
1983
1984 2008-05-02  Anders Carlsson  <andersca@apple.com>
1985
1986         Reviewed by Sam.
1987
1988         Name the event union so it will work in plain C.
1989
1990         * bridge/npapi.h:
1991         (_NPCocoaEvent::):
1992
1993 2008-05-02  Dan Bernstein  <mitz@apple.com>
1994
1995         Reviewed by John Sullivan.
1996
1997         - render text shadows with zero offset, as the shadow can be seen behind
1998           the text if the text is translucent
1999
2000         Test: fast/text/shadow-no-blur.html
2001
2002         * platform/graphics/mac/FontMac.mm:
2003         (WebCore::Font::drawComplexText): Removed the isEmpty() condition on the
2004         shadow offset. Since isEmpty() is also true for sizes that have one or
2005         more non-positive components, this also ensures that subpixel
2006         antialiasing of the text is maintained with shadows in all directions.
2007         (WebCore::Font::drawGlyphs): Ditto.
2008         * platform/graphics/win/FontCGWin.cpp:
2009         (WebCore::Font::drawGlyphs): Ditto.
2010
2011 2008-05-02  Ariya Hidayat  <ariya.hidayat@trolltech.com>
2012
2013         Reviewed by Simon.
2014
2015         Build the Qt port with SVG Use and As Image support.
2016
2017         * WebCore.pro:
2018
2019 2008-05-02  Ariya Hidayat  <ariya.hidayat@trolltech.com>
2020
2021         Reviewed by Simon.
2022
2023         Fixed potential crash on SVG animation (added more checks to the assert).
2024
2025         * svg/SVGUseElement.cpp:
2026         (WebCore::SVGUseElement::associateInstancesWithShadowTreeElements):
2027
2028 2008-05-02  Alexey Proskuryakov  <ap@webkit.org>
2029
2030         Rubber-stamped by John Sullivan.
2031
2032         Fix a debug-only crash in layout tests.
2033
2034         * loader/CachedResource.cpp:
2035         (WebCore::CachedResource::~CachedResource): Don't call resourceForURL() for null URLs.
2036
2037 2008-05-02  Simon Hausmann  <shausman@trolltech.com>
2038
2039         Fix the Qt build on Windows when Phonon is enabled for Audio/Video support
2040
2041         * WebCore.pro: Don't use QT += phonon as it prepends the phonon
2042         includes to the include paths. Instead add it manually and make sure
2043         phonon comes last, to avoid the conflict of phonon's path.h with
2044         WebCore's Path.h on case-insensitive filesystems.
2045
2046 2008-05-02  Simon Hausmann  <hausmann@webkit.org>
2047
2048         Fix the Qt build. Add ExecState where necessary.
2049
2050         * bridge/qt/qt_class.cpp:
2051         (KJS::Bindings::QtClass::fallbackObject):
2052         * bridge/qt/qt_instance.cpp:
2053         (KJS::Bindings::QtRuntimeObjectImp::construct):
2054         (KJS::Bindings::QtInstance::getRuntimeObject):
2055         (KJS::Bindings::QtInstance::invokeDefaultMethod):
2056         (KJS::Bindings::QtInstance::defaultValue):
2057         (KJS::Bindings::QtInstance::stringValue):
2058         * bridge/qt/qt_instance.h:
2059         (KJS::Bindings::QtInstance::getObject):
2060         * bridge/qt/qt_runtime.cpp:
2061         (KJS::Bindings::convertValueToQVariant):
2062         (KJS::Bindings::convertQVariantToValue):
2063         (KJS::Bindings::QtRuntimeMetaMethod::lengthGetter):
2064         (KJS::Bindings::QtRuntimeMetaMethod::connectGetter):
2065         (KJS::Bindings::QtRuntimeMetaMethod::disconnectGetter):
2066         (KJS::Bindings::QtRuntimeConnectionMethod::lengthGetter):
2067         (KJS::Bindings::QtConnectionObject::execute):
2068         * bridge/runtime.cpp:
2069         (KJS::Bindings::Instance::createRuntimeObject):
2070
2071 2008-05-02  Simon Hausmann  <shausman@trolltech.com>
2072
2073         Fix the Qt/Win build.
2074
2075         * WebCore.pro:
2076         * platform/qt/TemporaryLinkStubs.cpp:
2077         (PluginDatabase::getPluginPathsInDirectories):
2078         (PluginDatabase::defaultPluginDirectories):
2079         (PluginDatabase::isPreferredPluginDirectory):
2080         (PluginView::setNPWindowRect):
2081         (PluginView::userAgent):
2082         (PluginView::invalidateRect):
2083         (PluginView::invalidateRegion):
2084         (PluginView::forceRedraw):
2085         (PluginView::setFocus):
2086         (PluginView::show):
2087         (PluginView::hide):
2088         (PluginView::paint):
2089         (PluginView::setParent):
2090         (PluginView::attachToWindow):
2091         (PluginView::detachFromWindow):
2092         (PluginView::updateWindow):
2093         (PluginView::handleKeyboardEvent):
2094         (PluginView::handleMouseEvent):
2095         (PluginView::handlePostReadFile):
2096         (PluginView::getValue):
2097         * plugins/qt/PluginPackageQt.cpp:
2098         (WebCore::PluginPackage::load):
2099
2100 2008-05-02  Alexey Proskuryakov  <ap@webkit.org>
2101
2102         Reviewed by Geoffrey Garen.
2103
2104         https://bugs.webkit.org/show_bug.cgi?id=18826
2105         Make JavaScript heap per-thread
2106
2107         This is mostly adaptation for JSC changes. The most prominent one is that JSObject
2108         allocator now takes ExecState, e.g. "new (exec) JSXMLHttpRequestConstructor(...)". It is
2109         OK to pass either the current or global one, whichever is faster to get hold of, as both
2110         have the same reference to a per-thread JS heap.
2111
2112         * bindings/scripts/CodeGeneratorJS.pm: Pass ExecState to functions that now need it.
2113         JSDOMWindow, JSDOMWindowPrototype and JSDOMWindowWrapper are special, because they are
2114         constructed before any ExecState comes into existence, so they use Heap::threadHeap()
2115         directly for allocation.
2116
2117         * bindings/js/JSDOMWindowWrapper.cpp:
2118         (WebCore::JSDOMWindowWrapper::operator new):
2119         * bindings/js/JSDOMWindowWrapper.h:
2120         Added a custom operator new to use per-thread heap when there's no ExecState around.
2121
2122         * bindings/js/JSAudioConstructor.cpp:
2123         (WebCore::JSAudioConstructor::JSAudioConstructor):
2124         * bindings/js/JSCSSRuleCustom.cpp:
2125         (WebCore::toJS):
2126         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
2127         (WebCore::JSCSSStyleDeclaration::nameGetter):
2128         * bindings/js/JSCSSValueCustom.cpp:
2129         (WebCore::toJS):
2130         * bindings/js/JSCanvasPixelArrayCustom.cpp:
2131         (WebCore::JSCanvasPixelArray::indexGetter):
2132         (WebCore::toJS):
2133         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2134         (WebCore::toJS):
2135         * bindings/js/JSClipboardCustom.cpp:
2136         (WebCore::JSClipboard::types):
2137         (WebCore::JSClipboard::getData):
2138         * bindings/js/JSCustomXPathNSResolver.cpp:
2139         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
2140         * bindings/js/JSDOMApplicationCacheCustom.cpp:
2141         (WebCore::JSDOMApplicationCache::addEventListener):
2142         (WebCore::JSDOMApplicationCache::removeEventListener):
2143         (WebCore::JSDOMApplicationCache::setOnchecking):
2144         (WebCore::JSDOMApplicationCache::setOnerror):
2145         (WebCore::JSDOMApplicationCache::setOnnoupdate):
2146         (WebCore::JSDOMApplicationCache::setOndownloading):
2147         (WebCore::JSDOMApplicationCache::setOnprogress):
2148         (WebCore::JSDOMApplicationCache::setOnupdateready):
2149         (WebCore::JSDOMApplicationCache::setOncached):
2150         * bindings/js/JSDOMWindowBase.cpp:
2151         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
2152         (WebCore::JSDOMWindowBase::getValueProperty):
2153         (WebCore::JSDOMWindowBase::setListener):
2154         (WebCore::JSDOMWindowBase::findOrCreateJSEventListener):
2155         (WebCore::JSDOMWindowBase::findJSUnprotectedEventListener):
2156         (WebCore::JSDOMWindowBase::findOrCreateJSUnprotectedEventListener):
2157         (WebCore::windowProtoFuncAToB):
2158         (WebCore::windowProtoFuncBToA):
2159         (WebCore::windowProtoFuncSetTimeout):
2160         (WebCore::windowProtoFuncSetInterval):
2161         (WebCore::windowProtoFuncAddEventListener):
2162         * bindings/js/JSDOMWindowBase.h:
2163         * bindings/js/JSDocumentCustom.cpp:
2164         (WebCore::toJS):
2165         * bindings/js/JSEventCustom.cpp:
2166         (WebCore::toJS):
2167         * bindings/js/JSEventTargetBase.cpp:
2168         (WebCore::jsEventTargetAddEventListener):
2169         * bindings/js/JSEventTargetBase.h:
2170         (WebCore::JSEventTargetPrototype::self):
2171         * bindings/js/JSEventTargetNode.cpp:
2172         (WebCore::JSEventTargetNode::setListener):
2173         * bindings/js/JSHTMLCollectionCustom.cpp:
2174         (WebCore::getNamedItems):
2175         (WebCore::toJS):
2176         * bindings/js/JSHTMLElementWrapperFactory.cpp:
2177         (WebCore::createJSHTMLWrapper):
2178         * bindings/js/JSHTMLFormElementCustom.cpp:
2179         (WebCore::JSHTMLFormElement::nameGetter):
2180         * bindings/js/JSHTMLInputElementBase.cpp:
2181         (WebCore::JSHTMLInputElementBase::getValueProperty):
2182         * bindings/js/JSHTMLOptionElementConstructor.cpp:
2183         (WebCore::JSHTMLOptionElementConstructor::JSHTMLOptionElementConstructor):
2184         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
2185         (WebCore::JSHTMLOptionsCollection::length):
2186         * bindings/js/JSInspectedObjectWrapper.cpp:
2187         (WebCore::JSInspectedObjectWrapper::wrap):
2188         * bindings/js/JSInspectorCallbackWrapper.cpp:
2189         (WebCore::JSInspectorCallbackWrapper::wrap):
2190         * bindings/js/JSLocationCustom.cpp:
2191         (WebCore::JSLocation::toString):
2192         * bindings/js/JSNamedNodesCollection.cpp:
2193         (WebCore::JSNamedNodesCollection::lengthGetter):
2194         * bindings/js/JSNavigatorCustom.cpp:
2195         (WebCore::JSNavigator::appVersion):
2196         * bindings/js/JSNodeCustom.cpp:
2197         (WebCore::toJS):
2198         * bindings/js/JSNodeFilterCustom.cpp:
2199         (WebCore::JSNodeFilter::acceptNode):
2200         * bindings/js/JSRGBColor.cpp:
2201         (WebCore::getJSRGBColor):
2202         * bindings/js/JSSQLResultSetRowListCustom.cpp:
2203         (WebCore::JSSQLResultSetRowList::item):
2204         * bindings/js/JSSVGElementWrapperFactory.cpp:
2205         (WebCore::createJSSVGWrapper):
2206         * bindings/js/JSSVGLazyEventListener.cpp:
2207         (WebCore::JSSVGLazyEventListener::eventParameterName):
2208         * bindings/js/JSStorageCustom.cpp:
2209         (WebCore::JSStorage::nameGetter):
2210         * bindings/js/JSStyleSheetCustom.cpp:
2211         (WebCore::toJS):
2212         * bindings/js/JSXMLHttpRequestConstructor.cpp:
2213         (WebCore::JSXMLHttpRequestConstructor::construct):
2214         * bindings/js/JSXMLHttpRequestCustom.cpp:
2215         (WebCore::JSXMLHttpRequest::setOnreadystatechange):
2216         (WebCore::JSXMLHttpRequest::setOnload):
2217         (WebCore::JSXMLHttpRequest::setOnprogress):
2218         (WebCore::JSXMLHttpRequest::getResponseHeader):
2219         (WebCore::JSXMLHttpRequest::addEventListener):
2220         (WebCore::JSXMLHttpRequest::removeEventListener):
2221         * bindings/js/JSXSLTProcessor.cpp:
2222         (WebCore::jsXSLTProcessorPrototypeFunctionGetParameter):
2223         (WebCore::JSXSLTProcessorConstructor::construct):
2224         * bindings/js/kjs_binding.cpp:
2225         (WebCore::jsStringOrNull):
2226         (WebCore::jsOwnedStringOrNull):
2227         (WebCore::jsStringOrUndefined):
2228         (WebCore::jsStringOrFalse):
2229         (WebCore::nonCachingStaticFunctionGetter):
2230         (WebCore::objectToStringFunctionGetter):
2231         * bindings/js/kjs_binding.h:
2232         (WebCore::DOMObject::DOMObject):
2233         (WebCore::cacheDOMObject):
2234         (WebCore::cacheSVGDOMObject):
2235         * bindings/js/kjs_events.cpp:
2236         (WebCore::JSLazyEventListener::eventParameterName):
2237         (WebCore::JSLazyEventListener::parseCode):
2238         * bindings/js/kjs_html.cpp:
2239         (WebCore::getRuntimeObject):
2240         * bridge/c/c_instance.cpp:
2241         (KJS::Bindings::CInstance::defaultValue):
2242         (KJS::Bindings::CInstance::stringValue):
2243         (KJS::Bindings::CInstance::numberValue):
2244         (KJS::Bindings::CInstance::valueOf):
2245         * bridge/c/c_instance.h:
2246         * bridge/c/c_utility.cpp:
2247         (KJS::Bindings::convertNPVariantToValue):
2248         * bridge/jni/jni_instance.cpp:
2249         (JavaInstance::stringValue):
2250         (JavaInstance::numberValue):
2251         (JavaInstance::invokeMethod):
2252         (JavaInstance::defaultValue):
2253         (JavaInstance::valueOf):
2254         * bridge/jni/jni_instance.h:
2255         * bridge/jni/jni_jsobject.h:
2256         * bridge/jni/jni_jsobject.mm:
2257         (JavaJSObject::call):
2258         (JavaJSObject::setMember):
2259         (JavaJSObject::setSlot):
2260         (JavaJSObject::convertJObjectToValue):
2261         (JavaJSObject::getListFromJArray):
2262         * bridge/jni/jni_objc.mm:
2263         (KJS::Bindings::dispatchJNICall):
2264         * bridge/jni/jni_runtime.cpp:
2265         (JavaArray::convertJObjectToArray):
2266         (JavaField::dispatchValueFromInstance):
2267         (JavaField::valueFromInstance):
2268         (JavaField::dispatchSetValueToInstance):
2269         (JavaArray::valueAt):
2270         * bridge/jni/jni_utility.h:
2271         * bridge/objc/objc_class.mm:
2272         (KJS::Bindings::ObjcClass::fallbackObject):
2273         * bridge/objc/objc_instance.h:
2274         * bridge/objc/objc_instance.mm:
2275         (ObjcInstance::defaultValue):
2276         (ObjcInstance::stringValue):
2277         (ObjcInstance::numberValue):
2278         (ObjcInstance::valueOf):
2279         * bridge/objc/objc_utility.h:
2280         * bridge/objc/objc_utility.mm:
2281         (KJS::Bindings::convertNSStringToString):
2282         (KJS::Bindings::convertObjcValueToValue):
2283         * bridge/runtime.cpp:
2284         (KJS::Bindings::Instance::createRuntimeObject):
2285         * bridge/runtime.h:
2286         (KJS::Bindings::Instance::valueOf):
2287         * bridge/runtime_array.cpp:
2288         (RuntimeArray::lengthGetter):
2289         * bridge/runtime_method.cpp:
2290         (RuntimeMethod::lengthGetter):
2291         * bridge/runtime_object.cpp:
2292         (RuntimeObjectImp::RuntimeObjectImp):
2293         (RuntimeObjectImp::methodGetter):
2294         (RuntimeObjectImp::defaultValue):
2295         * xml/XMLHttpRequest.cpp:
2296         (WebCore::XMLHttpRequest::dropProtection):
2297         * bindings/js/GCController.cpp:
2298         (WebCore::GCController::gcTimerFired):
2299         (WebCore::GCController::garbageCollectNow):
2300         Adapted to JSC changes. Pass ExecState to functions that now need it. Removed
2301         collectOnMainThreadOnly, as this is the only way to collect now. Replaced calls to static
2302         Collector methods with calls to per-thread Heap ones.
2303
2304 2008-05-02  Ariya Hidayat  <ariya.hidayat@trolltech.com>
2305
2306         Reviewed by Simon.
2307
2308         Build the Qt port with SVG Animation support.
2309
2310         * WebCore.pro:
2311
2312 2008-05-02  Simon Hausmann  <hausmann@webkit.org>
2313
2314         Build fix for Qt/Gtk. Don't declare NP_InitializeFuncPtr twice
2315         with different signatures.
2316
2317         * plugins/npfunctions.h:
2318
2319 2008-05-01  Robin Dunn  <robin@alldunn.com>
2320
2321         Reviewed by Kevin Ollivier.
2322
2323         Explicitly set the pen style in wx port to keep pen style changes from 
2324         affecting URL underline or text field drawing.
2325         
2326         https://bugs.webkit.org/show_bug.cgi?id=18775
2327
2328         * platform/graphics/wx/GraphicsContextWx.cpp:
2329         (WebCore::GraphicsContext::fillRect):
2330         (WebCore::GraphicsContext::drawLineForText):
2331         * platform/wx/RenderThemeWx.cpp:
2332         (WebCore::RenderThemeWx::paintTextField):
2333
2334 2008-05-01  Robin Dunn  <robin@alldunn.com>
2335
2336         Reviewed by Kevin Ollivier.
2337
2338         Implement popup menu support for wx port.
2339         
2340         https://bugs.webkit.org/show_bug.cgi?id=18776
2341
2342         * platform/PopupMenu.h:
2343         * platform/wx/PopupMenuWx.cpp: Added.
2344         (WebCore::PopupMenu::PopupMenu):
2345         (WebCore::PopupMenu::~PopupMenu):
2346         (WebCore::PopupMenu::show):
2347         (WebCore::PopupMenu::OnMenuItemSelected):
2348         (WebCore::PopupMenu::hide):
2349         (WebCore::PopupMenu::updateFromElement):
2350         (WebCore::PopupMenu::itemWritingDirectionIsNatural):
2351         * platform/wx/TemporaryLinkStubs.cpp:
2352         * webcore-wx.bkl:
2353
2354 2008-05-01  Kevin Ollivier  <kevino@theolliviers.com>
2355
2356         Reviewed by Eric Seidel.
2357
2358         Make sure we properly set the button for all mouse events,
2359         not just mouse down, set the click count to 0
2360         for non-click events, and finally set the timestamp.
2361         
2362         https://bugs.webkit.org/show_bug.cgi?id=18464
2363
2364         * platform/wx/MouseEventWx.cpp:
2365         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
2366
2367 2008-05-01  Sam Weinig  <sam@webkit.org>
2368
2369         Reviewed by Mark Rowe (in his infinite wisdom).
2370
2371         Auto-generate the JSXSLTProcessor binding.
2372
2373         * DerivedSources.make:
2374         * GNUmakefile.am:
2375         * WebCore.pro:
2376         * WebCore.vcproj/WebCore.vcproj:
2377         * WebCore.xcodeproj/project.pbxproj:
2378         * WebCoreSources.bkl:
2379         * bindings/js/JSDOMWindowBase.cpp:
2380         (WebCore::JSDOMWindowBase::getValueProperty):
2381         * bindings/js/JSDOMWindowBase.h:
2382         (WebCore::JSDOMWindowBase::):
2383         * bindings/js/JSXSLTProcessor.cpp: Removed.
2384         * bindings/js/JSXSLTProcessor.h: Removed.
2385         * xml/XSLTProcessor.h:
2386
2387 2008-05-01  Sam Weinig  <sam@webkit.org>
2388
2389         Reviewed by Geoffrey Garen.
2390
2391         Fixes:
2392           - https://bugs.webkit.org/show_bug.cgi?id=17249
2393             Incorrect lexical scope after navigation leads to UXSS
2394             <rdar://problem/5738497>
2395
2396           - https://bugs.webkit.org/show_bug.cgi?id=16824
2397             Script authorization should follow lexical (not dynamic) scope
2398             <rdar://problem/5683032>
2399
2400         This patch changes us to perform same-origin checks based on the lexical global object) 
2401         rather than dynamic global object, which is now possible we don't re-use the window on 
2402         navigations, but rather switch in a new one and re-use the outer shell.  This is both
2403         more secure and conforms with the HTML5 specification.  Now that all the checks are
2404         done based on the lexical global object, we can remove the SecurityOrigin::Reason
2405         concept, as it was only around to work around an ebay.com bug that required the check to
2406         be done that way.
2407
2408         An important thing to note is that we currently implement a stricter than necessary policy
2409         and perform the same-origin check based on the currently active global object to avoid leaking
2410         the document in cases when the target frame is navigated before access.  This will be fixed in
2411         an upcoming patch.
2412
2413         * bindings/js/JSDOMWindowBase.cpp:
2414         (WebCore::JSDOMWindowBase::allowsAccessFrom):
2415         (WebCore::JSDOMWindowBase::allowsAccessFromNoErrorMessage):
2416         (WebCore::JSDOMWindowBase::allowsAccessFromPrivate):
2417         (WebCore::JSDOMWindowBase::crossDomainAccessErrorMessage):
2418         (WebCore::JSDOMWindowBase::printErrorMessage):
2419         (WebCore::asJSDOMWindow):
2420         * bindings/js/JSDOMWindowBase.h:
2421         * html/CanvasRenderingContext2D.cpp:
2422         (WebCore::CanvasRenderingContext2D::checkOrigin):
2423         (WebCore::CanvasRenderingContext2D::createPattern):
2424         * loader/FrameLoader.cpp:
2425         (WebCore::FrameLoader::begin):
2426         (WebCore::FrameLoader::write):
2427         (WebCore::FrameLoader::setOpener):
2428         (WebCore::FrameLoader::shouldAllowNavigation):
2429         * page/DOMWindow.h:
2430         (WebCore::DOMWindow::setSecurityOrigin):
2431         (WebCore::DOMWindow::securityOrigin):
2432         (WebCore::DOMWindow::setURL):
2433         (WebCore::DOMWindow::url):
2434         * platform/SecurityOrigin.cpp:
2435         (WebCore::SecurityOrigin::canAccess):
2436         (WebCore::SecurityOrigin::isSecureTransitionTo):
2437         * platform/SecurityOrigin.h:
2438
2439 2008-05-01  Anders Carlsson  <andersca@apple.com>
2440
2441         Reviewed by Mark.
2442
2443         Enable 64-bit NPAPI plugins.
2444         
2445         * WebCore.xcodeproj/project.pbxproj:
2446         Don't remove NPAPI related symbols from the 64-bit .exp file.
2447         
2448         * bridge/npruntime.h:
2449         Remove now unnecessary #error.
2450
2451 2008-05-01  Maciej Stachowiak  <mjs@apple.com>
2452
2453         Reviewed by Oliver (a while ago)
2454
2455         - just a wee bit more bindings speedup
2456         
2457         Store the per-document Node --> JS wrapper cache in the document
2458         instead of an external hashtable.
2459
2460         * bindings/js/kjs_binding.cpp:
2461         (WebCore::ScriptInterpreter::getDOMNodeForDocument):
2462         (WebCore::ScriptInterpreter::forgetDOMNodeForDocument):
2463         (WebCore::ScriptInterpreter::putDOMNodeForDocument):
2464         (WebCore::ScriptInterpreter::forgetAllDOMNodesForDocument):
2465         (WebCore::ScriptInterpreter::markDOMNodesForDocument):
2466         * dom/Document.h:
2467         (WebCore::Document::wrapperCache):
2468
2469 2008-05-01  Anders Carlsson  <andersca@apple.com>
2470
2471         Reviewed by Tim.
2472
2473         Remove duplicate npfunctions.h header from WebKit.
2474         
2475         * WebCore.xcodeproj/project.pbxproj:
2476         Add npfunctions.h and set its role to private.
2477         
2478         * plugins/npfunctions.h:
2479         Merge Mac specific changes.
2480
2481 2008-05-01  Sam Weinig  <sam@webkit.org>
2482
2483         Reviewed by Geoffrey Garen.
2484
2485         Rename toJSDOMWindow(KJS::JSGlobalObject) to asJSDOMWindow, as all it does is
2486         cast.
2487
2488         * bindings/js/JSCustomVoidCallback.cpp:
2489         (WebCore::toVoidCallback):
2490         * bindings/js/JSCustomXPathNSResolver.cpp:
2491         (WebCore::JSCustomXPathNSResolver::create):
2492         * bindings/js/JSDOMApplicationCacheCustom.cpp:
2493         (WebCore::JSDOMApplicationCache::add):
2494         (WebCore::JSDOMApplicationCache::remove):
2495         * bindings/js/JSDOMWindowBase.cpp:
2496         (WebCore::allowPopUp):
2497         (WebCore::createWindow):
2498         (WebCore::windowProtoFuncOpen):
2499         (WebCore::asJSDOMWindow):
2500         * bindings/js/JSDOMWindowBase.h:
2501         * bindings/js/JSDOMWindowCustom.cpp:
2502         (WebCore::JSDOMWindow::setLocation):
2503         (WebCore::JSDOMWindow::postMessage):
2504         * bindings/js/JSDatabaseCustom.cpp:
2505         (WebCore::JSDatabase::changeVersion):
2506         (WebCore::JSDatabase::transaction):
2507         * bindings/js/JSDocumentCustom.cpp:
2508         (WebCore::JSDocument::setLocation):
2509         * bindings/js/JSLocationCustom.cpp:
2510         (WebCore::navigateIfAllowed):
2511         (WebCore::JSLocation::setHref):
2512         (WebCore::JSLocation::replace):
2513         (WebCore::JSLocation::reload):
2514         (WebCore::JSLocation::assign):
2515         * bindings/js/JSSQLTransactionCustom.cpp:
2516         (WebCore::JSSQLTransaction::executeSql):
2517         * bindings/js/JSXMLHttpRequestCustom.cpp:
2518         (WebCore::JSXMLHttpRequest::open):
2519         * page/JavaScriptDebugServer.cpp:
2520         (WebCore::toPage):
2521
2522 2008-05-01  Anatoli Papirovski  <apapirovski@mac.com>
2523
2524         Reviewed by Dave Hyatt.
2525
2526         - fix https://bugs.webkit.org/show_bug.cgi?id=18347
2527           Absolutely positioned image percentage width does not respect container's padding
2528
2529         Test: fast/replaced/absolute-position-percentage-width.html
2530
2531         * rendering/RenderBox.cpp:
2532         (WebCore::RenderBox::calcReplacedWidthUsing):
2533
2534 2008-05-01  Dan Bernstein  <mitz@apple.com>
2535
2536         - Windows build fix
2537
2538         * platform/graphics/win/FontCGWin.cpp:
2539         (WebCore::Font::drawGlyphs):
2540
2541 2008-05-01  Dan Bernstein  <mitz@apple.com>
2542
2543         Reviewed by Darin Adler.
2544
2545         - make synthetic bold and synthetic italics work in GDI text
2546         - account for synthetic bold in complex text on Windows
2547
2548         * platform/graphics/win/FontCGWin.cpp:
2549         (WebCore::Font::drawGlyphs): Adjusted the text rectangle's x coordinates
2550         to fit italics. Added a skew transform for synthetic italics and a
2551         second paint pass for synthetic bold.
2552         * platform/graphics/win/SimpleFontDataWin.cpp:
2553         (WebCore::SimpleFontData::widthForGDIGlyph): Added the synthetic bold
2554         offset.
2555         * platform/graphics/win/UniscribeController.cpp:
2556         (WebCore::UniscribeController::shapeAndPlaceItem): Added the synthetic
2557         bold offset.
2558
2559 2008-05-01  Alp Toker  <alp@nuanti.com>
2560
2561         Qt/Win build fix attempt following plugin changes. Add missing return
2562         statements.
2563
2564         Also fixes some newly introduced coding style issues in the Qt port.
2565
2566         * platform/qt/FileSystemQt.cpp:
2567         (WebCore::openTemporaryFile):
2568         (WebCore::closeFile):
2569         (WebCore::writeToFile):
2570         (WebCore::unloadModule):
2571
2572 2008-05-01  Anders Carlsson  <andersca@apple.com>
2573
2574         Reviewed by Adam.
2575
2576         Export methods needed to subclass Widget.  (See r32770.)
2577
2578         * WebCore.base.exp:
2579
2580 2008-05-01  Marc Ordinas i Llopis  <marc.ordinasillopis@collabora.co.uk>
2581
2582         Reviewed by Alp Toker.
2583         Qt parts OK'ed by Simon Hausmann.
2584
2585         https://bugs.webkit.org/show_bug.cgi?id=14750
2586         Added support for NPAPI plugins on Gtk and Qt-x11 ports.
2587
2588         * GNUmakefile.am: Added Gtk plugin files.
2589         * WebCore.pro: Added Qt plugins files, defined XP_UNIX and
2590         ENABLE_NETSCAPE_PLUGIN_API
2591         * bridge/npruntime_internal.h: Additional undefs that conflict
2592         with Qt headers.
2593         * page/gtk/FrameGtk.cpp: Create js bindings for PluginView.
2594         (WebCore::Frame::createScriptInstanceForWidget):
2595         * page/qt/FrameQt.cpp: Create js bindings for PluginView.
2596         (WebCore::Frame::createScriptInstanceForWidget):
2597         (WebCore::Frame::clearPlatformScriptObjects):
2598         (WebCore::Frame::disconnectPlatformScriptObjects):
2599         * platform/FileSystem.h: Qt FileSystem implementation.
2600         * platform/Widget.h: Members to differentiate between Qt plugins and
2601         NPAPI ones.
2602         * platform/gtk/ScrollViewGtk.cpp:
2603         (WebCore::ScrollView::addChild): Set containing window before calling setParent.
2604         * platform/gtk/TemporaryLinkStubs.cpp: Removed implemented functions.
2605         (PluginView::invalidateRegion):
2606         * platform/qt/FileSystemQt.cpp: Implemented functions necessary for
2607         NPAPI plugins.
2608         (WebCore::openTemporaryFile):
2609         (WebCore::closeFile):
2610         (WebCore::writeToFile):
2611         (WebCore::unloadModule): Delete module if unloaded.
2612         * platform/qt/TemporaryLinkStubs.cpp: Removed implemented functions.
2613         * platform/qt/WidgetQt.cpp: Differentiate between Qt plugins and
2614         NPAPI ones.
2615         (WebCore::WidgetPrivate::WidgetPrivate):
2616         (WebCore::Widget::isNPAPIPlugin):
2617         (WebCore::Widget::setIsNPAPIPlugin):
2618         * plugins/PluginPackage.cpp:
2619         (WebCore::PluginPackage::~PluginPackage): Unload the module before
2620         destruction.
2621         (WebCore::PluginPackage::compare): Moved here as it's platform
2622         independent.
2623         * plugins/PluginView.cpp: Moved platform-independent functions here.
2624         (WebCore::PluginView::PluginView): Initialize m_npWindow.ws_info on
2625         Unix platforms.
2626         (WebCore::PluginView::freeStringArray):
2627         (WebCore::startsWithBlankLine):
2628         (WebCore::locationAfterFirstBlankLine):
2629         (WebCore::findEOL):
2630         (WebCore::capitalizeRFC822HeaderFieldName):
2631         (WebCore::parseRFC822HeaderFields):
2632         (WebCore::PluginView::handlePost):
2633         * plugins/PluginView.h: Moved platform-independent functions here.
2634         Added member to signal plugin needs XEmbed extension.
2635         * plugins/gtk/PluginDataGtk.cpp: Added.
2636         (WebCore::PluginData::initPlugins):
2637         (WebCore::PluginData::refresh):
2638         * plugins/gtk/PluginDatabaseGtk.cpp:
2639         (WebCore::PluginDatabase::defaultPluginDirectories):
2640         (WebCore::PluginDatabase::isPreferredPluginDirectory):
2641         * plugins/gtk/PluginPackageGtk.cpp: Added.
2642         (WebCore::PluginPackage::determineQuirks):
2643         (WebCore::PluginPackage::fetchInfo):
2644         (WebCore::PluginPackage::load):
2645         (WebCore::PluginPackage::hash):
2646         (WebCore::PluginPackage::equal):
2647         (WebCore::PluginPackage::compareFileVersion):
2648         * plugins/gtk/PluginViewGtk.cpp: Added.
2649         (WebCore::PluginView::updateWindow):
2650         (WebCore::PluginView::setFocus):
2651         (WebCore::PluginView::show):
2652         (WebCore::PluginView::hide):
2653         (WebCore::PluginView::paint):
2654         (WebCore::PluginView::handleKeyboardEvent):
2655         (WebCore::PluginView::handleMouseEvent):
2656         (WebCore::PluginView::setParent):
2657         (WebCore::PluginView::setNPWindowRect):
2658         (WebCore::PluginView::attachToWindow):
2659         (WebCore::PluginView::detachFromWindow):
2660         (WebCore::PluginView::stop):
2661         (WebCore::PluginView::userAgent):
2662         (WebCore::PluginView::handlePostReadFile):
2663         (WebCore::PluginView::getValue):
2664         (WebCore::PluginView::invalidateRect):
2665         (WebCore::PluginView::forceRedraw):
2666         (WebCore::PluginView::~PluginView):
2667         (WebCore::plug_removed_cb): Added callback to handle plug removal.
2668         (WebCore::PluginView::init):
2669         * plugins/gtk/xembed.h: Added.
2670         * plugins/npapi.cpp:
2671         (NPN_GetValue): Return error if no view present.
2672         * plugins/qt/PluginDataQt.cpp:
2673         (WebCore::PluginData::initPlugins):
2674         (WebCore::PluginData::refresh):
2675         * plugins/qt/PluginDatabaseQt.cpp: Added.
2676         (WebCore::PluginDatabase::getPluginPathsInDirectories):
2677         (WebCore::addQtWebKitPluginDirectories):
2678         (WebCore::addMozillaPluginDirectories):
2679         (WebCore::PluginDatabase::defaultPluginDirectories):
2680         (WebCore::PluginDatabase::isPreferredPluginDirectory):
2681         * plugins/qt/PluginPackageQt.cpp: Added.
2682         (WebCore::PluginPackage::determineQuirks):
2683         (WebCore::PluginPackage::fetchInfo):
2684         (WebCore::PluginPackage::load):
2685         (WebCore::PluginPackage::hash):
2686         (WebCore::PluginPackage::equal):
2687         (WebCore::PluginPackage::compareFileVersion):
2688         * plugins/qt/PluginViewQt.cpp: Added.
2689         (WebCore::PluginView::updateWindow):
2690         (WebCore::PluginView::setFocus):
2691         (WebCore::PluginView::show):
2692         (WebCore::PluginView::hide):
2693         (WebCore::PluginView::paint):
2694         (WebCore::PluginView::handleKeyboardEvent):
2695         (WebCore::PluginView::handleMouseEvent):
2696         (WebCore::PluginView::setParent):
2697         (WebCore::PluginView::setNPWindowRect):
2698         (WebCore::PluginView::attachToWindow):
2699         (WebCore::PluginView::detachFromWindow):
2700         (WebCore::PluginView::stop):
2701         (WebCore::PluginView::userAgent):
2702         (WebCore::PluginView::handlePostReadFile):
2703         (WebCore::PluginView::getValue):
2704         (WebCore::PluginView::invalidateRect):
2705         (WebCore::PluginView::invalidateRegion):
2706         (WebCore::PluginView::forceRedraw):
2707         (WebCore::PluginView::~PluginView):
2708         (WebCore::PluginView::init):
2709         * plugins/win/PluginPackageWin.cpp: Moved platform-independent code
2710         to plugins/PluginPackage.cpp
2711         * plugins/win/PluginViewWin.cpp: Moved platform-independent code to
2712         plugins/PluginView.cpp
2713         (WebCore::PluginView::stop):
2714         (WebCore::PluginView::handlePostReadFile):
2715         (WebCore::PluginView::getValue): Moved this function to each platform.
2716
2717 2008-05-01  Sam Weinig  <sam@webkit.org>
2718
2719         Fix build.
2720
2721         * ForwardingHeaders/wtf/StrHash.h: Added.
2722
2723 2008-05-01  Anders Carlsson  <andersca@apple.com>
2724
2725         Reviewed by Darin.
2726
2727         Move management of cache groups to ApplicationCacheStorage. Also,
2728         application caches now start out with a null group and will have their group set
2729         when the cache has finished loading. 
2730
2731         * loader/appcache/ApplicationCache.cpp:
2732         (WebCore::ApplicationCache::ApplicationCache):
2733         Initialize m_group to 0.
2734         
2735         (WebCore::ApplicationCache::~ApplicationCache):
2736         Null check the group.
2737         
2738         (WebCore::ApplicationCache::setGroup):
2739         New method for setting the group.
2740         
2741         * loader/appcache/ApplicationCache.h:        
2742         (WebCore::ApplicationCache::create):
2743         Remove the group argument.
2744         
2745         * loader/appcache/ApplicationCacheGroup.cpp:
2746         (WebCore::ApplicationCacheGroup::~ApplicationCacheGroup):
2747         Let the storage know that the cache group has been destroyed.
2748         
2749         (WebCore::ApplicationCacheGroup::cacheForMainRequest):
2750         Call into the storage.
2751         
2752         (WebCore::ApplicationCacheGroup::selectCache):
2753         Call into the storage.
2754         
2755         (WebCore::ApplicationCacheGroup::documentLoaderDestroyed):
2756         When there are no document loaders associated with the cache group,
2757         set the newest cache to 0.
2758         
2759         (WebCore::ApplicationCacheGroup::cacheDestroyed):
2760         Delete the group if there are no associated caches.
2761         
2762         (WebCore::ApplicationCacheGroup::setNewestCache):
2763         New method that will set the newest cache and associate the group with the cache.
2764         
2765         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
2766         Call setNewestCache instead.
2767         
2768         * loader/appcache/ApplicationCacheStorage.cpp:
2769         (WebCore::urlHostHash):
2770         Move host hash method here.
2771         
2772         (WebCore::ApplicationCacheStorage::findOrCreateCacheGroup):
2773         New method that finds a cache group with a given manifest URL or creates a new one.
2774
2775         (WebCore::ApplicationCacheStorage::cacheGroupForURL):
2776         New method that returns a cache group for a given URL.
2777         
2778         (WebCore::ApplicationCacheStorage::cacheGroupDestroyed):
2779         When the cache group has been destroyed, remove it from the hash map.
2780         
2781         * loader/appcache/ApplicationCacheStorage.h:
2782         Add new methods.I b
2783
2784 2008-05-01  Dan Winship  <danw@gnome.org>
2785
2786         Reviewed by Alp Toker.
2787
2788         http://bugs.webkit.org/show_bug.cgi?id=18490
2789         Add mostly-working file: support and mostly-broken ftp: support to
2790         the soup backend.
2791
2792         * platform/network/soup/ResourceHandleSoup.cpp (start): after
2793         doing basic checks, delegate to one of three submethods
2794         (startData): handles data: URLs
2795         (startHttp): handles http: and https: URLs, via libsoup
2796         (startGio, etc): handles file: and ftp: URLs, via gio. Lots of
2797         FIXMEs detailing the parts that don't fully work yet.
2798
2799         * platform/network/ResourceHandle.h:
2800         * platform/network/ResourceHandleInternal.h: add new member
2801         variables for gio-based loading
2802
2803 2008-05-01  Alp Toker  <alp@nuanti.com>
2804
2805         Rubber-stamped by Anders.
2806
2807         GTK+ build fix for changes in r32752. Use int32, not int32_t types in
2808         npapi.h.
2809
2810         Additional fix to use same signedness in npapi.h and Mac for the
2811         interval parameter.
2812
2813         * bridge/npapi.h:
2814
2815 2008-04-30  Anders Carlsson  <andersca@apple.com>
2816
2817         Reviewed by Adam.
2818
2819         Add new Cocoa event model type declarations.
2820         
2821         * bridge/npapi.h:
2822
2823 2008-04-30  Beth Dakin  <bdakin@apple.com>
2824
2825         Reviewed by Sam Weinig.
2826
2827         This patch does three things:
2828         1. Adds support for the "img" ARIA role
2829         2. Switches over to a HashMap for converting ARIA role attributes 
2830         to WebCore's AccessibilityRole type. 
2831         3. Fixes a crash in the new ARIA code that I ran into while 
2832         browsing with VoiceOver enabled.
2833
2834         * page/AccessibilityObject.cpp:
2835         (WebCore::AccessibilityObject::headingLevel): This is the crash 
2836         fix. Make sure the node's renderer is not null before looking up 
2837         its corresponding AccessibilityObject in the cache.
2838         (WebCore::AccessibilityObject::accessibilityIsIgnored): Account for 
2839         ARIA images.
2840         (WebCore::createARIARoleMap): Switch to HashMap, and add "img" to 
2841         the Map.
2842         (WebCore::RoleEntry::): Same.
2843         (WebCore::ariaRoleToWebCoreRole): Same.
2844         (WebCore::AccessibilityObject::ariaRoleAttribute): Same.
2845
2846 2008-04-30  Rob Buis  <buis@kde.org>
2847
2848         Reviewed by Nikolas.
2849
2850         https://bugs.webkit.org/show_bug.cgi?id=16447
2851         onload called too many times for <svg:image>
2852         https://bugs.webkit.org/show_bug.cgi?id=12282
2853         SVG wastes time in malloc to send loadEvents to non-existent listeners
2854
2855         Postpone load event dispatching for image when externalResourcesRequired
2856         is true, delaying parents but not siblings, and make sure the load event
2857         is sent once for image in all cases.
2858
2859         * svg/SVGElement.cpp:
2860         (WebCore::hasLoadListener):
2861         (WebCore::SVGElement::sendSVGLoadEventIfPossible):
2862         * svg/SVGImageElement.cpp:
2863         (WebCore::SVGImageElement::haveLoadedRequiredResources):
2864         * svg/SVGImageLoader.cpp:
2865         (WebCore::SVGImageLoader::dispatchLoadEvent):
2866
2867 2008-04-30  David Hyatt  <hyatt@apple.com>
2868
2869         Fix crashes when dynamically removing <video> elements with layers that establish stacking contexts.  This
2870         won't typically crash release builds because of arena recycling.
2871
2872         Reviewed by Dan Bernstein
2873         
2874         * rendering/RenderLayer.cpp:
2875         (WebCore::RenderLayer::~RenderLayer):
2876         Make sure to remove the reflection's child layer from its parent.
2877
2878         * rendering/RenderMedia.cpp:
2879         (WebCore::RenderMedia::~RenderMedia):
2880         (WebCore::RenderMedia::destroy):
2881         (WebCore::RenderMedia::removeChild):
2882         * rendering/RenderMedia.h:
2883         Adjust the teardown of RenderMedia so that it does all of its teardown inside destroy() (this makes it more
2884         like other renderers and doesn't leave you staring at a trashed layer hierarchy in the RenderMedia
2885         destructor).
2886
2887 2008-04-30  Rémi Zara  <remi_zara@mac.com>
2888
2889         Reviewed by Dave Hyatt.
2890
2891         fix https://bugs.webkit.org/show_bug.cgi?id=18618
2892         <rdar://problem/5876063> REGRESSION (r31823-r31847): Patterns are upside down
2893
2894         * svg/graphics/cg/SVGPaintServerPatternCg.cpp:
2895         (WebCore::patternCallback): flip the y axis when drawing the tile
2896
2897 2008-04-30  Timothy Hatcher  <timothy@apple.com>
2898
2899         Fixes an undefined type exception that fires when adding a resource to the inspector
2900         that has a MIME type warning.
2901
2902         Reviewed by Adam Roben.
2903
2904         * page/inspector/Resource.js:
2905         (WebInspector.Resource.prototype._addTip): Call WebInspector.console instead of
2906         WebInspector.consolePanel.
2907         (WebInspector.Resource.prototype._checkWarning): Ditto.
2908
2909 2008-04-30  Timothy Hatcher  <timothy@apple.com>
2910
2911         Fixes the bug where the selected resource would be deselected after
2912         changing the sort order in the Resources panel.
2913
2914         Reviewed by Dan Bernstein.
2915
2916         * page/inspector/ResourcesPanel.js:
2917         (WebInspector.ResourcesPanel.prototype._sortResourcesIfNeeded):
2918         Rememebr if the tree element that we are sorting was selected, so
2919         the selection can be restored after it is re-inserted. The onSelect
2920         is suppressed since we don't need to show the resource again.
2921
2922 2008-04-29  Timothy Hatcher  <timothy@apple.com>
2923
2924         Fixes the regression where error bubbles in source views always show
2925         "undefined" for the content because the message property on
2926         ConsoleMessage was removed. Adds support for a plain text formated
2927         message that is stored in the message proeprty.
2928
2929         Reviewed by Adam Roben.
2930
2931         * page/inspector/Console.js:
2932         (WebInspector.Console.prototype._format): Add a plainText argument that is passed to
2933         the formatters.
2934         (WebInspector.Console.prototype._formatvalue): Add a plainText argument, and a comment
2935         about needing to honor it if the textContent of the output doesn't make sense.
2936         (WebInspector.Console.prototype._formatvalue): Ditto.
2937         (WebInspector.Console.prototype._formatstring): Ditto.
2938         (WebInspector.Console.prototype._formatregexp): Ditto.
2939         (WebInspector.Console.prototype._formatarray): Ditto.
2940         (WebInspector.Console.prototype._formatnode): Ditto.
2941         (WebInspector.Console.prototype._formatobject): Ditto.
2942         (WebInspector.Console.prototype._formaterror): Ditto.
2943         (WebInspector.ConsoleMessage): Call _format passing true for plainText. Get the 
2944         textContnet of the result and assign to the message proeprty. This property is 
2945         referenced from the SourceView.
2946         (WebInspector.ConsoleMessage.prototype._format): Add a plainText argument. Build the 
2947         result element as a local and return it, instead of using formatedMessage directly.
2948
2949 2008-04-30  Timothy Hatcher  <timothy@apple.com>
2950
2951         Adds a helper function to convert a JSValueRef to a String.
2952
2953         Reviewed by Adam Roben.
2954
2955         * page/InspectorController.cpp:
2956         (WebCore::toString): Converts a JSValueRef to a String.
2957         (WebCore::search): Use toString.
2958         (WebCore::InspectorController::handleException): Ditto.
2959
2960 2008-04-30  Ariya Hidayat  <ariya.hidayat@trolltech.com>
2961
2962         Reviewed by Simon.
2963         
2964         Build the Qt port with SVG Foreign Object support.
2965
2966         * WebCore.pro:
2967
2968 2008-04-30  Simon Hausmann  <hausmann@webkit.org>
2969
2970         Reviewed by Holger.
2971
2972         Fix null pointer deference triggered by
2973         LayoutTests/fast/loader/cancel-load-during-port-block-timer.html
2974
2975         * platform/network/qt/ResourceHandleQt.cpp:
2976         (WebCore::ResourceHandle::cancel): Check m_job before dereferencing.
2977
2978 2008-04-29  David Hyatt  <hyatt@apple.com>
2979
2980         Improve the performance of masks by adding code to set more precise clips on the transparency layers
2981         used to paint the content under the mask, and then also avoid creating transparency layers for the masks
2982         themselves in common cases.
2983
2984         Reviewed by Dan Bernstein
2985
2986         * platform/graphics/GraphicsContext.cpp:
2987         (WebCore::GraphicsContext::drawTiledImage):
2988         Fix a bug in drawTiledImage where the composite mode got lost in the double stretch case for nine piece
2989         images.
2990
2991         * rendering/InlineFlowBox.cpp:
2992         (WebCore::InlineFlowBox::paintFillLayers):
2993         (WebCore::InlineFlowBox::paintFillLayer):
2994         (WebCore::InlineFlowBox::paintMask):
2995         Optimize to only push a transparency layer for the mask if multiple images are combining.  Add a new
2996         composite operator argument for use when painting fill layers to do direct destination-in compositing while
2997         painting images.
2998
2999
3000         * rendering/InlineFlowBox.h:
3001         * rendering/RenderBox.cpp:
3002         (WebCore::RenderBox::paintMask):
3003         (WebCore::RenderBox::paintMaskImages):
3004         Optimize to only push a transparency layer for the mask if multiple images are combining.
3005
3006         (WebCore::RenderBox::maskClipRect):
3007         A new method that attempts to compute a precise clip rect for the mask images.
3008
3009         (WebCore::RenderBox::paintFillLayers):
3010         (WebCore::RenderBox::paintFillLayer):
3011         (WebCore::RenderBox::paintFillLayerExtended):
3012         * rendering/RenderBox.h:
3013         Added the composite operator argument to the paintFillLayer methods.
3014
3015         * rendering/RenderFieldset.cpp:
3016         (WebCore::RenderFieldset::paintMask):
3017         Call the new base class paintMaskImages method for optimized mask painting.
3018
3019         * rendering/RenderLayer.cpp:
3020         (WebCore::transparencyClipBox):
3021         Fix a coordinate space issue with transparencyClipBox when masks were used.  The border box was in the
3022         wrong coordinate space.  Moved the code into the layer's boundingBox() method instead.
3023
3024         (WebCore::RenderLayer::paintLayer):
3025         Removed the code that always pushed a transparency layer before painting masks.
3026
3027         (WebCore::RenderLayer::boundingBox):
3028         Call maskClipRect to shrink the bounding box of the layer to fit the mask clip.
3029
3030         * rendering/RenderObject.cpp:
3031         (WebCore::RenderObject::paintNinePieceImage):
3032         Added a composite operator argument for direct destination-in painting of nine piece images.
3033
3034         * rendering/RenderObject.h:
3035         (WebCore::RenderObject::maskClipRect):
3036         (WebCore::RenderObject::paintFillLayerExtended):
3037         Base class stubs for RenderBox-implemented methods.
3038
3039         * rendering/RenderTable.cpp:
3040         (WebCore::RenderTable::paintMask):
3041         * rendering/RenderTableCell.cpp:
3042         (WebCore::RenderTableCell::paintMask):
3043         Modified to call the new paintMaskImages function.
3044
3045         * svg/graphics/SVGImage.cpp:
3046         (WebCore::SVGImage::draw):
3047         SVG images now respect composite modes by pushing a transparency layer when the composite mode
3048         is anything other than source-over.
3049
3050 2008-04-30  Ariya Hidayat  <ariya.hidayat@trolltech.com>
3051
3052         Rubber-stamped by Rob Buis.
3053
3054         Fixed crash or assertion if SVG_FOREIGN_OBJECT is not enabled
3055
3056         * svg/SVGUseElement.cpp:
3057         (WebCore::SVGUseElement::associateInstancesWithShadowTreeElements):
3058
3059 2008-04-30  Ariya Hidayat  <ariya.hidayat@trolltech.com>
3060
3061         Rubber-stamped by Rob Buis.
3062
3063         Fixed compile, due to API change in XMLSerializer
3064
3065         * svg/SVGUseElement.cpp:
3066         (WebCore::SVGUseElement::buildPendingResource):
3067
3068 2008-04-30  Rob Buis  <buis@kde.org>
3069
3070         Reviewed by Eric.
3071
3072         https://bugs.webkit.org/show_bug.cgi?id=11939
3073         Quirksmode: Ignores media types in stylesheet PIs
3074
3075         Transfer the xml-stylesheet pseudo attribute media to the css
3076         stylesheet created from the ProcessingInstruction.
3077
3078         Tests: fast/css/xml-stylesheet-media-processing.xhtml
3079
3080         * css/StyleSheet.cpp:
3081         (WebCore::StyleSheet::setMedia):
3082         * css/StyleSheet.h:
3083         * dom/ProcessingInstruction.cpp:
3084         (WebCore::ProcessingInstruction::checkStyleSheet):
3085         (WebCore::ProcessingInstruction::setCSSStyleSheet):
3086         * dom/ProcessingInstruction.h:
3087
3088 2008-04-29  David D. Kilzer  <ddkilzer@apple.com>
3089
3090         BUILD FIX for export of WTF::RefCounted<WebCore::FormData>::deref()
3091
3092         On the buildbot, this is a fatal error:
3093
3094         ld: symbols names listed in -exported_symbols_list: WebKitBuild/Release/DerivedSources/WebCore/WebCore.exp not in linked objects
3095         __ZN3WTF10RefCountedIN7WebCore8FormDataEE5derefEv
3096         /usr/bin/libtool: internal link edit command failed
3097
3098         Newer dev tools only produce a warning:
3099
3100         ld warning: cannot export hidden symbol __ZN3WTF10RefCountedIN7WebCore8FormDataEE5derefEv from WebKitBuild/WebCore.build/Release/WebCore.build/Objects-normal/i386/DocumentLoader.o
3101
3102         * WebCore.base.exp: Remove hidden symbol from export list.
3103
3104 2008-04-29  David Kilzer  <ddkilzer@apple.com>
3105
3106         Another BUILD FIX for ENABLE(DASHBOARD_SUPPORT)
3107
3108         * dom/make_names.pl: Added #if ENABLE(DASHBOARD_SUPPORT) to Dashboard code.
3109
3110 2008-04-29  David Kilzer  <ddkilzer@apple.com>
3111
3112         BUILD FIX for ENABLE(DASHBOARD_SUPPORT)
3113
3114         * DerivedSources.make: Removed duplication of targets for
3115         generating CSSPropertyNames.h and CSSValueKeywords.h.
3116         * GNUmakefile.am: Ditto.  Added support for ENABLE_DASHBOARD_SUPPORT.
3117         * WebCore.pro: Added support for ENABLE_DASHBOARD_SUPPORT.
3118         Made both SVG and non-SVG variables of GENERATOR 6-A use new
3119         DASHBOARDSUPPORTCSSPROPERTIES variable.
3120
3121 2008-04-29  Ada Chan  <adachan@apple.com>
3122
3123         Added missing return.        
3124
3125         * platform/win/COMPtr.h:
3126         (WTF::):
3127
3128 2008-04-29  Alp Toker  <alp@nuanti.com>
3129
3130         GTK+ build fix attempt following breakage in r32700 which
3131         conditionalised dashboard support.
3132
3133         * GNUmakefile.am:
3134
3135 2008-04-29  Adam Roben  <aroben@apple.com>
3136
3137         Restore the beloved COMPtr::operator&
3138
3139         * platform/win/COMPtr.h: Removed the HashTableDeletedValueType
3140         constructor and isHashTableDeletedValue and hashTableDeletedValue
3141         functions.
3142         (WTF::): Changed constructDeletedValue to play nicely with
3143         COMPtr::operator&.
3144
3145 2008-04-29  Adam Roben  <aroben@apple.com>
3146
3147         Fix assertion on launch on Windows
3148
3149         * platform/graphics/win/FontPlatformData.h: Pass
3150         WTF::HashTableDeletedValue to the m_font constructor instead of a
3151         bogus -1 value. This is needed because m_font is a RefPtr.
3152
3153 2008-04-29  Greg Bolsinga  <bolsinga@apple.com>
3154
3155         Reviewed by Darin.
3156
3157         Wrapped Dashboard code with ENABLE(DASHBOARD_SUPPORT)
3158
3159         * DerivedSources.make:
3160         * WebCore.DashboardSupport.exp: Added.
3161         * WebCore.base.exp:
3162         * WebCore.xcodeproj/project.pbxproj:
3163         * bindings/js/JSDOMWindowCustom.cpp:
3164         (WebCore::JSDOMWindow::setLocation):
3165         * css/CSSComputedStyleDeclaration.cpp:
3166         (WebCore::):
3167         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3168         * css/CSSParser.cpp:
3169         (WebCore::CSSParser::parseValue):
3170         * css/CSSPrimitiveValue.cpp:
3171         (WebCore::CSSPrimitiveValue::cleanup):
3172         (WebCore::CSSPrimitiveValue::cssText):
3173         * css/CSSPropertyNames.in:
3174         * css/CSSStyleSelector.cpp:
3175         (WebCore::CSSStyleSelector::applyProperty):
3176         * css/DashboardRegion.h:
3177         * css/DashboardSupportCSSPropertyNames.in: Added.
3178         * dom/DOMImplementation.cpp:
3179         (WebCore::DOMImplementation::createDocument):
3180         * dom/Document.cpp:
3181         (WebCore::Document::Document):
3182         (WebCore::Document::importNode):
3183         * dom/Document.h:
3184         * html/CanvasRenderingContext2D.cpp:
3185         (WebCore::CanvasRenderingContext2D::fill):
3186         (WebCore::CanvasRenderingContext2D::stroke):
3187         (WebCore::CanvasRenderingContext2D::clip):
3188         * html/CanvasRenderingContext2D.h:
3189         * html/HTMLCanvasElement.cpp:
3190         * html/HTMLCanvasElement.h:
3191         * page/Chrome.cpp:
3192         * page/ChromeClient.h:
3193         * page/Frame.cpp:
3194         (WebCore::Frame::paint):
3195         * page/Frame.h:
3196         * page/FrameView.cpp:
3197         (WebCore::FrameView::layout):
3198         * page/FrameView.h:
3199         * page/Settings.cpp:
3200         (WebCore::Settings::Settings):
3201         * page/Settings.h:
3202         * page/mac/EventHandlerMac.mm:
3203         (WebCore::EventHandler::needsKeyboardEventDisambiguationQuirks):
3204         * page/mac/FrameMac.mm:
3205         * page/mac/WebDashboardRegion.h:
3206         * page/mac/WebDashboardRegion.m:
3207         * rendering/RenderLayer.cpp:
3208         (WebCore::RenderLayer::scrollToOffset):
3209         (WebCore::RenderLayer::setHasHorizontalScrollbar):
3210         (WebCore::RenderLayer::setHasVerticalScrollbar):
3211         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
3212         * rendering/RenderObject.cpp:
3213         (WebCore::RenderObject::setStyle):
3214         * rendering/RenderObject.h:
3215         * rendering/RenderStyle.cpp:
3216         (WebCore::StyleRareNonInheritedData::operator==):
3217         (WebCore::RenderStyle::diff):
3218         * rendering/RenderStyle.h:
3219         * xml/XMLHttpRequest.cpp:
3220         (WebCore::XMLHttpRequest::send):
3221         (WebCore::XMLHttpRequest::setRequestHeader):
3222
3223 2008-04-29  Adam Roben  <aroben@apple.com>
3224
3225         Windows build fix
3226
3227         This removes COMPtr::operator&, which didn't jive with HashTable. It
3228         is replaced by COMPtr::adoptionPointer.
3229
3230         Discussed with Darin Adler and Anders Carlsson.
3231
3232         * platform/win/COMPtr.h: Replaced operator& with adoptionPointer.
3233
3234 2008-04-29  David Hyatt  <hyatt@apple.com>
3235
3236         Implement the new box-reflect property in CSS.  This property enables real-time reflections on
3237         objects (yes you can reflect <video>!).
3238
3239         Reviewed by Dan Bernstein
3240
3241         Test cases added in fast/reflections/
3242
3243         * GNUmakefile.am:
3244         * WebCore.pro:
3245         * WebCore.xcodeproj/project.pbxproj:
3246         * WebCoreSources.bkl:
3247         * css/CSSComputedStyleDeclaration.cpp:
3248         (WebCore::):
3249         (WebCore::valueForReflection):
3250         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3251         * css/CSSParser.cpp:
3252         (WebCore::CSSParser::parseValue):
3253         (WebCore::CSSParser::parseReflect):
3254         (WebCore::BorderImageParseContext::commitBorderImage):
3255         (WebCore::CSSParser::parseBorderImage):
3256         (WebCore::parseGradientColorStop):
3257         (WebCore::CSSParser::parseTransform):
3258         * css/CSSParser.h:
3259         * css/CSSPropertyNames.in:
3260         * css/CSSReflectValue.cpp: Added.
3261         (WebCore::CSSReflectValue::cssText):
3262         * css/CSSReflectValue.h: Added.
3263         (WebCore::):
3264         (WebCore::CSSReflectValue::CSSReflectValue):
3265         (WebCore::CSSReflectValue::direction):
3266         (WebCore::CSSReflectValue::offset):
3267         (WebCore::CSSReflectValue::mask):
3268         (WebCore::CSSReflectValue::setDirection):
3269         (WebCore::CSSReflectValue::setOffset):
3270         (WebCore::CSSReflectValue::setMask):
3271         * css/CSSStyleSelector.cpp:
3272         (WebCore::CSSStyleSelector::adjustRenderStyle):
3273         (WebCore::CSSStyleSelector::applyProperty):
3274         (WebCore::CSSStyleSelector::mapNinePieceImage):
3275         * css/CSSStyleSelector.h:
3276         * rendering/InlineFlowBox.cpp:
3277         (WebCore::InlineFlowBox::placeBoxesVertically):
3278         (WebCore::InlineFlowBox::paintMask):
3279         * rendering/Length.h:
3280         (WebCore::Length::calcFloatValue):
3281         * rendering/RenderBlock.cpp:
3282         (WebCore::RenderBlock::overflowHeight):
3283         (WebCore::RenderBlock::overflowWidth):
3284         (WebCore::RenderBlock::overflowLeft):
3285         (WebCore::RenderBlock::overflowTop):
3286         (WebCore::RenderBlock::overflowRect):
3287         (WebCore::RenderBlock::layoutBlock):
3288         * rendering/RenderBox.cpp:
3289         (WebCore::RenderBox::setStyle):
3290         (WebCore::RenderBox::paintMask):
3291         (WebCore::RenderBox::imageChanged):
3292         (WebCore::RenderBox::computeAbsoluteRepaintRect):
3293         * rendering/RenderFlexibleBox.cpp:
3294         (WebCore::RenderFlexibleBox::layoutBlock):
3295         * rendering/RenderLayer.cpp:
3296         (WebCore::RenderLayer::RenderLayer):
3297         (WebCore::RenderLayer::~RenderLayer):
3298         (WebCore::RenderLayer::updateLayerPositions):
3299         (WebCore::RenderLayer::enclosingPositionedAncestor):
3300         (WebCore::RenderLayer::enclosingTransformedAncestor):
3301         (WebCore::RenderLayer::isTransparent):
3302         (WebCore::transparencyClipBox):
3303         (WebCore::RenderLayer::operator delete):
3304         (WebCore::RenderLayer::destroy):
3305         (WebCore::RenderLayer::removeOnlyThisLayer):
3306         (WebCore::RenderLayer::insertOnlyThisLayer):
3307         (WebCore::RenderLayer::paintLayer):
3308         (WebCore::RenderLayer::updateZOrderLists):
3309         (WebCore::RenderLayer::updateOverflowList):
3310         (WebCore::RenderLayer::collectLayers):
3311         (WebCore::RenderLayer::shouldBeOverflowOnly):
3312         (WebCore::RenderLayer::styleChanged):
3313         (WebCore::RenderLayer::reflectionLayer):
3314         (WebCore::RenderLayer::createReflection):
3315         (WebCore::RenderLayer::updateReflectionStyle):
3316         * rendering/RenderLayer.h:
3317         (WebCore::RenderLayer::hasReflection):
3318         (WebCore::RenderLayer::reflection):
3319         (WebCore::RenderLayer::paintingInsideReflection):
3320         * rendering/RenderObject.cpp:
3321         (WebCore::RenderObject::RenderObject):
3322         (WebCore::RenderObject::requiresLayer):
3323         (WebCore::RenderObject::setStyle):
3324         (WebCore::RenderObject::updateImage):
3325         (WebCore::RenderObject::reflectionBox):
3326         (WebCore::RenderObject::reflectionOffset):
3327         * rendering/RenderObject.h:
3328         (WebCore::RenderObject::hasTransform):
3329         (WebCore::RenderObject::setHasReflection):
3330         (WebCore::RenderObject::hasReflection):
3331         * rendering/RenderReplica.cpp: Added.
3332         (WebCore::RenderReplica::RenderReplica):
3333         (WebCore::RenderReplica::~RenderReplica):
3334         (WebCore::RenderReplica::layout):
3335         (WebCore::RenderReplica::calcPrefWidths):
3336         (WebCore::RenderReplica::paint):
3337         * rendering/RenderReplica.h: Added.
3338         (WebCore::RenderReplica::renderName):
3339         (WebCore::RenderReplica::requiresLayer):
3340         * rendering/RenderStyle.cpp:
3341         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
3342         (WebCore::StyleRareNonInheritedData::operator==):
3343         (WebCore::StyleRareNonInheritedData::reflectionDataEquivalent):
3344         (WebCore::RenderStyle::diff):
3345         (WebCore::RenderStyle::applyTransform):
3346         * rendering/RenderStyle.h:
3347         (WebCore::TranslateTransformOperation::apply):
3348         (WebCore::StyleReflection::StyleReflection):
3349         (WebCore::StyleReflection::operator==):
3350         (WebCore::StyleReflection::operator!=):
3351         (WebCore::StyleReflection::direction):
3352         (WebCore::StyleReflection::offset):
3353         (WebCore::StyleReflection::mask):
3354         (WebCore::StyleReflection::setDirection):
3355         (WebCore::StyleReflection::setOffset):
3356         (WebCore::StyleReflection::setMask):
3357         (WebCore::RenderStyle::boxReflect):
3358         (WebCore::RenderStyle::setBoxReflect):
3359         (WebCore::RenderStyle::initialBoxReflect):
3360         * rendering/RenderTable.cpp:
3361         (WebCore::RenderTable::layout):
3362         (WebCore::RenderTable::paintMask):
3363         * rendering/RenderTableCell.cpp:
3364         (WebCore::RenderTableCell::requiresLayer):
3365         (WebCore::RenderTableCell::paintMask):
3366
3367 2008-04-29  Beth Dakin  <bdakin@apple.com>
3368
3369         Reviewed by Alice.
3370
3371         Initial implementation of the following ARIA roles: button, 
3372         checkbox, heading, link, radio, textbox.
3373
3374         * html/HTMLAttributeNames.in: Add 'role' to list of attributes.
3375
3376         * page/AccessibilityObject.cpp:
3377          When an ARIA role is set, the role overrides whatever the actual 
3378 element is when the element reports itself to the screen reader. So all of these isBlah functions report based on their roleValue now.
3379         (WebCore::AccessibilityObject::isWebArea):
3380         (WebCore::AccessibilityObject::isImageButton):
3381         (WebCore::AccessibilityObject::isAnchor):
3382         (WebCore::AccessibilityObject::isTextControl):
3383         (WebCore::AccessibilityObject::isImage):
3384         (WebCore::AccessibilityObject::isAttachment):
3385         (WebCore::AccessibilityObject::isPasswordField):
3386         (WebCore::AccessibilityObject::isCheckboxOrRadio):
3387         (WebCore::AccessibilityObject::isHeading):
3388         (WebCore::AccessibilityObject::isLink):
3389
3390         Check for ARIA information:
3391         (WebCore::AccessibilityObject::headingLevel):
3392         (WebCore::AccessibilityObject::anchorElement):
3393         (WebCore::AccessibilityObject::actionElement):
3394         (WebCore::AccessibilityObject::hasIntValue):
3395         (WebCore::AccessibilityObject::intValue):
3396         (WebCore::AccessibilityObject::stringValue):
3397         (WebCore::AccessibilityObject::title):
3398         (WebCore::AccessibilityObject::accessibilityIsIgnored):
3399         (WebCore::AccessibilityObject::roleValue):
3400
3401         There are a few places in the code where it is important to identify the difference between ARIA and non-ARIA.
3402         (WebCore::AccessibilityObject::isNativeImage):
3403         (WebCore::AccessibilityObject::isNativeTextControl):
3404         (WebCore::isARIAInput):
3405         (WebCore::isARIAControl):
3406
3407         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. 
3408         (WebCore::AccessibilityObject::text): Still calls into 
3409         RenderTextControl's text() for native text controls. Uses Element's 
3410         innerText() for ARIA textboxes.
3411         (WebCore::AccessibilityObject::textLength): Call 
3412         AccessibilityObject's text() instead of RenderTextControl's.
3413         (WebCore::AccessibilityObject::ariaSelectedTextDOMRange):
3414         (WebCore::AccessibilityObject::selectedText):
3415         (WebCore::AccessibilityObject::selectedTextRange):
3416         (WebCore::AccessibilityObject::selectionStart):
3417         (WebCore::AccessibilityObject::selectionEnd):
3418         (WebCore::AccessibilityObject::setSelectedTextRange):
3419         (WebCore::AccessibilityObject::setValue):
3420         (WebCore::AccessibilityObject::visiblePositionForIndex):
3421         (WebCore::AccessibilityObject::indexForVisiblePosition):
3422         (WebCore::AccessibilityObject::textMarkerRangeForRange):
3423         (WebCore::AccessibilityObject::textMarkerForIndex):
3424         (WebCore::AccessibilityObject::indexForTextMarker):
3425         (WebCore::AccessibilityObject::doAXRangeForLine):
3426         (WebCore::AccessibilityObject::doAXRangeForIndex):
3427         (WebCore::AccessibilityObject::doAXStringForRange):
3428         (WebCore::AccessibilityObject::doAXBoundsForRange):
3429         
3430         Reports ARIA role. If the role is not valid or simply not set, return UnknownRole.
3431         (WebCore::AccessibilityObject::ariaRoleAttribute):
3432         
3433         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.
3434         * page/AccessibilityObject.h:
3435
3436         Eliminated dependency on RenderTextControl cast. The information is generalized now and available directly through the AccessibilityObject.
3437         * page/mac/AccessibilityObjectWrapper.mm:
3438         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
3439         (-[AccessibilityObjectWrapper doAXAttributedStringForRange:]):
3440
3441 2008-04-29  Timothy Hatcher  <timothy@apple.com>
3442
3443         Make the exceptions that the InspectorController catches log the
3444         original file and line number, if present on the exception object.
3445
3446         Reviewed by Adam Roben.
3447
3448         * page/InspectorController.cpp:
3449         (WebCore::InspectorController::callFunction): Pass the context to HANDLE_EXCEPTION.
3450         (WebCore::InspectorController::~InspectorController): Ditto.
3451         (WebCore::InspectorController::scriptObjectReady): Ditto.
3452         (WebCore::InspectorController::addScriptResource): Ditto.
3453         (WebCore::InspectorController::updateScriptResourceRequest): Ditto.
3454         (WebCore::InspectorController::updateScriptResourceResponse): Ditto.
3455         (WebCore::InspectorController::updateScriptResource): Ditto.
3456         (WebCore::InspectorController::addDatabaseScriptResource): Ditto.
3457         (WebCore::InspectorController::addScriptConsoleMessage): Ditto.
3458         (WebCore::InspectorController::handleException): Take a context. Pull the line
3459         and sourceURL properties off the exception if it is an object.
3460         * page/InspectorController.h: Change handleException to take a context.
3461
3462 2008-04-29  Timothy Hatcher  <timothy@apple.com>
3463
3464         Fixes a regression where the Page's debugger would not be reattached
3465         when a new JSDOMWindow is created.
3466
3467         Reviewed by Sam Weinig.
3468
3469         * bindings/js/kjs_proxy.cpp:
3470         (WebCore::KJSProxy::clear): Call attachDebugger after creating the JSDOMWindow.
3471         * history/CachedPage.cpp:
3472         (WebCore::CachedPage::restore): For the case where the CachedPage doesn't
3473         contain a window, reattach the debugger to the new JSDOMWindow by calling
3474         proxy->attachDebugger. Also restore the setPageGroupIdentifier.
3475
3476 2008-04-29  Anatoli Papirovski  <apapirovski@mac.com>
3477
3478         Reviewed by Darin Adler.
3479
3480         Fix for https://bugs.webkit.org/show_bug.cgi?id=18355
3481         Fixed RGB and RGBA parsing to ignore the declaration when the value is not
3482         "either three integer values or three percentage values."
3483
3484         * css/CSSParser.cpp:
3485         (WebCore::CSSParser::parseColorParameters):
3486
3487 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
3488
3489         Reviewed by Simon.
3490
3491         Fix crash when setHtml gets called from slots connected to QWebPage::unsupportedContent
3492
3493         Ben found this crash in the demo browser.
3494
3495         In void MainResourceLoader::continueAfterContentPolicy(PolicyAction contentPolicy,
3496
3497         case PolicyDownload:
3498         frameLoader()->client()->download(m_handle.get(), request(), m_handle.get()->request(), r);
3499         receivedError(interruptionForPolicyChangeError());
3500
3501         We are in a policy check, the download() call will call setHtml, which will start loading
3502         the data into a frame. The loading will cancel all policy checks and call ResourceLoader::releaseResources
3503         which will set m_frame to 0. Then we return and invoke interruptionForPolicyChangeError() which
3504         will use the m_frame->loader() but it is gone. Do not call into receivedError and
3505         interruptionForPolicyChangeError if we are gone anyway...
3506
3507         * loader/MainResourceLoader.cpp:
3508         (WebCore::MainResourceLoader::continueAfterContentPolicy):
3509
3510 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
3511
3512         Reviewed by Simon.
3513
3514         Rely on auto-boxing of C++ for the QCursor c'tor
3515
3516         * platform/qt/CursorQt.cpp:
3517
3518 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
3519
3520         Reviewed by Simon.
3521
3522         Add the remaining cursors that defaulted to PointerCursor
3523
3524         * Resources/WebKitResources.qrc:
3525         * platform/qt/CursorQt.cpp:
3526         (WebCore::verticalTextCursor):
3527         (WebCore::cellCursor):
3528         (WebCore::contextMenuCursor):
3529         (WebCore::copyCursor):
3530         (WebCore::progressCursor):
3531         (WebCore::aliasCursor):
3532
3533 2008-04-29  Alice Liu  <alice.liu@apple.com>
3534
3535         Reviewed by Beth Dakin.
3536
3537         Comply with HTML5 spec about parsing tabindex property according to
3538         integer parsing rules
3539
3540         Test: fast/parser/tabindex-parsing.html
3541
3542         * html/HTMLElement.cpp:
3543         (WebCore::HTMLElement::parseMappedAttribute):
3544
3545 2008-04-29  Tor Arne Vestbø  <tavestbo@trolltech.com>
3546
3547         Reviewed by Simon.
3548
3549         Fixes: Fix timing problem where scrollbars in subframes were sometimes not property repainted.
3550
3551         https://bugs.webkit.org/show_bug.cgi?id=18482
3552
3553         We need to repaint scrollbars after a geometry change, and also make sure
3554         the computed clipping rect for the corners between scrollbars is propagated
3555         to the chrome client without beeing intersected by the visible content rect
3556         of the frame.
3557
3558         * platform/ScrollView.h:
3559         * platform/qt/ScrollViewQt.cpp:
3560         (WebCore::ScrollView::geometryChanged):
3561         (WebCore::ScrollView::suppressScrollbars):
3562         (WebCore::ScrollView::invalidateScrollbars):
3563
3564 2008-04-29  Holger Hans Peter Freyther  <zecke@selfish.org>
3565
3566         Reviewed by Simon.
3567
3568         Calling QWebView::setCursor will override the WebCore Cursor.
3569         Calling QWebView::setCursor will override the WebCore Cursor using
3570         QWidget::unsetCursor will revert to the WebCore Cursor.
3571
3572         For detecting the unset we have to compare the shape of the
3573         cursor to the default arrow. Qt::WA_SetCursor can not be used
3574         as it is set unconditionally but conditionally removed.
3575
3576         Calling QWidget::setCursor will immediately send the CursorChange
3577         event. We listen to this event to decide if we currently use a
3578         WebCore cursor, got a cursor from outside, or revert to the default.
3579
3580         This should be race free and work reliable, the manual test for this
3581         is WebCore/manual-tests/cursor.html
3582
3583         * platform/qt/WidgetQt.cpp:
3584         (WebCore::Widget::setCursor):
3585
3586 2008-04-28  Dan Bernstein  <mitz@apple.com>
3587
3588         Reviewed by Maciej Stachowiak.
3589
3590         - fix https://bugs.webkit.org/show_bug.cgi?id=18795
3591           REGRESSION (r32660): Text heavier with text-shadow
3592
3593         * rendering/InlineTextBox.cpp:
3594         (WebCore::paintTextWithShadows): The loop was doing one extra pass
3595         without shadow even in cases where the last pass with a shadow was
3596         painting the text at the right position (rather than outside the clip).
3597         Fixed that. The only case where a separate pass without shadow is needed
3598         is when there is text-stroke, since in that case all shadow passes
3599         paint the text outside the clip.