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