2009-06-25 Jian Li <jianli@chromium.org>
[WebKit-https.git] / WebCore / ChangeLog
1 2009-06-25  Jian Li  <jianli@chromium.org>
2
3         Reviewed by Dimitri Glazkov.
4
5         Bug 26701: Implement the missing code for "FIXME: Need to return an
6         exception" in WorkerScriptController::evaluate for v8 bindings.
7         https://bugs.webkit.org/show_bug.cgi?id=26701
8
9         * bindings/v8/WorkerScriptController.cpp:
10         (WebCore::WorkerScriptController::evaluate):
11
12 2009-06-25  Nate Chapin  <japhet@chromium.org>
13
14         Reviewed by Dimitri Glazkov.
15
16         Upstream V8Index.
17
18         https://bugs.webkit.org/show_bug.cgi?id=26495
19
20         * bindings/v8/V8Index.cpp: Added.
21         (WebCore::V8ClassIndex::GetFactory): Moved from src.chromium.org.
22         (WebCore::V8ClassIndex::GetCache): Moved from src.chromium.org.
23         * bindings/v8/V8Index.h:
24         (WebCore::V8ClassIndex::): Moved from src.chromium.org.
25         (WebCore::V8ClassIndex::ToInt): Moved from src.chromium.org.
26         (WebCore::V8ClassIndex::FromInt): Moved from src.chromium.org.
27
28 2009-06-25  Adam Langley  <agl@google.com>
29
30         Reviewed by Darin Fisher.
31
32         https://bugs.webkit.org/show_bug.cgi?id=26529
33
34         This is hopefully the last step before our renderers can run
35         cleanly in a chroot.
36
37         WebKit needs to be able to ask for the correct font to use in
38         the case that the current font doesn't include glyphs for
39         certain code points. Currently we make a fontconfig call in our
40         WebKit port to handle this.
41
42         This patch changes this so that the call is sent our via
43         ChromiumBridge.
44
45         http://codereview.chromium.org/132007
46
47         This should not affect any layout tests.
48
49         * platform/chromium/ChromiumBridge.h:
50         * platform/graphics/chromium/FontCacheLinux.cpp:
51         (WebCore::FontCache::getFontDataForCharacters):
52
53 2009-06-25  Albert J. Wong  <ajwong@chromium.org>
54
55         Reviewed by David Levin.
56
57         https://bugs.webkit.org/show_bug.cgi?id=26566
58         Upstream these files from the chromium v8 code.  No tests were
59         affected because this is essentially a code move.
60
61         * bindings/v8/NPV8Object.cpp: Added.
62         (allocV8NPObject):
63         (freeV8NPObject):
64         (listFromVariantArgs):
65         (npIdentifierToV8Identifier):
66         (npCreateV8ScriptObject):
67         (NPN_Invoke):
68         (NPN_InvokeDefault):
69         (NPN_Evaluate):
70         (NPN_EvaluateHelper):
71         (NPN_GetProperty):
72         (NPN_SetProperty):
73         (NPN_RemoveProperty):
74         (NPN_HasProperty):
75         (NPN_HasMethod):
76         (NPN_SetException):
77         (NPN_Enumerate):
78         (NPN_Construct):
79         * bindings/v8/NPV8Object.h: Added.
80         (PrivateIdentifier::):
81         * bindings/v8/V8NPUtils.cpp: Added.
82         (convertV8ObjectToNPVariant):
83         (convertNPVariantToV8Object):
84         (getStringIdentifier):
85         * bindings/v8/V8NPUtils.h: Added.
86
87 2009-06-25  Shinichiro Hamaji  <hamaji@chromium.org>
88
89         Reviewed by Dimitri Glazkov.
90
91         https://bugs.webkit.org/show_bug.cgi?id=26436
92
93         Windows Chromium bug fix: save context of destination canvas in
94         TransparencyWin::compositeTextComposite() before the function
95         modifies the context.
96
97         Test: fast/canvas/translate-text.html
98
99         * platform/graphics/chromium/TransparencyWin.cpp:
100         (WebCore::TransparencyWin::compositeTextComposite):
101
102 2009-06-25  Patrick Mueller  <Patrick_Mueller@us.ibm.com>
103
104         Reviewed by Timothy Hatcher.
105
106         Show the filename and first line for "(program)" in the Profiler/Debugger
107         https://bugs.webkit.org/show_bug.cgi?id=25475
108
109         Add support to associate a sourceURL with an eval()'d string
110         via a @sourceURL comment.  Currently the sourceURL is only available
111         in the script debugger, not in the console or profiler, but it's
112         most needed in the script debugger.
113
114         * English.lproj/localizedStrings.js: added new "(program): %s" string
115         * inspector/front-end/Script.js:
116         (WebInspector.Script): if no sourceURL is available for the Script,
117         search for a comment of the form //@ sourceURL=(url) to use
118         as the sourceURL instead.
119         * manual-tests/inspector/named-evals.html: Added.
120
121 2009-06-25  John Gregg  <johnnyg@google.com>
122
123         Reviewed by Sam Weinig.
124
125         Bug 23721: Changing dropdown's selectedIndex within onchange handler fires another onchange
126         https://bugs.webkit.org/show_bug.cgi?id=23721
127
128         onchange events fire when a SELECT element has
129         focus and the selectedIndex is updated by script in some way--either
130         during another onchange, onkeypress, onfocus, or timer--and then
131         focus is lost. 
132
133         Fixed by making a separate method for user-driven selectedIndex 
134         changes, leaving scripts to use one which doesn't cause onchange to
135         be queued.
136         
137         Test: fast/forms/select-script-onchange.html
138
139         * dom/SelectElement.cpp: check if the pending change is user driven
140         before calling onchange
141         (WebCore::SelectElement::menuListOnChange):
142         (WebCore::SelectElement::setSelectedIndex):
143         * dom/SelectElement.h: store whether the pending change is user driven
144         (WebCore::SelectElementData::userDrivenChange):
145         (WebCore::SelectElementData::setUserDrivenChange):
146         * html/HTMLSelectElement.cpp: split into two methods -- script version
147         [non-user-driven] corresponds to IDL defined property name
148         (WebCore::HTMLSelectElement::setSelectedIndex):
149         (WebCore::HTMLSelectElement::setSelectedIndexByUser):
150         * html/HTMLSelectElement.h: 
151         * rendering/RenderMenuList.cpp: use ByUser method when coming through
152         the renderer
153         (WebCore::RenderMenuList::valueChanged):
154
155 2009-06-25  Jeremy Orlow  <jorlow@chromium.org>
156
157         Reviewed by Darin Fisher.
158
159         https://bugs.webkit.org/show_bug.cgi?id=26698
160
161         Combined LocalStorageArea and SessionStorageArea into StorageArea since
162         (after my other refactorings) there are no longer substantial
163         differences between the two.
164
165         * GNUmakefile.am:
166         * WebCore.vcproj/WebCore.vcproj:
167         * WebCore.xcodeproj/project.pbxproj:
168         * WebCoreSources.bkl:
169         * storage/LocalStorage.cpp:
170         (WebCore::LocalStorage::storageArea):
171         * storage/LocalStorage.h:
172         * storage/LocalStorageArea.cpp: Removed.
173         * storage/LocalStorageArea.h: Removed.
174         * storage/SessionStorage.cpp:
175         (WebCore::SessionStorage::copy):
176         (WebCore::SessionStorage::storageArea):
177         * storage/SessionStorage.h:
178         * storage/SessionStorageArea.cpp: Removed.
179         * storage/SessionStorageArea.h: Removed.
180         * storage/StorageArea.cpp:
181         (WebCore::StorageArea::createLocalStorage):
182         (WebCore::StorageArea::StorageArea):
183         (WebCore::StorageArea::createSessionStorage):
184         (WebCore::StorageArea::copy):
185         (WebCore::StorageArea::setItem):
186         (WebCore::StorageArea::removeItem):
187         (WebCore::StorageArea::clear):
188         (WebCore::StorageArea::scheduleFinalSync):
189         (WebCore::StorageArea::blockUntilImportComplete):
190         (WebCore::StorageArea::dispatchStorageEvent):
191         * storage/StorageArea.h:
192         * storage/StorageAreaSync.cpp:
193         (WebCore::StorageAreaSync::StorageAreaSync):
194         (WebCore::StorageAreaSync::scheduleFinalSync):
195         (WebCore::StorageAreaSync::syncTimerFired):
196         (WebCore::StorageAreaSync::performImport):
197         * storage/StorageAreaSync.h:
198         * storage/StorageSyncManager.h:
199
200 2009-06-25  Dan Bernstein  <mitz@apple.com>
201
202         Reviewed by Darin Adler.
203
204         - fix https://bugs.webkit.org/show_bug.cgi?id=26671
205           <rdar://problem/7001880> Safari 4.0 crashes in
206           WebCore::DOMTimer::fired()
207
208         Test: fast/dom/style-sheet-candidate-remove-unrendered-document.html
209
210         When a "style sheet candidate" element is removed from a document,
211         call Document::removeStyleSheetCandidateNode() regardless of whether
212         the document is rendered. Otherwise, the document's style sheet
213         candidate set can end up containing stale references.
214
215         * dom/ProcessingInstruction.cpp:
216         (WebCore::ProcessingInstruction::removedFromDocument):
217         * html/HTMLLinkElement.cpp:
218         (WebCore::HTMLLinkElement::removedFromDocument):
219         * html/HTMLStyleElement.cpp:
220         (WebCore::HTMLStyleElement::removedFromDocument):
221
222 2009-06-25  Dimitri Glazkov  <dglazkov@chromium.org>
223
224         Reviewed by Darin Fisher.
225
226         Update CodeGeneratorV8.pm to sync up with the changes downstream.
227
228         * bindings/scripts/CodeGeneratorV8.pm: Added HTMLFrameSetElement check,
229           FileList as a ref-counted type, and DataGridColumn as typeCanFailConversion.
230
231 2009-06-25  Dimitri Glazkov  <dglazkov@chromium.org>
232
233         Unreviewed, build fix.
234
235         Add FileList.h include to fix Chromium build.
236
237         * platform/chromium/ClipboardChromium.cpp: Added FileList.h include.
238
239 2009-06-25  Joseph Pecoraro  <joepeck02@gmail.com>
240
241         Reviewed by Jan Alonzo.
242
243         Bug 26489: Web Inspector: Typo in DatabaseQuery Error Message
244         https://bugs.webkit.org/show_bug.cgi?id=26489
245
246         Fixed a Typo in a Web Inspector error message.
247
248         * English.lproj/localizedStrings.js:
249         * inspector/front-end/DatabaseQueryView.js:
250         (WebInspector.DatabaseQueryView.prototype._queryError):
251
252 2009-06-25  Simon Hausmann  <simon.hausmann@nokia.com>
253
254         Fix the Qt build, add missing StorageAreaSync files to the build.
255
256         * WebCore.pro:
257
258 2009-06-25  Simon Hausmann  <simon.hausmann@nokia.com>
259
260         Reviewed by and done with Tor Arne Vestbø.
261
262         Fix shortcut keyboard handling with plugins on the Qt/Mac build.
263
264         When we receive shortcut events like Ctrl+V then the text in the QKeyEvent is
265         empty. If we're asked to disambiguate the event into a Char keyboard event,
266         we try to detect this situation and still set the text, to ensure that the
267         general event handling sends a key press event after this disambiguation.
268
269         * platform/qt/PlatformKeyboardEventQt.cpp:
270         (WebCore::PlatformKeyboardEvent::disambiguateKeyDownEvent):
271
272 2009-06-25  Eric Seidel  <eric@webkit.org>
273
274         Build fix only, no review.
275
276         Add FileList.h and NotImplemented.h includes in an attempt to fix bots.
277
278         * platform/gtk/ClipboardGtk.cpp:
279         * platform/qt/ClipboardQt.cpp:
280         * platform/win/ClipboardWin.cpp:
281         * platform/wx/ClipboardWx.cpp:
282
283 2009-05-21  Eric Seidel  <eric@webkit.org>
284
285         Reviewed by Maciej Stachowiak.
286
287         Expose files in the clipboard in ondrop events
288         https://bugs.webkit.org/show_bug.cgi?id=25916
289
290         Make it possible for applications like gmail to implement
291         drag and drop of attachments onto email messages.
292
293         This patch exposes an event.dataTransfer.files accessor
294         on the drop event.  No information is exposed during dragover.
295         This follows the HTML 5 drag and drop security model:
296         http://www.w3.org/TR/html5/editing.html#security-risks-in-the-drag-and-drop-model
297         The test http/tests/security/clipboard/clipboard-file-access.html
298         verifies this behavior.
299
300         Internet Explorer shows historical documentation of supporting
301         getData('File') as a way of exposing files on the pasteboard.  The current version of their docs:
302         http://msdn.microsoft.com/en-us/library/ms537658(VS.85).aspx
303         has removed this reference (as far as I can tell IE never implemented it)
304         I have a printed copy of that URL from 2008 on my desk describing getData('File') in IE.
305         IE does not follow the HTML5 clipboard security model and always allows access to the full clipboard, even on dragover.
306
307         I choose not to use IE's getData('File') and instead added .files
308         so that the accessor could have a type, matching WebKit's existing
309         .files accessor on HTMLInputElement.
310
311         Mozilla has equivalent file access:
312         event.dataTransfer.mozGetDataAt("application/x-moz-file", 0);
313         which also does not return a typed value.
314         https://developer.mozilla.org/En/DragDrop/Recommended_Drag_Types#Dragging_Files
315
316         This is only implemented for Mac WebKit.  All other platforms (including Apple's Win WebKit)
317         have incomplete Clipboard implementations and will require experts from those platforms
318         to add this functionality.  Right now they all have Clipboard*::files() methods which call notImplemented();
319
320         Test: http/tests/security/clipboard/clipboard-file-access.html
321
322         * dom/Clipboard.h:
323         * dom/Clipboard.idl:
324         * platform/chromium/ClipboardChromium.cpp:
325         (WebCore::ClipboardChromium::files):
326         * platform/chromium/ClipboardChromium.h:
327         * platform/gtk/ClipboardGtk.cpp:
328         (WebCore::ClipboardGtk::files):
329         * platform/gtk/ClipboardGtk.h:
330         * platform/mac/ClipboardMac.h:
331         * platform/mac/ClipboardMac.mm:
332         (WebCore::absoluteURLsFromPasteboardFilenames):
333         (WebCore::absoluteURLsFromPasteboard):
334         (WebCore::ClipboardMac::files):
335         * platform/qt/ClipboardQt.cpp:
336         (WebCore::ClipboardQt::files):
337         * platform/qt/ClipboardQt.h:
338         * platform/win/ClipboardWin.cpp:
339         (WebCore::ClipboardWin::files):
340         * platform/win/ClipboardWin.h:
341         * platform/wx/ClipboardWx.cpp:
342         (WebCore::ClipboardWx::files):
343         * platform/wx/ClipboardWx.h:
344
345 2009-06-25  Eric Seidel  <eric@webkit.org>
346
347         No review, only completing revert of r45144.
348
349         Add back files deleted by r45144.
350
351         * storage/LocalStorageArea.cpp: Added.
352         (WebCore::LocalStorageArea::create):
353         (WebCore::LocalStorageArea::LocalStorageArea):
354         (WebCore::LocalStorageArea::scheduleFinalSync):
355         (WebCore::LocalStorageArea::itemChanged):
356         (WebCore::LocalStorageArea::itemRemoved):
357         (WebCore::LocalStorageArea::areaCleared):
358         (WebCore::LocalStorageArea::blockUntilImportComplete):
359         (WebCore::LocalStorageArea::dispatchStorageEvent):
360         * storage/LocalStorageArea.h: Added.
361         * storage/SessionStorageArea.cpp: Added.
362         (WebCore::SessionStorageArea::copy):
363         (WebCore::SessionStorageArea::SessionStorageArea):
364         (WebCore::SessionStorageArea::itemChanged):
365         (WebCore::SessionStorageArea::itemRemoved):
366         (WebCore::SessionStorageArea::areaCleared):
367         (WebCore::SessionStorageArea::blockUntilImportComplete):
368         (WebCore::SessionStorageArea::dispatchStorageEvent):
369         * storage/SessionStorageArea.h: Added.
370         (WebCore::SessionStorageArea::create):
371
372 2009-06-25  Eric Seidel  <eric@webkit.org>
373
374         No review, reverting r45144 only.
375
376         Roll out r45144 after 18 test failures appeared on the bots.
377         https://bugs.webkit.org/show_bug.cgi?id=26698
378
379         * GNUmakefile.am:
380         * WebCore.vcproj/WebCore.vcproj:
381         * WebCore.xcodeproj/project.pbxproj:
382         * WebCoreSources.bkl:
383         * storage/LocalStorage.cpp:
384         (WebCore::LocalStorage::storageArea):
385         * storage/LocalStorage.h:
386         * storage/SessionStorage.cpp:
387         (WebCore::SessionStorage::copy):
388         (WebCore::SessionStorage::storageArea):
389         * storage/SessionStorage.h:
390         * storage/StorageArea.cpp:
391         (WebCore::StorageArea::StorageArea):
392         (WebCore::StorageArea::~StorageArea):
393         (WebCore::StorageArea::setItem):
394         (WebCore::StorageArea::removeItem):
395         (WebCore::StorageArea::clear):
396         * storage/StorageArea.h:
397         * storage/StorageAreaSync.cpp:
398         (WebCore::StorageAreaSync::StorageAreaSync):
399         (WebCore::StorageAreaSync::scheduleFinalSync):
400         (WebCore::StorageAreaSync::syncTimerFired):
401         (WebCore::StorageAreaSync::performImport):
402         * storage/StorageAreaSync.h:
403         * storage/StorageSyncManager.h:
404
405 2009-06-24  Jeremy Orlow  <jorlow@chromium.org>
406
407         Reviewed by Darin Fisher.
408
409         https://bugs.webkit.org/show_bug.cgi?id=26698
410
411         Combined LocalStorageArea and SessionStorageArea into StorageArea since
412         (after my other refactorings) there are no longer substantial
413         differences between the two.
414
415         * GNUmakefile.am:
416         * WebCore.vcproj/WebCore.vcproj:
417         * WebCore.xcodeproj/project.pbxproj:
418         * WebCoreSources.bkl:
419         * storage/LocalStorage.cpp:
420         (WebCore::LocalStorage::storageArea):
421         * storage/LocalStorage.h:
422         * storage/LocalStorageArea.cpp: Removed.
423         * storage/LocalStorageArea.h: Removed.
424         * storage/SessionStorage.cpp:
425         (WebCore::SessionStorage::copy):
426         (WebCore::SessionStorage::storageArea):
427         * storage/SessionStorage.h:
428         * storage/SessionStorageArea.cpp: Removed.
429         * storage/SessionStorageArea.h: Removed.
430         * storage/StorageArea.cpp:
431         (WebCore::StorageArea::createLocalStorage):
432         (WebCore::StorageArea::StorageArea):
433         (WebCore::StorageArea::createSessionStorage):
434         (WebCore::StorageArea::copy):
435         (WebCore::StorageArea::setItem):
436         (WebCore::StorageArea::removeItem):
437         (WebCore::StorageArea::clear):
438         (WebCore::StorageArea::scheduleFinalSync):
439         (WebCore::StorageArea::blockUntilImportComplete):
440         (WebCore::StorageArea::dispatchStorageEvent):
441         * storage/StorageArea.h:
442         * storage/StorageAreaSync.cpp:
443         (WebCore::StorageAreaSync::StorageAreaSync):
444         (WebCore::StorageAreaSync::scheduleFinalSync):
445         (WebCore::StorageAreaSync::syncTimerFired):
446         (WebCore::StorageAreaSync::performImport):
447         * storage/StorageAreaSync.h:
448         * storage/StorageSyncManager.h:
449
450 2009-06-24  Dan Bernstein  <mitz@apple.com>
451
452         Reviewed by Simon Fraser.
453
454         - fix <rdar://problem/7001817> REGRESSION (r41902): Base position track
455           at UCSC Genome Browser doesn't work because image map prevents img
456           from hit-testing
457
458         Test: fast/replaced/image-map-2.html
459
460         * rendering/RenderImage.cpp:
461         (WebCore::RenderImage::nodeAtPoint): Do not reset 'inside' to false if
462         the image map failed the hit test.
463
464 2009-06-22  Adam Barth  <abarth@webkit.org>
465
466         Reviewed by Dimitri Glazkov.
467
468         https://bugs.webkit.org/show_bug.cgi?id=26366
469
470         Refactor V8DOMMap to support isolated worlds.
471
472         * bindings/v8/ScriptController.cpp:
473         (WebCore::ScriptController::evaluateInNewWorld):
474         * bindings/v8/ScriptController.h:
475         * bindings/v8/V8DOMMap.cpp:
476         (WebCore::DOMDataStore::InternalDOMWrapperMap::InternalDOMWrapperMap):
477         (WebCore::DOMDataStore::allStores):
478         (WebCore::DOMDataStore::allStoresMutex):
479         (WebCore::DOMDataStore::domData):
480         (WebCore::ScopedDOMDataStore::ScopedDOMDataStore):
481         (WebCore::ScopedDOMDataStore::~ScopedDOMDataStore):
482         (WebCore::StaticDOMDataStore::StaticDOMDataStore):
483         (WebCore::):
484         (WebCore::MainThreadDOMData::MainThreadDOMData):
485         (WebCore::MainThreadDOMData::getStore):
486         (WebCore::ChildThreadDOMData::ChildThreadDOMData):
487         (WebCore::ChildThreadDOMData::getStore):
488         (WebCore::DOMDataStore::DOMDataStore):
489         (WebCore::DOMDataStore::~DOMDataStore):
490         (WebCore::DOMDataStoreHandle::DOMDataStoreHandle):
491         (WebCore::DOMDataStoreHandle::~DOMDataStoreHandle):
492         (WebCore::::forget):
493         (WebCore::getDOMNodeMap):
494         (WebCore::getDOMObjectMap):
495         (WebCore::getActiveDOMObjectMap):
496         (WebCore::getDOMSVGElementInstanceMap):
497         (WebCore::getDOMSVGObjectWithContextMap):
498         (WebCore::DOMData::getCurrent):
499         (WebCore::DOMData::handleWeakObject):
500         (WebCore::DOMData::ensureDeref):
501         (WebCore::weakDOMObjectCallback):
502         (WebCore::weakActiveDOMObjectCallback):
503         (WebCore::weakNodeCallback):
504         (WebCore::weakSVGElementInstanceCallback):
505         (WebCore::weakSVGObjectWithContextCallback):
506         (WebCore::DOMData::derefObject):
507         (WebCore::DOMData::derefDelayedObjects):
508         (WebCore::DOMData::derefDelayedObjectsInCurrentThread):
509         (WebCore::DOMData::removeObjectsFromWrapperMap):
510         (WebCore::removeAllDOMObjectsInCurrentThreadHelper):
511         (WebCore::visitDOMNodesInCurrentThread):
512         (WebCore::visitDOMObjectsInCurrentThread):
513         (WebCore::visitActiveDOMObjectsInCurrentThread):
514         (WebCore::visitDOMSVGElementInstancesInCurrentThread):
515         (WebCore::visitSVGObjectsInCurrentThread):
516         * bindings/v8/V8DOMMap.h:
517         (WebCore::DOMDataStoreHandle::getStore):
518         * bindings/v8/V8IsolatedWorld.cpp: Added.
519         (WebCore::getIsolatedWorldKey):
520         (WebCore::contextWeakReferenceCallback):
521         (WebCore::V8IsolatedWorld::evaluate):
522         (WebCore::V8IsolatedWorld::V8IsolatedWorld):
523         (WebCore::V8IsolatedWorld::~V8IsolatedWorld):
524         (WebCore::V8IsolatedWorld::getEntered):
525         * bindings/v8/V8IsolatedWorld.h: Added.
526         (WebCore::V8IsolatedWorld::getDOMDataStore):
527
528 2009-06-24  Mikhail Naganov  <mnaganov@chromium.org>
529
530         Reviewed by Timothy Hatcher.
531
532         Bug 26604: Search doesn't work in Web Inspector Profiler
533         https://bugs.webkit.org/show_bug.cgi?id=26604
534
535         Seems like search was damaged in revision 42808.
536
537         * inspector/front-end/ProfileView.js:
538         (WebInspector.ProfileView.prototype.refresh):
539         Here and in other functions: nodes we're searching in are profile data grid
540         nodes, so there is no more need for '_dataGridNode' references.
541         (WebInspector.ProfileView.prototype.searchCanceled):
542         (WebInspector.ProfileView.prototype.performSearch.matchesQuery):
543         Fixed accidental semicolon that caused 'matchesQuery' always return true.
544         (WebInspector.ProfileView.prototype.performSearch):
545         To perform search correctly in the case of bottom up tree, we need to populate
546         the tree, because there's no 1-to-1 correspondence between profile nodes and
547         data grid nodes in this case.
548         (WebInspector.ProfileView.prototype._jumpToSearchResult):
549
550 2009-06-24  Simon Fraser  <simon.fraser@apple.com>
551
552         Reviewed by Darin Adler.
553         
554         <rdar://problem/6450239&6574516>
555     
556         Fix flashing issues caused by compositing layers rendering content before
557         a deferred layout has happened. Because the -viewWillDraw machinery doesn't
558         work for composited layers, we need to use scheduleViewUpdate() to queue
559         up a layout via the run loop observer in WebKit, whenever we know we
560         are going to be painting soon.
561
562         * rendering/RenderLayerBacking.cpp:
563         (WebCore::RenderLayerBacking::setContentsNeedDisplay):
564         (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
565
566 2009-06-24  David Levin  <levin@chromium.org>
567
568         Fix all builds.
569
570         * ForwardingHeaders/wtf/FastAllocBase.h: Added.
571
572 2009-06-24  Jeremy Orlow  <jorlow@chromium.org>
573
574         Reviewed by Darin Fisher.
575
576         https://bugs.webkit.org/show_bug.cgi?id=26658
577
578         Split the syncing portions of LocalStorageArea into StorageAreaSync.
579         This name will make more sense in the next patch (in this set) when
580         LocalStorageArea and SessionStorageArea are merged to become simply
581         StorageArea.  (Thus the synching portion of StorageArea is in
582         StorageAreaSync.)
583
584         This looks like a big patch, but really all it's doing is splitting
585         code and patching split-related things up.
586
587         * GNUmakefile.am:
588         * WebCore.vcproj/WebCore.vcproj:
589         * WebCore.xcodeproj/project.pbxproj:
590         * WebCoreSources.bkl:
591         * storage/LocalStorageArea.cpp:
592         (WebCore::LocalStorageArea::create):
593         (WebCore::LocalStorageArea::LocalStorageArea):
594         (WebCore::LocalStorageArea::scheduleFinalSync):
595         (WebCore::LocalStorageArea::itemChanged):
596         (WebCore::LocalStorageArea::itemRemoved):
597         (WebCore::LocalStorageArea::areaCleared):
598         (WebCore::LocalStorageArea::blockUntilImportComplete):
599         * storage/LocalStorageArea.h:
600         * storage/LocalStorageTask.cpp:
601         (WebCore::LocalStorageTask::LocalStorageTask):
602         * storage/LocalStorageTask.h:
603         (WebCore::LocalStorageTask::createImport):
604         (WebCore::LocalStorageTask::createSync):
605         * storage/LocalStorageThread.cpp:
606         (WebCore::LocalStorageThread::scheduleImport):
607         (WebCore::LocalStorageThread::scheduleSync):
608         * storage/LocalStorageThread.h:
609         * storage/SessionStorageArea.cpp:
610         (WebCore::SessionStorageArea::blockUntilImportComplete):
611         * storage/SessionStorageArea.h:
612         * storage/StorageArea.h:
613         * storage/StorageAreaSync.cpp: Copied from WebCore/storage/LocalStorageArea.cpp.
614         * storage/StorageAreaSync.h: Copied from WebCore/storage/LocalStorageArea.h.
615         * storage/StorageSyncManager.cpp:
616         (WebCore::StorageSyncManager::scheduleImport):
617         (WebCore::StorageSyncManager::scheduleSync):
618         * storage/StorageSyncManager.h:
619
620 2009-06-24  Adam Treat  <adam.treat@torchmobile.com>
621
622         Fix Qt build.
623
624         * WebCore.pro:
625
626 2009-06-24  David Levin  <levin@chromium.org>
627
628         Reviewed by David Hyatt.
629
630         Bug 26696: Member functions in DataGridColumnList should return pointers instead of PassRefPtr.
631         https://bugs.webkit.org/show_bug.cgi?id=26696
632
633         * html/DataGridColumnList.cpp:
634         (WebCore::DataGridColumnList::itemWithName):
635         (WebCore::DataGridColumnList::add):
636         * html/DataGridColumnList.h:
637         (WebCore::DataGridColumnList::item):
638         (WebCore::DataGridColumnList::primaryColumn):
639         (WebCore::DataGridColumnList::sortColumn):
640
641 2009-06-24  Sam Weinig  <sam@webkit.org>
642
643         Reviewed by Dave "Messy" Hyatt.
644
645         Little bit of style cleanup.
646
647         * html/DataGridColumn.cpp:
648         * html/DataGridColumn.h:
649         * html/DataGridColumn.idl:
650         * html/DataGridColumnList.cpp:
651         * html/DataGridColumnList.h:
652         * html/DataGridColumnList.idl:
653         * html/HTMLDataGridCellElement.cpp:
654         * html/HTMLDataGridCellElement.h:
655         * html/HTMLDataGridCellElement.idl:
656         * html/HTMLDataGridColElement.cpp:
657         * html/HTMLDataGridColElement.h:
658         * html/HTMLDataGridColElement.idl:
659         * html/HTMLDataGridElement.h:
660         * html/HTMLDataGridElement.idl:
661         * html/HTMLDataGridRowElement.cpp:
662         * html/HTMLDataGridRowElement.h:
663         * html/HTMLDataGridRowElement.idl:
664
665 2009-06-24  Chris Fleizach  <cfleizach@apple.com>
666
667         Reviewed by Oliver Hunt.
668
669         Bug 26668: AX: need a way to retrieve the language for an element
670         
671         Provides a way to retrieve the language associated with a specific accessibility element.
672
673         Test: accessibility/language-attribute.html
674
675         * accessibility/AccessibilityObject.cpp:
676         (WebCore::AccessibilityObject::language):
677         * accessibility/AccessibilityObject.h:
678         * accessibility/AccessibilityRenderObject.cpp:
679         (WebCore::AccessibilityRenderObject::language):
680         * accessibility/AccessibilityRenderObject.h:
681         * accessibility/mac/AccessibilityObjectWrapper.mm:
682         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
683
684 2009-06-24  Brady Eidson  <beidson@apple.com>
685
686         Reviewed by Dan Bernstein.
687         
688         <rdar://problem/6893811> Instead of downloading files linked from Google Earth, file contents displayed in browser window as text.
689
690         * platform/network/mac/WebCoreURLResponse.mm:
691         (createBinaryExtensionsSet): Add '.kmz' to the list of known-to-be-binary extensions.
692
693 2009-06-24  Nicolas Weber  <thakis@chromium.org>
694
695         Reviewed by Eric Seidel.
696
697         https://bugs.webkit.org/show_bug.cgi?id=26685
698         Accomodate for backwards-incompatible skia api changes.
699
700         * platform/graphics/skia/GraphicsContextSkia.cpp:
701         (WebCore::GraphicsContext::clearRect):
702         (WebCore::GraphicsContext::setCompositeOperation):
703         * platform/graphics/skia/ImageBufferSkia.cpp:
704         (WebCore::ImageBuffer::ImageBuffer):
705         * platform/graphics/skia/ImageSkia.cpp:
706         (WebCore::paintSkBitmap):
707         (WebCore::Image::drawPattern):
708         * platform/graphics/skia/PlatformContextSkia.cpp:
709         (PlatformContextSkia::State::State):
710         (PlatformContextSkia::setupPaintCommon):
711         (PlatformContextSkia::setXfermodeMode):
712         (PlatformContextSkia::applyClipFromImage):
713         * platform/graphics/skia/PlatformContextSkia.h:
714         * platform/graphics/skia/SkiaUtils.cpp:
715         (WebCore::):
716         (WebCore::WebCoreCompositeToSkiaComposite):
717         * platform/graphics/skia/SkiaUtils.h:
718
719 2009-06-24  Jan Michael Alonzo  <jmalonzo@webkit.org>
720
721         Gtk build fix. Add files that were added in r45093 and r45096
722
723         * GNUmakefile.am:
724
725 2009-06-24  Brady Eidson  <beidson@apple.com>
726
727         Fix 64-bit SnowLeopard build.
728
729         * html/DataGridColumnList.cpp:
730         (WebCore::DataGridColumnList::remove):
731         (WebCore::DataGridColumnList::move):
732
733 2009-06-24  Rob Buis  <rwlbuis@gmail.com>
734
735         Reviewed by Eric Seidel.
736
737         https://bugs.webkit.org/show_bug.cgi?id=26392
738         Bug 26392: In html, modification of xlink:href of an newly inserted svg image does not work.
739         https://bugs.webkit.org/show_bug.cgi?id=26328
740         Bug 26328: changing href attribute of svg images does not work when changing display attribute as well
741
742         React to href updates even when there is no renderer, i.e. display=none.
743
744         Tests: svg/custom/js-update-image-and-display.svg
745                svg/custom/js-update-image-and-display2.svg
746                svg/custom/js-update-image-and-display3.svg
747
748         * svg/SVGImageElement.cpp:
749         (WebCore::SVGImageElement::svgAttributeChanged):
750
751 2009-06-24  David Hyatt  <hyatt@apple.com>
752
753         Reviewed by Sam Weinig.
754
755         https://bugs.webkit.org/show_bug.cgi?id=26687
756
757         Add basic back-end column support to datagrid.
758
759         Added fast/dom/HTMLDataGridElement/ column tests.
760
761         * DerivedSources.cpp:
762         * DerivedSources.make:
763         * WebCore.pro:
764         * WebCore.vcproj/WebCore.vcproj:
765         * WebCore.xcodeproj/project.pbxproj:
766         * WebCoreSources.bkl:
767         * html/DataGridColumn.cpp: Added.
768         (WebCore::DataGridColumn::setPrimary):
769         * html/DataGridColumn.h: Added.
770         (WebCore::DataGridColumn::create):
771         (WebCore::DataGridColumn::id):
772         (WebCore::DataGridColumn::setId):
773         (WebCore::DataGridColumn::label):
774         (WebCore::DataGridColumn::setLabel):
775         (WebCore::DataGridColumn::type):
776         (WebCore::DataGridColumn::setType):
777         (WebCore::DataGridColumn::sortable):
778         (WebCore::DataGridColumn::setSortable):
779         (WebCore::DataGridColumn::sortDirection):
780         (WebCore::DataGridColumn::setSortDirection):
781         (WebCore::DataGridColumn::primary):
782         (WebCore::DataGridColumn::detachFromColumnList):
783         (WebCore::DataGridColumn::DataGridColumn):
784         * html/DataGridColumn.idl: Added.
785         * html/DataGridColumnList.cpp: Added.
786         (WebCore::DataGridColumnList::~DataGridColumnList):
787         (WebCore::DataGridColumnList::itemWithName):
788         (WebCore::DataGridColumnList::add):
789         (WebCore::DataGridColumnList::remove):
790         (WebCore::DataGridColumnList::move):
791         (WebCore::DataGridColumnList::clear):
792         (WebCore::DataGridColumnList::primaryColumnChanged):
793         * html/DataGridColumnList.h: Added.
794         (WebCore::DataGridColumnList::create):
795         (WebCore::DataGridColumnList::length):
796         (WebCore::DataGridColumnList::item):
797         (WebCore::DataGridColumnList::primaryColumn):
798         (WebCore::DataGridColumnList::sortColumn):
799         * html/DataGridColumnList.idl: Added.
800         * html/HTMLDataGridColElement.cpp:
801         (WebCore::HTMLDataGridColElement::sortable):
802         (WebCore::HTMLDataGridColElement::setSortable):
803         (WebCore::HTMLDataGridColElement::sortDirection):
804         (WebCore::HTMLDataGridColElement::setSortDirection):
805         * html/HTMLDataGridColElement.h:
806         * html/HTMLDataGridColElement.idl:
807         * html/HTMLDataGridElement.cpp:
808         (WebCore::HTMLDataGridElement::HTMLDataGridElement):
809         * html/HTMLDataGridElement.h:
810         (WebCore::HTMLDataGridElement::columns):
811         * html/HTMLDataGridElement.idl:
812         * rendering/RenderDataGrid.cpp:
813         (WebCore::RenderDataGrid::paintObject):
814         (WebCore::RenderDataGrid::paintColumnHeaders):
815         (WebCore::RenderDataGrid::rebuildColumns):
816         * rendering/RenderDataGrid.h:
817         (WebCore::RenderDataGrid::gridElement):
818
819 2009-06-24  Jessie Berlin  <jberlin@apple.com>
820
821         Reviewed by Adam Roben.
822
823         Partially fixes: https://bugs.webkit.org/show_bug.cgi?id=24735
824         (<rdar://problem/5015942>)
825         Where on windows it was not possible to set an element as the drag
826         image using setDragImage on the dataTransfer object.
827         
828         Does not "fix" the case of dragging a link where the default link image
829         is still used, even when the -webkit-user-drag is set to "element". This
830         is the same behavior as is found on OS X.
831         
832         Added a manual test because it is not possible to check that what is
833         contained in the image snapshot is indeed the requested element.
834
835         * dom/Clipboard.h:
836         (WebCore::Clipboard::dragImageElement):
837         Made getting the raw pointer from the RefPtr a const operation.
838         * manual-tests/drag-with-div-or-image-as-data-image.html: Added.
839         * platform/win/ClipboardWin.cpp:
840         (WebCore::ClipboardWin::createDragImage):
841         Get an image of the rendered element and its subtree.
842
843 2009-06-24  Darin Fisher  <darin@chromium.org>
844
845         Reviewed by David Levin.
846
847         https://bugs.webkit.org/show_bug.cgi?id=26683
848         Fix Chromium build bustage: Add custom binding for HTMLDataGridElement.dataSource
849
850         This change just adds a stub implementation for now to help fix the build.
851
852         * bindings/v8/custom/V8CustomBinding.h:
853         * bindings/v8/custom/V8HTMLDataGridElementCustom.cpp: Added.
854
855 2009-06-24  David Kilzer  <ddkilzer@apple.com>
856
857         Build fixes for ENABLE(PLUGIN_PROXY_FOR_VIDEO)
858
859         Reviewed by Adam Roben.
860
861         * html/HTMLMediaElement.cpp:
862         (WebCore::HTMLMediaElement::deliverNotification): Removed
863         ExceptionCode parameter from togglePlayState().
864         (WebCore::HTMLMediaElement::initialURL): Don't convert a KURL
865         object to a String when assigning to a KURL variable.
866
867 2009-06-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
868
869         Reviewed by Adam Treat.
870
871         Save memory by not storing attribute values in member variables, if not absolutely needed.
872         Also fixes bugs where we're substituting variables too early (noticeable with the upcoming <select> element).
873
874         * wml/WMLDoElement.cpp:
875         (WebCore::WMLDoElement::parseMappedAttribute):
876         (WebCore::WMLDoElement::label):
877         * wml/WMLDoElement.h:
878         * wml/WMLFieldSetElement.cpp:
879         (WebCore::WMLFieldSetElement::insertedIntoDocument):
880         * wml/WMLFieldSetElement.h:
881         * wml/WMLOptGroupElement.cpp:
882         (WebCore::WMLOptGroupElement::title):
883         (WebCore::WMLOptGroupElement::parseMappedAttribute):
884         (WebCore::WMLOptGroupElement::groupLabelText):
885         * wml/WMLOptGroupElement.h:
886         * wml/WMLPostfieldElement.cpp:
887         (WebCore::WMLPostfieldElement::name):
888         (WebCore::WMLPostfieldElement::value):
889         (WebCore::WMLPostfieldElement::encodeData):
890         * wml/WMLPostfieldElement.h:
891         * wml/WMLSetvarElement.cpp:
892         (WebCore::WMLSetvarElement::parseMappedAttribute):
893         (WebCore::WMLSetvarElement::name):
894         (WebCore::WMLSetvarElement::value):
895         * wml/WMLSetvarElement.h:
896         * wml/WMLTimerElement.cpp:
897         (WebCore::WMLTimerElement::parseMappedAttribute):
898         (WebCore::WMLTimerElement::insertedIntoDocument):
899         (WebCore::WMLTimerElement::timerFired):
900         (WebCore::WMLTimerElement::start):
901         (WebCore::WMLTimerElement::value):
902         * wml/WMLTimerElement.h:
903
904 2009-06-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
905
906         Reviewed by Adam Roben.
907
908         Forgot to initialize m_task member variable. Results in crashes sometimes.
909
910         * wml/WMLAnchorElement.cpp:
911         (WebCore::WMLAnchorElement::WMLAnchorElement):
912
913 2009-06-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
914
915         Not reviewed. Forgot to include within last patch.
916
917         * manual-tests/wml/card-title-attr.wml: Added.
918
919 2009-06-24  Wajahat Siddiqui <wajahatmeister@gmail.com>
920  
921         Reviewed by Nikolas Zimmermann.
922
923         Fixes: https://bugs.webkit.org/show_bug.cgi?id=26474
924         Adding WML <card> title attribute handling.
925
926         * wml/WMLElement.h: marking parseValueSubstitutingVariableReferences and parseValueForbiddingVariableReferences as const
927         * wml/WMLElement.cpp:
928         * wml/WMLCardElement.h: 
929         (WebCore::WMLCardElement::title):
930         * wml/WMLCardElement.cpp:
931         * wml/manual-test/card-title-attr.wml: Manual test  
932  
933 2009-06-24  Simon Hausmann  <simon.hausmann@nokia.com>
934
935         Reviewed by Tor Arne Vestbø.
936
937         Fix the build without ENABLE_VIDEO.
938
939         * html/CanvasRenderingContext2D.cpp: Add #if ENABLE guards.
940         * html/CanvasRenderingContext2D.h: Ditto.
941
942 2009-06-24  Siddhartha Chattopadhyay  <sidchat@google.com>
943
944         Reviewed by Eric Seidel.
945
946         Fix for https://bugs.webkit.org/show_bug.cgi?id=26200 which I introduced earlier. I had
947         the smartReplace set TRUE initially, which was wrong since the purpose of this call is
948         to just replace the selection, and place the caret at the end of the selection it replaced.
949
950         * editing/Editor.cpp:
951         (WebCore::Editor::markMisspellingsAfterTypingToPosition):
952         * manual-tests/textarea-caret-position-after-auto-spell-correct.html: Added.
953
954 2009-06-24  Kevin Watters  <kevinwatters@gmail.com>
955
956         Reviewed by Kevin Ollivier.
957
958         Don't use an unsigned int for intervalInMS because we sometimes initialize
959         it with a negative value.
960
961         * platform/wx/SharedTimerWx.cpp:
962         (WebCore::setSharedTimerFireTime):
963
964 2009-06-24  Eric Seidel  <eric@webkit.org>
965
966         No review, build fix only.
967
968         The previous checkin had an improper merge.  This fixes the build.
969
970         * page/DragController.cpp:
971         (WebCore::DragController::tryDocumentDrag):
972
973 2009-06-05  Eric Seidel  <eric@webkit.org>
974
975         Reviewed by Oliver Hunt.
976
977         https://bugs.webkit.org/show_bug.cgi?id=25922
978         JS setting dropEffect = "none" causes tryDHTMLDrag
979         to return DragOperationNone.  Which is also the value
980         tryDHTMLDrag previously used to indicate JS did not
981         want to handle the drag.
982
983         Make it possible for the DragController::try* methods
984         to return a bool to indicate if javascript accepted
985         or rejected the drag event, separate from the DragOperation.
986
987         Tests:
988         - fast/events/drag-to-navigate.html
989         - fast/events/prevent-drag-to-navigate.html
990
991         * page/DragController.cpp:
992         (WebCore::DragController::dragEnteredOrUpdated):
993         (WebCore::DragController::tryDocumentDrag):
994         (WebCore::defaultOperationForDrag):
995         (WebCore::DragController::tryDHTMLDrag):
996         * page/DragController.h:
997
998 2009-06-23  Oliver Hunt  <oliver@apple.com> and Eric Carlson  <eric.carlson@apple.com>
999
1000         Reviewed by Sam Weinig and Dave Hyatt.
1001
1002         <rdar://problem/6164797> Add Canvas API to allow drawing of <video> frames
1003         <https://bugs.webkit.org/show_bug.cgi?id=25920>
1004
1005         Add support for drawing the contents of the video element to the canvas
1006         in accordance with the current HTML5 draft.
1007
1008         Test: media/video-canvas.html
1009
1010         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
1011         (WebCore::JSCanvasRenderingContext2D::drawImage):
1012           Standard custom bindings stuff we need to do for all canvas methods.
1013         * html/CanvasRenderingContext2D.cpp:
1014         (WebCore::size): Helper function for finding the size of a video element
1015         (WebCore::CanvasRenderingContext2D::checkOrigin): moved up in the file.
1016         (WebCore::CanvasRenderingContext2D::drawImage): The various overloads of HTML5's drawImage(<video>)
1017         * html/CanvasRenderingContext2D.h:
1018         * html/HTMLMediaElement.h:
1019         (WebCore::HTMLMediaElement::hasSingleSecurityOrigin):
1020           hasSingleSecurityOrigin is needed for security, currently all implementations are trivial
1021           as we force QT to maintain a single origin.
1022         * html/HTMLVideoElement.cpp:
1023         (WebCore::HTMLVideoElement::paint): 
1024             Paint routine on video so we don't have to look at MediaPlayer directly
1025         * html/HTMLVideoElement.h:
1026         * platform/graphics/MediaPlayer.cpp:
1027         (WebCore::NullMediaPlayerPrivate::hasSingleSecurityOrigin):
1028         (WebCore::MediaPlayer::hasSingleSecurityOrigin):
1029             Default implementations of hasSingleSecurityOrigin
1030         * platform/graphics/MediaPlayer.h:
1031         * platform/graphics/MediaPlayerPrivate.h:
1032         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
1033         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1034         (WebCore::MediaPlayerPrivate::setUpVideoRendering):
1035             A video may need a player now even if it is not visible.
1036         (WebCore::MediaPlayerPrivate::hasSingleSecurityOrigin):
1037             Always return true due to restrictions we've placed on QT.
1038         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
1039         (WebCore::MediaPlayerPrivate::paint):
1040             Jump through some hoops to allow windows QT to draw to an intermediate buffer.
1041             In the long term we'd like to cache the HDC, but this will do for now.
1042         (WebCore::MediaPlayerPrivate::hasSingleSecurityOrigin):
1043         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
1044             As for Mac we force QT to only allow same origin loads.
1045
1046 2009-06-23  Adam Langley  <agl@google.com>
1047
1048         Reviewed by Eric Seidel.
1049
1050         Chromium: Fix crash with inherited font-size in <option>
1051
1052         https://bugs.webkit.org/show_bug.cgi?id=26656
1053         http://code.google.com/p/chromium/issues/detail?id=14853
1054
1055         In r42597 (https://bugs.webkit.org/show_bug.cgi?id=25244), I changed
1056         the <select> handing for Chromium to fix a rendering bug. However,
1057         although the font-size is correctly ignored, getRowHeight wasn't
1058         updated and so was calculating the height of the rows in an
1059         inconsistent manner. This can lead to a crash.
1060
1061         * manual-tests/optgroup-empty-and-nested.html: adding test case for crash
1062         * platform/chromium/PopupMenuChromium.cpp:
1063         (WebCore::PopupListBox::getRowHeight):
1064
1065 2009-06-23  Brady Eidson  <beidson@apple.com>
1066
1067         Patch by Antti Koivisto.
1068         Reviewed by Brady Eidson.
1069
1070         <rdar://problem/6988010> Failed resources not reloaded when built against Tiger SDK
1071
1072         A latent bug that cache revalidation uncovered.  When a CachedResource failed to load,
1073         it should always be revalidated upon reload.
1074
1075         * loader/CachedResource.cpp:
1076         (WebCore::CachedResource::canUseCacheValidator):
1077         (WebCore::CachedResource::mustRevalidate):
1078
1079 2009-06-23  Dan Bernstein  <mitz@apple.com>
1080
1081         Reviewed by Darin Adler.
1082
1083         - fix <rdar://problem/6634228> Crash in [NSScroller mouseDown:] beneath
1084           EventHandler::passMouseDownEventToWidget()
1085
1086         * page/mac/EventHandlerMac.mm:
1087         (WebCore::EventHandler::passMouseDownEventToWidget): Surround the
1088         -mouseDown: call with calls to Widget::beforeMouseDown() and
1089         Widget::afterMouseDown(), which prevent the widget's view hierarchy from
1090         being removed from its parent view while the scroller is tracking the
1091         mouse.
1092
1093 2009-06-23  Sam Weinig  <sam@webkit.org>
1094
1095         Reviewed by Dave Hyatt.
1096
1097         Fix for https://bugs.webkit.org/show_bug.cgi?id=26516
1098         Add initial implementation of DataGridDataSource
1099
1100         - Initial implementation only supports the initialize callback function.
1101
1102         Test: fast/dom/HTMLDataGridElement/DataGridDataSource-basic.html
1103
1104         * WebCore.xcodeproj/project.pbxproj:
1105         * GNUmakefile.am:
1106         * WebCore.pro:
1107         * WebCore.vcproj/WebCore.vcproj:
1108         * WebCore.xcodeproj/project.pbxproj:
1109         * WebCoreSources.bkl:
1110         * bindings/js/JSDataGridDataSource.cpp: Added.
1111         (WebCore::JSDataGridDataSource::JSDataGridDataSource):
1112         (WebCore::JSDataGridDataSource::~JSDataGridDataSource):
1113         (WebCore::JSDataGridDataSource::initialize):
1114         * bindings/js/JSDataGridDataSource.h: Added.
1115         (WebCore::JSDataGridDataSource::create):
1116         (WebCore::JSDataGridDataSource::isJSDataGridDataSource):
1117         (WebCore::JSDataGridDataSource::jsDataSource):
1118         (WebCore::asJSDataGridDataSource):
1119         * bindings/js/JSHTMLDataGridElementCustom.cpp: Added.
1120         (WebCore::JSHTMLDataGridElement::listener):
1121         (WebCore::JSHTMLDataGridElement::setListener):
1122         * html/DataGridDataSource.h: Added.
1123         (WebCore::DataGridDataSource::~DataGridDataSource):
1124         (WebCore::DataGridDataSource::isJSDataGridDataSource):
1125         * html/HTMLDataGridElement.cpp:
1126         (WebCore::HTMLDataGridElement::HTMLDataGridElement):
1127         (WebCore::HTMLDataGridElement::setDataSource):
1128         (WebCore::HTMLDataGridElement::initializationTimerFired):
1129         * html/HTMLDataGridElement.h:
1130         (WebCore::HTMLDataGridElement::dataSource):
1131         * html/HTMLDataGridElement.idl:
1132
1133 2009-06-23  Ryosuke Niwa  <rniwa@google.com>
1134
1135         Reviewed by Justin Garcia.
1136
1137         Undo the changeset 21212 to fix the regression bug 14062.
1138         The changeset 21212 attempted to fix rdar://problem/5002441.
1139         The changeset 21212 modified InsertTextCommand::input so as to convert
1140         all spaces in text to non-breaking spaces for rdar://problem/5002441.
1141         However, the bug was originally caused by rebalanceWhitespaceAt
1142         and this workaround introduced a regression bug 14062.
1143         Because rebalanceWhitespaceAt appears to behave correctly now,
1144         the workaround introduced in 21212 is no longer needed.
1145
1146         Test: editing/inserting/space-after-removeformat.html
1147
1148         * editing/InsertTextCommand.cpp:
1149         (WebCore::InsertTextCommand::input):
1150
1151 2009-06-23  Beth Dakin  <bdakin@apple.com>
1152
1153         Reviewed by Dave Hyatt.
1154
1155         Fix for https://bugs.webkit.org/show_bug.cgi?id=26523 <col> 
1156         elements width can't be changed with javascript
1157
1158         This patch both fixes setting the width attribute directly in 
1159         JavaScript, and setting the width on the style attribute. 
1160
1161         * html/HTMLTableColElement.cpp:
1162         (WebCore::HTMLTableColElement::parseMappedAttribute): If we have a 
1163         new width, call setNeedsLayoutAndPrefWidthsRecalc()
1164
1165         Call calcPrefWidths() on the table cols.
1166         * rendering/AutoTableLayout.cpp:
1167         (WebCore::AutoTableLayout::recalcColumn):
1168         * rendering/FixedTableLayout.cpp:
1169         (WebCore::FixedTableLayout::calcWidthArray):
1170         
1171         Call layoutIfNeeded on the table cols.
1172         * rendering/RenderTable.cpp:
1173         (WebCore::RenderTable::layout):
1174
1175         * rendering/RenderTableCol.cpp:
1176         (WebCore::RenderTableCol::clippedOverflowRectForRepaint): Use new 
1177         table() convenience function.
1178         (WebCore::RenderTableCol::calcPrefWidths): Just call 
1179         setPrefWidthsDirty(false) on ourself and our children.
1180         (WebCore::RenderTableCol::table):
1181         * rendering/RenderTableCol.h:
1182
1183 2009-06-23  Ojan Vafai  <ojan@chromium.org>
1184
1185         Reviewed by Dan Bernstein.
1186
1187         Add logic to CSSStyleDeclaration::diff to deal with font-sizes that are 
1188         keyword values. When diff is called on a CSSStyleDeclaration, we check
1189         the keywordSize to see if font-size matches a keyword value.
1190         
1191         This ensures that when we diff a CSSMutableStyleDeclaration returned from
1192         copyInheritableProperties on a CSSComputedStyleDeclaration that we 
1193         correctly identify matching font-sizes.
1194         
1195         https://bugs.webkit.org/show_bug.cgi?id=26279
1196
1197         Test: editing/inserting/font-size-clears-from-typing-style.html
1198
1199         * css/CSSComputedStyleDeclaration.cpp:
1200         (WebCore::CSSComputedStyleDeclaration::cssPropertyMatches):
1201         * css/CSSComputedStyleDeclaration.h:
1202         * css/CSSStyleDeclaration.cpp:
1203         (WebCore::CSSStyleDeclaration::cssPropertyMatches):
1204         (WebCore::CSSStyleDeclaration::diff):
1205         * css/CSSStyleDeclaration.h:
1206
1207 2009-06-23  Kevin McCullough  <kmccullough@apple.com>
1208
1209         Reviewed by Darin Adler.
1210
1211         <rdar://problem/6994790> CrashTracer: [USER] 8 crashes in Mail trying to
1212         add a blank line to pasted Facebook content (under
1213         CompositeEditCommand::positionAvoidingSpecialElementBoundary)
1214
1215         - Just added null checks and I will create a new bug to prevent the
1216         bad behavior.
1217
1218         * editing/CompositeEditCommand.cpp:
1219         (WebCore::CompositeEditCommand::positionAvoidingSpecialElementBoundary):
1220
1221 2009-06-23  Simon Fraser  <simon.fraser@apple.com>
1222
1223         Build fix.
1224
1225         Wrap shouldDoSoftwarePaint() in #if USE(ACCELERATED_COMPOSITING) to avoid warning when 
1226         ACCELERATED_COMPOSITING is not defined.
1227
1228         * rendering/RenderLayer.cpp:
1229
1230 2009-06-23  Simon Fraser  <simon.fraser@apple.com>
1231
1232         Reviewed by Dave Hyatt.
1233         
1234         https://bugs.webkit.org/show_bug.cgi?id=24863
1235         
1236         Fix reflection painting on elements with compositing layers.
1237
1238         Test: compositing/reflections/reflection-on-composited.html
1239
1240         * rendering/RenderLayer.h:
1241         Add a new PaintLayerPaintingReflection flag which is set while painting inside
1242         reflections.
1243         (WebCore::RenderLayer::setPaintingInsideReflection):
1244         Add a setter so that RenderLayerBacking can call it.
1245
1246         * rendering/RenderLayer.cpp:
1247         (WebCore::shouldDoSoftwarePaint):
1248         Utility to clarify the logic of when a composited layer should do a software paint.
1249         
1250         (WebCore::RenderLayer::paintLayer):
1251         Use shouldDoSoftwarePaint() to determine when to software-paint a reflected layer.
1252         Remove transform-related tests from the reflection-painting if test because they appear
1253         to be unnecessary.
1254
1255         * rendering/RenderLayerBacking.cpp:
1256         (WebCore::RenderLayerBacking::paintIntoLayer):
1257         Add the code to paint reflections to the composited layer painting method.
1258         
1259         * rendering/RenderReplica.cpp:
1260         (WebCore::RenderReplica::paint):
1261         Set the PaintLayerPaintingReflection flag.
1262
1263 2009-06-23  Antti Koivisto  <antti@apple.com>
1264
1265         Reviewed by Darin Adler.
1266         
1267         https://bugs.webkit.org/show_bug.cgi?id=26643
1268         Memory cache should respect Cache-Control: no-store
1269         
1270         Make resources with Cache-Control: no-store uncacheable in the memory cache.
1271         They get evicted immediately when all clients are gone and are always
1272         reloaded from the server.
1273
1274         Conforms to RFC2616 14.9.2 and seems also match Firefox behavior.
1275
1276         * loader/CachedResource.cpp:
1277         (WebCore::CachedResource::removeClient):
1278         (WebCore::CachedResource::canUseCacheValidator):
1279         (WebCore::CachedResource::mustRevalidate):
1280         * platform/network/ResourceResponseBase.cpp:
1281         (WebCore::ResourceResponseBase::ResourceResponseBase):
1282         (WebCore::ResourceResponseBase::parseCacheControlDirectives):
1283         (WebCore::ResourceResponseBase::cacheControlContainsNoStore):
1284         * platform/network/ResourceResponseBase.h:
1285
1286 2009-06-23  Brady Eidson  <beidson@apple.com>
1287
1288         Windows build fix.
1289
1290         * platform/graphics/win/QTMovieWin.cpp:
1291         (QTMovieWin::play):
1292         (QTMovieWin::pause):
1293         (QTMovieWin::setRate):
1294         (QTMovieWin::setCurrentTime):
1295
1296 2009-06-23  Kevin McCullough  <kmccullough@apple.com>
1297
1298         Reviewed by Adele Peterson.
1299
1300         <rdar://problem/6902203> REGRESSION: 'Return' insertion point incorrect
1301         after manually quoting blank line then hitting return
1302
1303         If the insertion point is both the begining and ending visible position
1304         then we need to insert at the end instead of the begining, which is what
1305         would normally happen if the insertion point was as the begining.
1306
1307         * editing/BreakBlockquoteCommand.cpp:
1308         (WebCore::BreakBlockquoteCommand::doApply):
1309
1310 2009-06-23  Brady Eidson  <beidson@apple.com>
1311
1312         Reviewed by Sam Weinig, and looked over by Eric Carlson.
1313
1314         <rdar://problem/6980466> Media elements should provide option for changing pitch correction
1315
1316         Introduce a new boolean property to HTMLMediaElement called webkitPreservesPitch for script to control this.
1317
1318         * html/HTMLMediaElement.cpp:
1319         (WebCore::HTMLMediaElement::HTMLMediaElement): Currently the platforms that have a flexible pitch preservation 
1320           property (Quicktime on Mac and Win) have had it on by default, so continue that default for now.
1321         (WebCore::HTMLMediaElement::loadResource):
1322         (WebCore::HTMLMediaElement::webkitPreservesPitch):
1323         (WebCore::HTMLMediaElement::setWebkitPreservesPitch):
1324         * html/HTMLMediaElement.h:
1325         * html/HTMLMediaElement.idl:
1326
1327         * platform/graphics/MediaPlayer.cpp:
1328         (WebCore::NullMediaPlayerPrivate::setPreservesPitch):
1329         (WebCore::MediaPlayer::MediaPlayer):
1330         (WebCore::MediaPlayer::preservesPitch):
1331         (WebCore::MediaPlayer::setPreservesPitch):
1332         * platform/graphics/MediaPlayer.h:
1333         * platform/graphics/MediaPlayerPrivate.h:
1334         (WebCore::MediaPlayerPrivateInterface::setPreservesPitch):
1335
1336         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
1337         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1338         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
1339         (WebCore::MediaPlayerPrivate::createQTMovie): Rework to allow recreation of the movie with almost the
1340           exact same attributes as before, with pitch preservation being the difference.
1341         (WebCore::MediaPlayerPrivate::setPreservesPitch): Recreate the QTMovie if the flag actually changes.
1342         (WebCore::MediaPlayerPrivate::updateStates): Restore current time and rate if this is a recreated movie.
1343         (WebCore::MediaPlayerPrivate::timeChanged): Clear the time-to-be-restored, as this callback means it
1344           has been effectively overwritten.
1345
1346         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
1347         (WebCore::MediaPlayerPrivate::load):
1348         (WebCore::MediaPlayerPrivate::setPreservesPitch):
1349         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
1350         * platform/graphics/win/QTMovieWin.cpp:
1351         (QTMovieWinPrivate::QTMovieWinPrivate):
1352         (QTMovieWinPrivate::~QTMovieWinPrivate):
1353         (QTMovieWinPrivate::task): Restore current time and rate if this is a re-created movie.
1354         (QTMovieWin::play): Clear the time-to-be-restored, as this effectively overwrites it.
1355         (QTMovieWin::pause): Ditto.
1356         (QTMovieWin::setRate): Ditto.
1357         (QTMovieWin::setCurrentTime): Ditto.
1358         (QTMovieWin::setPreservesPitch): Recreate the Movie if the flag actually changes.
1359         (QTMovieWin::load): Rework to allow recreation of the Movie with similar state as the movie before it, 
1360           but changing the pitch preservation flag.
1361         * platform/graphics/win/QTMovieWin.h:
1362
1363 2009-06-23  Eric Carlson  <eric.carlson@apple.com>
1364
1365         Reviewed by Simon Fraser.
1366
1367         <rdar://problem/6998286> Crash after leaving page with <video>
1368         
1369         Don't try to post events after going into the page cache.
1370
1371         * html/HTMLMediaElement.cpp:
1372         (WebCore::HTMLMediaElement::documentWillBecomeInactive): Cancel pending events and stop
1373         event timers so we won't try to post events after going into the cache.
1374
1375 2009-06-23  Jeremy Orlow  <jorlow@chromium.org>
1376
1377         Reviewed by Brady Eidson.
1378
1379         Simplify the interaction between LocalStorageArea/SessionStorageArea
1380         and StorageArea by creating a "blockUntilImportComplete()" function
1381         rather than bouncing back and forth between the child and parent
1382         classes in a somewhat unintuitive manner.
1383
1384         This patch also paves the way for LocalStorageArea and
1385         SessionStorageArea being merged into one.  It's part of several in a
1386         set which are separating syncing (to disk) code from the rest of the
1387         implementation so that local storage and session storage's code can be
1388         unified.
1389
1390         https://bugs.webkit.org/show_bug.cgi?id=25376
1391
1392         * storage/LocalStorageArea.cpp:
1393         (WebCore::LocalStorageArea::blockUntilImportComplete):
1394         * storage/LocalStorageArea.h:
1395         * storage/StorageArea.cpp:
1396         (WebCore::StorageArea::length):
1397         (WebCore::StorageArea::key):
1398         (WebCore::StorageArea::getItem):
1399         (WebCore::StorageArea::setItem):
1400         (WebCore::StorageArea::removeItem):
1401         (WebCore::StorageArea::clear):
1402         (WebCore::StorageArea::contains):
1403         * storage/StorageArea.h:
1404         (WebCore::StorageArea::blockUntilImportComplete):
1405
1406 2009-06-23  Simon Fraser  <simon.fraser@apple.com>
1407
1408         Reviewed by Dave Hyatt
1409
1410         First part of https://bugs.webkit.org/show_bug.cgi?id=26652
1411         
1412         * rendering/RenderLayer.cpp:
1413         (WebCore::RenderLayer::paint):
1414         (WebCore::RenderLayer::paintLayer):
1415         * rendering/RenderLayer.h:
1416         (WebCore::RenderLayer::):
1417         * rendering/RenderReplica.cpp:
1418         (WebCore::RenderReplica::paint):
1419         Replace the 3 boolean params to RenderLayer::paintLayer() with a bit mask for readability.
1420         
1421         * rendering/RenderLayerBacking.cpp:
1422         (WebCore::RenderLayerBacking::paintIntoLayer):
1423         (WebCore::RenderLayerBacking::paintContents):
1424         * rendering/RenderLayerBacking.h:
1425         Remove the unused 'haveTransparency' param to paintIntoLayer().
1426
1427 2009-06-23  Simon Fraser  <simon.fraser@apple.com>
1428
1429         Reviewed by Darin Adler.
1430
1431         <rdar://problem/6997929> Assertion at WebCore::RenderLayer::updateClipRects with hardware acceleration
1432
1433         The updatingControlTints() painting pass goes through compositing layer boundaries,
1434         so we need to ensure we don't cache clip rects computed with the wrong root by
1435         setting temporaryClipRects to true.
1436         
1437         * rendering/RenderLayer.cpp:
1438         (WebCore::RenderLayer::paintLayer):
1439         
1440         * rendering/RenderLayerBacking.cpp:
1441         (WebCore::RenderLayerBacking::contentOffsetInCompostingLayer):
1442         Remove a printf that I left in by mistake.
1443
1444 2009-06-23  Anders Carlsson  <andersca@apple.com>
1445
1446         Reviewed by Darin Adler.
1447
1448         WebCore side of <rdar://problem/6946094>.
1449         
1450         * platform/win/ClipboardWin.cpp:
1451         (WebCore::ClipboardWin::setExternalDataObject):
1452         * platform/win/ClipboardWin.h:
1453
1454 2009-06-23  Darin Fisher  <darin@chromium.org>
1455
1456         Reviewed by Darin Adler.
1457
1458         https://bugs.webkit.org/show_bug.cgi?id=26650
1459
1460         Add setFormContentType and setFormData since it is awkward for Chromium
1461         to use setFormInfoFromRequest to set the underlying members.  Also, add
1462         a clearChildren method that Chromium needs.  These methods are used as
1463         part of the Chromium code that serializes a HistoryItem for storing in
1464         the browser's session history.
1465
1466         * history/HistoryItem.cpp:
1467         * history/HistoryItem.h:
1468
1469 2009-06-23  Eric Carlson  <eric.carlson@apple.com>
1470
1471         Reviewed by Darin Adler.
1472
1473         <rdar://problem/6978938> Need HTML 5 event attributes for media elements
1474
1475         Test: media/event-attributes.html
1476
1477         * html/HTMLAttributeNames.in: Add media event attribute names.
1478         * html/HTMLMediaElement.cpp:
1479         (WebCore::HTMLMediaElement::parseMappedAttribute): Handle media event attributes.
1480
1481 2009-06-23  Thiago Macieira  <thiago.macieira@nokia.com>
1482
1483         Reviewed by Simon Hausmann.
1484
1485         Fix Qt build with Phonon.
1486
1487         The #include <phonon> header no longer exists. And the <Phonon> or
1488         <Phonon/Phonon> headers have never existed (neither for us nor for the
1489         Phonon sources). You have to select each and every header that you do
1490         want now.
1491
1492         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
1493
1494 2009-06-23  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
1495
1496         Reviewed by Simon Hausmann.
1497
1498         Remove duplicated code in Qt & GTK logging initialization
1499
1500         We now share the getChannelFromName() function in Logging.cpp
1501
1502         * platform/gtk/LoggingGtk.cpp:
1503         * platform/qt/LoggingQt.cpp:
1504
1505 2009-06-23  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
1506
1507         Reviewed by Simon Hausmann.
1508
1509         Rename the plugin logging channel to plural form 'Plugins'
1510
1511         This matches both the other logging channel names, as well as the
1512         WebKit logging channel used by Safari/Mac for plugins.
1513
1514         * platform/Logging.cpp:
1515         * platform/Logging.h:
1516         * platform/gtk/LoggingGtk.cpp:
1517         * platform/mac/LoggingMac.mm:
1518         * platform/qt/LoggingQt.cpp:
1519         * platform/win/LoggingWin.cpp:
1520         * plugins/PluginDebug.h:
1521         * plugins/gtk/PluginPackageGtk.cpp:
1522         * plugins/mac/PluginPackageMac.cpp:
1523         * plugins/mac/PluginViewMac.cpp:
1524         * plugins/qt/PluginPackageQt.cpp:
1525
1526 2009-06-23  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
1527
1528         Reviewed by Simon Hausmann.
1529
1530         Fix NPAPI mouse translation issues on Mac
1531
1532         The WindowRef we pass to the plugin refers to the the top level window,
1533         so the x and y positions have to be relative to this position, but we
1534         have to manually compensate for title bar decorations and other parents
1535         of the QWebView since contentsToWindow() only traverses to the QWebView.
1536
1537         Previously we did this compensation when passing on mouse coordinates to
1538         the plugin, which caused various issues with translations such as not
1539         being able to close the Flash settings dialog, or the hand cursor not
1540         appearing over links.
1541
1542         We now do the compensation as part of the call to NPP_SetWindow, and
1543         then pass mouse coordinates in global context without any compensation,
1544         similar to how both Safari and Mozilla does it.
1545
1546         * plugins/mac/PluginViewMac.cpp:
1547         (WebCore::PluginView::updatePluginWidget):
1548         (WebCore::PluginView::globalMousePosForPlugin):
1549
1550 2009-06-23  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
1551
1552         Rubber-stamped by Simon Hausmann.
1553
1554         [Qt] Resolve absolute path to library install_name manually
1555
1556         Since our target.path is set to the Qt directory (to be able
1557         to do 'make install') the 'absolute_library_soname' option
1558         to QMake did not do the right thing.
1559
1560         We now compute the absolute path manually using DESTDIR.
1561
1562         * WebCore.pro:
1563
1564 2009-06-22  Simon Fraser  <simon.fraser@apple.com>
1565
1566         Reviewed by Oliver Hunt.
1567
1568         <rdar://problem/6991146> Scrollbars in hardware layers don't change to the
1569         inactive look in background windows
1570
1571         * rendering/RenderLayer.cpp:
1572         (WebCore::RenderLayer::paintLayer):
1573         Don't short-circuit the "painting" pass that is used to udpate control tints.
1574
1575 2009-06-22  Dimitri Glazkov  <dglazkov@chromium.org>
1576
1577         Reviewed by Sam Weinig.
1578
1579         https://bugs.webkit.org/show_bug.cgi?id=26567
1580         Upstream V8 bindings code generator. With this change, also added interface ancestor
1581         traversal to IDL parser, which is necessary for V8 bindings. The traversal is used
1582         to determine whether an interface is a Node to facilitate proper casting and storage
1583         in V8DOMMap.
1584
1585         * bindings/scripts/CodeGenerator.pm: Added parent traversal sub, needed
1586             by V8 bindings.
1587         * bindings/scripts/CodeGeneratorV8.pm: Added.
1588         * bindings/scripts/IDLParser.pm: Modified to allow limited parsing for
1589             parent traversal cases.
1590
1591 2009-06-22  Sam Weinig  <sam@webkit.org>
1592
1593         Reviewed by Gavin Barraclough.
1594
1595         Add event handler attribute getter/setters to HTMLFrameSetElement
1596         as specified in HTML 5.  These match the ones on HTMLBodyElement.
1597
1598         * dom/Node.h:
1599         * html/HTMLFrameSetElement.cpp:
1600         (WebCore::HTMLFrameSetElement::parseMappedAttribute):
1601         (WebCore::HTMLFrameSetElement::onblur):
1602         (WebCore::HTMLFrameSetElement::setOnblur):
1603         (WebCore::HTMLFrameSetElement::onerror):
1604         (WebCore::HTMLFrameSetElement::setOnerror):
1605         (WebCore::HTMLFrameSetElement::onfocus):
1606         (WebCore::HTMLFrameSetElement::setOnfocus):
1607         (WebCore::HTMLFrameSetElement::onload):
1608         (WebCore::HTMLFrameSetElement::setOnload):
1609         (WebCore::HTMLFrameSetElement::onbeforeunload):
1610         (WebCore::HTMLFrameSetElement::setOnbeforeunload):
1611         (WebCore::HTMLFrameSetElement::onmessage):
1612         (WebCore::HTMLFrameSetElement::setOnmessage):
1613         (WebCore::HTMLFrameSetElement::onoffline):
1614         (WebCore::HTMLFrameSetElement::setOnoffline):
1615         (WebCore::HTMLFrameSetElement::ononline):
1616         (WebCore::HTMLFrameSetElement::setOnonline):
1617         (WebCore::HTMLFrameSetElement::onresize):
1618         (WebCore::HTMLFrameSetElement::setOnresize):
1619         (WebCore::HTMLFrameSetElement::onstorage):
1620         (WebCore::HTMLFrameSetElement::setOnstorage):
1621         (WebCore::HTMLFrameSetElement::onunload):
1622         (WebCore::HTMLFrameSetElement::setOnunload):
1623         * html/HTMLFrameSetElement.h:
1624         * html/HTMLFrameSetElement.idl:
1625
1626 2009-06-22  Darin Adler  <darin@apple.com>
1627
1628         Reviewed by Sam Weinig.
1629
1630         Bug 25425: DOM attribute getter/setter functions should use const AtomicString& type
1631         https://bugs.webkit.org/show_bug.cgi?id=25425
1632
1633         * bindings/scripts/CodeGeneratorJS.pm: Added handling for ReflectURL.
1634         * bindings/scripts/CodeGeneratorObjC.pm: Ditto.
1635
1636         * dom/Element.cpp:
1637         (WebCore::Element::getURLAttribute): Added. For use implementing getters
1638         for ReflectURL.
1639         * dom/Element.h: Added getURLAttribute.
1640
1641         * html/HTMLImageElement.idl: Use Reflect and ReflectURL.
1642
1643 2009-06-22  Jian Li  <jianli@chromium.org>
1644
1645         Reviewed by Dimitri Glazkov.
1646
1647         Bug 26626: Make WorkerContextExecutionProxy::toV8Object handle exception
1648         objects.
1649         https://bugs.webkit.org/show_bug.cgi?id=26626
1650
1651         * bindings/v8/WorkerContextExecutionProxy.cpp:
1652         (WebCore::WorkerContextExecutionProxy::ToV8Object):
1653
1654 2009-06-22  David Hyatt  <hyatt@apple.com>
1655
1656         Reviewed by Sam Weinig.
1657
1658         Add RenderDataGrid to the build.  Give it some basic default styling (that more or less matches a listbox).  It has a default size
1659         of 300x150.
1660
1661         * GNUmakefile.am:
1662         * WebCore.pro:
1663         * WebCore.vcproj/WebCore.vcproj:
1664         * WebCore.xcodeproj/project.pbxproj:
1665         * WebCoreSources.bkl:
1666         * css/html4.css:
1667         * html/HTMLDataGridElement.cpp:
1668         (WebCore::HTMLDataGridElement::createRenderer):
1669         * html/HTMLDataGridElement.h:
1670         * html/HTMLDataGridElement.idl:
1671         * rendering/RenderDataGrid.cpp: Added.
1672         (WebCore::RenderDataGrid::RenderDataGrid):
1673         (WebCore::RenderDataGrid::~RenderDataGrid):
1674         (WebCore::RenderDataGrid::calcPrefWidths):
1675         (WebCore::RenderDataGrid::paintObject):
1676         (WebCore::RenderDataGrid::valueChanged):
1677         (WebCore::RenderDataGrid::invalidateScrollbarRect):
1678         (WebCore::RenderDataGrid::isActive):
1679         * rendering/RenderDataGrid.h: Added.
1680         (WebCore::RenderDataGrid::renderName):
1681         (WebCore::RenderDataGrid::canHaveChildren):
1682         (WebCore::RenderDataGrid::scrollbarCornerPresent):
1683
1684 2009-06-22  Simon Fraser  <simon.fraser@apple.com>
1685
1686         Reviewed by Dave Hyatt.
1687
1688         https://bugs.webkit.org/show_bug.cgi?id=26430
1689         <rdar://problem/6944442> Elements jump around when they become composited (WWDC checkers demo)
1690         <rdar://problem/6989006> Lots of time spent in RenderLayerCompositor::calculateCompositedBounds()
1691             during window resize when using hardware layers
1692         
1693         Fix an ordering dependency which caused the compositing position of a layer
1694         to be affected by some later sibling, which affected the compositing ancestor's
1695         composited bounds.
1696         
1697         The fix is to only update the compositing positions of layers in some subtree
1698         when updateAfterLayout() has been called on all the layers in that subtree,
1699         from the ancestor down.
1700         
1701         Also cache the composited bounds of a RenderLayerBacking, now that we can
1702         guarantee that those bounds are accurate.
1703         
1704         Test: compositing/sibling-positioning.html
1705
1706         * rendering/RenderLayer.cpp:
1707         (WebCore::RenderLayer::updateLayerPositions):
1708         (WebCore::RenderLayer::hitTestLayer):
1709         * rendering/RenderLayerBacking.cpp:
1710         (WebCore::RenderLayerBacking::RenderLayerBacking):
1711         (WebCore::RenderLayerBacking::updateAfterLayout):
1712         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1713         (WebCore::RenderLayerBacking::contentOffsetInCompostingLayer):
1714         (WebCore::RenderLayerBacking::paintContents):
1715         (WebCore::RenderLayerBacking::compositedBounds):
1716         (WebCore::RenderLayerBacking::setCompositedBounds):
1717         * rendering/RenderLayerBacking.h:
1718         * rendering/RenderLayerCompositor.cpp:
1719         (WebCore::RenderLayerCompositor::updateBacking):
1720         (WebCore::RenderLayerCompositor::updateLayerCompositingState):
1721         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
1722         (WebCore::RenderLayerCompositor::layerWillBeRemoved):
1723         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
1724         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
1725         (WebCore::RenderLayerCompositor::updateCompositingChildrenGeometry):
1726         * rendering/RenderLayerCompositor.h:
1727
1728 2009-06-22  Jeremy Orlow  <jorlow@chromium.org>
1729
1730         Reviewed by Darin Fisher.
1731
1732         First step in https://bugs.webkit.org/show_bug.cgi?id=25376
1733
1734         Add StorageSyncManager.cpp/h
1735
1736         * GNUmakefile.am:
1737         * WebCore.pro:
1738         * WebCore.vcproj/WebCore.vcproj:
1739         * WebCore.xcodeproj/project.pbxproj:
1740         * WebCoreSources.bkl:
1741
1742         In preparation for combining SessionStorage and LocalStorage into a
1743         single StorageManager, move the syncing bits out of LocalStorage and
1744         into its own class.
1745
1746         The next step is to combine LocalStorageArea and SessionStorageArea
1747         into one.  Then SessionStorage and LocalStorage can be combined.
1748
1749         Note that combining them will cut down on code paths that must be
1750         proxied, eliminate virtual dispatch, and allow Chromium to (eventually)
1751         write historical sessionStorage to disk when memory is getting tight.
1752
1753         Also remove a couple bits of cruft including code for quotas which is
1754         unnecessary (since a meta-data db is unnecessary since you can just
1755         count bytes as you read the local storage databases into memory).
1756
1757         * storage/LocalStorage.cpp:
1758         (WebCore::LocalStorage::LocalStorage):
1759         (WebCore::LocalStorage::storageArea):
1760         (WebCore::LocalStorage::close):
1761         * storage/LocalStorage.h:
1762         * storage/LocalStorageArea.cpp:
1763         (WebCore::LocalStorageArea::LocalStorageArea):
1764         (WebCore::LocalStorageArea::scheduleFinalSync):
1765         (WebCore::LocalStorageArea::syncTimerFired):
1766         (WebCore::LocalStorageArea::performImport):
1767         * storage/LocalStorageArea.h:
1768         (WebCore::LocalStorageArea::create):
1769         * storage/LocalStorageTask.cpp:
1770         (WebCore::LocalStorageTask::performTask):
1771         * storage/LocalStorageTask.h:
1772         (WebCore::LocalStorageTask::):
1773         (WebCore::LocalStorageTask::createImport):
1774         * storage/LocalStorageThread.cpp:
1775         * storage/LocalStorageThread.h:
1776         * storage/SessionStorage.h:
1777         * storage/StorageSyncManager.cpp: Copied from WebCore/storage/LocalStorage.cpp.
1778         (WebCore::StorageSyncManager::create):
1779         (WebCore::StorageSyncManager::StorageSyncManager):
1780         (WebCore::StorageSyncManager::fullDatabaseFilename):
1781         (WebCore::StorageSyncManager::close):
1782         (WebCore::StorageSyncManager::scheduleImport):
1783         (WebCore::StorageSyncManager::scheduleSync):
1784         * storage/StorageSyncManager.h: Copied from WebCore/storage/LocalStorage.h.
1785         (WebCore::):
1786
1787 2009-06-22  Darin Fisher  <darin@chromium.org>
1788
1789         Reviewed by Dimitri Glazkov.
1790
1791         https://bugs.webkit.org/show_bug.cgi?id=26622
1792         Add ChromiumDataObject::copy()
1793
1794         * platform/chromium/ChromiumDataObject.cpp:
1795         * platform/chromium/ChromiumDataObject.h:
1796
1797 2009-06-22  Timothy Hatcher  <timothy@apple.com>
1798
1799         Add a silhouette image for the enable view of the Resource panel.
1800
1801         Reviewed by Kevin McCullough.
1802
1803         * inspector/front-end/Images/resourcesSilhouette.png: Added.
1804         * inspector/front-end/inspector.css:
1805
1806 2009-06-22  Kyle Prete  <kylep@chromium.org>
1807
1808         Reviewed by Dimitri Glazkov.
1809
1810         https://bugs.webkit.org/show_bug.cgi?id=26552
1811         Add V8 JS bindings for Audio Constructor.
1812
1813         * bindings/v8/custom/V8CustomBinding.h:
1814         Added a callback declaration for audio ctor to macro.
1815         * bindings/v8/custom/V8HTMLAudioElementConstructor.cpp:
1816         Added the whole file.
1817
1818 2009-06-22  Alexey Proskuryakov  <ap@webkit.org>
1819
1820         Reviewed by David Levin.
1821
1822         https://bugs.webkit.org/show_bug.cgi?id=26600
1823         StringImpl::copy() no longer copies empty string correctly
1824
1825         * platform/text/StringImpl.cpp:
1826         (WebCore::StringImpl::ustring): Changed method calling syntax to look less like calling a
1827         static method.
1828         (WebCore::StringImpl::copy): Reverted part of r41917 that caused the problem.
1829
1830 2009-06-22  Xiaomei Ji  <xji@chromium.org>
1831
1832         Reviewed by Eric Seidel
1833
1834         Not auto-testable since it involves sending a keyboard event to
1835         the popup, which is not possible (eventSender sends the key
1836         events through webview, we want to go through the webwidget).
1837
1838         This patch is one part of the fix for issue "keyboard selection in
1839         Hebrew select element does not work in Windows". The other part of the
1840         fix is in chromium's webkit/glue layer.
1841         https://bugs.webkit.org/show_bug.cgi?id=25899
1842
1843         * manual-tests/keyboard_select_non_english.html: Added.
1844         * platform/chromium/PopupMenuChromium.cpp:
1845         (WebCore::isCharacterTypeEvent): Added. Check whether the event is a 
1846         character type event. "Char" in Windows or "KeyDown" in Mac is character
1847         type event.
1848         (WebCore::PopupListBox::typeAheadFind): Since m_lastCharTime is used to
1849         indicate whether user types multiple characters continuely as a search
1850         prefix or not, it should be only assigned when the event is character 
1851         type event. 
1852
1853 2009-06-22  Kevin McCullough  <kmccullough@apple.com>
1854
1855         Reviewed by Darin Adler.
1856
1857         <rdar://problem/6115819> Notify of profile start in console
1858
1859         Put a message in the console that announces that a profile has started,
1860         similar to how a console message announces that a profile has finished.
1861
1862         * inspector/InspectorController.cpp:
1863         (WebCore::InspectorController::addProfile): Use renamed function.
1864         (WebCore::InspectorController::addProfileFinishedMessageToConsole):
1865         Renamed.
1866         (WebCore::InspectorController::addStartProfilingMessageToConsole):
1867         New function that logs the message about the profile starting.
1868         (WebCore::InspectorController::startUserInitiatedProfiling): Ditto
1869         * inspector/InspectorController.h:
1870         * inspector/front-end/ProfilesPanel.js: Print the "run" of the profile's
1871         title if there are multiple profiles, and take into account the fact
1872         that titles are displayed twice as much now.
1873         (WebInspector.ProfilesPanel.prototype.displayTitleForProfileLink):
1874         * page/Console.cpp:
1875         (WebCore::Console::profile): Call new function.
1876
1877 2009-06-22  David Hyatt  <hyatt@apple.com>
1878
1879         Reviewed by Sam Weinig.
1880
1881         https://bugs.webkit.org/show_bug.cgi?id=26615
1882
1883         Add IDL interface for datagrid cell elements.  Add a few more properties to the datagrid itself that
1884         correspond to ones you find on <select> elements.
1885
1886         Add an expanded property to row elements.
1887
1888         * DerivedSources.cpp:
1889         * DerivedSources.make:
1890         * GNUmakefile.am:
1891         * WebCore.pro:
1892         * WebCore.vcproj/WebCore.vcproj:
1893         * WebCore.xcodeproj/project.pbxproj:
1894         * WebCoreSources.bkl:
1895         * html/HTMLAttributeNames.in:
1896         * html/HTMLDataGridCellElement.cpp: Added.
1897         (WebCore::HTMLDataGridCellElement::HTMLDataGridCellElement):
1898         (WebCore::HTMLDataGridCellElement::label):
1899         (WebCore::HTMLDataGridCellElement::setLabel):
1900         (WebCore::HTMLDataGridCellElement::focused):
1901         (WebCore::HTMLDataGridCellElement::setFocused):
1902         (WebCore::HTMLDataGridCellElement::checked):
1903         (WebCore::HTMLDataGridCellElement::setChecked):
1904         (WebCore::HTMLDataGridCellElement::indeterminate):
1905         (WebCore::HTMLDataGridCellElement::setIndeterminate):
1906         (WebCore::HTMLDataGridCellElement::progress):
1907         (WebCore::HTMLDataGridCellElement::setProgress):
1908         * html/HTMLDataGridCellElement.h: Added.
1909         (WebCore::HTMLDataGridCellElement::endTagRequirement):
1910         (WebCore::HTMLDataGridCellElement::tagPriority):
1911         * html/HTMLDataGridCellElement.idl: Added.
1912         * html/HTMLDataGridElement.cpp:
1913         (WebCore::HTMLDataGridElement::autofocus):
1914         (WebCore::HTMLDataGridElement::setAutofocus):
1915         (WebCore::HTMLDataGridElement::disabled):
1916         (WebCore::HTMLDataGridElement::setDisabled):
1917         (WebCore::HTMLDataGridElement::size):
1918         (WebCore::HTMLDataGridElement::setSize):
1919         * html/HTMLDataGridElement.h:
1920         * html/HTMLDataGridElement.idl:
1921         * html/HTMLDataGridRowElement.cpp:
1922         (WebCore::HTMLDataGridRowElement::checkDTD):
1923         (WebCore::HTMLDataGridRowElement::expanded):
1924         (WebCore::HTMLDataGridRowElement::setExpanded):
1925         * html/HTMLDataGridRowElement.h:
1926         * html/HTMLDataGridRowElement.idl:
1927         * html/HTMLElementsAllInOne.cpp:
1928         * html/HTMLTagNames.in:
1929
1930 2009-06-22  Sam Weinig  <sam@webkit.org>
1931
1932         Reviewed by Mark Rowe.
1933
1934         Add event handler attribute getter/setters to HTMLBodyElement
1935         as specified in HTML 5.
1936
1937         - Removes erroneous inclusion of the onresize and onunload event
1938         handler attributes in Element and Document.
1939
1940         * dom/Document.cpp:
1941         (WebCore::Document::getWindowAttributeEventListener):
1942         * dom/Document.h:
1943         * dom/Document.idl:
1944         * dom/Element.idl:
1945         * dom/Node.cpp:
1946         * dom/Node.h: onblur, onerror, onfocus, and onload all need to be declared
1947         virtual, since their behavior for HTMLBodyElement differs from the base
1948         implementation.
1949         * html/HTMLBodyElement.cpp:
1950         (WebCore::HTMLBodyElement::onblur):
1951         (WebCore::HTMLBodyElement::setOnblur):
1952         (WebCore::HTMLBodyElement::onerror):
1953         (WebCore::HTMLBodyElement::setOnerror):
1954         (WebCore::HTMLBodyElement::onfocus):
1955         (WebCore::HTMLBodyElement::setOnfocus):
1956         (WebCore::HTMLBodyElement::onload):
1957         (WebCore::HTMLBodyElement::setOnload):
1958         (WebCore::HTMLBodyElement::onbeforeunload):
1959         (WebCore::HTMLBodyElement::setOnbeforeunload):
1960         (WebCore::HTMLBodyElement::onmessage):
1961         (WebCore::HTMLBodyElement::setOnmessage):
1962         (WebCore::HTMLBodyElement::onoffline):
1963         (WebCore::HTMLBodyElement::setOnoffline):
1964         (WebCore::HTMLBodyElement::ononline):
1965         (WebCore::HTMLBodyElement::setOnonline):
1966         (WebCore::HTMLBodyElement::onresize):
1967         (WebCore::HTMLBodyElement::setOnresize):
1968         (WebCore::HTMLBodyElement::onstorage):
1969         (WebCore::HTMLBodyElement::setOnstorage):
1970         (WebCore::HTMLBodyElement::onunload):
1971         (WebCore::HTMLBodyElement::setOnunload):
1972         * html/HTMLBodyElement.h:
1973         * html/HTMLBodyElement.idl:
1974
1975 2009-06-22  Alexey Proskuryakov  <ap@webkit.org>
1976
1977         Reviewed by Darin Adler.
1978
1979         https://bugs.webkit.org/show_bug.cgi?id=26601
1980         Remove disabled code for appcache dynamic entries
1981
1982         This also removes code for DOM 3 Core DOMStringList, which we don't use for anything else yet.
1983
1984         * DerivedSources.cpp:
1985         * DerivedSources.make:
1986         * GNUmakefile.am:
1987         * WebCore.pro:
1988         * WebCore.vcproj/WebCore.vcproj:
1989         * WebCore.xcodeproj/project.pbxproj:
1990         * WebCoreSources.bkl:
1991         * bindings/js/JSDOMStringListCustom.cpp: Removed.
1992         * bindings/v8/custom/V8CustomBinding.h:
1993         * bindings/v8/custom/V8DOMStringListCustom.cpp: Removed.
1994         * dom/DOMStringList.cpp: Removed.
1995         * dom/DOMStringList.h: Removed.
1996         * dom/DOMStringList.idl: Removed.
1997         * dom/StaticStringList.cpp: Removed.
1998         * dom/StaticStringList.h: Removed.
1999         * loader/DocumentLoader.cpp:
2000         (WebCore::DocumentLoader::shouldLoadResourceFromApplicationCache):
2001         * loader/appcache/ApplicationCache.cpp:
2002         (WebCore::ApplicationCache::addResource):
2003         * loader/appcache/ApplicationCache.h:
2004         * loader/appcache/ApplicationCacheGroup.cpp:
2005         (WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
2006         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
2007         * loader/appcache/ApplicationCacheResource.cpp:
2008         (WebCore::ApplicationCacheResource::dumpType):
2009         * loader/appcache/ApplicationCacheResource.h:
2010         (WebCore::ApplicationCacheResource::):
2011         * loader/appcache/ApplicationCacheStorage.cpp:
2012         (WebCore::ApplicationCacheStorage::storeUpdatedType):
2013         * loader/appcache/DOMApplicationCache.cpp:
2014         * loader/appcache/DOMApplicationCache.h:
2015         * loader/appcache/DOMApplicationCache.idl:
2016         * page/DOMWindow.idl:
2017
2018 2009-06-22  Steve Falkenburg  <sfalken@apple.com>
2019
2020         Windows build fix.
2021
2022         * DerivedSources.cpp:
2023         * html/HTMLElementsAllInOne.cpp:
2024
2025 2009-06-22  Alexey Proskuryakov  <ap@webkit.org>
2026
2027         Reviewed by John Sullivan.
2028
2029         <rdar://problem/6956606> REGRESSION (S4Beta -> Final): After the password is input,
2030         Japanese can't be input.
2031
2032         WebKit uses a per-frame input context for most editable fields, and application's global
2033         context for password fields, manually controlling secure input state and the list of available
2034         input sources.
2035
2036         We were setting TSMDocument property to disable non-Roman input methods after focus changed
2037         to a password field, but before selection was updated. This resulted in the property being
2038         applied to a wrong TSMDocument in some cases, because TSMGetActiveDocument() uses input
2039         context cached by +[NSApplication updateWindows], we change context based on selection,
2040         not on focus.
2041
2042         * page/mac/FrameMac.mm: (WebCore::Frame::setUseSecureKeyboardEntry): Since there is only one
2043         context that we use for password fields - the global one - there is no need to get the active
2044         one.
2045
2046 2009-06-22  David Levin  <levin@chromium.org>
2047
2048         Reviewed by David Hyatt and Eric Seidel.
2049
2050         REGRESSION: When the main page (ScrollView) has a custom scrollbar, it crashes on destruction.
2051         https://bugs.webkit.org/show_bug.cgi?id=26326
2052
2053         Test: scrollbars/scrollbar-crash-on-refresh.html
2054
2055         * dom/Document.cpp:
2056         (WebCore::Document::detach):
2057         Gives the FrameView a change to do any necessary cleanup on
2058         Document::detach() which is where the renderArena gets detroyed.
2059         * page/FrameView.cpp:
2060         (WebCore::FrameView::detachCustomScrollbars):
2061         Gets rid of any custom scrollbars (if the docment supplied them).
2062         * page/FrameView.h:
2063         * platform/Scrollbar.h:
2064         (WebCore::Scrollbar::isCustomScrollbar):
2065         * rendering/RenderObject.cpp:
2066         (WebCore::RenderObject::destroy):
2067         Removed the check for document()->frame().  If frame() is 0 in this code,
2068         then the call to animation() is also incorrect (since it does document()->frame()->animation()).
2069         * rendering/RenderScrollbar.h:
2070         (WebCore::RenderScrollbar::isCustomScrollbar):
2071
2072 2009-06-22  Dan Bernstein  <mitz@apple.com>
2073
2074         Reviewed by Simon Fraser.
2075
2076         - fix https://bugs.webkit.org/show_bug.cgi?id=23606
2077           <rdar://problem/6537777> CSS gradient not repainted when image load
2078           completes
2079
2080         Test: fast/repaint/background-generated.html
2081
2082         * rendering/RenderObject.cpp:
2083         (WebCore::mustRepaintFillLayers): Return true if the layer does not
2084         specify a size and the image uses the container size.
2085
2086 2009-06-22  David Hyatt  <hyatt@apple.com>
2087
2088         Reviewed by Sam Weinig.
2089
2090         https://bugs.webkit.org/show_bug.cgi?id=26607
2091
2092         Add IDL for HTMLDataGridRowElement.
2093
2094         * DerivedSources.make:
2095         * GNUmakefile.am:
2096         * WebCore.pro:
2097         * WebCore.vcproj/WebCore.vcproj:
2098         * WebCore.xcodeproj/project.pbxproj:
2099         * WebCoreSources.bkl:
2100         * html/HTMLAttributeNames.in:
2101         * html/HTMLDataGridColElement.cpp:
2102         (WebCore::HTMLDataGridColElement::primary):
2103         (WebCore::HTMLDataGridColElement::setPrimary):
2104         * html/HTMLDataGridColElement.h:
2105         * html/HTMLDataGridColElement.idl:
2106         * html/HTMLDataGridElement.cpp:
2107         (WebCore::HTMLDataGridElement::checkDTD):
2108         (WebCore::HTMLDataGridElement::multiple):
2109         (WebCore::HTMLDataGridElement::setMultiple):
2110         * html/HTMLDataGridElement.h:
2111         * html/HTMLDataGridElement.idl:
2112         * html/HTMLDataGridRowElement.cpp: Added.
2113         (WebCore::HTMLDataGridRowElement::HTMLDataGridRowElement):
2114         (WebCore::HTMLDataGridRowElement::selected):
2115         (WebCore::HTMLDataGridRowElement::setSelected):
2116         (WebCore::HTMLDataGridRowElement::focused):
2117         (WebCore::HTMLDataGridRowElement::setFocused):
2118         * html/HTMLDataGridRowElement.h: Added.
2119         (WebCore::HTMLDataGridRowElement::tagPriority):
2120         * html/HTMLDataGridRowElement.idl: Added.
2121         * html/HTMLTagNames.in:
2122
2123 2009-06-19  Yael Aharon <yael.aharon@nokia.com>
2124
2125         Reviewed by Holger Freyther.
2126
2127         https://bugs.webkit.org/show_bug.cgi?id=26556
2128
2129         Fix a crash in case that the QNetworkReply::readReady signal is
2130         "stuck" in deferred mode due to JavaScript alert, and in the meantime,
2131         QNetworkreply::finished signal is received and processed before
2132         QNetworkReply::readReady is processed.
2133
2134         * manual-tests/qt/unload-alert.html: Added.
2135         * platform/network/qt/QNetworkReplyHandler.cpp:
2136         (WebCore::QNetworkReplyHandler::setLoadMode):
2137         (WebCore::QNetworkReplyHandler::finish):
2138         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
2139         (WebCore::QNetworkReplyHandler::forwardData):
2140         (WebCore::QNetworkReplyHandler::start):
2141         (WebCore::QNetworkReplyHandler::sendQueuedItems):
2142         * platform/network/qt/QNetworkReplyHandler.h:
2143         (WebCore::QNetworkReplyHandler::):
2144
2145 2009-06-22  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2146
2147         Fix the Qt build.
2148
2149         * WebCore.pro:
2150
2151 2009-06-21  Darin Adler  <darin@apple.com>
2152
2153         Reviewed by Sam Weinig.
2154
2155         Bug 25425: DOM attribute getter/setter functions should use const AtomicString& type
2156         https://bugs.webkit.org/show_bug.cgi?id=25425
2157
2158         * bindings/scripts/CodeGeneratorJS.pm: Tweaked mechanism for includes to be a bit
2159         more consistent and to make SVGElement.h be included in the header rather than in
2160         every implementation file that includes the header. Added code to use getAttribute
2161         and setAttribute directly when the [Reflect] extended attribute is used.
2162
2163         * bindings/scripts/CodeGeneratorObjC.pm: Ditto.
2164
2165         * html/HTMLElement.idl: Used [Reflect] for all the attributes in this class that
2166         reflect content attributes. Restricting this to one class for now to keep the
2167         patch small and start out slowly.
2168
2169 2009-06-21  Sam Weinig  <sam@webkit.org>
2170
2171         Reviewed by Oliver Hunt.
2172
2173         Fix for https://bugs.webkit.org/show_bug.cgi?id=26596
2174         Only expose event handler attributes to elements and documents.
2175
2176         Test: fast/dom/event-attribute-availability.html
2177
2178         * dom/Document.idl:
2179         * dom/Element.idl:
2180         * dom/Node.cpp:
2181         * dom/Node.h:
2182         * dom/Node.idl:
2183
2184 2009-06-21  Daniel Bates  <dbates@intudata.com>
2185
2186         Reviewed by Adam Barth.
2187
2188         https://bugs.webkit.org/show_bug.cgi?id=26580
2189         
2190         Fix to enable XSSAuditor on child windows.
2191         
2192         Test: http/tests/security/xssAuditor/link-opens-new-window.html
2193         
2194         * page/XSSAuditor.cpp:
2195         (WebCore::XSSAuditor::XSSAuditor):
2196         (WebCore::XSSAuditor::isEnabled):
2197         (WebCore::XSSAuditor::canEvaluate):
2198         (WebCore::XSSAuditor::canCreateInlineEventListener):
2199         (WebCore::XSSAuditor::canLoadExternalScriptFromSrc):
2200         (WebCore::XSSAuditor::canLoadObject):
2201         * page/XSSAuditor.h: Removed method setXSSAuditorEnabled, and field m_isEnabled.
2202         Moved implementation of isEnabled to XSSAuditor.cpp and changed implementation
2203         to query Settings.
2204
2205 2009-06-21  David Levin  <levin@chromium.org>
2206
2207         Reviewed by NOBODY.
2208
2209         Speculative windows build fix (idea by Mark Rowe).
2210
2211         * WebCore.vcproj/WebCore.vcproj:
2212
2213 2009-06-21  David Levin  <levin@chromium.org>
2214
2215         Reviewed by NOBODY (Speculative gtk build fix).
2216
2217         * GNUmakefile.am:
2218
2219 2009-06-21  David Levin  <levin@chromium.org>
2220
2221         Reviewed by NOBODY.
2222
2223         Speculative tiger build fix and a windows build fix.
2224         More fixes may still be in order.
2225
2226         * WebCore.vcproj/WebCoreCommon.vsprops:
2227         * dom/default/PlatformMessagePortChannel.h:
2228         (WebCore::PlatformMessagePortChannel::MessagePortQueue::tryGetMessage):
2229
2230 2009-06-21  David Levin  <levin@chromium.org>
2231
2232         Reviewed by NOBODY (Speculative tiger build fix).
2233
2234         * dom/default/PlatformMessagePortChannel.h:
2235         (WebCore::PlatformMessagePortChannel::MessagePortQueue::~MessagePortQueue):
2236
2237 2009-06-21  Drew Wilson  <atwilson@google.com>
2238
2239         Reviewed by David Levin.
2240
2241         <https://bugs.webkit.org/show_bug.cgi?id=26448>
2242         
2243         Added optimized GC for MessagePorts when the entangled port is run by the same thread.
2244         Fixed bug in isProxyFor() that was not properly throwing an exception when trying to clone the entangled port.
2245
2246         * bindings/js/JSDOMBinding.cpp:
2247         (WebCore::markActiveObjectsForContext):
2248         Now marks remotely entangled ports as in-use, in addition to those with pending activity.
2249         * bindings/js/JSMessagePortCustom.cpp:
2250         (WebCore::JSMessagePort::mark):
2251         Now checks if the entangled port is local (run by same thread) and if so mark()s it.
2252         * dom/MessagePort.cpp:
2253         (WebCore::MessagePort::postMessage):
2254         (WebCore::MessagePort::disentangle):
2255         Removes cloned ports from the ScriptExecutionContext - this allows cloned ports to be GC'd as otherwise they look like remotely entangled ports.
2256         (WebCore::MessagePort::start):
2257         (WebCore::MessagePort::locallyEntangledPort):
2258         Added API for fetching the entangled port if it is run by the same thread
2259         * dom/MessagePort.h:
2260         * dom/MessagePortProxyWrapper.h:
2261         * dom/default/MessagePortProxy.cpp:
2262         (WebCore::MessagePortProxyWrapper::locallyEntangledPort):
2263         Added API for fetching the entangled port if it is run by the same thread        
2264         (WebCore::MessagePortProxy::hasPendingActivity):
2265         Changed definition of hasPendingActivity() to be stricter - only returns true if there are pending messages.
2266         (WebCore::MessagePortProxy::locallyEntangledPort):
2267         * dom/default/MessagePortProxy.h:
2268
2269 2009-06-21  Drew Wilson  <atwilson@google.com>
2270
2271         Reviewed by David Levin.
2272
2273         <https://bugs.webkit.org/show_bug.cgi?id=25043>
2274         Removed obsolete MessagePort.startConversation(), active and onclose APIs.
2275
2276         Refactored MessagePortProxy into MessagePortChannel and a platform-dependent PlatformMessagePortChannel
2277         implementation. Modified APIs to simplify cross-process implementations by moving the messaging code
2278         entirely into the platform-dependent proxy.
2279
2280         Created a thread-safe default PlatformMessagePortChannel implementation.
2281
2282         Changed DOMWindow messaging to create the MessageEvent in the target ScriptExecutionContext to match how
2283         cross-thread MessagePorts work.
2284         
2285         * GNUMakefile.am:
2286         * WebCore.vcproj/WebCore.vcproj:
2287         * WebCore.xcodeproj/project.pbxproj:
2288             Added MessagePortChannel/PlatformMessagePortChannel files.
2289         * bindings/js/JSMessagePortCustom.cpp:
2290         (WebCore::JSMessagePort::mark):
2291             Changed ports to not mark their entangled pair as reachable, per the spec.
2292         * bindings/v8/custom/V8MessagePortCustom.cpp:
2293         * dom/MessageChannel.cpp:
2294         (WebCore::MessageChannel::MessageChannel):
2295             Updated to use PlatformMessagePortChannel::createChannel() to entangle the ports.
2296         * dom/MessagePort.cpp:
2297         (WebCore::MessagePort::MessagePort):
2298         (WebCore::MessagePort::~MessagePort):
2299         (WebCore::MessagePort::postMessage):
2300         (WebCore::MessagePort::disentangle):
2301         (WebCore::MessagePort::messageAvailable):
2302         (WebCore::MessagePort::start):
2303         (WebCore::MessagePort::close):
2304         (WebCore::MessagePort::entangle):
2305         (WebCore::MessagePort::contextDestroyed):
2306         (WebCore::MessagePort::dispatchMessages):
2307         (WebCore::MessagePort::setOnmessage):
2308         (WebCore::MessagePort::hasPendingActivity):
2309             Changed these APIs to delegate to new PlatformMessagePortChannel APIs.
2310         * dom/MessagePort.h:
2311             Renamed isQueueOpen() to started().
2312         * dom/MessagePort.idl:
2313             Removed startConversation and onclose.
2314         * dom/MessagePortProxy.h: Removed.
2315         * dom/MessagePortChannel.cpp: Added.
2316         (WebCore::MessagePortChannel::EventData::create):
2317         (WebCore::MessagePortChannel::EventData::EventData):
2318         (WebCore::MessagePortChannel::~MessagePortChannel):
2319         * dom/MessagePortChannel.h: Added.
2320         (WebCore::MessagePortChannel::EventData::message):
2321         (WebCore::MessagePortChannel::EventData::channel):
2322             Changed EventData to hold a reference to a MessagePortChannel object instead of a MessagePort to enable cross-thread messaging.
2323         (WebCore::MessagePortChannel::MessagePortChannel):
2324         (WebCore::MessagePortChannel::create):        
2325         * dom/ScriptExecutionContext.cpp:
2326         (WebCore:ScriptExecutionContext::dispatchMessagePortEvents):
2327             Renamed isQueueOpen() to started().
2328         * dom/default/PlatformMessagePortChannel.cpp: Added.
2329         (WebCore::MessagePortChannel::entangleIfOpen):
2330         (WebCore::MessagePortChannel::disentangle):
2331         (WebCore::MessagePortChannel::postMessageToRemote):
2332         (WebCore::MessagePortChannel::tryGetMessageFromRemote):
2333         (WebCore::MessagePortChannel::close):
2334         (WebCore::MessagePortChannel::isConnectedTo):
2335         (WebCore::MessagePortChannel::hasPendingActivity):
2336         (WebCore::PlatformMessagePortChannel::PlatformMessagePortChannel):
2337         (WebCore::PlatformMessagePortChannel::~PlatformMessagePortChannel):
2338         (WebCore::PlatformMessagePortChannel::createChannel):
2339         (WebCore::PlatformMessagePortChannel::entangleIfOpen):
2340         (WebCore::PlatformMessagePortChannel::disentangle):
2341         (WebCore::PlatformMessagePortChannel::setRemotePort):
2342         (WebCore::PlatformMessagePortChannel::remotePort):
2343         (WebCore::PlatformMessagePortChannel::entangledChannel):
2344         (WebCore::PlatformMessagePortChannel::setEntangledChannel):
2345         (WebCore::PlatformMessagePortChannel::postMessageToRemote):
2346         (WebCore::PlatformMessagePortChannel::tryGetMessageFromRemote):
2347         (WebCore::PlatformMessagePortChannel::isConnectedTo):
2348         (WebCore::PlatformMessagePortChannel::close):
2349         (WebCore::PlatformMessagePortChannel::closeInternal):
2350         (WebCore::PlatformMessagePortChannel::hasPendingActivity):
2351         * dom/default/PlatformMessagePortChannel.h: Added.
2352         (WebCore::PlatformMessagePortChannel::MessagePortQueue::create):
2353         (WebCore::PlatformMessagePortChannel::MessagePortQueue::tryGetMessage):
2354         (WebCore::PlatformMessagePortChannel::MessagePortQueue::appendAndCheckEmpty):
2355         (WebCore::PlatformMessagePortChannel::MessagePortQueue::isEmpty):
2356         (WebCore::PlatformMessagePortChannel::MessagePortQueue::MessagePortQueue):
2357         * page/DOMWindow.cpp:
2358         (WebCore::PostMessageTimer::PostMessageTimer):
2359             Changed DOMWindow messaging to create the MessageEvent in the target ScriptExecutionContext to match how cross-thread MessagePorts work.
2360         (WebCore::PostMessageTimer::event):
2361         (WebCore::DOMWindow::postMessage):
2362         (WebCore::DOMWindow::postMessageTimerFired):
2363
2364 2009-06-21  Dan Bernstein  <mitz@apple.com>
2365
2366         Reviewed by Sam Weinig.
2367
2368         - fix https://bugs.webkit.org/show_bug.cgi?id=15383
2369           <rdar://problem/5682745> resize: vertical does not restrict to vertical
2370           resize
2371
2372         Test: fast/css/resize-single-axis.html
2373
2374         * rendering/RenderLayer.cpp:
2375         (WebCore::RenderLayer::resize): Ignore movement along the non-resizing
2376         axis.
2377
2378 2009-06-21  Sam Weinig  <sam@webkit.org>
2379
2380         Reviewed by Eric Seidel
2381
2382         Fix for https://bugs.webkit.org/show_bug.cgi?id=26578
2383         event.currentTarget for listener registered on window should point to the window object like in Firefox
2384
2385         Test: fast/events/event-trace.html
2386
2387         * dom/Node.cpp:
2388         (WebCore::Node::dispatchGenericEvent): Make the DOMWindow the currentTarget when events are dispatched
2389         to it. We previously used the document because DOMWindow was not yet an EventTarget.
2390
2391 2009-06-21  Dan Bernstein  <mitz@apple.com>
2392
2393         Reviewed by Sam Weinig.
2394
2395         - fix https://bugs.webkit.org/show_bug.cgi?id=9694
2396           resize value not compared
2397
2398         Test: fast/css/resize-value-compared.html
2399
2400         * rendering/style/StyleRareInheritedData.cpp:
2401         (WebCore::StyleRareInheritedData::operator==): Compare the resize
2402         member.
2403
2404 2009-06-19  Alice Liu  <alice.liu@apple.com>
2405
2406         Fix https://bugs.webkit.org/show_bug.cgi?id=26568 
2407         Repro crash animating GIF if previously used in a closed window's back/forward list
2408         Also filed as <rdar://problem/6978362>
2409
2410         Reviewed by Maciej Stachowiak.
2411
2412         Can't test this bug with an automated layout test since it requires b/f caching 
2413         * manual-tests/animated-gif-bfcache-crash.html: Added.
2414         * manual-tests/resources/containsAnimatedGif.html: Added.
2415
2416         Adding checks for hostWindow() since there is no guarantee that the Page is alive
2417         * platform/ScrollView.cpp:
2418         (WebCore::ScrollView::scrollRectIntoViewRecursively):
2419         (WebCore::ScrollView::contentsToScreen):
2420         (WebCore::ScrollView::screenToContents):
2421         (WebCore::ScrollView::wheelEvent):
2422
2423 2009-06-20  Sam Weinig  <sam@webkit.org>
2424
2425         Reviewed by Adam Barth.
2426
2427         Fix for https://bugs.webkit.org/show_bug.cgi?id=26554
2428         Shadowing of top and parent
2429
2430         * page/DOMWindow.idl:
2431
2432 2009-06-20  Mark Rowe  <mrowe@apple.com>
2433
2434         Reviewed by Dan Bernstein.
2435
2436         Fix <https://bugs.webkit.org/show_bug.cgi?id=15106>.
2437         Bug 15106: REGRESSION: Can't drag text as element when user-select is set to none
2438
2439         We allow selections to begin within an element that has -webkit-user-select: none set,
2440         unless the element is draggable as dragging should take priority over starting a selection.
2441
2442         Test: editing/selection/user-drag-element-and-user-select-none.html
2443
2444         * dom/Node.cpp:
2445         (WebCore::Node::canStartSelection):
2446
2447 2009-06-20  Darin Adler  <darin@apple.com>
2448
2449         Reviewed by Dan Bernstein.
2450
2451         Bug 26528: REGRESSION (r44674): Assertion in TextIterator::pushFullyClippedState while counting matches for "a" on apple.com
2452         https://bugs.webkit.org/show_bug.cgi?id=26528
2453         rdar://problem/6985329
2454
2455         * editing/TextIterator.cpp:
2456         (WebCore::TextIterator::handleReplacedElement): When entering a text control,
2457         start at the top of the shadow tree (by calling shadowTreeRootNode). Also
2458         remove assumption that innerTextElement will never be 0 since RenderTextControl
2459         doesn't really guarantee this.
2460
2461 2009-06-20  Jan Michael Alonzo  <jmalonzo@webkit.org>
2462
2463         Reviewed by NOBODY.
2464
2465         Speculative Qt build fix - add HTMLDataGridColElement to the build script.
2466
2467         * WebCore.pro:
2468
2469 2009-06-19  Adam Barth  <abarth@webkit.org>
2470
2471         Reviewed by Darin Adler.
2472
2473         https://bugs.webkit.org/show_bug.cgi?id=26561
2474
2475         Remove a memcpy by retrieving the already existing copy of a string
2476         instead of making a new one.
2477
2478         * bindings/js/ScriptSourceCode.h:
2479         (WebCore::ScriptSourceCode::ScriptSourceCode):
2480         (WebCore::ScriptSourceCode::source):
2481         * bindings/js/StringSourceProvider.h:
2482         (WebCore::StringSourceProvider::source):
2483
2484 2009-06-19  Brian Weinstein  <bweinstein@apple.com>
2485
2486         Reviewed by Steve Falkenburg.
2487         
2488         https://bugs.webkit.org/show_bug.cgi?id=26488
2489         No Support for Single Finger or Two Finger Panning in Windows 7
2490         
2491         The code in WebCore allows us to interpret a Pan gesture as
2492         a mousewheel event, and we are able to reuse the scrolling code.
2493         Another constructor was created in WheelEventWin which takes data
2494         better suited to the pan guesture than what was currently there. 
2495         
2496         Unable to add tests to simulate touch behavior/gestures.
2497
2498         * platform/PlatformWheelEvent.h:
2499         * platform/win/WheelEventWin.cpp:
2500
2501 2009-06-19  Chris Marrin  <cmarrin@apple.com>
2502
2503         Fixed a build error, which only shows up in the i386 compile
2504
2505         * platform/graphics/mac/GraphicsLayerCA.mm:
2506         (WebCore::GraphicsLayerCA::animateTransform):
2507
2508 2009-06-19  Simon Fraser  <simon.fraser@apple.com>
2509
2510         Reviewed by Oliver Hunt.
2511
2512         <rdar://problem/6988385> REGRESSION: In full page video player, movie's
2513         video track becomes detached from its controller.
2514         
2515         When in the media document, the MediaPlayer should not report that it
2516         is capable of hardware acceleration, because it renders via a QTMovieView
2517         which is already accelerated.
2518
2519         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2520         (WebCore::MediaPlayerPrivate::supportsAcceleratedRendering):
2521
2522 2009-06-19  Kevin Ollivier  <kevino@theolliviers.com>
2523
2524         Adding XSSAuditor.cpp to the wx build.
2525
2526         * WebCoreSources.bkl:
2527
2528 2009-06-19  Chris Marrin  <cmarrin@apple.com>
2529
2530         Reviewed by Simon Fraser  <simon.fraser@apple.com>.
2531
2532         https://bugs.webkit.org/show_bug.cgi?id=26544
2533
2534         If I am doing a Matrix hardware animation and any matrix is singular, I revert to software.
2535         This is not really testable, since we can't see what the hardware animation is doing.
2536
2537         * platform/graphics/mac/GraphicsLayerCA.mm:
2538         (WebCore::GraphicsLayerCA::animateTransform):
2539
2540 2009-06-19  Geoffrey Garen  <ggaren@apple.com>
2541
2542         Reviewed by Maciej Stachowiak.
2543         
2544         An additional fix for Bug 26532: Native functions do not correctly unlink
2545         from optimised callsites when they're collected
2546         <https://bugs.webkit.org/show_bug.cgi?id=26532> | <rdar://problem/6625385>
2547
2548         Use "NativeFunctionWrapper" instead of "PrototypeFunction" in cross-frame
2549         accessors, so the type of object you get to wrap a function is the same,
2550         regardless of whether the access to the function is cross-frame.
2551         
2552         This is faster and more idiomatic than what we had before. It also would
2553         have avoided Bug 26532 because it would have prevented a conflicting
2554         PrototypeFunction from being allocated to wrap postMessage, where a
2555         NativeFunctionWrapper had been allocated previously.
2556         
2557         * bindings/js/JSDOMBinding.cpp:
2558         (WebCore::objectToStringFunctionGetter):
2559         * bindings/js/JSDOMWindowCustom.cpp:
2560         (WebCore::nonCachingStaticFunctionGetter):
2561         * bindings/js/JSHistoryCustom.cpp:
2562         (WebCore::nonCachingStaticBackFunctionGetter):
2563         (WebCore::nonCachingStaticForwardFunctionGetter):
2564         (WebCore::nonCachingStaticGoFunctionGetter):
2565         * bindings/js/JSLocationCustom.cpp:
2566         (WebCore::nonCachingStaticReplaceFunctionGetter):
2567         (WebCore::nonCachingStaticReloadFunctionGetter):
2568         (WebCore::nonCachingStaticAssignFunctionGetter):
2569
2570 2009-06-19  Simon Fraser  <simon.fraser@apple.com>
2571
2572         Reviewed by John Sullivan
2573
2574         <rdar://problem/6953673> Crash in RenderLayerCompositor::setCompositingParent
2575         
2576         Fix a crash that could occur in complex content due to timing issues
2577         when doing a partial layer tree rebuild which is required when painting;
2578         setCompositingParent() could be called with a parent which has not been made
2579         compositing yet.
2580
2581 2009-06-19  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2582
2583         Build fix. Adding missing HTMLDataGrid* files to the build.
2584
2585         * GNUmakefile.am:
2586
2587 2009-06-19  Peter Kasting  <pkasting@google.com>
2588
2589         Reviewed by Eric Seidel.
2590
2591         https://bugs.webkit.org/show_bug.cgi?id=26460 part three
2592         Make BMPImageReader a standalone class that is used by ICOImageDecoder
2593         and BMPImageDecoder to decode individual BMPs within a file.  These
2594         decoders now inherit directly from ImageDecoder.
2595         
2596         This also makes these decoders decode on-demand in isSizeAvailable() and
2597         frameBufferAtIndex(), like the other decoders, instead of when setData()
2598         is called, like before.  This should provide a speedup on pages
2599         containing BMPs that aren't immediately onscreen.
2600
2601         * platform/image-decoders/bmp/BMPImageDecoder.cpp:
2602         (WebCore::BMPImageDecoder::BMPImageDecoder):
2603         (WebCore::BMPImageDecoder::setData):
2604         (WebCore::BMPImageDecoder::isSizeAvailable):
2605         (WebCore::BMPImageDecoder::frameBufferAtIndex):
2606         (WebCore::BMPImageDecoder::decodeWithCheckForDataEnded):
2607         (WebCore::BMPImageDecoder::decode):
2608         (WebCore::BMPImageDecoder::processFileHeader):
2609         * platform/image-decoders/bmp/BMPImageDecoder.h:
2610         (WebCore::BMPImageDecoder::readUint32):
2611         * platform/image-decoders/bmp/BMPImageReader.cpp:
2612         (WebCore::BMPImageReader::BMPImageReader):
2613         (WebCore::BMPImageReader::decodeBMP):
2614         (WebCore::BMPImageReader::readInfoHeaderSize):
2615         (WebCore::BMPImageReader::processInfoHeader):
2616         (WebCore::BMPImageReader::readInfoHeader):
2617         (WebCore::BMPImageReader::processBitmasks):
2618         (WebCore::BMPImageReader::processColorTable):
2619         (WebCore::BMPImageReader::processRLEData):
2620         (WebCore::BMPImageReader::processNonRLEData):
2621         (WebCore::BMPImageReader::setFailed):
2622         * platform/image-decoders/bmp/BMPImageReader.h:
2623         (WebCore::BMPImageReader::readUint16):
2624         (WebCore::BMPImageReader::readUint32):
2625         (WebCore::BMPImageReader::setBuffer):
2626         (WebCore::BMPImageReader::setData):
2627         (WebCore::BMPImageReader::):
2628         (WebCore::BMPImageReader::pastEndOfImage):
2629         (WebCore::BMPImageReader::readCurrentPixel):
2630         (WebCore::BMPImageReader::setRGBA):
2631         * platform/image-decoders/ico/ICOImageDecoder.cpp:
2632         (WebCore::ICOImageDecoder::ICOImageDecoder):
2633         (WebCore::ICOImageDecoder::setData):
2634         (WebCore::ICOImageDecoder::isSizeAvailable):
2635         (WebCore::ICOImageDecoder::size):
2636         (WebCore::ICOImageDecoder::frameBufferAtIndex):
2637         (WebCore::ICOImageDecoder::decodeWithCheckForDataEnded):
2638         (WebCore::ICOImageDecoder::decode):
2639         (WebCore::ICOImageDecoder::processDirectory):
2640         (WebCore::ICOImageDecoder::processDirectoryEntries):
2641         (WebCore::ICOImageDecoder::readDirectoryEntry):
2642         (WebCore::ICOImageDecoder::processImageType):
2643         * platform/image-decoders/ico/ICOImageDecoder.h:
2644         (WebCore::ICOImageDecoder::readUint16):
2645         (WebCore::ICOImageDecoder::readUint32):
2646
2647 2009-06-19  Adam Barth  <abarth@webkit.org>
2648
2649         Reviewed by Dimitri Glazkov.
2650
2651         https://bugs.webkit.org/show_bug.cgi?id=26555
2652
2653         Fix the Chromium canary bot.  Turns out ScriptSourceCode doesn't have
2654         the same API in V8 and JSC.
2655
2656         * WebCore/bindings/js/ScriptController.cpp:
2657         * WebCore/bindings/js/ScriptSourceCode.h:
2658         * WebCore/bindings/v8/ScriptController.cpp:
2659         * WebCore/page/XSSAuditor.cpp:
2660         * WebCore/page/XSSAuditor.h:
2661
2662 2009-06-19  David Hyatt  <hyatt@apple.com>
2663
2664         Reviewed by Anders Carlsson.
2665
2666         https://bugs.webkit.org/show_bug.cgi?id=26547
2667         
2668         Implement the IDL interface for HTMLDataGridColElement.
2669
2670         * DerivedSources.cpp:
2671         * DerivedSources.make:
2672         * GNUmakefile.am:
2673         * WebCore.pro:
2674         * WebCore.vcproj/WebCore.vcproj:
2675         * WebCore.xcodeproj/project.pbxproj:
2676         * WebCoreSources.bkl:
2677         * html/HTMLAttributeNames.in:
2678         * html/HTMLDataGridColElement.cpp: Added.
2679         (WebCore::HTMLDataGridColElement::HTMLDataGridColElement):
2680         (WebCore::HTMLDataGridColElement::label):
2681         (WebCore::HTMLDataGridColElement::setLabel):
2682         (WebCore::HTMLDataGridColElement::type):
2683         (WebCore::HTMLDataGridColElement::setType):
2684         (WebCore::HTMLDataGridColElement::sortable):
2685         (WebCore::HTMLDataGridColElement::setSortable):
2686         (WebCore::HTMLDataGridColElement::sortDirection):
2687         (WebCore::HTMLDataGridColElement::setSortDirection):
2688         (WebCore::HTMLDataGridColElement::selected):
2689         (WebCore::HTMLDataGridColElement::setSelected):
2690         * html/HTMLDataGridColElement.h: Added.
2691         (WebCore::HTMLDataGridColElement::endTagRequirement):
2692         (WebCore::HTMLDataGridColElement::tagPriority):
2693         * html/HTMLDataGridColElement.idl: Added.
2694         * html/HTMLDataGridElement.h:
2695         * html/HTMLElementsAllInOne.cpp:
2696         * html/HTMLTagNames.in:
2697         * page/DOMWindow.idl:
2698
2699 2009-06-19  Chris Evans  <scarybeasts@gmail.com>
2700
2701         Reviewed by Eric Seidel.
2702
2703         There is no new test because this cannot be tested deterministically.
2704         I've not been able to cause a crash at all in the test framework, but
2705         I have verified that this is happening in the wild and that the patch
2706         fixes the likely cause in the debugger.
2707
2708         * loader/TextResourceDecoder.cpp: careful not to iterate off the end
2709           of our input buffer looking for the end of the comment.
2710
2711 2009-06-19  Adam Barth  <abarth@webkit.org>
2712
2713         Reviewed by Dimitri Glazkov.
2714
2715         https://bugs.webkit.org/show_bug.cgi?id=26536
2716
2717         Fix external-script-URL-location.html and
2718         write-external-script-open.html LayoutTests.
2719
2720         implicitOpen is called from several places.  We need to setXSSAuditor
2721         each time, so I moved the call inside implicitOpen.
2722
2723         * dom/Document.cpp:
2724         (WebCore::Document::open):
2725         (WebCore::Document::implicitOpen):
2726         * loader/FrameLoader.cpp:
2727         (WebCore::FrameLoader::begin):
2728
2729 2009-06-19  Kent Tamura  <tkent@chromium.org>
2730
2731         Reviewed by David Levin.
2732
2733         Use WebCore::multipleFileUploadText() in Chromium to fix a problem
2734         that Chromium shows only the first filename even if a user selects
2735         multiple files for <input type=file multiple>.
2736         <https://bugs.webkit.org/show_bug.cgi?id=26502>
2737
2738         * platform/chromium/FileChooserChromium.cpp:
2739         (WebCore::FileChooser::basenameForWidth):
2740
2741 2009-06-19  Dan Bernstein  <mitz@apple.com>
2742
2743         Reviewed by Dave Hyatt.
2744
2745         - fix <rdar://problem/6967596> Safari hung using 100% CPU when I tried
2746           to look up a word in Dictionary using command-control-d
2747
2748         Test: editing/selection/move-by-line-005.html
2749
2750         The root cause of this bug was searchAheadForBetterMatch() continuing
2751         past the first rendered text object after the given object. While we
2752         want to skip non-rendered text and empty containers, when we encounter
2753         rendered text object, we must return a text box for that object.
2754
2755         * dom/Position.cpp:
2756         (WebCore::searchAheadForBetterMatch):
2757
2758 2009-06-19  Jungshik Shin  <jshin@chromium.org>
2759
2760         Reviewed by David Levin
2761
2762         https://bugs.webkit.org/show_bug.cgi?id=25657
2763
2764         Chromium Linux port does not handle non-BMP characters properly.
2765         It's fixed with a 'UTF-16 iterator macro' to extract Unicode
2766         codepoints out of a UTF-16 input string.
2767
2768         A manual test is added for non-BMP character rendering,
2769         which we can use until a small freely-distributable font
2770         covering non-BMP is added to the Webkit source tree.
2771
2772
2773         * platform/graphics/chromium/FontCacheLinux.cpp:
2774         (WebCore::FontCache::getFontDataForCharacters):
2775         * manual-tests/non-bmp.html: Added.
2776
2777 2009-06-19  Pavel Feldman  <pfeldman@chromium.org>
2778
2779         Reviewed by Dimitri Glazkov.
2780
2781         V8 Bindings: return proper state from the script stack.
2782
2783         https://bugs.webkit.org/show_bug.cgi?id=26512
2784
2785         * bindings/v8/ScriptCallStack.cpp:
2786         (WebCore::ScriptCallStack::ScriptCallStack):
2787         * bindings/v8/ScriptCallStack.h:
2788         (WebCore::ScriptCallStack::state):
2789
2790 2009-06-19  Jessie Berlin  <jberlin@apple.com>
2791
2792         Reviewed by Simon Fraser.
2793
2794         Windows build fix.
2795         
2796         * platform/graphics/cg/PatternCG.cpp:
2797         (WebCore::Pattern::createPlatformPattern):
2798
2799 2009-06-19  Yael Aharon  <yael.aharon@nokia.com>
2800
2801         Reviewed by Simon Hausmann.
2802         Build fix after 44825.
2803
2804         * platform/graphics/qt/ImageDecoderQt.cpp:
2805         (WebCore::ImageDecoderQt::isSizeAvailable):
2806         * platform/graphics/qt/ImageDecoderQt.h:
2807
2808 2009-06-18  Shinichiro Hamaji  <hamaji@chromium.org>
2809
2810         Reviewed by Oliver Hunt.
2811
2812         Bug 26426: Canvas: rotation of 'no-repeat' pattern is weird
2813         <https://bugs.webkit.org/show_bug.cgi?id=26426>
2814
2815         Use 1<<23-1 as steps of no-repeat patterns instead of 100000000.0f.
2816         The original number cannot be represented by mantissa of float
2817         (23bit) so that it caused some error.
2818
2819         Test: fast/canvas/image-object-in-canvas.html:
2820
2821         * platform/graphics/cg/PatternCG.cpp:
2822         (WebCore::Pattern::createPlatformPattern):
2823
2824 2009-06-19  Adam Barth  <abarth@webkit.org>
2825
2826         Unreviewed attempt to fix the Chromium build.
2827
2828         * bindings/v8/ScriptController.cpp:
2829         (WebCore::ScriptController::ScriptController):
2830         (WebCore::ScriptController::evaluate):
2831         * bindings/v8/ScriptController.h:
2832         (WebCore::ScriptController::xssAuditor):
2833         * bindings/v8/ScriptEventListener.cpp:
2834         (WebCore::createAttributeEventListener):
2835
2836 2009-06-18  Adam Barth  <abarth@webkit.org>
2837
2838         Reviewed by Sam Weinig.
2839
2840         https://bugs.webkit.org/show_bug.cgi?id=26199
2841
2842         Added an experimental reflective XSS filter.  The filter is disabled by
2843         default.
2844
2845         Test: http/tests/security/xssAuditor/script-tag.html
2846
2847         * GNUmakefile.am:
2848         * WebCore.base.exp:
2849         * WebCore.pro:
2850         * WebCore.vcproj/WebCore.vcproj:
2851         * WebCore.xcodeproj/project.pbxproj:
2852         * bindings/js/ScriptController.cpp:
2853         (WebCore::ScriptController::ScriptController):
2854         (WebCore::ScriptController::evaluate):
2855         * bindings/js/ScriptController.h:
2856         (WebCore::ScriptController::xssAuditor):
2857         * bindings/js/ScriptEventListener.cpp:
2858         (WebCore::createAttributeEventListener):
2859         * dom/Tokenizer.h:
2860         (WebCore::Tokenizer::xssAuditor):
2861         (WebCore::Tokenizer::setXSSAuditor):
2862         (WebCore::Tokenizer::Tokenizer):
2863         * html/HTMLTokenizer.cpp:
2864         (WebCore::HTMLTokenizer::scriptHandler):
2865         * loader/FrameLoader.cpp:
2866         (WebCore::FrameLoader::begin):
2867         (WebCore::FrameLoader::requestObject):
2868         * page/Settings.cpp:
2869         (WebCore::Settings::Settings):
2870         (WebCore::Settings::setXSSAuditorEnabled):
2871         * page/Settings.h:
2872         (WebCore::Settings::xssAuditorEnabled):
2873         * page/XSSAuditor.cpp: Added.
2874         (WebCore::isControlCharacter):
2875         (WebCore::XSSAuditor::XSSAuditor):
2876         (WebCore::XSSAuditor::~XSSAuditor):
2877         (WebCore::XSSAuditor::canEvaluate):
2878         (WebCore::XSSAuditor::canCreateInlineEventListener):
2879         (WebCore::XSSAuditor::canLoadExternalScriptFromSrc):
2880         (WebCore::XSSAuditor::canLoadObject):
2881         (WebCore::XSSAuditor::decodeURL):
2882         (WebCore::XSSAuditor::findInRequest):
2883         * page/XSSAuditor.h: Added.
2884         (WebCore::XSSAuditor::isEnabled):
2885         (WebCore::XSSAuditor::setXSSAuditorEnabled):
2886
2887 2009-06-18  Dirk Schulze  <krit@webkit.org>
2888
2889         Reviewed by Oliver Hunt.
2890
2891         feOffset and objectBoundingBox
2892         [https://bugs.webkit.org/show_bug.cgi?id=26441]
2893
2894         If we use objectBoundingBox for primitiveUnits, the fractions given
2895         to dx or dy of feOffset must be multiplied with the referenced objects
2896         objectBoundingBox size.
2897
2898         Test: svg/filters/feOffset.svg
2899
2900         * svg/graphics/filters/SVGFEOffset.cpp:
2901         (WebCore::FEOffset::apply):
2902
2903 2009-06-18  Dirk Schulze  <krit@webkit.org>
2904
2905         Reviewed by Oliver Hunt.
2906
2907         feTile implementation missing
2908         [https://bugs.webkit.org/show_bug.cgi?id=26419]
2909
2910         Implementation of feTile, a pattern effect for SVG filters. It was
2911         necessary to modify FilterEffect since source inputs need a secial
2912         logic and we have to identify if an effect is a source input.
2913
2914         Tests: svg/batik/filters/feTile.svg
2915                svg/filters/feTile.svg
2916
2917         * platform/graphics/filters/FilterEffect.h:
2918         (WebCore::FilterEffect::isSourceInput):
2919         * platform/graphics/filters/SourceAlpha.h:
2920         (WebCore::SourceAlpha::isSourceInput):
2921         * platform/graphics/filters/SourceGraphic.h:
2922         (WebCore::SourceGraphic::isSourceInput):
2923         * svg/graphics/filters/SVGFETile.cpp:
2924         (WebCore::FETile::apply):
2925
2926 2009-06-18  Dirk Schulze  <krit@webkit.org>
2927
2928         Reviewed by Oliver Hunt.
2929
2930         feMerge implementation
2931         [https://bugs.webkit.org/show_bug.cgi?id=26480]
2932
2933         Added feMerge to the SVG Filter system.
2934
2935         Test: svg/filters/feMerge.svg
2936
2937         * svg/graphics/filters/SVGFEMerge.cpp:
2938         (WebCore::FEMerge::uniteChildEffectSubregions):
2939         (WebCore::FEMerge::apply):
2940         * svg/graphics/filters/SVGFEMerge.h:
2941
2942 2009-06-18  Mark Rowe  <mrowe@apple.com>
2943
2944         Speculative Windows build fix.
2945
2946         * page/win/FrameCGWin.cpp: Add missing #include.
2947
2948 2009-06-17  Brent Fulgham  <bfulgham@webkit.org>
2949
2950         Reviewed by Dave Levin.
2951
2952         https://bugs.webkit.org/show_bug.cgi?id=26425
2953         Final refactorings, picking up a few places where BitmapInfo
2954         could be used.
2955
2956         * page/win/FrameCGWin.cpp:
2957         (WebCore::imageFromRect):
2958         * platform/win/CursorWin.cpp:
2959         (WebCore::Cursor::Cursor):
2960         * platform/win/PopupMenuWin.cpp:
2961         (WebCore::PopupMenu::paint):
2962
2963 2009-06-18  Chris Fleizach  <cfleizach@apple.com>
2964
2965         Reviewed by Darin Adler.
2966
2967         Bug 26522: In DOM mode, VoiceOver reads some mouseover text on web sites strangely
2968         https://bugs.webkit.org/show_bug.cgi?id=26522
2969
2970         Test: accessibility/non-data-table-cell-title-ui-element.html
2971
2972         * accessibility/AccessibilityTableCell.cpp:
2973         (WebCore::AccessibilityTableCell::titleUIElement):
2974
2975 2009-06-18  Kevin Ollivier  <kevino@theolliviers.com>
2976
2977         wx build fix after recent RenderTheme changes.
2978
2979         * platform/wx/RenderThemeWx.cpp:
2980         (WebCore::RenderThemeWx::~RenderThemeWx):
2981         (WebCore::RenderTheme::themeForPage):
2982
2983 2009-06-18  Peter Kasting  <pkasting@google.com>
2984
2985         Reviewed by Eric Seidel.
2986
2987         https://bugs.webkit.org/show_bug.cgi?id=26460 part two
2988         Attempt to minimize diff of following functional change by first landing
2989         non-functional change to:
2990         * Make readUintX() public and static (since they will need to be once
2991           BMPImageReader is included in *ImageDecoder via composition rather
2992           than inheritance).  Add wrappers in each class so callers can be
2993           simpler.  In the next patch, these wrappers will be beefed up slightly
2994           and the callers will get even simpler.
2995         * Change direct setting of m_failed to use setFailed(), since in the
2996           next patch much of this code won't even have direct access to m_failed
2997         * Add a helper function in ICOImageDecoder to determine the image type
2998           instead of simply doing it inline
2999         * Rewrap lines that used to be <=80 cols and slipped over it during the
3000           original landing of these decoders
3001         * Other misc. changes, e.g. adding constructor definitions, reordering
3002           functions, changing RGBA32Buffer& to RGBA32Buffer*, etc. that have no
3003           functional effect but minimize the subsequent diff for readability
3004
3005
3006         * platform/image-decoders/bmp/BMPImageDecoder.cpp:
3007         (WebCore::BMPImageDecoder::BMPImageDecoder):
3008         (WebCore::BMPImageDecoder::processFileHeader):
3009         * platform/image-decoders/bmp/BMPImageDecoder.h:
3010         (WebCore::BMPImageDecoder::readUint32):
3011         * platform/image-decoders/bmp/BMPImageReader.cpp:
3012         (WebCore::BMPImageReader::decodeBMP):
3013         (WebCore::BMPImageReader::getInfoHeaderSize):
3014         (WebCore::BMPImageReader::processInfoHeader):
3015         (WebCore::BMPImageReader::readInfoHeader):
3016         (WebCore::BMPImageReader::processBitmasks):
3017         (WebCore::BMPImageReader::processColorTable):
3018         (WebCore::BMPImageReader::processRLEData):
3019         (WebCore::BMPImageReader::processNonRLEData):
3020         * platform/image-decoders/bmp/BMPImageReader.h:
3021         (WebCore::BMPImageReader::readUint16Helper):
3022         (WebCore::BMPImageReader::readUint32Helper):
3023         (WebCore::BMPImageReader::):
3024         (WebCore::BMPImageReader::readUint16):
3025         (WebCore::BMPImageReader::readUint32):
3026         (WebCore::BMPImageReader::readCurrentPixel):
3027         (WebCore::BMPImageReader::getComponent):
3028         (WebCore::BMPImageReader::setI):
3029         (WebCore::BMPImageReader::setRGBA):
3030         (WebCore::BMPImageReader::fillRGBA):
3031         * platform/image-decoders/ico/ICOImageDecoder.cpp:
3032         (WebCore::ICOImageDecoder::ICOImageDecoder):
3033         (WebCore::ICOImageDecoder::isSizeAvailable):
3034         (WebCore::ICOImageDecoder::size):
3035         (WebCore::ICOImageDecoder::decodeImage):
3036         (WebCore::ICOImageDecoder::processDirectory):
3037         (WebCore::ICOImageDecoder::processDirectoryEntries):
3038         (WebCore::ICOImageDecoder::isBetterEntry):
3039         (WebCore::ICOImageDecoder::processImageType):
3040         * platform/image-decoders/ico/ICOImageDecoder.h:
3041         (WebCore::ICOImageDecoder::readUint16):
3042         (WebCore::ICOImageDecoder::readUint32):
3043
3044 2009-06-18  Peter Kasting  <pkasting@google.com>
3045
3046         Fix build bustage.
3047
3048         * platform/image-decoders/gif/GIFImageDecoder.h:
3049
3050 2009-06-18  Kevin McCullough  <kmccullough@apple.com>
3051
3052         Reviewed by Oliver Hunt.
3053
3054         <rdar://problem/6940880> REGRESSION: Breakpoints don't break in 64-bit
3055
3056         Convert intptr_t to Strings so that we don't loose bits in the
3057         conversion to JS.  Previously they were being put into 32bit ints.
3058
3059         * inspector/InspectorController.cpp: Convert the String back to an
3060         intptr_t.
3061         (WebCore::InspectorController::addBreakpoint):
3062         (WebCore::InspectorController::removeBreakpoint):
3063         * inspector/InspectorController.h:
3064         * inspector/InspectorController.idl: Use strings in JS to avoid 32bit
3065         truncation.
3066         * inspector/InspectorFrontend.cpp: Make the intptr_t into a String.
3067         (WebCore::InspectorFrontend::parsedScriptSource):
3068         * platform/text/PlatformString.h: Implemented the necessary conversion
3069         functions to be able to convert to and from an intptr_t.
3070         * platform/text/String.cpp: Ditto.
3071         (WebCore::String::toIntPtrStrict):
3072         (WebCore::String::toIntPtr):
3073         (WebCore::charactersToIntPtrStrict):
3074         (WebCore::charactersToIntPtr):
3075         * platform/text/StringImpl.cpp: Ditto.
3076         (WebCore::StringImpl::toIntPtrStrict):
3077         (WebCore::StringImpl::toIntPtr):
3078         * platform/text/StringImpl.h: Ditto.
3079
3080 2009-06-17  Brent Fulgham  <bfulgham@webkit.org>
3081
3082         Reviewed by Eric Seidel.
3083
3084         Final cleanups in this refactoring:
3085         (1) Move WindowsBitmap implementation from CG-specific file to
3086             the platform-common GraphicsContextWin.cpp, since it is
3087             equally useful on both platforms.
3088         (2) Revise the TransformationMatrix logic as suggested by
3089             Adam Roben in his review comments to Part #2 of this
3090             refactoring.
3091
3092         * platform/graphics/win/GraphicsContextCGWin.cpp:
3093         * platform/graphics/win/GraphicsContextWin.cpp:
3094         (WebCore::GraphicsContext::WindowsBitmap::WindowsBitmap):
3095         (WebCore::GraphicsContext::WindowsBitmap::~WindowsBitmap):
3096         (WebCore::GraphicsContext::createWindowsBitmap):
3097         (WebCore::GraphicsContext::getWindowsContext):
3098         (WebCore::GraphicsContextPlatformPrivate::scale):
3099         (WebCore::GraphicsContextPlatformPrivate::rotate):
3100         (WebCore::GraphicsContextPlatformPrivate::translate):
3101         (WebCore::GraphicsContextPlatformPrivate::concatCTM):
3102
3103 2009-06-18  Peter Kasting  <pkasting@google.com>
3104
3105         Reviewed by Eric Seidel.
3106
3107         https://bugs.webkit.org/show_bug.cgi?id=26460 part one
3108         Make isSizeAvailable non-const, since it's not logically const (it
3109         triggers lazy decoding), and simplify all the implementations (without
3110         changing behavior; just make less verbose).  Remove some other
3111         inappropriate consts, which enables the removal of all the mutable
3112         declarations in the decoders.
3113
3114         * platform/image-decoders/ImageDecoder.h:
3115         (WebCore::ImageDecoder::isSizeAvailable):
3116         (WebCore::ImageDecoder::setSize): Make public to avoid needing a friend declaration in the JPEG decoder, and because the ICO/BMP decoders will soon need this.
3117         * platform/image-decoders/gif/GIFImageDecoder.cpp:
3118         (WebCore::GIFImageDecoder::isSizeAvailable):
3119         (WebCore::GIFImageDecoder::repetitionCount):
3120         (WebCore::GIFImageDecoder::decode):
3121         * platform/image-decoders/gif/GIFImageDecoder.h:
3122         * platform/image-decoders/ico/ICOImageDecoder.cpp:
3123         (WebCore::ICOImageDecoder::isSizeAvailable):
3124         * platform/image-decoders/ico/ICOImageDecoder.h:
3125         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
3126         (WebCore::JPEGImageDecoder::isSizeAvailable):
3127         (WebCore::JPEGImageDecoder::decode):
3128         * platform/image-decoders/jpeg/JPEGImageDecoder.h:
3129         * platform/image-decoders/png/PNGImageDecoder.cpp:
3130         (WebCore::PNGImageDecoder::isSizeAvailable):
3131         (WebCore::PNGImageDecoder::decode):
3132         * platform/image-decoders/png/PNGImageDecoder.h:
3133         * platform/image-decoders/xbm/XBMImageDecoder.cpp:
3134         (WebCore::XBMImageDecoder::isSizeAvailable):
3135         (WebCore::XBMImageDecoder::frameBufferAtIndex):
3136         (WebCore::XBMImageDecoder::decode):
3137         * platform/image-decoders/xbm/XBMImageDecoder.h: Rename decodeXBM() to decode() for consistency with the JPEG/PNG decoders, and in the future the ICO/BMP decoders.
3138
3139 2009-06-17  Brent Fulgham  <bfulgham@webkit.org>
3140
3141         Reviewed by Eric Seidel.
3142
3143         Move some common functions out of platform files and into
3144         the common implementation.
3145
3146         https://bugs.webkit.org/show_bug.cgi?id=26425.
3147         Add a new platform context method (flush) so that the
3148         getWindowsContext method can be consolidated into the common
3149         GraphicsContextWin.cpp file.
3150          
3151         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
3152         (WebCore::GraphicsContextPlatformPrivate::flush):
3153         * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
3154         (WebCore::GraphicsContextPlatformPrivate::flush):
3155         * platform/graphics/win/GraphicsContextCGWin.cpp: Remove
3156           getWindowContext method.
3157         * platform/graphics/win/GraphicsContextCairoWin.cpp: Remove
3158           getWindowContext method and fillWithClearColor methods.
3159         * platform/graphics/win/GraphicsContextWin.cpp:
3160         (WebCore::fillWithClearColor): Moved from *CairoWin.cpp
3161         (WebCore::GraphicsContext::getWindowsContext): Moved
3162           from *CairoWin.cpp
3163
3164 2009-06-18  Ojan Vafai  <ojan@chromium.org>
3165
3166         Reviewed by Oliver Hunt.
3167
3168         Remove code that I accidentally committed in r44811.
3169
3170         * editing/markup.cpp:
3171         (WebCore::createMarkup):
3172
3173 2009-06-18  Simon Fraser  <simon.fraser@apple.com>
3174
3175         Reviewed by Dan Bernstein.
3176
3177         <rdar://problem/6983207> Non-layer content is not re-rendered when transition
3178         starts sometimes (with hardware acceleration).
3179         
3180         When deciding which RenderLayers should be composited, when a layer goes into
3181         compositing mode we repaint the old location. However, we did that before
3182         we'd looked at all the factors that may force a layer to composite, so missed
3183         some cases. Fix by doing the repaint once we really know whether it's going
3184         to composite.
3185
3186         Test: compositing/repaint/become-overlay-composited-layer.html
3187
3188         * rendering/RenderLayerCompositor.cpp:
3189         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
3190
3191 2009-06-18  Simon Fraser  <simon.fraser@apple.com>
3192
3193         Fix the Leopard build where USE(ACCELERATED_COMPOSITING) is not defined, and
3194         the Tiger build where QTMovieLayer does not exist.
3195
3196         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3197         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3198         (WebCore::MediaPlayerPrivate::createQTMovieLayer):
3199         (WebCore::MediaPlayerPrivate::destroyQTMovieLayer):
3200         (WebCore::MediaPlayerPrivate::currentRenderingMode):
3201         (WebCore::MediaPlayerPrivate::setUpVideoRendering):
3202         (WebCore::MediaPlayerPrivate::tearDownVideoRendering):
3203         (WebCore::MediaPlayerPrivate::hasSetUpVideoRendering):
3204
3205 2009-06-18  Simon Fraser  <simon.fraser@apple.com>
3206
3207         Fix the Leopard build where USE(ACCELERATED_COMPOSITING) is not defined.
3208
3209         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3210         (WebCore::MediaPlayerPrivate::currentRenderingMode):
3211         (WebCore::MediaPlayerPrivate::setUpVideoRendering):
3212         (WebCore::MediaPlayerPrivate::tearDownVideoRendering):
3213
3214 2009-06-17  Erik Arvidsson  <arv@chromium.org>
3215
3216         Reviewed by Adele Peterson.
3217
3218         https://bugs.webkit.org/show_bug.cgi?id=15189
3219         Adds the HTML5 input event support for textarea.
3220         
3221         Also, moves the oninput attribute parse handling to HTMLElement so that
3222         it can be set on any HTML element so that bubbling events can be handled
3223         using HTML attribute handlers.
3224
3225         Test: fast/forms/textarea-input-event.html
3226
3227         * html/HTMLElement.cpp:
3228         (WebCore::HTMLElement::parseMappedAttribute):
3229         * html/HTMLInputElement.cpp:
3230         (WebCore::HTMLInputElement::parseMappedAttribute):
3231         * rendering/RenderTextControlMultiLine.cpp:
3232         (WebCore::RenderTextControlMultiLine::subtreeHasChanged):
3233
3234 2009-06-18  Dirk Schulze  <krit@webkit.org>
3235
3236         Reviewed by Oliver Hunt.
3237
3238         Share code between filterEffects
3239         [https://bugs.webkit.org/show_bug.cgi?id=26479]
3240
3241         Share more code of filter effects. The imageBuffer creation can move to
3242         FilterEffect ant every effect asks for the GraphicsContext. Move the
3243         drawingRect calculation to FilterEffect.
3244
3245         * platform/graphics/filters/FilterEffect.cpp:
3246         (WebCore::FilterEffect::calculateDrawingRect):
3247         (WebCore::FilterEffect::getEffectContext):
3248         * platform/graphics/filters/FilterEffect.h:
3249         * platform/graphics/filters/SourceGraphic.cpp:
3250         (WebCore::SourceGraphic::apply):
3251         * svg/graphics/filters/SVGFEFlood.cpp:
3252         (WebCore::FEFlood::apply):
3253         * svg/graphics/filters/SVGFEOffset.cpp:
3254         (WebCore::FEOffset::apply):
3255
3256 2009-06-18  Simon Fraser  <simon.fraser@apple.com>
3257
3258         Reviewed by Dave Hyatt.
3259         
3260         https://bugs.webkit.org/show_bug.cgi?id=26499
3261         
3262         Support hardware-accelerationed rendering of video elements.
3263
3264         * html/HTMLMediaElement.cpp:
3265         (WebCore::HTMLMediaElement::mediaPlayerSawUnsupportedTracks):
3266         (WebCore::HTMLMediaElement::mediaPlayerRepaint):
3267         Just move these methods to group the render-related methods together.
3268         
3269         (WebCore::HTMLMediaElement::mediaPlayerRenderingCanBeAccelerated):
3270         Call out method to ask the RenderLayerCompositor if presentation of this video
3271         can be acclerated. It might say no, if, for example, the video has a reflection.
3272         
3273         (WebCore::HTMLMediaElement::mediaPlayerGraphicsLayer):
3274         Fetch the GraphicsLayer from the RenderVideo that will host the movie layer.
3275         
3276         * html/HTMLMediaElement.h:
3277         Reordered the rendering-related methods, and added two methods related to video
3278         acceleration.
3279         
3280         * platform/graphics/MediaPlayer.cpp:
3281         (WebCore::MediaPlayer::acceleratedRenderingStateChanged):
3282         Called by the rendering system when it determines that the video must go into, or
3283         fall off of the hardware-accelerated path.
3284         
3285         (WebCore::MediaPlayer::supportsAcceleratedRendering):
3286         Method to say whether the media engine supports accelerated rendering.
3287         
3288         * platform/graphics/MediaPlayer.h:
3289         (WebCore::MediaPlayerClient::mediaPlayerRepaint):
3290         (WebCore::MediaPlayerClient::mediaPlayerSizeChanged):
3291         Moved.
3292         
3293         (WebCore::MediaPlayerClient::mediaPlayerRenderingCanBeAccelerated):
3294         (WebCore::MediaPlayerClient::mediaPlayerGraphicsLayer):
3295         New methods to ask the client if the rendering system can support accelerated
3296         rendering, and to get a GraphicsLayer to plug the movie layer into.
3297         
3298         * platform/graphics/MediaPlayerPrivate.h:
3299         (WebCore::MediaPlayerPrivateInterface::supportsAcceleratedRendering):
3300         (WebCore::MediaPlayerPrivateInterface::acceleratedRenderingStateChanged):
3301         Forwarding methods from MediaPlayer.
3302         
3303         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3304         Some new methods related to using a QTMovieLayer, and to simplify the rendering mode logic.
3305
3306         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3307         (WebCore::MediaPlayerPrivate::createQTMovieLayer):
3308         (WebCore::MediaPlayerPrivate::destroyQTMovieLayer):
3309         Methods to create and destroy the QTMovieLayer.
3310         
3311         (WebCore::MediaPlayerPrivate::currentRenderingMode):
3312         (WebCore::MediaPlayerPrivate::preferredRenderingMode):
3313         Methods to clarify the code that decides which of the 3 rendering modes to use.
3314         
3315         (WebCore::MediaPlayerPrivate::setUpVideoRendering):
3316         Changed to use the new rendering mode methods.
3317         
3318         (WebCore::MediaPlayerPrivate::tearDownVideoRendering):
3319         Destroy the layer if we have one.
3320         
3321         (WebCore::MediaPlayerPrivate::hasSetUpVideoRendering):
3322         Small utility method.
3323         
3324         (WebCore::MediaPlayerPrivate::updateStates):
3325         Move the call to setUpVideoRendering() to before we send out the state notifications,
3326         so that we will have created the rendering objects already.
3327         
3328         (WebCore::MediaPlayerPrivate::supportsAcceleratedRendering):
3329         Return true if we have QTMovieLayer.
3330         
3331         (WebCore::MediaPlayerPrivate::acceleratedRenderingStateChanged):
3332         We've been told that we went into or out of accelerated mode; maybe reset
3333         the renderer, and set the layer if we have to.
3334         
3335         * rendering/RenderLayer.cpp:
3336         (WebCore::RenderLayer::rendererContentChanged):
3337         We may need to udpate compositing layers if the video went into accelerated mode.
3338         
3339         * rendering/RenderLayerBacking.cpp:
3340         (WebCore::RenderLayerBacking::canUseDirectCompositing):
3341         Add smarts to deal with video, which allows us to avoid extra backing store.
3342         
3343         (WebCore::RenderLayerBacking::contentsBox):
3344         Use the videoBox to use the content layer for video layers.
3345         
3346         * rendering/RenderLayerCompositor.cpp:
3347         (WebCore::RenderLayerCompositor::updateLayerCompositingState):
3348         Poke the RenderVideo if the state changed.
3349         
3350         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
3351         Handle an edge case when the video element itself is a stacking context
3352         because of opacity or transform.
3353         
3354         (WebCore::RenderLayerCompositor::canAccelerateVideoRendering):
3355         (WebCore::RenderLayerCompositor::requiresCompositingLayer):
3356         (WebCore::RenderLayerCompositor::requiresCompositingForVideo):
3357         Allow video to throw us into compositing mode if the media engine supports it.
3358         
3359         * rendering/RenderLayerCompositor.h:
3360         New methods related to video.
3361         
3362         * rendering/RenderVideo.h:
3363         * rendering/RenderVideo.cpp:
3364         (WebCore::RenderVideo::updatePlayer):
3365         Call rendererContentChanged() to give the compositor a change to throw the video into
3366         compositing mode.
3367         
3368         (WebCore::RenderVideo::supportsAcceleratedRendering):
3369         (WebCore::RenderVideo::acceleratedRenderingStateChanged):
3370         (WebCore::RenderVideo::videoGraphicsLayer):
3371         Methods to allow the MediaPlayer to do rendering-related stuff via the media element.
3372
3373 2009-06-18  Rob Buis  <rwlbuis@gmail.com>
3374
3375         Reviewed by Niko.
3376
3377         https://bugs.webkit.org/show_bug.cgi?id=26385
3378         Root SVG element is not checked on requiredFeatures, requiredExtension like other elements
3379
3380         Also do the isValid check for outer <svg>.
3381
3382         Test: svg/custom/outer-svg-unknown-feature.svg
3383
3384         * svg/SVGDocument.cpp:
3385         (WebCore::SVGDocument::childShouldCreateRenderer):
3386         * svg/SVGDocument.h:
3387
3388 2009-06-18  Dan Bernstein  <mitz@apple.com>
3389
3390         Reviewed by Darin Adler.
3391
3392         - fix <rdar://problem/6913221> REGRESSION (Safari 3-4): Search field on
3393           apple.com cuts entered text
3394
3395         Test: fast/forms/search-vertical-alignment.html
3396
3397         * rendering/RenderTextControlSingleLine.cpp:
3398         (WebCore::RenderTextControlSingleLine::layout): Vertically center the
3399             the search field's inner block.
3400
3401 2009-06-18  Janne Koskinen  <janne.p.koskinen@digia.com>
3402
3403         Reviewed by Simon Hausmann.
3404
3405         Fix compilation with Symbian WINSCW compiler, which produced
3406         multiple definitions of the CSSPrimitiveValue conversion operators.
3407
3408         It turns out that they are defined inline but not declared inline.
3409
3410         Adding the inline keyword to the declaration fixes the build.
3411
3412         * css/CSSPrimitiveValue.h:
3413
3414 2009-06-18  Markus Goetz <Markus.Goetz@nokia.com>
3415
3416         Reviewed by Simon Hausman.
3417
3418         Clarify in docs how to compile with debug information.
3419
3420         * WebCore.pro:
3421
3422 2009-06-18  Jakub Wieczorek  <faw217@gmail.com>
3423
3424         Reviewed by Simon Hausmann.
3425
3426         [Qt] When writing an URL to the clipboard, save the corresponding title
3427         in the mime data as well.
3428
3429         * platform/qt/ClipboardQt.cpp:
3430         (WebCore::ClipboardQt::writeURL):
3431
3432 2009-06-18  Jakub Wieczorek  <faw217@gmail.com>
3433
3434         [Qt] Fix build. Add HTMLDataGridElement.
3435
3436         * WebCore.pro:
3437
3438 2009-06-18  Jan Michael Alonzo  <jmalonzo@webkit.org>
3439
3440         Gtk build fix.
3441
3442         Add HTMLDataGridElement header and IDL to the build script.
3443
3444         * GNUmakefile.am:
3445
3446 2009-06-18  Chris Evans  <scarybeasts@gmail.com>
3447
3448         Reviewed by Adam Barth.
3449
3450         Fix 8-digit long hex entities. Fixes bug 26454
3451         https://bugs.webkit.org/show_bug.cgi?id=26454
3452
3453         Test: fast/parser/eightdigithexentity.html
3454
3455         * html/HTMLTokenizer.cpp: fix off-by-ones.
3456
3457 2009-06-18  David Levin  <levin@chromium.org>
3458
3459         Fix chromium linux build.
3460
3461         Fixes a mistake that happened during the complicated merge for
3462         landing r44775, r44776, r44777.
3463
3464         * rendering/RenderThemeChromiumLinux.cpp:
3465         (WebCore::RenderThemeChromiumLinux::create):
3466
3467 2009-06-17  Simon Fraser  <simon.fraser@apple.com>
3468
3469         Reviewed by Darin Adler.
3470         
3471         https://bugs.webkit.org/show_bug.cgi?id=26499
3472         
3473         First step to making video rendering be hardware-accelerated:
3474         make <video> elements get self-painting RenderLayers, and add
3475         an isVideo() virtual method to RenderObject.
3476
3477         * html/HTMLMediaElement.cpp:
3478         (WebCore::HTMLMediaElement::setReadyState):
3479         (WebCore::HTMLMediaElement::mediaPlayerDurationChanged):
3480         (WebCore::HTMLMediaElement::mediaPlayerSizeChanged):
3481         * rendering/RenderLayer.cpp:
3482         (WebCore::RenderLayer::shouldBeNormalFlowOnly):
3483         (WebCore::RenderLayer::isSelfPaintingLayer):
3484         * rendering/RenderObject.h:
3485         (WebCore::RenderObject::isVideo):
3486         * rendering/RenderVideo.h:
3487         (WebCore::RenderVideo::requiresLayer):
3488         (WebCore::RenderVideo::isVideo):
3489
3490 2009-06-17  Brent Fulgham  <bfulgham@webkit.org>
3491
3492         Reviewed by Adam Roben.
3493
3494         Refactor a few common routines in the various Windows ports
3495         and reduce some duplicated code.
3496
3497         (1) Create TransformationMatrix XFORM casting operator, and
3498             switch various XFORM structure uses to utilize it.
3499         (2) Push concatCTM call to GraphicsContextWin now that the
3500             TransformationMatrix can directly create XFORM (rather
3501             than converting to CGAffineTransform/cairo_matrix_t first.)
3502
3503         * WebCore.vcproj/WebCore.vcproj: Add new BitmapInfo structure.
3504         * platform/graphics/transforms/TransformationMatrix.h:
3505         * platform/graphics/win/GraphicsContextCGWin.cpp:
3506         * platform/graphics/win/GraphicsContextCairoWin.cpp:
3507         * platform/graphics/win/GraphicsContextWin.cpp:
3508         (WebCore::GraphicsContextPlatformPrivate::scale):
3509         (WebCore::GraphicsContextPlatformPrivate::rotate):
3510         (WebCore::GraphicsContextPlatformPrivate::translate):
3511         (WebCore::GraphicsContextPlatformPrivate::concatCTM):
3512         * platform/graphics/win/TransformationMatrixWin.cpp: Added.
3513         (WebCore::TransformationMatrix::operator XFORM): New operator
3514
3515 2009-06-17  Brent Fulgham  <bfulgham@webkit.org>
3516
3517         Non-CG Windows build fix after @r44758.
3518
3519         * rendering/RenderThemeWin.cpp:
3520         (WebCore::RenderTheme::themeForPage):
3521
3522 2009-06-17  Brent Fulgham  <bfulgham@webkit.org>
3523
3524         Reviewed by Adam Roben.
3525
3526         Refactor a few common routines in the various Windows ports
3527         and reduce some duplicated code.
3528         https://bugs.webkit.org/show_bug.cgi?id=26425.
3529
3530         Refactor use of BITMAPINFO for the new BitmapInfo structure.
3531
3532         * WebCore.vcproj/WebCore.vcproj:
3533         * platform/win/BitmapInfo.cpp: Added.
3534         (WebCore::bitmapInfoForSize):
3535         (WebCore::BitmapInfo::create):
3536         (WebCore::BitmapInfo::createBottomUp):
3537         * platform/win/BitmapInfo.h: Added.
3538         * platform/graphics/win/GraphicsContextCairoWin.cpp:
3539         * platform/graphics/win/GraphicsContextCGWin.cpp:
3540         * platform/graphics/win/TransformationMatrixWin.cpp: Added.
3541         (WebCore::TransformationMatrix::operator XFORM): New operator
3542         * platform/win/DragImageCGWin.cpp:
3543         (WebCore::allocImage):
3544         * platform/win/DragImageCairoWin.cpp:
3545         (WebCore::allocImage):
3546         * platform/win/PasteboardWin.cpp:
3547         (WebCore::Pasteboard::writeImage):
3548         * platform/win/PopupMenuWin.cpp:
3549         (WebCore::PopupMenu::paint):
3550
3551 2009-06-17  Adam Roben  <aroben@apple.com>
3552
3553         Remove unnecessary 6th parameter from SOFT_LINK_OPTIONAL
3554
3555         Reviewed by Mark Rowe.
3556
3557         * platform/graphics/win/ColorSafari.cpp: Removed the 6th parameter and
3558         an unnecessary parameter name.
3559         * platform/win/SoftLinking.h: Removed the unused 6th parameter.
3560
3561 2009-06-17  Adam Roben  <aroben@apple.com>
3562
3563         Make Settings::shouldPaintNativeControls default to true
3564
3565         This matches the default up in WebKit (that was changed in r43318).
3566
3567         Fixes Bug 26493: REGRESSION (r44758): First tab always uses Mac-style
3568         form controls
3569         <https://bugs.webkit.org/show_bug.cgi?id=26493>
3570
3571         Reviewed by Darin Adler and Dave Hyatt.
3572
3573         No test possible since DRT always uses Mac-style form controls.
3574
3575         * page/Settings.cpp: Changed the initial value of
3576         gShouldPaintNativeControls to true.
3577
3578         * rendering/RenderThemeSafari.cpp:
3579         (WebCore::RenderTheme::themeForPage): Added a FIXME about the design
3580         flaw here involving querying Settings before it's been initialized.
3581
3582 2009-06-17  David Levin  <levin@chromium.org>
3583
3584         Fix chromium windows build.
3585
3586         A mistake that happened during the complicated merge for
3587         landing r44775, r44776, r44777.
3588
3589         * rendering/RenderThemeChromiumWin.h:
3590         (WebCore::RenderThemeChromiumWin::RenderThemeChromiumWin):
3591         (WebCore::RenderThemeChromiumWin::~RenderThemeChromiumWin):
3592
3593 2009-06-17  Eric Carlson  <eric.carlson@apple.com>
3594
3595         Reviewed by Simon Fraser.
3596
3597     &nbs