e8d96e4a8ec22520708c443585dd32d06abfdee0
[WebKit-https.git] / WebCore / ChangeLog
1 2009-04-13  Jian Li  <jianli@chromium.org>
2
3         Reviewed by Darin Fisher.
4
5         https://bugs.webkit.org/show_bug.cgi?id=25121
6         Upstream changes to handle error messages from V8 when running worker script.
7
8         * bindings/v8/WorkerContextExecutionProxy.cpp:
9         (WebCore::reportFatalErrorInV8):
10         (WebCore::handleConsoleMessage):
11         (WebCore::WorkerContextExecutionProxy::WorkerContextExecutionProxy):
12         (WebCore::WorkerContextExecutionProxy::dispose):
13         (WebCore::WorkerContextExecutionProxy::initV8IfNeeded):
14         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
15         (WebCore::WorkerContextExecutionProxy::evaluate):
16         * bindings/v8/WorkerContextExecutionProxy.h:
17
18 2009-04-13  Geoffrey Garen  <ggaren@apple.com>
19
20         Build fix: Made setInlineEventListenerForType not inline, since Document
21         calls it now. Made RegisteredEventListener.h a private header on Mac,
22         so WebKit can use it.
23
24         * page/DOMWindow.cpp:
25         (WebCore::DOMWindow::setInlineEventListenerForType):
26
27 2009-04-13  Dan Bernstein  <mitz@apple.com>
28
29         Reviewed by Sam Weinig.
30
31         - fix <rdar://problem/6404439> REGRESSION: Overlapping text and other
32           layout issues in View Sample feature of MYOB FIrstEdge v3
33
34         * page/Navigator.cpp:
35         (WebCore::shouldHideFourDot): Added "tdqm_loader.js" to the list of
36         JavaScript files this quirk applies to.
37
38 2009-04-13  Sam Weinig  <sam@webkit.org>
39
40         Reviewed by Oliver Hunt.
41
42         Move open and showModalDialog functions out of JSDOMWindowBase
43         and into JSDOMWindow by partially generating them.
44
45         This slightly changes the behavior of getting window.showModalDialog
46         when the embedding app does not support it to return undefined regardless
47         of shadowing.  This should not be an issue in a practice, but will be addressed
48         when we add a generic way to handle runtime specialization of property
49         access.
50
51         * DerivedSources.make: Remove JSDOMWindowBase.lut.h
52         * WebCore.xcodeproj/project.pbxproj: Ditto.
53         * bindings/js/JSDOMWindowBase.cpp:
54         (WebCore::):
55         (WebCore::JSDOMWindowBase::getOwnPropertySlot): Move canShowModalDialog check from
56         here to JSDOMWindow::customGetOwnPropertySlot.
57         (WebCore::JSDOMWindowBase::put): Remove dead code.
58         * bindings/js/JSDOMWindowCustom.cpp:
59         (WebCore::createWindow):
60         (WebCore::JSDOMWindow::open):
61         (WebCore::JSDOMWindow::showModalDialog):
62         * bindings/js/JSDOMWindowCustom.h:
63         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
64         * page/DOMWindow.cpp:
65         (WebCore::DOMWindow::parseModalDialogFeatures): Move from JSDOMWindowBase.
66         (WebCore::DOMWindow::allowPopUp): Ditto.
67         (WebCore::DOMWindow::canShowModalDialog): Ditto.
68         (WebCore::DOMWindow::canShowModalDialogNow): Ditto.
69         * page/DOMWindow.h:
70         * page/DOMWindow.idl:
71
72 2009-04-13  Geoffrey Garen  <ggaren@apple.com>
73
74         Reviewed by Sam Weinig.
75
76         Moved storage for window event listeners into the window object.
77
78         * bindings/js/JSDOMWindowCustom.cpp:
79         (WebCore::JSDOMWindow::addEventListener):
80         (WebCore::JSDOMWindow::removeEventListener): Add / remove window event
81         listeners to / from the window object.
82
83         * dom/Document.cpp:
84         (WebCore::Document::removeAllEventListeners):
85         (WebCore::Document::clear):
86         (WebCore::Document::setWindowInlineEventListenerForTypeAndAttribute): Moved
87         a bunch of code to the DOMWindow class, and left behind a few calls through
88         to DOMWindow, to support legacy clients. (Eventually, these will go away, too.)
89
90         * dom/Document.h: ditto.
91
92         * dom/Node.cpp:
93         (WebCore::Node::dispatchGenericEvent):
94         (WebCore::Node::dispatchWindowEvent): Dipatch window events on the window
95         object, not the document.
96
97         * dom/Node.h:
98         * dom/RegisteredEventListener.h: Moved RegisteredEventListenerVector
99         declaration, since it's required in more places now.
100
101         * history/CachedFrame.cpp:
102         (WebCore::CachedFrame::clear): Updated for rename. Also, remove event
103         listeners before detaching and clearing the document's window pointer,
104         since the the document needs its window pointer in order to tell the window
105         to clear its event listeners.
106
107         * loader/FrameLoader.cpp:
108         (WebCore::FrameLoader::stopLoading):
109         (WebCore::FrameLoader::canCachePageContainingThisFrame):
110         (WebCore::FrameLoader::logCanCacheFrameDecision): Updated for rename, and
111         movement of window event listeners into the window.
112
113         * loader/ImageDocument.cpp:
114         (WebCore::ImageDocument::createDocumentStructure): Updated for movement
115         of window event listeners into the window.
116
117         * page/DOMWindow.cpp:
118         (WebCore::DOMWindow::handleEvent):
119         (WebCore::DOMWindow::addEventListener):
120         (WebCore::DOMWindow::removeEventListener):
121         (WebCore::DOMWindow::removeAllEventListeners):
122         (WebCore::DOMWindow::hasEventListener):
123         (WebCore::DOMWindow::setInlineEventListenerForType):
124         (WebCore::DOMWindow::removeInlineEventListenerForType):
125         (WebCore::DOMWindow::inlineEventListenerForType):
126         (WebCore::DOMWindow::addPendingFrameUnloadEventCount):
127         (WebCore::DOMWindow::removePendingFrameUnloadEventCount):
128         (WebCore::DOMWindow::addPendingFrameBeforeUnloadEventCount):
129         (WebCore::DOMWindow::removePendingFrameBeforeUnloadEventCount):
130         * page/DOMWindow.h: Moved a bunch of code to the DOMWindow class, from the Document.
131
132         * page/Frame.cpp:
133         (WebCore::Frame::shouldClose): Updated for movement of window event listeners into the window.
134
135 2009-04-13  Greg Bolsinga  <bolsinga@apple.com>
136
137         Reviewed by Sam Weinig.
138
139         https://bugs.webkit.org/show_bug.cgi?id=25149
140
141         The Geolocation timer needs to start after the UA has granted permission.
142
143         * bindings/js/JSGeolocationCustom.cpp: Use PassRefPtr<PositionOptions>
144         (WebCore::JSGeolocation::getCurrentPosition):
145         (WebCore::JSGeolocation::watchPosition):
146         * page/Geolocation.cpp: Add a RefPtr<PositionOptions> so it can be used
147         later when the timer is started. Change PositionOptions* to PassRefPtr<PositionOptions>
148         where needed.
149         (WebCore::Geolocation::GeoNotifier::GeoNotifier):
150         (WebCore::Geolocation::GeoNotifier::startTimer):
151         (WebCore::Geolocation::getCurrentPosition):
152         (WebCore::Geolocation::watchPosition):
153         (WebCore::Geolocation::setIsAllowed): Start the timer is the UA allows
154         (WebCore::Geolocation::startTimer):
155         (WebCore::Geolocation::startTimersForOneShots):
156         (WebCore::Geolocation::startTimersForWatchers):
157         (WebCore::Geolocation::startTimers):
158         * page/Geolocation.h:
159         (WebCore::Geolocation::GeoNotifier::create):
160
161 2009-04-13  Pamela Greene  <pam@chromium.org>
162
163         Reviewed by Darin Fisher.
164
165         Fix Chromium (V8) build by renaming methods to match changes
166         in http://trac.webkit.org/changeset/42377.
167
168         https://bugs.webkit.org/show_bug.cgi?id=25141
169
170         * bindings/v8/ScheduledAction.cpp:
171      (WebCore::ScheduledAction::execute): updateRendering() -> updateStyleIfNeeded()
172         * bindings/v8/V8AbstractEventListener.cpp:
173         (WebCore::V8AbstractEventListener::handleEvent): updateDocumentsRendering() -> updateStyleForAllDocuments()
174
175 2009-04-13  Darin Fisher  <darin@chromium.org>
176
177         Reviewed by Darin Adler.
178
179         https://bugs.webkit.org/show_bug.cgi?id=25136
180         CRASH in DocumentLoader::removeSubresourceLoader due to null m_frame
181
182         Test: fast/frames/frame-unload-crash.html
183
184         * loader/DocumentLoader.cpp:
185         (WebCore::DocumentLoader::updateLoading): Added null check of m_frame.
186
187 2009-04-13  Sam Weinig  <sam@webkit.org>
188
189         Reviewed by Tim Hatcher.
190
191         Put the MessagePort constructor back in ENABLE_CHANNEL_MESSAGING.
192
193         * page/DOMWindow.idl:
194
195 2009-04-13  Greg Bolsinga  <bolsinga@apple.com>
196
197         Fix GTK build break.
198
199         * platform/gtk/GeolocationServiceGtk.cpp:
200         (WebCore::GeolocationServiceGtk::updatePosition):
201
202 2009-04-13  David Hyatt  <hyatt@apple.com>
203
204         Reviewed by Darin Adler and Dan Bernstein.
205
206         Assertion in updateStyleForAllDocuments.  Make sure to unscheduleStyleRecalc when an object goes into
207         the page cache.  Disallow scheduling of style recalcs on a document that is already in the page cache.
208         Schedule a style recalc if needed when an object comes out of the page cache.
209
210         * dom/Document.cpp:
211         (WebCore::Document::scheduleStyleRecalc):
212         (WebCore::Document::setInPageCache):
213
214 2009-04-13  Timothy Hatcher  <timothy@apple.com>
215
216         Correctly sort (program) scripts in the Scripts panel popup menu.
217
218         Reviewed by Ada Chan.
219
220         * inspector/front-end/ScriptsPanel.js:
221         (WebInspector.ScriptsPanel.prototype._addScriptToFilesMenu): Refactor the code
222         and sort "(program)" options by the sourceID to maintain some order.
223         * inspector/front-end/utilities.js:
224         (indexOfObjectInListSortedByFunction): Fix a bug where identical objects would cause
225         an incorrect return value that confuses insertionIndexForObjectInListSortedByFunction.
226         Just set 'first' and break so the correct result will be returned.
227
228 2009-04-13  Greg Bolsinga  <bolsinga@apple.com>
229
230         Reviewed by Darin Adler.
231
232         https://bugs.webkit.org/show_bug.cgi?id=24770
233         
234         Add custom code for Coordinates that returns null when required by the
235         Geolocation spec.
236         
237         http://dev.w3.org/geo/api/spec-source.html#coordinates
238
239         * WebCore.xcodeproj/project.pbxproj:
240         * bindings/js/JSCoordinatesCustom.cpp: Added.
241         (WebCore::JSCoordinates::altitude): returns null if the value cannot be provided.
242         (WebCore::JSCoordinates::altitudeAccuracy): Ditto
243         (WebCore::JSCoordinates::heading): Ditto
244         (WebCore::JSCoordinates::speed): Ditto
245         * page/Coordinates.h:
246         (WebCore::Coordinates::create): Add 'canProvide' parameters and values
247         (WebCore::Coordinates::canProvideAltitude):
248         (WebCore::Coordinates::canProvideAltitudeAccuracy):
249         (WebCore::Coordinates::canProvideHeading):
250         (WebCore::Coordinates::canProvideSpeed):
251         (WebCore::Coordinates::Coordinates):
252         * page/Coordinates.idl: specify custom getters
253         * platform/mac/GeolocationServiceMac.mm: Set the values correctly if they cannot be provided.
254         (-[WebCoreCoreLocationObserver locationManager:didUpdateToLocation:fromLocation:]):
255
256 2009-04-13  Adele Peterson  <adele@apple.com>
257
258         Reviewed by Darin Adler.
259
260         Fix for <rdar://problem/5510537> Typing return at start of block quote yields empty quoted line
261
262         Test: editing/inserting/5510537.html
263
264         * editing/BreakBlockquoteCommand.cpp: (WebCore::BreakBlockquoteCommand::doApply): If the break insertion position
265         is at the beginning of the topmost quote, then just insert the <br> before the blockquote.  Otherwise, if the break
266         insertion position is at the beginning of any quote, adjust the position so the break comes before the current quote level
267         so we don't end up with an empty line in that quote in addition to the new line we're adding with the <br>.
268
269 2009-04-11  Darin Adler  <darin@apple.com>
270
271         Reviewed by Dan Bernstein.
272
273         Fix problem when encoding history files with duplicate integer arrays near the end of the file.
274         This results in an assertion failure, and if assertions are turned off, corrupted output.
275
276         When writing an integer array it's important not to add an object reference to the
277         aggregate buffer. The writing of the array does not depend on the aggregate buffer. But,
278         more importantly, it's possible this instance integer array is a duplicate and won't be
279         written out. If so, there's no guarantee there's enough space in the aggregate buffer to
280         store the object references (the references will be ignored). In some cases the aggregate
281         buffer can then overrun the data being written; normally this is prevented by the fact that
282         the data being written will include a copy of the aggregate buffer.
283
284         Also removed a bit of unneeded dead code to handle the integer -1.
285
286         * platform/cf/BinaryPropertyList.cpp:
287         (WebCore::BinaryPropertyListPlan::BinaryPropertyListPlan): Removed unneeded
288         m_integerNegativeOneObjectReference, since property lists support only non-negative integers.
289         (WebCore::BinaryPropertyListPlan::writeInteger): Removed support for
290         m_integerNegativeOneObjectReference.
291         (WebCore::BinaryPropertyListPlan::integerObjectReference): Ditto.
292         (WebCore::BinaryPropertyListSerializer::writeIntegerWithoutAddingAggregateObjectReference):
293         Added. Factored out most of writeInteger, for use in writeIntegerArray, without calling
294         addAggregateObjectReference.
295         (WebCore::BinaryPropertyListSerializer::writeInteger): Changed to call the new
296         writeIntegerWithoutAddingAggregateObjectReference function.
297         (WebCore::BinaryPropertyListSerializer::writeIntegerArray): Call the new
298         writeIntegerWithoutAddingAggregateObjectReference function and therefore remove the
299         code to save and restore m_currentAggregateBufferByte, which is no longer needed.
300
301 2009-04-13  Holger Hans Peter Freyther  <zecke@selfish.org>
302
303         Unreviewed Qt build fix.
304
305         * platform/graphics/qt/FontQt.cpp:
306         (WebCore::Font::floatWidthForComplexText):
307
308 2009-04-12  Sam Weinig  <sam@webkit.org>
309
310         Reviewed by Mark Rowe.
311
312         Move the event and crypto attributes and the captureEvents and releaseEvents
313         functions out of JSDOMWindowBase by partially generating them.
314
315         * bindings/js/JSDOMGlobalObject.cpp:
316         (WebCore::JSDOMGlobalObject::currentEvent): Make const.
317         * bindings/js/JSDOMGlobalObject.h:
318         * bindings/js/JSDOMWindowBase.cpp:
319         * bindings/js/JSDOMWindowCustom.cpp:
320         (WebCore::JSDOMWindow::crypto): Not implemented.
321         (WebCore::JSDOMWindow::event):
322         (WebCore::JSDOMWindow::captureEvents): Not implemented.
323         (WebCore::JSDOMWindow::releaseEvents): Ditto.
324         * page/DOMWindow.idl:
325
326 2009-04-12  Sam Weinig  <sam@webkit.org>
327
328         Reviewed by Mark Rowe.
329
330         Move more attributes out of JSDOMWindowBase by
331         partially generating them.
332
333         - Expose the MessagePort constructor.
334
335         * bindings/js/JSDOMGlobalObject.h:
336         (WebCore::getDOMConstructor):
337         * bindings/js/JSDOMWindowBase.cpp:
338         (setJSDOMWindowBaseEvent):
339         * bindings/js/JSDOMWindowCustom.cpp:
340         (WebCore::JSDOMWindow::image):
341         (WebCore::JSDOMWindow::option):
342         (WebCore::JSDOMWindow::audio):
343         (WebCore::JSDOMWindow::webKitPoint):
344         (WebCore::JSDOMWindow::webKitCSSMatrix):
345         (WebCore::JSDOMWindow::xMLHttpRequest):
346         (WebCore::JSDOMWindow::xSLTProcessor):
347         (WebCore::JSDOMWindow::messageChannel):
348         (WebCore::JSDOMWindow::worker):
349         * page/DOMWindow.idl:
350
351 2009-04-12  Timothy Hatcher  <timothy@apple.com>
352
353         A resource's filename is not correct after a redirect in the Inspector.
354
355         Reviewed by Dan Bernstein.
356
357         * inspector/InspectorResource.cpp:
358         (WebCore::InspectorResource::updateScriptObject): Fix a typo in the
359         lastPathComponent property name.
360
361 2009-04-12  Adele Peterson  <adele@apple.com>
362
363         Reviewed by Darin Adler.
364
365         Test: editing/inserting/6609479-1.html
366
367         Follow-up to <rdar://problem/6609479>.
368
369         Before my last change, a Mail blockquote would've been broken up earlier, and you would've been guaranteed that the inserted content
370         was at the start of a paragraph.  Now we need to check for that explicitly, and only merge the start of the inserted content if it is 
371         at the start of a paragraph.
372
373         * editing/ReplaceSelectionCommand.cpp: (WebCore::ReplaceSelectionCommand::shouldMergeStart):
374
375 2009-04-11  Adele Peterson  <adele@apple.com>
376
377         Reviewed by Dan Bernstein.
378
379         Fix for <rdar://problem/6609479> Pressing return inside a table cell that's inside quoted content will split the table
380
381         Test: editing/inserting/6609479.html
382
383         Don't break a blockquote if pasting or inserting into a table.
384
385         * editing/ReplaceSelectionCommand.cpp: (WebCore::ReplaceSelectionCommand::doApply):
386         * editing/TypingCommand.cpp: (WebCore::TypingCommand::insertParagraphSeparatorInQuotedContent):
387
388 2009-04-11  Dan Bernstein  <mitz@apple.com>
389
390         Reviewed by Darin Adler.
391
392         - fix <rdar://problem/6643103> Unscaled values from body.scrollHeight
393
394         Test: fast/css/zoom-body-scroll.html
395
396         Adjust scroll{Left,Top,Width,Height} values for zoom in getters and
397         setters.
398
399         * html/HTMLBodyElement.cpp:
400         (WebCore::adjustForZoom):
401         (WebCore::HTMLBodyElement::scrollLeft):
402         (WebCore::HTMLBodyElement::setScrollLeft):
403         (WebCore::HTMLBodyElement::scrollTop):
404         (WebCore::HTMLBodyElement::setScrollTop):
405         (WebCore::HTMLBodyElement::scrollHeight):
406         (WebCore::HTMLBodyElement::scrollWidth):
407
408 2009-04-10  Timothy Hatcher  <timothy@apple.com>
409
410         Allow page navigation and reload while stopped at a breakpoint.
411
412         <rdar://problem/6781108> Having a breakpoint active prevents page reload
413
414         Reviewed by Darin Adler.
415
416         * inspector/InspectorController.cpp:
417         (WebCore::InspectorController::didContinue): Call the resumedScript function.
418         * inspector/InspectorController.h: Added didContinue.
419         * inspector/JavaScriptDebugListener.h: Ditto.
420         * inspector/JavaScriptDebugServer.cpp:
421         (WebCore::JavaScriptDebugServer::pauseIfNeeded): Call didContinue on the listeners.
422         * inspector/front-end/ScriptsPanel.js:
423         (WebInspector.ScriptsPanel.prototype.debuggerResumed): Update the interface and state.
424         * inspector/front-end/inspector.js:
425         (WebInspector.resumedScript): Call ScriptsPanel.debuggerResumed.
426         * loader/FrameLoader.cpp:
427         (WebCore::FrameLoader::continueLoadAfterNavigationPolicy): Call resumeDebugger.
428
429 2009-04-10  Sam Weinig  <sam@webkit.org>
430
431         Reviewed by Adele Peterson.
432
433         Remove unused include for JSLock.
434
435         * page/mac/FrameMac.mm:
436
437 2009-04-10  Sam Weinig  <sam@webkit.org>
438
439         Reviewed by Darin Adler.
440
441         Add back the keepAlive timer for after the script execution to
442         protect the callers of evaluate, as was part of the original intent
443         of timer.
444
445         * bindings/js/ScriptController.cpp:
446         (WebCore::ScriptController::evaluate):
447         * page/mac/FrameMac.mm:
448
449 2009-04-10  Chris Marrin  <cmarrin@apple.com>
450
451         Reviewed by Simon Fraser.
452
453         Fixed https://bugs.webkit.org/show_bug.cgi?id=25137
454
455         If we reload, the animation controller sticks around and has
456         a stale animation time. So the needed delay is computed wrong.
457         I added a reset of the animation timer on load.
458
459         I did not do a test case because this only happens on reload so I
460         couldn't make an automated test. I tried using an iframe and using
461         reload() but that doesn't tickle the bug.
462
463         * dom/Document.cpp:
464         (WebCore::Document::implicitOpen):
465
466 2009-04-10  Grace Kloba  <klobag@gmail.com>
467
468         Reviewed by Darin Adler.
469
470         Move WORKERS header files inside ENABLE(WORKERS).
471         So if WORKERS is not enabled and the generated files are not generated, the build is still working.
472
473         * bindings/js/JSDOMGlobalObject.cpp:
474         * bindings/js/JSMessageChannelConstructor.cpp:
475         * bindings/js/ScheduledAction.cpp:
476
477 2009-04-10  Darin Adler  <darin@apple.com>
478
479         Reviewed by Brady Eidson.
480
481         <rdar://problem/6773515> crash in push_heap inside WebCore when printing
482
483         The crash was due to manipulating a timer on a different thread than the one it was created on.
484         This adds some diagnostics so we'll catch that kind of mistake immediately.
485
486         * platform/Timer.cpp:
487         (WebCore::TimerBase::TimerBase): Store the thread identifier in debug versions.
488         (WebCore::TimerBase::start): Assert it's the same thread the timer was created on.
489         (WebCore::TimerBase::stop): Ditto.
490         (WebCore::TimerBase::isActive): Ditto.
491         (WebCore::TimerBase::setNextFireTime): Ditto.
492
493         * platform/Timer.h: Added the thread identifier data member.
494
495 2009-04-10  Chris Marrin  <cmarrin@apple.com>
496
497         Reviewed by Dan Bernstein
498
499         https://bugs.webkit.org/show_bug.cgi?id=25108
500
501         If you remove a class with a transition while that transition is running
502         the animation timer will continue to fire after the transition is finished.
503         This has no visual indication, but it does drain the processor. And in some
504         cases it might even cause a glitch in future animations. Unfortunately there
505         is no way to test this without putting in printfs.
506
507         This happens because the animation logic is never traversed after a transition
508         is removed, so we never get a chance to cleanup. So I added cleanup in the logic
509         that fires the dispatch of the last style change when the animation finishes.
510
511         Test: transitions/remove-transition-style.html
512
513         * page/animation/AnimationController.cpp:
514         (WebCore::AnimationControllerPrivate::updateStyleIfNeededDispatcherFired):
515         * page/animation/CompositeAnimation.cpp:
516         (WebCore::CompositeAnimation::updateTransitions):
517         (WebCore::CompositeAnimation::animate):
518         (WebCore::CompositeAnimation::cleanupFinishedAnimations):
519         * page/animation/CompositeAnimation.h:
520
521 2009-04-10  Sam Weinig  <sam@webkit.org>
522
523         Reviewed by Geoffrey Garen.
524
525         Fix for <rdar://problem/6648858>
526         CrashTracer: [REGRESSION(Safari 4)] 60 crashes in Safari at com.apple.WebCore • WebCore::ScriptController::evaluate + 241
527
528         The Frame (and therefore ScriptController) were being destroyed
529         during JavaScript execution causing the JSDOMWindowShell to become
530         null.
531
532         * bindings/js/ScriptController.cpp:
533         (WebCore::ScriptController::evaluate): Use a RefPtr to protect the Frame
534         instead of the keep-alive timer, since a nested event loop used from with-in 
535         JavaScript execution could cause the timer to fire before returning.
536
537 2009-04-10  Dimitri Glazkov  <dglazkov@chromium.org>
538
539         Reviewed by Timothy Hatcher.
540
541         https://bugs.webkit.org/show_bug.cgi?id=25133
542         Fix an error in InspectorController's bindings, clean up a few header
543         includes, make empty object construction in ScriptObject less ambiguous.
544
545         * bindings/js/JSInspectorControllerCustom.cpp:
546         (WebCore::JSInspectorController::setSetting): Send correct argument from
547             the bindings.
548         * bindings/js/ScriptObject.cpp:
549         (WebCore::ScriptObject::createNew): Added.
550         * bindings/js/ScriptObject.h: Removed constructor, added decl for createNew.
551         * inspector/ConsoleMessage.cpp: Remove unused header.
552         * inspector/ConsoleMessage.h: Ditto.
553         * inspector/InspectorResource.cpp:
554         (WebCore::createHeadersObject): Changed to use ScriptObject::createNew.
555
556 2009-04-10  Chris Marrin  <cmarrin@apple.com>
557
558         Reviewed by Simon Fraser.
559
560         Fixed https://bugs.webkit.org/show_bug.cgi?id=25134
561
562         This both fixes a bug where I was not sending in the right time
563         to continue the animation and was not recomputing current time
564         when coming out of suspend.
565
566         * page/animation/AnimationBase.cpp:
567         (WebCore::AnimationBase::updateStateMachine):
568         * page/animation/AnimationController.cpp:
569         (WebCore::AnimationControllerPrivate::suspendAnimations):
570         (WebCore::AnimationControllerPrivate::resumeAnimations):
571
572 2009-04-10  Adam Roben  <aroben@apple.com>
573
574         Give Windows's <select> popup menus drop shadows
575
576         Rubber-stamped by Steve Falkenburg.
577
578         No test possible.
579
580         * platform/win/PopupMenuWin.cpp:
581         (WebCore::registerPopup): Use the CS_DROPSHADOW window class style.
582
583 2009-04-10  Timothy Hatcher  <timothy@apple.com>
584
585         Fix a bug in the Web Inspector where it would show scripts
586         from previous pages when toggling the debugger off and back on.
587
588         https://bugs.webkit.org/show_bug.cgi?id=25095
589         rdar://problem/6769970
590
591         Reviewed by John Sullivan.
592
593         * bindings/js/ScriptCachedFrameData.cpp:
594         (WebCore::ScriptCachedFrameData::ScriptCachedFrameData): Null out the
595         debugger for the scriptController. This balances the attachDebugger
596         that was already in ScriptCachedFrameData::restore.
597         (WebCore::ScriptCachedFrameData::restore): Clean up an if statement.
598         * bindings/js/ScriptController.cpp:
599         (WebCore::ScriptController::clearWindowShell): Clear the debugger from
600         the current window before setting the new window.
601         * inspector/JavaScriptDebugServer.cpp:
602         (WebCore::JavaScriptDebugServer::recompileAllJSFunctions): Only accumulate
603         source providers for code associated this as the debugger.
604
605 2009-04-10  Pierre d'Herbemont  <pdherbemont@apple.com>
606
607         Reviewed by Adele Peterson.
608
609         <rdar://problem/6646998> Avoid starting QTKitServer if possible
610         When possible avoid asking QTKit for the MIME types that require QTKitServer
611         when running 64-bit.
612
613         * WebCore.base.exp: Added new entry point.
614
615         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
616         (WebCore::addFileTypesToCache): Add an NSArray of types to the cache.
617         (WebCore::mimeCommonTypesCache): Add all "common" QTKit types to the cache.
618         (WebCore::mimeModernTypesCache): Add only "modern" QTKit types to the cache (this list does 
619         not start QTKitServer if it is not already running).
620         (WebCore::MediaPlayerPrivate::getSupportedTypes): Refactored.
621         (WebCore::MediaPlayerPrivate::supportsType): Look in list of "modern" types first to avoid
622         starting QTKitServer if possible.
623
624         * platform/mac/WebCoreSystemInterface.h: Add wkQTIncludeOnlyModernMediaFileTypes.
625         * platform/mac/WebCoreSystemInterface.mm: Ditto.
626
627 2009-04-10  Adam Roben  <aroben@apple.com>
628
629         Turn on window animations for <select> popup menus
630
631         We turned these off back when <select> popup menus were partially
632         transparent. Now that they're opaque, there's no reason not to
633         animate them.
634
635         Reviewed by Steve Falkenburg.
636
637         No test possible.
638
639         * platform/win/PopupMenuWin.cpp:
640         (WebCore::PopupMenu::show): Remove the #ifdef that was disabling the
641         window animation.
642
643 2009-04-10  Dan Bernstein  <mitz@apple.com>
644
645         Reviewed by Sam Weinig.
646
647         - fix a regression from r42379 which made zero-width characters affect
648           line height
649
650         Test: fixes fast/text/wide-zero-width-space.html
651
652         * platform/graphics/mac/FontMacATSUI.mm:
653         (WebCore::overrideLayoutOperation): Add to the fallback font list set
654         here, and only if the glyph is not zero-width...
655         (WebCore::ATSULayoutParameters::initialize): ...instead of doing it
656         here. This matches WidthIterator's behavior.
657
658 2009-04-10  Darin Fisher  <darin@chromium.org>
659
660         Fixing build bustage caused by warnings being treated as errors.
661         1- A local variable was only be used inside a debug assertion, which
662            caused grief for the release build.
663         2- Missing initializer for member 'DocumentMarker::activeMatch'
664
665         * dom/Document.cpp:
666         (WebCore::Document::addMarker):
667         (WebCore::Document::setMarkersActive):
668
669 2009-04-10  Finnur Thorarinsson  <finnur.webkit@gmail.com>
670
671         Reviewed by John Sullivan.
672
673         Fixing: https://bugs.webkit.org/show_bug.cgi?id=25117
674         (TextMatches don't have a concept of active match)
675
676         For the ports that use the DocumentMarker as highlighting for FindInPage it is
677         useful to have a flag that specifies which marker is active, so it can be drawn
678         in a different color.
679
680         This allows me to remove the hack to use the SelectionController to highlight
681         the active match (in the ChromiumWin port).
682
683         * dom/Document.cpp:
684         (WebCore::Document::setMarkersActive):
685         * dom/Document.h:
686         * dom/DocumentMarker.h:
687         * rendering/InlineTextBox.cpp:
688         (WebCore::InlineTextBox::paintTextMatchMarker):
689         * rendering/RenderTheme.cpp:
690         (WebCore::RenderTheme::platformActiveTextSearchHighlightColor):
691         (WebCore::RenderTheme::platformInactiveTextSearchHighlightColor):
692         * rendering/RenderTheme.h:
693         * rendering/RenderThemeChromiumWin.cpp:
694         (WebCore::RenderThemeChromiumWin::platformActiveSelectionBackgroundColor):
695         (WebCore::RenderThemeChromiumWin::platformInactiveSelectionBackgroundColor):
696         (WebCore::RenderThemeChromiumWin::platformActiveTextSearchHighlightColor):
697         (WebCore::RenderThemeChromiumWin::platformInactiveTextSearchHighlightColor):
698         * rendering/RenderThemeChromiumWin.h:
699
700 2009-04-10  Pamela Greene  <pam@chromium.org>
701
702         Reviewed by Dimitri Glazkov.
703
704         Build fix for Chromium.
705         https://bugs.webkit.org/show_bug.cgi?id=12440
706
707         * page/chromium/FrameChromium.cpp:
708         (WebCore::computePageRectsForFrame): change docWidth() to overflowWidth()
709
710 2009-04-09  David Hyatt  <hyatt@apple.com>
711
712         Reviewed by Oliver Hunt
713
714         Add a timer for style recalc (similar to the one used for scheduling layouts).  For now in order
715         to reduce the risk of regressions, I have left in all the synchronous machinery for updating style
716         following DOM events and JavaScript timeouts.  Eventually these calls will be removed.
717
718         Where the timer will really kick in and be useful is for clients that do style changes from
719         Objective-C DOM bindings or that execute JavaScript to manipulate style from the JavaScriptCore C API.
720
721         * dom/ContainerNode.cpp:
722         (WebCore::ContainerNode::insertBefore):
723         (WebCore::ContainerNode::replaceChild):
724         (WebCore::ContainerNode::removeChild):
725         (WebCore::ContainerNode::appendChild):
726         * dom/Document.cpp:
727         (WebCore::Document::Document):
728         (WebCore::Document::~Document):
729         (WebCore::Document::scheduleStyleRecalc):
730         (WebCore::Document::unscheduleStyleRecalc):
731         (WebCore::Document::styleRecalcTimerFired):
732         (WebCore::Document::updateStyleForAllDocuments):
733         (WebCore::Document::detach):
734         * dom/Document.h:
735         * dom/Node.cpp:
736         (WebCore::Node::setNeedsStyleRecalc):
737         (WebCore::Node::lazyAttach):
738
739 2009-04-09  Oliver Hunt  <oliver@apple.com>
740
741         Reviewed by Gavin Barraclough.
742
743         <rdar://problem/6586787> JS debugger does not work in 64-bit
744
745         Don't truncate the source id in JSCallFrame
746
747         * inspector/JavaScriptCallFrame.h:
748
749 2009-04-09  Adam Roben  <aroben@apple.com>
750
751         Start compiling HistoryPropertyList on Windows
752
753         Reviewed by Darin Adler.
754
755         * WebCore.vcproj/WebCore.vcproj: Added HistoryPropertyList and its
756         dependencies to the project. Copy headers from history/cf to
757         $WebKitOutputDir.
758         * history/cf/HistoryPropertyList.cpp: Added StringExtras.h so that
759         this file will compile on Windows.
760
761 2009-04-09  Dan Bernstein  <mitz@apple.com>
762
763         Reviewed by Dave Hyatt.
764
765         - fix <rdar://problem/6166612> Text boxes' metrics should be based on
766           the actual fonts used in them, not just the primary font
767
768         Covered by many existing layout tests
769
770         * platform/graphics/Font.cpp:
771         (WebCore::Font::floatWidth): Added a fallbackFonts parameter. If the
772         platform supports collecting fallback fonts in its complex font path
773         and fallbackFonts is not null, all fallback fonts used for the text run
774         will be added to it.
775
776         * platform/graphics/Font.h:
777         (WebCore::Font::width): Ditto.
778
779         * platform/graphics/FontFastPath.cpp:
780         (WebCore::Font::glyphDataForCharacter): Removed an unnecessary namespace
781         qualifier.
782         (WebCore::Font::floatWidthForSimpleText): Added a fallbackFonts
783         parameter, which is passed down to WidthIterator.
784
785         * platform/graphics/WidthIterator.cpp:
786         (WebCore::WidthIterator::WidthIterator): Added a fallbackFonts parameter
787         and used it to initialize the m_fallbackFonts member.
788         (WebCore::WidthIterator::advance): Track the fonts being used and add
789         any fallback fonts to the m_fallbackFonts set. Make sure to only add
790         non-small-caps fonts.
791
792         * platform/graphics/WidthIterator.h:
793
794         * platform/graphics/chromium/FontChromiumWin.cpp:
795         (WebCore::Font::canReturnFallbackFontsForComplexText): Added an
796         implementation that returns false, meaning this platform's
797         implementation of floatWidthForComplexText() does not populate the
798         fallbackFonts set.
799         (WebCore::Font::floatWidthForComplexText): Updated for the new
800         prototype.
801
802         * platform/graphics/chromium/FontLinux.cpp: Ditto.
803
804         * platform/graphics/gtk/FontGtk.cpp: Ditto.
805
806         * platform/graphics/mac/CoreTextController.cpp:
807         (WebCore::CoreTextController::CoreTextController): Added a fallbackFonts
808         parameter and used it to initialize the m_fallbackFonts member.
809         (WebCore::CoreTextController::collectCoreTextRunsForCharacters): Add
810         fallback fonts to m_fallbackFonts.
811
812         * platform/graphics/mac/CoreTextController.h:
813
814         * platform/graphics/mac/FontMac.mm:
815         (WebCore::Font::canReturnFallbackFontsForComplexText): Added an
816         implementation that returns true, indicating that the Mac
817         implementations of floatWidthForComplexText() populate the fallbackFonts
818         set.
819         * platform/graphics/mac/FontMacATSUI.mm:
820         (WebCore::ATSULayoutParameters::ATSULayoutParameters): Added a
821         fallbackFonts parameter and used it to initialize the m_fallbackFonts
822         member.
823         (WebCore::ATSULayoutParameters::initialize): Add fallback fonts to
824         m_fallbackFonts.
825         (WebCore::Font::floatWidthForComplexText): Added a fallbackFonts
826         parameter, which is passed down to ATSULayoutParameters.
827
828         * platform/graphics/mac/FontMacCoreText.cpp:
829         (WebCore::Font::floatWidthForComplexText): Added a fallbackFonts
830         parameter, which is passed down to CoreTextController.
831
832         * platform/graphics/win/FontWin.cpp:
833         (WebCore::Font::canReturnFallbackFontsForComplexText): Added an
834         implementation that returns true, indicating that the
835         UniscribeController-based implementations of floatWidthForComplexText()
836         populate the fallbackFonts set.
837         (WebCore::Font::floatWidthForComplexText): Added a fallbackFonts
838         parameter, which is passed down to UniscribeController.
839
840         * platform/graphics/win/UniscribeController.cpp:
841         (WebCore::UniscribeController::UniscribeController): Added a
842         fallbackfonts parameter and used it to initialize m_fallbackFonts.
843         (WebCore::UniscribeController::advance): Add fallback fonts to
844         m_fallbackFonts.
845
846         * platform/graphics/win/UniscribeController.h:
847         
848         * platform/graphics/wx/FontWx.cpp:
849         (WebCore::Font::canReturnFallbackFontsForComplexText): Added an
850         implementation that returns false, meaning this platform's
851         implementation of floatWidthForComplexText() does not populate the
852         fallbackFonts set.
853         (WebCore::Font::floatWidthForComplexText): Updated for the new
854         prototype.
855
856         * rendering/InlineFlowBox.cpp:
857         (WebCore::InlineFlowBox::computeLogicalBoxHeights): For an InlineTextBox
858         with multiple fonts, compute a common baseline and line height by
859         considering all fonts' ascents and descents (and line spacing, if
860         applicable).
861
862         * rendering/InlineTextBox.cpp:
863         (WebCore::InlineTextBox::setFallbackFonts): Added. Temporarily stores
864         the set of fallback fonts in a vector.
865         (WebCore::InlineTextBox::takeFallbackFonts): Added. Returns the fallback
866         fonts previously stored and removes them from storage.
867
868         * rendering/InlineTextBox.h:
869
870         * rendering/RenderText.cpp:
871         (WebCore::RenderText::RenderText): Initialized the
872         m_knownNotToUseFallbackFonts to false.
873         (WebCore::RenderText::styleDidChange): Reset
874         m_knownNotToUseFallbackFonts to false if the style difference is such that
875         affects layout.
876         (WebCore::RenderText::widthFromCache): Added a fallbackFonts parameter,
877         which is passed down to Font::width().
878         (WebCore::RenderText::trimmedPrefWidths): Updated for the change to
879         widthFromCache().
880         (WebCore::RenderText::calcPrefWidths): Made this call a private version
881         of calcPrefWidths() that takes a fallbackFonts parameter and set the
882         m_knownNotToUseFallbackFonts to true if the set comes back empty.
883         The private version passes the fallbackFonts set to widthFromCache().
884         (WebCore::RenderText::setText): Reset m_knownNotToUseFallbackFonts to
885         false.
886         (WebCore::RenderText::createFallbackFontMetricsBox): Added.
887         (WebCore::RenderText::width): Added a fallbackFonts parameter, which is
888         passed down to calcPrefWidths(), widthFromCache() and Font::width().
889         Set m_knownNotToUseFallbackFonts to true when appropriate.
890
891         * rendering/RenderText.h:
892
893         * rendering/bidi.cpp:
894         (WebCore::RenderBlock::constructLine): Added an assertion and a continue
895         statement to remove one level of indentation.
896         (WebCore::RenderBlock::computeHorizontalPositionsForLine): Temporarily
897         store the set of fallback fonts in the InlineTextBox.
898         (WebCore::RenderBlock::computeVerticalPositionsForLine): Added an
899         assertion.
900
901 2009-04-09  David Hyatt  <hyatt@apple.com>
902
903         Reviewed by Adam Roben
904
905         Rename all of the changed()/setChanged()/setDocumentChanged() methods to mention style recalc
906         explicitly instead.
907
908         * bindings/js/JSCustomPositionCallback.cpp:
909         (WebCore::JSCustomPositionCallback::handleEvent):
910         * bindings/js/JSCustomPositionErrorCallback.cpp:
911         (WebCore::JSCustomPositionErrorCallback::handleEvent):
912         * bindings/js/JSCustomSQLStatementCallback.cpp:
913         (WebCore::JSCustomSQLStatementCallback::handleEvent):
914         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
915         (WebCore::JSCustomSQLStatementErrorCallback::handleEvent):
916         * bindings/js/JSCustomSQLTransactionCallback.cpp:
917         (WebCore::JSCustomSQLTransactionCallback::handleEvent):
918         * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
919         (WebCore::JSCustomSQLTransactionErrorCallback::handleEvent):
920         * bindings/js/JSCustomVoidCallback.cpp:
921         (WebCore::JSCustomVoidCallback::handleEvent):
922         * bindings/js/JSCustomXPathNSResolver.cpp:
923         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
924         * bindings/js/JSEventListener.cpp:
925         (WebCore::JSAbstractEventListener::handleEvent):
926         * bindings/js/ScheduledAction.cpp:
927         (WebCore::ScheduledAction::execute):
928         * bindings/js/ScriptControllerMac.mm:
929         (WebCore::updateStyleIfNeededForBindings):
930         (WebCore::ScriptController::initJavaJSBindings):
931         * css/CSSMutableStyleDeclaration.cpp:
932         (WebCore::CSSMutableStyleDeclaration::removeProperty):
933         (WebCore::CSSMutableStyleDeclaration::setNeedsStyleRecalc):
934         (WebCore::CSSMutableStyleDeclaration::setProperty):
935         (WebCore::CSSMutableStyleDeclaration::setStringProperty):
936         (WebCore::CSSMutableStyleDeclaration::setImageProperty):
937         (WebCore::CSSMutableStyleDeclaration::parseDeclaration):
938         (WebCore::CSSMutableStyleDeclaration::addParsedProperties):
939         (WebCore::CSSMutableStyleDeclaration::setCssText):
940         (WebCore::CSSMutableStyleDeclaration::merge):
941         (WebCore::CSSMutableStyleDeclaration::removePropertiesInSet):
942         * css/CSSMutableStyleDeclaration.h:
943         * css/CSSStyleSelector.cpp:
944         (WebCore::CSSStyleSelector::SelectorChecker::allVisitedStateChanged):
945         (WebCore::CSSStyleSelector::SelectorChecker::visitedStateChanged):
946         * css/CSSVariablesDeclaration.cpp:
947         (WebCore::CSSVariablesDeclaration::removeVariable):
948         (WebCore::CSSVariablesDeclaration::setVariable):
949         (WebCore::CSSVariablesDeclaration::setNeedsStyleRecalc):
950         * css/CSSVariablesDeclaration.h:
951         * dom/ContainerNode.cpp:
952         (WebCore::ContainerNode::insertBefore):
953         (WebCore::ContainerNode::replaceChild):
954         (WebCore::ContainerNode::removeChild):
955         (WebCore::ContainerNode::appendChild):
956         (WebCore::ContainerNode::detach):
957         (WebCore::ContainerNode::setFocus):
958         (WebCore::ContainerNode::setActive):
959         (WebCore::ContainerNode::setHovered):
960         * dom/Document.cpp:
961         (WebCore::Document::Document):
962         (WebCore::Document::~Document):
963         (WebCore::Document::scheduleStyleRecalc):
964         (WebCore::Document::unscheduleStyleRecalc):
965         (WebCore::Document::recalcStyle):
966         (WebCore::Document::updateStyleIfNeeded):
967         (WebCore::Document::updateStyleForAllDocuments):
968         (WebCore::Document::updateLayout):
969         (WebCore::Document::implicitClose):
970         (WebCore::Document::prepareMouseEvent):
971         (WebCore::Document::setFocusedNode):
972         (WebCore::Document::setCSSTarget):
973         * dom/Document.h:
974         * dom/Element.cpp:
975         (WebCore::Element::recalcStyle):
976         (WebCore::checkForSiblingStyleChanges):
977         * dom/InputElement.cpp:
978         (WebCore::InputElement::parseMaxLengthAttribute):
979         * dom/MouseRelatedEvent.cpp:
980         (WebCore::MouseRelatedEvent::receivedTarget):
981         * dom/Node.cpp:
982         (WebCore::Node::Node):
983         (WebCore::Node::setNeedsStyleRecalc):
984         (WebCore::Node::lazyAttach):
985         (WebCore::Node::dispatchGenericEvent):
986         * dom/Node.h:
987         (WebCore::Node::needsStyleRecalc):
988         (WebCore::Node::childNeedsStyleRecalc):
989         (WebCore::Node::setChildNeedsStyleRecalc):
990         * dom/OptionElement.cpp:
991         (WebCore::OptionElement::setSelectedState):
992         * dom/ScriptElement.cpp:
993         (WebCore::ScriptElementData::evaluateScript):
994         * dom/StyledElement.cpp:
995         (WebCore::StyledElement::attributeChanged):
996         (WebCore::StyledElement::classAttributeChanged):
997         (WebCore::StyledElement::parseMappedAttribute):
998         * dom/Text.cpp:
999         (WebCore::Text::recalcStyle):
1000         * dom/XMLTokenizer.cpp:
1001         (WebCore::XMLTokenizer::insertErrorMessageBlock):
1002         * editing/DeleteButtonController.cpp:
1003         (WebCore::DeleteButtonController::enable):
1004         * editing/Editor.cpp:
1005         (WebCore::Editor::setBaseWritingDirection):
1006         * editing/SelectionController.cpp:
1007         (WebCore::SelectionController::nodeWillBeRemoved):
1008         (WebCore::SelectionController::layout):
1009         (WebCore::SelectionController::focusedOrActiveStateChanged):
1010         * html/HTMLAnchorElement.cpp:
1011         (WebCore::HTMLAnchorElement::parseMappedAttribute):
1012         * html/HTMLElement.cpp:
1013         (WebCore::HTMLElement::setInnerText):
1014         (WebCore::HTMLElement::isContentEditable):
1015         (WebCore::HTMLElement::isContentRichlyEditable):
1016         (WebCore::HTMLElement::contentEditable):
1017         * html/HTMLEmbedElement.cpp:
1018         (WebCore::HTMLEmbedElement::updateWidget):
1019         * html/HTMLFormControlElement.cpp:
1020         (WebCore::HTMLFormControlElement::parseMappedAttribute):
1021         * html/HTMLFrameSetElement.cpp:
1022         (WebCore::HTMLFrameSetElement::parseMappedAttribute):
1023         (WebCore::HTMLFrameSetElement::recalcStyle):
1024         * html/HTMLInputElement.cpp:
1025         (WebCore::HTMLInputElement::parseMappedAttribute):
1026         (WebCore::HTMLInputElement::setChecked):
1027         (WebCore::HTMLInputElement::setIndeterminate):
1028         (WebCore::HTMLInputElement::setValue):
1029         (WebCore::HTMLInputElement::setAutofilled):
1030         * html/HTMLMediaElement.cpp:
1031         (WebCore::HTMLMediaElement::finishParsingChildren):
1032         * html/HTMLObjectElement.cpp:
1033         (WebCore::HTMLObjectElement::updateWidget):
1034         (WebCore::HTMLObjectElement::finishParsingChildren):
1035         (WebCore::HTMLObjectElement::childrenChanged):
1036         * html/HTMLSelectElement.cpp:
1037         (WebCore::HTMLSelectElement::recalcStyle):
1038         (WebCore::HTMLSelectElement::restoreState):
1039         (WebCore::HTMLSelectElement::setRecalcListItems):
1040         (WebCore::HTMLSelectElement::reset):
1041         (WebCore::HTMLSelectElement::typeAheadFind):
1042         * html/HTMLTableElement.cpp:
1043         (WebCore::setTableCellsChanged):
1044         (WebCore::HTMLTableElement::parseMappedAttribute):
1045         * html/HTMLTextAreaElement.cpp:
1046         (WebCore::HTMLTextAreaElement::setValue):
1047         * loader/FrameLoader.cpp:
1048         (WebCore::FrameLoader::stopLoading):
1049         (WebCore::FrameLoader::executeScript):
1050         (WebCore::FrameLoader::gotoAnchor):
1051         * page/DOMWindow.cpp:
1052         (WebCore::DOMWindow::alert):
1053         (WebCore::DOMWindow::confirm):
1054         (WebCore::DOMWindow::prompt):
1055         * page/EventHandler.cpp:
1056         (WebCore::EventHandler::hoverTimerFired):
1057         * page/FrameView.cpp:
1058         (WebCore::FrameView::layout):
1059         (WebCore::FrameView::needsLayout):
1060         * page/animation/AnimationBase.cpp:
1061         (WebCore::AnimationBase::setNeedsStyleRecalc):
1062         (WebCore::AnimationBase::updateStateMachine):
1063         * page/animation/AnimationBase.h:
1064         * page/animation/AnimationController.cpp:
1065         (WebCore::AnimationControllerPrivate::AnimationControllerPrivate):
1066         (WebCore::AnimationControllerPrivate::clear):
1067         (WebCore::AnimationControllerPrivate::updateAnimationTimer):
1068         (WebCore::AnimationControllerPrivate::updateStyleIfNeededDispatcherFired):
1069         (WebCore::AnimationControllerPrivate::startupdateStyleIfNeededDispatcher):
1070         (WebCore::AnimationControllerPrivate::addEventToDispatch):
1071         (WebCore::AnimationControllerPrivate::addNodeChangeToDispatch):
1072         (WebCore::AnimationControllerPrivate::animationTimerFired):
1073         (WebCore::AnimationControllerPrivate::pauseAnimationAtTime):
1074         (WebCore::AnimationControllerPrivate::pauseTransitionAtTime):
1075         (WebCore::AnimationControllerPrivate::addToStartTimeResponseWaitList):
1076         (WebCore::AnimationController::cancelAnimations):
1077         * page/animation/AnimationControllerPrivate.h:
1078         * page/animation/ImplicitAnimation.cpp:
1079         (WebCore::ImplicitAnimation::sendTransitionEvent):
1080         * page/animation/KeyframeAnimation.cpp:
1081         (WebCore::KeyframeAnimation::endAnimation):
1082         (WebCore::KeyframeAnimation::sendAnimationEvent):
1083         * rendering/RenderObject.cpp:
1084         (WebCore::RenderObject::updateDragState):
1085         * rendering/RenderView.cpp:
1086         (WebCore::RenderView::selectionBounds):
1087         * svg/SVGAElement.cpp:
1088         (WebCore::SVGAElement::svgAttributeChanged):
1089         * svg/SVGAnimationElement.cpp:
1090         (WebCore::SVGAnimationElement::setTargetAttributeAnimatedValue):
1091         * svg/SVGCursorElement.cpp:
1092         (WebCore::SVGCursorElement::svgAttributeChanged):
1093         * svg/SVGElementInstance.cpp:
1094         (WebCore::SVGElementInstance::setNeedsUpdate):
1095         * svg/SVGForeignObjectElement.cpp:
1096         (WebCore::addCSSPropertyAndNotifyAttributeMap):
1097         * svg/SVGStopElement.cpp:
1098         (WebCore::SVGStopElement::parseMappedAttribute):
1099         * svg/SVGStyledElement.cpp:
1100         (WebCore::SVGStyledElement::parseMappedAttribute):
1101         * svg/SVGUseElement.cpp:
1102         (WebCore::SVGUseElement::svgAttributeChanged):
1103         (WebCore::SVGUseElement::childrenChanged):
1104         (WebCore::SVGUseElement::recalcStyle):
1105         * svg/animation/SMILTimeContainer.cpp:
1106         (WebCore::SMILTimeContainer::updateAnimations):
1107         * wml/WMLAElement.cpp:
1108         (WebCore::WMLAElement::parseMappedAttribute):
1109         * wml/WMLInputElement.cpp:
1110         (WebCore::WMLInputElement::setValue):
1111         (WebCore::WMLInputElement::parseMappedAttribute):
1112         * wml/WMLNoopElement.cpp:
1113         (WebCore::WMLNoopElement::insertedIntoDocument):
1114
1115 2009-04-09  Brett Wilson  <brettw@chromium.org>
1116
1117         Reviewed by Darin Fisher.
1118
1119         When there is a shadow set but it specifies "no shadow", clear the
1120         shadow shader. This will prevent Chromium from thinking there's a
1121         shadow and using the Skia codepath rather than Windows.
1122
1123         * platform/graphics/skia/GraphicsContextSkia.cpp:
1124         (WebCore::GraphicsContext::setPlatformShadow):
1125
1126 2009-04-09  Eric Seidel  <eric@webkit.org>
1127
1128         Reviewed by Simon Fraser.
1129
1130         Crash when accessing svg.viewport on a detached SVGSVGElement
1131         https://bugs.webkit.org/show_bug.cgi?id=25105
1132
1133         * svg/SVGSVGElement.cpp:
1134         (WebCore::SVGSVGElement::isOutermostSVG): return "true" that we are the "outermost" SVG element if we have no parent.  (The spec is unclear as to what behavior we should have in this case, and I doubt anyone cares for now).
1135
1136 2009-04-09  Jian Li  <jianli@chromium.org>
1137
1138         Reviewed by Dimitri Glazkov.
1139
1140         https://bugs.webkit.org/show_bug.cgi?id=25084
1141         Upstream changes to V8 bindings for XHR so that it can work under either DOMWindow or WorkerContext.
1142
1143         * bindings/v8/WorkerContextExecutionProxy.cpp:
1144         (WebCore::WorkerContextExecutionProxy::dispose):
1145         (WebCore::WorkerContextExecutionProxy::retrieve):
1146         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
1147         (WebCore::WorkerContextExecutionProxy::findOrCreateEventListenerHelper):
1148         (WebCore::WorkerContextExecutionProxy::FindOrCreateEventListener):
1149         (WebCore::WorkerContextExecutionProxy::findOrCreateObjectEventListener):
1150         * bindings/v8/WorkerContextExecutionProxy.h:
1151         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
1152         (WebCore::CALLBACK_FUNC_DECL):
1153         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
1154         (WebCore::getEventListener):
1155         (WebCore::ACCESSOR_SETTER):
1156         (WebCore::CALLBACK_FUNC_DECL):
1157
1158 2009-04-09  Darin Adler  <darin@apple.com>
1159
1160         Reviewed by Anders Carlsson and Sam Weinig.
1161
1162         Part of <rdar://problem/5438063> Saving history containing 100,000 entries causes pauses of 2s while browsing
1163
1164         Longer term solution is to change the design so Safari doesn't read and write all of history.
1165         This patch is step one: Do the serializing, which is done on the main thread, much faster.
1166
1167         * WebCore.base.exp: Added new entry points.
1168         * WebCore.xcodeproj/project.pbxproj: Added new source files.
1169
1170         * history/cf: Added.
1171
1172         * history/cf/HistoryPropertyList.cpp: Added.
1173         * history/cf/HistoryPropertyList.h: Added. Code to write history files. In the future we'll also
1174         have code for reading here too.
1175
1176         * platform/cf/BinaryPropertyList.cpp: Added.
1177         * platform/cf/BinaryPropertyList.h: Added. Code to write binary property list files.
1178
1179 2009-04-09  Simon Fraser  <simon.fraser@apple.com>
1180
1181         Reviewed by Antti Koivisto
1182
1183         https://bugs.webkit.org/show_bug.cgi?id=25122
1184
1185         If deferred repainting is active, we need to ensure that there are no repaints
1186         pending at the end of layoutIfNeededRecursive, which is called just before
1187         painting via -viewWillDraw.
1188
1189         * page/FrameView.cpp:
1190         (WebCore::FrameView::layoutIfNeededRecursive):
1191
1192 2009-04-09  John Grabowski  <jrg@chromium.org>
1193
1194         Reviewed by Darin Fisher.
1195
1196         https://bugs.webkit.org/show_bug.cgi?id=25117
1197         Fix Mac Chromium form controls.
1198
1199         * rendering/RenderThemeChromiumMac.mm:
1200         When rendering native controls in Mac Chromium, use a clean NSGraphicsContext.
1201         Properly save and restore native graphics context.
1202         (WebCore::RenderThemeChromiumMac::paintCheckbox):
1203         (WebCore::RenderThemeChromiumMac::paintRadio):
1204         (WebCore::RenderThemeChromiumMac::paintMenuList):
1205         (WebCore::RenderThemeChromiumMac::paintSearchFieldCancelButton):
1206         (WebCore::RenderThemeChromiumMac::paintSearchFieldResultsDecoration):
1207         (WebCore::RenderThemeChromiumMac::paintSearchFieldResultsButton):
1208
1209 2009-04-09  Drew Wilson  <atwilson@google.com>
1210
1211         Reviewed by Alexey Proskuryakov.
1212
1213         https://bugs.webkit.org/show_bug.cgi?id=25030
1214         Refactor MessagePort code to enable Chrome to use a MessagePortProxy object
1215         instead of a real MessagePort for the entangledPort, since it could
1216         theoretically live in a separate process.
1217
1218         The goal of this refactoring is to remove all assumptions that the object
1219         representing the entangled port is actually of type MessagePort. All
1220         operations that were previously directly modifying private MessagePort member
1221         variables in the entangled port (i.e. entangle(), postMessage()) have been changed
1222         to invoke functions in the  MessagePortProxy interface instead which will allow
1223         the Chrome bindings to proxy these calls to another process.
1224
1225         No new layout tests, as this is just a refactoring with no bug fixes
1226         or new functionality.
1227
1228         * GNUmakefile.am:
1229         * WebCore.vcproj/WebCore.vcproj:
1230         * WebCore.xcodeproj/project.pbxproj:
1231         * bindings/js/JSMessagePortCustom.cpp:
1232         (WebCore::JSMessagePort::mark):
1233         * dom/MessagePort.cpp:
1234         (WebCore::MessagePort::clone):
1235         (WebCore::MessagePort::postMessage):
1236         (WebCore::MessagePort::deliverMessage):
1237         (WebCore::MessagePort::startConversation):
1238         (WebCore::MessagePort::close):
1239         (WebCore::MessagePort::entangle):
1240         (WebCore::MessagePort::unentangle):
1241         * dom/MessagePort.h:
1242         (WebCore::MessagePort::entangledPort):
1243         * dom/MessagePortProxy.h: Added.
1244         (WebCore::MessagePortProxy::~MessagePortProxy):
1245
1246 2009-04-08  Sam Weinig  <sam@webkit.org>
1247
1248         Reviewed by Geoffrey "Big Boy" Garen.
1249
1250         Fix for <rdar://problem/5745677> Possible to stop load during an unload event
1251         Also fixes https://bugs.webkit.org/show_bug.cgi?id=20605
1252
1253         Tests: fast/events/stop-load-in-unload-handler-using-document-write.html
1254                fast/events/stop-load-in-unload-handler-using-window-stop.html
1255
1256         Don't allow calling methods that would stop the new load inside the unload
1257         event.
1258
1259         * loader/FrameLoader.cpp:
1260         (WebCore::FrameLoader::FrameLoader):
1261         (WebCore::FrameLoader::stopLoading):
1262         (WebCore::FrameLoader::stopAllLoaders):
1263         * loader/FrameLoader.h:
1264
1265 2009-04-09  David Kilzer  <ddkilzer@apple.com>
1266
1267         Reinstating <rdar://problem/6718589> Option to turn off SVG DOM Objective-C bindings
1268
1269         Rolled r42345 back in.  The build failure was caused by an
1270         internal script which had not been updated the same way that
1271         build-webkit was updated.
1272
1273         * Configurations/WebCore.xcconfig:
1274         * DerivedSources.make:
1275         * bindings/objc/DOM.mm:
1276         (WebCore::createElementClassMap):
1277         (+[DOMNode _wrapNode:WebCore::]):
1278         * bindings/objc/DOMCSS.mm:
1279         (+[DOMCSSValue _wrapCSSValue:WebCore::]):
1280         * bindings/objc/DOMEvents.mm:
1281         (+[DOMEvent _wrapEvent:WebCore::]):
1282         * bindings/objc/DOMInternal.h:
1283         * bindings/objc/ExceptionHandlers.mm:
1284         (WebCore::raiseDOMException):
1285         * html/HTMLEmbedElement.idl:
1286         * html/HTMLFrameElement.idl:
1287         * html/HTMLIFrameElement.idl:
1288         * html/HTMLObjectElement.idl:
1289
1290 2009-04-09  Simon Fraser  <simon.fraser@apple.com>
1291
1292         Reviewed by Darin Adler
1293
1294         https://bugs.webkit.org/show_bug.cgi?id=25109
1295
1296         Eliminate CompositeAnimationPrivate, which was a needless level
1297         of abstraction. Remove the methods like addToStyleAvailableWaitList()
1298         that simply turn around and call the animation controller.
1299         
1300         Rename animationControllerPriv() to animationController().
1301         Rename willNeedService() to timeToNextService().
1302
1303         * page/animation/AnimationBase.cpp:
1304         (WebCore::AnimationBase::~AnimationBase):
1305         (WebCore::AnimationBase::updateStateMachine):
1306         (WebCore::AnimationBase::timeToNextService):
1307         (WebCore::AnimationBase::beginAnimationUpdateTime):
1308         * page/animation/AnimationBase.h:
1309         * page/animation/AnimationController.cpp:
1310         (WebCore::AnimationControllerPrivate::updateAnimationTimer):
1311         * page/animation/CompositeAnimation.cpp:
1312         (WebCore::CompositeAnimation::~CompositeAnimation):
1313         (WebCore::CompositeAnimation::clearRenderer):
1314         (WebCore::CompositeAnimation::updateTransitions):
1315         (WebCore::CompositeAnimation::updateKeyframeAnimations):
1316         (WebCore::CompositeAnimation::animate):
1317         (WebCore::CompositeAnimation::getAnimatedStyle):
1318         (WebCore::CompositeAnimation::setAnimating):
1319         (WebCore::CompositeAnimation::timeToNextService):
1320         (WebCore::CompositeAnimation::getAnimationForProperty):
1321         (WebCore::CompositeAnimation::cleanupFinishedAnimations):
1322         (WebCore::CompositeAnimation::suspendAnimations):
1323         (WebCore::CompositeAnimation::resumeAnimations):
1324         (WebCore::CompositeAnimation::overrideImplicitAnimations):
1325         (WebCore::CompositeAnimation::resumeOverriddenImplicitAnimations):
1326         (WebCore::CompositeAnimation::isAnimatingProperty):
1327         (WebCore::CompositeAnimation::pauseAnimationAtTime):
1328         (WebCore::CompositeAnimation::pauseTransitionAtTime):
1329         (WebCore::CompositeAnimation::numberOfActiveAnimations):
1330         * page/animation/CompositeAnimation.h:
1331         (WebCore::CompositeAnimation::animationController):
1332         (WebCore::CompositeAnimation::isSuspended):
1333         (WebCore::CompositeAnimation::hasAnimations):
1334         (WebCore::CompositeAnimation::CompositeAnimation):
1335         * page/animation/ImplicitAnimation.cpp:
1336         (WebCore::ImplicitAnimation::sendTransitionEvent):
1337         (WebCore::ImplicitAnimation::timeToNextService):
1338         * page/animation/ImplicitAnimation.h:
1339         * page/animation/KeyframeAnimation.cpp:
1340         (WebCore::KeyframeAnimation::sendAnimationEvent):
1341         (WebCore::KeyframeAnimation::timeToNextService):
1342         * page/animation/KeyframeAnimation.h:
1343
1344 2009-04-09  Alexey Proskuryakov  <ap@webkit.org>
1345
1346         Reverting <rdar://problem/6718589> Option to turn off SVG DOM Objective-C bindings.
1347         It broke Mac build, and I don't know how to fix it.
1348
1349         * Configurations/WebCore.xcconfig:
1350         * DerivedSources.make:
1351         * bindings/objc/DOM.mm:
1352         (WebCore::createElementClassMap):
1353         (+[DOMNode _wrapNode:WebCore::]):
1354         * bindings/objc/DOMCSS.mm:
1355         (+[DOMCSSValue _wrapCSSValue:WebCore::]):
1356         * bindings/objc/DOMEvents.mm:
1357         (+[DOMEvent _wrapEvent:WebCore::]):
1358         * bindings/objc/DOMInternal.h:
1359         * bindings/objc/ExceptionHandlers.mm:
1360         (WebCore::raiseDOMException):
1361         * html/HTMLEmbedElement.idl:
1362         * html/HTMLFrameElement.idl:
1363         * html/HTMLIFrameElement.idl:
1364         * html/HTMLObjectElement.idl:
1365
1366 2009-04-09  Xan Lopez  <xlopez@igalia.com>
1367
1368         Unreviewed build fix.
1369
1370         RenderView::docWidth() was made private by r42334. That commit
1371         changes its usage for overflowWidth(), so do that here too.
1372
1373         * page/PrintContext.cpp:
1374         (WebCore::PrintContext::computePageRects):
1375
1376 2009-04-09  Xan Lopez  <xlopez@igalia.com>
1377
1378         Reviewed by Holger Freyther.
1379
1380         https://bugs.webkit.org/show_bug.cgi?id=21546
1381         [GTK] ATK accessibility enhancements
1382
1383         Based on a patch by Alp Toker.
1384
1385         Implement AtkObject::ref_state_set. Still quite a few states not
1386         implemented.
1387
1388         * page/gtk/AccessibilityObjectWrapperAtk.cpp:
1389
1390 2009-04-09  Xan Lopez  <xlopez@igalia.com>
1391
1392         Reviewed by Holger Freyther.
1393
1394         https://bugs.webkit.org/show_bug.cgi?id=21546
1395         [GTK] ATK accessibility enhancements
1396
1397         Based on a patch by Alp Toker.
1398
1399         Move fallback object creation to its own function, as it will be
1400         used in several places.
1401
1402         * page/gtk/AccessibilityObjectWrapperAtk.cpp:
1403         (fallbackObject):
1404
1405 2009-04-09  Xan Lopez  <xlopez@igalia.com>
1406
1407         Reviewed by Holger Freyther.
1408
1409         https://bugs.webkit.org/show_bug.cgi?id=21546
1410         [GTK] ATK accessibility enhancements
1411
1412         Based on a patch by Alp Toker.
1413
1414         Move AccessibilityObject methods to their file.
1415
1416         * page/gtk/AccessibilityObjectAtk.cpp:
1417         (WebCore::AccessibilityObject::wrapper):
1418         (WebCore::AccessibilityObject::setWrapper):
1419         * page/gtk/AccessibilityObjectWrapperAtk.cpp:
1420
1421 2009-04-09  Xan Lopez  <xlopez@igalia.com>
1422
1423         Reviewed by Holger Freyther.
1424
1425         https://bugs.webkit.org/show_bug.cgi?id=21546
1426         [GTK] ATK accessibility enhancements
1427
1428         Rework accessibility type generation code, based on Mozilla a11y
1429         implementation.
1430
1431         Have one base a11y type, and generate derived types that implement
1432         only the necessary interfaces at runtime, based on the specific
1433         object we are wrapping. This allows to save a lot of code while
1434         covering all possible cases.
1435
1436         * page/gtk/AccessibilityObjectWrapperAtk.cpp:
1437
1438 2009-04-09  Eric Seidel  <eric@webkit.org>
1439
1440         Reviewed by Oliver Hunt.
1441
1442         Fix document.implementation.createDocument(null, "a:b") not to crash!
1443         https://bugs.webkit.org/show_bug.cgi?id=25096
1444
1445         Test: fast/dom/DOMImplementation/createDocument-namespace-err.html
1446
1447         * dom/ContainerNode.cpp:
1448         (WebCore::ContainerNode::addChild): add ASSERT() to give a better crash next time
1449         * dom/DOMImplementation.cpp:
1450         (WebCore::DOMImplementation::createDocument): check the exception code before using the result
1451
1452 2009-04-08  Adam Roben  <aroben@apple.com>
1453
1454         Make <select>s in application chrome documents match the Vista system
1455         dialog look
1456
1457         Reviewed by Dave Hyatt.
1458
1459         * rendering/RenderThemeWin.cpp:
1460         (WebCore::documentIsInApplicationChromeMode): Added this simple helper
1461         function.
1462         (WebCore::RenderThemeWin::getThemeData): In application chrome mode,
1463         the drop down button never uses any look but the "normal" look.
1464         (WebCore::RenderThemeWin::paintMenuList): In application chrome mode,
1465         use the "readonly" style to match system dialogs.
1466
1467 2009-04-08  Adam Roben  <aroben@apple.com>
1468
1469         Fix <rdar://6592515> Crash closing tab with Top Sites or Cover Flow
1470         showing after clicking "Go Back" in phishing alert
1471
1472         RenderButton's m_timer is not stopped when its Document enters the
1473         page cache. When the WebView was torn down, the timer would fire after
1474         the Frame's Page had been destroyed, leading to a crash. This patch
1475         just makes the timer do nothing when it fires. Making the timer not
1476         fire when in the page cache is covered by bug 25110.
1477
1478         Reviewed by Dave Hyatt.
1479
1480         No test possible.
1481
1482         * rendering/RenderButton.cpp:
1483         (WebCore::RenderButton::timerFired): Do nothing when we're in the page
1484         cache.
1485
1486 2009-04-09  David Hyatt  <hyatt@apple.com>
1487
1488         Reviewed by Adam Roben
1489
1490         Fix bugs where we would mistakenly turn off blitting for iframes if an external paint
1491         caused the checks to be triggered too early in the loading process of the frame.
1492
1493         * rendering/RenderBoxModelObject.cpp:
1494         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1495
1496 2009-04-08  Simon Fraser  <simon.fraser@apple.com>
1497
1498         Reviewed by Cameron Zwarich
1499
1500         https://bugs.webkit.org/show_bug.cgi?id=25106
1501         
1502         Fix signature of virtual function on AnimationBase so that it matches
1503         those in the derived classes, by removing unused parameter.
1504         
1505         * page/animation/AnimationBase.h:
1506         (WebCore::AnimationBase::endAnimation):
1507
1508 2009-04-08  David Kilzer  <ddkilzer@apple.com>
1509
1510         <rdar://problem/6718589> Option to turn off SVG DOM Objective-C bindings
1511
1512         Reviewed by Darin Adler and Maciej Stachowiak.
1513
1514         Introduce the ENABLE_SVG_DOM_OBJC_BINDINGS feature define so
1515         that SVG DOM Objective-C bindings may be optionally disabled.
1516
1517         * Configurations/WebCore.xcconfig: Added
1518         ENABLE_SVG_DOM_OBJC_BINDINGS variable and use it in
1519         FEATURE_DEFINES and EXCLUDED_SOURCE_FILE_NAMES.  When SVG DOM
1520         Objective-C bindings are disabled, two generated header files no
1521         longer exist and none of the generated DOMSVG*.mm files should
1522         be compiled.
1523         * DerivedSources.make: All of the WebCore.SVG*.exp files contain
1524         SVG DOM Objective-C bindings classes, so exclude them unless
1525         ENABLE_SVG_DOM_OBJC_BINDINGS is set.
1526         * bindings/objc/DOM.mm: Switched from using ENABLE(SVG) to using
1527         ENABLE(SVG_DOM_OBJC_BINDINGS).
1528         (WebCore::createElementClassMap):
1529         (+[DOMNode _wrapNode:WebCore::]):
1530         * bindings/objc/DOMCSS.mm: Ditto.
1531         (+[DOMCSSValue _wrapCSSValue:WebCore::]):
1532         * bindings/objc/DOMEvents.mm: Ditto.
1533         (+[DOMEvent _wrapEvent:WebCore::]):
1534         * bindings/objc/DOMInternal.h: Ditto.
1535         * bindings/objc/ExceptionHandlers.mm: Added use of
1536         ENABLE(SVG_DOM_OBJC_BINDINGS).
1537         (WebCore::raiseDOMException):
1538         * html/HTMLEmbedElement.idl: Excluded -getSVGDocument method
1539         in generated Objective-C DOM classes if SVG DOM Objective-C
1540         bindings are disabled.
1541         * html/HTMLFrameElement.idl: Ditto.
1542         * html/HTMLIFrameElement.idl: Ditto.
1543         * html/HTMLObjectElement.idl: Ditto.
1544
1545 2009-04-08  Dan Bernstein  <mitz@apple.com>
1546
1547         Reviewed by Sam Weinig.
1548
1549         - limit the workaround for <rdar://problem/5781372> to Mac OS X versions
1550           that need it
1551
1552         * platform/mac/WebFontCache.mm:
1553         (fixUpWeight): Changed this function to be a no-op post-Leopard.
1554
1555 2009-04-08  Dan Bernstein  <mitz@apple.com>
1556
1557         Reviewed by Dave Hyatt.
1558
1559         - fix <rdar://problem/6771547> Appending to a RenderText causes all its
1560           lines to be dirtied
1561
1562         Test: fast/repaint/text-append-dirty-lines.html
1563
1564         * rendering/RenderText.cpp:
1565         (WebCore::RenderText::setTextWithOffset): If no text boxes intersected
1566         with or came after the new text, dirty the last root box, since the new
1567         text may begin there. Having at least one dirty line prevents the
1568         incorrect dirtying of all lines later during layoutInlineChildren().
1569
1570 2009-04-08  Darin Fisher  <darin@chromium.org>
1571
1572         Reviewed by Eric Seidel.
1573
1574         https://bugs.webkit.org/show_bug.cgi?id=25100
1575
1576         Fixes a Chromium-specific crash in WebCore::ImageBuffer::context that
1577         occurs when rendering semi-transparent RTL text.
1578
1579         Test: fast/text/complex-text-opacity.html
1580
1581         * platform/graphics/chromium/FontChromiumWin.cpp: Handle RTL when computing text bounds.
1582         (WebCore::TransparencyAwareFontPainter::TransparencyAwareUniscribePainter::estimateTextBounds):
1583
1584 2009-04-08  David Hyatt  <hyatt@apple.com>
1585
1586         Reviewed by Beth Dakin
1587
1588         Fix a porting error in my previous patch.  A != was supposed to be an ==.
1589
1590         * platform/ScrollView.cpp:
1591         (WebCore::ScrollView::updateScrollbars):
1592
1593 2009-04-08  David Hyatt  <hyatt@apple.com>
1594
1595         Reviewed by Adam Roben and Darin Adler
1596
1597         Fix for https://bugs.webkit.org/show_bug.cgi?id=12440, repaints inconsistent for
1598         fixed positioned elements.
1599
1600         Rewrite the updateScrollers method to be more correct in its results.
1601
1602         Test: fast/block/positioning/fixed-positioning-scrollbar-bug.html
1603
1604         * dom/Document.cpp:
1605         (WebCore::Document::recalcStyle):
1606         (WebCore::Document::implicitClose):
1607         * page/FrameView.cpp:
1608         (WebCore::FrameView::createScrollbar):
1609         (WebCore::FrameView::layout):
1610         (WebCore::FrameView::adjustPageHeight):
1611         * page/FrameView.h:
1612         * page/win/FrameWin.cpp:
1613         (WebCore::computePageRectsForFrame):
1614         * platform/ScrollView.cpp:
1615         (WebCore::ScrollView::ScrollView):
1616         (WebCore::ScrollView::updateScrollbars):
1617         * platform/ScrollView.h:
1618         * rendering/RenderView.cpp:
1619         (WebCore::RenderView::layout):
1620         (WebCore::RenderView::docHeight):
1621         (WebCore::RenderView::docWidth):
1622         * rendering/RenderView.h:
1623
1624 2009-04-08  Sam Weinig  <sam@webkit.org>
1625
1626         Reviewed by Anders Carlsson.
1627
1628         Fix for <rdar://problem/6226200> Implement Microsoft's X-FRAME-OPTIONS anti-framing defense
1629
1630         Tests: http/tests/security/XFrameOptions/x-frame-options-deny-meta-tag-in-body.html
1631                http/tests/security/XFrameOptions/x-frame-options-deny-meta-tag-parent-same-origin-allow.html
1632                http/tests/security/XFrameOptions/x-frame-options-deny-meta-tag-parent-same-origin-deny.html
1633                http/tests/security/XFrameOptions/x-frame-options-deny-meta-tag.html
1634                http/tests/security/XFrameOptions/x-frame-options-deny.html
1635                http/tests/security/XFrameOptions/x-frame-options-parent-same-origin-allow.html
1636                http/tests/security/XFrameOptions/x-frame-options-parent-same-origin-deny.html
1637
1638         * dom/Document.cpp:
1639         (WebCore::Document::processHttpEquiv): Stop the current load and redirect to about:blank
1640         if an X-FRAME-OPTIONS <meta> tag http-equiq dictates we should.
1641         * loader/FrameLoader.cpp:
1642         (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions): Add logic to parse
1643         the X-FRAME-OPTIONS parameter.
1644         * loader/FrameLoader.h:
1645         * loader/MainResourceLoader.cpp:
1646         (WebCore::MainResourceLoader::didReceiveResponse): Stop the current load if framed and
1647         a X-FRAME-OPTIONS header and its parameter dictate that we should.
1648
1649 2009-04-08  Adam Roben  <aroben@apple.com>
1650
1651         Fix http/tests/xmlhttprequest/xmlhttprequest-unsafe-redirect.html on Windows
1652
1653         Reviewed by Sam Weinig.
1654
1655         * platform/network/cf/ResourceHandleCFNet.cpp:
1656         (WebCore::ResourceHandle::loadResourceSynchronously): Mimic the
1657         ResourceHandleMac code by propagating the CFError's error code for
1658         kCFErrorDomainCFNetwork errors to the ResourceResponse.
1659
1660 2009-04-08  Anders Carlsson  <andersca@apple.com>
1661
1662         Try to fix the PPC build.
1663         
1664         * plugins/npfunctions.h:
1665
1666 2009-04-08  Darin Adler  <darin@apple.com>
1667
1668         Reviewed by Sam Weinig.
1669
1670         <rdar://problem/5908616> tokenizer resizer should handle edge cases consistently
1671
1672         * html/HTMLTokenizer.cpp:
1673         (WebCore::HTMLTokenizer::enlargeBuffer): Handle edge cases the same way as a failed fastMalloc.
1674         (WebCore::HTMLTokenizer::enlargeScriptBuffer): Ditto.
1675
1676 2009-04-08  David Hyatt  <hyatt@apple.com>
1677
1678         Reviewed by Darin Adler
1679
1680         Make sure that cloneNode works with SVG attributes that require synchronization.  This fixes
1681         issues with <use> element shadow tree cloning where the clones can end up not obtaining the
1682         correct attribute values.
1683
1684         A subsequent patch of mine will expose this problem and cause it to be covered by existing
1685         layout tests, so no test is required at this time for this problem.
1686
1687         * dom/Element.cpp:
1688         (WebCore::Element::cloneElementWithoutChildren):
1689
1690 2009-04-08  Dimitri Glazkov  <dglazkov@chromium.org>
1691
1692         Reviewed by Timothy Hatcher.
1693
1694         https://bugs.webkit.org/show_bug.cgi?id=25093
1695         REGRESSION: some scripts are showing in the Inspector with only "true"
1696         as the source.
1697
1698         * inspector/InspectorController.cpp:
1699         (WebCore::InspectorController::didParseSource): Fixed conversion issue.
1700         (WebCore::InspectorController::failedToParseSource): Ditto.
1701
1702 2009-04-08  Adam Barth  <abarth@webkit.org>
1703
1704         Reviewed by Alexey Proskuryakov.
1705
1706         https://bugs.webkit.org/show_bug.cgi?id=24904
1707
1708         Verify the MIME type of stylesheets (in standards mode) by looking
1709         at the Content-Type header directly.  This bypasses any content
1710         sniffing that might be confusing the issue.
1711
1712         Test: http/tests/mime/standard-mode-loads-stylesheet-without-content-type-header.html
1713
1714         * loader/CachedCSSStyleSheet.cpp:
1715         (WebCore::CachedCSSStyleSheet::canUseSheet):
1716
1717 2009-04-08  Eric Carlson  <eric.carlson@apple.com>
1718
1719         Reviewed by Simon Fraser.
1720
1721         https://bugs.webkit.org/show_bug.cgi?id=25041
1722         <rdar://problem/6697754>
1723         Bug 25041: HTMLMediaElement: OSX autoplay broken by r41907
1724         
1725         OSX media player should set readyState to HAVE_ENOUGH_DATA when the movie's load state
1726         reaches QTMovieLoadStatePlaythroughOK, not when the entire file has been downloaded,
1727         so autoplay can begin when it should.
1728
1729         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1730         (WebCore::MediaPlayerPrivate::updateStates): Set readState to 
1731         HAVE_ENOUGH_DATA when QTMovie load state reaches QTMovieLoadStatePlaythroughOK.
1732         (WebCore::MediaPlayerPrivate::paint): Add braces missed in r42203.
1733
1734 2009-04-08  Alexey Proskuryakov  <ap@webkit.org>
1735
1736         Reviewed by David Kilzer. Based on a patch by Grace Kloba.
1737
1738         https://bugs.webkit.org/show_bug.cgi?id=24656
1739         cacheControlContainsNoCache() in ResourceResponseBase.h is wrong
1740
1741         * platform/network/ResourceResponseBase.cpp:
1742         (WebCore::ResourceResponseBase::parseCacheControlDirectives): Removed misused code for
1743         parsing directive values, fixing parsing of directives that we care about.
1744
1745         * platform/network/ResourceResponseBase.h:
1746         (WebCore::ResourceResponseBase::cacheControlContainsNoCache): Fixed a copy/paste mistake,
1747         m_cacheControlContainsMustRevalidate was returned instead of m_cacheControlContainsNoCache.
1748
1749 2009-04-08  Adam Roben  <aroben@apple.com>
1750
1751         Make text fields match the system look on Vista
1752
1753         Reviewed by Dave Hyatt.
1754
1755         * rendering/RenderThemeWin.cpp:
1756         (WebCore::RenderThemeWin::getThemeData): Use the new-to-Vista
1757         EP_EDITBORDER_NOSCROLL part for text fields.
1758
1759 2009-04-07  Alexey Proskuryakov  <ap@webkit.org>
1760
1761         Reviewed by Maciej Stachowiak.
1762
1763         https://bugs.webkit.org/show_bug.cgi?id=24957
1764         REGRESSION: Google calendar widget no longer shows upcoming events
1765
1766         Test: http/tests/xmlhttprequest/authorization-header.html
1767
1768         * xml/XMLHttpRequest.cpp:
1769         (WebCore::XMLHttpRequestStaticData::XMLHttpRequestStaticData): Removed Authorization from
1770         the list of forbidden headers.
1771
1772 2009-04-07  miggilin  <mr.diggilin@gmail.com>
1773
1774         Reviewed by Kevin Ollivier.
1775
1776         Remove no longer needed debug warning and Windows-specific codepaths
1777         (as we now use the Safari/Win port's timer there)
1778
1779         https://bugs.webkit.org/show_bug.cgi?id=25070
1780
1781         * platform/wx/SharedTimerWx.cpp:
1782         (WebCore::setSharedTimerFireTime):
1783
1784
1785 2009-04-07  Adam Roben  <aroben@apple.com>
1786
1787         Fix many <video> regression tests on Windows
1788
1789         Reviewed by Dave Hyatt.
1790
1791         * platform/graphics/win/QTMovieWin.cpp:
1792         (QTMovieWin::getNaturalSize): Call GetMovieNaturalBoundsRect, which
1793         returns the movie's natural bounds (duh), rather than GetMovieBox,
1794         which returns the movie's current displayed size/position.
1795
1796 2009-04-07  Brady Eidson  <beidson@apple.com>
1797
1798         Reviewed by Darin Adler and Sam Weinig
1799
1800         <rdar://problem/5968249> "Private Browsing" doesn't affect HTML 5 LocalStorage
1801
1802         The expected behavior for persistent storage when private browsing mode is undefined by the spec.
1803         For now we're going with a "read-only when in private browsing" policy until we can get feedback
1804         and/or get the behavior specified in the spec.
1805
1806         Note that I purposefully made the change to restrict SessionStorage to read-only, also, with the
1807         understanding that the spec allows for SessionStorage to persist across relaunches, even though
1808         our implementation currently doesn't do this.
1809
1810         * dom/DOMCoreException.idl: Add some new ExceptionCodes defined in HTML5, one of which is needed
1811           for LocalStorage changes (QUOTA_EXCEEDED_ERR)
1812         * dom/ExceptionCode.cpp: 
1813         * dom/ExceptionCode.h:
1814
1815         * storage/StorageArea.cpp:
1816         (WebCore::StorageArea::internalSetItem): If private browsing is enabled, throw the QUOTA_EXCEEDED_ERR
1817           exception as the spec allows.
1818         (WebCore::StorageArea::internalRemoveItem): If private browsing is enabled, silently fail to remove
1819           the item.
1820         (WebCore::StorageArea::internalClear): If private browsing is enabled, silently fail to clear the area.
1821
1822 2009-04-07  Dean Jackson  <dino@apple.com>
1823
1824         Reviewed by Simon Fraser.
1825
1826         <rdar://problem/6148255>
1827
1828         Standalone media documents can not always handle everything
1829         using a <video> element. In these cases switch to an <embed>
1830         element that uses the QuickTime plugin, in the hope that it
1831         will have more luck. Typical media types that trigger this
1832         are streamed media and QTVR.
1833
1834         Equivalent Windows fix to come once reviewed. Note also that
1835         this area of code needs a cleanup:
1836         https://bugs.webkit.org/show_bug.cgi?id=25085
1837
1838         * html/HTMLMediaElement.cpp:
1839         (WebCore::HTMLMediaElement::mediaPlayerSawUnsupportedTracks):
1840         * html/HTMLMediaElement.h:
1841         * loader/MediaDocument.cpp:
1842         (WebCore::MediaDocument::mediaElementSawUnsupportedTracks):
1843         (WebCore::MediaDocument::replaceVideoWithEmbed):
1844         * loader/MediaDocument.h:
1845             - removes the <video> element and puts in an <embed>
1846         * platform/graphics/MediaPlayer.h:
1847         (WebCore::MediaPlayerClient::mediaPlayerSawUnsupportedTracks):
1848             - new internal method for flagging a problem
1849         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
1850         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1851         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
1852         (WebCore::MediaPlayerPrivate::updateStates):
1853             - looks for the types of content we don't handle
1854         (WebCore::MediaPlayerPrivate::rateChanged):
1855         (WebCore::MediaPlayerPrivate::sizeChanged):
1856         (WebCore::MediaPlayerPrivate::timeChanged):
1857         (WebCore::MediaPlayerPrivate::didEnd):
1858         (WebCore::MediaPlayerPrivate::disableUnsupportedTracks):
1859         (WebCore::MediaPlayerPrivate::sawUnsupportedTracks):
1860             - inform the MediaClient that we have a potential problem
1861
1862 2009-04-07  Dan Bernstein  <mitz@apple.com>
1863
1864         Reviewed by Darin Adler.
1865
1866         - fix <rdar://problem/6767428> Resurrect
1867           +[WebFontCache fontWithFamily:traits:size:] for clients that call it
1868           directly
1869
1870         WebFontCache is a class in the WebCore framework and is not WebKit API,
1871         but apparently (perhaps mistakenly) some clients call this private
1872         interface.
1873
1874         This change resurrects the interface and gives it reasonable behavior
1875         (however, note that WebCore will not call the old interface, so hacks that
1876         override it will have no effect on WebKit clients).
1877
1878         * platform/mac/WebFontCache.h:
1879         * platform/mac/WebFontCache.mm:
1880         (+[WebFontCache fontWithFamily:traits:size:]): Added. Call through to
1881         +fontWithFamily:traits:weight:size:.
1882
1883 2009-04-07  David Hyatt  <hyatt@apple.com>
1884
1885         Reviewed by Adam Roben
1886
1887         Fix ScrollView's algorithm that determines whether or not to show scrollbars.  There was a bug
1888         with the method mainly because RenderView will size itself to the viewport's size, making it
1889         impossible to really know the document's "true" size.
1890
1891         In order to solve this problem ScrollView now has a minimumContentsSize method.  This method
1892         returns the document size excluding the RenderView from the calculation.  This width/height
1893         is now cached on RenderView in m_docWidth/m_docHeight member variables.
1894
1895         * WebCore.base.exp:
1896         * page/FrameView.cpp:
1897         (WebCore::FrameView::adjustPageHeight):
1898         (WebCore::FrameView::minimumContentsSize):
1899         * page/FrameView.h:
1900         * platform/ScrollView.cpp:
1901         (WebCore::ScrollView::updateScrollbars):
1902         * platform/ScrollView.h:
1903         (WebCore::ScrollView::minimumContentsSize):
1904         * rendering/RenderView.cpp:
1905         (WebCore::RenderView::layout):
1906         (WebCore::RenderView::calcDocHeight):
1907         (WebCore::RenderView::calcDocWidth):
1908         * rendering/RenderView.h:
1909         (WebCore::RenderView::docWidth):
1910         (WebCore::RenderView::docHeight):
1911
1912 2009-04-07  Dimitri Glazkov  <dglazkov@chromium.org>
1913
1914         Build fix, not reviewed.
1915
1916         * WebCore.xcodeproj/project.pbxproj: Made ScriptObject.h private.
1917
1918 2009-04-07  Dimitri Glazkov  <dglazkov@chromium.org>
1919
1920         Reviewed by Timothy Hatcher.
1921
1922         https://bugs.webkit.org/show_bug.cgi?id=25063
1923         Refactor InspectorController to use ScriptObject/State.
1924
1925         * GNUmakefile.am: Added ScriptState.cpp.
1926         * WebCore.pro: Ditto.
1927         * WebCore.vcproj/WebCore.vcproj: Ditto.
1928         * WebCore.xcodeproj/project.pbxproj: Ditto.
1929         * WebCoreSources.bkl: Ditto.
1930         * bindings/js/JSInspectorControllerCustom.cpp:
1931         (WebCore::JSInspectorController::addSourceToFrame): Fixed argument index typo.
1932         * bindings/js/ScriptFunctionCall.cpp:
1933         (WebCore::ScriptFunctionCall::call): Added reportExceptions parameter.
1934         (WebCore::ScriptFunctionCall::construct): Ditto.
1935         * bindings/js/ScriptFunctionCall.h: Ditto.
1936         * bindings/js/ScriptObject.cpp:
1937         (WebCore::handleException): Added exception-reporting heloper.
1938         (WebCore::ScriptObject::set): Changed to use handleException.
1939         (WebCore::ScriptGlobalObject::set): Ditto,
1940         * bindings/js/ScriptObject.cpp: Added ScriptGlobalObject.
1941         (WebCore::ScriptGlobalObject::set): Added.
1942         (WebCore::ScriptGlobalObject::getObject): Added.
1943         * bindings/js/ScriptObject.h: Added ScriptGlobalObject decls.
1944         (WebCore::ScriptGlobalObject::ScriptGlobalObject): Added.
1945         * bindings/js/ScriptState.cpp: Added.
1946         * bindings/js/ScriptState.h: Added scriptStateFromPage decl.
1947         * inspector/ConsoleMessage.cpp:
1948         (WebCore::ConsoleMessage::addToConsole): Changed to not report exceptions
1949             to avoid re-entrancy.
1950         * inspector/InspectorController.cpp: Refactored to use ScriptState/Object.
1951         * inspector/InspectorController.h: Ditto.
1952
1953 2009-04-07  Adam Langley  <agl@google.com>
1954
1955         Reviewed by Darin Fisher.
1956
1957         https://bugs.webkit.org/show_bug.cgi?id=25083
1958
1959         Skia was previously calculating the leading value incorrectly, leading
1960         us to add fHeight to get the height of a line of text. Now that Skia
1961         is calculating fLeading correctly, we can remove fHeight.
1962
1963         This doesn't affect any layout tests.
1964
1965         * platform/graphics/chromium/SimpleFontDataLinux.cpp:
1966         (WebCore::SimpleFontData::platformInit):
1967
1968 2009-04-07  Brian Weinstein  <bweinstein@gmail.com>
1969
1970         Reviewed by Darin Adler.
1971
1972         https://bugs.webkit.org/show_bug.cgi?id=24851
1973
1974         This fix removes the status code from the status message in a ResourceResponse, which allows a few more tests in http to pass.
1975
1976         * platform/network/cf/ResourceResponseCFNet.cpp:
1977         (WebCore::ResourceResponse::platformLazyInit):
1978
1979 2009-04-07  Adam Langley  <agl@google.com>
1980
1981         Reviewed by Darin Fisher.
1982
1983         https://bugs.webkit.org/show_bug.cgi?id=25081
1984
1985         Skia is changing from reporting the XRange to reporting the XMin and
1986         XMax.  Obviously these are equivalent, but other users of the metrics
1987         need the two numbers to be separate.
1988
1989         This doesn't affect any layout tests.
1990
1991         * platform/graphics/chromium/SimpleFontDataLinux.cpp:
1992         (WebCore::SimpleFontData::platformInit):
1993
1994 2009-04-07  Adam Roben  <aroben@apple.com>
1995
1996         Make the look of <select>s match the system look on Vista
1997
1998         Reviewed by Dave Hyatt.
1999
2000         * rendering/RenderThemeWin.cpp: Added new constants.
2001         (WebCore::RenderThemeWin::getThemeData): On Vista, use the
2002         CP_DROPDOWNBUTTONRIGHT part for drop down buttons.
2003         (WebCore::RenderThemeWin::paintMenuList): On Vista, use the CP_BORDER
2004         part to draw the border of <select>s.
2005         (WebCore::RenderThemeWin::paintMenuListButton): On Vista, outset the
2006         drop down button to make its border coincide with the <select>'s
2007         border.
2008
2009 2009-04-07  Adam Roben  <aroben@apple.com>
2010
2011         Move isRunningOnVistaOrLater to a shared location
2012
2013         Rubber-stamped in advance by Dave Hyatt.
2014
2015         * WebCore.vcproj/WebCore.vcproj: Added SystemInfo.{cpp,h}, and let VS
2016         have its way with the rest of the file.
2017         * platform/win/ScrollbarThemeWin.cpp: Moved isRunningOnVistaOrLater
2018         from here...
2019         * platform/win/SystemInfo.cpp: Added.
2020         (WebCore::isRunningOnVistaOrLater): ...to here.
2021         * platform/win/SystemInfo.h: Added.
2022
2023 2009-04-07  Paul Godavari  <paul@chromium.org>
2024
2025         Reviewed by Darin Fisher.
2026
2027         https://bugs.webkit.org/show_bug.cgi?id=24692
2028         Enable PopupMenuChromium to handle HTML select popups using native
2029         cocoa controls on the Mac, all other platforms are unchanged.
2030
2031         We also split out the storage container for the popup menu items
2032         so that ChromeClientChromium can access them for forwarding to
2033         the embedding host (Chromium.app or test_shell).
2034
2035         * page/chromium/ChromeClientChromium.h:
2036         * platform/chromium/PopupMenuChromium.cpp:
2037         (WebCore::PopupListBox::items):
2038         (WebCore::PopupContainer::PopupContainer):
2039         (WebCore::PopupContainer::~PopupContainer):
2040         (WebCore::PopupContainer::showPopup):
2041         (WebCore::PopupContainer::showExternal):
2042         (WebCore::PopupContainer::menuItemHeight):
2043         (WebCore::popupData):
2044         (WebCore::PopupListBox::pointToRowIndex):
2045         (WebCore::PopupListBox::getRowBounds):
2046         (WebCore::PopupListBox::isSelectableItem):
2047         (WebCore::PopupListBox::updateFromElement):
2048         (WebCore::PopupListBox::layout):
2049         (WebCore::PopupListBox::clear):
2050         (WebCore::PopupMenu::show):
2051         * platform/chromium/PopupMenuChromium.h:
2052         (WebCore::PopupItem::):
2053         (WebCore::PopupItem::PopupItem):
2054
2055 2009-04-07  Geoffrey Garen  <ggaren@apple.com>
2056
2057         Reviewed by Oliver Hunt.
2058         
2059         Added some double-checking to event handler marking. Now, when the
2060         wrapper that's responsible for marking an event handler's JavaScript
2061         function gets collected, it clears the event handler's JavaScript function
2062         so we won't dereference it after it's collected.
2063         
2064         In theory, we would never dereference a JavaScript event handler after
2065         its node's wrapper was collected anyway, but it's nice to be safe.
2066
2067         * bindings/js/JSDOMApplicationCacheCustom.cpp:
2068         (WebCore::JSDOMApplicationCache::mark):
2069         * bindings/js/JSEventListener.cpp:
2070         (WebCore::JSEventListener::JSEventListener):
2071         (WebCore::JSEventListener::jsFunction):
2072         (WebCore::JSEventListener::invalidateJSFunction):
2073         (WebCore::JSEventListener::markJSFunction):
2074         * bindings/js/JSEventListener.h:
2075         * bindings/js/JSMessagePortCustom.cpp:
2076         (WebCore::JSMessagePort::mark):
2077         * bindings/js/JSNodeCustom.cpp:
2078         (WebCore::markEventListeners):
2079         * bindings/js/JSWorkerContextCustom.cpp:
2080         (WebCore::JSWorkerContext::mark):
2081         * bindings/js/JSWorkerCustom.cpp:
2082         (WebCore::JSWorker::mark):
2083         * bindings/js/JSXMLHttpRequestCustom.cpp:
2084         (WebCore::JSXMLHttpRequest::mark):
2085         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
2086         (WebCore::JSXMLHttpRequestUpload::mark):
2087         * bindings/scripts/CodeGeneratorJS.pm:
2088         * dom/EventListener.h:
2089         (WebCore::EventListener::invalidateJSFunction):
2090         (WebCore::EventListener::markJSFunction):
2091         (WebCore::markIfNotNull):
2092
2093 2009-04-07  David Levin  <levin@chromium.org>
2094
2095         Build fix.
2096
2097         r44280 undid the change in r42268 that made CookieJar.h private.
2098         This redoes the change.
2099
2100         * WebCore.xcodeproj/project.pbxproj:
2101
2102 2009-04-07  Jian Li  <jianli@chromium.org>
2103
2104         Reviewed by Darin Fisher.
2105
2106         Upstream changes to WorkerContextExecutionProxy for enabling V8 preemption.
2107         https://bugs.webkit.org/show_bug.cgi?id=25034
2108
2109         * bindings/v8/WorkerContextExecutionProxy.cpp:
2110         (WebCore::WorkerContextExecutionProxy::evaluate):
2111
2112 2009-04-07  Dan Bernstein  <mitz@apple.com>
2113
2114         Reviewed by Darin Adler.
2115
2116         - fix <rdar://problem/6764359> Thai word selection misbehaves for the
2117           last sentence in the document
2118
2119         Test: editing/selection/thai-word-at-document-end.html
2120
2121         * editing/visible_units.cpp:
2122             - Added a BoundarySearchContextAvailability enum used to indicate
2123             whether the caller to a boundary search function may be able to provide
2124             additional text in the search direction and call again.
2125             - Added a named type for the boundary search function signature. Changed
2126             the signature to take a context availability parameter and a boolean
2127             out parameter indicating whether more context is needed to perform
2128             the search.
2129         (WebCore::previousBoundary): If the beginning of the range was reached
2130             but the last search wanted more context, perform the search again, this
2131             time indicating that there is no earlier text.
2132         (WebCore::nextBoundary): Similarly, in the other direction.
2133         (WebCore::startWordBoundary): Check whether more context may be available
2134             and ask for more context if needed.
2135         (WebCore::endWordBoundary): Ditto.
2136         (WebCore::previousWordPositionBoundary): Ditto.
2137         (WebCore::nextWordPositionBoundary): Ditto.
2138         (WebCore::startSentenceBoundary):  Updated signature.
2139         (WebCore::endSentenceBoundary): Ditto.
2140         (WebCore::previousSentencePositionBoundary): Ditto.
2141         (WebCore::nextSentencePositionBoundary): Ditto.
2142
2143 2009-04-07  Geoffrey Garen  <ggaren@apple.com>
2144
2145         Rubber stamped by Sam Weinig.
2146         
2147         A little renaming:
2148         
2149         function => jsFunction
2150         listener => jsFunction
2151
2152         * bindings/js/JSEventListener.cpp:
2153         (WebCore::JSAbstractEventListener::handleEvent):
2154         (WebCore::JSEventListener::JSEventListener):
2155         (WebCore::JSEventListener::~JSEventListener):
2156         (WebCore::JSEventListener::jsFunction):
2157         (WebCore::JSEventListener::mark):
2158         (WebCore::JSProtectedEventListener::JSProtectedEventListener):
2159         (WebCore::JSProtectedEventListener::~JSProtectedEventListener):
2160         (WebCore::JSProtectedEventListener::jsFunction):
2161         * bindings/js/JSEventListener.h:
2162         (WebCore::JSProtectedEventListener::create):
2163         * bindings/js/JSLazyEventListener.cpp:
2164         (WebCore::JSLazyEventListener::jsFunction):
2165         (WebCore::JSLazyEventListener::parseCode):
2166         * dom/EventListener.h:
2167         (WebCore::EventListener::jsFunction):
2168
2169 2009-04-07  Brady Eidson  <beidson@apple.com>
2170
2171         Reviewed by Darin Adler
2172
2173         While working on <rdar://problem/5968249>, noticed some glaring problems with LocalStorage.
2174
2175         * page/DOMWindow.cpp:
2176         (WebCore::DOMWindow::localStorage): Return the cached m_localStorage object if it exists to 
2177           avoid creating multiple representations for the same underlying StorageArea.
2178         * page/DOMWindow.h:
2179         (WebCore::DOMWindow::optionalLocalStorage): Return m_localStorage, not m_sessionStorage.
2180
2181 2009-04-07  Darin Adler  <darin@apple.com>
2182
2183         Roll out incorrect build fix.
2184
2185         * WebCore.NPAPI.exp: Reverted.
2186
2187 2009-04-07  Darin Adler  <darin@apple.com>
2188
2189         Another build fix.
2190
2191         * WebCore.NPAPI.exp: Added new functions.
2192
2193 2009-04-07  Anders Carlsson  <andersca@apple.com>
2194
2195         Another build fix.
2196         
2197         * plugins/npfunctions.h:
2198
2199 2009-04-07  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2200
2201         Unreviewed build fix. Fix non-Mac builds.
2202
2203         * bridge/npapi.h:
2204
2205 2009-04-07  Simon Fraser  <simon.fraser@apple.com>
2206
2207         Reviewed by Dan Bernstein
2208
2209         https://bugs.webkit.org/show_bug.cgi?id=25082
2210         
2211         Clean up repaint logic when RenderLayers become and stop being composited.
2212
2213         * rendering/RenderLayer.h:
2214         * rendering/RenderLayer.cpp:
2215         (WebCore::RenderLayer::rendererContentChanged):
2216         (WebCore::RenderLayer::repaintIncludingNonCompositingDescendants):
2217         New compositing-only method that repaints a layer and all its non-composited descendants.
2218         Takes a repaintContainer for performance; all the repaints necessarily share the same
2219         repaintContainer.
2220
2221         * rendering/RenderLayerCompositor.h:
2222         * rendering/RenderLayerCompositor.cpp:
2223         (WebCore::RenderLayerCompositor::updateLayerCompositingState):
2224         Rather than use calculateCompositedBounds() to compute the repaint rect (which gave
2225         the wrong answer when the composited layer tree was in flux), use the new
2226         repaintOnCompositingChange() method.
2227         
2228         (WebCore::RenderLayerCompositor::repaintOnCompositingChange):
2229         Call repaintIncludingNonCompositingDescendants(), and if necessary make sure
2230         that the view/layer drawing synchronization happens.
2231         
2232         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
2233         Do a repaintOnCompositingChange() when a layer is going to be composited. This is
2234         a good place because we haven't started to change the compositing tree.
2235         
2236         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
2237         After we've finished updating all the descendant layers, we can do a repaint for
2238         layers that ceased compositing.
2239
2240 2009-04-07  Simon Fraser  <simon.fraser@apple.com>
2241
2242         Reviewed by Dave Hyatt
2243         
2244         https://bugs.webkit.org/show_bug.cgi?id=25069
2245         
2246         Clean up the accelerated compositing code that determines the format of
2247         the GraphicsLayer hierarchy, being more explicit about which parts have
2248         to happen before and after descendant layers have been updated. Also remove
2249         some unhelpful caching of state.
2250
2251         * dom/Document.cpp:
2252         (WebCore::Document::recalcStyle):
2253         Only call updateCompositingLayers() if we know we're not going to be
2254         doing a layout soon.
2255         
2256         * platform/graphics/mac/GraphicsLayerCA.mm:
2257         (WebCore::GraphicsLayerCA::setDrawsContent):
2258         Toggling drawsContent from false to true should do a setNeedsDisplay().
2259         
2260         * rendering/RenderLayer.cpp:
2261         (WebCore::RenderLayer::styleChanged):
2262         updateLayerCompositingState() no longer updates the layer geometry, so
2263         do that here if we're not going to rebuild layers anyway.
2264         Also, updateLayerCompositingState() no longer does a setContentsNeedDisplay,
2265         so do that if the style change indicates that a repaint is required.
2266         
2267         * rendering/RenderLayerBacking.h:
2268         * rendering/RenderLayerBacking.cpp:
2269         (WebCore::RenderLayerBacking::RenderLayerBacking):
2270         (WebCore::RenderLayerBacking::updateAfterLayout):
2271         The 'drawing optimizations' logic has been rolled into updateGraphicsLayerConfiguration()
2272         and updateGraphicsLayerGeometry().
2273         
2274         (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration):
2275         Group that code that decides what GraphicsLayers are needed into this method,
2276         which deals with clipping layers and 'direct compositing': images that can be
2277         rendered via the compositor.
2278         
2279         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2280         Call setDrawsContent() if updateGraphicsLayerConfiguration() didn't already
2281         figure it out for image layers.
2282         
2283         (WebCore::RenderLayerBacking::isSimpleContainerCompositingLayer):
2284         Remove the m_simpleCompositingLayerStatusDirty cache indicator, since we just
2285         computed it every time anyway.
2286         
2287         * rendering/RenderLayerCompositor.h:
2288         * rendering/RenderLayerCompositor.cpp:
2289         (WebCore::RenderLayerCompositor::updateLayerCompositingState):
2290         updateGraphicsLayers() was renamed to updateGraphicsLayerConfiguration(),
2291         which calls clippedByAncestor() etc. itself rather than having everything passed in.
2292         Repaints are taken care of by styleChanged() and setDrawsContent().
2293         
2294         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
2295         !layer->isComposited() && layer->transform() is a synonym for paintsWithTransform().
2296         
2297         (WebCore::RenderLayerCompositor::setCompositingParent):
2298         No need to call updateGraphicsLayerGeometry() here, because we're going to
2299         rebuild layers anyway.
2300         
2301         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
2302         Add comments, and test layerBacking instead of layer->isComposited().
2303
2304 2009-04-07  Anders Carlsson  <andersca@apple.com>
2305
2306         Fix build.
2307         
2308         * WebCore.base.exp:
2309
2310 2009-04-07  Anders Carlsson  <andersca@apple.com>
2311
2312         Reviewed by Sam Weinig.
2313
2314         <rdar://problem/6667001> NPAPI: need NPN_Get/SetValueForURL() and NPN_GetAuthenticationInfo()
2315         
2316         * WebCore.base.exp:
2317         Add symbols needed by WebKit.
2318         
2319         * WebCore.xcodeproj/project.pbxproj:
2320         Make CookieJar a private header.
2321         
2322         * bridge/npapi.h:
2323         Add function definitions.
2324         
2325         * plugins/npfunctions.h:
2326         Fix the NPN_SetValueForURLProcPtr signature.
2327
2328 2009-04-07  Adam Roben  <aroben@apple.com>
2329
2330         Fix <rdar://6520933> REGRESSION (3.2.1-ToT): Scroll bar disappears in
2331         WebView and Bookmarks view after switching theme or turning on High
2332         Contrast mode
2333
2334         Reviewed by Dave Hyatt.
2335
2336         * platform/win/ScrollbarThemeWin.cpp:
2337         (WebCore::ScrollbarThemeWin::themeChanged): Null out scrollbarTheme
2338         after closing it so that we'll re-open the theme next time we paint.
2339
2340 2009-04-07  Adam Roben  <aroben@apple.com>
2341
2342         Small cleanup/correctness fix in ScrollbarThemeWin
2343
2344         Reviewed by Dave Hyatt.
2345
2346         * platform/win/ScrollbarThemeWin.cpp: Removed the now-unused
2347         haveTheme boolean.
2348         (WebCore::checkAndInitScrollbarTheme): Check IsThemeActive() before
2349         calling OpenThemeData. This seems to be what MSDN recommends.
2350         (WebCore::ScrollbarThemeWin::themeChanged): Null-check scrollbarTheme
2351         before closing it, rather than indirectly null-checking it via
2352         checking haveTheme.
2353
2354 2009-04-07  Dan Bernstein  <mitz@apple.com>
2355
2356         Reviewed by John Sullivan.
2357
2358         - when -webkit-line-break: after-white-space is specified but the text
2359           does not auto-wrap, do not shrink the trailing space to fit in the
2360           available width
2361
2362         Test: fast/text/whitespace/nowrap-line-break-after-white-space.html
2363
2364         - when shrinking such trailing space, do not shrink below zero
2365
2366         Covered by existing tests
2367
2368         * rendering/bidi.cpp:
2369         (WebCore::RenderBlock::computeHorizontalPositionsForLine):
2370         (WebCore::RenderBlock::layoutInlineChildren):
2371
2372 2009-04-07  Eric Seidel  <eric@webkit.org>
2373
2374         Reviewed by Darin Adler.
2375
2376         Move RangeBoundaryPoint off of Position, per Darin's suggestion
2377         https://bugs.webkit.org/show_bug.cgi?id=24966
2378
2379         Rename setToChild to setToBeforeChild (since that's what the method does)
2380
2381         * dom/Position.h:
2382         (WebCore::Position::offsetInContainerNode):
2383         * dom/Range.cpp:
2384         (WebCore::Range::insertNode):
2385         (WebCore::Range::selectNodeContents):
2386         (WebCore::boundaryNodeWillBeRemoved):
2387         * dom/Range.h:
2388         (WebCore::Range::startPosition):
2389         (WebCore::Range::endPosition):
2390         * dom/RangeBoundaryPoint.h:
2391         (WebCore::RangeBoundaryPoint::RangeBoundaryPoint):
2392         (WebCore::RangeBoundaryPoint::container):
2393         (WebCore::RangeBoundaryPoint::childBefore):
2394         (WebCore::RangeBoundaryPoint::position):
2395         (WebCore::RangeBoundaryPoint::offset):
2396         (WebCore::RangeBoundaryPoint::clear):
2397         (WebCore::RangeBoundaryPoint::set):
2398         (WebCore::RangeBoundaryPoint::setOffset):
2399         (WebCore::RangeBoundaryPoint::setToBeforeChild):
2400         (WebCore::RangeBoundaryPoint::setToStartOfNode):
2401         (WebCore::RangeBoundaryPoint::setToEndOfNode):
2402         (WebCore::RangeBoundaryPoint::childBeforeWillBeRemoved):
2403         (WebCore::RangeBoundaryPoint::invalidateOffset):
2404
2405 2009-04-07  Eric Seidel  <eric@webkit.org>
2406
2407         Reviewed by Darin Adler.
2408
2409         Add containerNode(), computeOffsetInContainerNode(),
2410         computeNodeBeforePosition() and computeNodeAfterPosition().
2411         https://bugs.webkit.org/show_bug.cgi?id=24763
2412
2413         These functions will replace uses of rangeCompliantPosition()
2414         in future patches.
2415
2416         No changes in behavior, thus no tests.
2417
2418         * dom/Position.cpp:
2419         (WebCore::Position::containerNode):
2420         (WebCore::Position::computeOffsetInContainerNode):
2421         (WebCore::Position::computeNodeBeforePosition):
2422         (WebCore::Position::computeNodeAfterPosition):
2423         (WebCore::Position::anchorType):
2424         * dom/Position.h:
2425         (WebCore::Position::):
2426
2427 2009-04-06  Sam Weinig  <sam@webkit.org>
2428
2429         Reviewed by Mark Rowe.
2430
2431         Bottleneck dispatching mutation events in a new dispatchMutationEvent
2432         function.
2433
2434         * dom/CharacterData.cpp:
2435         (WebCore::CharacterData::dispatchModifiedEvent):
2436         * dom/ContainerNode.cpp:
2437         (WebCore::dispatchChildInsertionEvents):
2438         (WebCore::dispatchChildRemovalEvents):
2439         * dom/Node.cpp:
2440         (WebCore::Node::dispatchSubtreeModifiedEvent):
2441         (WebCore::Node::dispatchMutationEvent):
2442         * dom/Node.h:
2443
2444 2009-04-06  Dimitri Glazkov  <dglazkov@chromium.org>
2445
2446         Reviewed by Darin Fisher.
2447
2448         https://bugs.webkit.org/show_bug.cgi?id=25059
2449         Remove references to dominantScript, getGenericFontForScript.
2450
2451         * platform/graphics/chromium/FontCacheChromiumWin.cpp: Removed references
2452             to getGenericFontForScript.
2453         (WebCore::FontCache::getLastResortFallbackFont): Removed calls to dominantScript.
2454         * platform/graphics/chromium/FontCacheLinux.cpp: Ditto.
2455         * rendering/RenderThemeChromiumLinux.cpp:
2456         (WebCore::defaultGUIFont): Removed Document* arg.
2457         (WebCore::RenderThemeChromiumLinux::systemFont): Ditto.
2458         * rendering/RenderThemeChromiumLinux.h: Ditto.
2459         * rendering/RenderThemeChromiumMac.h: Ditto.
2460         * rendering/RenderThemeChromiumMac.mm: Ditto.
2461         (WebCore::RenderThemeChromiumMac::systemFont): Ditto.
2462         * rendering/RenderThemeChromiumWin.cpp:
2463         (WebCore::defaultGUIFont): Ditto.
2464         (WebCore::RenderThemeChromiumWin::systemFont): Ditto.
2465         * rendering/RenderThemeChromiumWin.h: Ditto.
2466
2467 2009-04-06  Geoffrey Garen  <ggaren@apple.com>
2468
2469         Reviewed by Darin Adler.
2470         
2471         Fixed https://bugs.webkit.org/show_bug.cgi?id=21260
2472         Unbounded memory growth when churning elements with anonymous event handler functions
2473
2474         The problem was that a protected event listener's scope chain would end
2475         up with a reference to the Node protecting it, causing a cycle. The
2476         solution is to stop protecting event listeners and rely on marking instead.
2477
2478         This patch converts most Node event listeners to use marking instead of
2479         GC protection.
2480
2481         * bindings/js/JSDOMBinding.cpp:
2482         (WebCore::isObservableThroughDOM):
2483         (WebCore::markDOMNodesForDocument): Refactored the test for whether a Node
2484         needs marking, and added a case for marking the node in order to mark its
2485         event listeners.
2486
2487         * bindings/js/JSNodeCustom.cpp:
2488         (WebCore::markEventListeners):
2489         (WebCore::JSNode::addEventListener):
2490         (WebCore::JSNode::removeEventListener):
2491         (WebCore::JSNode::mark): Added code to mark a Node's event listeners when
2492         marking the Node. Changed code using protected event listeners to use event
2493         listeners.
2494
2495         * dom/Node.idl: Changed code using protected event listeners to use event
2496         listeners.
2497
2498 2009-04-06  Sam Weinig  <sam@webkit.org>
2499
2500         Reviewed by Darin Adler.
2501
2502         Remove unchecked bool return values for some dispatch event functions.
2503
2504         * dom/Node.cpp:
2505         (WebCore::Node::dispatchSubtreeModifiedEvent):
2506         (WebCore::Node::dispatchUIEvent):
2507         (WebCore::Node::dispatchWebKitAnimationEvent):
2508         (WebCore::Node::dispatchWebKitTransitionEvent):
2509         (WebCore::Node::dispatchProgressEvent):
2510         * dom/Node.h:
2511
2512 2009-04-06  Darin Fisher  <darin@chromium.org>
2513
2514         Reviewed by Dimitri Glazkov.
2515
2516         https://bugs.webkit.org/show_bug.cgi?id=25058
2517         Fix chromium build bustage caused by r42216
2518
2519         * bindings/scripts/CodeGeneratorJS.pm:
2520         * page/DOMWindow.idl:
2521
2522 2009-04-06  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2523
2524         Rubber-stamped by Sam Weinig.
2525
2526         https://bugs.webkit.org/show_bug.cgi?id=20575
2527         No localization in WebKitGtk
2528
2529         * platform/gtk/FileChooserGtk.cpp: Remove usage of glib/gi18n.h,
2530         since there are not translatable strings.
2531         * platform/gtk/LocalizedStringsGtk.cpp: Use the glib i18n header
2532         that is specific for libraries.
2533
2534 2009-04-06  Mike Belshe  <mike@belshe.com>
2535
2536         Reviewed by Dimitri Glazkov.
2537
2538         https://bugs.webkit.org/show_bug.cgi?id=24978
2539         Use custom implementations of a few Node methods so that
2540         we don't over-aggressively create JS wrappers here.
2541
2542         * bindings/v8/custom/V8NodeCustom.cpp: Added custom implementations.
2543         * dom/Node.idl: Removed JSC-specifier, making impl custom for V8 as well.
2544
2545 2009-04-06  Dave Moore  <davemoore@google.com>
2546
2547         Reviewed by Dimitri Glazkov.
2548
2549         https://bugs.webkit.org/show_bug.cgi?id=25031
2550         Make the V8 element collections check for named properties *before*
2551         checking if there are any elements with the same name. Otherwise
2552         it is both incorrect and slow.
2553
2554         Test: fast/dom/HTMLSelectElement/length-not-overridden.html
2555
2556         Both of these interceptors were attempting to find an element in the
2557         collection that had a name or id of the property name before checking
2558         for a JS property with that name.
2559         * bindings/v8/V8Collection.h:
2560         (WebCore::collectionNamedPropertyGetter):
2561         (WebCore::nodeCollectionNamedPropertyGetter):
2562
2563 2009-04-06  Simon Fraser  <simon.fraser@apple.com>
2564
2565         Reviewed by Darin Adler
2566
2567         https://bugs.webkit.org/show_bug.cgi?id=25052
2568         
2569         Pull the call to updateGraphicsLayerGeometry() out of updateGraphicsLayers(),
2570         because we need to call it at the end of rebuildCompositingLayerTree() once
2571         we've determined which descendant layers are composited, otherwise
2572         calculateCompositedBounds() can give the wrong answer.
2573         
2574         Now that updateLayerCompositingState() doesn't end up calling updateGraphicsLayerGeometry(),
2575         call that explicitly from styleChanged(), if we know a layer update is not pending,
2576         and similarly from updateAfterLayout().
2577
2578         Test: compositing/overflow/overflow-positioning.html
2579
2580         * rendering/RenderLayer.cpp:
2581         (WebCore::RenderLayer::styleChanged):
2582         * rendering/RenderLayerBacking.cpp:
2583         (WebCore::RenderLayerBacking::updateAfterLayout):
2584         (WebCore::RenderLayerBacking::updateGraphicsLayers):
2585         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2586         * rendering/RenderLayerCompositor.cpp:
2587         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
2588
2589 2009-04-06  Mike Belshe  <mike@belshe.com>
2590
2591         Reviewed by Alexey Proskuryakov.
2592
2593         Add accessors to AtomicString which take String/const char* arguments
2594         so that we don't accidentally thrash the AtomicString table.
2595
2596         https://bugs.webkit.org/show_bug.cgi?id=24979
2597
2598         * platform/text/AtomicString.h:
2599
2600 2009-04-03  Holger Hans Peter Freyther  <zecke@selfish.org>
2601
2602         Reviewed by Simon Hausmann.
2603
2604         Make col and row work in WebCore/manual-tests/cursor.html. The issue
2605         was spotted in the WebKit inspector.
2606
2607         * platform/gtk/CursorGtk.cpp:
2608         (WebCore::columnResizeCursor):
2609         (WebCore::rowResizeCursor):
2610
2611 2009-04-06  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2612
2613         Reviewed by Simon Hausmann.
2614
2615         [Qt] Don't show and hide the platformPluginWidget, as it's our QWebView
2616
2617         * plugins/mac/PluginViewMac.cpp:
2618         (WebCore::PluginView::show):
2619         (WebCore::PluginView::hide):
2620         (WebCore::PluginView::setParentVisible):
2621
2622 2009-04-06  Simon Hausmann  <simon.hausmann@nokia.com>
2623
2624         Reviewed by Tor Arne Vestbø.
2625
2626         Add new files to the Qt build.
2627         Export helper function from the Qt JSC binding, needed in WebKit/qt.
2628
2629         * WebCore.pro: Add new files.
2630         * bridge/qt/qt_runtime.h: Declare convertQVariantToValue.
2631
2632 2009-04-06  Simon Hausmann  <simon.hausmann@nokia.com>
2633
2634         Reviewed by Tor Arne Vestbø.
2635
2636         Changed ScriptFunctionCall's last argument from a const char* as the function name to a String.
2637
2638         Internally the function name is stored as a WebCore::String and the Qt port wants to use this
2639         constructor programmatically where the function name is also a WebCore::String.
2640
2641         * bindings/js/ScriptFunctionCall.cpp:
2642         (WebCore::ScriptFunctionCall::ScriptFunctionCall):
2643         * bindings/js/ScriptFunctionCall.h:
2644
2645 2009-04-06  Mike Belshe <mike@belshe.com>
2646
2647         Reviewed by Eric Seidel.
2648
2649         HTMLCanvasElement crash when ImageBuffer creation fails.
2650         https://bugs.webkit.org/show_bug.cgi?id=23212
2651
2652         Check for NULL before using the ImageBuffer as we might
2653         be low on memory and creation may have failed.
2654
2655         Test case creation blocked by:
2656         https://bugs.webkit.org/show_bug.cgi?id=25055
2657
2658         * html/HTMLCanvasElement.cpp:
2659         (WebCore::HTMLCanvasElement::createImageBuffer):
2660
2661 2009-04-05  Geoffrey Garen  <ggaren@apple.com>
2662
2663         [Originally] Reviewed by Sam Weinig.
2664
2665         Rolled back in r42214 with crashes fixed.
2666
2667         [Removed irrelevant ExecState* parameter from event handler registration code.]
2668         
2669         [No change in behavior.]
2670
2671         * bindings/js/JSDOMApplicationCacheCustom.cpp:
2672         (WebCore::JSDOMApplicationCache::addEventListener):
2673         (WebCore::JSDOMApplicationCache::removeEventListener):
2674         * bindings/js/JSDOMGlobalObject.cpp:
2675         (WebCore::JSDOMGlobalObject::findOrCreateJSProtectedEventListener):
2676         (WebCore::JSDOMGlobalObject::findJSEventListener):
2677         (WebCore::JSDOMGlobalObject::findOrCreateJSEventListener):
2678         * bindings/js/JSDOMGlobalObject.h:
2679         * bindings/js/JSDOMWindowCustom.cpp:
2680         (WebCore::JSDOMWindow::addEventListener):
2681         * bindings/js/JSMessagePortCustom.cpp:
2682         (WebCore::JSMessagePort::addEventListener):
2683         (WebCore::JSMessagePort::removeEventListener):
2684         * bindings/js/JSNodeCustom.cpp:
2685         (WebCore::JSNode::addEventListener):
2686         * bindings/js/JSSVGElementInstanceCustom.cpp:
2687         (WebCore::JSSVGElementInstance::addEventListener):
2688         * bindings/js/JSWorkerContextCustom.cpp:
2689         (WebCore::JSWorkerContext::addEventListener):
2690         (WebCore::JSWorkerContext::removeEventListener):
2691         * bindings/js/JSWorkerCustom.cpp:
2692         (WebCore::JSWorker::addEventListener):
2693         (WebCore::JSWorker::removeEventListener):
2694         * bindings/js/JSXMLHttpRequestCustom.cpp:
2695         (WebCore::JSXMLHttpRequest::addEventListener):
2696         (WebCore::JSXMLHttpRequest::removeEventListener):
2697         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
2698         (WebCore::JSXMLHttpRequestUpload::addEventListener):
2699         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
2700         * bindings/scripts/CodeGeneratorJS.pm:
2701
2702 2009-04-05  Erik L. Bunce  <elbunce@xendom.com>
2703
2704         Reviewed by Simon Hausmann.
2705
2706         https://bugs.webkit.org/show_bug.cgi?id=25050
2707
2708         Fix an assert failure when dropping an 'empty' text/uri-list on a QWebView. 
2709
2710         * platform/qt/DragDataQt.cpp:
2711         (WebCore::DragData::asURL):
2712
2713 2009-04-05  Simon Hausmann  <hausmann@webkit.org>
2714
2715         Fix the Qt build.
2716
2717         * bridge/qt/qt_runtime.h:
2718         (JSC::Bindings::QtRuntimeMethod::createPrototype): Take the JSGlobalObject
2719         as second argument.
2720
2721 2009-04-04  Kevin Ollivier  <kevino@theolliviers.com>
2722
2723         Build fixes for wxMac/Tiger.
2724
2725         * platform/wx/wxcode/mac/carbon/fontprops.cpp:
2726         (wxFontProperties::wxFontProperties):
2727         * rendering/break_lines.cpp:
2728         (WebCore::nextBreakablePosition):
2729         * webcore-wx.bkl:
2730
2731 2009-04-04  Simon Fraser  <simon.fraser@apple.com>
2732
2733         Reviewed by Cameron Zwarich
2734
2735         https://bugs.webkit.org/show_bug.cgi?id=24648
2736         
2737         Ensure that mapPoint(const IntPoint&) calls the FloatPoint
2738         version to avoid infinite recursion.
2739         
2740         No test because mapPoint(const IntPoint&) isn't ever called
2741         on Mac, so I can't reproduce.
2742         
2743         * platform/graphics/transforms/TransformationMatrix.h:
2744         (WebCore::TransformationMatrix::mapPoint):
2745
2746 2009-04-04  Dan Bernstein  <mitz@apple.com>
2747
2748         Reviewed by Mark Rowe.
2749
2750         - fix <rdar://problem/6757862> REGRESSION: Cannot use the mouse to place
2751           the insertion point inside a Thai character
2752
2753         Test: fast/text/international/thai-offsetForPosition-inside-character.html
2754
2755         * platform/graphics/mac/CoreTextController.cpp:
2756         (WebCore::CoreTextController::offsetForPosition): Changed to use
2757         cursorMovementIterator instead of characterBreakIterator, allowing this
2758         function to return a valid cursor position even if it is not at
2759         a character boundary.
2760
2761 2009-04-04  Dan Bernstein  <mitz@apple.com>
2762
2763         Reviewed by Mark Rowe.
2764
2765         - fix an assertion failure when clicking at the beginning of a
2766           glyph cluster at the beginning of a text run
2767
2768         Test: fast/text/offsetForPosition-cluster-at-zero.html
2769
2770         * platform/graphics/mac/CoreTextController.cpp:
2771         (WebCore::CoreTextController::offsetForPosition): Corrected the bound
2772         check on firstGlyphBeforeCluster, letting it be 0 or -1, but not less
2773         than -1.
2774
2775 2009-04-03  Brian Weinstein  <bweinstein@gmail.com>
2776
2777         Allows 16 HTML/CSS standard colors to be shown as swatch backgrounds
2778         when the names are given.
2779
2780         https://bugs.webkit.org/show_bug.cgi?id=25044
2781
2782         Reviewed by Timothy Hatcher.
2783
2784         * inspector/front-end/StylesSidebarPane.js:
2785         (WebInspector.StylePropertyTreeElement.prototype.updateTitle):
2786
2787 2009-04-03  Sam Weinig  <sam@webkit.org>
2788
2789         Reviewed by Darin Adler.
2790
2791         <rdar://problem/6330929>
2792         https://bugs.webkit.org/show_bug.cgi?id=21456
2793
2794         Don't update the document pointer for all inactive windows on navigations.
2795         This change causes us to differ slightly from Firefox when accessing the
2796         document from within a closure tied to a navigated context, but as all
2797         browsers differ on this edge case, I don't foresee compatibility issues.
2798
2799         Test: http/tests/security/cross-frame-access-document-direct.html
2800
2801         * bindings/js/JSDOMWindowBase.cpp:
2802         (WebCore::JSDOMWindowBase::~JSDOMWindowBase):
2803         * bindings/js/ScriptController.cpp:
2804         (WebCore::ScriptController::clearWindowShell):
2805         (WebCore::ScriptController::initScript):
2806         (WebCore::ScriptController::updateDocument):
2807         * bindings/js/ScriptController.h:
2808
2809 2009-04-03  Chris Marrin  <cmarrin@apple.com>
2810
2811         Reviewed by Simon Fraser.
2812
2813         Test: transitions/bad-transition-shorthand-crash.html
2814
2815         Fixed https://bugs.webkit.org/show_bug.cgi?id=24787.
2816
2817         We were starting transitions with 0 duration and delay, which is 
2818         useless. With accelerated compositing on, this went through a code
2819         path that tried to use m_toStyle, which never got set because the 
2820         transitions was short circuited before it had a chance to. So I
2821         both protect against using that null pointer and avoid starting
2822         the transition in the first place.
2823
2824         * page/animation/CompositeAnimation.cpp:
2825         (WebCore::CompositeAnimationPrivate::updateTransitions):
2826         * page/animation/ImplicitAnimation.cpp:
2827         (WebCore::ImplicitAnimation::blendPropertyValueInStyle):
2828
2829 2009-04-03  Timothy Hatcher  <timothy@apple.com>
2830
2831         Fixes a bug where you could not type any more in the Web Inspector's
2832         search field after the first match is selected in the Resources panel.
2833
2834         https://bugs.webkit.org/show_bug.cgi?id=23982
2835         rdar://problem/6592367
2836
2837         Reviewed by Darin Adler.
2838
2839         * inspector/front-end/SourceView.js:
2840         (WebInspector.SourceView.prototype._jumpToSearchResult): Use the
2841         window object of the frame to set the selection, not the main window.
2842
2843 2009-04-03  Sam Weinig  <sam@webkit.org>
2844
2845         Reviewed by Anders Carlsson.
2846
2847         Fix for https://bugs.webkit.org/show_bug.cgi?id=22081
2848         <rdar://problem/6346030>
2849         Don't allow overriding the return value of window.location.
2850
2851         Tests: fast/dom/Window/Location/location-override-toString-on-proto-using-defineGetter.html
2852                fast/dom/Window/Location/location-override-toString-on-proto-using-with.html
2853                fast/dom/Window/Location/location-override-toString-on-proto.html
2854                fast/dom/Window/Location/location-override-toString-using-defineGetter.html
2855                fast/dom/Window/Location/location-override-toString-using-with.html
2856                fast/dom/Window/Location/location-override-toString.html
2857                fast/dom/Window/Location/location-override-valueOf-on-proto-using-defineGetter.html
2858                fast/dom/Window/Location/location-override-valueOf-on-proto-using-with.html
2859                fast/dom/Window/Location/location-override-valueOf-on-proto.html
2860                fast/dom/Window/Location/location-override-valueOf-using-defineGetter.html
2861                fast/dom/Window/Location/location-override-valueOf-using-with.html
2862                fast/dom/Window/Location/location-override-valueOf.html
2863                fast/dom/Window/Location/window-override-location-using-defineGetter.html
2864                fast/dom/Window/Location/window-override-window-using-defineGetter.html
2865                fast/dom/Window/Location/window-shadow-location-using-js-object-with-toString.html
2866                fast/dom/Window/Location/window-shadow-location-using-string.html
2867                fast/dom/Window/Location/window-shadow-window-using-js-object-with-location-field.html
2868
2869         * bindings/js/JSDOMWindowCustom.cpp:
2870         (WebCore::JSDOMWindow::defineGetter):
2871         * bindings/js/JSLocationCustom.cpp:
2872         (WebCore::JSLocation::customPut):
2873         (WebCore::JSLocation::defineGetter):
2874         (WebCore::JSLocationPrototype::customPut):
2875         (WebCore::JSLocationPrototype::defineGetter):
2876         * bindings/scripts/CodeGeneratorJS.pm:
2877         * page/Location.idl:
2878
2879 2009-04-03  Geoffrey Garen  <ggaren@apple.com>
2880
2881         Rolled out r42214 since it seems to have caused crashes on the buildbot.
2882
2883         * bindings/js/JSDOMApplicationCacheCustom.cpp:
2884         (WebCore::JSDOMApplicationCache::addEventListener):
2885         (WebCore::JSDOMApplicationCache::removeEventListener):
2886         * bindings/js/JSDOMGlobalObject.cpp:
2887         (WebCore::JSDOMGlobalObject::findOrCreateJSProtectedEventListener):
2888         (WebCore::JSDOMGlobalObject::findJSEventListener):
2889         (WebCore::JSDOMGlobalObject::findOrCreateJSEventListener):
2890         * bindings/js/JSDOMGlobalObject.h:
2891         * bindings/js/JSDOMWindowCustom.cpp:
2892         (WebCore::JSDOMWindow::addEventListener):
2893         * bindings/js/JSMessagePortCustom.cpp:
2894         (WebCore::JSMessagePort::addEventListener):
2895         (WebCore::JSMessagePort::removeEventListener):
2896         * bindings/js/JSNodeCustom.cpp:
2897         (WebCore::JSNode::addEventListener):
2898         (WebCore::JSNode::removeEventListener):
2899         * bindings/js/JSSVGElementInstanceCustom.cpp:
2900         (WebCore::JSSVGElementInstance::addEventListener):
2901         * bindings/js/JSWorkerContextCustom.cpp:
2902         (WebCore::JSWorkerContext::addEventListener):
2903         (WebCore::JSWorkerContext::removeEventListener):
2904         * bindings/js/JSWorkerCustom.cpp:
2905         (WebCore::JSWorker::addEventListener):
2906         (WebCore::JSWorker::removeEventListener):
2907         * bindings/js/JSXMLHttpRequestCustom.cpp:
2908         (WebCore::JSXMLHttpRequest::addEventListener):
2909         (WebCore::JSXMLHttpRequest::removeEventListener):
2910         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
2911         (WebCore::JSXMLHttpRequestUpload::addEventListener):
2912         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
2913         * bindings/scripts/CodeGeneratorJS.pm:
2914
2915 2009-04-03  Sam Weinig  <sam@webkit.org>
2916
2917         Reviewed by Oliver Hunt.
2918
2919         Fix for <rdar://problem/6476356>
2920         https://bugs.webkit.org/show_bug.cgi?id=23148
2921
2922         - Use the window object the Location and History objects are directly associated with
2923           instead of the lexical global object to pick the object prototype to serve as the
2924           base of the their respective prototype chains.
2925         - Re-factor as necessary to allow passing the correct global object to the createPrototype
2926           functions.
2927
2928         Tests: http/tests/security/cross-frame-access-history-prototype.html
2929                http/tests/security/cross-frame-access-location-prototype.html
2930
2931         * bindings/js/JSAudioConstructor.cpp:
2932         (WebCore::JSAudioConstructor::JSAudioConstructor):
2933         * bindings/js/JSDOMBinding.cpp:
2934         (WebCore::getCachedDOMStructure):
2935         (WebCore::cacheDOMStructure):
2936         * bindings/js/JSDOMBinding.h:
2937         (WebCore::getDOMStructure):
2938         (WebCore::getDOMPrototype):
2939         * bindings/js/JSDOMWindowCustom.cpp:
2940         (WebCore::JSDOMWindow::history):
2941         (WebCore::JSDOMWindow::location):
2942         * bindings/js/JSDocumentCustom.cpp:
2943         (WebCore::JSDocument::location):
2944         * bindings/js/JSImageConstructor.cpp:
2945         (WebCore::JSImageConstructor::JSImageConstructor):
2946         * bindings/js/JSMessageChannelConstructor.cpp:
2947         (WebCore::JSMessageChannelConstructor::JSMessageChannelConstructor):
2948         * bindings/js/JSNamedNodesCollection.h:
2949         (WebCore::JSNamedNodesCollection::createPrototype):
2950         * bindings/js/JSOptionConstructor.cpp:
2951         (WebCore::JSOptionConstructor::JSOptionConstructor):
2952         * bindings/js/JSRGBColor.h:
2953         (WebCore::JSRGBColor::createPrototype):
2954         * bindings/js/JSWebKitCSSMatrixConstructor.cpp:
2955         (WebCore::JSWebKitCSSMatrixConstructor::JSWebKitCSSMatrixConstructor):
2956         * bindings/js/JSWebKitPointConstructor.cpp:
2957         (WebCore::JSWebKitPointConstructor::JSWebKitPointConstructor):
2958         * bindings/js/JSWorkerConstructor.cpp:
2959         (WebCore::JSWorkerConstructor::JSWorkerConstructor):
2960         * bindings/js/JSXMLHttpRequestConstructor.cpp:
2961         (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
2962         * bindings/js/JSXSLTProcessorConstructor.cpp:
2963         (WebCore::JSXSLTProcessorConstructor::JSXSLTProcessorConstructor):
2964         * bindings/scripts/CodeGeneratorJS.pm:
2965         * bridge/objc/objc_runtime.h:
2966         (JSC::Bindings::ObjcFallbackObjectImp::createPrototype):
2967         * bridge/runtime_array.h:
2968         (JSC::RuntimeArray::createPrototype):
2969         * bridge/runtime_method.h:
2970         (JSC::RuntimeMethod::createPrototype):
2971         * bridge/runtime_object.h:
2972         (JSC::RuntimeObjectImp::createPrototype):
2973         * page/DOMWindow.idl:
2974
2975 2009-04-03  Jian Li  <jianli@chromium.org>
2976
2977         Reviewed by Darin Fisher.
2978
2979         https://bugs.webkit.org/show_bug.cgi?id=25009
2980         Upstream changes to WorkerContextExecutionProxy for V8 bindings in order to use V8EventListenerList as container.
2981
2982         * bindings/v8/WorkerContextExecutionProxy.cpp:
2983         (WebCore::WorkerContextExecutionProxy::WorkerContextExecutionProxy):
2984         (WebCore::WorkerContextExecutionProxy::dispose):
2985         (WebCore::WorkerContextExecutionProxy::FindOrCreateEventListener):
2986         (WebCore::WorkerContextExecutionProxy::RemoveEventListener):
2987         * bindings/v8/WorkerContextExecutionProxy.h:
2988
2989 2009-04-03  Geoffrey Garen  <ggaren@apple.com>
2990
2991         Reviewed by Sam Weinig.
2992
2993         Removed irrelevant ExecState* parameter from event handler registration code.
2994         
2995         No change in behavior.
2996
2997         * bindings/js/JSDOMApplicationCacheCustom.cpp:
2998         (WebCore::JSDOMApplicationCache::addEventListener):
2999         (WebCore::JSDOMApplicationCache::removeEventListener):
3000         * bindings/js/JSDOMGlobalObject.cpp:
3001         (WebCore::JSDOMGlobalObject::findOrCreateJSProtectedEventListener):
3002         (WebCore::JSDOMGlobalObject::findJSEventListener):
3003         (WebCore::JSDOMGlobalObject::findOrCreateJSEventListener):
3004         * bindings/js/JSDOMGlobalObject.h:
3005         * bindings/js/JSDOMWindowCustom.cpp:
3006         (WebCore::JSDOMWindow::addEventListener):
3007         * bindings/js/JSMessagePortCustom.cpp:
3008         (WebCore::JSMessagePort::addEventListener):
3009         (WebCore::JSMessagePort::removeEventListener):
3010         * bindings/js/JSNodeCustom.cpp:
3011         (WebCore::JSNode::addEventListener):
3012         (WebCore::JSNode::removeEventListener):
3013         * bindings/js/JSSVGElementInstanceCustom.cpp:
3014         (WebCore::JSSVGElementInstance::addEventListener):
3015         * bindings/js/JSWorkerContextCustom.cpp:
3016         (WebCore::JSWorkerContext::addEventListener):
3017         (WebCore::JSWorkerContext::removeEventListener):
3018         * bindings/js/JSWorkerCustom.cpp:
3019         (WebCore::JSWorker::addEventListener):
3020         (WebCore::JSWorker::removeEventListener):
3021         * bindings/js/JSXMLHttpRequestCustom.cpp:
3022         (WebCore::JSXMLHttpRequest::addEventListener):
3023         (WebCore::JSXMLHttpRequest::removeEventListener):
3024         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
3025         (WebCore::JSXMLHttpRequestUpload::addEventListener):
3026         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
3027         * bindings/scripts/CodeGeneratorJS.pm:
3028
3029 2009-04-03  Dan Bernstein  <mitz@apple.com>
3030
3031         Reviewed by Simon Fraser.
3032
3033         - fix <rdar://problem/6634771> Under full-page zoom, cannot scroll
3034           MobileMe contact list
3035
3036         Test: fast/css/zoom-in-length-round-trip.html
3037
3038         * dom/Element.cpp:
3039         (WebCore::adjustForLocalZoom): For zoom factors greater than 1, ensure
3040         that the returned value is equal to the original unscaled value.
3041         (WebCore::adjustForAbsoluteZoom): Ditto.
3042
3043 2009-04-03  Chris Marrin  <cmarrin@apple.com>
3044
3045         Reviewed by David Hyatt.
3046
3047         Fixed https://bugs.webkit.org/show_bug.cgi?id=24941
3048
3049         This fix essentially does a -viewWillDraw call for layout. It adds 
3050         a CFRunLoopObserver which performs layout just before drawing on the 
3051         Mac platform. This makes sure layout is complete before rendering and 
3052         avoids a flash.
3053
3054         * page/ChromeClient.h:
3055         (WebCore::ChromeClient::scheduleViewUpdate):
3056         * rendering/RenderLayerCompositor.cpp:
3057         (WebCore::RenderLayerCompositor::setCompositingLayersNeedUpdate):
3058         (WebCore::RenderLayerCompositor::scheduleViewUpdate):
3059         * rendering/RenderLayerCompositor.h:
3060
3061 2009-04-02  Simon Fraser  <simon.fraser@apple.com>
3062
3063         Reviewed by Dan Bernstein
3064
3065         https://bugs.webkit.org/show_bug.cgi?id=24648
3066
3067         Optimize mapPoint(), mapRect() and mapQuad() for identity matrix and translations.
3068         
3069         * platform/graphics/transforms/TransformationMatrix.cpp:
3070         (WebCore::TransformationMatrix::mapPoint):
3071         (WebCore::TransformationMatrix::mapRect):
3072         (WebCore::TransformationMatrix::mapQuad):
3073         * platform/graphics/transforms/TransformationMatrix.h:
3074         (WebCore::TransformationMatrix::mapPoint):
3075
3076 2009-04-02  Simon Fraser  <simon.fraser@apple.com>
3077
3078         Reviewed by Dan Bernstein
3079
3080         https://bugs.webkit.org/show_bug.cgi?id=25018
3081         
3082         Add containsPoint() and containsQuad() methods to FloatQuad.
3083
3084         * platform/graphics/FloatQuad.cpp:
3085         (WebCore::dot):
3086         (WebCore::isPointInTriangle):
3087         (WebCore::FloatQuad::containsPoint):
3088         (WebCore::FloatQuad::containsQuad):
3089         * platform/graphics/FloatQuad.h:
3090
3091 2009-04-03  Kevin Decker  <kdecker@apple.com>
3092
3093         Reviewed by Darin.
3094
3095         *  loader/ProgressTracker.cpp: Included DocumentLoader.h
3096         (WebCore::ProgressTracker::incrementProgress): Limit the 50%-clamp rule to 
3097         documents that use WebCore's layout system.
3098
3099 2009-04-03  Eric Carlson  <eric.carlson@apple.com>
3100
3101         Reviewed by Simon Fraser.
3102
3103         https://bugs.webkit.org/show_bug.cgi?id=25029
3104         <rdar://problem/6336092> REGRESSION: movie does not resize correctly
3105
3106         Test: media/video-size-intrinsic-scale.html
3107
3108         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3109         (WebCore::MediaPlayerPrivate::naturalSize): Use QTMovieCurrentSizeAttribute instead 
3110         of QTMovieNaturalSizeAttribute so we return the correct size for movies saved
3111         with a non-default matrix.
3112         (WebCore::MediaPlayerPrivate::setSize): Don't resize the QTMovieView
3113         because [QTMovieView setFrame] also resizes the movie itself, and as
3114         the renderer calls setSize immediately when a movie reports a size change
3115         (QTMovieSizeDidChangeNotification) we can get into a feedback loop
3116         observing the size change and resetting the size, and this can cause
3117         QuickTime to miss correctly setting a movie's size when the media size
3118         changes after opening (as happens with an rtsp movie once the server sends
3119         the track sizes). Instead, remember the size passed to paint() and 
3120         resize the view when it changes.
3121         (WebCore::MediaPlayerPrivate::paint): Resize the view when passed a new size.
3122
3123         * platform/graphics/win/QTMovieWin.cpp:
3124         (QTMovieWin::getNaturalSize): Use GetMovieBox instead of GetMovieNaturalBoundsRect
3125         so we return the correct size for movies saved with non-default matrix.
3126
3127 2009-04-03  Darin Fisher  <darin@chromium.org>
3128
3129         Reviewed by Darin Adler.
3130
3131         Restore FrameLoader::policyDocumentLoader to fix the Chromium build.
3132         https://bugs.webkit.org/show_bug.cgi?id=25028
3133
3134         * loader/FrameLoader.h:
3135         (WebCore::FrameLoader::policyDocumentLoader):
3136
3137 2009-04-02  Michael Nordman  <michaeln@google.com>
3138
3139         Reviewed by Alexey Proskuryakov.
3140
3141         Use long long, not int64, when working in webcore (sorry).
3142         https://bugs.webkit.org/show_bug.cgi?id=25011
3143
3144         No change in functionality, so no tests.
3145
3146         * platform/network/chromium/ResourceResponse.h:
3147         (WebCore::ResourceResponse::getAppCacheID):
3148         (WebCore::ResourceResponse::setAppCacheID):
3149
3150 2009-04-03  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
3151
3152         Reviewed by Holger Freyther.
3153
3154         Remove pre-processor checks for GTK+ >= 2.10, since we now require
3155         at least that version.
3156
3157         * platform/graphics/gtk/FontPlatformDataGtk.cpp:
3158         (WebCore::FontPlatformData::FontPlatformData):
3159         * platform/gtk/ContextMenuItemGtk.cpp:
3160         (WebCore::gtkStockIDFromContextMenuAction):
3161         * platform/gtk/KeyEventGtk.cpp:
3162         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
3163         * platform/gtk/LocalizedStringsGtk.cpp:
3164         (WebCore::contextMenuItemTagSelectAll):
3165         * platform/gtk/MouseEventGtk.cpp:
3166         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
3167         * platform/gtk/PasteboardGtk.cpp:
3168         (WebCore::Pasteboard::writeSelection):
3169         (WebCore::Pasteboard::documentFragment):
3170         * platform/gtk/WheelEventGtk.cpp:
3171         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
3172
3173 2009-04-02  Simon Fraser  <simon.fraser@apple.com>
3174
3175         Reviewed by Dan Bernstein
3176         
3177         https://bugs.webkit.org/show_bug.cgi?id=25021
3178         
3179         Fix repainting an element with a reflection and transform after layout.
3180         Telling the reflection to repaint directly is wrong, because, with
3181         LayoutState enabled, it only takes the reflection's transform into account,
3182         not that of the element. We can fix this, and keep the benefits of LayoutState,
3183         by computing the reflected repaint rect, and repainting that using the original
3184         renderer.
3185
3186         Test: fast/repaint/reflection-repaint-test.html
3187
3188         * rendering/RenderBlock.cpp:
3189         (WebCore::RenderBlock::layoutBlock):
3190
3191 2009-04-02  Simon Fraser  <simon.fraser@apple.com>
3192
3193         Reviewed by Dan Bernstein
3194         
3195         https://bugs.webkit.org/show_bug.cgi?id=23307
3196         
3197         When repainting during layout (when LayoutState is enabled), we need
3198         to apply the transform to the dirty rect, before applying x(), y() and
3199         the offset storted in the LayoutState.
3200         
3201         Also bypass LayoutState in mapLocalToContainer() if we have a repaintContainer,
3202         since LayoutState is always root-relative.
3203
3204         Test: fast/repaint/transform-layout-repaint.html
3205
3206         * rendering/RenderBox.cpp:
3207         (WebCore::RenderBox::mapLocalToContainer):
3208         (WebCore::RenderBox::computeRectForRepaint):
3209
3210 2009-04-02  Mark Rowe  <mrowe@apple.com>
3211
3212         Fix the Mac build after r42191.
3213
3214         * WebCore.base.exp:
3215
3216 2009-04-02  Mark Rowe  <mrowe@apple.com>
3217
3218         Fix Windows build after r42190.
3219
3220         * page/EventHandler.cpp:
3221         (WebCore::EventHandler::keyEvent):  Update to use the new name of the constant.
3222
3223 2009-04-02  Darin Adler  <darin@apple.com>
3224
3225         Reviewed by Brady Eidson.
3226
3227         <rdar://problem/6625840> Previous Page isn't loaded after hitting back button at http://www.breakingnews.ie/
3228
3229         Test: http/tests/navigation/onload-navigation-iframe-2.html
3230
3231         * html/HTMLFrameElement.cpp:
3232         (WebCore::HTMLFrameElement::HTMLFrameElement): Removed unneeded createdByParser flag.
3233         * html/HTMLFrameElement.h: Ditto.
3234         * html/HTMLFrameElementBase.cpp:
3235         (WebCore::HTMLFrameElementBase::HTMLFrameElementBase): Ditto.
3236         * html/HTMLFrameElementBase.h: Ditto.
3237         * html/HTMLFrameOwnerElement.cpp:
3238         (WebCore::HTMLFrameOwnerElement::HTMLFrameOwnerElement): Ditto.
3239         * html/HTMLFrameOwnerElement.h: Ditto.
3240         * html/HTMLIFrameElement.cpp:
3241         (WebCore::HTMLIFrameElement::HTMLIFrameElement): Ditto.
3242         * html/HTMLIFrameElement.h: Ditto.
3243         * html/HTMLPlugInElement.cpp:
3244         (WebCore::HTMLPlugInElement::HTMLPlugInElement): Ditto.
3245
3246         * loader/FrameLoader.cpp:
3247         (WebCore::FrameLoader::submitForm): Removed unneeded check of the createdByParser flag.
3248         The original change that introduced this, http://trac.webkit.org/changeset/25410, does
3249         not make it clear why this check was needed. And it seems it is not needed.
3250
3251 2009-04-02  Adele Peterson  <adele@apple.com>
3252
3253         Reviewed by Darin Adler.
3254
3255         Add a way to get a list of focusable nodes.
3256
3257         * dom/Document.cpp:
3258         (WebCore::Document::setFocusedNode):
3259         (WebCore::Document::getFocusableNodes):
3260         * dom/Document.h:
3261
3262 2009-04-02  Darin Adler  <darin@apple.com>
3263
3264         Reviewed by Sam Weinig.
3265
3266         <rdar://problem/6654255> crash due to null FrameView in EventHandler
3267
3268         Lots of code was added to EventHandler that used view() and page() without
3269         null checking, but both of those can become null due to the frame lifetime.
3270
3271         * page/EventHandler.cpp:
3272         (WebCore::EventHandler::handleMousePressEventSingleClick):
3273         (WebCore::EventHandler::eventMayStartDrag):
3274         (WebCore::EventHandler::handleAutoscroll):
3275         (WebCore::EventHandler::autoscrollTimerFired):
3276         (WebCore::EventHandler::setPanScrollCursor):
3277         (WebCore::EventHandler::allowDHTMLDrag):
3278         (WebCore::EventHandler::hitTestResultAtPoint):
3279         (WebCore::EventHandler::stopAutoscrollTimer):
3280         (WebCore::EventHandler::selectCursor):
3281         (WebCore::EventHandler::handleMousePressEvent):
3282         (WebCore::EventHandler::handleMouseMoveEvent):
3283         (WebCore::EventHandler::dispatchDragEvent):
3284         (WebCore::EventHandler::prepareMouseEvent):
3285         (WebCore::EventHandler::dispatchMouseEvent):
3286         (WebCore::EventHandler::handleWheelEvent):
3287         (WebCore::EventHandler::hoverTimerFired):
3288         (WebCore::EventHandler::keyEvent):
3289         (WebCore::EventHandler::dragHysteresisExceeded):
3290         (WebCore::EventHandler::shouldDragAutoNode):
3291         (WebCore::EventHandler::handleDrag):
3292         (WebCore::EventHandler::handleTextInputEvent):
3293         (WebCore::EventHandler::addPendingFrameUnloadEventCount):
3294         (WebCore::EventHandler::removePendingFrameUnloadEventCount):
3295         (WebCore::EventHandler::clearPendingFrameUnloadEventCount):
3296         (WebCore::EventHandler::addPendingFrameBeforeUnloadEventCount):
3297         (WebCore::EventHandler::removePendingFrameBeforeUnloadEventCount):
3298         (WebCore::EventHandler::clearPendingFrameBeforeUnloadEventCount):
3299         Added null checks for view() and page(). Made minor code cleanups.
3300
3301 2009-04-02  David Hyatt  <hyatt@apple.com>
3302
3303         Reviewed by Oliver Hunt.
3304
3305         Fix regression in <object> layout test.  Make sure that even though a 404 image loads, that <object>
3306         still considers it an error for the purposes of firing onerror.
3307
3308         * html/HTMLImageLoader.cpp:
3309         (WebCore::HTMLImageLoader::dispatchLoadEvent):
3310
3311 2009-04-02  Dimitri Glazkov  <dglazkov@chromium.org>
3312
3313         Reviewed by Timothy Hatcher.
3314
3315         https://bugs.webkit.org/show_bug.cgi?id=25010
3316         Refactor InspectorController to replace all JS function invocations with
3317         ScriptFunctionCall.
3318
3319         * bindings/js/ScriptFunctionCall.cpp:
3320         (WebCore::ScriptFunctionCall::appendArgument): Added int, UString,
3321             and JSValuePtr methods.
3322         (WebCore::ScriptFunctionCall::call): Added simplified, exception-eating
3323             method.
3324         * bindings/js/ScriptFunctionCall.h: Decls for above.
3325         * bindings/js/ScriptObjectQuarantine.cpp: Added helper for Node and DOMWindow.
3326         (WebCore::getQuarantinedScriptObject):
3327         * bindings/js/ScriptObjectQuarantine.h: Decls for above.
3328         * inspector/InspectorController.cpp:
3329         (WebCore::callSimpleFunction): Made into a static.
3330         (WebCore::InspectorController::focusNode): Refactored to use ScriptFunctionCall.
3331         (WebCore::InspectorController::toggleRecordButton): Ditto.
3332         (WebCore::InspectorController::startGroup): Ditto.
3333         (WebCore::InspectorController::setAttachedWindow): Ditto.
3334         (WebCore::InspectorController::inspectedWindowScriptObjectCleared): Ditto.
3335         (WebCore::InspectorController::addScriptProfile): Ditto.
3336         (WebCore::InspectorController::didParseSource): Ditto.
3337         (WebCore::InspectorController::failedToParseSource): Ditto.
3338         (WebCore::InspectorController::didPause): Ditto.
3339         * inspector/InspectorController.h: Removed callFunction and callSimpleFunction
3340             decls.
3341
3342 2009-04-02  Jian Li  <jianli@chromium.org>
3343
3344         Reviewed by Darin Fisher.
3345
3346         Upstream changes to V8WorkerContextEventListener for V8 bindings.
3347         https://bugs.webkit.org/show_bug.cgi?id=25007
3348
3349         * bindings/v8/V8ObjectEventListener.h:
3350         * bindings/v8/V8WorkerContextEventListener.cpp:
3351
3352 2009-04-02  Jian Li  <jianli@chromium.org>
3353
3354         Reviewed by Darin Fisher.
3355
3356         Upstream V8WorkerContextObjectEventListener for V8 bindings.
3357         https://bugs.webkit.org/show_bug.cgi?id=25005
3358
3359         * bindings/v8/V8WorkerContextObjectEventListener.cpp: Added.
3360         * bindings/v8/V8WorkerContextObjectEventListener.h: Added.
3361
3362 2009-04-02  Jian Li  <jianli@chromium.org>
3363
3364         Reviewed by Darin Fisher.
3365
3366         Upstream V8EventListenerList for V8 bindings.
3367         https://bugs.webkit.org/show_bug.cgi?id=25004
3368
3369         * bindings/v8/V8EventListenerList.cpp: Added.
3370         * bindings/v8/V8EventListenerList.h: Added.
3371
3372 2009-04-02  Michael Nordman  <michaeln@google.com>
3373
3374         Reviewed by Darin Fisher.
3375
3376         Chromium's ResourceRequest and ResourceResponse structs need some new data members.
3377         https://bugs.webkit.org/show_bug.cgi?id=24897
3378
3379         These fields are needed to facilitate Chromium's implementation of the HTML5
3380         ApplicationCache feature. We need to know what frame (or context) is doing the
3381         requesting, and from what cache the resulting resource was retrieved.
3382
3383         No change in functionality, so no tests.
3384
3385         * platform/network/chromium/ResourceRequest.h:
3386         (WebCore::ResourceRequest::ResourceRequest):
3387         (WebCore::ResourceRequest::appCacheContextID):
3388         (WebCore::ResourceRequest::setAppCacheContextID):
3389         * platform/network/chromium/ResourceResponse.h:
3390         (WebCore::ResourceResponse::ResourceResponse):
3391         (WebCore::ResourceResponse::getAppCacheID):
3392         (WebCore::ResourceResponse::setAppCacheID):
3393
3394 2009-04-02  David Hyatt  <hyatt@apple.com>
3395
3396         Reviewed by Darin Adler
3397
3398         Fix for https://bugs.webkit.org/show_bug.cgi?id=24643.
3399         
3400         Make sure images just ignore HTTP error codes and keep loading anyway.  Only <object> checks http error codes and falls back.  Everyone
3401         else just ignores it and displays the image anyway.
3402
3403         Added http/tests/misc/image-error.html
3404
3405         * html/HTMLImageLoader.cpp:
3406         (WebCore::HTMLImageLoader::notifyFinished):
3407         * loader/CachedImage.cpp:
3408         (WebCore::CachedImage::CachedImage):
3409         * loader/CachedImage.h:
3410         (WebCore::CachedImage::httpStatusCodeError):
3411         (WebCore::CachedImage::httpStatusCodeErrorOccurred):
3412         * loader/CachedResource.h:
3413         (WebCore::CachedResource::httpStatusCodeError):
3414         * loader/loader.cpp:
3415         (WebCore::Loader::Host::didReceiveData):
3416
3417 2009-04-02  Jian Li  <jianli@chromium.org>
3418
3419         Reviewed by Dimitri Glazkov.
3420
3421         Add XHR constructor in WorkerContext.idl for V8 bindings.
3422         https://bugs.webkit.org/show_bug.cgi?id=24962
3423
3424         * workers/WorkerContext.idl:
3425
3426 2009-04-02  Ben Murdoch  <benm@google.com>
3427
3428         Fix Bug 19743: Release build fails on 32-bit Windows
3429
3430         <https://bugs.webkit.org/show_bug.cgi?id=19743>
3431
3432         Combines all the HTML element cpp files into one to help reduce the
3433         size of WebCore.lib so we can build in release mode on 32bit Windows.
3434
3435         Reviewed by Adam Roben.
3436
3437         * WebCore.vcproj/WebCore.vcproj: Excluded all the separate
3438         HTML*Element.cpp files from the build. Added HTMLElementsAllInOne.cpp
3439         to the build.
3440         * html/HTMLElementsAllInOne.cpp: Added.
3441
3442 2009-04-02  Simon Fraser  <simon.fraser@apple.com>
3443
3444         Reviewed by Darin Adler
3445
3446         https://bugs.webkit.org/show_bug.cgi?id=24999
3447         
3448         Optimize hit testing with transforms.
3449
3450         * rendering/RenderBox.cpp:
3451         (WebCore::RenderBox::mapLocalToContainer):
3452         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
3453         getTransformFromContainer() change to return the matrix by reference.
3454
3455         * rendering/RenderLayer.cpp:
3456         (WebCore::RenderLayer::update3DTransformedDescendantStatus):
3457         The method failed to set m_3DTransformedDescendantStatusDirty to false,
3458         so did the work every time.
3459
3460         (WebCore::RenderLayer::createLocalTransformState):
3461         Only call the expensive getTransformFromContainer() if there is a transform,
3462         otherwise we just have a translation.
3463
3464         * rendering/RenderObject.cpp:
3465         (WebCore::RenderObject::getTransformFromContainer):
3466         * rendering/RenderObject.h:
3467         Change transformFromContainer() to getTransformFromContainer(), and return
3468         the matrix by reference to reduce copying.
3469         New enum values for arguments for readability.
3470
3471         * rendering/TransformState.cpp:
3472         (WebCore::TransformState::move):
3473         (WebCore::TransformState::applyTransform):
3474         (WebCore::HitTestingTransformState::translate):
3475         New method that adds a translation to the accumulated matrix, optionally
3476         without flattening. Cheaper than applyTransform().
3477
3478         (WebCore::HitTestingTransformState::applyTransform):
3479         (WebCore::HitTestingTransformState::flatten):
3480         (WebCore::HitTestingTransformState::flattenWithTransform):
3481         Add flattenWithTransform(), which is a helper that allows us to
3482         avoid doing the inverse() twice.
3483
3484         * rendering/TransformState.h:
3485         (WebCore::TransformState::):
3486         (WebCore::TransformState::move):
3487         (WebCore::HitTestingTransformState::):
3488         New method on HitTestingTransformState that adds a translation to the
3489         accumulated matrix, optionally without flattening. Cheaper than applyTransform().
3490         New enum values for arguments for readability.
3491
3492 2009-04-02  Simon Fraser  <simon.fraser@apple.com>
3493
3494         Reviewed by Dan Bernstein
3495         
3496         https://bugs.webkit.org/show_bug.cgi?id=24648
3497         
3498         Optimize common code paths in TransformationMatrix.
3499
3500         * platform/graphics/transforms/TransformationMatrix.cpp:
3501         (WebCore::TransformationMatrix::translate):
3502         (WebCore::TransformationMatrix::translate3d):
3503         Optimize to avoid matrix copy.
3504         
3505         (WebCore::TransformationMatrix::isInvertible):
3506         Test for identity and translation matrices before computing
3507         the determinant.
3508         
3509         (WebCore::TransformationMatrix::inverse):
3510         Optimize for identity matrix and translations.
3511         
3512         * platform/graphics/transforms/TransformationMatrix.h:
3513         (WebCore::TransformationMatrix::isIdentityOrTranslation):
3514         Utility method.
3515
3516 2009-04-02  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
3517
3518         Reviewed by Alexey Proskuryakov.
3519
3520         https://bugs.webkit.org/show_bug.cgi?id=24930
3521         [Gtk] ISO files content is displayed inside the webview instead of being downloaded
3522
3523         Also sniff content of types declared as text/plain. This is
3524         justified by the fact that it is common to have Apache HTTP
3525         servers configured to send text/plain as Content-Type by default.
3526
3527         * platform/network/soup/ResourceHandleSoup.cpp:
3528         (WebCore::gotHeadersCallback):
3529
3530 2009-04-02  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
3531
3532         Reviewed by Alexey Proskuryakov.
3533
3534         Protect the handle when notifying the client that the response was
3535         received also in gotChunkCallback, or we crash in didReceiveData
3536         when the load is cancelled in didReceiveResponse.
3537
3538         * platform/network/soup/ResourceHandleSoup.cpp:
3539         (WebCore::gotChunkCallback):
3540
3541 2009-04-02  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
3542
3543         Reviewed by Alexey Proskuryakov.
3544
3545         https://bugs.webkit.org/show_bug.cgi?id=25001
3546         Crash when content type parameters have no value
3547
3548         Handle the case where a Content-Type header parameter has no
3549         value (i.e. no = character), to work-around a bug in libsoup.
3550
3551         * platform/network/soup/ResourceHandleSoup.cpp:
3552         (WebCore::fillResponseFromMessage):
3553
3554 2009-04-02  Yael Aharon  <yael.aharon@nokia.com>
3555
3556         Reviewed by Simon Hausmann.
3557
3558         https://bugs.webkit.org/show_bug.cgi?id=24490
3559
3560         Enable web workers in Qt.
3561
3562         * WebCore.pro:
3563
3564 2009-04-01  Alexey Proskuryakov  <ap@webkit.org>
3565
3566         Reviewed by Darin Adler. Based on work of Julien Chaffraix.
3567
3568         https://bugs.webkit.org/show_bug.cgi?id=22475
3569         REGRESSION: Async XMLHttpRequest never finishes on nonexistent files anymore
3570
3571         https://bugs.webkit.org/show_bug.cgi?id=24886
3572         XHR requests opened when offline never return
3573
3574         Tests: fast/xmlhttprequest/xmlhttprequest-nonexistent-file.html
3575                http/tests/xmlhttprequest/state-after-network-error.html
3576
3577         * xml/XMLHttpRequest.cpp:
3578         (WebCore::XMLHttpRequest::callReadyStateChangeListener): Only dispatch load event if this
3579         wasn't an error.
3580         (WebCore::XMLHttpRequest::abort): Fixed formatting.
3581         (WebCore::XMLHttpRequest::genericError): Change state to DONE and dispatch readystatechange.
3582         The comment saying that this doesn't match Firefox was added in r33559 without explanation
3583         or tests, and I don't think that it's accurate. Also, Firefox and Safari 3 both change state
3584         to HEADERS_RECEIVED before DONE on error - this doesn't match the spec, and I doubt
3585         that any code depends on this, so I went with the spec here.
3586
3587 2009-04-01  Steve Falkenburg  <sfalken@apple.com>
3588
3589         https://bugs.webkit.org/show_bug.cgi?id=24997
3590         Race conditions in icon database threading code
3591         
3592         m_syncThreadRunning set was mistakenly eliminated in r27717.
3593         This reintroduces it.
3594
3595         Reviewed by Oliver Hunt.
3596
3597         * loader/icon/IconDatabase.cpp:
3598         (WebCore::IconDatabase::open): Set m_syncThreadRunning.
3599
3600 2009-04-01  Antti Koivisto  <antti@apple.com>
3601
3602         Reviewed by Darin Adler.
3603
3604         <rdar://problem/6748609> Use ActiveDOMObject to suspend marquees
3605         
3606         Make marquees ActiveDOMObjects, get rid of the special suspension code.
3607
3608         * html/HTMLMarqueeElement.cpp:
3609         (WebCore::HTMLMarqueeElement::HTMLMarqueeElement):
3610         (WebCore::HTMLMarqueeElement::canSuspend):
3611         (WebCore::HTMLMarqueeElement::suspend):
3612         (WebCore::HTMLMarqueeElement::resume):
3613         * html/HTMLMarqueeElement.h:
3614         * page/Frame.cpp:
3615         (WebCore::Frame::clearTimers):
3616         * rendering/RenderLayer.cpp:
3617         * rendering/RenderLayer.h:
3618         (WebCore::RenderLayer::marquee):
3619
3620 2009-04-01  Dean Jackson  <dino@apple.com>
3621
3622         Reviewed by Darin Adler
3623
3624         Make constant values static in previous commit, as suggested
3625         by Darin.
3626
3627         * rendering/RenderVideo.cpp:
3628
3629 2009-04-01  Dean Jackson  <dino@apple.com>
3630
3631         Reviewed by Simon Fraser
3632
3633         https://bugs.webkit.org/show_bug.cgi?id=24993
3634
3635         Standalone media should have a smaller instrinsic
3636         height.
3637
3638         * rendering/RenderVideo.cpp:
3639         (WebCore::RenderVideo::RenderVideo):
3640
3641 2009-04-01  Darin Adler  <darin@apple.com>
3642
3643         Reviewed by Geoff Garen.
3644
3645         Bug 22378: Crash submitting a form when parsing an XHTML document
3646         https://bugs.webkit.org/show_bug.cgi?id=22378
3647         rdar://problem/6388377
3648
3649         Tests: fast/loader/submit-form-while-parsing-1.xhtml
3650                fast/loader/submit-form-while-parsing-2.html
3651
3652         * WebCore.base.exp: Updated.
3653
3654         * history/HistoryItem.cpp:
3655         (WebCore::HistoryItem::HistoryItem): Renamed m_subItems to m_children.
3656         Used uncheckedAppend because we reserveInitialCapacity.
3657         (WebCore::HistoryItem::addChildItem): Renamed m_subItems to m_children.
3658         Added an assertion that this is only used to add items that don't have
3659         duplicate frame names.
3660         (WebCore::HistoryItem::setChildItem): Added. Replaces an existing item
3661         if any, preserving the isTargetItem flag.
3662         (WebCore::HistoryItem::childItemWithTarget): Renamed from childItemWithName
3663         for consistency with the other functions here that all call the frame name the
3664         "target". Also updated for rename of m_subItems to m_children.
3665         (WebCore::HistoryItem::findTargetItem): Renamed from recurseToFindTargetItem.
3666         Removed unneeded size check.
3667         (WebCore::HistoryItem::targetItem): Changed to always return the top item
3668         if no item has the isTargetItem flag set. The old version would instead return
3669         0 in some cases, but return the top item if it had no children.
3670         (WebCore::HistoryItem::children): Renamed m_subItems to m_children.
3671         (WebCore::HistoryItem::hasChildren): Ditto.
3672         (WebCore::HistoryItem::showTreeWithIndent): Ditto.
3673
3674         * history/HistoryItem.h: Name changes.
3675
3676         * html/HTMLFormElement.cpp:
3677         (WebCore::HTMLFormElement::submit): Create and pass a FormState instead of
3678         attaching "recorded form values" and "form about to be submitted" to the frame
3679         loader. Parameter work fine for this; there's no need to store state on the
3680         FrameLoader.
3681
3682         * loader/FormState.cpp:
3683         (WebCore::FormState::FormState): Adopt a vector instead of copying a hash map.
3684         (WebCore::FormState::create): Ditto.
3685         * loader/FormState.h: Update to use a vector that we adopt instead of hash map
3686         that we copy for auto-fill text field values.
3687
3688         * loader/FrameLoader.cpp:
3689         (WebCore::ScheduledRedirection::ScheduledRedirection): Added a new case for
3690         form submissions and turned the "wasDuringLoad" state into a separate boolean
3691         instead of using a special redirection type to track it.
3692         (WebCore::FrameLoader::createWindow): Updated for name and argument change of
3693         loadFrameRequest.
3694         (WebCore::FrameLoader::urlSelected): Ditto.
3695         (WebCore::FrameLoader::submitForm): Removed the "deferred form submission"
3696         machinery, replacing it with the "scheduled redirection" mechanism, shared
3697         with other kinds of redirection and navigation. Moved frame targeting here
3698         so we can schedule the redirection on the right frame. Moved the multiple
3699         form submission protection here. Moved the code to implement the rule that
3700         m_navigationDuringLoad was used for here too.
3701         (WebCore::FrameLoader::didOpenURL): Use the new wasDuringLoad flag instead
3702         of the locationChangeDuringLoad type to detect location change during a load.
3703         (WebCore::FrameLoader::executeScript): Removed call to now-obsolete function,
3704         submitFormAgain.
3705         (WebCore::FrameLoader::scheduleLocationChange): Moved the code to stop loading
3706         out of this function into scheduleRedirection, so it can be shared with the
3707         new scheduleFormSubmission function.
3708         (WebCore::FrameLoader::scheduleFormSubmission): Added. Almost the same as
3709         scheduleLocationChange, but with the arguments for a form submission.
3710         (WebCore::FrameLoader::scheduleRefresh): Updated for the change to the
3711         duringLoad flag.
3712         (WebCore::FrameLoader::isLocationChange): Added case for formSubmission
3713         and removed case for locationChangeDuringLoad.
3714         (WebCore::FrameLoader::redirectionTimerFired): Ditto. Also removed unneeded
3715         completeURL call and just use KURL constructor to match the other cases.
3716         (WebCore::FrameLoader::provisionalLoadStarted): Removed the code to set up
3717         the m_navigationDuringLoad, which is no longer needed. The new version of
3718         this is in the submitForm function and sets the lockHistory boolean.
3719         (WebCore::FrameLoader::scheduleRedirection): Moved the code to stop a load
3720         in here that used to be in scheduleLocationChange.
3721         (WebCore::FrameLoader::startRedirectionTimer): Added case for formSubmission
3722         and removed case for locationChangeDuringLoad.
3723         (WebCore::FrameLoader::stopRedirectionTimer): Ditto.
3724         (WebCore::FrameLoader::completed): Removed call to now-obsolete function,
3725         submitFormAgain.
3726         (WebCore::FrameLoader::loadFrameRequest): Renamed from
3727         loadFrameRequestWithFormAndValues. Replaced form element and form values
3728         argument with a single FormState argument. Changed frame targeting code
3729         to use the source frame in the case of a form submission to better match
3730         the actual target frame.
3731         (WebCore::FrameLoader::loadURL): Don't search for existing frames in the
3732         form submission case since we already did that in the submitForm function.
3733         (WebCore::FrameLoader::clientRedirected): Changed to work with the
3734         m_isExecutingJavaScriptFormAction data member directly instead of taking
3735         it as a function parameter.
3736         (WebCore::FrameLoader::loadPostRequest): Don't search for existing frames
3737         in the form submission case since we already did that in the submitForm
3738         function.
3739         (WebCore::FrameLoader::addBackForwardItemClippedAtTarget): Moved comment
3740         in here that was misplaced elsewhere in the file.
3741         (WebCore::FrameLoader::findFrameForNavigation): Changed to use the early
3742         return idiom.
3743         (WebCore::FrameLoader::recursiveGoToItem): Updated for HistoryItem changes.
3744         (WebCore::FrameLoader::childFramesMatchItem): Ditto.
3745         (WebCore::FrameLoader::updateHistoryForStandardLoad): Removed the
3746         m_navigationDuringLoad logic; that's now handled by setting lockHistory
3747         to true in the submitForm function.
3748         (WebCore::FrameLoader::updateHistoryForRedirectWithLockedBackForwardList):
3749         Use the new setChildItem function so we don't get multiple items for the
3750         same frame name in the history item tree in the back/forward list.
3751
3752         * loader/FrameLoader.h: Renamed loadFrameRequestWithFormAndValues to
3753         loadFrameRequest and made it take a form state object instead of the
3754         form element and form values. Removed the unused functions
3755         loadEmptyDocumentSynchronously, provisionalDocumentLoader,
3756         notifyIconChnaged, and updateBaseURLForEmptyDocument. Changed the
3757         submitForm function to take a form state argument. Eliminated the
3758         clearRecordedFormValues, setFormAboutToBeSubmitted, and recordFormValue
3759         functions, which are replaced by the form state arguments to submitForm
3760         and loadFrameRequest. Removed the isJavaScriptFormAction argument from
3761         the clientRedirected function; instead it looks at a data member directly.
3762         Eliminated the submitFormAgain and overload of the submitForm function;
3763         these are now subsumed into the remaining submitForm function and the
3764         scheduleFormSubmission function. Removed unused and obsolete data
3765         members m_navigationDuringLoad, m_deferredFormSubmission,
3766         m_formAboutToBeSubmitted and m_formValuesAboutToBeSubmitted.
3767
3768         * page/ContextMenuController.cpp:
3769         (WebCore::ContextMenuController::contextMenuItemSelected):
3770         Updated for name and argument change of loadFrameRequest.
3771
3772         * page/Frame.cpp:
3773         (WebCore::Frame::~Frame): Removed call to the now-unneeded
3774         clearRecordedFormValues function.
3775
3776 2009-04-01  Dimitri Glazkov  <dglazkov@chromium.org>
3777
3778         Unreviewed, fixing previous commit.
3779
3780         https://bugs.webkit.org/show_bug.cgi?id=24994
3781         Revert V8DOMMap.cpp change which accidentally snuck into the previous
3782         commit.
3783
3784         * bindings/v8/V8DOMMap.cpp: Revert change in previous commit.
3785
3786 2009-04-01  Dimitri Glazkov  <dglazkov@chromium.org>
3787
3788         Reviewed by Darin Fisher.
3789
3790         https://bugs.webkit.org/show_bug.cgi?id=24994
3791         Fix miscellaneous merge/upstreaming divergencies in Chromium port.
3792
3793         * bindings/v8/V8Collection.h: Added an include.
3794         * platform/KURLGoogle.cpp:
3795         (WebCore::KURL::baseAsString): Added to match KURL.cpp.
3796         * platform/chromium/ClipboardChromium.cpp: Added an include.
3797
3798 2009-04-01  Dimitri Glazkov  <dglazkov@chromium.org>
3799
3800         Reviewed by Timothy Hatcher.
3801
3802         https://bugs.webkit.org/show_bug.cgi?id=24989
3803         Refactor InspectorResource to use ScriptObject/FunctionCall.
3804
3805         * bindings/js/JSInspectorControllerCustom.cpp:
3806         (WebCore::JSInspectorController::addResourceSourceToFrame): Tweaked to use
3807             a more appropriate type conversion.
3808         (WebCore::JSInspectorController::getResourceDocumentNode): Tweaked to
3809             accommodate for InspectorResource refactoring.
3810         * bindings/js/ScriptFunctionCall.cpp:
3811         (WebCore::ScriptFunctionCall::appendArgument): Added long long type to match
3812             existing jsNumber call signature.
3813         * bindings/js/ScriptFunctionCall.h: Declaration for above.
3814         * bindings/js/ScriptObject.cpp:
3815         (WebCore::createEmptyObject): Added.
3816         (WebCore::ScriptObject::ScriptObject):
3817         (WebCore::ScriptObject::set): Added a bunch of property setters.
3818         * bindings/js/ScriptObject.h: Declarations for above.
3819         * inspector/InspectorController.cpp: Moved all InspectorResource-managing code
3820             to InspectorResource.cpp
3821         (WebCore::InspectorController::populateScriptObjects): Changed to use
3822             refactored InspectorResource.
3823         (WebCore::InspectorController::resetScriptObjects): Ditto.
3824         (WebCore::InspectorController::pruneResources): Ditto.
3825         (WebCore::InspectorController::didCommitLoad): Ditto.
3826         (WebCore::InspectorController::addResource): Ditto.
3827         (WebCore::InspectorController::removeResource): Ditto.
3828         (WebCore::InspectorController::didLoadResourceFromMemoryCache): Ditto.
3829         (WebCore::InspectorController::identifierForInitialRequest): Ditto.
3830         (WebCore::InspectorController::willSendRequest): Ditto.
3831         (WebCore::InspectorController::didReceiveResponse): Ditto.
3832         (WebCore::InspectorController::didReceiveContentLength): Ditto.
3833         (WebCore::InspectorController::didFinishLoading): Ditto.
3834         (WebCore::InspectorController::didFailLoading): Ditto,
3835         (WebCore::InspectorController::resourceRetrievedByXMLHttpRequest): Ditto.
3836         (WebCore::InspectorController::scriptImported): Ditto.
3837         * inspector/InspectorController.h: Removed InspectorResource-managing code decls
3838             and tweaked some signatures to use ScriptString and long long for identifier.
3839         * inspector/InspectorController.idl: Changed to use long long for identifier.
3840         * inspector/InspectorResource.cpp: Refactored to use ScriptObject/FunctionCall.
3841         (WebCore::InspectorResource::InspectorResource): Ditto.
3842         (WebCore::InspectorResource::~InspectorResource): Ditto.
3843         (WebCore::InspectorResource::createCached): Added.
3844         (WebCore::InspectorResource::updateRequest): Added.
3845         (WebCore::InspectorResource::updateResponse): Added.
3846         (WebCore::createHeadersObject): Added.
3847         (WebCore::InspectorResource::createScriptObject): Added.
3848         (WebCore::InspectorResource::updateScriptObject): Added.
3849         (WebCore::InspectorResource::releaseScriptObject): Added.
3850         (WebCore::InspectorResource::type): Tweaked to use ScriptString.
3851         (WebCore::InspectorResource::setXMLHttpResponseText): Added.
3852         (WebCore::InspectorResource::sourceString): Tweaked to use ScriptString.
3853         (WebCore::InspectorResource::startTiming): Added.
3854         (WebCore::InspectorResource::markResponseReceivedTime): Added.
3855         (WebCore::InspectorResource::endTiming): Added.
3856         (WebCore::InspectorResource::markFailed): Added.
3857         (WebCore::InspectorResource::addLength): Added.
3858         * inspector/InspectorResource.h: Added decls for newly refactored-in methods.
3859         (WebCore::InspectorResource::create): Added.
3860         (WebCore::InspectorResource::isSameLoader): Added.
3861         (WebCore::InspectorResource::markMainResource): Added.
3862         (WebCore::InspectorResource::identifier): Added.
3863         (WebCore::InspectorResource::requestURL): Added.
3864         (WebCore::InspectorResource::frame): Added.
3865         (WebCore::InspectorResource::mimeType): Added.
3866         (WebCore::InspectorResource::Changes::Changes): Added new class to track
3867             resource changes.
3868         (WebCore::InspectorResource::Changes::hasChange): Added.
3869         (WebCore::InspectorResource::Changes::set): Added.
3870         (WebCore::InspectorResource::Changes::clear): Added.
3871         (WebCore::InspectorResource::Changes::setAll): Added.
3872         (WebCore::InspectorResource::Changes::clearAll): Added.
3873
3874 2009-04-01  Tony Chang  <tony@chromium.org>
3875
3876         Reviewed by Darin Fisher.
3877
3878         Ensure the right click doesn't deselect text under it.  This was
3879         happening in the Chromium and GTK+ ports because they don't select
3880         the text under the cursor on right click.
3881         
3882         This was regressed in r41715, https://bugs.webkit.org/show_bug.cgi?id=19737
3883         
3884         https://bugs.webkit.org/show_bug.cgi?id=24946
3885
3886         Test: fast/events/context-no-deselect.html
3887
3888         * page/EventHandler.cpp:
3889         (WebCore::EventHandler::handleMouseReleaseEvent):
3890
3891 2009-04-01  Simon Fraser  <simon.fraser@apple.com>
3892
3893         Reviewed by Dave Hyatt
3894
3895         https://bugs.webkit.org/show_bug.cgi?id=24991
3896         
3897         Need to use toRenderBoxModelObject(), not toRenderBox(), to test for layer()
3898         when getting the transform.
3899         
3900         * rendering/RenderObject.cpp:
3901         (WebCore::RenderObject::transformFromContainer):
3902
3903 2009-03-31  Darin Adler  <darin@apple.com>
3904
3905         Rolled out that last change until I can investigate the regression test failures it seems
3906         to have caused.
3907
3908         * dom/PositionIterator.cpp:
3909         (WebCore::PositionIterator::decrement):
3910         * dom/PositionIterator.h:
3911         (WebCore::PositionIterator::PositionIterator):
3912
3913 2009-03-31  Darin Adler  <darin@apple.com>
3914
3915         Reviewed by Eric Seidel.
3916
3917         Bug 24621: PositionIterator doesn't iterate "after last child" positions when going backwards
3918         https://bugs.webkit.org/show_bug.cgi?id=24621
3919
3920         * dom/PositionIterator.cpp:
3921         (WebCore::PositionIterator::decrement): Make sure that when the parent has no children, we
3922         don't ever use Position::uncheckedPreviousOffset. This is consistent with the forward
3923         iterator, but also should never arise because of the fix below.
3924         * dom/PositionIterator.h:
3925         (WebCore::PositionIterator::PositionIterator): Fixed so m_offset will always be 0 when
3926         the passed-in node has no children. Like the change above, this is consistent with the rest
3927         of the class, although in the long run I think it's a bit strange to treat a <p> element
3928         with no children differently than a <p> element with children.
3929
3930 2009-03-31  Eric Carlson  <eric.carlson@apple.com>
3931
3932         Reviewed by Simon Fraser.
3933
3934         https://bugs.webkit.org/show_bug.cgi?id=24965
3935         Bug 24965: HTMLMediaElement: network state changes can be missed
3936         
3937         * html/HTMLMediaElement.cpp:
3938         (WebCore::HTMLMediaElement::setNetworkState): Always update m_networkState when the
3939         state changes, even when no event needs to be fired.
3940
3941 2009-03-31  Eric Carlson  <eric.carlson@apple.com>
3942
3943         Reviewed by Darin Adler.
3944         
3945         https://bugs.webkit.org/show_bug.cgi?id=24964
3946         Bug 24964: HTMLMediaElement: 'waiting' event may fire twice
3947
3948         * html/HTMLMediaElement.cpp:
3949         (WebCore::HTMLMediaElement::setReadyState): Only fire 'waiting' event once when ready state
3950         drops below HAVE_FUTURE_DATA.
3951
3952 2009-03-31  Eric Carlson  <eric.carlson@apple.com>
3953
3954         Reviewed by Darin Adler.
3955
3956         https://bugs.webkit.org/show_bug.cgi?id=24846
3957         Bug 24846: HTMLMediaElement should implement 'autobuffer' attribute
3958
3959         Add 'autobuffer' attrubute to media element. 'autobuffer' is a hint that
3960         the author recommends downloading the entire resource optimistically, so the
3961         attribute is made available to the media engine to use if it is able.
3962
3963         Test: media/video-dom-autobuffer.html
3964
3965         * html/HTMLAttributeNames.in: Add autobuffer.
3966
3967         * html/HTMLMediaElement.cpp:
3968         (WebCore::HTMLMediaElement::parseMappedAttribute): New.
3969         (WebCore::HTMLMediaElement::autobuffer): Ditto.
3970         (WebCore::HTMLMediaElement::setAutobuffer): Ditto.
3971
3972         * html/HTMLMediaElement.h: Declare autobuffer and setAutobuffer.
3973
3974         * html/HTMLMediaElement.idl: Add autobuffer.
3975
3976         * platform/graphics/MediaPlayer.cpp:
3977         (WebCore::MediaPlayer::MediaPlayer): Initialize m_autobuffer.
3978         (WebCore::MediaPlayer::autobuffer): New.
3979         (WebCore::MediaPlayer::setAutobuffer): Ditto.
3980         * platform/graphics/MediaPlayer.h: Declare m_autobuffer, autobuffer and setAutobuffer
3981
3982         * platform/graphics/MediaPlayerPrivate.h:
3983         (WebCore::MediaPlayerPrivateInterface::setAutobuffer): Declare setAutobuffer.
3984
3985 2009-03-31  Craig Schlenter  <craig.schlenter@gmail.com>
3986
3987         Reviewed by Dimitri Glazkov.
3988
3989         https://bugs.webkit.org/show_bug.cgi?id=24550
3990         Check return value of vasprintf. This should keep gcc 4.3.3
3991         happy rather than have it complain about attribute warn_unused_result.
3992
3993         * dom/XMLTokenizerLibxml2.cpp:
3994         (WebCore::XMLTokenizer::error):
3995
3996 2009-03-31  Dean Jackson  <dino@apple.com>
3997
3998         Style guide violation!
3999
4000         * loader/MediaDocument.cpp:
4001         (WebCore::MediaDocument::defaultEventHandler):
4002
4003 2009-03-31  Dean Jackson  <dino@apple.com>
4004
4005         Fix Tiger build.
4006
4007         * loader/MediaDocument.cpp:
4008         (WebCore::MediaDocument::defaultEventHandler):
4009
4010 2009-03-31  Jian Li  <jianli@chromium.org>
4011
4012         Reviewed by Darin Fisher.
4013
4014         Upstream V8DOMMap for v8 bindings.
4015         https://bugs.webkit.org/show_bug.cgi?id=24951
4016
4017         * bindings/v8/V8DOMMap.cpp: Added.
4018         * bindings/v8/V8DOMMap.h: Added.
4019
4020 2009-03-31  Dean Jackson  <dino@apple.com>
4021
4022         Reviewed by Simon Fraser.
4023
4024         https://bugs.webkit.org/show_bug.cgi?id=24955
4025
4026         Spacebar didn't play/pause in standalone MediaDocument
4027
4028         * loader/MediaDocument.cpp:
4029         (WebCore::MediaDocument::defaultEventHandler):
4030
4031 2009-03-31  Alpha Lam  <hclam@chromium.org>
4032
4033         Reviewed by Eric Seidel.
4034
4035         https://bugs.webkit.org/show_bug.cgi?id=24901
4036         Added the following methods to MediaPlayerPrivate for Chromium port.
4037         void sizeChanged();
4038         void rateChanged();
4039         void durationChanged();
4040
4041         The above changes are to reflect changes in MediaPlayer.cpp.
4042         More details can be found in the original changeset.
4043         http://trac.webkit.org/changeset/41907
4044
4045         * platform/graphics/chromium/MediaPlayerPrivateChromium.h:
4046
4047 2009-03-31  Rafael Weinstein  <rafaelw@chromium.org>
4048
4049         Reviewed by Eric Seidel.
4050
4051         https://bugs.webkit.org/show_bug.cgi?id=24947
4052
4053         Special-case drawing text-shadow on win32, to let GDI draw in cases
4054         when both fill & shadow color are opaque and the shadow has no blur.
4055
4056         * platform/graphics/chromium/FontChromiumWin.cpp:
4057         (WebCore::TransparencyAwareFontPainter::TransparencyAwareGlyphPainter::drawGlyphs):
4058         (WebCore::Font::drawComplexText):
4059         * platform/graphics/skia/SkiaFontWin.cpp:
4060         (WebCore::windowsCanHandleDrawTextShadow):
4061         (WebCore::windowsCanHandleTextDrawing):
4062         * platform/graphics/skia/SkiaFontWin.h:
4063
4064 2009-03-31  Jeremy Moskovich  <jeremy@chromium.org>
4065
4066         Reviewed by Darin Fisher.
4067
4068         r42055 removed some functions in FrameLoader used by Chrome,
4069         this CL backs out some of those changes to unbreak the Chrome build.
4070
4071         https://bugs.webkit.org/show_bug.cgi?id=24949
4072
4073         * WebCore.base.exp:
4074         * loader/FrameLoader.cpp:
4075         * loader/FrameLoader.h:
4076
4077 2009-03-31  Jeremy Moskovich  <jeremy@chromium.org>
4078
4079         Reviewed by Darin Adler.
4080
4081         Build fixes for Chromium.
4082
4083         https://bugs.webkit.org/show_bug.cgi?id=24945
4084
4085         * dom/Document.h:
4086         * platform/chromium/ClipboardChromium.cpp:
4087         (WebCore::imageToMarkup):
4088
4089 2009-03-31  Simon Hausmann  <simon.hausmann@nokia.com>
4090
4091         Fix the Qt build.
4092
4093         * dom/XMLTokenizerQt.cpp:
4094         (WebCore::XMLTokenizer::XMLTokenizer): Use NamedNodeMap instead of NamedAttrMap.
4095
4096 2009-03-30  Steve Falkenburg  <sfalken@apple.com>
4097
4098         Don't create CFDataRef with a fixed size.
4099         Fixes synchronous XMLHTTPRequests on Windows.
4100         
4101         Reviewed by Ada Chan.
4102
4103         * platform/network/cf/ResourceHandleCFNet.cpp:
4104         (WebCore::WebCoreSynchronousLoader::didReceiveData):
4105
4106 2009-03-30  Darin Adler  <darin@apple.com>
4107
4108         Reviewed by Sam Weinig.
4109
4110         Bug 24594: PolicyDelegate NavigationAction is WebNavigationTypeOther instead of WebNavigationTypeReload
4111         https://bugs.webkit.org/show_bug.cgi?id=24594
4112         rdar://problem/6682110
4113
4114         Test: fast/loader/reload-policy-delegate.html
4115
4116         * loader/FrameLoader.cpp:
4117         (WebCore::FrameLoader::loadWithDocumentLoader): Set the triggering action here where we know it's
4118         the policy loader and can use m_policyLoadType rather than letting it get set inside
4119         checkNavigationPolicy.
4120
4121 2009-03-30  Timothy Hatcher  <timothy@apple.com>
4122
4123         <rdar://problem/5838871> CrashTracer: 1483 crashes Quicklooking
4124         in Finder (painting without up to date layout)
4125
4126         Reviewed by Dan Bernstein.
4127
4128         * page/FrameView.cpp:
4129         (WebCore::FrameView::paintContents): Add an early return when
4130         painting is attempted when layout is needed.
4131
4132 2009-03-30  Greg Bolsinga  <bolsinga@apple.com>
4133
4134         Reviewed by Simon Fraser.
4135
4136         https://bugs.webkit.org/show_bug.cgi?id=24938
4137         
4138         Sort alphabetically.
4139
4140         * css/CSSComputedStyleDeclaration.cpp:
4141         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
4142
4143 2009-03-30  Greg Bolsinga  <bolsinga@apple.com>
4144
4145         Reviewed by Simon Fraser.
4146
4147         https://bugs.webkit.org/show_bug.cgi?id=24938
4148         
4149         Build fixes for building --3d-rendering and --no-svg
4150
4151         * rendering/RenderLayerBacking.cpp:
4152
4153 2009-03-30  Greg Bolsinga  <bolsinga@apple.com>
4154
4155         Reviewed by Simon Fraser.
4156         
4157         https://bugs.webkit.org/show_bug.cgi?id=24938
4158
4159         Build fixes when building --no-svg
4160         
4161         * css/CSSComputedStyleDeclaration.cpp:
4162         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Add missing CSS properties
4163         * css/CSSCursorImageValue.cpp:
4164         (WebCore::CSSCursorImageValue::updateIfSVGCursorIsUsed): Handle unused param
4165         * css/CSSParser.cpp:
4166         (WebCore::CSSParser::parseValue): Add missing CSS properties
4167         * css/CSSStyleSelector.cpp:
4168         (WebCore::CSSStyleSelector::applyProperty): Add missing CSS properties
4169         * dom/Node.cpp:
4170         (WebCore::updateSVGElementInstancesAfterEventListenerChange): Handle unused param
4171         * platform/graphics/Font.cpp:
4172         (WebCore::Font::floatWidth): Handle unused param
4173         * platform/graphics/SimpleFontData.cpp:
4174         (WebCore::SimpleFontData::SimpleFontData): Handle unused param
4175
4176 2009-03-30  Darin Adler  <darin@apple.com>
4177
4178         Reviewed by Adam Roben.
4179
4180         Bug 24916: REGRESSION: NavigationAction policy dispatch broken
4181         https://bugs.webkit.org/show_bug.cgi?id=24916
4182
4183         * loader/FrameLoader.cpp:
4184         (WebCore::FrameLoader::loadURL): Rearrange the code so that the "event" PassRefPtr
4185         is not used twice. This also optimizes the case where a frame name is specified,
4186         but it's the name of the frame being loaded. Also called release in all the final
4187         uses of FormState.
4188
4189 2009-03-30  Darin Adler  <darin@apple.com>
4190
4191         Reviewed by Adam Roben.
4192
4193         Bug 24937: NamedNodeMap and NamedAttrMap should not be separate classes
4194         https://bugs.webkit.org/show_bug.cgi?id=24937
4195
4196         Also should fix the Windows COM bindings build.
4197
4198         * bindings/scripts/CodeGeneratorJS.pm: Removed special case for NamedNodeMap.
4199         * bindings/scripts/CodeGeneratorObjC.pm: Ditto.
4200
4201         * dom/NamedAttrMap.h: Renamed class from NamedAttrMap to
4202         NamedNodeMap and removed NamedNodeMap base class. Made the NamedNodeMap
4203         functions all public and non-virtual. Removed virtualLength.
4204
4205         * dom/NamedNodeMap.h: Replaced file with just an include
4206         of NamedAttrMap.h. As a follow up we will rename the NamedAttrMap
4207         files and remove this file.
4208
4209         * bindings/js/JSNamedNodesCollection.cpp: Renamed from NamedAttrMap to NamedNodeMap.
4210         * dom/Attr.h: Ditto.
4211         * dom/Attribute.h: Ditto.
4212         * dom/Document.cpp:
4213         (WebCore::Document::importNode): Ditto.
4214         * dom/Element.cpp:
4215