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