2009-09-30 Maciej Stachowiak <mjs@apple.com>
[WebKit.git] / WebCore / ChangeLog
1 2009-09-30  Maciej Stachowiak  <mjs@apple.com>
2
3         Reviewed by Brady Eidson.
4
5         307 redirects should pass along http body and Content-Type header
6         https://bugs.webkit.org/show_bug.cgi?id=29943
7
8         Follow-up fix for:
9         <rdar://problem/3802660> SAP: 307 (Temporary Redirect) responses should use POST, not GET
10         
11         Test: http/tests/loading/resources/redirect-methods-result.php
12
13         * platform/network/cf/ResourceHandleCFNet.cpp:
14         (WebCore::willSendRequest): Pass along http body and Content-Type header.
15         * platform/network/mac/ResourceHandleMac.mm:
16         (-[WebCoreResourceHandleAsDelegate connection:willSendRequest:redirectResponse:]): ditto
17
18 2009-09-30  Geoffrey Garen  <ggaren@apple.com>
19
20         Reviewed by Mark Rowe.
21
22         Fixed https://bugs.webkit.org/show_bug.cgi?id=29941
23         REGRESSION (r48882-r48888): Many memory leaks on SnowLeopard leaks bot
24
25         Forgot to implement a destructor for JSDOMWindowBaseData, so it was
26         leaking its RefPtr data member.
27
28         * bindings/js/JSDOMWindowBase.cpp:
29         (WebCore::JSDOMWindowBase::destroyJSDOMWindowBaseData):
30         * bindings/js/JSDOMWindowBase.h:
31         (WebCore::JSDOMWindowBase::JSDOMWindowBaseData::JSDOMWindowBaseData::JSDOMWindowBaseData):
32
33 2009-09-30  Dave Hyatt  <hyatt@apple.com>
34
35         Reviewed by Tim Hatcher.
36
37         Make sure the removal of user stylesheets results in all of the WebViews being updated to
38         reflect the changes.
39
40         * page/PageGroup.cpp:
41         (WebCore::PageGroup::removeUserContentWithURLForWorld):
42         (WebCore::PageGroup::removeUserContentForWorld):
43
44 2009-09-30  Dan Bernstein  <mitz@apple.com>
45
46         Reviewed by Sam Weinig.
47
48         REGRESSION(r47440): drop down menus at americanexpress.com disappear on mouse out
49         https://bugs.webkit.org/show_bug.cgi?id=29209
50
51         Test: fast/inline/relative-positioned-overflow.html
52
53         * rendering/InlineFlowBox.cpp:
54         (WebCore::InlineFlowBox::computeVerticalOverflow): Add self-painting
55         inlines to overflow to ensure that they are included in hit-testing.
56
57 2009-09-30  Simon Fraser  <simon.fraser@apple.com>
58
59         Reviewed by Mark Rowe.
60
61         transforms/3d tests are not run in Release builds
62         https://bugs.webkit.org/show_bug.cgi?id=29827
63
64         Make sure we export the WebCoreHas3DRendering symbol in Release builds,
65         because this symbols is used by run-webkit-tests (via 'nm') to detect whether
66         WebCore was built with ENABLE_3D_RENDERING turned on.
67
68         * DerivedSources.make:
69         * WebCore.3DRendering.exp: Added.
70         * WebCore.xcodeproj/project.pbxproj:
71
72 2009-09-30  Jeremy Orlow  <jorlow@chromium.org>
73
74         Build fix for QT.  Didn't know WebCore.pro existed.
75
76         * WebCore.pro:
77
78 2009-09-30  Dave Hyatt  <hyatt@apple.com>
79
80         Reviewed by Adam Roben.
81
82         Add a method for removal of user scripts and stylesheets by URL from a specific world.
83
84         * page/PageGroup.cpp:
85         (WebCore::PageGroup::removeUserContentURLForWorld):
86         * page/PageGroup.h:
87
88 2009-09-30  Chris Hawk  <hawk@chromium.org>
89
90         Reviewed by Dimitri Glazkov.
91
92         Fix for conditionals in the WebCore gyp file, which contained two separate
93         'conditions' values for the webcore target. The first entry was ignored,
94         resulting in some missine defines.
95         https://bugs.webkit.org/show_bug.cgi?id=29907
96
97         * WebCore.gyp/WebCore.gyp:
98
99 2009-09-21  Jeremy Orlow  <jorlow@chromium.org>
100
101         Reviewed by Adam Barth.
102
103         DOM Storage needs to be more careful about where "ThreadSafe" objects are destroyed.
104         https://bugs.webkit.org/show_bug.cgi?id=29265
105
106         DOM Storage needs to be more careful about where "ThreadSafe" objects are
107         destroyed.  With the current code, there actually isn't a race condition, but
108         it sure would be easy for someone to introduce one.  A bunch of
109         ThreadSafeShared objects have RefPtrs to objects that are NOT ThreadSafeShared
110         objects.  If it were possible any of these objects' destructors to be fired off
111         the main thread, then the you'd have a race condition.  The code should be more
112         clear and self-documenting about how things related to each other.
113
114         Since the lifetime of a LocalStorageTask is bounded by the LocalStorageThread
115         which is bounded by the StorageSyncManager, StorageAreaImpl, and
116         StorageAreaSync, there's no reason for LocalStorageTask to store anything other
117         than pointers.  By breaking this dependency, we can eliminate the risk.
118
119         Note that we _could_ have LocalStorageThread's task queue just store
120         LocalStorageTask*'s rather than RefPtr<LocalStorageTask>s but then we'd need to
121         manually take care of deleting.  It'd probably also be possible to change
122         LocalStorageThread around so that it needn't hold onto a reference of itself
123         and have a more deterministic shutdown, but my initial attempts to do so
124         failed, and I decided it wasn't worth changing.  The queue is killed before
125         hand, so the thread is 100% impotent before the main thread continues anyway.
126
127         The constructors and destructors of StorageSyncManager, StorageAreaImpl, and
128         StorageAreaSync now have ASSERTs to verify they're running on the main thread. 
129         I'm fairly positive that it'd be impossible to hit these asserts and the fact
130         that these classes are no longer ThreadSafeShared should make it clear how
131         they're meant to be used, but I think it's worth it to be extra sure.  Of
132         course, ideally, we'd have such an assert every time a ref is incremented or
133         decremented.
134
135         Behavior should be unchanged and this is just an internal code cleanup, so no
136         new tests.
137
138         * storage/LocalStorageTask.cpp:
139         (WebCore::LocalStorageTask::LocalStorageTask):
140         (WebCore::LocalStorageTask::performTask):
141         * storage/LocalStorageTask.h:
142         (WebCore::LocalStorageTask::createImport):
143         (WebCore::LocalStorageTask::createSync):
144         (WebCore::LocalStorageTask::createTerminate):
145         * storage/LocalStorageThread.cpp:
146         (WebCore::LocalStorageThread::scheduleImport):
147         (WebCore::LocalStorageThread::scheduleSync):
148         * storage/LocalStorageThread.h:
149         * storage/StorageArea.h:
150         * storage/StorageAreaImpl.cpp:
151         (WebCore::StorageAreaImpl::~StorageAreaImpl):
152         (WebCore::StorageAreaImpl::StorageAreaImpl):
153         * storage/StorageAreaSync.cpp:
154         (WebCore::StorageAreaSync::StorageAreaSync):
155         (WebCore::StorageAreaSync::~StorageAreaSync):
156         * storage/StorageSyncManager.cpp:
157         (WebCore::StorageSyncManager::StorageSyncManager):
158         (WebCore::StorageSyncManager::~StorageSyncManager):
159         (WebCore::StorageSyncManager::scheduleImport):
160         (WebCore::StorageSyncManager::scheduleSync):
161         * storage/StorageSyncManager.h:
162
163 2009-09-28  Jeremy Orlow  <jorlow@chromium.org>
164
165         Reviewed by Darin Fisher.
166
167         Chromium needs to be able to override the way storage events are delivered
168         https://bugs.webkit.org/show_bug.cgi?id=29655
169
170         Chromium needs to be able to override the way storage events are delivered.
171         This replaced https://bugs.webkit.org/show_bug.cgi?id=29257 because it'll be
172         faster (no vtables and extra allocation) and somewhat cleaner (no dependency
173         injection).  This is necessary because Chromium needs to transport events across
174         a process barrier and then dispatch them without use of a Frame*.
175
176         Behavior should not change with this, so no updates to tests.
177
178         * GNUmakefile.am:
179         * WebCore.gypi:
180         * WebCore.vcproj/WebCore.vcproj:
181         * WebCore.xcodeproj/project.pbxproj:
182         * WebCoreSources.bkl:
183         * storage/StorageAreaImpl.cpp:
184         (WebCore::StorageAreaImpl::setItem):
185         (WebCore::StorageAreaImpl::removeItem):
186         (WebCore::StorageAreaImpl::clear):
187         * storage/StorageAreaImpl.h:
188         * storage/StorageEventDispatcher.cpp: Copied from WebCore/storage/StorageAreaImpl.cpp.
189         (WebCore::StorageEventDispatcher::dispatch):
190         * storage/StorageEventDispatcher.h: Added.  (Well, technically in the other half of this patch.)
191
192 2009-09-30  Jian Li  <jianli@chromium.org>
193
194         Reviewed by Darin Adler.
195
196         Need to check NULL frame in EventHandler::updateDragAndDrop.
197         https://bugs.webkit.org/show_bug.cgi?id=29929
198
199         Test: http/tests/misc/drag-over-iframe-invalid-source-crash.html
200
201         * page/EventHandler.cpp:
202         (WebCore::EventHandler::updateDragAndDrop):
203
204 2009-09-29  Simon Fraser  <simon.fraser@apple.com>
205
206         Reviewed by Dan Bernstein.
207
208         ASSERTION FAILED: !repaintContainer || repaintContainer == this
209         https://bugs.webkit.org/show_bug.cgi?id=29755
210         
211         Generalize the fix for this bug to account for cases where there may be multiple
212         containing blocks between the repaint container, and the container of the element
213         being repainted.
214
215         Test: compositing/repaint/opacity-between-absolute2.html
216
217         * rendering/RenderBox.cpp:
218         (WebCore::RenderBox::mapLocalToContainer):
219         Call offsetFromAncestorContainer() to get the correct offset.
220         
221         (WebCore::RenderBox::computeRectForRepaint): Ditto
222         * rendering/RenderInline.cpp:
223         (WebCore::RenderInline::computeRectForRepaint): Ditto.
224         
225         * rendering/RenderObject.h:
226         * rendering/RenderObject.cpp:
227         (WebCore::RenderObject::offsetFromAncestorContainer):
228         New method that computes an offset from some object in the ancestor container() chain.
229
230 2009-09-30  Andras Becsi  <becsi.andras@stud.u-szeged.hu>
231
232         Reviewed by Simon Hausmann.
233
234         [Qt] Fix TextCodecQt::decode method after r48752 to return a non-null string if the length of the input is 0.
235         This fixes https://bugs.webkit.org/show_bug.cgi?id=29736.
236
237         * platform/text/qt/TextCodecQt.cpp:
238         (WebCore::TextCodecQt::decode):
239
240 2009-09-29  Dave Hyatt  <hyatt@apple.com>
241
242         Reviewed by Jon Honeycutt.
243
244         Fix a couple of bugs with patterns.  Move the setting of the document URL to before the style
245         selector gets constructed so that pattern match testing gets the correct URL.
246
247         * loader/FrameLoader.cpp:
248         (WebCore::FrameLoader::begin):
249         * page/UserContentURLPattern.cpp:
250         (WebCore::UserContentURLPattern::parse):
251
252 2009-09-29  Alexey Proskuryakov  <ap@apple.com>
253
254         Rubber-stamped by Brady Eidson.
255
256         Assertion failure in http/tests/xmlhttprequest/failed-auth.html.
257
258         I couldn't find out why this only started to happen now, but it was incorrect to check
259         persistence of a credential returned by CredentialStorage::get() without checking that it
260         was non-null. When there is no credential for the protection space in storage, get()
261         returns a new object, and Credentil constructor doesn't initialize m_persistence.
262
263         * platform/network/mac/ResourceHandleMac.mm:
264         (-[WebCoreSynchronousLoader connection:didReceiveAuthenticationChallenge:]): Moved the
265         assertion after credential null check.
266         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Added the same persistence
267         assertion, matching sync code (and CF one, as well).
268
269 2009-09-29  Yong Li  <yong.li@torchmobile.com>
270
271         Reviewed by Darin Adler.
272
273         Add an ASSERT for UTF8Encoding().isValid()
274         https://bugs.webkit.org/show_bug.cgi?id=29908
275
276         * platform/text/TextEncoding.cpp:
277         (WebCore::UTF8Encoding):
278
279 2009-09-29  Dave Hyatt  <hyatt@apple.com>
280
281         Reviewed by Jon Honeycutt.
282
283         https://bugs.webkit.org/show_bug.cgi?id=29892
284         Add support for whitelist patterns to control conditional injection of user scripts and
285         user stylesheets.
286
287         No new tests. Not testable until WebKit portion is added in followup patch.
288
289         * GNUmakefile.am:
290         * WebCore.gypi:
291         * WebCore.pro:
292         * WebCore.vcproj/WebCore.vcproj:
293         * WebCore.xcodeproj/project.pbxproj:
294         * dom/Document.cpp:
295         (WebCore::Document::pageGroupUserSheets):
296         * page/Frame.cpp:
297         (WebCore::Frame::injectUserScriptsForWorld):
298         * page/UserContentURLPattern.cpp: Added.
299         (WebCore::UserContentURLPattern::matchesPatterns):
300         (WebCore::UserContentURLPattern::parse):
301         (WebCore::UserContentURLPattern::matches):
302         (WebCore::UserContentURLPattern::matchesHost):
303         (WebCore::MatchTester::MatchTester):
304         (WebCore::MatchTester::testStringFinished):
305         (WebCore::MatchTester::patternStringFinished):
306         (WebCore::MatchTester::eatWildcard):
307         (WebCore::MatchTester::eatSameChars):
308         (WebCore::MatchTester::test):
309         (WebCore::UserContentURLPattern::matchesPath):
310         * page/UserContentURLPattern.h: Added.
311         (WebCore::UserContentURLPattern::UserContentURLPattern):
312         (WebCore::UserContentURLPattern::scheme):
313         (WebCore::UserContentURLPattern::host):
314         (WebCore::UserContentURLPattern::path):
315         (WebCore::UserContentURLPattern::matchSubdomains):
316
317 2009-09-29  Enrica Casucci  <enrica@apple.com>
318
319         Reviewed by Adele Peterson.
320
321         Reproducible crash pressing return inside quoted content
322         at WebCore::BreakBlockquoteCommand::doApply.
323         <rdar://problem/7085453>
324         In some case, like the one provided in the test case, m_downStreamEnd
325         refers to a node that gets deleted when executing the DeleteSelectionCommand.
326         We shouldn't use m_downStreamEnd to recalculate the new m_endPosition when
327         pruning is needed, because it may be point to a node that has been deleted, but
328         rather rely on removeNode in CompositeEditCommand to update m_endPosition correctly.
329
330         Test: editing/selection/blockquote-crash.html
331
332         * editing/BreakBlockquoteCommand.cpp:
333         (WebCore::BreakBlockquoteCommand::doApply): Added check for invalid position
334         to avoid dereferencing a null node pointer.
335         * editing/DeleteSelectionCommand.cpp:
336         (WebCore::DeleteSelectionCommand::mergeParagraphs): Don't reset m_endPosition
337         using the value in m_downStreamEnd when it is necessary to prune the start block.
338         
339 2009-09-29  Alexey Proskuryakov  <ap@apple.com>
340
341         Reviewed by Brady Eidson.
342
343         Basic authentication credentials are not sent automatically to top resources
344         https://bugs.webkit.org/show_bug.cgi?id=29901
345
346         No new tests - I don't want to pollute root directory of http tests to check for this rather
347         minor issue.
348
349         * platform/network/CredentialStorage.cpp:
350         (WebCore::CredentialStorage::set): Changed to always preserve leading slash.
351         (WebCore::CredentialStorage::getDefaultAuthenticationCredential): Made breaking out of the
352         loop more explicit.
353
354 2009-09-29  Pavel Feldman  <pfeldman@chromium.org>
355
356         Reviewed by Oliver Hunt.
357
358         Web Inspector REGRESSION(r47820-r47822): Profiles aren't
359         added to the inspector unless the inspector is already open
360         when the profile completes.
361
362         https://bugs.webkit.org/show_bug.cgi?id=29897
363
364         * inspector/front-end/ProfilesPanel.js:
365         (WebInspector.ProfilesPanel.prototype._populateProfiles):
366
367 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
368
369         Rubberstamped by David Hyatt.
370
371         Fix to logic of earlier commit 48902.
372
373         When merging two if's before committing, I forgot to invert the
374         bool check.
375
376         * platform/network/qt/QNetworkReplyHandler.cpp:
377         (WebCore::ignoreHttpError):
378
379 2009-09-29  Stephen White  <senorblanco@chromium.org>
380
381         Unreviewed, build fix.
382
383         Fixing Chromium build, following r48884.
384
385         [https://bugs.webkit.org/show_bug.cgi?id=29894]
386
387         * bindings/v8/V8AbstractEventListener.cpp:
388         (WebCore::V8AbstractEventListener::handleEvent):
389         * bindings/v8/V8AbstractEventListener.h:
390         * bindings/v8/V8WorkerContextEventListener.cpp:
391         (WebCore::V8WorkerContextEventListener::handleEvent):
392         * bindings/v8/V8WorkerContextEventListener.h:
393
394 2009-09-29  Kent Tamura  <tkent@chromium.org>
395
396         Reviewed by Darin Adler.
397
398         Follows HTML5's maxLength change in September 2009.
399         - Change HTMLTextAreaElement.maxLength type to signed.
400         - HTMLTextAreaElement.maxLength returns -1 if maxlength= attribute is missing.
401         - HTMLTextAreaElement.maxLength and HTMLInputElement.maxLength
402           throw INDEX_SIZE_ERR for setting negative values.
403         https://bugs.webkit.org/show_bug.cgi?id=29796
404
405         * html/HTMLInputElement.cpp:
406         (WebCore::HTMLInputElement::setMaxLength):
407         * html/HTMLInputElement.h:
408         * html/HTMLInputElement.idl:
409         * html/HTMLTextAreaElement.cpp:
410         (WebCore::HTMLTextAreaElement::handleBeforeTextInsertedEvent):
411         (WebCore::HTMLTextAreaElement::maxLength):
412         (WebCore::HTMLTextAreaElement::setMaxLength):
413         * html/HTMLTextAreaElement.h:
414         * html/HTMLTextAreaElement.idl:
415
416 2009-09-29  Dimitri Glazkov  <dglazkov@chromium.org>
417
418         No review, rolling out r48894, because review discussion was not complete.
419         http://trac.webkit.org/changeset/48894
420
421         * platform/sql/SQLiteTransaction.cpp:
422         (WebCore::SQLiteTransaction::begin):
423
424 2009-09-29  Dirk Schulze  <krit@webkit.org>
425
426         Reviewed by Nikolas Zimmermann.
427
428         SVG Filter feComposite implementation is missing
429         [https://bugs.webkit.org/show_bug.cgi?id=28362]
430
431         feComposite implementation for SVG.
432
433         Test: svg/filters/feComposite.svg
434
435         * platform/graphics/filters/FEComposite.cpp:
436         (WebCore::arithmetic):
437         (WebCore::FEComposite::apply):
438
439 2009-09-29  Dumitru Daniliuc  <dumi@chromium.org>
440
441         Reviewed by Dimitri Glazkov.
442
443         Starting all read-only transactions with an explicit BEGIN
444         DEFERRED command instead of BEGIN, since some ports (chromium)
445         might compile their own SQLite library and set BEGIN to BEGIN
446         IMMEDIATE by default; which would result in a deadlock in case of
447         two concurrent read-only transactions on the same DB, and would
448         unnecessarily delay other potential transactions to the same DB.
449
450         https://bugs.webkit.org/show_bug.cgi?id=29729
451
452         * platform/sql/SQLiteTransaction.cpp:
453         (WebCore::SQLiteTransaction::begin):
454
455 2009-09-29  Kenneth Russell  <kbr@google.com>
456
457         Reviewed by Dimitri Glazkov.
458
459         Add support for run-time flag for 3D canvas
460         https://bugs.webkit.org/show_bug.cgi?id=29826
461
462         * html/HTMLCanvasElement.cpp:
463         (WebCore::HTMLCanvasElement::getContext): Check page settings for
464         experimental WebGL flag before returning 3D graphics context.
465         * page/Settings.cpp:
466         (WebCore::Settings::Settings): Initialize new flag to false.
467         (WebCore::Settings::setExperimentalWebGLEnabled):
468         * page/Settings.h: Set new flag.
469         (WebCore::Settings::experimentalWebGLEnabled): Return new flag.
470
471 2009-09-29  Jeremy Orlow  <jorlow@chromium.org>
472
473         Reviewed by Darin Fisher.
474
475         Chromium needs to be able to override the way storage events are delivered - part 1
476         https://bugs.webkit.org/show_bug.cgi?id=29889
477
478         Chromium needs to be able to override the way storage events are delivered.
479         This replaced https://bugs.webkit.org/show_bug.cgi?id=29257 because it'll be
480         faster (no vtables and extra allocation) and somewhat cleaner (no dependency
481         injection).  This is necessary because Chromium needs to transport events across
482         a process barrier and then dispatch them without use of a Frame*.
483
484         This patch should be a no-op for all ports other than Chromium.
485
486         * WebCore.gypi:
487         * storage/StorageEventDispatcher.h: Added.
488
489 2009-09-29  Oliver Hunt  <oliver@apple.com>
490
491         Reviewed by NOBODY (missed file).
492
493         Adding file missed in previous commit.
494
495         * manual-tests/gtk/resources/long_cell.cur: Copied from WebCore/dom/PositionCreationFunctions.h.
496
497 2009-09-29  Dimitri Glazkov  <dglazkov@chromium.org>
498
499         Reviewed by Darin Fisher.
500
501         [V8] Correct an issue with XMLHttpRequest attribute event listeners never being cleared.
502         https://bugs.webkit.org/show_bug.cgi?id=29888
503
504         Test: LayoutTests/http/tests/xmlhttprequest/xmlhttprequest-abort-readyState-shouldDispatchEvent.html
505
506         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
507         (WebCore::getEventListener): Added isAttribute parameter.
508         (WebCore::ACCESSOR_SETTER): Made all event listener setters create attribute listeners.
509         (WebCore::CALLBACK_FUNC_DECL): Made addEventListener create object listener.
510
511 2009-09-22  Martin Robinson  <martin.james.robinson@gmail.com>
512
513         Reviewed by Eric Seidel.
514
515         Fix corruption for non-square images.
516
517         [GTK] REGRESSION: BitmapImage::getGdkPixbuf fails for non-square images
518         https://bugs.webkit.org/show_bug.cgi?id=29654
519
520         Added an additional manual-test for this issue to the existing Gtk
521         cursor image test.
522
523         * manual-tests/gtk/cursor-image.html:
524         * manual-tests/gtk/resources/long_cell.cur: Added.
525         * platform/graphics/gtk/ImageGtk.cpp:
526         (WebCore::BitmapImage::getGdkPixbuf):
527
528 2009-09-29  Alexey Proskuryakov  <ap@apple.com>
529
530         Reviewed by Timothy Hatcher.
531
532         Build fix - pass a proper ScriptExecutipnContext to getEventListenerHandlerBody()
533
534         * bindings/js/ScriptEventListener.cpp:
535         (WebCore::getEventListenerHandlerBody):
536         * bindings/js/ScriptEventListener.h:
537         * bindings/v8/ScriptEventListener.cpp:
538         (WebCore::getEventListenerHandlerBody):
539         * bindings/v8/ScriptEventListener.h:
540         * inspector/InspectorDOMAgent.cpp:
541         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
542
543 2009-09-29  Nate Chapin  <japhet@chromium.org>
544
545         Reviewed by Eric Seidel.
546
547         Ensure that we don't scroll lock to an anchor node after a
548         user-initiated scroll, even if that scroll doesn't propagate
549         all the way up to FrameView.
550
551         Test: fast/events/node-event-anchor-lock.html
552
553         * page/EventHandler.cpp: Call setFrameWasScrolledByUser() when a scroll is handled by a node rather than a frame.
554         (WebCore::EventHandler::scrollOverflow):
555         (WebCore::EventHandler::handleWheelEvent):
556         (WebCore::EventHandler::sendScrollEvent): Use setFrameWasScrolledByUser();
557         (WebCore::EventHandler::setFrameWasScrolledByUser): Split out of sendScrollEvent();
558         (WebCore::EventHandler::passMousePressEventToScrollbar):
559         * page/EventHandler.h: Declare setFrameWasScrolledByUser().
560
561 2009-09-28  Alexey Proskuryakov  <ap@apple.com>
562
563         Reviewed by Darin Adler and Sam Weinig.
564
565         Onclick not fired for an element copied with cloneContents() or cloneNode()
566         https://bugs.webkit.org/show_bug.cgi?id=25130
567
568         The change here is that JS event listeners don't keep a reference to a global object from
569         where they were created, and instead take it as a parameter when parsing source code. Also,
570         the listener creation won't fail just because it happens for an element in a frameless
571         document.
572         Thus, moving nodes between documents no longer results in having incorrect registered
573         lazy event listeners on them.
574
575         Tests: fast/events/attribute-listener-cloned-from-frameless-doc-context-2.html
576                fast/events/attribute-listener-cloned-from-frameless-doc-context.html
577                fast/events/attribute-listener-cloned-from-frameless-doc.xhtml
578                fast/events/attribute-listener-extracted-from-frameless-doc-context-2.html
579                fast/events/attribute-listener-extracted-from-frameless-doc-context.html
580
581         * bindings/js/JSEventListener.cpp:
582         (WebCore::JSEventListener::JSEventListener): Don't take a reference to JSDOMGlobalObject.
583         (WebCore::JSEventListener::jsFunction): Take ScriptExecutionContext as a parameter for
584         getting to JSDOMGlobalObject. It's not used in base class, but is in JSLazyEventListner.
585         (WebCore::JSEventListener::markJSFunction): Don't mark the global object.
586         (WebCore::JSEventListener::handleEvent): Get global object from ScriptExecutionContext.
587         (WebCore::JSEventListener::reportError): Ditto.
588
589         * bindings/js/JSEventListener.h: (WebCore::JSEventListener::create): Don't keep a reference
590         to JSDOMGlobalObject.
591
592         * bindings/js/JSLazyEventListener.cpp: (WebCore::JSLazyEventListener::parseCode): Listener
593         creation was split between this function and ScriptEventListener; moved it here, as JS
594         global object can be different now.
595
596         * bindings/js/JSLazyEventListener.h: (WebCore::JSLazyEventListener::create): Keep source URL,
597         which can not be determined at parsing time.
598
599         * bindings/js/ScriptEventListener.cpp: (WebCore::createAttributeEventListener): Moved code
600         for listener creation to JSLazyEventListener. XSSAuditor code remains here, because tests
601         expect that errors are logged at document parsing time, and because I don't know what other
602         side effects moving it vould have.
603
604         * dom/EventListener.h: handleEvent() and reportError() now take ScriptExecutionContext,
605         because JSC needs a global context here.
606
607         * bindings/js/JSAbstractWorkerCustom.cpp:
608         (WebCore::JSAbstractWorker::addEventListener):
609         (WebCore::JSAbstractWorker::removeEventListener):
610         * bindings/js/JSDOMApplicationCacheCustom.cpp:
611         (WebCore::JSDOMApplicationCache::addEventListener):
612         (WebCore::JSDOMApplicationCache::removeEventListener):
613         * bindings/js/JSDOMGlobalObject.cpp:
614         (WebCore::JSDOMGlobalObject::createJSAttributeEventListener):
615         * bindings/js/JSDOMWindowCustom.cpp:
616         (WebCore::JSDOMWindow::addEventListener):
617         (WebCore::JSDOMWindow::removeEventListener):
618         * bindings/js/JSEventSourceCustom.cpp:
619         (WebCore::JSEventSource::addEventListener):
620         (WebCore::JSEventSource::removeEventListener):
621         * bindings/js/JSMessagePortCustom.cpp:
622         (WebCore::JSMessagePort::addEventListener):
623         (WebCore::JSMessagePort::removeEventListener):
624         * bindings/js/JSNodeCustom.cpp:
625         (WebCore::JSNode::addEventListener):
626         (WebCore::JSNode::removeEventListener):
627         * bindings/js/JSSVGElementInstanceCustom.cpp:
628         (WebCore::JSSVGElementInstance::addEventListener):
629         (WebCore::JSSVGElementInstance::removeEventListener):
630         * bindings/js/JSWorkerContextCustom.cpp:
631         (WebCore::JSWorkerContext::addEventListener):
632         (WebCore::JSWorkerContext::removeEventListener):
633         * bindings/js/JSXMLHttpRequestCustom.cpp:
634         (WebCore::JSXMLHttpRequest::addEventListener):
635         (WebCore::JSXMLHttpRequest::removeEventListener):
636         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
637         (WebCore::JSXMLHttpRequestUpload::addEventListener):
638         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
639         * bindings/objc/ObjCEventListener.h:
640         * bindings/objc/ObjCEventListener.mm:
641         (WebCore::ObjCEventListener::handleEvent):
642         * bindings/scripts/CodeGeneratorJS.pm:
643         * dom/EventTarget.cpp:
644         (WebCore::EventTarget::fireEventListeners):
645         * inspector/InspectorDOMAgent.cpp:
646         (WebCore::InspectorDOMAgent::handleEvent):
647         * inspector/InspectorDOMAgent.h:
648         * inspector/InspectorDOMStorageResource.cpp:
649         (WebCore::InspectorDOMStorageResource::handleEvent):
650         * inspector/InspectorDOMStorageResource.h:
651         * loader/ImageDocument.cpp:
652         (WebCore::ImageEventListener::handleEvent):
653         * svg/animation/SVGSMILElement.cpp:
654         (WebCore::ConditionEventListener::handleEvent):
655         * workers/WorkerContext.cpp:
656         (WebCore::WorkerContext::reportException):
657         Don't pass global object to JSEventListener::create(), which no longer needs it.
658         Note that some of these functions still have an early return for null global object, which
659         can probably be removed in a later patch.
660         Pass ScriptExecutionContext to EventListener methods that now need it.
661
662         * bindings/scripts/CodeGeneratorCOM.pm: Don't force EventTarget implementation on Node -
663         it doesn't work yet (it didn't quite work before this patch, too, because it assumed that
664         any object implementing EventTarget COM interface originated from WebCore).
665
666         * dom/EventListener.idl: Just like in ObjC, EventListener should be a pure interface in
667         COM bindings.
668
669 2009-09-28  Geoffrey Garen  <ggaren@apple.com>
670
671         Reviewed by Sam Weinig.
672
673         Removed virtual destructor from JSGlobalObjectData to eliminate pointer
674         fix-ups when accessing JSGlobalObject::d.
675         
676         Replaced with an explicit destructor function pointer.
677
678         * bindings/js/JSDOMGlobalObject.cpp:
679         (WebCore::JSDOMGlobalObject::destroyJSDOMGlobalObjectData):
680         * bindings/js/JSDOMGlobalObject.h:
681         (WebCore::JSDOMGlobalObject::JSDOMGlobalObjectData::JSDOMGlobalObjectData):
682
683 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
684
685         Reviewed by Simon Hausmann.
686
687         Don't rely on QNetworkReply::NetworkError codes, but
688         on HTTP error codes instead.
689
690         * platform/network/qt/QNetworkReplyHandler.cpp:
691         (WebCore::ignoreHttpError):
692         (WebCore::QNetworkReplyHandler::finish):
693
694 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
695
696         Reviewed by Simon Hausmann.
697
698         Use const references when using Qt's foreach.
699
700         * platform/network/qt/QNetworkReplyHandler.cpp:
701         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
702
703 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
704
705         Reviewed by Simon Hausmann.
706
707         Fix handling of QNetworkReply errors.
708
709         In the QNetworkReplyHandler::finish() a response was sent even when
710         the reply contained an error. This resulted in a sendResponseIfNeeded()
711         calling didReceiveResponse on the client, leading to the destruction
712         of the m_resourceHandle, discontinuing further processing in finish(),
713         and thus not calling didFail on the client.
714
715         Instead it continued as everything went fine, and
716         FrameLoaderClientQt::dispatchDecidePolicyForMIMEType() changed the
717         policy to PolicyDownload due to not being able to show the non existing
718         MIMEType. As the download also obviously fails, it ended up with a
719         policy change error.
720
721         * platform/network/qt/QNetworkReplyHandler.cpp:
722         (WebCore::QNetworkReplyHandler::finish):
723
724 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
725
726         Reviewed by Simon Hausmann.
727
728         The code for showing error pages when the response was
729         a 401/403/404, was not actually doing so. This patch
730         fixes that.
731
732         * platform/network/qt/QNetworkReplyHandler.cpp:
733         (WebCore::QNetworkReplyHandler::finish):
734
735 2009-09-28  Alexey Proskuryakov  <ap@apple.com>
736
737         Reviewed by Brady Eidson.
738
739         <rdar://problem/7259965> REGRESSION: http/tests/xmlhttprequest/cross-origin-authorization.html
740         is failing/crashing intermittently
741         https://bugs.webkit.org/show_bug.cgi?id=29322
742
743         This was caused by CStringBuffer::encodeBase64() returning a buffer that wasn't zero terminated.
744         The code had other issues as well, so I removed it altogether:
745         - it claimed to avoid some buffer copies, but it didn't;
746         - and I don't think that base64 encoding should be part of CString interface.
747
748         * platform/network/mac/ResourceHandleMac.mm:
749         (WebCore::encodeBasicAuthorization): Encode username and password using Base64.h directly.
750         (WebCore::ResourceHandle::start): Use encodeBasicAuthorization().
751         (+[WebCoreSynchronousLoader loadRequest:allowStoredCredentials:returningResponse:error:]): Ditto.
752         (-[WebCoreSynchronousLoader connection:willSendRequest:redirectResponse:]): Extended logging
753         to synchronous case.
754         (-[WebCoreSynchronousLoader connectionShouldUseCredentialStorage:]): Ditto.
755         (-[WebCoreSynchronousLoader connection:didReceiveAuthenticationChallenge:]): Ditto.
756         (-[WebCoreSynchronousLoader connection:didReceiveResponse:]): Ditto.
757         (-[WebCoreSynchronousLoader connection:didReceiveData:]): Ditto.
758         (-[WebCoreSynchronousLoader connectionDidFinishLoading:]): Ditto.
759         (-[WebCoreSynchronousLoader connection:didFailWithError:]): Ditto.
760
761         * platform/network/cf/ResourceHandleCFNet.cpp: Matched Mac changes.
762
763         * platform/text/CString.cpp:
764         * platform/text/CString.h:
765         (WebCore::CStringBuffer::create):
766         (WebCore::CStringBuffer::CStringBuffer):
767         Removed code that was added for Base64 in r48363.
768
769 2009-09-29  Jedrzej Nowacki  <jedrzej.nowacki@nokia.com>
770
771         Reviewed by Simon Hausmann.
772
773         Fix typo in Localizations.cpp
774
775         https://bugs.webkit.org/show_bug.cgi?id=29872
776
777         * platform/qt/Localizations.cpp:
778         (WebCore::localizedMediaControlElementHelpText):
779
780 2009-09-29  Simon Hausmann  <simon.hausmann@nokia.com>
781
782         Reviewed by Tor Arne Vestbø.
783
784         Make the XSLT conditional in DOMWindow.idl's xsltProcessor
785         attribute conditional in the generated files, similar to
786         r44116.
787
788         * page/DOMWindow.idl:
789
790 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
791
792         Reviewed by Simon Hausmann and Tor Arne Vestbø.
793
794         Use the ResourceError as it is supposed to and handle
795         not HTTP errors from QNetworkReply.
796
797         Thanks to Adam Roben for his input.
798
799         * platform/network/qt/QNetworkReplyHandler.cpp:
800         (WebCore::QNetworkReplyHandler::finish):
801
802 009-09-29  Pavel Feldman  <pfeldman@chromium.org>
803
804         Reviewed by Timothy Hatcher.
805
806         Web Inspector: Encapsulate JS listeners specifics into ScriptEventListener.
807
808         https://bugs.webkit.org/show_bug.cgi?id=29816
809
810         * bindings/js/ScriptEventListener.cpp:
811         (WebCore::getEventListenerHandlerBody):
812         * bindings/js/ScriptEventListener.h:
813         * bindings/v8/ScriptEventListener.cpp:
814         (WebCore::getEventListenerHandlerBody):
815         * bindings/v8/ScriptEventListener.h:
816         * inspector/InspectorDOMAgent.cpp:
817         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
818
819 2009-09-29  Xan Lopez  <xlopez@igalia.com>
820
821         Unreviewed attempt to fix the build.
822
823         * page/Settings.cpp:
824         (WebCore::Settings::Settings):
825
826 2009-09-28  Fumitoshi Ukai  <ukai@chromium.org>
827
828         Reviewed by Eric Seidel.
829
830         Add experimentalWebSocketsEnabled in Settings.
831         https://bugs.webkit.org/show_bug.cgi?id=28941
832
833         * WebCore.base.exp:
834         * bindings/js/JSDOMWindowCustom.cpp:
835         (WebCore::JSDOMWindow::webSocket):
836         * bindings/v8/V8DOMWrapper.cpp:
837         (WebCore::V8DOMWrapper::getConstructor):
838         * bindings/v8/custom/V8WebSocketCustom.cpp:
839         * page/Settings.cpp:
840         (WebCore::Settings::Settings):
841         (WebCore::Settings::setExperimentalWebSocketsEnabled):
842         * page/Settings.h:
843         (WebCore::Settings::experimentalWebSocketsEnabled):
844         
845 2009-09-11  Fumitoshi Ukai  <ukai@chromium.org>
846
847         Reviewed by Adam Barth.
848
849         Add platform code to support WebSocket for chromium.
850         https://bugs.webkit.org/show_bug.cgi?id=29171
851
852         To build within chromium tree, it requires a patch in bug 29174.
853         Real implementation will be landed in chromium tree.
854
855         * WebCore.gypi:
856         * platform/network/chromium/SocketStreamError.h: Added.
857         (WebCore::SocketStreamError::SocketStreamError):
858         * platform/network/chromium/SocketStreamHandle.h: Added.
859         (WebCore::SocketStreamHandle::create):
860
861 2009-09-28  Dan Bernstein  <mitz@apple.com>
862
863         Reviewed by Sam Weinig.
864
865         <rdar://problem/7157288> Crash in RenderStyle::computedLineHeight()
866         when Times New Roman is not installed
867
868         * platform/graphics/win/FontCacheWin.cpp:
869         (WebCore::FontCache::getLastResortFallbackFont): If Times New Roman is
870         not available, use the Windows default GUI font.
871
872 2009-09-28  Jian Li  <jianli@chromium.org>
873
874         Reviewed by David Levin.
875
876         Do not add platform-specific methods to cross-platform header
877         FileSystem.h per Darin's feedback for 29109.
878         https://bugs.webkit.org/show_bug.cgi?id=29830
879
880         * platform/FileSystem.h:
881         * platform/chromium/DragDataChromium.cpp:
882         (WebCore::DragData::asURL):
883         * platform/chromium/FileSystemChromium.cpp:
884
885 2009-09-28  Dumitru Daniliuc  <dumi@chromium.org>
886
887         Reviewed by Dimitri Glazkov.
888
889         Register Chromium's VFSs with a proper sqlite3_io_methods
890         finder. This should only affect the POSIX implementation. The
891         Windows change is included for consistency and in case sqlite
892         starts using something similar in its Windows VFS in the future.
893
894         https://bugs.webkit.org/show_bug.cgi?id=29743
895
896         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
897         (WebCore::SQLiteFileSystem::registerSQLiteVFS):
898         * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
899         (WebCore::SQLiteFileSystem::registerSQLiteVFS):
900
901 2009-09-28  Nate Chapin  <japhet@chromium.org>
902
903         Reviewed by Adam Barth.
904
905         Change the V8 bindings' handling of window.toString(),
906         so we return [object DOMWindow] (like JSC), not [object global].
907
908         https://bugs.webkit.org/show_bug.cgi?id=29742
909
910         This will fix a couple of Chromium port test failures and enable us to
911         use the default expectations for a bunch more.
912
913         * bindings/v8/custom/V8DOMWindowCustom.cpp: Use the DOMWindow wrapper instead
914         of the global object wrapper when it's available in the DOMWindow toString callback.
915
916 2009-09-28  Nate Chapin  <japhet@chromium.org>
917
918         Rubber stamped by David Levin.
919
920         Chromium build fix, add back in #include of V8Proxy.h in V8WebKitPointConstructor.cpp.
921
922         * bindings/v8/custom/V8WebKitPointConstructor.cpp: Re-include V8Proxy.h.
923
924 2009-09-28  Geoffrey Garen  <ggaren@apple.com>
925
926         Reviewed by Darin Adler.
927
928         NotNullPassRefPtr: smart pointer optimized for passing references that are not null
929         https://bugs.webkit.org/show_bug.cgi?id=29822
930         
931         Added NotNullPassRefPtr, and deployed it in all places that initialize
932         JavaScript objects.
933
934         * bindings/js/DOMObjectWithSVGContext.h:
935         (WebCore::DOMObjectWithSVGContext::DOMObjectWithSVGContext):
936         * bindings/js/JSDOMBinding.cpp:
937         (WebCore::cacheDOMStructure):
938         * bindings/js/JSDOMBinding.h:
939         (WebCore::DOMObject::DOMObject):
940         (WebCore::DOMObjectWithGlobalPointer::DOMObjectWithGlobalPointer):
941         (WebCore::DOMConstructorObject::DOMConstructorObject):
942         (WebCore::DOMConstructorWithDocument::DOMConstructorWithDocument):
943         * bindings/js/JSDOMGlobalObject.cpp:
944         (WebCore::JSDOMGlobalObject::JSDOMGlobalObject):
945         * bindings/js/JSDOMGlobalObject.h:
946         * bindings/js/JSDOMWindowBase.cpp:
947         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
948         * bindings/js/JSDOMWindowBase.h:
949         * bindings/js/JSHTMLAllCollection.h:
950         (WebCore::JSHTMLAllCollection::JSHTMLAllCollection):
951         * bindings/js/JSInspectedObjectWrapper.cpp:
952         (WebCore::JSInspectedObjectWrapper::JSInspectedObjectWrapper):
953         * bindings/js/JSInspectedObjectWrapper.h:
954         * bindings/js/JSInspectorCallbackWrapper.cpp:
955         (WebCore::JSInspectorCallbackWrapper::JSInspectorCallbackWrapper):
956         * bindings/js/JSInspectorCallbackWrapper.h:
957         * bindings/js/JSQuarantinedObjectWrapper.cpp:
958         (WebCore::JSQuarantinedObjectWrapper::JSQuarantinedObjectWrapper):
959         * bindings/js/JSQuarantinedObjectWrapper.h:
960         * bindings/js/JSWorkerContextBase.cpp:
961         (WebCore::JSWorkerContextBase::JSWorkerContextBase):
962         * bindings/js/JSWorkerContextBase.h:
963         * bindings/scripts/CodeGeneratorJS.pm:
964         * bridge/runtime_object.cpp:
965         (JSC::RuntimeObjectImp::RuntimeObjectImp):
966         * bridge/runtime_object.h:
967
968 2009-09-28  Nate Chapin  <japhet@chromium.org>
969
970         Reviewed by Dimitri Glazkov.
971
972         Allow V8 to handle x/y parameters in a WebKitPoint constructor.
973         https://bugs.webkit.org/show_bug.cgi?id=29823
974
975         Fixes V8's handling of LayoutTests/fast/dom/Window/webkitConvertPoint.html
976
977         * bindings/v8/custom/V8WebKitPointConstructor.cpp: Allow for x/y parameters in constructor.
978
979 2009-09-28  Mark Rowe  <mrowe@apple.com>
980
981         Fix the build by doing something approximating reasonableness in the Xcode project.
982
983         * WebCore.xcodeproj/project.pbxproj:
984
985 2009-09-28  Simon Hausmann  <hausmann@webkit.org>
986
987         Prospective Tiger build fix.
988
989         * WebCore.xcodeproj/project.pbxproj: Try to use unique IDs for the new files.
990
991 2009-09-28  Pavel Feldman  <pfeldman@chromium.org>
992
993         Reviewed by Timothy Hatcher.
994
995         Web Inspector: Add explicit frontend event for commit load.
996
997         https://bugs.webkit.org/show_bug.cgi?id=29814
998
999         * inspector/InspectorController.cpp:
1000         (WebCore::InspectorController::didCommitLoad):
1001         * inspector/InspectorFrontend.cpp:
1002         (WebCore::InspectorFrontend::didCommitLoad):
1003         * inspector/InspectorFrontend.h:
1004         * inspector/front-end/DOMAgent.js:
1005         (WebInspector.DOMAgent.prototype._setDocument):
1006         * inspector/front-end/inspector.js:
1007         (WebInspector.addResource):
1008         (WebInspector.didCommitLoad):
1009
1010 2009-09-28  Yaar Schnitman  <yaar@chromium.org>
1011
1012         Reviewed by Dimitri Glazkov.
1013
1014         Chromium port - recognize we are being built independently
1015         of chromium and look for dependencies under webkit/chromium rather
1016         than chromium/src.
1017
1018         https://bugs.webkit.org/show_bug.cgi?id=29722
1019
1020         * WebCore.gyp/WebCore.gyp: See above. Also removed a few files from
1021           the sources list, since they are not supposed to be built here.
1022
1023 2009-09-28  Jakub Wieczorek  <faw217@gmail.com>
1024
1025         Reviewed by Simon Hausmann.
1026
1027         [Qt] Implement XSLT support with QtXmlPatterns.
1028         https://bugs.webkit.org/show_bug.cgi?id=28303
1029
1030         * GNUmakefile.am:
1031         * WebCore.gypi:
1032         * WebCore.pro:
1033         * WebCore.vcproj/WebCore.vcproj:
1034         * WebCoreSources.bkl:
1035         * dom/Document.cpp:
1036         (WebCore::Document::Document):
1037         (WebCore::Document::~Document):
1038         (WebCore::Document::setTransformSource):
1039         * dom/Document.h:
1040         (WebCore::Document::transformSource):
1041         * dom/TransformSource.h: Added.
1042         (WebCore::TransformSource::platformSource):
1043         * dom/TransformSourceLibxslt.cpp: Added.
1044         (WebCore::TransformSource::TransformSource): Wraps a libxml2 document.
1045         (WebCore::TransformSource::~TransformSource):
1046         * dom/TransformSourceQt.cpp: Added.
1047         (WebCore::TransformSource::TransformSource): Wraps a plain string.
1048         (WebCore::TransformSource::~TransformSource):
1049         * dom/XMLTokenizerLibxml2.cpp:
1050         (WebCore::XMLTokenizer::doEnd):
1051         * dom/XMLTokenizerQt.cpp:
1052         (WebCore::XMLTokenizer::doEnd):
1053         (WebCore::XMLTokenizer::parseProcessingInstruction):
1054         * xml/XSLStyleSheet.h:
1055         (WebCore::XSLStyleSheet::sheetString):
1056         * xml/XSLStyleSheetLibxslt.cpp:
1057         (WebCore::XSLStyleSheet::document):
1058         * xml/XSLStyleSheetQt.cpp: Added.
1059         * xml/XSLTProcessor.h:
1060         * xml/XSLTProcessorLibxslt.cpp:
1061         (WebCore::xmlDocPtrFromNode):
1062         * xml/XSLTProcessorQt.cpp: Added.
1063         (WebCore::XSLTMessageHandler::XSLTMessageHandler): A subclass of QAbstractMessageHandler.
1064         (WebCore::XSLTMessageHandler::handleMessage): Forwards all processor messages to the Console.
1065         (WebCore::XSLTProcessor::transformToString): Uses QXmlQuery.
1066
1067 2009-09-28  Andrew Scherkus  <scherkus@chromium.org>
1068
1069         Reviewed by Eric Carlson.
1070
1071         Delegate implementation of rendererIsNeeded() for media control elements to RenderTheme.
1072
1073         https://bugs.webkit.org/show_bug.cgi?id=28689
1074
1075         Covered by LayoutTests/media/video-no-audio.html
1076
1077         * rendering/MediaControlElements.cpp: Removed subclass implementations of rendererIsNeeded().
1078         (WebCore::MediaControlElement::rendererIsNeeded): Include calling shouldRenderMediaControlPart().
1079         (WebCore::MediaControlInputElement::rendererIsNeeded): Include calling shouldRenderMediaControlPart().
1080         * rendering/MediaControlElements.h:
1081         * rendering/RenderTheme.cpp:
1082         (WebCore::RenderTheme::shouldRenderMediaControlPart): New method.  Contains logic moved from subclass implementations of rendererIsNeeded().
1083         * rendering/RenderTheme.h:
1084         * rendering/RenderThemeChromiumSkia.cpp:
1085         (WebCore::RenderThemeChromiumSkia::shouldRenderMediaControlPart): Override to always render mute button.
1086         * rendering/RenderThemeChromiumSkia.h:
1087
1088 2009-09-28  Jian Li  <jianli@chromium.org>
1089
1090         Reviewed by David Levin.
1091
1092         [chromium] DragData::asURL should return file URL.
1093         https://bugs.webkit.org/show_bug.cgi?id=29109
1094
1095         Tested by LayoutTests/fast/events/drag-to-navigate.html.
1096
1097         * platform/FileSystem.h:
1098         * platform/chromium/ChromiumBridge.h:
1099         * platform/chromium/DragDataChromium.cpp:
1100         (WebCore::DragData::asURL):
1101         * platform/chromium/FileSystemChromium.cpp:
1102         (WebCore::getAbsolutePath):
1103         (WebCore::isDirectory):
1104         (WebCore::filePathToURL):
1105
1106 2009-09-28  Dimitri Glazkov  <dglazkov@chromium.org>
1107
1108         Reviewed by David Levin.
1109
1110         [V8] Add a special case to handle index arguments, because we need to be
1111         able to see if they're < 0.
1112         https://bugs.webkit.org/show_bug.cgi?id=29810
1113
1114         Test: LayoutTests/dom/html/level1/core/hc_characterdataindexsizeerrdeletedatacountnegative.html
1115
1116         * bindings/scripts/CodeGeneratorV8.pm: Added special case (matching CodeGeneratorJS.pm)
1117           for index arguments.
1118
1119 2009-09-28  Dan Bernstein  <mitz@apple.com>
1120
1121         Reviewed by Darin Adler.
1122
1123         Extend the MediaWiki/KHTMLFixes.css workaround to cover older MediaWiki versions
1124         https://bugs.webkit.org/show_bug.cgi?id=29792
1125
1126         * html/HTMLLinkElement.cpp:
1127         (WebCore::HTMLLinkElement::setCSSStyleSheet): If site specific hacks are
1128         enabled, check if the linked style sheet is one of two versions of the
1129         MediaWiki KHTMLFixes.css. If so, remove the offending rule.
1130
1131 2009-09-28  Dimitri Glazkov  <dglazkov@chromium.org>
1132
1133         Reviewed by Adam Barth.
1134
1135         [V8] Fix an error in type logic in CodeGeneratorV8.pm, where
1136         unsigned ints are accidentally used as signed.
1137         https://bugs.webkit.org/show_bug.cgi?id=29810
1138
1139         Test: LayoutTests/fast/forms/textarea-maxlength.html
1140
1141         * bindings/scripts/CodeGeneratorV8.pm: Made sure "unsigned long" in IDL is
1142           properly generates on "unsigned" return value.
1143
1144 2009-09-28  Jakub Wieczorek  <faw217@gmail.com>
1145
1146         Reviewed by Simon Hausmann.
1147
1148         Rename XSLStyleSheet.cpp to XSLStyleSheetLibxslt.cpp.
1149         https://bugs.webkit.org/show_bug.cgi?id=28303
1150
1151         In preparation for adding XSLT support with QtXmlPatterns to the Qt
1152         port, rename XSLStyleSheet.cpp to XSLStyleSheetLibxslt.cpp as we will
1153         have our own implementation which most likely will not share any code
1154         with the current one.
1155
1156         Additionally, fix some coding style issues.
1157
1158         * GNUmakefile.am:
1159         * WebCore.gypi:
1160         * WebCore.vcproj/WebCore.vcproj:
1161         * WebCore.xcodeproj/project.pbxproj:
1162         * WebCoreSources.bkl:
1163         * xml/XSLStyleSheet.cpp: Renamed to XSLStyleSheetLibxslt.cpp.
1164         * xml/XSLStyleSheetLibxslt.cpp: Added.
1165
1166 2009-09-28  Simon Hausmann  <simon.hausmann@nokia.com>
1167
1168         Prospective build fix for r48812.
1169
1170         Forgot to remove the inline reset() implementation when reverting the indentation
1171         changes in the file.
1172
1173         * xml/XSLTProcessor.h:
1174
1175 2009-09-28  Pavel Feldman  <pfeldman@chromium.org>
1176
1177         Reviewed by nobody (trivial follow up fix), Joseph Pecoraro LGTM-ed.
1178
1179         Web Inspector: Follow up to r48809.
1180         InspectorController.wrapObject should only be called on the inspectable page side.
1181
1182         https://bugs.webkit.org/show_bug.cgi?id=17429
1183
1184         * inspector/front-end/EventListenersSidebarPane.js:
1185         (WebInspector.EventListenersSidebarPane.prototype.update.callback):
1186         (WebInspector.EventListenersSidebarPane.prototype.update):
1187         (WebInspector.EventListenersSection):
1188         (WebInspector.EventListenersSection.prototype.update):
1189         (WebInspector.EventListenerBar):
1190         (WebInspector.EventListenerBar.prototype.update):
1191
1192 2009-09-28  Jakub Wieczorek  <faw217@gmail.com>
1193
1194         Reviewed by Simon Hausmann.
1195
1196         Move the libxslt specific part of XSLTProcessor to a separate file.
1197         https://bugs.webkit.org/show_bug.cgi?id=28303
1198
1199         In preparation for adding XSLT support with QtXmlPatterns to the Qt
1200         port, move the libxslt part of the XSLTProcessor implementation into
1201         another file and leave the part that can be reused and shared.
1202
1203         Additionally, fix some coding style issues.
1204
1205         * GNUmakefile.am:
1206         * WebCore.gypi:
1207         * WebCore.vcproj/WebCore.vcproj:
1208         * WebCore.xcodeproj/project.pbxproj:
1209         * WebCoreSources.bkl:
1210         * xml/XSLTProcessor.cpp:
1211         (WebCore::XSLTProcessor::createDocumentFromSource): Remove trailing whitespaces.
1212         (WebCore::createFragmentFromSource): Remove trailing whitespaces.
1213         (WebCore::XSLTProcessor::transformToFragment): Remove trailing whitespaces.
1214         (WebCore::XSLTProcessor::reset): Moved out of the class definition.
1215         * xml/XSLTProcessorLibxslt.cpp: Added.
1216         (WebCore::XSLTProcessor::genericErrorFunc): Moved.
1217         (WebCore::XSLTProcessor::parseErrorFunc): Moved.
1218         (WebCore::docLoaderFunc): Moved.
1219         (WebCore::setXSLTLoadCallBack): Moved.
1220         (WebCore::writeToVector): Moved.
1221         (WebCore::saveResultToString): Moved.
1222         (WebCore::xsltParamArrayFromParameterMap): Moved.
1223         (WebCore::freeXsltParamArray): Moved.
1224         (WebCore::xsltStylesheetPointer): Moved.
1225         (WebCore::xmlDocPtrFromNode): Moved.
1226         (WebCore::resultMIMEType): Moved.
1227         (WebCore::XSLTProcessor::transformToString): Moved.
1228
1229 2009-09-28  Charles Wei  <charles.wei@torchmobile.com.cn>
1230
1231         Reviewed by Nikolas Zimmermann.
1232
1233         Fix the crash of SVG that crashes when use a non-exist symbol
1234         https://bugs.webkit.org/show_bug.cgi?id=27693
1235
1236         Test: svg/custom/use-non-existing-symbol-crash.svg
1237
1238         * svg/SVGUseElement.cpp:
1239         (WebCore::shadowTreeContainsChangedNodes):
1240
1241 2009-09-28  Joseph Pecoraro  <joepeck@webkit.org>
1242
1243         Reviewed by Timothy Hatcher.
1244
1245         Inspector Should Show Event Listeners/Handlers Registered on each Node
1246         https://bugs.webkit.org/show_bug.cgi?id=17429
1247         
1248           Extracted a method from dispatchEvent to get the event ancestor chain
1249         
1250         * dom/Node.cpp:
1251         (WebCore::Node::eventAncestors): the extracted method
1252         (WebCore::Node::dispatchGenericEvent): use eventAncestors
1253         * dom/Node.h:
1254
1255           Asynchronous Flow For the Inspector, Backend -> DOM Agent -> Frontend
1256           The DOMAgent's getEventListenersForNode handles the logic of finding
1257           all the relevant listeners in the event flow.
1258
1259         * inspector/InspectorBackend.cpp:
1260         (WebCore::InspectorBackend::getEventListenersForNode):
1261         * inspector/InspectorBackend.h:
1262         * inspector/InspectorBackend.idl:
1263         * inspector/InspectorDOMAgent.cpp:
1264         (WebCore::InspectorDOMAgent::getEventListenersForNode):
1265         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
1266         (WebCore::InspectorDOMAgent::buildObjectForNode): added localName
1267         * inspector/InspectorDOMAgent.h:
1268         (WebCore::EventListenerInfo::EventListenerInfo):
1269         * inspector/InspectorFrontend.cpp:
1270         (WebCore::InspectorFrontend::didGetEventListenersForNode):
1271         * inspector/InspectorFrontend.h:
1272         (WebCore::InspectorFrontend::scriptState):
1273         * inspector/front-end/DOMAgent.js: added localName to WebInspector.DOMNode from payload
1274         (WebInspector.EventListeners.getEventListenersForNodeAsync.mycallback):
1275         (WebInspector.EventListeners.getEventListenersForNodeAsync):
1276
1277           New Sidebar Pane in the Element's Panel
1278           Includes Gear Menu for filtering the Event Listeners on the
1279           "Selected Node Only" or "All Nodes"
1280
1281         * inspector/front-end/ElementsPanel.js: Handles refreshing the Pane when necessary
1282         (WebInspector.ElementsPanel.this.treeOutline.focusedNodeChanged):
1283         (WebInspector.ElementsPanel):
1284         (WebInspector.ElementsPanel.prototype.updateEventListeners):
1285         * inspector/front-end/EventListenersSidebarPane.js: Added. 
1286         (WebInspector.EventListenersSidebarPane): The 1st level in the Pane
1287         (WebInspector.EventListenersSidebarPane.prototype.update.callback):
1288         (WebInspector.EventListenersSidebarPane.prototype.update):
1289         (WebInspector.EventListenersSection): The 2nd level in the Pane
1290         (WebInspector.EventListenersSection.prototype.update): filters on Preference
1291         (WebInspector.EventListenersSection.prototype.addListener):
1292         (WebInspector.EventListenerBar): The 3rd level in the Pane
1293         (WebInspector.EventListenerBar.prototype._getNodeDisplayName):
1294         (WebInspector.EventListenerBar.prototype._getFunctionDisplayName):
1295         (WebInspector.EventListenersSidebarPane.prototype._changeSetting): For the Gear Menu
1296         
1297           Consolidated "appropriateSelectorForNode"
1298
1299         * inspector/front-end/StylesSidebarPane.js:
1300         * inspector/front-end/utilities.js:
1301
1302           Miscellaneous Updates
1303
1304         * English.lproj/localizedStrings.js: "Event Listeners", "No Event Listeners", "Selected Node Only", "All Nodes"
1305         * WebCore.gypi: included the new inspector files
1306         * WebCore.vcproj/WebCore.vcproj: included source files that were missing
1307         * inspector/front-end/Images/grayConnectorPoint.png: Added. Thanks to Timothy Hatcher.
1308         * inspector/front-end/Images/whiteConnectorPoint.png: Added. Thanks to Timothy Hatcher.
1309         * inspector/front-end/inspector.js: Preferences for the Gear Menu Event Listeners filter
1310         * inspector/front-end/inspector.css: reused as much as possible
1311         * inspector/front-end/inspector.html: include the new script
1312         * inspector/front-end/WebKit.qrc: included the new inspector files
1313
1314 2009-09-27  Sam Weinig  <sam@webkit.org>
1315
1316         Reviewed by Dan Bernstein.
1317
1318         Fix for https://bugs.webkit.org/show_bug.cgi?id=29760
1319         Implement CSSOM Range.getClientRects/getBoundingClientRect 
1320
1321         Tests: fast/dom/Range/getBoundingClientRect-getClientRects-relative-to-viewport.html
1322                fast/dom/Range/getBoundingClientRect.html
1323                fast/dom/Range/getClientRects.html
1324
1325         * dom/Range.cpp:
1326         (WebCore::Range::getClientRects):
1327         (WebCore::Range::getBoundingClientRect):
1328         (WebCore::adjustFloatQuadsForScrollAndAbsoluteZoom):
1329         (WebCore::Range::getBorderAndTextQuads):
1330         * dom/Range.h:
1331         * dom/Range.idl:
1332         Implement Range.getClientRects/getBoundingClientRect.
1333
1334         * dom/Element.cpp:
1335         * rendering/RenderObject.h: 
1336         (WebCore::adjustForAbsoluteZoom):
1337         (WebCore::adjustIntRectForAbsoluteZoom):
1338         (WebCore::adjustFloatPointForAbsoluteZoom):
1339         (WebCore::adjustFloatQuadForAbsoluteZoom):
1340         Move point/quad adjustment methods from Element.cpp to RenderObject.h
1341         so that Range.cpp can use them as well.
1342
1343 2009-09-27  Simon Hausmann  <hausmann@webkit.org>
1344
1345         Unreviewed fix for WebInspector with Qt build.
1346
1347         Simply re-generate the Qt resource file by running
1348         WebKitTools/Scripts/generate-qt-inspector-resource
1349
1350         * inspector/front-end/WebKit.qrc:
1351
1352 2009-09-27  Pavel Feldman  <pfeldman@chromium.org>
1353
1354         Reviewed by nobody (trivial ChangeLog fix).
1355
1356         Restore WebCore/ChangeLog truncated in r48778.
1357
1358 2009-09-27  Pavel Feldman  <pfeldman@chromium.org>
1359
1360         Reviewed by Timothy Hatcher.
1361
1362         Web Inspector: DOM store is being unbound twice, leading to assertion failure.
1363
1364         https://bugs.webkit.org/show_bug.cgi?id=29770
1365
1366         * inspector/InspectorController.cpp:
1367         (WebCore::InspectorController::didOpenDatabase):
1368         (WebCore::InspectorController::didUseDOMStorage):
1369         * inspector/InspectorDOMStorageResource.cpp:
1370         (WebCore::InspectorDOMStorageResource::unbind):
1371
1372 2009-09-26  Pavel Feldman  <pfeldman@chromium.org>
1373
1374         Reviewed by Timothy Hatcher.
1375
1376         Web Inspector: Do not track DOM changes while inspector window is closed.
1377
1378         https://bugs.webkit.org/show_bug.cgi?id=29769
1379
1380         * inspector/InspectorController.cpp:
1381         (WebCore::InspectorController::inspectedWindowScriptObjectCleared):
1382         (WebCore::InspectorController::populateScriptObjects):
1383         (WebCore::InspectorController::resetScriptObjects):
1384         (WebCore::InspectorController::didCommitLoad):
1385         * inspector/InspectorController.h:
1386         * inspector/InspectorDOMAgent.cpp:
1387         (WebCore::InspectorDOMAgent::setDocument):
1388         * inspector/InspectorDOMAgent.h:
1389         * loader/FrameLoader.cpp:
1390         (WebCore::FrameLoader::dispatchWindowObjectAvailable):
1391         * page/android/InspectorControllerAndroid.cpp:
1392         (WebCore::InspectorController::inspectedWindowScriptObjectCleared):
1393
1394 2009-09-26  Pavel Feldman  <pfeldman@chromium.org>
1395
1396         Reviewed by Timothy Hatcher.
1397
1398         Web Inspector: [REGRESSION] Double Clicking Resources Fails to Open in New Window
1399
1400         https://bugs.webkit.org/show_bug.cgi?id=29762
1401
1402         * inspector/front-end/InjectedScript.js:
1403         (InjectedScript.setStyleText):
1404         (InjectedScript.openInInspectedWindow):
1405         * inspector/front-end/InjectedScriptAccess.js:
1406         * inspector/front-end/ResourcesPanel.js:
1407         (WebInspector.ResourceSidebarTreeElement.prototype.ondblclick):
1408
1409 2009-09-26  David Kilzer  <ddkilzer@apple.com>
1410
1411         Part 2 of 2: <http://webkit.org/b/29753> DerivedSources.make broken for non-Mac targets
1412
1413         Reviewed by Darin Adler.
1414
1415         Fix ENABLE_ORIENTATION_EVENTS for non-Mac platforms.
1416
1417         * DerivedSources.make: Moved Platform.h check for
1418         ENABLE_ORIENTATION_EVENTS into Mac-only section and added
1419         default of ENABLE_ORIENTATION_EVENTS = 0 to non-Mac section.
1420         Added ifndef test to make it possible to override both
1421         ENABLE_DASHBOARD_SUPPORT and ENABLE_ORIENTATION_EVENTS external
1422         to the makefile.  Moved addition of ENABLE_ORIENTATION_EVENTS to
1423         ADDITIONAL_IDL_DEFINES to common section.
1424         * GNUmakefile.am: Added support for ENABLE_ORIENTATION_EVENTS if
1425         it is ever used.
1426         * WebCore.pro: Ditto.
1427
1428 2009-09-26  Kent Tamura  <tkent@chromium.org>
1429
1430         Reviewed by David Kilzer.
1431
1432         Move placeholder-related code to HTMLTextFormControlElement from
1433         HTMLInputElement, WMLInputElement, InputElement, and
1434         HTMLTextAreaElement.
1435         https://bugs.webkit.org/show_bug.cgi?id=28703
1436
1437         * dom/InputElement.cpp:
1438         (WebCore::InputElement::dispatchFocusEvent):
1439         (WebCore::InputElement::dispatchBlurEvent):
1440         (WebCore::InputElement::setValueFromRenderer):
1441         * dom/InputElement.h:
1442         * html/HTMLFormControlElement.cpp:
1443         (WebCore::HTMLTextFormControlElement::HTMLTextFormControlElement):
1444         (WebCore::HTMLTextFormControlElement::~HTMLTextFormControlElement):
1445         (WebCore::HTMLTextFormControlElement::dispatchFocusEvent):
1446         (WebCore::HTMLTextFormControlElement::dispatchBlurEvent):
1447         (WebCore::HTMLTextFormControlElement::placeholderShouldBeVisible):
1448         (WebCore::HTMLTextFormControlElement::updatePlaceholderVisibility):
1449         * html/HTMLFormControlElement.h:
1450         (WebCore::HTMLTextFormControlElement::handleFocusEvent):
1451         (WebCore::HTMLTextFormControlElement::handleBlurEvent):
1452         * html/HTMLInputElement.cpp:
1453         (WebCore::HTMLInputElement::HTMLInputElement):
1454         (WebCore::HTMLInputElement::handleFocusEvent):
1455         (WebCore::HTMLInputElement::handleBlurEvent):
1456         (WebCore::HTMLInputElement::parseMappedAttribute):
1457         (WebCore::HTMLInputElement::createRenderer):
1458         (WebCore::HTMLInputElement::setValue):
1459         (WebCore::HTMLInputElement::setValueFromRenderer):
1460         * html/HTMLInputElement.h:
1461         (WebCore::HTMLInputElement::supportsPlaceholder):
1462         (WebCore::HTMLInputElement::isEmptyValue):
1463         * html/HTMLIsIndexElement.cpp:
1464         (WebCore::HTMLIsIndexElement::parseMappedAttribute):
1465         * html/HTMLTextAreaElement.cpp:
1466         (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
1467         (WebCore::HTMLTextAreaElement::createRenderer):
1468         * html/HTMLTextAreaElement.h:
1469         (WebCore::HTMLTextAreaElement::supportsPlaceholder):
1470         (WebCore::HTMLTextAreaElement::isEmptyValue):
1471         * rendering/RenderTextControl.cpp:
1472         (WebCore::RenderTextControl::RenderTextControl):
1473         * rendering/RenderTextControl.h:
1474         * rendering/RenderTextControlMultiLine.cpp:
1475         (WebCore::RenderTextControlMultiLine::RenderTextControlMultiLine):
1476         * rendering/RenderTextControlMultiLine.h:
1477         * rendering/RenderTextControlSingleLine.cpp:
1478         (WebCore::RenderTextControlSingleLine::RenderTextControlSingleLine):
1479         (WebCore::RenderTextControlSingleLine::updateFromElement):
1480         * rendering/RenderTextControlSingleLine.h:
1481         * wml/WMLInputElement.cpp:
1482         (WebCore::WMLInputElement::setValue):
1483         (WebCore::WMLInputElement::createRenderer):
1484         * wml/WMLInputElement.h:
1485
1486 2009-09-26  Shu Chang  <Chang.Shu@nokia.com>
1487
1488         Reviewed by Alexey Proskuryakov.
1489
1490         Optimize the code so only the text from start to end is scanned.
1491         https://bugs.webkit.org/show_bug.cgi?id=29092
1492
1493         On a platform with webkit+Qt+Symbian, the parsing time for a 600K text
1494         file improved from 400ms to 40ms (10x faster).
1495
1496         * dom/Text.cpp:
1497         (WebCore::Text::createWithLengthLimit):
1498
1499 2009-09-26  Xiaomei Ji  <xji@chromium.org>
1500
1501         Reviewed by Eric Seidel.
1502
1503         This Patch fixes [chromium] the drop-down is always left-aligned even
1504         for RTL element.
1505         https://bugs.webkit.org/show_bug.cgi?id=29612
1506
1507         For auto-complete, the items in drop-down should be right-aligned if
1508         the directionality of <input> field is RTL.
1509         For <select><option>, the items in drop-down should be right-aligned
1510         if the directionality of <select> is RTL.
1511
1512         No automatic test is possible. Manual tests are added.
1513
1514         * manual-tests/autofill_alignment.html: Added.
1515         * manual-tests/select_alignment.html: Added.
1516         * platform/chromium/PopupMenuChromium.cpp:
1517         (WebCore::PopupListBox::paintRow): Adjust the starting x-axis of text to
1518         be paint if it should be right-aligned.
1519
1520 2009-09-25  Dan Bernstein  <mitz@apple.com>
1521
1522         Reviewed by Sam Weinig.
1523
1524         REGRESSION (r48775) FontList.plist written by TOT WebKit causes Safari 4
1525         to crash on launch
1526         https://bugs.webkit.org/show_bug.cgi?id=29759
1527
1528         * platform/graphics/win/FontDatabase.cpp:
1529         (WebCore::writeFontDatabaseToPlist): Reverted to saving the CG font DB
1530         property list at the root of FontList.plist, but with an additional
1531         key for the last value of the Fonts registry key.
1532         (WebCore::populateFontDatabase): Pass the FontList.plist in its entirety
1533         to populatFontDatabaseFromPlist.
1534
1535 2009-09-25  Kevin Ollivier  <kevino@theolliviers.com>
1536
1537         Build fix. Adding missing header files.
1538
1539         * bindings/js/JSNamedNodeMapCustom.cpp:
1540
1541 2009-09-25  David Kilzer  <ddkilzer@apple.com>
1542
1543         Part 1 of 2: <http://webkit.org/b/29753> DerivedSources.make broken for non-Mac targets
1544
1545         Reviewed by Darin Adler.
1546
1547         * DerivedSources.make: Move tests for ENABLE_CONTEXT_MENUS,
1548         ENABLE_DRAG_SUPPORT and ENABLE_INSPECTOR into Mac-only section.
1549
1550 2009-09-25  Adam Barth  <abarth@webkit.org>
1551
1552         Reviewed by Darin Adler.
1553
1554         Load blocks during unload should not affect targeted loads
1555         https://bugs.webkit.org/show_bug.cgi?id=29747
1556
1557         Move the check of the unload state after checking for targeted links.
1558
1559         Test: fast/loader/unload-hyperlink-targeted.html
1560
1561         * loader/FrameLoader.cpp:
1562         (WebCore::FrameLoader::loadURL):
1563
1564 2009-09-25  Kenneth Russell  <kbr@google.com>
1565
1566         Reviewed by Dimitri Glazkov.
1567
1568         [Chromium] Add initial V8 bindings for WebGL
1569         https://bugs.webkit.org/show_bug.cgi?id=29664
1570
1571         * WebCore.gypi:
1572         * bindings/scripts/CodeGeneratorV8.pm:
1573         * bindings/v8/DOMObjectsInclude.h:
1574         * bindings/v8/DerivedSourcesAllInOne.cpp:
1575         * bindings/v8/V8DOMWrapper.cpp:
1576         (WebCore::V8DOMWrapper::getTemplate):
1577         * bindings/v8/V8Index.cpp:
1578         * bindings/v8/V8Index.h:
1579         * bindings/v8/custom/V8CanvasArrayBufferCustom.cpp: Added.
1580         (WebCore::CALLBACK_FUNC_DECL):
1581         * bindings/v8/custom/V8CanvasArrayCustom.h: Added.
1582         (WebCore::constructCanvasArray):
1583         * bindings/v8/custom/V8CanvasByteArrayCustom.cpp: Added.
1584         (WebCore::CALLBACK_FUNC_DECL):
1585         (WebCore::INDEXED_PROPERTY_GETTER):
1586         (WebCore::INDEXED_PROPERTY_SETTER):
1587         * bindings/v8/custom/V8CanvasFloatArrayCustom.cpp: Added.
1588         (WebCore::CALLBACK_FUNC_DECL):
1589         (WebCore::INDEXED_PROPERTY_GETTER):
1590         (WebCore::INDEXED_PROPERTY_SETTER):
1591         * bindings/v8/custom/V8CanvasIntArrayCustom.cpp: Added.
1592         (WebCore::CALLBACK_FUNC_DECL):
1593         (WebCore::INDEXED_PROPERTY_GETTER):
1594         (WebCore::INDEXED_PROPERTY_SETTER):
1595         * bindings/v8/custom/V8CanvasRenderingContext3DCustom.cpp: Added.
1596         (WebCore::jsArrayToFloatArray):
1597         (WebCore::jsArrayToIntArray):
1598         (WebCore::CALLBACK_FUNC_DECL):
1599         (WebCore::):
1600         (WebCore::vertexAttribAndUniformHelperf):
1601         (WebCore::uniformHelperi):
1602         (WebCore::uniformMatrixHelper):
1603         * bindings/v8/custom/V8CanvasShortArrayCustom.cpp: Added.
1604         (WebCore::CALLBACK_FUNC_DECL):
1605         (WebCore::INDEXED_PROPERTY_GETTER):
1606         (WebCore::INDEXED_PROPERTY_SETTER):
1607         * bindings/v8/custom/V8CanvasUnsignedByteArrayCustom.cpp: Added.
1608         (WebCore::CALLBACK_FUNC_DECL):
1609         (WebCore::INDEXED_PROPERTY_GETTER):
1610         (WebCore::INDEXED_PROPERTY_SETTER):
1611         * bindings/v8/custom/V8CanvasUnsignedIntArrayCustom.cpp: Added.
1612         (WebCore::CALLBACK_FUNC_DECL):
1613         (WebCore::INDEXED_PROPERTY_GETTER):
1614         (WebCore::INDEXED_PROPERTY_SETTER):
1615         * bindings/v8/custom/V8CanvasUnsignedShortArrayCustom.cpp: Added.
1616         (WebCore::CALLBACK_FUNC_DECL):
1617         (WebCore::INDEXED_PROPERTY_GETTER):
1618         (WebCore::INDEXED_PROPERTY_SETTER):
1619         * bindings/v8/custom/V8CustomBinding.h:
1620         * bindings/v8/custom/V8DocumentCustom.cpp:
1621         (WebCore::CALLBACK_FUNC_DECL):
1622         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
1623         (WebCore::CALLBACK_FUNC_DECL):
1624         * platform/graphics/GraphicsContext3D.h:
1625
1626 2009-09-25  Jeremy Orlow  <jorlow@chromium.org>
1627
1628         This is breaking Chromium try bots, so I'm counting this as a build fix.
1629
1630         Add more svn:ignore exceptions.  On different platforms, these files are
1631         generated with different case for WebCore.
1632
1633         * WebCore.gyp: Changed property svn:ignore.
1634
1635 2009-09-25  Alexey Proskuryakov  <ap@apple.com>
1636
1637         Reverting r48767, as it broke Windows build in a non-trivial way.
1638
1639         * bindings/js/JSAbstractWorkerCustom.cpp:
1640         (WebCore::JSAbstractWorker::addEventListener):
1641         (WebCore::JSAbstractWorker::removeEventListener):
1642         * bindings/js/JSDOMApplicationCacheCustom.cpp:
1643         (WebCore::JSDOMApplicationCache::addEventListener):
1644         (WebCore::JSDOMApplicationCache::removeEventListener):
1645         * bindings/js/JSDOMGlobalObject.cpp:
1646         (WebCore::JSDOMGlobalObject::createJSAttributeEventListener):
1647         * bindings/js/JSDOMWindowCustom.cpp:
1648         (WebCore::JSDOMWindow::addEventListener):
1649         (WebCore::JSDOMWindow::removeEventListener):
1650         * bindings/js/JSEventListener.cpp:
1651         (WebCore::JSEventListener::JSEventListener):
1652         (WebCore::JSEventListener::jsFunction):
1653         (WebCore::JSEventListener::markJSFunction):
1654         (WebCore::JSEventListener::handleEvent):
1655         (WebCore::JSEventListener::reportError):
1656         * bindings/js/JSEventListener.h:
1657         (WebCore::JSEventListener::create):
1658         * bindings/js/JSEventSourceCustom.cpp:
1659         (WebCore::JSEventSource::addEventListener):
1660         (WebCore::JSEventSource::removeEventListener):
1661         * bindings/js/JSLazyEventListener.cpp:
1662         (WebCore::JSLazyEventListener::JSLazyEventListener):
1663         (WebCore::JSLazyEventListener::jsFunction):
1664         (WebCore::JSLazyEventListener::parseCode):
1665         * bindings/js/JSLazyEventListener.h:
1666         (WebCore::JSLazyEventListener::create):
1667         * bindings/js/JSMessagePortCustom.cpp:
1668         (WebCore::JSMessagePort::addEventListener):
1669         (WebCore::JSMessagePort::removeEventListener):
1670         * bindings/js/JSNodeCustom.cpp:
1671         (WebCore::JSNode::addEventListener):
1672         (WebCore::JSNode::removeEventListener):
1673         * bindings/js/JSSVGElementInstanceCustom.cpp:
1674         (WebCore::JSSVGElementInstance::addEventListener):
1675         (WebCore::JSSVGElementInstance::removeEventListener):
1676         * bindings/js/JSWorkerContextCustom.cpp:
1677         (WebCore::JSWorkerContext::addEventListener):
1678         (WebCore::JSWorkerContext::removeEventListener):
1679         * bindings/js/JSXMLHttpRequestCustom.cpp:
1680         (WebCore::JSXMLHttpRequest::addEventListener):
1681         (WebCore::JSXMLHttpRequest::removeEventListener):
1682         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
1683         (WebCore::JSXMLHttpRequestUpload::addEventListener):
1684         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
1685         * bindings/js/ScriptEventListener.cpp:
1686         (WebCore::createAttributeEventListener):
1687         * bindings/objc/ObjCEventListener.h:
1688         * bindings/objc/ObjCEventListener.mm:
1689         (WebCore::ObjCEventListener::handleEvent):
1690         * bindings/scripts/CodeGeneratorJS.pm:
1691         * dom/EventListener.h:
1692         (WebCore::EventListener::reportError):
1693         (WebCore::EventListener::jsFunction):
1694         * dom/EventTarget.cpp:
1695         (WebCore::EventTarget::fireEventListeners):
1696         * inspector/InspectorDOMAgent.cpp:
1697         (WebCore::InspectorDOMAgent::handleEvent):
1698         * inspector/InspectorDOMAgent.h:
1699         * inspector/InspectorDOMStorageResource.cpp:
1700         (WebCore::InspectorDOMStorageResource::handleEvent):
1701         * inspector/InspectorDOMStorageResource.h:
1702         * loader/ImageDocument.cpp:
1703         (WebCore::ImageEventListener::handleEvent):
1704         * svg/animation/SVGSMILElement.cpp:
1705         (WebCore::ConditionEventListener::handleEvent):
1706         * workers/WorkerContext.cpp:
1707         (WebCore::WorkerContext::reportException):
1708
1709 2009-09-24  Tony Chang  <tony@chromium.org>
1710
1711         Reviewed by David Levin.
1712
1713         Add a gyp variable to allow building a debug webcore without debug
1714         symbols.  This allows for faster compile, link, and gdb times.
1715
1716         https://bugs.webkit.org/show_bug.cgi?id=29721
1717
1718         No new tests, build config change.
1719
1720         * WebCore.gyp/WebCore.gyp:
1721
1722 2009-09-25  Darin Fisher  <darin@chromium.org>
1723
1724         Reviewed by Dimitri Glazkov.
1725
1726         Declare RegisteredEventListener as a class instead of a struct.
1727         This fixes a warning in the Chromium build.
1728
1729         * dom/RegisteredEventListener.h:
1730
1731 2009-09-25  Dan Bernstein  <mitz@apple.com>
1732
1733         Reviewed by Jon Honeycutt.
1734
1735         WebCore part of
1736         <rdar://problem/7211635> 2 byte characters are displayed as garbaged
1737         <rdar://problem/7212626> garbled/gibberish text (off-by-one)
1738
1739         When the Windows Fonts directory contains more than one font file for a
1740         given font name, which of the fonts gets assigned to the name in the
1741         Core Graphics font database was determined arbitrarily and did not
1742         always match the font GDI used for the same font name. The mismatch
1743         caused character-to-glyph mapping to use one font and glyph rendering to
1744         use another.
1745
1746         The fix is to update the Core Graphics font database from the registry
1747         entries (that reflect the name-to-font mapping that GDI uses) after
1748         populating it with the result of scanning the Fonts directory. As a
1749         consequence, the directory needs to be scanned at startup every time the
1750         registry key changes, so the last value of the registry key is kept
1751         in the property list on disk so that it could be compared to the current
1752         value on startup.
1753
1754         * platform/graphics/win/FontDatabase.cpp:
1755         (WebCore::populateFontDatabaseFromPlist): Now takes a property list as
1756         a parameter and avoids round-tripping through XML by calling
1757         wkAddFontsFromPlist() instead of wkAddFontsFromPlistRepresentation().
1758         (WebCore::fontFilenamesFromRegistryKey):
1759         (WebCore::cgFontDBKey):
1760         (WebCore::writeFontDatabaseToPlist): Now takes the CG font DB property
1761         list and a property list with the font filenames from the registry and
1762         writes a dictionary with those property lists as values.
1763         (WebCore::fontFilenamesFromRegistry): Added. Returns an array with the
1764         values in the HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts
1765         registry key.
1766         (WebCore::populateFontDatabase): Changed to read the contents of the
1767         Fonts registry key and compare it with the last-saved value from the
1768         property list, and to call wkAddFontsFromRegistry() after populating the
1769         CG font DB from the file system. Uses wkCreateFontsPlist() instead of
1770         wkCreateFontsPlistRepresentation() to avoid round-tripping through XML.
1771
1772 2009-09-25  Geoffrey Garen  <ggaren@apple.com>
1773
1774         Reviewed by Darin Adler.
1775
1776         Inlined some object creation code, including lexicalGlobalObject access
1777         https://bugs.webkit.org/show_bug.cgi?id=29750
1778
1779         * bindings/js/JSInspectorBackendCustom.cpp:
1780         (WebCore::JSInspectorBackend::currentCallFrame):
1781         * inspector/JavaScriptDebugServer.cpp:
1782         (WebCore::JavaScriptDebugServer::hasBreakpoint): Updated for JavaScriptCore
1783         API changes.
1784
1785 2009-09-25  Dave Hyatt  <hyatt@apple.com>
1786
1787         Reviewed by Anders Carlsson.
1788
1789         https://bugs.webkit.org/show_bug.cgi?id=24399
1790         Make @import work in user stylesheets.  The first bug was that the URL wasn't being set on the
1791         user sheets themselves, so relative @import URLs couldn't resolve properly.  The second bug
1792         was that the loads would be denied.  This is fixed by using the requestUserCSSStyleSheet method
1793         instead of the normal request method.  In order to know when to do this, CSSStyleSheets now have
1794         a propagated boolean, m_isUserStyleSheet, that lets them know if they are user stylesheets or not.
1795
1796         * css/CSSImportRule.cpp:
1797         (WebCore::CSSImportRule::insertedIntoParent):
1798         * css/CSSStyleSheet.cpp:
1799         (WebCore::CSSStyleSheet::CSSStyleSheet):
1800         * css/CSSStyleSheet.h:
1801         (WebCore::CSSStyleSheet::setIsUserStyleSheet):
1802         (WebCore::CSSStyleSheet::isUserStyleSheet):
1803         * dom/Document.cpp:
1804         (WebCore::Document::pageUserSheet):
1805         (WebCore::Document::pageGroupUserSheets):
1806
1807 2009-09-25  Simon Fraser  <simon.fraser@apple.com>
1808
1809         Reviewed by Darin Adler.
1810
1811         ASSERTION FAILED: !repaintContainer || repaintContainer == this
1812         https://bugs.webkit.org/show_bug.cgi?id=29755
1813         
1814         It's possible for RenderObject::container() to return an object that is higher
1815         in the hierarchy than the repaintContainer that is being used to repaint an
1816         object. For example, this can happen when running an accelerated opacity
1817         transition on an element with a position:absolute parent, and a position:absolute child.
1818         
1819         In this case we need to detect when RenderObject::container() will skip over
1820         repaintContainer, and in that case adjust the coords to shift into repaintContainer's space.
1821
1822         Test: compositing/repaint/opacity-between-absolute.html
1823
1824         * rendering/RenderBox.cpp:
1825         (WebCore::RenderBox::mapLocalToContainer):
1826         (WebCore::RenderBox::computeRectForRepaint):
1827         * rendering/RenderInline.cpp:
1828         (WebCore::RenderInline::computeRectForRepaint):
1829         * rendering/RenderObject.cpp:
1830         (WebCore::RenderObject::container):
1831         * rendering/RenderObject.h:
1832
1833 2009-09-25  Simon Fraser  <simon.fraser@apple.com>
1834
1835         Reviewed by Darin Adler.
1836
1837         Crash with hardware accelerated rotation of a PDF image in a data URL
1838         <rdar://problem/7250378>
1839         
1840         PDF images don't return a color space from CGImageGetColorSpace(),
1841         so we need to null-check the return value before use.
1842
1843         Test: compositing/color-matching/pdf-image-match.html
1844
1845         * platform/graphics/mac/GraphicsLayerCA.mm:
1846         (WebCore::GraphicsLayerCA::setContentsToImage):
1847
1848 2009-09-25  Darin Adler  <darin@apple.com>
1849
1850         Reviewed by Geoffrey Garen.
1851
1852         Null-deref when first access to an Attr node is after its Element is destroyed
1853         https://bugs.webkit.org/show_bug.cgi?id=29748
1854
1855         Test: fast/dom/Attr/access-after-element-destruction.html
1856
1857         * bindings/js/JSAttrCustom.cpp:
1858         (WebCore::JSAttr::markChildren): Added. Keeps the ownerElement alive as
1859         long as the Attr is alive.
1860
1861         * bindings/js/JSNamedNodeMapCustom.cpp:
1862         (WebCore::JSNamedNodeMap::markChildren): Added. Keeps the Element alive as
1863         long as the NamedNodeMap is alive.
1864
1865         * dom/Attr.idl: Added CustomMarkFunction attribute.
1866
1867         * dom/NamedAttrMap.cpp:
1868         (WebCore::NamedNodeMap::getAttributeItem): Tweaked formatting.
1869         (WebCore::NamedNodeMap::detachFromElement): Call clearAttributes so we don't
1870         have attributes hanging around that might need an Attr node created; that way
1871         we won't crash with a null-dereference trying to deal with one of them. This
1872         can't happen when working with JavaScript since the Element will be kept
1873         alive due to the change above.
1874         (WebCore::NamedNodeMap::addAttribute): Fix function name in comment.
1875         (WebCore::NamedNodeMap::removeAttribute): Removed unneeded "+ 1" and added
1876         missing braces.
1877
1878         * dom/NamedAttrMap.h: Made the element function public so it can be used by
1879         the JavaScript binding to keep the Element alive.
1880
1881         * dom/NamedNodeMap.idl: Added CustomMarkFunction attribute.
1882
1883 2009-09-24  Alexey Proskuryakov  <ap@apple.com>
1884
1885         Reviewed by Darin Adler and Sam Weinig.
1886
1887         Onclick not fired for an element copied with cloneContents() or cloneNode()
1888         https://bugs.webkit.org/show_bug.cgi?id=25130
1889
1890         The change here is that JS event listeners don't keep a reference to a global object from
1891         where they were created, and instead take it as a parameter when parsing source code. Also,
1892         the listener creation won't fail just because it happens for an element in a frameless
1893         document.
1894         Thus, moving nodes between documents no longer results in having incorrect registered
1895         lazy event listeners on them.
1896
1897         Tests: fast/events/attribute-listener-cloned-from-frameless-doc-context-2.html
1898                fast/events/attribute-listener-cloned-from-frameless-doc-context.html
1899                fast/events/attribute-listener-cloned-from-frameless-doc.xhtml
1900                fast/events/attribute-listener-extracted-from-frameless-doc-context-2.html
1901                fast/events/attribute-listener-extracted-from-frameless-doc-context.html
1902
1903         * bindings/js/JSEventListener.cpp:
1904         (WebCore::JSEventListener::JSEventListener): Don't take a reference to JSDOMGlobalObject.
1905         (WebCore::JSEventListener::jsFunction): Take ScriptExecutionContext as a parameter for
1906         getting to JSDOMGlobalObject. It's not used in base class, but is in JSLazyEventListner.
1907         (WebCore::JSEventListener::markJSFunction): Don't mark the global object.
1908         (WebCore::JSEventListener::handleEvent): Get global object from ScriptExecutionContext.
1909         (WebCore::JSEventListener::reportError): Ditto.
1910
1911         * bindings/js/JSEventListener.h: (WebCore::JSEventListener::create): Don't keep a reference
1912         to JSDOMGlobalObject.
1913
1914         * bindings/js/JSLazyEventListener.cpp: (WebCore::JSLazyEventListener::parseCode): Listener
1915         creation was split between this function and ScriptEventListener; moved it here, as JS
1916         global object can be different now.
1917
1918         * bindings/js/JSLazyEventListener.h: (WebCore::JSLazyEventListener::create): Keep source URL,
1919         which can not be determined at parsing time.
1920
1921         * bindings/js/ScriptEventListener.cpp: (WebCore::createAttributeEventListener): Moved code
1922         for listener creation to JSLazyEventListener. XSSAuditor code remains here, because tests
1923         expect that errors are logged at document parsing time, and because I don't know what other
1924         side effects moving it vould have.
1925
1926         * dom/EventListener.h: handleEvent() and reportError() now take ScriptExecutionContext,
1927         because JSC needs a global context here.
1928
1929         * bindings/js/JSAbstractWorkerCustom.cpp:
1930         (WebCore::JSAbstractWorker::addEventListener):
1931         (WebCore::JSAbstractWorker::removeEventListener):
1932         * bindings/js/JSDOMApplicationCacheCustom.cpp:
1933         (WebCore::JSDOMApplicationCache::addEventListener):
1934         (WebCore::JSDOMApplicationCache::removeEventListener):
1935         * bindings/js/JSDOMGlobalObject.cpp:
1936         (WebCore::JSDOMGlobalObject::createJSAttributeEventListener):
1937         * bindings/js/JSDOMWindowCustom.cpp:
1938         (WebCore::JSDOMWindow::addEventListener):
1939         (WebCore::JSDOMWindow::removeEventListener):
1940         * bindings/js/JSEventSourceCustom.cpp:
1941         (WebCore::JSEventSource::addEventListener):
1942         (WebCore::JSEventSource::removeEventListener):
1943         * bindings/js/JSMessagePortCustom.cpp:
1944         (WebCore::JSMessagePort::addEventListener):
1945         (WebCore::JSMessagePort::removeEventListener):
1946         * bindings/js/JSNodeCustom.cpp:
1947         (WebCore::JSNode::addEventListener):
1948         (WebCore::JSNode::removeEventListener):
1949         * bindings/js/JSSVGElementInstanceCustom.cpp:
1950         (WebCore::JSSVGElementInstance::addEventListener):
1951         (WebCore::JSSVGElementInstance::removeEventListener):
1952         * bindings/js/JSWorkerContextCustom.cpp:
1953         (WebCore::JSWorkerContext::addEventListener):
1954         (WebCore::JSWorkerContext::removeEventListener):
1955         * bindings/js/JSXMLHttpRequestCustom.cpp:
1956         (WebCore::JSXMLHttpRequest::addEventListener):
1957         (WebCore::JSXMLHttpRequest::removeEventListener):
1958         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
1959         (WebCore::JSXMLHttpRequestUpload::addEventListener):
1960         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
1961         * bindings/objc/ObjCEventListener.h:
1962         * bindings/objc/ObjCEventListener.mm:
1963         (WebCore::ObjCEventListener::handleEvent):
1964         * bindings/scripts/CodeGeneratorJS.pm:
1965         * dom/EventTarget.cpp:
1966         (WebCore::EventTarget::fireEventListeners):
1967         * inspector/InspectorDOMAgent.cpp:
1968         (WebCore::InspectorDOMAgent::handleEvent):
1969         * inspector/InspectorDOMAgent.h:
1970         * inspector/InspectorDOMStorageResource.cpp:
1971         (WebCore::InspectorDOMStorageResource::handleEvent):
1972         * inspector/InspectorDOMStorageResource.h:
1973         * loader/ImageDocument.cpp:
1974         (WebCore::ImageEventListener::handleEvent):
1975         * svg/animation/SVGSMILElement.cpp:
1976         (WebCore::ConditionEventListener::handleEvent):
1977         * workers/WorkerContext.cpp:
1978         (WebCore::WorkerContext::reportException):
1979         Don't pass global object to JSEventListener::create(), which no longer needs it.
1980         Note that some of these functions still have an early return for null global object, which
1981         can probably be removed in a later patch.
1982         Pass ScriptExecutionContext to EventListener methods that now need it.
1983
1984 2009-09-25  Enrica Casucci  <enrica@apple.com>
1985
1986         Reviewed by Darin Adler, Dan Bernstein, Adele Peterson, and others.
1987
1988         Fix for https://bugs.webkit.org/show_bug.cgi?id=29740
1989         <rdar://problem/7168738> Gmail: After changing a foreground text color, pressing return doesn't apply background to new line
1990
1991         Change the way style is preserved when inserting a new paragraph.
1992         The original code handled insertion at the beginning and at the end of a paragraph as special
1993         cases. The newly created paragraph contained a set of nodes generated starting from the
1994         computed style of the insertion node. This approach has two problems:
1995         1. if the insertion node has a non opaque background color and one of the parent element did have
1996         a solid background color the new paragraph did not have the element with the solid color in the tree.
1997         2. in some circumstances it generated more markup than the original paragraph had (a span with bold, italic,
1998         background color and some font attribute was being reproduced as span + bold + italic + font as separate tags.
1999         The new approach is to recreate in the new paragraph the same hierarchy of nodes found in the
2000         paragraph where the insertion point is.
2001
2002         Test: editing/inserting/insert-bg-font.html
2003
2004         * editing/InsertParagraphSeparatorCommand.cpp:
2005         (WebCore::InsertParagraphSeparatorCommand::getAncestorsInsideBlock): retrieves the list of all the ancestors
2006         between the insert node and the outer block.
2007         (WebCore::InsertParagraphSeparatorCommand::cloneHierarchyUnderNewBlock): uses the list of ancestors to recreate
2008         in the new paragraph the same element hierarchy present in the starting paragraph.
2009         (WebCore::InsertParagraphSeparatorCommand::doApply): changed the code to handle the general case of insertion
2010         in the middle of the paragraph to use the new methods. Changed the handling of the insertion at the beginning and
2011         at the end of the paragraph to use the new methods instead of applying the calculated style.
2012         * editing/InsertParagraphSeparatorCommand.h: added methods getAncestorsInsideBlock and cloneHierarchyUnderNewBlock.
2013
2014 2009-09-25  Patrick Mueller  <Patrick_Mueller@us.ibm.com>
2015
2016         Reviewed by Timothy Hatcher.
2017
2018         Content-type parameters not taken into account when building form-data
2019         https://bugs.webkit.org/show_bug.cgi?id=28970
2020
2021         existing manual test case extended with new tests
2022
2023         * English.lproj/localizedStrings.js:
2024         * inspector/front-end/ResourceView.js:
2025         (WebInspector.ResourceView.prototype._refreshFormData):
2026         (WebInspector.ResourceView.prototype._refreshParms):
2027         * manual-tests/inspector/display-form-data.html:
2028
2029 2009-09-25  Yuan Song  <song.yuan@ericsson.com>
2030
2031         Reviewed by Darin Adler.
2032
2033         https://bugs.webkit.org/show_bug.cgi?id=14566
2034
2035         Raise SECURITY_ERR exception if an attempt is made to change document.domain to an invalid value.
2036
2037         Test: fast/js/invalid-domain-change-throws-exception.html
2038
2039         * dom/Document.cpp:
2040         (WebCore::Document::setDomain):
2041         * dom/Document.h:
2042         * dom/Document.idl:
2043
2044 2009-09-25  Adam Barth  <abarth@webkit.org>
2045
2046         Reviewed by Dimitri Glazkov.
2047
2048         [V8] Teach ScheduledAction::execute about isolated worlds
2049         https://bugs.webkit.org/show_bug.cgi?id=27703
2050
2051         When setTimeout is called with a string argument in an isolated
2052         world, we now compile the string in the isolated world.
2053
2054         Last time we tried this change, we got a lot of crashes.  This
2055         time we're using a fresh local handle as our context to avoid
2056         trouble if the peristent handle gets disposed before we leave
2057         the context.
2058
2059         Test: fast/dom/timer-clear-interval-in-handler-and-generate-error.html
2060
2061         * bindings/v8/ScheduledAction.cpp:
2062         (WebCore::ScheduledAction::execute):
2063
2064 2009-09-25  Paul Godavari  <paul@chromium.org>
2065
2066         Reviewed by Darin Fisher.
2067
2068         Fix a regression in Mac Chromium popup menus, where the user's
2069         selection was ignored and the popup became unresponsive.
2070         https://bugs.webkit.org/show_bug.cgi?id=29726
2071
2072         The fix is to notify the popup's client that the popup was hidden,
2073         even if the popup has no parent.
2074
2075         * platform/chromium/PopupMenuChromium.cpp:
2076         (WebCore::PopupListBox::hidePopup):
2077
2078 2009-09-25  Alexander Pavlov  <apavlov@chromium.org>
2079
2080         Reviewed by Dan Bernstein.
2081
2082         Enable Pasteboard::writePlainText for Chromium and fix code style nits.
2083         https://bugs.webkit.org/show_bug.cgi?id=29734
2084
2085         * platform/chromium/PasteboardChromium.cpp:
2086         (WebCore::Pasteboard::writePlainText):
2087         * platform/gtk/PasteboardGtk.cpp:
2088         (WebCore::Pasteboard::writePlainText):
2089         (WebCore::Pasteboard::writeURL):
2090         * platform/mac/PasteboardMac.mm:
2091         (WebCore::Pasteboard::writeSelection):
2092         (WebCore::Pasteboard::writePlainText):
2093         (WebCore::Pasteboard::writeURL):
2094         * platform/qt/PasteboardQt.cpp:
2095         (WebCore::Pasteboard::writePlainText):
2096
2097 2009-09-25  Yongjun Zhang  <yongjun.zhang@nokia.com>
2098
2099         Reviewed by Ariya Hidayat.
2100
2101         https://bugs.webkit.org/show_bug.cgi?id=28876
2102         [Qt] reduce peak memory consumption of text decoding.
2103
2104         Chop large input buffer into small buffers to reduce peak memory
2105         during decoding.
2106
2107         * platform/text/qt/TextCodecQt.cpp:
2108         (WebCore::TextCodecQt::decode):
2109
2110 2009-09-24  Jon Honeycutt  <jhoneycutt@apple.com>
2111
2112         Add a mechanism for automatically halting plug-ins.
2113
2114         Reviewed by Oliver Hunt and Alice Liu.
2115
2116         * GNUmakefile.am:
2117
2118         * WebCore.base.exp:
2119         Update export of Page constructor.
2120
2121         * WebCore.gypi:
2122
2123         * WebCore.pro:
2124
2125         * WebCore.vcproj/WebCore.vcproj:
2126         Add PluginHalter.{h,cpp}, PluginHalterClient.h, and
2127         HaltablePlugin.h.
2128
2129         * WebCore.xcodeproj/project.pbxproj:
2130         Add files to Mac project.
2131
2132         * loader/EmptyClients.h:
2133         Added an empty PluginHalterClient.
2134         (WebCore::EmptyPluginHalterClient::shouldHaltPlugin):
2135         Return false.
2136
2137         * page/PluginHalter.cpp: Added.
2138         (WebCore::PluginHalter::PluginHalter):
2139         (WebCore::PluginHalter::didStartPlugin):
2140         Add the object to the plug-in set. If this is the only item in the set,
2141         set m_oldestStartTime to this object's time, and start the timer.
2142         (WebCore::PluginHalter::didStopPlugin):
2143         Remove the plug-in from the set.
2144         (WebCore::PluginHalter::timerFired):
2145         Find the cut-off time as the current time minus the allowed run time;
2146         plug-ins older than this may be halted. Iterate over the plug-ins. Find
2147         the object with the oldest start time that is too young to be halted;
2148         we'll use its start time to set the timer's next fire time. For all
2149         plug-ins that are candidates to be halted, call the
2150         PluginHalterClient's shouldHaltPlugin(). If this function returns true,
2151         call the plug-in's halt() function. Remove these objects from the set
2152         of tracked plug-ins. Call startTimerIfNecessary() to restart the timer.
2153         (WebCore::PluginHalter::startTimerIfNecessary):
2154         If the timer is set to fire, or the set of tracked plug-ins is empty,
2155         return early. Set the timer to fire after the oldest plug-in has run
2156         for the allowed run time.
2157
2158         * page/PluginHalter.h: Added.
2159         (WebCore::PluginHalter::setPluginAllowedRunTime):
2160
2161         * page/PluginHalterClient.h: Added.
2162         (WebCore::PluginHalterClient::~PluginHalterClient):
2163
2164         * page/Page.cpp:
2165         (WebCore::Page::Page):
2166         Initialize m_pluginHalterClient. Call pluginHalterEnabledStateChanged()
2167         to create the PluginHalter if necessary.
2168         (WebCore::Page::pluginHalterEnabledStateChanged):
2169         If plug-in halting is enabled, create the PluginHalter. If it is
2170         disabled, clear it.
2171         (WebCore::Page::pluginAllowedRunTimeChanged):
2172         If there is a plug-in halter, call its setPluginAllowedRunTime().
2173         (WebCore::Page::didStartPlugin):
2174         If there is a plug-in halter, call its didStartPlugin().
2175         (WebCore::Page::didStopPlugin):
2176         If there is a plug-in halter, call its didStopPlugin().
2177
2178         * page/Page.h:
2179         Add a parameter to the Page constructor for the PluginHalterClient.
2180         Added declarations for didStartPlugin() and didStopPlugin(), which are
2181         called when HaltablePlugins are added to or removed from the page. Adds
2182         pluginAllowedRunTimeChanged() and pluginHalterEnabledStateChanged() to
2183         notify the Page when these settings are changed. Added members to hold
2184         the PluginHalter and the PluginHalterClient.
2185
2186         * page/Settings.cpp:
2187         (WebCore::Settings::Settings):
2188         (WebCore::Settings::setPluginHalterEnabled):
2189         If the enabled state has changed, call the Page's
2190         pluginHalterEnabledStateChanged().
2191         (WebCore::Settings::setPluginAllowedRunTime):
2192         Call the Page's pluginAllowedRunTimeChanged().
2193
2194         * page/Settings.h:
2195         (WebCore::Settings::pluginHalterEnabled):
2196         (WebCore::Settings::pluginAllowedRunTime):
2197
2198         * page/HaltablePlugin.h: Added. Defines an interface for plug-ins that
2199         can be automatically halted.
2200         (WebCore::HaltablePlugin::~HaltablePlugin):
2201
2202         * svg/graphics/SVGImage.cpp:
2203         (WebCore::SVGImage::dataChanged):
2204         Pass a dummy PluginHalterClient.
2205
2206 2009-09-24  Simon Fraser  <simon.fraser@apple.com>
2207
2208         Reviewed by Dan Bernstein.
2209
2210         REGRESSION: webkit-transform scale no longer works properly in nightly build
2211         https://bugs.webkit.org/show_bug.cgi?id=29730
2212         
2213         When the initial or final state of a scale animation does not specify a transform,
2214         use a default scale of 1, rather than zero.
2215
2216         Test: compositing/transitions/scale-transition-no-start.html
2217
2218         * platform/graphics/mac/GraphicsLayerCA.mm:
2219         (WebCore::getTransformFunctionValue):
2220
2221 2009-09-24  John Gregg  <johnnyg@google.com>
2222
2223         Reviewed by Eric Seidel.
2224
2225         isEnabled switch for notifications (experimental) in Page Settings
2226         https://bugs.webkit.org/show_bug.cgi?id=28930
2227
2228         Adds a run-time flag in Settings object that controls whether
2229         to expose desktop notifications.
2230
2231         No new test, but test code also modified to set this preference.
2232
2233         * page/DOMWindow.cpp:
2234         (WebCore::DOMWindow::webkitNotifications): check preference before returning notifications object
2235         * page/Settings.cpp:
2236         (WebCore::Settings::Settings):
2237         (WebCore::Settings::setExperimentalNotificationsEnabled):
2238         * page/Settings.h:
2239         (WebCore::Settings::experimentalNotificationsEnabled):
2240
2241 2009-09-24  Dan Bernstein  <mitz@apple.com>
2242
2243         Reviewed by Sam Weinig.
2244
2245         Fix <rdar://problem/7162000> Crash while trying to
2246         calculate the horizontal position of image
2247
2248         Test: fast/inline-block/relative-positioned-rtl-crash.html
2249
2250         * rendering/RenderBox.cpp:
2251         (WebCore::RenderBox::calcAbsoluteHorizontalReplaced): Corrected an
2252         isInline() test to isRenderInline(). This is similar to r41259.
2253
2254 2009-09-24  Jessie Berlin  <jberlin@webkit.org>
2255
2256         Reviewed by Timothy Hatcher.
2257
2258         Fix expanding profile call stacks being broken after sorting.
2259         https://bugs.webkit.org/show_bug.cgi?id=26423
2260
2261         * inspector/front-end/ProfileDataGridTree.js:
2262         (WebInspector.ProfileDataGridNode.prototype.sort):
2263         Set shouldRefreshChildren to true on collapsed nodes with children so that expanding it
2264         causes the children to be placed in the right positions.
2265
2266 2009-09-24  Geoffrey Garen  <ggaren@apple.com>
2267
2268         Reviewed by Stephanie Lewis.
2269
2270         Fixed sudden termination console spew due to too many calls to
2271         enableSuddenTermination.
2272         
2273         <rdar://problem/7063125> 10A410: Safari logging enableSuddenTermination errors
2274
2275         * page/DOMWindow.cpp:
2276         (WebCore::removeUnloadEventListener):
2277         (WebCore::removeAllUnloadEventListeners):
2278         (WebCore::removeBeforeUnloadEventListener):
2279         (WebCore::removeAllBeforeUnloadEventListeners): Only
2280         enableSuddenTermination if the set of listeners is empty *and* this
2281         window was in the set. Otherwise, a no-op will cause us to enableSuddenTermination.
2282
2283 2009-09-24  Carol Szabo  <carol.szabo@nokia.com>
2284
2285         Reviewed by Alexey Proskuryakov.
2286
2287         WebKit returns "" instead of null when getting
2288         inexistent, forbidden or invalidly named headers.
2289         https://bugs.webkit.org/show_bug.cgi?id=29140
2290
2291         * xml/XMLHttpRequest.cpp:
2292         (WebCore::XMLHttpRequest::getResponseHeader):
2293         Changed to return null as it should according to the spec.
2294
2295 2009-09-24  Jeremy Orlow  <jorlow@chromium.org>
2296
2297         Reviewed by Dimitri Glazkov.
2298
2299         Add GYP generated files to svn:ignore
2300         https://bugs.webkit.org/show_bug.cgi?id=29724
2301
2302         Adding the following files to the svn:ignore list (all in the
2303         WebCore/WebCore.gyp directory)
2304
2305         WebCore.xcodeproj
2306         WebCore.sln
2307         WebCore.vcproj
2308         WebCore_Debug.rules
2309         WebCore_Release.rules
2310         WebCore_Release - no tcmalloc.rules
2311         WebCore_Purify.rules
2312         WebCore.mk
2313         WebCore_Debug_rules.mk
2314         WebCore_Release_rules.mk
2315         WebCore_Release - no tcmalloc_rules.mk
2316         WebCore_Purify_rules.mk
2317         WebCore.scons
2318         WebCore_main.scons
2319
2320         * WebCore.gyp: Changed property svn:ignore.
2321
2322 2009-09-24  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2323
2324         Unreviewed. Mac build fix.
2325
2326         * page/EventHandler.cpp:
2327         (WebCore::EventHandler::shouldTurnVerticalTicksIntoHorizontal):
2328         remove unused parameter from function signature;
2329
2330 2009-09-24  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2331
2332         Reviewed by Oliver Hunt.
2333
2334         Implement correct horizontal scrollbar behavior for GTK+ also on
2335         styled scrollbars.
2336
2337         https://bugs.webkit.org/show_bug.cgi?id=29348
2338         [Gtk] Scrollwheel on horizontal scrollbars should slide horizontally
2339
2340         Test: platform/gtk/scrollbars/overflow-scrollbar-horizontal-wheel-scroll.html
2341
2342         * page/EventHandler.cpp:
2343         (WebCore::EventHandler::handleWheelEvent): on GTK+, when using the
2344         wheel with the pointer on the horizontal scrollbar, scroll
2345         horizontally;
2346         * platform/PlatformWheelEvent.h:
2347         * platform/gtk/WheelEventGtk.cpp:
2348         (WebCore::PlatformWheelEvent::swapOrientation): allow adding a
2349         vertical scroll to the horizontal one;
2350
2351 2009-09-24  Jeremy Orlow  <jorlow@chromium.org>
2352
2353         Reviewed by Eric Seidel.
2354
2355         StorageNamespace::storageArea() should take in a PassRefPtr<StorageOrigin>
2356         https://bugs.webkit.org/show_bug.cgi?id=29290
2357
2358         Modified StorageNamespace::storageArea() to take in a PassRefPtr<StorageOrigin>
2359         per http://webkit.org/coding/RefPtr.html
2360
2361         No behavior change, so no tests.
2362
2363         * storage/StorageNamespace.h:
2364         * storage/StorageNamespaceImpl.cpp:
2365         (WebCore::StorageNamespaceImpl::storageArea):
2366         * storage/StorageNamespaceImpl.h:
2367
2368 2009-09-24  Geoffrey Garen  <ggaren@apple.com>
2369
2370         Reviewed by Sam Weinig.
2371
2372         Added back enable/disableSuddenTermination() functionality I accidentally
2373         removed in my last patch.
2374
2375         * page/DOMWindow.cpp:
2376         (WebCore::addUnloadEventListener):
2377         (WebCore::removeUnloadEventListener):
2378         (WebCore::removeAllUnloadEventListeners):
2379         (WebCore::addBeforeUnloadEventListener):
2380         (WebCore::removeBeforeUnloadEventListener):
2381         (WebCore::removeAllBeforeUnloadEventListeners):
2382         (WebCore::DOMWindow::dispatchAllPendingUnloadEvents):
2383         (WebCore::DOMWindow::~DOMWindow):
2384         (WebCore::DOMWindow::addEventListener):
2385         (WebCore::DOMWindow::removeEventListener):
2386         (WebCore::DOMWindow::removeAllEventListeners):
2387
2388 2009-09-24  Sam Weinig  <sam@webkit.org>
2389
2390         Reviewed by Steve Falkenburg and Mark Rowe.
2391
2392         Don't pass -F to GCC on non-mac platforms since it is an darwin only.
2393
2394         * DerivedSources.make:
2395
2396 2009-09-24  Sam Weinig  <sam@webkit.org>
2397
2398         Fix windows build.
2399
2400         * dom/Element.idl:
2401
2402 2009-09-23  Stephen White  <senorblanco@chromium.org>
2403
2404         Reviewed by Eric Seidel.
2405
2406         Revert the relevant parts of r47925, and implement an alternate
2407         fix (localize the coordinate check to GraphicsContext::clipPath()).
2408         This fixes http://crbug.com/21174.
2409
2410         Covered by LayoutTests/svg/dynamic-updates/SVGClipPathElement-dom-clipPathUnits-attr.html.
2411
2412         * platform/graphics/skia/GraphicsContextSkia.cpp:
2413         (WebCore::GraphicsContext::clipPath):
2414         * platform/graphics/skia/PlatformContextSkia.cpp:
2415         (PlatformContextSkia::currentPathInLocalCoordinates):
2416
2417 2009-09-24  Brady Eidson  <beidson@apple.com>
2418
2419         Reviewed by Sam Weinig.
2420
2421         Merge changes from Mozilla's FTP directory parser.
2422         <rdar://problem/7227620> and https://bugs.webkit.org/show_bug.cgi?id=29294
2423
2424         FTP layout tests not possible at this time.
2425         https://bugs.webkit.org/show_bug.cgi?id=29719 tracks making them possible.
2426
2427         * loader/FTPDirectoryParser.cpp:
2428         (WebCore::ParsingFailed):
2429         (WebCore::parseOneFTPLine):
2430
2431 2009-09-24  Philippe Normand  <pnormand@igalia.com>
2432
2433         Reviewed by Gustavo Noronha.
2434
2435         [GTK] re-enable some media tests
2436         https://bugs.webkit.org/show_bug.cgi?id=29716
2437
2438         make canPlayType() return "probably" if mime-type is known
2439         and codecs string is not empty. If codecs is empty return
2440         "maybe".
2441
2442         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
2443         (WebCore::MediaPlayerPrivate::supportsType):
2444
2445 2009-09-24  Sam Weinig  <sam@webkit.org>
2446
2447         Reviewed by Dan Bernstein.
2448
2449         Fix for https://bugs.webkit.org/show_bug.cgi?id=29703
2450         Add a function to element to check whether it matches a CSS selector
2451
2452         Implement Element.webkitMatchesSelector.
2453
2454         * css/CSSSelectorList.cpp:
2455         (WebCore::forEachTagSelector):
2456         (WebCore::forEachSelector):
2457         (WebCore::SelectorNeedsNamespaceResolutionFunctor::operator()):
2458         (WebCore::CSSSelectorList::selectorsNeedNamespaceResolution):
2459         * css/CSSSelectorList.h:
2460         Moved code to iterate the CSSSelectorList and determine if any
2461         selectors need namespace resolution from a static function in
2462         Node.cpp to CSSSelectorList so that it can be used by webkitMatchesSelector
2463         as well as querySelector/querySelectorAll.
2464
2465         * dom/Element.cpp:
2466         (WebCore::Element::webkitMatchesSelector):
2467         * dom/Element.h: 
2468         * dom/Element.idl:
2469         Implement the new function. Handles exceptional cases identically to
2470         querySelector/querySelectorAll.
2471
2472         * dom/Node.cpp:
2473         (WebCore::Node::querySelector):
2474         (WebCore::Node::querySelectorAll):
2475         Moved selectorsNeedNamespaceResolution to CSSSelectorList from here.
2476
2477 2009-09-24  Vitaly Repeshko  <vitalyr@chromium.org>
2478
2479         Reviewed by Dimitri Glazkov.
2480
2481         [V8] Fixed bindings build after http://trac.webkit.org/changeset/48701
2482         https://bugs.webkit.org/show_bug.cgi?id=29713
2483
2484         Got rid of isWindowEvent in function signatures:
2485         * bindings/v8/V8AbstractEventListener.cpp:
2486         (WebCore::V8AbstractEventListener::invokeEventHandler):
2487         (WebCore::V8AbstractEventListener::handleEvent):
2488         (WebCore::V8AbstractEventListener::getReceiverObject):
2489         * bindings/v8/V8AbstractEventListener.h:
2490         * bindings/v8/V8LazyEventListener.cpp:
2491         (WebCore::V8LazyEventListener::callListenerFunction):
2492         * bindings/v8/V8LazyEventListener.h:
2493         * bindings/v8/V8WorkerContextEventListener.cpp:
2494         (WebCore::V8WorkerContextEventListener::handleEvent):
2495         (WebCore::V8WorkerContextEventListener::callListenerFunction):
2496         (WebCore::V8WorkerContextEventListener::getReceiverObject):
2497         * bindings/v8/V8WorkerContextEventListener.h:
2498         * bindings/v8/custom/V8CustomEventListener.cpp:
2499         (WebCore::V8EventListener::callListenerFunction):
2500         * bindings/v8/custom/V8CustomEventListener.h:
2501
2502         Switched to EventTarget methods of adding/removing listeners:
2503         * bindings/v8/custom/V8DOMApplicationCacheCustom.cpp:
2504         (WebCore::toEventID):
2505         (WebCore::ACCESSOR_SETTER):
2506
2507         * dom/EventTarget.h: Some functions were incorrectly marked
2508         as JSC-specific.
2509
2510 2009-09-24  Pavel Feldman  <pfeldman@chromium.org>
2511
2512         Reviewed by Timothy Hatcher.
2513
2514         Web Inspector: Color-code watch expression errors with red.
2515
2516         https://bugs.webkit.org/show_bug.cgi?id=29707
2517
2518         * inspector/front-end/WatchExpressionsSidebarPane.js:
2519         (WebInspector.WatchExpressionsSection.prototype.update):
2520         (WebInspector.WatchExpressionTreeElement.prototype.update):
2521         * inspector/front-end/inspector.css:
2522
2523 2009-09-24  Pavel Feldman  <pfeldman@chromium.org>
2524
2525         Reviewed by Timothy Hatcher.
2526
2527         Web Inspector: Fix formatting for messages derived from resource warnings,
2528         couple of drive-by formatting fixes.
2529
2530         https://bugs.webkit.org/show_bug.cgi?id=29705
2531
2532         * inspector/InspectorFrontend.cpp:
2533         (WebCore::InspectorFrontend::addMessageToConsole):
2534         * inspector/front-end/ConsoleView.js:
2535         * inspector/front-end/InjectedScript.js:
2536         (InjectedScript._evaluateAndWrap):
2537         * inspector/front-end/WatchExpressionsSidebarPane.js:
2538         (WebInspector.WatchExpressionsSection.prototype.update):
2539
2540 2009-09-22  Pavel Feldman  <pfeldman@chromium.org>
2541
2542         Reviewed by Timothy Hatcher.
2543
2544         WebInspector: Implement InspectorController::copyNode(id).
2545
2546         https://bugs.webkit.org/show_bug.cgi?id=28357
2547
2548         * inspector/InspectorBackend.cpp:
2549         (WebCore::InspectorBackend::copyNode):
2550         * inspector/InspectorBackend.h:
2551         * inspector/InspectorBackend.idl:
2552         * inspector/front-end/ElementsPanel.js:
2553         (WebInspector.ElementsPanel.prototype.handleCopyEvent):
2554
2555 2009-09-24  Oliver Hunt  <oliver@apple.com>
2556
2557         Reviewed by NOBODY(rollout)
2558
2559         Roll out r48712 as it is incorrect.
2560
2561         Overriding getPropertyNames is incorrect.
2562
2563         * bridge/runtime_array.cpp:
2564         * bridge/runtime_array.h:
2565
2566 2009-09-24  Xan Lopez  <xlopez@igalia.com>
2567
2568         Revert r48697, since it broke key handling notification to GTK+.
2569
2570         * platform/gtk/KeyEventGtk.cpp:
2571         (WebCore::keyIdentifierForGdkKeyCode):
2572         (WebCore::singleCharacterString):
2573
2574 2009-09-24  Philippe Normand  <pnormand@igalia.com>
2575
2576         Reviewed by Xan Lopez.
2577
2578         [GTK] GStreamer MediaPlayer is unable to correctly querry duration
2579         https://bugs.webkit.org/show_bug.cgi?id=24639
2580
2581         check duration returned by gst_element_query_duration() only
2582         when using GStreamer < 0.10.23.
2583
2584         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
2585         (WebCore::MediaPlayerPrivate::duration):
2586
2587 2009-09-24  Benjamin Poulain  <benjamin.poulain@nokia.com>
2588
2589         Reviewed by Eric Seidel.
2590
2591         The indices of RuntimeArray should be enumerated like for a regular array.
2592         https://bugs.webkit.org/show_bug.cgi?id=29005
2593
2594         * bridge/runtime_array.cpp:
2595         (JSC::RuntimeArray::getPropertyNames):
2596         * bridge/runtime_array.h:
2597
2598 2009-09-23  Alexander Pavlov  <apavlov@chromium.org>
2599
2600         Reviewed by Eric Seidel.
2601
2602         Introduce Pasteboard::writePlaintext(const String&) so that copying
2603         of the inspected elements HTML will be possible in WebInspector.
2604         https://bugs.webkit.org/show_bug.cgi?id=29634
2605
2606         * platform/Pasteboard.h:
2607         * platform/android/TemporaryLinkStubs.cpp:
2608         (Pasteboard::writePlainText):
2609         * platform/chromium/ChromiumBridge.h:
2610         * platform/chromium/PasteboardChromium.cpp:
2611         (WebCore::Pasteboard::writePlainText):
2612         * platform/gtk/PasteboardGtk.cpp:
2613         (WebCore::Pasteboard::writePlainText):
2614         * platform/haiku/PasteboardHaiku.cpp:
2615         (WebCore::Pasteboard::writePlainText):
2616         * platform/mac/PasteboardMac.mm:
2617         (WebCore::Pasteboard::writePlainText):
2618         * platform/qt/PasteboardQt.cpp:
2619         (WebCore::Pasteboard::writePlainText):
2620         * platform/win/PasteboardWin.cpp:
2621         (WebCore::Pasteboard::writeSelection):
2622         (WebCore::Pasteboard::writePlainText):
2623         * platform/wince/PasteboardWince.cpp:
2624         (WebCore::Pasteboard::writePlainText):
2625         * platform/wx/PasteboardWx.cpp:
2626         (WebCore::Pasteboard::writeSelection):
2627         (WebCore::Pasteboard::writePlainText):
2628         (WebCore::Pasteboard::writeURL):
2629
2630 2009-09-24  Oswald Buddenhagen  <oswald.buddenhagen@nokia.com>
2631
2632         Reviewed by Simon Hausmann.
2633
2634         Fix QApp::translate() calls to provide the correct class name without
2635         a trailing comma.
2636
2637         * platform/qt/Localizations.cpp:
2638         (WebCore::localizedMediaTimeDescription):
2639
2640 2009-09-24  Geoffrey Garen  <ggaren@apple.com>
2641
2642         More build fix: Removed JSSharedWorkerContextCustom.cpp from project
2643         files, since it no longer exists in the repository.
2644
2645         * GNUmakefile.am:
2646         * WebCore.gypi:
2647         * WebCore.pro:
2648         * WebCore.vcproj/WebCore.vcproj:
2649
2650 2009-09-24  Geoffrey Garen  <ggaren@apple.com>
2651
2652         Windows build fix: Declare set/unsetPendingActivity public, so
2653         SharedWorkerScriptLoader can call them.
2654
2655         * dom/ActiveDOMObject.h:
2656
2657 2009-09-24  Geoffrey Garen  <ggaren@apple.com>
2658
2659         Fixed a bit of the Windows build.
2660
2661         * workers/SharedWorker.idl: Declare a custom mark function. (I accidentally
2662         removed this in my last patch.)
2663         * WebCore.xcodeproj/project.pbxproj: Added JSSharedWorkerCustom.cpp back
2664         to the build. (I accidentally removed this in my last patch.)
2665
2666 2009-09-23  Geoffrey Garen  <ggaren@apple.com>
2667
2668         32-bit build fix: restore previous cast that I thought was unnecessary.
2669
2670         * xml/XMLHttpRequest.cpp:
2671         (WebCore::XMLHttpRequest::didSendData):
2672         (WebCore::XMLHttpRequest::didReceiveData):
2673
2674 2009-09-23  Geoffrey Garen  <ggaren@apple.com>
2675
2676         Reviewed by Sam Weinig.
2677
2678         Bring a little sanity to this crazy EventTarget world of ours
2679         https://bugs.webkit.org/show_bug.cgi?id=29701
2680
2681         Lots of EventTarget refactoring to achieve a single shared implementation
2682         that fixes some of the performance and correctness bugs of the many individual
2683         implementations, and makes reasoning about EventTargets and EventListeners
2684         much easier.
2685         
2686         The basic design is this:
2687             - EventTarget manages a set of EventListeners.
2688             - onXXX EventListener attributes forward to standard EventTarget APIs.
2689             - Since the onXXX code is repetitive, it is usually done with macros
2690               of the form DEFINE_ATTRIBUTE_EVENT_LISTENER(attributeName).
2691             - EventTarget provides a shared implementation of dispatchEvent,
2692               which subclasses with special event dispatch rules, like Node, override.
2693             - To support Node, which lazily instantiates its EventTarget data,
2694               EventTarget has no data members, and instead makes a virtual call
2695               to get its data from wherever its subclass chose to store it.
2696               
2697         Code that used to call dispatchEvent, passing an ExceptionCode paratmeter,
2698         even though no exception could be thrown, has been changed not to do so,
2699         to improve clarity and performance.
2700         
2701         Code that used to call a special dispatchXXXEvent function, which just
2702         turned around and called dispatchEvent, has been changed to call
2703         dispatchEvent, to improve clarity and performance.
2704
2705         * WebCore.base.exp:
2706         * WebCore.xcodeproj/project.pbxproj: Another day in the life of a WebKit
2707         engineer.
2708
2709         * bindings/js/JSDOMBinding.cpp:
2710         (WebCore::isObservableThroughDOM): Updated for Node API change. Added
2711         "is not in the document but is firing event listeners" as a condition
2712         that makes a Node observable in the DOM, so that event listeners firing
2713         on removed nodes are not destroyed midstream. (This was a long-standing
2714         bug that was somewhat hidden by the old implementation's habit of
2715         copying the RegisteredEventListener vector before firing events, which
2716         would keep almost all the relevant objects from being destroyed.)
2717
2718         * bindings/js/JSEventListener.cpp:
2719         (WebCore::JSEventListener::handleEvent): Removed the isWindowEvent flag
2720         because it was one of the most elaborately planned no-ops in the history
2721         of software crime, and one of the reasons clients thought they needed more
2722         than one dispatchEvent function even though they didn't.
2723         * bindings/js/JSEventListener.h:
2724
2725         * bindings/js/JSDOMWindowCustom.cpp:
2726         (WebCore::JSDOMWindow::markChildren):
2727         (WebCore::JSMessagePort::markChildren):
2728         * bindings/js/JSNodeCustom.cpp:
2729         (WebCore::JSNode::markChildren):
2730         * bindings/js/JSAbstractWorkerCustom.cpp:
2731         * bindings/js/JSDOMApplicationCacheCustom.cpp:
2732         * bindings/js/JSDedicatedWorkerContextCustom.cpp:
2733         * bindings/js/JSEventSourceCustom.cpp:
2734         * bindings/js/JSMessagePortCustom.cpp:
2735         * bindings/js/JSSharedWorkerContextCustom.cpp: Removed.
2736         * bindings/js/JSWebSocketCustom.cpp:
2737         * bindings/js/JSWorkerContextCustom.cpp:
2738         (WebCore::JSWorkerContext::markChildren):
2739         * bindings/js/JSWorkerCustom.cpp:
2740         * bindings/js/JSXMLHttpRequestCustom.cpp:
2741         (WebCore::JSXMLHttpRequest::markChildren):
2742         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
2743         (WebCore::JSXMLHttpRequestUpload::markChildren): EventListener marking is
2744         now autogenerated. Classes that still have custom mark functions for other
2745         reasons now call a shared EventTarget API to mark their EventListeners.
2746
2747         * bindings/objc/ObjCEventListener.h:
2748         * bindings/objc/ObjCEventListener.mm:
2749         (WebCore::ObjCEventListener::handleEvent): Bye bye isWindowEvent.
2750
2751         * bindings/scripts/CodeGeneratorJS.pm: Autogeneration support for
2752         marking and invalidating event listeners.
2753
2754         * dom/CharacterData.cpp:
2755         (WebCore::CharacterData::dispatchModifiedEvent):
2756         * dom/ContainerNode.cpp:
2757         (WebCore::ContainerNode::insertBefore):
2758         (WebCore::ContainerNode::replaceChild):
2759         (WebCore::willRemoveChild):
2760         (WebCore::ContainerNode::appendChild):
2761         (WebCore::dispatchChildInsertionEvents):
2762         (WebCore::dispatchChildRemovalEvents):
2763         * dom/Document.cpp:
2764         (WebCore::Document::removeAllEventListeners):
2765         (WebCore::Document::implicitClose):
2766         (WebCore::Document::setFocusedNode):
2767         (WebCore::Document::dispatchWindowEvent):
2768         (WebCore::Document::dispatchWindowLoadEvent):
2769         (WebCore::Document::finishedParsing):
2770         * dom/Document.h: Use dispatchEvent directly.
2771
2772         * dom/Element.h: Moved a few event listener attributes down from Node,
2773         since they don't apply to all Nodes, only Elements.
2774
2775         * dom/EventListener.h: Removed isWindowEvent parameter.
2776
2777         * dom/EventNames.h: Added the "display" event name, so it works correctly
2778         with attribute macros, and for performance.
2779
2780         * dom/EventTarget.cpp:
2781         (WebCore::forbidEventDispatch):
2782         (WebCore::allowEventDispatch):
2783         (WebCore::eventDispatchForbidden): Made this code (embarrasingly) thread
2784         safe, since it's now called on multiple threads. (Currently, we only forbid
2785         event dispatch on the main thread. If we ever want to forbid event dispatch
2786         on secondary threads, we can improve it then.)
2787
2788         (WebCore::EventTarget::addEventListener):
2789         (WebCore::EventTarget::removeEventListener):
2790         (WebCore::EventTarget::setAttributeEventListener):
2791         (WebCore::EventTarget::getAttributeEventListener):
2792         (WebCore::EventTarget::clearAttributeEventListener):
2793         (WebCore::EventTarget::dispatchEvent):
2794         (WebCore::EventTarget::fireEventListeners):
2795         (WebCore::EventTarget::getEventListeners):
2796         (WebCore::EventTarget::removeAllEventListeners):
2797         * dom/EventTarget.h:
2798         (WebCore::FiringEventEndIterator::FiringEventEndIterator):
2799         (WebCore::EventTarget::ref):
2800         (WebCore::EventTarget::deref):
2801         (WebCore::EventTarget::markEventListeners):
2802         (WebCore::EventTarget::invalidateEventListeners):
2803         (WebCore::EventTarget::isFiringEventListeners):
2804         (WebCore::EventTarget::hasEventListeners): The ONE TRUE IMPLEMENTATION of
2805         EventTarget APIs, crafted from an amalgam of all the different versions
2806         we used to have. The most significant change here is that we no longer
2807         make a copy of an EventListener vector before firing the events in the
2808         vector -- instead, we use a reference to the original vector, along with
2809         a notification mechanism for the unlikely case when an EventListener is
2810         removed from the vector. This substantially reduces malloc, copying, and
2811         refcount overhead, and complexity.
2812
2813         * dom/InputElement.cpp:
2814         (WebCore::InputElement::setValueFromRenderer):
2815         * dom/MessageEvent.h:
2816         (WebCore::MessageEvent::create): Use dispatchEvent directly.
2817
2818         * dom/MessagePort.cpp:
2819         (WebCore::MessagePort::dispatchMessages):
2820         (WebCore::MessagePort::eventTargetData):
2821         (WebCore::MessagePort::ensureEventTargetData):
2822         * dom/MessagePort.h:
2823         (WebCore::MessagePort::setOnmessage):
2824         (WebCore::MessagePort::onmessage):
2825         * dom/MessagePort.idl: Removed custom EventTarget implementation.
2826
2827         * dom/MutationEvent.h:
2828         (WebCore::MutationEvent::create): Added some default values so callers
2829         can construct MutationEvents more easily, without calling a custom dispatch
2830         function.
2831
2832         * dom/Node.cpp:
2833         (WebCore::Node::addEventListener):
2834         (WebCore::Node::removeEventListener):
2835         (WebCore::Node::eventTargetData):
2836         (WebCore::Node::ensureEventTargetData):
2837         (WebCore::Node::handleLocalEvents):
2838         (WebCore::Node::dispatchEvent):
2839         (WebCore::Node::dispatchGenericEvent):
2840         (WebCore::Node::dispatchSubtreeModifiedEvent):
2841         (WebCore::Node::dispatchUIEvent):
2842         (WebCore::Node::dispatchKeyEvent):
2843         (WebCore::Node::dispatchMouseEvent):
2844         (WebCore::Node::dispatchWheelEvent):
2845         (WebCore::Node::dispatchFocusEvent):
2846         (WebCore::Node::dispatchBlurEvent):
2847         * dom/Node.h:
2848         (WebCore::Node::preDispatchEventHandler):
2849         (WebCore::Node::postDispatchEventHandler):
2850         * dom/Node.idl:
2851         * dom/NodeRareData.h:
2852         (WebCore::NodeRareData::eventTargetData):
2853         (WebCore::NodeRareData::ensureEventTargetData): Use the shared EventTarget
2854         interface, and call dispatchEvent directly instead of custom dispatchXXXEvent
2855         functions that just forwarded to dispatchEvent.
2856
2857         * dom/RegisteredEventListener.cpp:
2858         * dom/RegisteredEventListener.h:
2859         (WebCore::RegisteredEventListener::RegisteredEventListener):
2860         (WebCore::operator==): This is just a simple struct now, since we no longer
2861         do a complicated copy / refCount / isRemoved dance just to honor the rule
2862         that an EventListener can be removed during event dispatch.
2863
2864         * history/CachedFrame.cpp:
2865         (WebCore::CachedFrameBase::restore): Removed another custom dispatchEvent.
2866
2867         * html/HTMLBodyElement.cpp:
2868         * html/HTMLBodyElement.h: Use the shared EventTarget API.
2869
2870         * html/HTMLFormControlElement.cpp:
2871         (WebCore::HTMLFormControlElement::dispatchFormControlChangeEvent):
2872         (WebCore::HTMLFormControlElement::checkValidity):
2873         * html/HTMLFormElement.cpp:
2874         (WebCore::HTMLFormElement::handleLocalEvents):
2875         (WebCore::HTMLFormElement::prepareSubmit):
2876         (WebCore::HTMLFormElement::reset):
2877         * html/HTMLFormElement.h: Use the standard dispatchEvent API.
2878
2879         * html/HTMLFrameSetElement.cpp:
2880         * html/HTMLFrameSetElement.h: Use the shared EventTarget API.
2881
2882         * html/HTMLImageLoader.cpp:
2883         (WebCore::HTMLImageLoader::dispatchLoadEvent):
2884         * html/HTMLInputElement.cpp:
2885         (WebCore::HTMLInputElement::onSearch):
2886         * html/HTMLMediaElement.cpp:
2887         (WebCore::HTMLMediaElement::loadInternal):
2888         * html/HTMLScriptElement.cpp:
2889         (WebCore::HTMLScriptElement::dispatchLoadEvent):
2890         (WebCore::HTMLScriptElement::dispatchErrorEvent):
2891         * html/HTMLSourceElement.cpp:
2892         (WebCore::HTMLSourceElement::errorEventTimerFired):
2893         * html/HTMLTokenizer.cpp:
2894         (WebCore::HTMLTokenizer::notifyFinished): Use the standard dispatchEvent API.
2895
2896         * inspector/InspectorDOMAgent.cpp:
2897         (WebCore::InspectorDOMAgent::handleEvent):
2898         * inspector/InspectorDOMAgent.h:
2899         * inspector/InspectorDOMStorageResource.cpp:
2900         (WebCore::InspectorDOMStorageResource::handleEvent):
2901         * inspector/InspectorDOMStorageResource.h:
2902         * loader/FrameLoader.cpp:
2903         (WebCore::FrameLoader::stopLoading):
2904         (WebCore::FrameLoader::canCachePageContainingThisFrame):
2905         (WebCore::FrameLoader::logCanCacheFrameDecision):
2906         (WebCore::HashChangeEventTask::performTask):
2907         (WebCore::FrameLoader::pageHidden): No more isWindowEvent.
2908
2909         * loader/ImageDocument.cpp:
2910         (WebCore::ImageEventListener::handleEvent):
2911         * loader/appcache/ApplicationCacheGroup.cpp:
2912         (WebCore::CallCacheListenerTask::performTask):
2913         * loader/appcache/ApplicationCacheHost.cpp:
2914         (WebCore::ApplicationCacheHost::notifyDOMApplicationCache):
2915         * loader/appcache/ApplicationCacheHost.h:
2916         * loader/appcache/DOMApplicationCache.cpp:
2917         (WebCore::DOMApplicationCache::eventTargetData):
2918         (WebCore::DOMApplicationCache::ensureEventTargetData):
2919         * loader/appcache/DOMApplicationCache.h:
2920         * loader/appcache/DOMApplicationCache.idl: Switched to the standard
2921         EventTarget API. As a part of this, I switched this class from using a
2922         custom internal event name enumeration to using the standard EventNames.
2923
2924         * notifications/Notification.cpp:
2925         (WebCore::Notification::eventTargetData):
2926         (WebCore::Notification::ensureEventTargetData):
2927         * notifications/Notification.h:
2928         (WebCore::Notification::scriptExecutionContext):
2929         * notifications/Notification.idl: Switched to the standard EventTarget API.
2930
2931         * page/DOMWindow.cpp:
2932         (WebCore::PostMessageTimer::event):
2933         (WebCore::windowsWithUnloadEventListeners):
2934         (WebCore::windowsWithBeforeUnloadEventListeners):
2935         (WebCore::allowsBeforeUnloadListeners):
2936         (WebCore::DOMWindow::dispatchAllPendingBeforeUnloadEvents):
2937         (WebCore::DOMWindow::pendingUnloadEventListeners):
2938         (WebCore::DOMWindow::dispatchAllPendingUnloadEvents): Changed the "pending"
2939         unload / beforeunload listener tracker just to track which windows had
2940         such listeners, instead of actually keeping a copy of the listeners. Now,
2941         this code can use the standard EventTarget API.
2942
2943         (WebCore::DOMWindow::~DOMWindow):
2944         (WebCore::DOMWindow::postMessageTimerFired):
2945         (WebCore::DOMWindow::addEventListener):
2946         (WebCore::DOMWindow::removeEventListener):
2947         (WebCore::DOMWindow::dispatchLoadEvent):
2948         (WebCore::DOMWindow::dispatchEvent):
2949         (WebCore::DOMWindow::removeAllEventListeners):
2950         (WebCore::DOMWindow::captureEvents):
2951         (WebCore::DOMWindow::releaseEvents):
2952         (WebCore::DOMWindow::eventTargetData):
2953         (WebCore::DOMWindow::ensureEventTargetData):
2954         * page/DOMWindow.h:
2955         * page/DOMWindow.idl: Use the standard EventTarget APIs.
2956
2957         * page/EventHandler.cpp:
2958         (WebCore::EventHandler::canMouseDownStartSelect):
2959         (WebCore::EventHandler::canMouseDragExtendSelect):
2960         (WebCore::EventHandler::sendResizeEvent):
2961         (WebCore::EventHandler::sendScrollEvent): Use dispatchEvent directly.
2962
2963         * page/EventSource.cpp:
2964         (WebCore::EventSource::endRequest):
2965         (WebCore::EventSource::didReceiveResponse):
2966         (WebCore::EventSource::parseEventStreamLine):
2967         (WebCore::EventSource::stop):
2968         (WebCore::EventSource::createMessageEvent):
2969         (WebCore::EventSource::eventTargetData):
2970         (WebCore::EventSource::ensureEventTargetData):
2971         * page/EventSource.h:
2972         * page/EventSource.idl: Use the standard EventTarget APIs.
2973
2974         * page/FocusController.cpp:
2975         (WebCore::dispatchEventsOnWindowAndFocusedNode):
2976         (WebCore::FocusController::setFocusedFrame):
2977         * page/Frame.cpp:
2978         (WebCore::Frame::shouldClose):
2979         * page/Frame.h:
2980         * page/Page.cpp:
2981         (WebCore::networkStateChanged):
2982         * page/animation/AnimationController.cpp:
2983         (WebCore::AnimationControllerPrivate::updateStyleIfNeededDispatcherFired):
2984         * rendering/RenderListBox.cpp:
2985         (WebCore::RenderListBox::valueChanged):
2986         * rendering/RenderTextControl.cpp:
2987         (WebCore::RenderTextControl::selectionChanged):
2988         * rendering/RenderTextControlMultiLine.cpp:
2989         (WebCore::RenderTextControlMultiLine::subtreeHasChanged): Use dispatchEvent.
2990
2991         * svg/SVGElement.cpp:
2992         (WebCore::hasLoadListener): Rewritten for new EventTarget API.
2993
2994         * svg/SVGElementInstance.cpp:
2995         (WebCore::dummyEventTargetData):
2996         (WebCore::SVGElementInstance::addEventListener):
2997         (WebCore::SVGElementInstance::removeEventListener):
2998         (WebCore::SVGElementInstance::removeAllEventListeners):
2999         (WebCore::SVGElementInstance::dispatchEvent):
3000         (WebCore::SVGElementInstance::eventTargetData):
3001         (WebCore::SVGElementInstance::ensureEventTargetData): Use the EventTarget API.
3002
3003         * svg/SVGElementInstance.h:
3004         * svg/SVGImageLoader.cpp:
3005         (WebCore::SVGImageLoader::dispatchLoadEvent):
3006         * svg/SVGScriptElement.cpp:
3007         (WebCore::SVGScriptElement::dispatchErrorEvent): Use dispatchEvent directly.
3008
3009         * svg/SVGUseElement.cpp:
3010         (WebCore::SVGUseElement::transferEventListenersToShadowTree): Updated for
3011         new EventTarget API.
3012
3013         * svg/animation/SVGSMILElement.cpp:
3014         (WebCore::ConditionEventListener::handleEvent): No more isWindowEvent.
3015
3016         * websockets/WebSocket.cpp:
3017         (WebCore::ProcessWebSocketEventTask::create):
3018         (WebCore::ProcessWebSocketEventTask::performTask):
3019         (WebCore::ProcessWebSocketEventTask::ProcessWebSocketEventTask):
3020         (WebCore::WebSocket::didConnect):
3021         (WebCore::WebSocket::didReceiveMessage):
3022         (WebCore::WebSocket::didClose):
3023         (WebCore::WebSocket::eventTargetData):
3024         (WebCore::WebSocket::ensureEventTargetData):
3025         * websockets/WebSocket.h:
3026         * websockets/WebSocket.idl:
3027         * workers/AbstractWorker.cpp:
3028         (WebCore::AbstractWorker::eventTargetData):
3029         (WebCore::AbstractWorker::ensureEventTargetData):
3030         * workers/AbstractWorker.h:
3031         * workers/AbstractWorker.idl:
3032         * workers/DedicatedWorkerContext.cpp:
3033         * workers/DedicatedWorkerContext.h:
3034         * workers/DedicatedWorkerContext.idl:
3035         * workers/DefaultSharedWorkerRepository.cpp:
3036         (WebCore::SharedWorkerConnectTask::performTask):
3037         (WebCore::SharedWorkerScriptLoader::load):
3038         (WebCore::SharedWorkerScriptLoader::notifyFinished):
3039         * workers/SharedWorker.idl:
3040         * workers/SharedWorkerContext.cpp:
3041         (WebCore::createConnectEvent):
3042         * workers/SharedWorkerContext.h:
3043         * workers/SharedWorkerContext.idl:
3044         * workers/Worker.cpp:
3045         (WebCore::Worker::notifyFinished):
3046         * workers/Worker.h:
3047         * workers/Worker.idl:
3048         * workers/WorkerContext.cpp:
3049         (WebCore::WorkerContext::eventTargetData):
3050         (WebCore::WorkerContext::ensureEventTargetData):
3051         * workers/WorkerContext.h:
3052         * workers/WorkerContext.idl:
3053         * workers/WorkerMessagingProxy.cpp:
3054         (WebCore::MessageWorkerContextTask::performTask):
3055         (WebCore::MessageWorkerTask::performTask):
3056         (WebCore::WorkerExceptionTask::performTask):
3057         * xml/XMLHttpRequest.cpp:
3058         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
3059         (WebCore::XMLHttpRequest::createRequest):
3060         (WebCore::XMLHttpRequest::abort):
3061         (WebCore::XMLHttpRequest::networkError):
3062         (WebCore::XMLHttpRequest::abortError):
3063         (WebCore::XMLHttpRequest::didSendData):
3064         (WebCore::XMLHttpRequest::didReceiveData):
3065         (WebCore::XMLHttpRequest::eventTargetData):
3066         (WebCore::XMLHttpRequest::ensureEventTargetData):
3067         * xml/XMLHttpRequest.h:
3068         * xml/XMLHttpRequest.idl:
3069         * xml/XMLHttpRequestProgressEvent.h:
3070         (WebCore::XMLHttpRequestProgressEvent::create):
3071         * xml/XMLHttpRequestUpload.cpp:
3072         (WebCore::XMLHttpRequestUpload::eventTargetData):
3073         (WebCore::XMLHttpRequestUpload::ensureEventTargetData):
3074         * xml/XMLHttpRequestUpload.h:
3075         * xml/XMLHttpRequestUpload.idl: Use new EventTarget API.
3076
3077 2009-09-23  Kent Tamura  <tkent@chromium.org>
3078
3079         Reviewed by Darin Adler.
3080
3081         - Support for maxLength of <textarea>
3082         - Move numGraphemeClusters() and numCharactersInGraphemeClusters() from InputElement to String.
3083         https://bugs.webkit.org/show_bug.cgi?id=29292
3084
3085         Test: fast/forms/textarea-maxlength.html
3086
3087         * dom/InputElement.cpp:
3088         (WebCore::InputElement::sanitizeUserInputValue):
3089         (WebCore::InputElement::handleBeforeTextInsertedEvent):
3090         * html/HTMLTextAreaElement.cpp:
3091         (WebCore::HTMLTextAreaElement::defaultEventHandler):
3092         (WebCore::HTMLTextAreaElement::handleBeforeTextInsertedEvent):
3093         (WebCore::HTMLTextAreaElement::sanitizeUserInputValue):
3094         (WebCore::HTMLTextAreaElement::maxLength):
3095         (WebCore::HTMLTextAreaElement::setMaxLength):
3096         * html/HTMLTextAreaElement.h:
3097         * html/HTMLTextAreaElement.idl:
3098         * platform/text/PlatformString.h:
3099         * platform/text/String.cpp:
3100         (WebCore::String::numGraphemeClusters):
3101         (WebCore::String::numCharactersInGraphemeClusters):
3102
3103 2009-09-23  Martin Robinson  <martin.james.robinson@gmail.com>
3104
3105         Reviewed by Xan Lopez.
3106
3107         [GTK] REGRESSION: BitmapImage::getGdkPixbuf fails for non-square images
3108         https://bugs.webkit.org/show_bug.cgi?id=29654
3109
3110         Give GDK_Backspace key events the proper text properties.
3111
3112         Instead of adding new tests, this change removes existing tests
3113         from Gtk's skipped list.
3114
3115         * platform/gtk/KeyEventGtk.cpp:
3116         (WebCore::keyIdentifierForGdkKeyCode):
3117         (WebCore::singleCharacterString):
3118
3119 2009-09-23  Sam Weinig  <sam@webkit.org>
3120
3121         Reviewed by Adam Barth.
3122
3123         Fix for https://bugs.webkit.org/show_bug.cgi?id=26989
3124         Should allow navigation of top-level openers
3125         <rdar://problem/7034025>
3126
3127         Allow navigation of cross-origin window.opener if it is top-level frame.
3128
3129         Test: http/tests/security/frameNavigation/cross-origin-opener.html
3130
3131         * loader/FrameLoader.cpp:
3132         (WebCore::FrameLoader::shouldAllowNavigation):
3133
3134 2009-09-23  Marshall Culpepper  <mculpepper@appcelerator.com>
3135
3136         Reviewed by Eric Seidel.
3137
3138         Added $(WebKitLibrariesDir)/include/cairo so cairo.h is found by
3139         default when the necessary dependencies are extracted into the
3140         WebKitLibrariesDir.
3141         https://bugs.webkit.org/show_bug.cgi?id=29661
3142
3143         * WebCore.vcproj/WebCoreCairo.vsprops:
3144
3145 2009-09-23  Darin Adler  <darin@apple.com>
3146
3147         Reviewed by Sam Weinig.
3148
3149         Crash when website does a history.back() followed by an alert()
3150         https://bugs.webkit.org/show_bug.cgi?id=29686
3151         rdar://problem/6984996
3152
3153         When loading is deferred, we need to defer timer-based loads
3154         too, not just networking-driven loads. Otherwise we can get
3155         syncronouse navigation while running a script, which leads to
3156         crashes and other badness.
3157
3158         This patch includes a manual test; an automated test may be
3159         possible some time in the future.
3160
3161         * dom/Document.cpp:
3162         (WebCore::Document::processHttpEquiv): Use scheduleLocationChange
3163         instead of scheduleHTTPRedirection to implement the navigation
3164         needed for x-frame-options.
3165
3166         * loader/FrameLoader.cpp:
3167         (WebCore::FrameLoader::FrameLoader): Updated for data members with
3168         new names and new data members.
3169         (WebCore::FrameLoader::setDefersLoading): When turning deferral
3170         off, call startRedirectionTimer and startCheckCompleteTimer, since
3171         either of them might have been fired and ignored while defersLoading
3172         was true.
3173         (WebCore::FrameLoader::clear): Updated for replacement of the
3174         m_checkCompletedTimer and m_checkLoadCompleteTimer timers.
3175         (WebCore::FrameLoader::allAncestorsAreComplete): Added.
3176         (WebCore::FrameLoader::checkCompleted): Added code to set
3177         m_shouldCallCheckCompleted to false. Changed code that calls
3178         startRedirectionTimer to call it unconditionally, since that
3179         function now knows when to do work and doesn't expect callers
3180         to handle that any more.
3181         (WebCore::FrameLoader::checkTimerFired): Added. Replaces the old
3182         timer fired callbacks. Calls checkCompleted and checkLoadComplete
3183         as appropriate, but not when defersLoading is true.
3184         (WebCore::FrameLoader::startCheckCompleteTimer): Added. Replaces
3185         the two different calls to start timers before. Only starts the
3186         timers if they are needed.
3187         (WebCore::FrameLoader::scheduleCheckCompleted): Changed to call
3188         startCheckCompleteTimer after setting boolean.
3189         (WebCore::FrameLoader::scheduleCheckLoadComplete): Ditto.
3190         (WebCore::FrameLoader::scheduleHistoryNavigation): Removed
3191         canGoBackOrForward check. The logic works more naturally when
3192         we don't do anything until the timer fires.
3193         (WebCore::FrameLoader::redirectionTimerFired): Do nothing if
3194         defersLoading is true. Also moved canGoBackOrForward check here.
3195         (WebCore::FrameLoader::scheduleRedirection): Changed code that
3196         calls startRedirectionTimer to do so unconditionally. That
3197         function now handles the rules about when to start the timer
3198         rather than expecting the caller to do so.
3199         (WebCore::FrameLoader::startRedirectionTimer): Added code to
3200         handle the case where there is no redirection scheduled,
3201         where the timer is already active, or where this is a classic
3202         redirection and there is an ancestor that has not yet completed
3203         loading.
3204         (WebCore::FrameLoader::completed): Call startRedirectionTimer
3205         here directly instead of calling a cover named parentCompleted.
3206         Hooray! One less function in the giant FrameLoader class!
3207         (WebCore::FrameLoader::checkLoadComplete): Added code to set
3208         m_shouldCallCheckLoadComplete to false.
3209
3210         * loader/FrameLoader.h: Replaced the two functions
3211         checkCompletedTimerFired and checkLoadCompleteTimerFired with
3212         one function, checkTimerFired. Removed the parentCompleted
3213         function. Added the startCheckCompleteTimer and
3214         allAncestorsAreComplete functions. Replaced the
3215         m_checkCompletedTimer and m_checkLoadCompleteTimer data
3216         members with m_checkTimer, m_shouldCallCheckCompleted, and
3217         m_shouldCallCheckLoadComplete.
3218
3219         * manual-tests/go-back-after-alert.html: Added.
3220         * manual-tests/resources/alert-and-go-back.html: Added.
3221
3222 2009-09-23  David Kilzer  <ddkilzer@apple.com>
3223
3224         <http://webkit.org/b/29660> Move "Generate 64-bit Export File" build phase script into DerivedSources.make
3225
3226         Reviewed by Mark Rowe.
3227
3228         The "Generate 64-bit Export File" build phase script generated
3229         the WebCore.LP64.exp export file used to link 64-bit WebCore.
3230         Instead of having a separate build phase script, move its
3231         generation into DerivedSources.make where WebCore.exp is
3232         generated.
3233
3234         * DerivedSources.make: Added a rule to make WebCore.LP64.exp.
3235         Added code to append WebCore.PluginHostProcess.exp to
3236         $(WEBCORE_EXPORT_DEPENDENCIES) when WTF_USE_PLUGIN_HOST_PROCESS
3237         is set to 1.
3238         * WebCore.PluginHostProcess.exp: Renamed from WebCore/WebCore.LP64.exp.
3239         * WebCore.xcodeproj/project.pbxproj: Removed the "Generate
3240         64-bit Export File" build phase script. Renamed WebCore.LP64.exp
3241         to WebCore.PluginHostProcess.exp.
3242
3243 2009-09-23  Peter Kasting  <pkasting@google.com>
3244
3245         Reviewed by Dimitri Glazkov.
3246
3247         https://bugs.webkit.org/show_bug.cgi?id=29694
3248         [Chromium] Eliminate dependency on gfx::Rect from ImageSkia.
3249
3250         * platform/graphics/skia/ImageSkia.cpp:
3251         (WebCore::drawResampledBitmap):
3252
3253 2009-09-22  Timothy Hatcher  <timothy@apple.com>
3254
3255         Prevent scrolling multiple elements during latched wheel events.
3256
3257         Reviewed by Anders Carlsson.
3258
3259         * page/EventHandler.cpp:
3260         (WebCore::scrollAndAcceptEvent):
3261         (WebCore::EventHandler::clear):
3262         (WebCore::EventHandler::handleWheelEvent):
3263         * page/EventHandler.h:
3264         * rendering/RenderBox.cpp:
3265         (WebCore::RenderBox::scroll):
3266         * rendering/RenderBox.h:
3267
3268 2009-09-23  Daniel Bates  <dbates@webkit.org>
3269
3270         Reviewed by Adam Barth.
3271
3272         https://bugs.webkit.org/show_bug.cgi?id=29523
3273         
3274         Fixes an issue where a JavaScript URL that was URL-encoded twice can bypass the
3275         XSSAuditor.
3276         
3277         The method FrameLoader::executeIfJavaScriptURL decodes the URL escape 
3278         sequences in a JavaScript URL before it is eventually passed to the XSSAuditor.
3279         Because the XSSAuditor also decodes the URL escape sequences as part of its
3280         canonicalization, the double decoding of a JavaScript URL would
3281         not match the canonicalization of the input parameters.
3282
3283         Tests: http/tests/security/xssAuditor/iframe-javascript-url-url-encoded.html
3284                http/tests/security/xssAuditor/javascript-link-url-encoded.html
3285
3286         * bindings/js/ScriptController.cpp:
3287         (WebCore::ScriptController::evaluate): Moved call to 
3288         XSSAuditor::canEvaluateJavaScriptURL into FrameLoader::executeIfJavaScriptURL.
3289         * bindings/v8/ScriptController.cpp:
3290         (WebCore::ScriptController::evaluate): Ditto.
3291         * loader/FrameLoader.cpp:
3292         (WebCore::FrameLoader::executeIfJavaScriptURL): Modified to call 
3293         XSSAuditor::canEvaluateJavaScriptURL on the JavaScript URL before it is
3294         decoded.
3295
3296 2009-09-22  Dave Hyatt  <hyatt@apple.com>
3297
3298         Reviewed by John Sullivan.
3299
3300         https://bugs.webkit.org/show_bug.cgi?id=29657
3301         Columns don't break properly in positioned elements with a fixed height.  Make sure that
3302         a block is still considered to have columns even when the column count is 1 if the column
3303         width is non-auto.
3304     
3305         Added fast/multicol/positioned-with-constrained-height.html
3306
3307         * rendering/RenderBlock.cpp:
3308         (WebCore::RenderBlock::setDesiredColumnCountAndWidth):
3309
3310 2009-09-23  Holger Hans Peter Freyther  <zecke@selfish.org>
3311
3312         Rubber-stamped by Simon Hausmann.
3313
3314         Add a null check for the Document*. In the mirror benchmarking
3315         application a crash from a call from JavaScript was observed.
3316
3317         I was not able to come up with a test case for this issue.
3318
3319         * platform/qt/CookieJarQt.cpp:
3320         (WebCore::cookieJar):
3321
3322 2009-09-23  Simon Hausmann  <simon.hausmann@nokia.com>
3323
3324         Reviewed by Tor Arne Vestbø.
3325
3326         Fix the Qt/Windows build, after the introduction of
3327         the page client.
3328
3329         * plugins/win/PluginViewWin.cpp:
3330         (windowHandleForPageClient):
3331         (WebCore::PluginView::getValue):
3332         (WebCore::PluginView::forceRedraw):
3333         (WebCore::PluginView::platformStart):
3334
3335 2009-09-23  Gustavo Noronha Silva  <gns@gnome.org>
3336
3337         Reviewed by Xan Lopez.
3338
3339         [GTK] media tests failing after their rework
3340         https://bugs.webkit.org/show_bug.cgi?id=29532
3341
3342         Correctly advertise the mime types used by the common formats used
3343         in the tests.
3344
3345         Tests that regressed, and will pass again:
3346
3347            media/video-canvas-source.html
3348            media/video-controls.html
3349            media/video-currentTime-set2.html
3350            media/video-dom-autoplay.html
3351            media/video-dom-src.html
3352            media/video-error-abort.html
3353            media/video-load-networkState.html
3354            media/video-load-readyState.html
3355            media/video-muted.html
3356            media/video-no-autoplay.html
3357            media/video-pause-empty-events.html
3358            media/video-play-empty-events.html
3359            media/video-seekable.html
3360            media/video-seeking.html
3361            media/video-size.html
3362            media/video-source-type-params.html
3363            media/video-source-type.html
3364            media/video-source.html
3365            media/video-src-change.html
3366            media/video-src-invalid-remove.html
3367            media/video-src-remove.html
3368            media/video-src-set.html
3369            media/video-src-source.html
3370            media/video-src.html
3371            media/video-timeupdate-during-playback.html
3372            media/video-volume.html
3373
3374         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
3375         (WebCore::mimeTypeCache):
3376
3377 2009-09-22  Charles Wei  <charles.wei@torchmobile.com.cn>
3378
3379         Reviewed by Eric Seidel.
3380
3381         Fix the crash problem with absolte positioned children in foreignobject
3382         htts://bugs.webkit.org/show_bug.cgi?id=26342
3383
3384         Test: svg/custom/foreignobject-crash-with-absolute-positioned-children.svg
3385
3386         * rendering/RenderForeignObject.h:
3387         (WebCore::RenderForeignObject::isSVGForeignObject):
3388         * rendering/RenderObject.cpp:
3389         (WebCore::RenderObject::containingBlock):
3390         * rendering/RenderObject.h:
3391         (WebCore::RenderObject::isSVGForeignObject):
3392
3393 2009-09-22  Drew Wilson  <atwilson@google.com>
3394
3395         Reviewed by David Levin.
3396
3397         SharedWorkers "name" attribute is now optional.
3398         https://bugs.webkit.org/show_bug.cgi?id=28897
3399
3400         Test: fast/workers/shared-worker-name.html
3401
3402         * bindings/js/JSSharedWorkerConstructor.cpp:
3403         (WebCore::constructSharedWorker):
3404         Default 'name' attribute to empty string if it is not provided.
3405         * bindings/v8/custom/V8SharedWorkerCustom.cpp:
3406         (WebCore::CALLBACK_FUNC_DECL):
3407         Default 'name' attribute to empty string if it is not provided.
3408         * workers/DefaultSharedWorkerRepository.cpp:
3409         (WebCore::SharedWorkerProxy::matches):
3410         Now matches URLs if names are empty strings.
3411         (WebCore::DefaultSharedWorkerRepository::getProxy):
3412         Pass URL in to SharedWorkerProxy::matches().
3413
3414 2009-09-22  Dimitri Glazkov  <dglazkov@chromium.org>
3415
3416         Unreviewed, another build fix.
3417
3418         [Chromium] Add another missing include.
3419         https://bugs.webkit.org/show_bug.cgi?id=29536
3420
3421         * inspector/InspectorController.cpp: Added DOMWindow.h include.
3422
3423 2009-09-22  Dimitri Glazkov  <dglazkov@chromium.org>
3424
3425         Unreviewed, build fix.
3426
3427         [Chromium] Add missing include.
3428         https://bugs.webkit.org/show_bug.cgi?id=29536
3429
3430         * inspector/InspectorDOMStorageResource.cpp: Added DOMWindow.h include.
3431
3432 2009-09-22  Darin Adler  <darin@apple.com>
3433
3434         Reviewed by Sam Weinig.
3435
3436         Tighten up the ScheduledRedirection machinery to prepare for a bug fix
3437         https://bugs.webkit.org/show_bug.cgi?id=29663
3438
3439         * loader/FrameLoader.cpp:
3440         (WebCore::ScheduledRedirection::ScheduledRedirection): Added a boolean,
3441         initialized to false, to keep track if the redirection has been
3442         communicated to the client.
3443         (WebCore::FrameLoader::stopLoading): Tweaked a comment.
3444         (WebCore::FrameLoader::cancelRedirection): Removed code to clear
3445         m_scheduledRedirection.clear since stopRedirectionTimer does that now.
3446         (WebCore::FrameLoader::allChildrenAreComplete): Added.
3447         (WebCore::FrameLoader::checkCompleted): Use allChildrenAreComplete
3448         function for clarity.
3449         (WebCore::FrameLoader::checkCallImplicitClose): Ditto.
3450         (WebCore::FrameLoader::scheduleRedirection): Changed to take a PassOwnPtr.
3451         (WebCore::FrameLoader::startRedirectionTimer): Added code to set the
3452         toldClient flag and not call clientRedirected a second time if it is set.
3453         (WebCore::FrameLoader::stopRedirectionTimer): Changed so this can be safely
3454         called multiple times and it will call clientRedirectCancelledOrFinished
3455         only once.
3456
3457         * loader/FrameLoader.h: Changed scheduleRedirection to be a PassOwnPtr.
3458         Added allChildrenAreComplete function.
3459
3460 2009-09-22  Yury Semikhatsky  <yurys@chromium.org>
3461
3462         Reviewed by Timothy Hatcher.
3463
3464         WebInspector: Migrate Databases tab to InjectedScript /
3465         serialized interaction.
3466
3467         DOMStorage interaction is now serialized into JSON messages
3468         and doesn't require quarantined objects.
3469         
3470         https://bugs.webkit.org/show_bug.cgi?id=28873
3471
3472         * dom/EventListener.h:
3473         (WebCore::EventListener::):
3474         * inspector/InspectorBackend.cpp:
3475         (WebCore::InspectorBackend::selectDOMStorage):
3476         (WebCore::InspectorBackend::getDOMStorageEntries):
3477         (WebCore::InspectorBackend::setDOMStorageItem):
3478         (WebCore::InspectorBackend::removeDOMStorageItem):
3479         * inspector/InspectorBackend.h:
3480         * inspector/InspectorBackend.idl:
3481         * inspector/InspectorController.cpp:
3482         (WebCore::InspectorController::didCommitLoad):
3483         (WebCore::InspectorController::selectDOMStorage):
3484         (WebCore::InspectorController::getDOMStorageEntries):
3485         (WebCore::InspectorController::setDOMStorageItem):
3486         (WebCore::InspectorController::removeDOMStorageItem):
3487         (WebCore::InspectorController::getDOMStorageResourceForId):
3488         * inspector/InspectorController.h:
3489         * inspector/InspectorDOMStorageResource.cpp:
3490         (WebCore::InspectorDOMStorageResource::InspectorDOMStorageResource):
3491         (WebCore::InspectorDOMStorageResource::bind):
3492         (WebCore::InspectorDOMStorageResource::unbind):
3493         (WebCore::InspectorDOMStorageResource::startReportingChangesToFrontend):
3494         (WebCore::InspectorDOMStorageResource::handleEvent):
3495         (WebCore::InspectorDOMStorageResource::operator==):
3496         * inspector/InspectorDOMStorageResource.h:
3497         (WebCore::InspectorDOMStorageResource::cast):
3498         (WebCore::InspectorDOMStorageResource::id):
3499         (WebCore::InspectorDOMStorageResource::domStorage):
3500         * inspector/InspectorFrontend.cpp:
3501         (WebCore::InspectorFrontend::selectDOMStorage):
3502         (WebCore::InspectorFrontend::didGetDOMStorageEntries):
3503         (WebCore::InspectorFrontend::didSetDOMStorageItem):
3504         (WebCore::InspectorFrontend::didRemoveDOMStorageItem):
3505         (WebCore::InspectorFrontend::updateDOMStorage):
3506         * inspector/InspectorFrontend.h:
3507         * inspector/front-end/DOMStorage.js:
3508         (WebInspector.DOMStorage):
3509         (WebInspector.DOMStorage.prototype.get id):
3510         (WebInspector.DOMStorage.prototype.get domStorage):
3511         (WebInspector.DOMStorage.prototype.get isLocalStorage):
3512         (WebInspector.DOMStorage.prototype.getEntriesAsync):
3513         (WebInspector.DOMStorage.prototype.setItemAsync):
3514         (WebInspector.DOMStorage.prototype.removeItemAsync):
3515         * inspector/front-end/DOMStorageDataGrid.js:
3516         (WebInspector.DOMStorageDataGrid):
3517         (WebInspector.DOMStorageDataGrid.prototype._startEditingColumnOfDataGridNode):
3518         (WebInspector.DOMStorageDataGrid.prototype._startEditing):
3519         (WebInspector.DOMStorageDataGrid.prototype._editingCommitted):
3520         (WebInspector.DOMStorageDataGrid.prototype._editingCancelled):
3521         (WebInspector.DOMStorageDataGrid.prototype.deleteSelectedRow):
3522         * inspector/front-end/DOMStorageItemsView.js:
3523         (WebInspector.DOMStorageItemsView.prototype.update):
3524         (WebInspector.DOMStorageItemsView.prototype._showDOMStorageEntries):
3525         (WebInspector.DOMStorageItemsView.prototype._dataGridForDOMStorageEntries):
3526         * inspector/front-end/StoragePanel.js:
3527         (WebInspector.StoragePanel.prototype.show):
3528         (WebInspector.StoragePanel.prototype.reset):
3529         (WebInspector.StoragePanel.prototype.selectDOMStorage):
3530         (WebInspector.StoragePanel.prototype.updateDOMStorage):
3531         (WebInspector.StoragePanel.prototype._domStorageForId):
3532         * inspector/front-end/inspector.js:
3533         (WebInspector.addDOMStorage):
3534         (WebInspector.updateDOMStorage):
3535
3536 2009-09-22  Sam Weinig  <sam@webkit.org>
3537
3538         Reviewed by Alexey Proskuryakov.
3539
3540         Fix for XMLHttpRequest.abort() should destroy the response text.
3541         https://bugs.webkit.org/show_bug.cgi?id=29658
3542         <rdar://problem/5301430>
3543
3544         Clearing the response text after calling XMLHttpRequest.abort() is necessary
3545         per spec and matches Firefox. It is also a potential memory win.
3546
3547         Test: http/tests/xmlhttprequest/abort-should-destroy-responseText.html
3548
3549         * xml/XMLHttpRequest.cpp:
3550         (WebCore::XMLHttpRequest::abort): Clear the response text making sure to
3551         keep the actual ResourceReponse around so that the response status and response
3552         status text are kept around.
3553
3554 2009-09-22  Dimitri Glazkov  <dglazkov@chromium.org>
3555
3556         No review, rolling out r48639.
3557         http://trac.webkit.org/changeset/48639
3558
3559         * bindings/v8/V8GCController.cpp:
3560         (WebCore::ObjectGrouperVisitor::visitDOMWrapper):
3561
3562 2009-09-22  Dumitru Daniliuc  <dumi@chromium.org>
3563
3564         Reviewed by Dimitri Glazkov.
3565
3566         Changing the transaction coordinator to (re-)allow multiple read
3567         transactions on the same database to run concurrently (without
3568         risking a deadlock this time).
3569
3570         https://bugs.webkit.org/show_bug.cgi?id=29115
3571
3572         Tests: storage/read-and-write-transactions-dont-run-together.html
3573                storage/read-transactions-running-concurrently.html
3574
3575         * storage/SQLTransaction.h:
3576         (WebCore::SQLTransaction::isReadOnly): Returns the type of the
3577         transaction.
3578         * storage/SQLTransactionCoordinator.cpp:
3579         (WebCore::SQLTransactionCoordinator::acquireLock): Changed to
3580         allow multiple read transactions on the same DB to run
3581         concurrently.
3582         (WebCore::SQLTransactionCoordinator::releaseLock): Changed to
3583         allow multiple read transactions on the same DB to run
3584         concurrently.
3585         (WebCore::SQLTransactionCoordinator::shutdown): Renamed the map.
3586         * storage/SQLTransactionCoordinator.h:
3587
3588 2009-09-22  Peter Kasting  <pkasting@google.com>
3589
3590         Reviewed by David Levin.
3591
3592         https://bugs.webkit.org/show_bug.cgi?id=29652
3593         Support true system colors for CSS system colors in Chromium/Win.
3594
3595         * rendering/RenderThemeChromiumWin.cpp:
3596         (WebCore::cssValueIdToSysColorIndex):
3597         (WebCore::RenderThemeChromiumWin::systemColor):
3598         * rendering/RenderThemeChromiumWin.h:
3599
3600 2009-09-22  Beth Dakin  <bdakin@apple.com>
3601
3602         Reviewed by Dave Hyatt.
3603
3604         Fix for <rdar://problem/6925121> SAP: Wrong width calculation in 
3605         table with fixed layout
3606         -and corresponding-
3607         https://bugs.webkit.org/show_bug.cgi?id=29501
3608
3609         New Tests:
3610         * fast/table/fixed-table-with-percent-inside-percent-table.html: Added.
3611         * fast/table/fixed-table-with-percent-width-inside-auto-table.html: Added.
3612         * fast/table/fixed-table-with-percent-width-inside-div.html: Added.
3613         * fast/table/fixed-table-with-percent-width-inside-extra-large-div.html: Added.
3614         * fast/table/fixed-table-with-percent-width-inside-fixed-width-table.html: Added.
3615         * fast/table/fixed-table-with-small-percent-width.html: Added.
3616
3617         This new quirk is very similar to an existing one that was 
3618         implemented in revision 4316.
3619         * rendering/FixedTableLayout.cpp:
3620         (WebCore::FixedTableLayout::calcPrefWidths):
3621
3622 2009-09-22  Brian Weinstein  <bweinstein@apple.com>
3623
3624         Reviewed by Timothy Hatcher.
3625
3626         List HTTP status code with response headers in resources tab of Web Inspector.
3627         http://webkit.org/b/19945
3628
3629         This patch adds a new top level list in the resources tab, HTTP Information, that 
3630         for now, contains the Request Method (GET, POST, etc.) and the Status Code (200, 404, etc.).
3631         Additionally, it adds a colored dot next to the requested URL to show the status 
3632         (green for success, orange for redirect, red for error).
3633
3634         * English.lproj/localizedStrings.js:
3635         * inspector/front-end/ImageView.js:
3636         (WebInspector.ImageView):
3637         * inspector/front-end/Images/errorRedDot.png: Added.
3638         * inspector/front-end/Images/successGreenDot.png: Added.
3639         * inspector/front-end/Images/warningOrangeDot.png: Added.
3640         * inspector/front-end/Resource.js:
3641         (WebInspector.Resource.StatusTextForCode):
3642         * inspector/front-end/ResourceView.js:
3643         (WebInspector.ResourceView):
3644         (WebInspector.ResourceView.prototype._refreshURL):
3645         (WebInspector.ResourceView.prototype._refreshHTTPInformation):