WebCore: Changing the V8 and JSC implementations of
[WebKit-https.git] / WebCore / ChangeLog
1 2010-03-24  Dumitru Daniliuc  <dumi@chromium.org>
2
3         Reviewed by Dimitri Glazkov.
4
5         Changing the V8 and JSC implementations of
6         SQLStatementErrorCallback to interpret as false all results that
7         could be converted to a false boolean. Pretty much a revert of
8         r54981.
9
10         https://bugs.webkit.org/show_bug.cgi?id=36569
11
12         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
13         (WebCore::JSCustomSQLStatementErrorCallback::handleEvent):
14         * bindings/v8/custom/V8CustomSQLStatementErrorCallback.cpp:
15         (WebCore::V8CustomSQLStatementErrorCallback::handleEvent):
16         * bindings/v8/custom/V8CustomVoidCallback.cpp:
17         (WebCore::invokeCallback):
18         * bindings/v8/custom/V8CustomVoidCallback.h:
19
20 2010-03-25  Dmitry Titov  <dimich@chromium.org>
21
22         Unreviewed, fix Chromium tests.
23
24         Recent http://trac.webkit.org/changeset/56489 made all urls in Chromium that
25         have unspecified port to return invalidPortNumber from KURL::port().
26
27         * platform/KURLGoogle.cpp: Return 0 for unspecified ports, mimic WebKit KURL behavior for invalid ports.
28         (WebCore::KURL::port):
29
30 2010-03-25  Dirk Schulze  <krit@webkit.org>
31
32         Reviewed by Nikolas Zimmermann.
33
34         This is a follow up of:
35         https://bugs.webkit.org/show_bug.cgi?id=30055
36         Bad DOM performance in large SVG files
37
38         Just save and restore the GraphicsContext, if we realy modify it.
39         (Cairo)Path::contains checks if a point is in the boundingBox
40         as a heuristic. The intention was to make the process faster for
41         points outside of this rect, but it rather causes the
42         opposite.
43
44         No new test cases added. No change in functionality.
45
46         * platform/graphics/cairo/PathCairo.cpp:
47         (WebCore::Path::contains):
48         * rendering/RenderPath.cpp:
49         (WebCore::RenderPath::paint):
50
51 2010-03-25  Ojan Vafai  <ojan@chromium.org>
52
53         Reviewed by David Levin.
54
55         mouse-based selections are always directional on Windows/Linux
56         https://bugs.webkit.org/show_bug.cgi?id=25195
57
58         Change m_lastChangeWasHorizontalExtension to m_isDirectional
59         and make m_isDirectional always be true for Windows/Linux.
60
61         * editing/SelectionController.cpp:
62         (WebCore::SelectionController::SelectionController):
63         (WebCore::SelectionController::setSelection):
64         (WebCore::SelectionController::setIsDirectional):
65         (WebCore::SelectionController::willBeModified):
66         When double-clicking, the base/extent will be in the middle
67         of the selection instead of the start/end of it. Changed to
68         maintain that modifications after double-click still move the
69         start/end of the selection, not the base/extent.
70         (WebCore::SelectionController::modify):
71         * editing/SelectionController.h:
72         * page/EventHandler.cpp:
73         (WebCore::EventHandler::handleMousePressEventSingleClick):
74         (WebCore::EventHandler::updateSelectionForMouseDrag):
75
76 2010-03-25  Simon Fraser  <simon.fraser@apple.com>
77
78         Revert r56565 which was based on an incorrect premise.
79
80         * page/animation/CompositeAnimation.cpp:
81         (WebCore::CompositeAnimation::clearRenderer):
82         (WebCore::CompositeAnimation::updateKeyframeAnimations):
83         (WebCore::CompositeAnimation::getAnimatedStyle):
84         (WebCore::CompositeAnimation::setAnimating):
85         (WebCore::CompositeAnimation::timeToNextService):
86         (WebCore::CompositeAnimation::getAnimationForProperty):
87         (WebCore::CompositeAnimation::suspendAnimations):
88         (WebCore::CompositeAnimation::resumeAnimations):
89         (WebCore::CompositeAnimation::isAnimatingProperty):
90         (WebCore::CompositeAnimation::pauseAnimationAtTime):
91         (WebCore::CompositeAnimation::numberOfActiveAnimations):
92
93 2010-03-25  Simon Fraser  <simon.fraser@apple.com>
94
95         Reviewed by Eric Carlson.
96
97         Make calls to m_keyframeAnimations.checkConsistency() debug-only
98         https://bugs.webkit.org/show_bug.cgi?id=36555
99
100         Remove lots of calls to m_keyframeAnimations.checkConsistency(); which were left after some earlier
101         debugging. Leave one in CompositeAnimation::animate() to catch any future issues, which is OK since
102         these calls are no-ops in release builds.
103         
104         * page/animation/CompositeAnimation.cpp:
105         (WebCore::CompositeAnimation::clearRenderer):
106         (WebCore::CompositeAnimation::updateKeyframeAnimations):
107         (WebCore::CompositeAnimation::getAnimatedStyle):
108         (WebCore::CompositeAnimation::setAnimating):
109         (WebCore::CompositeAnimation::timeToNextService):
110         (WebCore::CompositeAnimation::getAnimationForProperty):
111         (WebCore::CompositeAnimation::suspendAnimations):
112         (WebCore::CompositeAnimation::resumeAnimations):
113         (WebCore::CompositeAnimation::isAnimatingProperty):
114         (WebCore::CompositeAnimation::pauseAnimationAtTime):
115         (WebCore::CompositeAnimation::numberOfActiveAnimations):
116
117 2010-03-25  Simon Fraser  <simon.fraser@apple.com>
118
119         Reviewed by Geoffrey Garen.
120
121         https://bugs.webkit.org/show_bug.cgi?id=36557
122         Animations use the wrong timing-function sometimes
123         
124         Fix an issue where animations picked the wrong style for their "unanimated" value.
125         
126         Previously, the "unanimated" style was considered to be the style before the animation
127         was applied. This caused us to pick up stale values for animation timing functions, for
128         blending when a property is missing from the first keyframe, and for resuming transitions
129         once an animation ends.
130         
131         Instead, we need to use the "current" style, which is the one that causes the animation
132         to kick off.
133
134         Tests: animations/longhand-timing-function.html
135                animations/transition-and-animation-3.html
136                animations/unanimated-style.html
137
138         * page/animation/CompositeAnimation.cpp:
139         (WebCore::CompositeAnimation::updateKeyframeAnimations):
140
141 2010-03-25  Gavin Barraclough  <barraclough@apple.com>
142
143         Reviewed by Geoff Garen.
144
145         Bug 36611 - Cleanup JSC::CString
146         Rename CString::c_str() -> CString::data(), CString::size() -> CString::length(),
147         remove UString::getCString() (all uses are wrong, should use UString::UTF8String()).
148
149         * bridge/NP_jsobject.cpp:
150         (_NPN_Enumerate):
151         * bridge/c/c_utility.cpp:
152         (JSC::Bindings::convertValueToNPVariant):
153         * bridge/jni/jsc/JNIBridgeJSC.cpp:
154         (JavaField::valueFromInstance):
155         (JavaField::setValueToInstance):
156         * bridge/jni/jsc/JavaInstanceJSC.cpp:
157         (JavaInstance::invokeMethod):
158         * bridge/jni/jsc/JavaStringJSC.h:
159         (JSC::Bindings::JavaStringImpl::UTF8String):
160
161 2010-03-25  Jakub Wieczorek  <jwieczorek@webkit.org>
162
163         Reviewed by Eric Seidel.
164
165         [Qt] RenderTheme: fix size adjustment for text fields
166         https://bugs.webkit.org/show_bug.cgi?id=36413
167
168         To match other ports, remove the hardcoded dimensions for text fields so that
169         the default ones from WebCore can be used.
170         Properly apply the correct padding to text areas - this fixes their appearance
171         with the Oxygen style.
172
173         * platform/qt/RenderThemeQt.cpp:
174         (WebCore::RenderThemeQt::computeSizeBasedOnStyle):
175
176 2010-03-25  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
177
178         Reviewed by Simon Hausmann.
179
180         [Qt] Implement ChromeClient::windowResizerRect()
181
182         https://bugs.webkit.org/show_bug.cgi?id=21300
183
184         The helper function geometryRelativeToOwnerWidget() in the page
185         client is used to clip the resize rect to the actual size of the
186         viewport, not the size of the QGraphicsView.
187
188         * platform/qt/QWebPageClient.h:
189
190 2010-03-25  Joseph Pecoraro  <joepeck@webkit.org>
191
192         Reviewed by Pavel Feldman.
193
194         Web Inspector: reloading debug target window with cmd-R from inspector window produces beep.
195         https://bugs.webkit.org/show_bug.cgi?id=36554
196
197         * inspector/front-end/inspector.js:
198         (WebInspector.documentKeyDown): prevent the default behavior, if handled, which would result in a system beep.
199
200 2010-03-25  Jochen Eisinger  <jochen@chromium.org>
201
202         Reviewed by Jeremy Orlow.
203
204         Forward DatabaseTracker::canEstablishDatabase to chromium layer.
205         https://bugs.webkit.org/show_bug.cgi?id=36595
206
207         * storage/chromium/DatabaseObserver.h:
208         * storage/chromium/DatabaseTrackerChromium.cpp:
209         (WebCore::DatabaseTracker::canEstablishDatabase):
210
211 2010-03-25  yael aharon  <yael.aharon@nokia.com>
212
213         Reviewed by Laszlo Gombos.
214
215         [Qt] Windowed netscape plugins don't work with QGraphicsWebView on Symbian
216         https://bugs.webkit.org/show_bug.cgi?id=35112
217
218         Add a proxy widget when loading a QWidget based plugin in a QGraphicsWebView.
219
220         * plugins/symbian/PluginContainerSymbian.cpp:
221         (PluginContainerSymbian::PluginContainerSymbian):
222         (PluginContainerSymbian::focusInEvent):
223         * plugins/symbian/PluginContainerSymbian.h:
224         (WebCore::PluginContainerSymbian::proxy):
225         * plugins/symbian/PluginViewSymbian.cpp:
226         (WebCore::PluginView::updatePluginWidget):
227         (WebCore::PluginView::platformStart):
228         (WebCore::PluginView::platformDestroy):
229
230 2010-03-25  Simon Fraser  <simon.fraser@apple.com>
231
232         Reviewed by Adele Peterson.
233
234         https://bugs.webkit.org/show_bug.cgi?id=35714
235         Computed style on delayed transform animations is incorrect
236         
237         When fetching computed style while a delayed accelerated animation is in effect,
238         we would get the value form the first keyframe, rather than getting the current
239         style.
240         
241         Fix by checking to see whether we've in the delay phase (with no backwards-fill)
242         in KeyframeAnimation::getAnimatedStyle().
243
244         Test: compositing/animation/computed-style-during-delay.html
245
246         * page/animation/KeyframeAnimation.cpp:
247         (WebCore::KeyframeAnimation::getAnimatedStyle):
248
249 2010-03-25  Yury Semikhatsky  <yurys@chromium.org>
250
251         Reviewed by Pavel Feldman.
252
253         Initialize Web Inspector title with inspected page URL when opening Web Inspector.
254
255         https://bugs.webkit.org/show_bug.cgi?id=36534
256
257         * inspector/InspectorController.cpp:
258         (WebCore::InspectorController::setFrontend):
259
260 2010-03-25  Antti Koivisto  <koivisto@iki.fi>
261
262         Reviewed by Kenneth Rohde Christiansen.
263
264         https://bugs.webkit.org/show_bug.cgi?id=36316
265         Tiles of selected content do not update if not in viewport
266         
267         Don't clip repaints to viewport when tiling is enabled.
268
269         * page/Frame.cpp:
270         (WebCore::Frame::setView):
271         (WebCore::Frame::setTiledBackingStoreEnabled):
272
273 2010-03-25  Diego Gonzalez  <diego.gonzalez@openbossa.org>
274
275         Reviewed by Eric Seidel.
276
277         Missing forward ENABLE_DATALIST macro to JavaScript enabled features macros
278         on WebKit.pri
279
280         [Qt] Forward ENABLE_DATALIST macro to JavaScript enabled macros
281         https://bugs.webkit.org/show_bug.cgi?id=36547
282
283         * WebCore.pri:
284
285 2010-03-25  Pavel Feldman  <pfeldman@chromium.org>
286
287         Reviewed by Timothy Hatcher.
288
289         Web Inspector: Expect console object wrapping to fail.
290
291         https://bugs.webkit.org/show_bug.cgi?id=36587
292
293         * inspector/front-end/InjectedScript.js:
294         (injectedScriptConstructor):
295
296 2010-03-25  Joanmarie Diggs  <joanmarie.diggs@gmail.com>
297
298         Reviewed by Eric Seidel.
299
300         https://bugs.webkit.org/show_bug.cgi?id=36371
301         [Gtk] Elements with a title attribute should not be ignored
302
303         * accessibility/AccessibilityRenderObject.cpp:
304         (AccessibilityRenderObject::accessibilityIsIgnored):
305
306 2010-03-24  Steve Block  <steveblock@google.com>
307
308         Reviewed by David Levin.
309
310         Adds a missing ENABLE(WORKERS) guards to the V8 bindings.
311         https://bugs.webkit.org/show_bug.cgi?id=36550
312
313         Build fix only, no new tests.
314
315         * bindings/v8/V8DOMWrapper.cpp:
316         (WebCore::V8DOMWrapper::instantiateV8Object):
317
318 2010-03-25  Leandro Pereira  <leandro@profusion.mobi>
319
320         Reviewed by Eric Seidel.
321
322         Add EFL-specific code to platform/ScrollView.cpp and
323         platform/Scrollbar.cpp.
324         http://webkit.org/b/36305
325
326         * platform/ScrollView.cpp:
327         * platform/Scrollbar.cpp:
328
329 2010-03-25  Tasuku Suzuki  <tasuku.suzuki@nokia.com>
330
331         Reviewed by Eric Seidel.
332
333         [Qt]Fix compile error with QT_NO_LIBRARY
334         https://bugs.webkit.org/show_bug.cgi?id=36533
335
336         * platform/FileSystem.h:
337         * platform/qt/FileSystemQt.cpp:
338         (WebCore::unloadModule):
339
340 2010-03-25  Tasuku Suzuki  <tasuku.suzuki@nokia.com>
341
342         Reviewed by Eric Seidel.
343
344         [Qt]Fix compile error with QT_NO_ANIMATION
345         https://bugs.webkit.org/show_bug.cgi?id=36526
346
347         * platform/graphics/qt/GraphicsLayerQt.cpp:
348         (WebCore::GraphicsLayerQtImpl::~GraphicsLayerQtImpl):
349         * platform/graphics/qt/GraphicsLayerQt.h:
350
351 2010-03-25  Tony Chang  <tony@chromium.org>
352
353         Reviewed by Eric Seidel.
354
355         https://bugs.webkit.org/show_bug.cgi?id=33697
356         Have dragOpFromIEOp("move") return DragOperationGeneric | DragOperationMove
357         because only returning Generic doesn't work for platforms that don't
358         have a generic operation.
359
360         Covered by existing tests (fast/events/drag-and-drop.html).
361
362         * dom/Clipboard.cpp:
363         (WebCore::dragOpFromIEOp):
364         (WebCore::Clipboard::destinationOperation):
365         (WebCore::Clipboard::setDestinationOperation):
366
367 2010-03-25  Fumitoshi Ukai  <ukai@chromium.org>
368
369         Reviewed by Eric Seidel.
370
371         [Qt] websocket/tests/long-invalid-header.html fails
372         https://bugs.webkit.org/show_bug.cgi?id=36492
373
374         trim message at most 128 bytes from the current position.
375         I believe it's enough data to investigate the error reason and
376         it makes test not depend on buffered size.
377
378         * websockets/WebSocketHandshake.cpp:
379         (WebCore::trimConsoleMessage):
380         (WebCore::WebSocketHandshake::readServerHandshake):
381         (WebCore::WebSocketHandshake::readHTTPHeaders):
382
383 2010-03-24  Jon Honeycutt  <jhoneycutt@apple.com>
384
385         <rdar://problem/7780798> Missing plug-ins should be represented by text
386         only, instead of lego block
387
388         https://bugs.webkit.org/show_bug.cgi?id=36583
389
390         Reviewed by Dan Bernstein.
391
392         * rendering/RenderEmbeddedObject.cpp:
393         (WebCore::RenderEmbeddedObject::paintReplaced):
394         Set the font rendering mode and the computed size, so that the text will
395         draw properly on Windows.
396
397 2010-03-24  Vangelis Kokkevis  <vangelis@chromium.org>
398
399         Reviewed by Dimitri Glazkov.
400
401         Removing unecessary redraws of LayerSkia contents:
402         https://bugs.webkit.org/show_bug.cgi?id=36470
403
404         Test: No new functionality added, no tests.
405
406         * platform/graphics/skia/LayerRendererSkia.cpp:
407         (WebCore::LayerRendererSkia::drawLayerInCanvasRecursive):
408         Debug borders now rendered at composite time rather than update time.
409         * platform/graphics/skia/LayerSkia.cpp:
410         (WebCore::LayerSkia::updateContents):
411         (WebCore::LayerSkia::drawDebugBorder):
412         Debug border drawing removed from updateContents and split into a separate method that
413         can be called at composite time.
414         (WebCore::LayerSkia::setBounds):
415         Resetting the bounds causes the layer to redraw its contents.
416         (WebCore::LayerSkia::setNeedsDisplay):
417         * platform/graphics/skia/LayerSkia.h:
418         Added declaration for drawDebugBorders method.
419
420 2010-03-24  Mark Rowe  <mrowe@apple.com>
421
422         Revert the portion of r56489 that dealt with port zero as it introduced some test failures.
423
424         * platform/KURL.cpp:
425         (WebCore::KURL::port): Use the "ok" argument to charactersToUIntStrict to determine whether
426         it was able to successfully parse the string as an unsigned integer, rather than relying on
427         the fact it returned zero when it failed.
428
429 2010-03-24  Gavin Barraclough  <barraclough@apple.com>
430
431         Reviewed by Sam Weinig.
432
433         * platform/text/String.cpp:
434         (WebCore::putUTF8Triple): Correct capitalization of function name.
435         (WebCore::String::utf8): Fix C-style casts.
436         (WebCore::String::fromUTF8): Remove unnecessary newline.
437         (WebCore::String::fromUTF8WithLatin1Fallback): Use early return.
438
439 2010-03-24  Mark Rowe  <mrowe@apple.com>
440
441         Reviewed by Darin Adler.
442
443         WebKit should treat port numbers outside the valid range as being blacklisted
444         <http://webkit.org/b/36571> / <rdar://problem/7790908>
445
446         * platform/KURL.cpp:
447         (WebCore::KURL::port): Map invalid port numbers to invalidPortNumber.
448         (WebCore::portAllowed): Add invalidPortNumber to the blacklist.
449         * platform/KURLGoogle.cpp:  invalid port numbers to invalidPortNumber.
450         (WebCore::KURL::port): Add invalidPortNumber to the blacklist.
451         Also bring this in to sync with KURL.  Having this identical code in two places is stupid.
452
453 2010-03-24  Sam Weinig  <sam@webkit.org>
454
455         Reviewed by Mark Rowe.
456
457         Add some missing exports.
458
459         * WebCore.base.exp:
460
461 2010-03-24  Gavin Barraclough  <barraclough@apple.com>
462
463         Reviewed by Sam Weinig.
464
465         Switch String::latin1, String::utf8, String::fromUTF8 to
466         use WTF's Unicode conversion methods rather than TextEncoder.
467         These methods only perform simple conversion, and don't need
468         really require TextEncoder's full capability (to look up arbitrary
469         encodings by name), switching to only be dependent on WTF will
470         make it easier if we chose to move WebCore::String to WTF.
471
472         * platform/text/String.cpp:
473         (WebCore::String::latin1):
474         (WebCore::putUTF8triple):
475         (WebCore::String::utf8):
476         (WebCore::String::fromUTF8):
477
478 2010-03-24  Dmitry Titov  <dimich@chromium.org>
479
480         No review, rolling out r56453.
481         http://trac.webkit.org/changeset/56453
482         https://bugs.webkit.org/show_bug.cgi?id=36426
483
484         In Chromium port, it broke invalid-image-data-standalone.html
485         invalid-image-data.html multipart-wait-before-boundary.html
486         stop-crash.html win-boundary-crash.html
487
488         * loader/FrameLoader.cpp:
489         (WebCore::FrameLoader::finishedLoadingDocument):
490
491 2010-03-24  Ilya Tikhonovsky  <loislo@chromium.org>
492
493         Reviewed by Pavel Feldman.
494
495         Web Inspector: Significant scroll speed degradation if Timeline has
496         an expanded record with significant number of children.
497         https://bugs.webkit.org/show_bug.cgi?id=36543
498
499
500         * inspector/front-end/TimelinePanel.js:
501         (WebInspector.TimelinePanel.prototype._updateBoundaries):
502         (WebInspector.TimelinePanel.prototype._addToRecordsWindow):
503         (WebInspector.TimelinePanel.prototype._filterRecords):
504         (WebInspector.TimelinePanel.prototype._refreshRecords):
505
506 2010-03-24  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
507
508         Reviewed by Eric Carlson.
509
510         [GStreamer] Fails to go to Loaded state because of floating point discrepancies
511         https://bugs.webkit.org/show_bug.cgi?id=35891
512
513         Use the m_fillStatus variable, which is more reliable, instead of
514         using the calculation, for the completed case.
515
516         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
517         (WebCore::MediaPlayerPrivate::fillTimerFired):
518
519 2010-03-24  Dmitry Titov  <dimich@chromium.org>
520
521         Unreviewed, Chromium test fix.
522
523         Recent r56445 added CustomEvent and a test but it didn't work on Chromium bots.
524         Test crashed due to infinte recursion because the compiler did not have the right definition of toV8(CustomEvent*)
525         and was substituting toV8(Event*).
526
527         Fixing test fast/events/custom-event.html
528
529         * bindings/v8/custom/V8EventCustom.cpp:
530
531 2010-03-24  MORITA Hajime  <morrita@google.com>
532
533         Reviewed by Darin Adler.
534
535         Refactoring: HTMLFormControlElement should not have redundant null check
536         https://bugs.webkit.org/show_bug.cgi?id=36487
537         
538         No new tests as there is no new functionality.        
539
540         * html/HTMLFormControlElement.cpp:
541         (WebCore::HTMLFormControlElement::dispatchFocusEvent):
542         (WebCore::HTMLFormControlElement::dispatchBlurEvent):
543
544 2010-03-24  Eric Uhrhane  <ericu@chromium.org>
545
546         Reviewed by Alexey Proskuryakov.
547
548         DOMCoreException needs NoStaticTables modifier
549         https://bugs.webkit.org/show_bug.cgi?id=36458
550
551         No new tests, but this shows up in tests of Database accesses from the
552         Worker thread that I'll be checking in soon.  The symptom is that
553         DOMCoreException.toString() returns [object DOMException] instead of
554         something more helpful.
555
556         * dom/DOMCoreException.idl:  Added NoStaticTables.
557
558 2010-03-24  Drew Wilson  <atwilson@chromium.org>
559
560         Reviewed by Dmitry Titov.
561
562         Failed assertion in V8Proxy::setDOMException() if worker is shutting down.
563         https://bugs.webkit.org/show_bug.cgi?id=36514
564
565         Test: none (existing worker tests suffice)
566
567         * bindings/v8/V8Proxy.cpp:
568         (WebCore::V8Proxy::setDOMException):
569         Updated setDOMException() to check for an empty exception (due to no active context) and avoid throwing in that case.
570
571 2010-03-23  Evan Martin  <evan@chromium.org>
572
573         Reviewed by Dmitry Titov.
574
575         [chromium] use integral glyph widths
576         https://bugs.webkit.org/show_bug.cgi?id=36510
577
578         Despite WebKit (and Skia, to an extent) supporting non-integral
579         glyph widths, the font code path we hit in Skia only supports
580         integral glyph positions.  This means that we would accumulate
581         offsets when drawing a sequence up non-integer-width glyphs
582         which would cause gaps when snapped to the pixel grid when drawing.
583
584         * platform/graphics/chromium/SimpleFontDataLinux.cpp:
585         (WebCore::SimpleFontData::platformWidthForGlyph):
586         round glyph widths to integers.
587
588 2010-03-24  Dean Jackson  <dino@apple.com>
589
590         Reviewed by Kevin Decker.
591
592         <rdar://problem/7785305>
593         Fix regression caused by r55576. It turned out that ensuring
594         CoreAnimation always gets a correct fill parameter caused flashing
595         as non-filled animations ended (CA briefly showed the initial animation
596         value before the style system set the final value).
597
598         * platform/graphics/mac/GraphicsLayerCA.mm:
599         (WebCore::GraphicsLayerCA::setupAnimation):
600
601 2010-03-24  Hayato Ito  <hayato@chromium.org>
602
603         Reviewed by Shinichiro Hamaji.
604
605         Refactor computePageRects so that Mac can make use of it.
606         https://bugs.webkit.org/show_bug.cgi?id=36159
607
608         Refactoring only, so no new tests.
609
610         * WebCore.base.exp:
611         * page/PrintContext.cpp:
612         (WebCore::PrintContext::computePageRects):
613         (WebCore::PrintContext::computePageRectsWithPageSize):
614         (WebCore::PrintContext::computePageRectsWithPageSizeInternal):
615         (WebCore::PrintContext::pageNumberForElement):
616         (WebCore::PrintContext::numberOfPages):
617         * page/PrintContext.h:
618
619 2010-03-24  Jeremy Moskovich  <jeremy@chromium.org>
620
621         Reviewed by Jeremy Orlow.
622
623         Add some diagnostics to try to track down cause of crash in ArchiveFactory::isArchiveMimeType().
624
625         https://bugs.webkit.org/show_bug.cgi?id=36426
626
627         No new tests as there is no new functionality.
628
629         * loader/FrameLoader.cpp:
630         (WebCore::FrameLoader::finishedLoadingDocument): Make copy of mimeType string to isolate crash.
631
632 2010-03-24  Anton Muhin  <antonm@chromium.org>
633
634         Reviewed by Nate Chapin.
635
636         Use newly introduced SetPrototype method to deal with global objects.
637         https://bugs.webkit.org/show_bug.cgi?id=36497
638
639         No new tests, should be covered by the current test infrastructure.
640
641         * bindings/v8/V8DOMWindowShell.cpp:
642         (WebCore::V8DOMWindowShell::installDOMWindow):
643         * bindings/v8/V8DOMWrapper.cpp:
644         (WebCore::V8DOMWrapper::getConstructor):
645         * bindings/v8/WorkerContextExecutionProxy.cpp:
646         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
647
648 2010-03-24  Dmitry Titov  <dimich@chromium.org>
649
650         Unreviewed, Chromium build fix.
651
652         * platform/chromium/PopupMenuChromium.cpp:
653         (WebCore::PopupContainer::PopupContainer): Fix order of initializers.
654         (WebCore::PopupContainer::layout): Remove unused variable.
655
656 2010-03-23  Kenneth Rohde Christiansen  <kenneth@webkit.org>
657
658         Reviewed by Simon Hausmann.
659
660         Add a way to check if the page client is making use of
661         a QWidget.
662
663         * platform/qt/QWebPageClient.h:
664         (QWebPageClient::isQWidgetClient):
665
666 2010-03-24  Jay Campan  <jcampan@google.com>
667
668         Reviewed by Darin Fisher.
669
670         Making Chromium select popups not steal activation from the browser.
671         Select popups are now like autocomplete popups, shown in non-activated
672         windows.
673         https://bugs.webkit.org/show_bug.cgi?id=36062
674
675         * page/chromium/ChromeClientChromium.h:
676         * platform/chromium/PopupMenuChromium.cpp:
677         (WebCore::):
678         (WebCore::PopupListBox::setMaxHeight):
679         (WebCore::PopupListBox::disconnectClient):
680         (WebCore::PopupListBox::PopupListBox):
681         (WebCore::PopupContainer::create):
682         (WebCore::PopupContainer::PopupContainer):
683         (WebCore::PopupContainer::showPopup):
684         (WebCore::PopupContainer::showExternal):
685         (WebCore::PopupContainer::hidePopup):
686         (WebCore::PopupContainer::layout):
687         (WebCore::PopupContainer::chromeClientChromium):
688         (WebCore::PopupListBox::hidePopup):
689         (WebCore::PopupListBox::layout):
690         (WebCore::PopupMenu::~PopupMenu):
691         (WebCore::PopupMenu::show):
692         * platform/chromium/PopupMenuChromium.h:
693         (WebCore::PopupItem::):
694         (WebCore::PopupItem::PopupItem):
695         (WebCore::PopupContainerSettings::):
696         (WebCore::PopupContainer::):
697         (WebCore::PopupContainer::listBox):
698         (WebCore::PopupContainer::popupType):
699
700 2010-03-10  David Levin  <levin@chromium.org>
701
702         Reviewed by Oliver Hunt.
703
704         Need to move items that CanvasRenderingContext2D depends on into CanvasSurface.
705         https://bugs.webkit.org/show_bug.cgi?id=35453
706
707         Prepartory changes to allow for an OffscreenCanvas which may be used in a worker
708         or outside of the DOM.
709
710         No change in functionality, so new tests.
711
712         * dom/CanvasSurface.cpp: Moved functionality that CanvasRenderingContext2D depends on
713         into this class (and removed dependencies on document/html element).
714         (WebCore::CanvasSurface::CanvasSurface):
715         (WebCore::CanvasSurface::~CanvasSurface): Put the desctructor in the cpp file
716         to avoid needing access to ~ImageBuffer in the header file.
717         (WebCore::CanvasSurface::setSurfaceSize): Does basic items needed
718         when the size changes. It is protected to force outside callers to go
719         through HTMLCanvasElement::setSize.
720         (WebCore::CanvasSurface::toDataURL): Just moved from HTMLCanvasElement and
721         made a note about a method to fix for worker usage.
722         (WebCore::CanvasSurface::willDraw): Made this virtual to allow an overide
723         which uses the renderbox and tracks a dirtyRect.
724         (WebCore::CanvasSurface::convertLogicalToDevice): Moved and changed to
725         rely on a member variable for page scale (to avoid using the document).
726         (WebCore::CanvasSurface::createImageBuffer):
727         (WebCore::CanvasSurface::drawingContext): Simple move from HTMLCanvasElement.
728         (WebCore::CanvasSurface::buffer): Ditto.
729         (WebCore::CanvasSurface::baseTransform): Ditto.
730         * dom/CanvasSurface.h:
731         (WebCore::CanvasSurface::width): Simple move from HTMLCanvasElement.
732         (WebCore::CanvasSurface::height): Ditto.
733         (WebCore::CanvasSurface::size): Ditto.
734         (WebCore::CanvasSurface::setOriginTainted): Ditto.
735         (WebCore::CanvasSurface::originClean): Ditto.
736         (WebCore::CanvasSurface::hasCreatedImageBuffer): Ditto (with small name change).
737         * html/HTMLCanvasElement.cpp:
738         (WebCore::HTMLCanvasElement::HTMLCanvasElement): Pass in the scale factor to CanvasSurface
739         so it doesn't need the document.
740         (WebCore::HTMLCanvasElement::willDraw): Moved the relevant portion to CanvasSurface.
741         (WebCore::HTMLCanvasElement::reset): Small changes due to refactoring.
742         (WebCore::HTMLCanvasElement::paint): Ditto.
743         * html/HTMLCanvasElement.h:
744         (WebCore::HTMLCanvasElement::setSize): Ditto.
745         * platform/MIMETypeRegistry.cpp:
746         (WebCore::MIMETypeRegistry::isSupportedImageMIMETypeForEncoding): Added assert
747         to verify that this is only called on the main thread.
748         * platform/graphics/Image.cpp:
749         (WebCore::Image::nullImage): Ditto.
750         * platform/graphics/cg/ImageBufferCG.cpp:
751         (WebCore::utiFromMIMEType): Ditto.
752
753 2010-03-24  Alexander Pavlov  <apavlov@chromium.org>
754
755         Reviewed by Pavel Feldman.
756
757         Inspector: XML Tags should not be converted to lowercase
758         https://bugs.webkit.org/show_bug.cgi?id=28600
759
760         * inspector/front-end/ElementsPanel.js:
761         (WebInspector.ElementsPanel.prototype.updateBreadcrumb):
762         (WebInspector.ElementsPanel.prototype.decorateNodeLabel):
763         * inspector/front-end/ElementsTreeOutline.js:
764         (WebInspector.ElementsTreeOutline.prototype.nodeNameToCorrectCase):
765         (WebInspector.ElementsTreeElement.prototype._updateChildren):
766         (WebInspector.ElementsTreeElement.prototype._nodeTitleInfo):
767
768 2010-03-03  Kenneth Rohde Christiansen  <kenneth@webkit.org>
769
770         Reviewed by Antti Koivisto.
771
772         Add support for DOM Level 3 Custom Event
773         http://www.w3.org/TR/DOM-Level-3-Events
774
775         V8 Generator change by Nate Chapin <japhet@chromium.org>, Thanks!
776
777         Test: fast/events/custom-event.html
778
779         * DerivedSources.cpp:
780         * GNUmakefile.am:
781         * WebCore.gypi:
782         * WebCore.pri:
783         * WebCore.pro:
784         * WebCore/DerivedSources.make:
785         * WebCore.vcproj/WebCore.vcproj:
786         * WebCore.xcodeproj/project.pbxproj:
787         * bindings/js/JSEventCustom.cpp:
788         (WebCore::toJS):
789         * bindings/scripts/CodeGeneratorJS.pm:
790         * bindings/scripts/CodeGeneratorV8.pm:
791         * dom/CustomEvent.cpp: Added.
792         (WebCore::CustomEvent::CustomEvent):
793         (WebCore::CustomEvent::initCustomEvent):
794         (WebCore::CustomEvent::isCustomEvent):
795         * dom/CustomEvent.h: Added.
796         (WebCore::CustomEvent::create):
797         (WebCore::CustomEvent::detail):
798         * dom/Document.cpp:
799         (WebCore::Document::createEvent):
800         * dom/Event.cpp:
801         (WebCore::Event::isCustomEvent):
802         * dom/Event.h:
803
804 2010-03-24  Alexander Pavlov  <apavlov@chromium.org>
805
806         Reviewed by Pavel Feldman.
807
808         Web Inspector: Error when highlighting JavaScript with an invalid mime type
809         https://bugs.webkit.org/show_bug.cgi?id=36530
810
811         * inspector/front-end/SourceTokenizer.js:
812         (WebInspector.SourceTokenizer.Registry):
813         * inspector/front-end/SourceView.js:
814         (WebInspector.SourceView.prototype._contentLoaded):
815         (WebInspector.SourceView.prototype._canonicalMimeType):
816         * inspector/front-end/TextEditorHighlighter.js:
817         (WebInspector.TextEditorHighlighter):
818
819 2010-03-24  Pavel Feldman  <pfeldman@chromium.org>
820
821         Not reviewed. Chromium test fix: added a frameCount check to the
822         debugger function call.
823
824         * bindings/v8/V8Proxy.cpp:
825         (WebCore::V8Proxy::createUtilityContext):
826
827 2010-03-19  Miikka Heikkinen  <miikka.heikkinen@digia.com>
828
829         Reviewed by Simon Hausmann.
830
831         [Qt] Support for QT_LIBINFIX in Symbian builds
832
833         Configuring Qt with -qtlibinfix parameter will enable installing
834         an alternate version of Qt on devices that already have it on ROM.
835         This patch provides support for infixed builds of Webkit.
836
837         * WebCore.pro:
838
839 2010-03-24  Kent Tamura  <tkent@chromium.org>
840
841         Reviewed by Darin Adler.
842
843         Make Icon::createIconForFiles() optional.
844         https://bugs.webkit.org/show_bug.cgi?id=35072
845
846         r54923 made Icon::createIconForFiles() deprecated. However moving
847         existing icon loading code to outside of WebCore is not good.  So,
848         we assume:
849         - ChromeClient::chooseIconForFiles(), renamed from iconForFiles(), is
850           the primary API to load icons.
851         - Icon::createIconForFiles() is an optional API to help
852           implementing ChromeClient::iconForFiles().
853
854         This patch removes a call to Icon::createIconForFiles() from
855         FileChooser::loadIcon(), and ChromeClient::chooseIconForFiles() of
856         non-Chromium ports calls Icon::createIconForFiles().
857
858         * WebCore.base.exp: Export FileChooser::iconLoaded(),
859           Icon::createIconForFiles(), and Icon::~Icon().
860         * WebCore.xcodeproj/project.pbxproj: Export Icon.h
861         * loader/EmptyClient.h: Rename iconForFiles() to chooseIconForFiles().
862         * page/Chrome.cpp: ditto.
863         * page/Chrome.h: ditto.
864         * page/ChromeClient.h: ditto.
865         * platform/FileChooser.cpp:
866         (WebCore::FileChooser::loadIcon):
867         * platform/graphics/Icon.h: Remove a comment on createIconForFiles().
868         * platform/graphics/chromium/IconChromiumLinux.cpp: Remove createIconForFiles().
869         * platform/graphics/chromium/IconChromiumMac.cpp: ditto.
870         * platform/graphics/chromium/IconChromiumWin.cpp: ditto.
871         * rendering/RenderFileUploadControl.cpp: Rename iconForFiles() to chooseIconForFiles().
872         * rendering/RenderFileUploadControl.h: ditto.
873
874 2010-03-23  Dan Bernstein  <mitz@apple.com>
875
876         Fixed typos.
877
878         * manual-tests/plugin-visible-rect-change.html:
879
880 2010-03-23  Dan Bernstein  <mitz@apple.com>
881
882         Reviewed by John Sullivan.
883
884         WebCore part of
885         <rdar://problem/7197736> Plug-in clip rect does not update when overflow
886         clip changes
887         https://bugs.webkit.org/show_bug.cgi?id=36479.
888
889         * manual-tests/plugin-visible-rect-change.html: Added.
890         * platform/mac/WidgetMac.mm:
891         (WebCore::WidgetPrivate::WidgetPrivate): Added previousVisibleRect.
892         (WebCore::Widget::setFrameRect): If the visible rect changed but the
893         frame rect did not, send a -visibleRectDidChange message to the view,
894         if it responds to it.
895         (WebCore::Widget::releasePlatformWidget): Reset previousVisibleRect.
896         * rendering/RenderWidget.cpp:
897         (WebCore::RenderWidget::setWidgetGeometry): Track changes to the clip rect
898         imposed by the enclosing layer. Call Widget::setFrameRect when it changes,
899         even if the frame rect did not.
900         * rendering/RenderWidget.h:
901         (WebCore::RenderWidget::windowClipRect): Added this accessor.
902
903 2010-03-23  Simon Fraser  <simon.fraser@apple.com>
904
905         Reviewed by Dan Bernstein.
906
907         Assertion ASSERTION FAILED: rootLayer == m_clipRectsRoot at hulu.com
908         https://bugs.webkit.org/show_bug.cgi?id=34065
909         
910         Fix another cause of assertions related to the clip rects root. Embeds
911         with zero size caused the overlap testing to fail, yet we require them to work
912         for correct compositing, so when the composited bounds is empty, use a 1x1 rect
913         for overlap testing.
914
915         Test: compositing/geometry/empty-embed-rects.html
916
917         * rendering/RenderLayerCompositor.cpp:
918         (WebCore::RenderLayerCompositor::addToOverlapMap):
919         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
920
921 2010-03-23  David Levin  <levin@chromium.org>
922
923         Reviewed by Nate Chapin.
924
925         [chromium] XMLHttpRequest.send sends 'undefined' string when passed undefined value.
926         https://bugs.webkit.org/show_bug.cgi?id=36506
927
928         Test: http/tests/xmlhttprequest/send-undefined-and-null.html
929
930         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
931         (WebCore::isDocumentType): Unrelated style fix: fixed the casing of the method.
932         (WebCore::V8XMLHttpRequest::sendCallback): Added check for null/undefined to do the send.
933         This mirrors what is done in the JSC bindings. Previously, sending 'null' worked because
934         the last case, which did "toWebCoreStringWithNullCheck", resulted in sending an empty
935         request body.
936
937 2010-03-23  Chris Evans  <cevans@chromium.org>
938
939         Reviewed by Darin Adler.
940
941         Fix hard-to-see crash due to incorrect libxml API usage.
942
943         https://bugs.webkit.org/show_bug.cgi?id=36000
944
945         Test: fast/text/bad-encoding.html
946
947         * dom/XMLTokenizerLibxml2.cpp:
948         (WebCore::XMLTokenizer::doEnd): Avoid operations on a closed context.
949
950 2010-03-23  Nate Chapin  <japhet@chromium.org>
951
952         Unreviewed, revert r56376.
953
954         This revision introduced a crash in a couple of layout tests
955         on Chromium Linux.
956
957         * page/chromium/ChromeClientChromium.h:
958         * platform/chromium/PopupMenuChromium.cpp:
959         (WebCore::):
960         (WebCore::PopupContainer::create):
961         (WebCore::PopupContainer::PopupContainer):
962         (WebCore::PopupContainer::showPopup):
963         (WebCore::PopupContainer::showExternal):
964         (WebCore::PopupContainer::hidePopup):
965         (WebCore::PopupMenu::show):
966         * platform/chromium/PopupMenuChromium.h:
967         (WebCore::PopupItem::):
968         (WebCore::PopupItem::PopupItem):
969         (WebCore::PopupContainerSettings::):
970         (WebCore::PopupContainer::listBox):
971
972 2010-03-23  David Hyatt  <hyatt@apple.com>
973
974         Reviewed by Simon Fraser and Darin Adler.
975
976         https://bugs.webkit.org/show_bug.cgi?id=36272, make sure nth-child can work when the portion with "n" is omitted.
977
978         Added fast/css/nth-child-implied-step.html
979
980         * css/CSSGrammar.y:
981         * css/tokenizer.flex:
982
983 2010-03-23  Darin Adler  <darin@apple.com>
984
985         Reviewed by Sam Weinig.
986
987         Reduce and straighten internal use of DOMImplementation
988         https://bugs.webkit.org/show_bug.cgi?id=36501
989
990         * WebCore.xcodeproj/project.pbxproj: Xcode decided to
991         re-sort this file.
992
993         * dom/Clipboard.cpp: Removed unneeded include of DOMImplementation.h.
994
995         * dom/DOMImplementation.cpp: Removed unneeded createDocument and
996         createHTMLDocument functions. These should be done directly instead
997         of involving the DOMImplementation class.
998         * dom/DOMImplementation.h: Ditto.
999
1000         * dom/DocumentType.cpp: Removed unneeded include of DOMImplementation.h.
1001
1002         * html/HTMLViewSourceDocument.cpp:
1003         (WebCore::HTMLViewSourceDocument::createTokenizer): Don't allocate a
1004         DOMImplementation object just to use a class member function.
1005
1006         * loader/CachedFont.cpp: Removed unneeded include of DOMImplementation.h.
1007
1008         * xml/XMLHttpRequest.cpp:
1009         (WebCore::XMLHttpRequest::responseXML): Use Document::create to create a
1010         new document instead of involving DOMImplementation.
1011         * xml/XSLTProcessor.cpp:
1012         (WebCore::XSLTProcessor::createDocumentFromSource): Ditto. And in the case
1013         where we do need to call DOMImplementation to interpret the MIME type,
1014         don't allocate a DOMImplementation object just to use a class member
1015         function.
1016
1017 2010-03-23  Luiz Agostini  <luiz.agostini@openbossa.org>
1018
1019         Reviewed by Kenneth Rohde Christiansen.
1020
1021         [Qt] Maemo5 theme - all <select> elements should be rendered as menu lists.
1022         https://bugs.webkit.org/show_bug.cgi?id=36367
1023
1024         Enabling NO_LISTBOX_RENDERING in WebCore.pri for Maemo5.
1025
1026         * WebCore.pri:
1027
1028 2010-03-22  Joseph Pecoraro  <joepeck@webkit.org>
1029
1030         Reviewed by David Kilzer.
1031
1032         Upstream iPhone KeyEvent platform code and share with Mac platform
1033         https://bugs.webkit.org/show_bug.cgi?id=35870
1034
1035         * platform/iphone/KeyEventCodesIPhone.h: Improper comment for #endif.
1036         * platform/iphone/KeyEventIPhone.mm: Fixed headers.
1037
1038 2010-03-23  David Hyatt  <hyatt@apple.com>
1039
1040         Reviewed by Jeremy Orlow.
1041
1042         https://bugs.webkit.org/show_bug.cgi?id=36277, make sure nth-child supports the positive unary prefix (+) as well as the negative
1043         one (-).
1044
1045         Added fast/css/nth-child-unary-prefix.html
1046
1047         * css/tokenizer.flex:
1048
1049 2010-03-23  Andrey Kosyakov  <caseq@chromium.org>
1050
1051         Reviewed by Dmitry Titov.
1052
1053         Change notification sent to inspector frontend on workers creation / destruction
1054         to be posted asynchronously to avoid JS reenterability problems. Also, renamed
1055         willDestroyWorker to didDestroyWorker to reflect that it gets called later and got
1056         rid of explicit IDs for workers (use addresses instead).
1057         https://bugs.webkit.org/show_bug.cgi?id=36213
1058
1059         * inspector/InjectedScriptHost.cpp:
1060         (WebCore::InjectedScriptHost::didDestroyWorker):
1061         * inspector/InjectedScriptHost.h:
1062         * inspector/InjectedScriptHost.idl:
1063         * inspector/InspectorController.cpp:
1064         (WebCore::PostWorkerNotificationToFrontendTask::create):
1065         (WebCore::PostWorkerNotificationToFrontendTask::PostWorkerNotificationToFrontendTask):
1066         (WebCore::PostWorkerNotificationToFrontendTask::performTask):
1067         (WebCore::InspectorController::postWorkerNotificationToFrontend):
1068         (WebCore::InspectorController::didCreateWorker):
1069         (WebCore::InspectorController::didDestroyWorker):
1070         * inspector/InspectorController.h:
1071         (WebCore::InspectorController::):
1072         * inspector/InspectorFrontend.cpp:
1073         (WebCore::InspectorFrontend::didDestroyWorker):
1074         * inspector/InspectorFrontend.h:
1075         * inspector/InspectorWorkerResource.h:
1076         (WebCore::InspectorWorkerResource::create):
1077         (WebCore::InspectorWorkerResource::id):
1078         (WebCore::InspectorWorkerResource::InspectorWorkerResource):
1079         * inspector/front-end/InjectedFakeWorker.js:
1080         (InjectedFakeWorker.FakeWorker.prototype.terminate):
1081         * inspector/front-end/WorkersSidebarPane.js:
1082         (WebInspector.didDestroyWorker):
1083         * workers/AbstractWorker.cpp:
1084         (WebCore::AbstractWorker::AbstractWorker):
1085         (WebCore::AbstractWorker::onDestroyWorker):
1086         * workers/AbstractWorker.h:
1087         (WebCore::AbstractWorker::asID):
1088         * workers/SharedWorker.cpp:
1089         (WebCore::SharedWorker::SharedWorker):
1090         * workers/Worker.cpp:
1091         (WebCore::Worker::Worker):
1092
1093 2010-03-22  David Hyatt  <hyatt@apple.com>
1094
1095         Reviewed by Sam Weinig.
1096
1097         https://bugs.webkit.org/show_bug.cgi?id=36266, support DOM Level 3 focusin/focusout events.  Add support for
1098         IE onfocusin/onfocusout extensions to HTML.  The old DOM level 2 names (DOMFocusIn/DOMFocusOut are still supported).
1099
1100         Added fast/events/focusinout.html
1101
1102         * dom/Document.cpp:
1103         (WebCore::Document::setFocusedNode):
1104         * dom/Event.cpp:
1105         (WebCore::Event::aliasedType):
1106         (WebCore::Event::hasAliasedType):
1107         * dom/Event.h:
1108         * dom/EventNames.h:
1109         * dom/EventTarget.cpp:
1110         (WebCore::EventTarget::fireEventListeners):
1111         * dom/EventTarget.h:
1112         * dom/Node.cpp:
1113         (WebCore::Node::dispatchUIEvent):
1114         * html/HTMLAttributeNames.in:
1115         * html/HTMLButtonElement.cpp:
1116         (WebCore::HTMLButtonElement::parseMappedAttribute):
1117         * html/HTMLElement.cpp:
1118         (WebCore::HTMLElement::parseMappedAttribute):
1119         * html/HTMLFormControlElement.cpp:
1120         (WebCore::HTMLTextFormControlElement::parseMappedAttribute):
1121         * html/HTMLFrameSetElement.cpp:
1122         (WebCore::HTMLFrameSetElement::parseMappedAttribute):
1123         * html/HTMLSelectElement.cpp:
1124         (WebCore::HTMLSelectElement::parseMappedAttribute):
1125         * svg/SVGElement.cpp:
1126         (WebCore::SVGElement::parseMappedAttribute):
1127
1128 2010-03-23  MORITA Hajime  <morrita@google.com>
1129
1130         Reviewed by Alexey Proskuryakov.
1131
1132         WebCore::SelectionController::setSelection NULL pointer
1133         https://bugs.webkit.org/show_bug.cgi?id=31545
1134
1135         Added missing NULL-check that other APIs have.
1136
1137         Test: svg/dom/frame-related-api-during-load.html
1138
1139         * svg/SVGSVGElement.cpp:
1140         (WebCore::SVGSVGElement::deselectAll):
1141
1142 2010-03-23  Qi Zhang  <qi.2.zhang@nokia.com>
1143
1144         Reviewed by Simon Hausmann.
1145
1146         [Qt] LayoutTests/fast/canvas/fillrect_gradient.html failed
1147         https://bugs.webkit.org/show_bug.cgi?id=36444
1148
1149         Handle duplicated or unsorted colorStop at platformDestory
1150
1151         * platform/graphics/qt/GradientQt.cpp:
1152         (WebCore::Gradient::platformGradient):
1153
1154 2010-03-23  Julien Chaffraix  <jchaffraix@webkit.org>
1155
1156         Unreviewed build fix.
1157
1158         Try to make the window buildbot happy.
1159
1160         * xml/XMLHttpRequestProgressEventThrottle.cpp:
1161         * xml/XMLHttpRequestProgressEventThrottle.h: Move initialization of the
1162         static const in the cpp file.
1163
1164 2010-03-23  Pavel Feldman  <pfeldman@chromium.org>
1165
1166         Reviewed by Timothy Hatcher.
1167
1168         Web Inspector: make gear menu appear on styles panel at all times.
1169
1170         https://bugs.webkit.org/show_bug.cgi?id=36490
1171
1172         * inspector/front-end/inspector.css:
1173
1174 2010-03-23  Pavel Feldman  <pfeldman@chromium.org>
1175
1176         Reviewed by Timothy Hatcher.
1177
1178         Web Inspector: render nodes in inherited style bars as links.
1179
1180         https://bugs.webkit.org/show_bug.cgi?id=36486
1181
1182         * English.lproj/localizedStrings.js:
1183         * inspector/front-end/BreakpointsSidebarPane.js:
1184         (WebInspector.BreakpointsSidebarPane.prototype._appendBreakpointElement.breakpointClicked):
1185         (WebInspector.BreakpointsSidebarPane.prototype._appendBreakpointElement):
1186         * inspector/front-end/StylesSidebarPane.js:
1187         (WebInspector.StylesSidebarPane.prototype._update.else.insertInheritedNodeSeparator):
1188         (WebInspector.StylesSidebarPane.prototype._update):
1189         (WebInspector.StylesSidebarPane.prototype._selectNode):
1190         * inspector/front-end/inspector.js:
1191
1192 2010-03-23  Julien Chaffraix  <jchaffraix@webkit.org>
1193
1194         Reviewed by Alexey Proskuryakov.
1195
1196         [XHR] onProgress event needs to be dispatched according to what the specification states
1197         https://bugs.webkit.org/show_bug.cgi?id=18654
1198
1199         Test: http/tests/xmlhttprequest/xmlhttprequest-50ms-download-dispatch.html
1200
1201         * Android.mk:
1202         * GNUmakefile.am:
1203         * WebCore.gypi:
1204         * WebCore.pro:
1205         * WebCore.vcproj/WebCore.vcproj:
1206         * WebCore.xcodeproj/project.pbxproj:
1207         Added XMLHttpRequestProgressEventThrottle to the build systems.
1208
1209         * xml/XMLHttpRequest.cpp:
1210         (WebCore::XMLHttpRequest::XMLHttpRequest): Created the throttle.
1211         (WebCore::XMLHttpRequest::callReadyStateChangeListener): The 'readyState' event are
1212         dispatched using the XMLHttpRequestProgressEventThrottle now. For the DONE state, we
1213         need to flush any pending progress event as we do not want it to be dispatched after
1214         the DONE readyState event.
1215         (WebCore::XMLHttpRequest::createRequest): Made this event use the
1216         XMLHttpRequestProgressEventThrottle for event dispatching.
1217         (WebCore::XMLHttpRequest::abort): Ditto.
1218         (WebCore::XMLHttpRequest::networkError): Ditto.
1219         (WebCore::XMLHttpRequest::abortError): Ditto.
1220         (WebCore::XMLHttpRequest::didReceiveData): Ditto. Also fixed a potential warning.
1221         (WebCore::XMLHttpRequest::suspend):
1222         (WebCore::XMLHttpRequest::resume): Implemented the logic for suspend / resume.
1223         * xml/XMLHttpRequest.h:
1224         * xml/XMLHttpRequestProgressEventThrottle.cpp: Added.
1225         (WebCore::XMLHttpRequestProgressEventThrottle::XMLHttpRequestProgressEventThrottle):
1226         (WebCore::XMLHttpRequestProgressEventThrottle::~XMLHttpRequestProgressEventThrottle):
1227         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchProgressEvent): Implemented the bulk
1228         of the event throttling here: we use a timer to do so, as long as the timer is active it means
1229         that events are coming faster than the throttling time and we coalesce them.
1230         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchEvent): Generic method to dispatch an event.
1231         (WebCore::XMLHttpRequestProgressEventThrottle::flushProgressEvent): Called when we want to dispatch
1232         any pending events and stopping any further dispatching.
1233         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchPausedEvent): Used to dispatch the event
1234         that was queued due to the object being suspended.
1235         (WebCore::XMLHttpRequestProgressEventThrottle::fired): Used to dispatch any coalesced event.
1236         (WebCore::XMLHttpRequestProgressEventThrottle::hasEventToDispatch): Used to check if we have
1237         an event to dispatch.
1238         (WebCore::XMLHttpRequestProgressEventThrottle::suspend): Marked the object as suspended.
1239         (WebCore::XMLHttpRequestProgressEventThrottle::resume): Dispatched the event that was queued.
1240         * xml/XMLHttpRequestProgressEventThrottle.h: Added.
1241         (WebCore::):
1242         (WebCore::XMLHttpRequestProgressEventThrottle::suspended):
1243
1244 2010-03-23  Pavel Feldman  <pfeldman@chromium.org>
1245
1246         Reviewed by Timothy Hatcher.
1247
1248         Web Inspector: Element inspector search funtion: Error dispatching: performSearch.
1249
1250         https://bugs.webkit.org/show_bug.cgi?id=36488
1251
1252         Test: inspector/elements-panel-search.html
1253
1254         * inspector/front-end/ElementsPanel.js:
1255         (WebInspector.ElementsPanel.prototype.performSearch):
1256         (WebInspector.ElementsPanel.prototype.addNodesToSearchResult):
1257         * inspector/front-end/InjectedScript.js:
1258         (injectedScriptConstructor.):
1259         (injectedScriptConstructor):
1260
1261 2010-03-23  Qi Zhang  <qi.2.zhang@nokia.com>
1262
1263         Reviewed by Simon Hausmann.
1264
1265         [Qt]  fast/canvas/patternfill-repeat.html failed.
1266         https://bugs.webkit.org/show_bug.cgi?id=34477
1267
1268         Change Pattern to expose the repeatX and repeatY
1269         At GraphicsContextQt to apply repeatX and repeatY
1270
1271         * platform/graphics/Pattern.h:
1272         (WebCore::Pattern::repeatX):
1273         (WebCore::Pattern::repeatY):
1274         * platform/graphics/qt/GraphicsContextQt.cpp:
1275         (WebCore::GraphicsContext::drawLine):
1276         (WebCore::GraphicsContext::fillRect):
1277         (WebCore::GraphicsContext::rotate):
1278
1279 2010-03-23  Alex Milowski  <alex@milowski.com>
1280
1281         Reviewed by Kenneth Rohde Christiansen.
1282
1283         Removed the use of beta STIX fonts.
1284
1285         * css/mathml.css:
1286
1287 2010-03-23  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
1288
1289         Reviewed by Holger Freyther.
1290
1291         [GTK] Does not build with latest GTK+ development release
1292         https://bugs.webkit.org/show_bug.cgi?id=36398
1293
1294         Fix building with newest GTK+ versions.
1295
1296         * GNUmakefile.am:
1297         * platform/gtk/GtkPluginWidget.cpp:
1298         (WebCore::GtkPluginWidget::invalidateRect):
1299         (WebCore::GtkPluginWidget::paint):
1300         * platform/gtk/GtkVersioning.h: Added.
1301         * platform/gtk/PlatformScreenGtk.cpp:
1302         (WebCore::getVisual):
1303         (WebCore::screenRect):
1304         (WebCore::screenAvailableRect):
1305         * platform/gtk/ScrollbarGtk.cpp:
1306         (ScrollbarGtk::paint):
1307         * plugins/gtk/gtk2xtbin.c:
1308         (gtk_xtbin_set_position):
1309         (gtk_xtbin_unrealize):
1310
1311 2010-03-23  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
1312
1313         Reviewed by Kenneth Rohde Christiansen.
1314
1315         [Qt] Remove support for Qt v4.4
1316         https://bugs.webkit.org/show_bug.cgi?id=36389
1317
1318         No new tests as there is no new functionality.
1319
1320         * WebCore.pri:
1321         * WebCore.pro:
1322         * platform/network/qt/ResourceHandleQt.cpp:
1323         (WebCore::ResourceHandle::willLoadFromCache):
1324         * platform/qt/CookieJarQt.cpp:
1325         (WebCore::setCookies):
1326         (WebCore::cookies):
1327         * platform/qt/KURLQt.cpp:
1328         (WebCore::KURL::operator QUrl):
1329         * platform/qt/ScrollbarThemeQt.cpp:
1330         (WebCore::ScrollbarThemeQt::paintScrollCorner):
1331         * plugins/mac/PluginViewMac.cpp:
1332
1333 2010-03-23  Kent Tamura  <tkent@chromium.org>
1334
1335         Reviewed by Adam Barth.
1336
1337         Add checks if setNeedsWillValidateCheck() and
1338         setNeedsValidityCheck() are called correctly.
1339         https://bugs.webkit.org/show_bug.cgi?id=34924
1340
1341         Introduce HTMLFormControlElement::m_willValidate and
1342         m_isValid. They are the caches of willValidate() and
1343         isValidFormControlElement(). setNeedsWillValidateCheck() updates
1344         m_willValidate and setNeedsValidityCheck() updates m_isValid.
1345
1346         willValidate() and isValidFormControlElement() have assertions to
1347         check m_willvalidate or m_isValid has the correct state. If
1348         setNeedsWillValidateCheck() or setNeedsValidityCheck() is needed
1349         to be called and is not called, these assertions fail.
1350
1351         * html/HTMLButtonElement.h:
1352         (WebCore::HTMLButtonElement::recalcWillValidate):
1353         * html/HTMLFieldSetElement.h:
1354         (WebCore::HTMLFieldSetElement::recalcWillValidate):
1355         * html/HTMLFormControlElement.cpp:
1356         (WebCore::HTMLFormControlElement::HTMLFormControlElement):
1357         (WebCore::HTMLFormControlElement::parseMappedAttribute):
1358         (WebCore::HTMLFormControlElement::recalcWillValidate):
1359         (WebCore::HTMLFormControlElement::willValidate):
1360         (WebCore::HTMLFormControlElement::setNeedsWillValidateCheck):
1361         (WebCore::HTMLFormControlElement::validationMessage):
1362         (WebCore::HTMLFormControlElement::isValidFormControlElement):
1363         (WebCore::HTMLFormControlElement::setNeedsValidityCheck):
1364         * html/HTMLFormControlElement.h:
1365         * html/HTMLInputElement.cpp:
1366         (WebCore::HTMLInputElement::setInputType):
1367         (WebCore::HTMLInputElement::parseMappedAttribute):
1368         (WebCore::HTMLInputElement::setValue):
1369         (WebCore::HTMLInputElement::recalcWillValidate):
1370         * html/HTMLInputElement.h:
1371         * html/HTMLTextAreaElement.cpp:
1372         (WebCore::HTMLTextAreaElement::setNonDirtyValue):
1373
1374 2010-03-22  Pavel Feldman  <pfeldman@chromium.org>
1375
1376         Reviewed by Dave Hyatt.
1377
1378         Web Inspector: display CSS selector source line in the styles sidebar pane.
1379
1380         https://bugs.webkit.org/show_bug.cgi?id=36414
1381
1382         This change adds a sourceLine field into the CSSStyleRule that is populated
1383         from within the parser. CSSParser is now keeping track of the line numbers
1384         and last selector line number that is being used while creating CSSStyleRules.
1385
1386         Test: inspector/styles-source-lines.html
1387
1388         * css/CSSGrammar.y:
1389         * css/CSSParser.cpp:
1390         (WebCore::CSSParser::CSSParser):
1391         (WebCore::CSSParser::lex):
1392         (WebCore::CSSParser::countLines):
1393         (WebCore::CSSParser::createStyleRule):
1394         * css/CSSParser.h:
1395         (WebCore::CSSParser::updateLastSelectorLine):
1396         * css/CSSStyleRule.cpp:
1397         (WebCore::CSSStyleRule::CSSStyleRule):
1398         * css/CSSStyleRule.h:
1399         (WebCore::CSSStyleRule::create):
1400         (WebCore::CSSStyleRule::sourceLine):
1401         * css/tokenizer.flex:
1402         * inspector/InspectorDOMAgent.cpp:
1403         (WebCore::InspectorDOMAgent::buildObjectForRule):
1404         * inspector/front-end/DOMAgent.js:
1405         (WebInspector.CSSStyleDeclaration.parseRule):
1406         * inspector/front-end/StylesSidebarPane.js:
1407         (WebInspector.StylePropertiesSection):
1408
1409 2010-03-22  Qi Zhang  <qi.2.zhang@nokia.com>
1410
1411         Reviewed by Laszlo Gombos.
1412
1413         [Qt] Fix arc function in canvas
1414         https://bugs.webkit.org/show_bug.cgi?id=36296
1415
1416         Based on HTLM5 spec (4.8.10.1.8 Complex shapes), arc function should draw a line to previous point, not only the arc.
1417
1418         * platform/graphics/qt/PathQt.cpp:
1419         (WebCore::Path::addArc):
1420
1421 2010-03-19  Abhishek Arya  <inferno@chromium.org>
1422
1423         Reviewed by Adam Barth.
1424
1425         https://bugs.webkit.org/show_bug.cgi?id=36339
1426         Off-by-one memory corruption fix for long invalid websockets upgrade header
1427
1428         Test: websocket/tests/long-invalid-header.html
1429
1430         * websockets/WebSocketHandshake.cpp:
1431         (WebCore::WebSocketHandshake::readServerHandshake):
1432
1433 2010-03-22  Fumitoshi Ukai  <ukai@chromium.org>
1434
1435         Unreviewed build fix for Chromim Mac at r56376
1436
1437         Fix initializer order  of PopupContainer.
1438
1439         * platform/chromium/PopupMenuChromium.cpp:
1440         (WebCore::PopupContainer::PopupContainer):
1441
1442 2010-03-22  Jay Campan  <jcampan@google.com>
1443
1444         Reviewed by Darin Fisher.
1445
1446         Making Chromium select popups not steal activation from the browser.
1447         Select popups are now like autocomplete popups, shown in non-activated
1448         windows.
1449         https://bugs.webkit.org/show_bug.cgi?id=36062
1450
1451         * page/chromium/ChromeClientChromium.h:
1452         * platform/chromium/PopupMenuChromium.cpp:
1453         (WebCore::):
1454         (WebCore::PopupContainer::create):
1455         (WebCore::PopupContainer::PopupContainer):
1456         (WebCore::PopupContainer::~PopupContainer):
1457         (WebCore::PopupContainer::showPopup):
1458         (WebCore::PopupContainer::showExternal):
1459         (WebCore::PopupContainer::hidePopup):
1460         (WebCore::PopupMenu::show):
1461         * platform/chromium/PopupMenuChromium.h:
1462         (WebCore::PopupContainer::):
1463         (WebCore::PopupContainer::popupType):
1464
1465 2010-03-22  Dmitry Titov  <dimich@chromium.org>
1466
1467         Reviewed by Nate Chapin.
1468
1469         [v8] Crash if the worker is terminated before its initial script is executed.
1470         https://bugs.webkit.org/show_bug.cgi?id=36336
1471
1472         Test: fast/workers/termination-early.html
1473
1474         * bindings/v8/WorkerContextExecutionProxy.cpp:
1475         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded): Check for 0 context. When terminated, the v8 heap initialization returns 0.
1476         (WebCore::WorkerContextExecutionProxy::evaluate): Don't execute script if initialization failed.
1477         * bindings/v8/WorkerContextExecutionProxy.h:
1478
1479 2010-03-22  Andrey Kosyakov  <caseq@chromium.org>
1480
1481         Reviewed by Pavel Feldman.
1482
1483         Support creation of fake workers before document is loaded by deferring
1484         attaching of fake workers iframe until document is loaded and buffering all
1485         messages addressed to worker.
1486         https://bugs.webkit.org/show_bug.cgi?id=36445
1487
1488         * inspector/front-end/InjectedFakeWorker.js:
1489         (InjectedFakeWorker.FakeWorker.prototype.postMessage):
1490         (InjectedFakeWorker.FakeWorker.prototype._buildWorker):
1491         (InjectedFakeWorker.FakeWorker.prototype._attachWorkerFrameToDocument):
1492         (InjectedFakeWorker.FakeWorker.prototype._onWorkerFrameLoaded):
1493
1494 2010-03-22  Darin Fisher  <darin@chromium.org>
1495
1496         Reviewed by Brady Eidson.
1497
1498         HistoryController::replaceState() should modify m_currentItem
1499         instead of the current HistoryItem of the BackForwardList.
1500
1501         https://bugs.webkit.org/show_bug.cgi?id=36435
1502
1503         Test: fast/loader/stateobjects/replacestate-in-iframe.html
1504
1505         * loader/HistoryController.cpp:
1506         (WebCore::HistoryController::replaceState):
1507
1508 2010-03-22  Joseph Pecoraro  <joepeck@webkit.org>
1509
1510         Reviewed by David Kilzer.
1511
1512         Upstream Part of the iPhone Platform sharing code with the Mac Platform
1513         https://bugs.webkit.org/show_bug.cgi?id=35870
1514         <rdar://problem/7707283> and <rdar://problem/7707318>
1515
1516         Part 3 of 3: Shared code between iphone and mac. The shared code was
1517         refactored to be usable by both platforms without platform specific
1518         typing, meaning no NSEvent versus WebEvent special cases.
1519
1520           Shared code usable by either mac or iphone platforms.
1521
1522         * platform/cocoa/KeyEventCocoa.h:
1523         * platform/cocoa/KeyEventCocoa.mm:
1524         (WebCore::keyIdentifierForCharCode):
1525         (WebCore::windowsKeyCodeForKeyCode):
1526         (WebCore::windowsKeyCodeForCharCode):
1527
1528           Make use of the shared code. Keep anything platform specific in the
1529           original file before calling the shared code.
1530
1531         * platform/iphone/KeyEventIPhone.mm:
1532         (WebCore::keyIdentifierForKeyEvent):
1533         * platform/mac/KeyEventMac.mm:
1534         (WebCore::keyIdentifierForKeyEvent):
1535         (WebCore::windowsKeyCodeForKeyEvent):
1536
1537 2010-03-22  Kevin Decker  <kdecker@apple.com>
1538
1539         Reviewed by Simon Fraser.
1540
1541         https://bugs.webkit.org/show_bug.cgi?id=36328
1542
1543         * rendering/RenderEmbeddedObject.cpp:
1544         (WebCore::RenderEmbeddedObject::RenderEmbeddedObject): Fix a find/repalce mistake from my earlier patch.
1545         Rename m_setShowsMissingPluginIndicator -> m_showsMissingPluginIndicator. 
1546         (WebCore::RenderEmbeddedObject::updateWidget): Don't update the widget if we're showing
1547         the missing plug-in indicator.
1548         (WebCore::RenderEmbeddedObject::paint):Fix a find/repalce mistake from my earlier patch.
1549         Rename m_setShowsMissingPluginIndicator -> m_showsMissingPluginIndicator. 
1550         (WebCore::RenderEmbeddedObject::paintReplaced): Ditto.
1551         * rendering/RenderEmbeddedObject.h: Ditto.
1552         (WebCore::RenderEmbeddedObject::setShowsMissingPluginIndicator): Ditto.
1553         (WebCore::RenderEmbeddedObject::showsMissingPluginIndicator): Ditto.
1554
1555 2010-03-22  Joseph Pecoraro  <joepeck@webkit.org>
1556
1557         Reviewed by David Kilzer.
1558
1559         Upstream Part of the iPhone Platform sharing code with the Mac Platform
1560         https://bugs.webkit.org/show_bug.cgi?id=35870
1561         <rdar://problem/7707283>
1562
1563         Part 2 of 3: No changes other than moving code around.
1564         Copied KeyEvent function from platform/mac to a platform/cocoa shared directory.
1565
1566         * WebCore.xcodeproj/project.pbxproj: Added cocoa group and new files.
1567         * platform/cocoa/KeyEventCocoa.h: Added.
1568         * platform/cocoa/KeyEventCocoa.mm: Copied from WebCore/platform/mac/KeyEventMac.mm.
1569         (WebCore::keyIdentifierForKeyEvent):
1570         (WebCore::windowsKeyCodeForKeyEvent): Include the shared code.
1571         * platform/mac/KeyEventMac.mm:
1572
1573 2010-03-22  Joseph Pecoraro  <joepeck@webkit.org>
1574
1575         Reviewed by David Kilzer.
1576
1577         Part 1 of 3: Upstream iPhone KeyEvent platform code and share with Mac platform
1578         https://bugs.webkit.org/show_bug.cgi?id=35870
1579         <rdar://problem/7707283>
1580
1581         * WebCore.xcodeproj/project.pbxproj: Added iphone group and new files.
1582         * platform/iphone: Added.
1583         * platform/iphone/KeyEventCodesIPhone.h: Added.
1584         * platform/iphone/KeyEventIPhone.mm: Added. Ensure PLATFORM(IPHONE)
1585         * platform/mac/KeyEventMac.mm: Ensure PLATFORM(MAC)
1586
1587 2010-03-22  Kevin Decker  <kdecker@apple.com>
1588     
1589         Attempt to fix the Leopard build.
1590         * rendering/RenderEmbeddedObject.cpp: Add ".f" to contants.
1591
1592 2010-03-22  Justin Schuh  <jschuh@chromium.org>
1593
1594         Reviewed by Dirk Schulze.
1595
1596         Out of bounds read in SVG feColorMatrix filter
1597         https://bugs.webkit.org/show_bug.cgi?id=32714
1598
1599         Prevents an invalid read when a valid values attribute is not
1600         supplied for an feColorMatrix SVG filter. Also fixes general
1601         handling of missing or invalid values attribute.
1602
1603         Tests: svg/filters/feColorMatrix-invalid-value.svg
1604                svg/filters/feColorMatrix-values.svg
1605
1606         * svg/SVGFEColorMatrixElement.cpp:
1607         (WebCore::SVGFEColorMatrixElement::build):
1608
1609 2010-03-22  Philippe Normand  <pnormand@igalia.com>
1610
1611         Reviewed by Eric Carlson.
1612
1613         [GStreamer] Use ImageBuffer API to do painting
1614         https://bugs.webkit.org/show_bug.cgi?id=35783
1615
1616         New ImageGStreamer class abstracting the conversion of GStreamer
1617         buffers to cairo surfaces. Using this makes the painting code of
1618         the player more generic.
1619
1620         * GNUmakefile.am:
1621         * platform/graphics/gstreamer/ImageGStreamer.h: Added.
1622         (WebCore::ImageGStreamer::image):
1623         * platform/graphics/gstreamer/ImageGStreamerCairo.cpp: Added.
1624         (ImageGStreamer::createImage):
1625         (ImageGStreamer::ImageGStreamer):
1626         (ImageGStreamer::~ImageGStreamer):
1627         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
1628         (WebCore::MediaPlayerPrivate::paint):
1629         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
1630
1631 2010-03-22  Beth Dakin  <bdakin@apple.com>
1632
1633         Reviewed by Darin Adler.
1634
1635         Fix for <rdar://problem/7766437> With Web Inspector opened, a crash 
1636         occurs at Webcore:getMatchedCSSRules() when navigating to a 
1637         previous page
1638
1639         defaultView() can legitimately by null (as it is in this case), so 
1640         it must be null-checked.
1641
1642         * inspector/InspectorDOMAgent.cpp:
1643         (WebCore::InspectorDOMAgent::getStyles):
1644         (WebCore::InspectorDOMAgent::getComputedStyle):
1645         (WebCore::InspectorDOMAgent::getMatchedCSSRules):
1646
1647 2010-03-22  Kevin Decker  <kdecker@apple.com>
1648
1649         Reviewed by Darin.
1650
1651         https://bugs.webkit.org/show_bug.cgi?id=36328
1652         
1653         * loader/FrameLoader.cpp:
1654         (WebCore::FrameLoader::loadPlugin): Call setShowsMissingPluginIndicator(true) in cases that fail
1655         to generate a widget.
1656         * rendering/RenderEmbeddedObject.cpp: Added new missing plug-in related static constants
1657         (WebCore::RenderEmbeddedObject::RenderEmbeddedObject): Initialize newly boolean to false.
1658         (WebCore::RenderEmbeddedObject::paint): Added.
1659         (WebCore::RenderEmbeddedObject::paintReplaced): Added. Draws a subtle rounded rectangle
1660         containing the text "Missing Plug-in".
1661         * rendering/RenderEmbeddedObject.h: Added the following two methods below.
1662         (WebCore::RenderEmbeddedObject::setShowsMissingPluginIndicator):
1663         (WebCore::RenderEmbeddedObject::showsMissingPluginIndicator):
1664         * rendering/RenderWidget.h: Moved paint(PaintInfo&, int, int) from private to protected.
1665
1666 2010-03-22  Jakub Wieczorek  <faw217@gmail.com>
1667
1668         Reviewed by Kenneth Rohde Christiansen.
1669
1670         [Qt] Phonon media backend: expose supported MIME types to WebCore
1671
1672         https://bugs.webkit.org/show_bug.cgi?id=33453
1673
1674         MediaPlayerPrivate should expose the MIME types that are supported
1675         by the underlying backend in Phonon.
1676
1677         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
1678         (WebCore::MediaPlayerPrivate::supportedTypesCache):
1679         (WebCore::MediaPlayerPrivate::getSupportedTypes):
1680         (WebCore::MediaPlayerPrivate::supportsType):
1681         * platform/graphics/qt/MediaPlayerPrivatePhonon.h:
1682
1683 2010-03-22  Alexander Pavlov  <apavlov@chromium.org>
1684
1685         Reviewed by Pavel Feldman.
1686
1687         Web Inspector: AuditRules still use getMatchedCSSRules as a part of the img-related audit.
1688         https://bugs.webkit.org/show_bug.cgi?id=36424
1689
1690         * inspector/front-end/AuditRules.js:
1691         (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun):
1692         (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun.receivedImages):
1693         (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun.pushImageNodes):
1694         * inspector/front-end/InjectedScript.js:
1695         (injectedScriptConstructor):
1696
1697 2010-03-22  Darin Adler  <darin@apple.com>
1698
1699         Reviewed by Dan Bernstein.
1700
1701         TextBreakIteratorICU.cpp is incompatible with new UBreakIterator type in ICU 4.4
1702         https://bugs.webkit.org/show_bug.cgi?id=36381
1703
1704         * platform/text/TextBreakIteratorICU.cpp:
1705         (WebCore::setUpIterator): Use reinterpret_cast instead of static_cast or relying
1706         on conversion to void*.
1707         (WebCore::textBreakFirst): Ditto.
1708         (WebCore::textBreakLast): Ditto.
1709         (WebCore::textBreakNext): Ditto.
1710         (WebCore::textBreakPrevious): Ditto.
1711         (WebCore::textBreakPreceding): Ditto.
1712         (WebCore::textBreakFollowing): Ditto.
1713         (WebCore::textBreakCurrent): Ditto.
1714         (WebCore::isTextBreak): Ditto.
1715         (WebCore::setUpIteratorWithRules): Ditto.
1716
1717 2010-03-22  Eric Carlson  <eric.carlson@apple.com>
1718
1719         Reviewed by Sam Weinig.
1720
1721         Typo in GPL license text
1722         https://bugs.webkit.org/show_bug.cgi?id=36442
1723
1724         Fix typo - "aint with this library" -> "along with this library".
1725
1726         * bindings/scripts/CodeGenerator.pm:
1727         * bindings/scripts/CodeGeneratorJS.pm:
1728         * bindings/scripts/CodeGeneratorObjC.pm:
1729         * bindings/scripts/CodeGeneratorV8.pm:
1730         * bindings/scripts/IDLParser.pm:
1731         * bindings/scripts/IDLStructure.pm:
1732         * bindings/scripts/generate-bindings.pl:
1733
1734 2010-03-22  Jakub Wieczorek  <jwieczorek@webkit.org>
1735
1736         Reviewed by Simon Hausmann.
1737
1738         [Qt] Don't construct a QLineEdit every time when painting a text field
1739         https://bugs.webkit.org/show_bug.cgi?id=36373
1740
1741         Instead, keep one instance per RenderTheme around.
1742
1743         * platform/qt/RenderThemeQt.cpp:
1744         (WebCore::findFrameLineWidth):
1745
1746 2010-03-22  Luiz Agostini  <luiz.agostini@openbossa.org>
1747
1748         Reviewed by Kenneth Rohde Christiansen.
1749
1750         [Qt] Multiselect Popup - adjusting QtAbstractWebPopup
1751         https://bugs.webkit.org/show_bug.cgi?id=36186
1752
1753         QtAbstractWebPopup must provide new methods to be used by its descendants that
1754         wish to handle <select multiple> elements.
1755
1756         * platform/qt/QtAbstractWebPopup.cpp:
1757         (WebCore::QtAbstractWebPopup::selectItem):
1758         (WebCore::QtAbstractWebPopup::multiple):
1759         * platform/qt/QtAbstractWebPopup.h:
1760
1761 2010-03-22  Alex Milowski  <alex@milowski.com>
1762
1763         Reviewed by Kenneth Rohde Christiansen.
1764
1765         Added basic support for mfrac (fractions)
1766
1767         Test: mathml/presentation/fractions.xhtml
1768
1769         * WebCore.xcodeproj/project.pbxproj:
1770         * mathml/MathMLInlineContainerElement.cpp:
1771         (WebCore::MathMLInlineContainerElement::createRenderer):
1772         * mathml/RenderMathMLFraction.cpp: Added.
1773         (WebCore::RenderMathMLFraction::RenderMathMLFraction):
1774         (WebCore::RenderMathMLFraction::updateFromElement):
1775         (WebCore::RenderMathMLFraction::addChild):
1776         * mathml/RenderMathMLFraction.h: Added.
1777
1778 2010-03-22  Kevin Decker  <kdecker@apple.com>
1779
1780         Reviewed by John Sullivan.
1781
1782         https://bugs.webkit.org/show_bug.cgi?id=36328
1783
1784         * page/mac/WebCoreViewFactory.h: Added -missingPluginText method 
1785         * platform/LocalizedStrings.h: Added missingPluginText()
1786         * platform/gtk/LocalizedStringsGtk.cpp: Likewise.
1787         * platform/mac/LocalizedStringsMac.mm: Same here.
1788         * platform/qt/Localizations.cpp: Ditto.
1789
1790 2010-03-22  Yury Semikhatsky  <yurys@chromium.org>
1791
1792         Reviewed by Pavel Feldman.
1793
1794         Handle worker exceptions in V8MessageHandler like it's done in regular documents. This way all worker exceptions will be logged in the console not only those which happen in event listeners. 
1795
1796         https://bugs.webkit.org/show_bug.cgi?id=31171
1797
1798         * bindings/v8/V8AbstractEventListener.cpp:
1799         (WebCore::V8AbstractEventListener::invokeEventHandler): Removed explicit call to reportException.
1800         * bindings/v8/V8Utilities.cpp: reportException function was removed since it's not used.
1801         (WebCore::getScriptExecutionContext):
1802         * bindings/v8/V8Utilities.h:
1803         * bindings/v8/WorkerContextExecutionProxy.cpp:
1804         (WebCore::v8MessageHandler):
1805         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded): Setup message handler when first worker context is created.
1806
1807 2010-03-22  Leandro Pereira  <leandro@profusion.mobi>
1808
1809         Reviewed by Simon Hausmann.
1810
1811         Add EFL-specific code to page/EventHandler.cpp.
1812         http://webkit.org/b/36306
1813
1814         * page/EventHandler.cpp:
1815
1816 2010-03-22  Leandro Pereira  <leandro@profusion.mobi>
1817
1818         Reviewed by Simon Hausmann.
1819
1820         Add EFL-specific code to platform/DragImage.h and
1821         platform/DragData.h.
1822         http://webkit.org/b/36310
1823
1824         * platform/DragImage.h:
1825         * platform/DragData.h:
1826
1827 2010-03-22  Leandro Pereira  <leandro@profusion.mobi>
1828
1829         Reviewed by Simon Hausmann.
1830
1831         Add EFL-specific code to platform/FileSystem.h.
1832         http://webkit.org/b/36313
1833
1834         * platform/FileSystem.h:
1835
1836 2010-03-22  Leandro Pereira  <leandro@profusion.mobi>
1837
1838         Reviewed by Simon Hausmann.
1839
1840         Add EFL-specific code to platform/Cursor.h.
1841         http://webkit.org/b/36319
1842
1843         * platform/Cursor.h:
1844
1845 2010-03-22  Leandro Pereira  <leandro@profusion.mobi>
1846
1847         Reviewed by Simon Hausmann.
1848
1849         Add EFL-specific code to platform/NotImplemented.h.
1850         http://webkit.org/b/36320
1851
1852         * platform/NotImplemented.h:
1853
1854 2010-03-21  Kim Grönholm  <kim.gronholm@nomovok.com>
1855
1856         Reviewed by Simon Hausmann.
1857
1858         [Qt] GraphicsLayer: matrix interpolations in transform-animations don't behave correctly
1859         https://bugs.webkit.org/show_bug.cgi?id=35520
1860         
1861         The case where the list of source and target transform operations are 
1862         not the same but have the same size needs to be special-cased in
1863         GraphicsLayerQt, as well as the case where the source or target
1864         operation list is empty. The URLs listed here render correctly after
1865         applying the patch.
1866
1867         Tests: https://bug-35520-attachments.webkit.org/attachment.cgi?id=49890
1868                https://bug-35520-attachments.webkit.org/attachment.cgi?id=49889
1869             
1870
1871         * platform/graphics/qt/GraphicsLayerQt.cpp:
1872         (WebCore::TransformAnimationQt::applyFrame):
1873
1874 2010-03-21  Dmitry Gorbik  <socket.h@gmail.com>
1875
1876         <http://webkit.org/b/14858> <col> width ignored when not tied to a single cell
1877
1878         Reviewed by David Kilzer.
1879
1880         Fixed width calculation for cells with span when <col> is defined.
1881
1882         Test: fast/table/col-width-span-expand.html
1883
1884         * rendering/RenderTableCell.cpp:
1885         (WebCore::RenderTableCell::styleOrColWidth): Added the calculation of cell width
1886         in case of <col> defined and span > 1.
1887
1888 2010-03-20  Antonio Gomes  <tonikitoo@webkit.org>
1889
1890         Reviewed by Kenneth Christiansen.
1891         Patch by Antonio Gomes <tonikitoo@webkit.org>
1892
1893         Spatial Navigation: Code simplification in FocusController.cpp and SpatialNavigation.cpp (part I)
1894         https://bugs.webkit.org/show_bug.cgi?id=36168
1895
1896         Make use of isNull and document methods introduced in FocusCandidate class by patch in bug 36167.
1897         No functionalty change.
1898
1899         * page/FocusController.cpp:
1900         (WebCore::updateFocusCandidateIfCloser):
1901         * page/SpatialNavigation.cpp:
1902         (WebCore::distanceInDirection):
1903
1904 2010-03-20  Kevin Ollivier  <kevino@theolliviers.com>
1905
1906         [wx] Build fixes after recent changes.
1907
1908         * platform/graphics/wx/ImageWx.cpp:
1909         * wscript:
1910
1911 2010-03-20  Joseph Pecoraro  <joepeck@webkit.org>
1912
1913         Reviewed by David Kilzer.
1914
1915         Assertion failure in media/video-controls-with-mutation-event-handler.html
1916         https://bugs.webkit.org/show_bug.cgi?id=36376
1917
1918         Test: media/video-controls-with-mutation-event-handler.html
1919
1920         Break early (when not attached) in the defaultEventHandler before the
1921         slider is completely set up.
1922
1923         * rendering/MediaControlElements.cpp:
1924         (WebCore::MediaControlTimelineElement::defaultEventHandler):
1925         (WebCore::MediaControlVolumeSliderElement::defaultEventHandler):
1926         * rendering/RenderMedia.cpp:
1927         (WebCore::RenderMedia::createVolumeSlider):
1928
1929 2010-03-19  Shinichiro Hamaji  <hamaji@chromium.org>
1930
1931         Reviewed by Dan Bernstein.
1932
1933         WebCore::RenderButton::styleDidChange ReadAV@NULL (6739b7fe455ecb54a6812c0866c3b47c)
1934         https://bugs.webkit.org/show_bug.cgi?id=34641
1935
1936         Don't dig into buttons and menu lists when finding which element
1937         should be modified by :first-letter pseudo class.  Even before
1938         this change, we didn't dig into inline buttons and menu lists as
1939         they are replaced so this issue wasn't found long time.
1940
1941         Test: fast/css/first-letter-block-form-controls-crash.html
1942
1943         * rendering/RenderBlock.cpp:
1944         (WebCore::RenderBlock::updateFirstLetter):
1945
1946 2010-03-19  Adam Barth  <abarth@webkit.org>
1947
1948         Reviewed by Daniel Bates.
1949
1950         Change XSSAuditor block syntax
1951         https://bugs.webkit.org/show_bug.cgi?id=34436
1952
1953         Update our blocking syntax to something more reasonable.  Also,
1954         implemented a way for a web site to disable the filter.
1955
1956         Tests: http/tests/security/xssAuditor/no-protection-script-tag.html
1957                http/tests/security/xssAuditor/xss-protection-parsing-01.html
1958
1959         * page/XSSAuditor.cpp:
1960         (WebCore::XSSAuditor::xssProtection):
1961         (WebCore::XSSAuditor::findInRequest):
1962         * page/XSSAuditor.h:
1963         * platform/network/HTTPParsers.cpp:
1964         (WebCore::skipToken):
1965         (WebCore::parseXSSProtectionHeader):
1966         * platform/network/HTTPParsers.h:
1967         (WebCore::):
1968
1969 2010-03-19  Eric Uhrhane  <ericu@chromium.org>
1970
1971         Reviewed by Dmitry Titov.
1972
1973         Refactor DatabaseTracker.cpp for thread safety
1974         https://bugs.webkit.org/show_bug.cgi?id=34991
1975
1976         This enables calling into DatabaseTracker from multiple context threads,
1977         as will happen once Workers can access the Database.  It required a fair
1978         amount of reshuffling of locks.  I ended up splitting the public
1979         interface [calls that take locks and call private functions] from the
1980         implementations [calls that assert that locks are already held] in order
1981         to avoid lock conflicts.  I also had to make sure we weren't sharing
1982         Strings or SecurityOrigins across threads.
1983
1984         No new tests.
1985
1986         Allow access to database handles from multiple threads IFF SQLite is new enough and the user requests it.
1987
1988         * platform/sql/SQLiteDatabase.cpp:
1989         (WebCore::SQLiteDatabase::SQLiteDatabase):
1990         (WebCore::SQLiteDatabase::disableThreadingChecks):
1991         * platform/sql/SQLiteDatabase.h:
1992         (WebCore::SQLiteDatabase::sqlite3Handle):
1993         (WebCore::SQLiteDatabase::disableThreadingChecks):
1994
1995         Remove an asynchronous call from Database::close back to the execution thread, so that cleanup can be more deterministic.
1996
1997         * storage/Database.cpp:
1998         (WebCore::Database::markAsDeletedAndClose):
1999         (WebCore::Database::close):
2000         * storage/Database.h:
2001         (WebCore::Database::):
2002         * storage/DatabaseDetails.h:
2003         (WebCore::DatabaseDetails::DatabaseDetails):
2004         (WebCore::DatabaseDetails::thread):
2005         * storage/DatabaseTask.cpp:
2006         (WebCore::DatabaseCloseTask::doPerformTask):
2007         * storage/DatabaseThread.cpp:
2008         (WebCore::DatabaseThread::databaseThread):
2009
2010         Any Strings that get stored in DatabaseTracker, and any Strings returned from DatabaseTracker, are now threadsafeCopies.
2011         Public functions now take all needed locks, then generally call only private functions [there are a few exceptions: deletion functions and origins()].
2012         Private functions no longer take locks.
2013         m_quotaMapGuard becomes m_databaseGuard, and now protects m_database, m_quotaMap, m_proposedDatabases, m_databaseDirectoryPath, m_originsBeingDeleted, m_beingCreated, and m_beingDeleted.
2014         m_proposedDatabases replaces m_proposedDatabase, to account for reentrancy.
2015
2016         * storage/DatabaseTracker.h:
2017         * storage/DatabaseTracker.cpp:
2018         (WebCore::DatabaseTracker::originQuotaManagerNoLock):
2019         (WebCore::DatabaseTracker::originQuotaManager):
2020         (WebCore::DatabaseTracker::DatabaseTracker):
2021         (WebCore::DatabaseTracker::setDatabaseDirectoryPath):
2022         (WebCore::DatabaseTracker::databaseDirectoryPath):
2023         (WebCore::DatabaseTracker::trackerDatabasePath):
2024         (WebCore::DatabaseTracker::openTrackerDatabase):
2025         (WebCore::DatabaseTracker::canEstablishDatabase):
2026         (WebCore::DatabaseTracker::hasEntryForOriginNoLock):
2027         (WebCore::DatabaseTracker::hasEntryForOrigin):
2028         (WebCore::DatabaseTracker::hasEntryForDatabase):
2029         (WebCore::DatabaseTracker::originPath):
2030         (WebCore::DatabaseTracker::fullPathForDatabaseNoLock):
2031         (WebCore::DatabaseTracker::fullPathForDatabase):
2032         (WebCore::DatabaseTracker::populateOrigins):
2033         (WebCore::DatabaseTracker::origins):
2034         (WebCore::DatabaseTracker::databaseNamesForOriginNoLock):
2035         (WebCore::DatabaseTracker::databaseNamesForOrigin):
2036         (WebCore::DatabaseTracker::detailsForNameAndOrigin):
2037         (WebCore::DatabaseTracker::setDatabaseDetails):
2038         (WebCore::DatabaseTracker::usageForDatabase):
2039         (WebCore::DatabaseTracker::addOpenDatabase):
2040         (WebCore::DatabaseTracker::removeOpenDatabase):
2041         (WebCore::DatabaseTracker::usageForOriginNoLock):
2042         (WebCore::DatabaseTracker::usageForOrigin):
2043         (WebCore::DatabaseTracker::quotaForOriginNoLock):
2044         (WebCore::DatabaseTracker::quotaForOrigin):
2045         (WebCore::DatabaseTracker::setQuota):
2046         (WebCore::DatabaseTracker::addDatabase):
2047         (WebCore::DatabaseTracker::deleteAllDatabases):
2048         (WebCore::DatabaseTracker::deleteOrigin):
2049         (WebCore::DatabaseTracker::deleteDatabase):
2050         (WebCore::DatabaseTracker::deleteDatabaseFile):
2051         (WebCore::DatabaseTracker::setClient):
2052         (WebCore::DatabaseTracker::scheduleNotifyDatabaseChanged):
2053         (WebCore::DatabaseTracker::notifyDatabasesChanged):
2054
2055         These functions keep track of in-progress deletions and creations, so that we can make sure nobody every deletes a database file while a live database is using it.
2056         (WebCore::DatabaseTracker::canCreateDatabase):
2057         (WebCore::DatabaseTracker::recordCreatingDatabase):
2058         (WebCore::DatabaseTracker::doneCreatingDatabase):
2059         (WebCore::DatabaseTracker::creatingDatabase):
2060         (WebCore::DatabaseTracker::canDeleteDatabase):
2061         (WebCore::DatabaseTracker::recordDeletingDatabase):
2062         (WebCore::DatabaseTracker::doneDeletingDatabase):
2063         (WebCore::DatabaseTracker::deletingDatabase):
2064         (WebCore::DatabaseTracker::canDeleteOrigin):
2065         (WebCore::DatabaseTracker::deletingOrigin):
2066         (WebCore::DatabaseTracker::recordDeletingOrigin):
2067         (WebCore::DatabaseTracker::doneDeletingOrigin):
2068
2069         Any SecurityOrigins stored in OriginQuotaManager are now threadsafeCopies of inputs.  There's a new tryLock() function in addition to the existing lock().
2070
2071         * storage/OriginQuotaManager.cpp:
2072         (WebCore::OriginQuotaManager::tryLock):
2073         (WebCore::OriginQuotaManager::trackOrigin):
2074         * storage/OriginQuotaManager.h:
2075
2076         * page/SecurityOrigin.cpp:
2077         (WebCore::SecurityOrigin::databaseIdentifier):
2078         Removed DEFINE_STATIC_LOCAL wrapper on a local variable; it appears to have been a small optimization, but it's not thread-safe.
2079
2080 2010-03-19  Luiz Agostini  <luiz.agostini@openbossa.org>
2081
2082         Reviewed by Antti Koivisto.
2083
2084         Multiselect popups - rendering
2085         https://bugs.webkit.org/show_bug.cgi?id=36006
2086
2087         The objective of this patch is to create a compile time flag that can be used
2088         to force all <select> elements to be rendered as menu lists.
2089
2090         Theme stylesheet mechanism has been used to change the appearance of the elements.
2091
2092         Class QtStyleOptionWebComboBox has been introduced to provide to QStyle objects
2093         the needed information to render <select multiple> comboboxes.
2094
2095         * WebCore.pri:
2096         * WebCore.pro:
2097         * css/themeQtNoListboxes.css: Added.
2098         (select[size][multiple]):
2099         * dom/SelectElement.h:
2100         (WebCore::SelectElementData::usesMenuList):
2101         * platform/qt/QtStyleOptionWebComboBox.h: Added.
2102         (WebCore::QtStyleOptionWebComboBox::QtStyleOptionWebComboBox):
2103         (WebCore::QtStyleOptionWebComboBox::multiple):
2104         (WebCore::QtStyleOptionWebComboBox::checkMultiple):
2105         * platform/qt/RenderThemeQt.cpp:
2106         (WebCore::RenderThemeQt::extraDefaultStyleSheet):
2107         (WebCore::RenderThemeQt::paintMenuList):
2108         (WebCore::RenderThemeQt::paintMenuListButton):
2109         * platform/qt/RenderThemeQt.h:
2110
2111 2010-03-19  Zhenyao Mo  <zmo@google.com>
2112
2113         Reviewed by Oliver Hunt.
2114
2115         Update WebGLArray.slice() to new spec
2116         https://bugs.webkit.org/show_bug.cgi?id-35612
2117
2118         * bindings/js/JSWebGLArrayCustom.cpp: Adding support for default inputs.
2119         (WebCore::JSWebGLArray::slice):
2120         * bindings/v8/custom/V8WebGLArrayCustom.cpp: Ditto.
2121         (WebCore::V8WebGLArray::sliceCallback):
2122         * html/canvas/WebGLArray.cpp: Map start/end to offset/length.
2123         (WebCore::WebGLArray::calculateOffsetAndLength):
2124         * html/canvas/WebGLArray.h: Modified slice parameters.
2125         * html/canvas/WebGLArray.idl: Define custom binding for slice().
2126         * html/canvas/WebGLByteArray.cpp: Modified slice parameters.
2127         (WebCore::WebGLByteArray::slice):
2128         * html/canvas/WebGLByteArray.h: Ditto.
2129         * html/canvas/WebGLFloatArray.cpp: Ditto.
2130         (WebCore::WebGLFloatArray::slice):
2131         * html/canvas/WebGLFloatArray.h: Ditto.
2132         * html/canvas/WebGLIntArray.cpp: Ditto.
2133         (WebCore::WebGLIntArray::slice):
2134         * html/canvas/WebGLIntArray.h: Ditto.
2135         * html/canvas/WebGLShortArray.cpp: Ditto.
2136         (WebCore::WebGLShortArray::slice):
2137         * html/canvas/WebGLShortArray.h: Ditto.
2138         * html/canvas/WebGLUnsignedByteArray.cpp: Ditto.
2139         (WebCore::WebGLUnsignedByteArray::slice):
2140         * html/canvas/WebGLUnsignedByteArray.h: Ditto.
2141         * html/canvas/WebGLUnsignedIntArray.cpp: Ditto.
2142         (WebCore::WebGLUnsignedIntArray::slice):
2143         * html/canvas/WebGLUnsignedIntArray.h: Ditto.
2144         * html/canvas/WebGLUnsignedShortArray.cpp: Ditto.
2145         (WebCore::WebGLUnsignedShortArray::slice):
2146         * html/canvas/WebGLUnsignedShortArray.h: Ditto.
2147
2148 2010-03-19  Yong Li <yong.li@torchmobile.com> and Andy Estes <aestes@apple.com>
2149
2150         Reviewed by Darin Adler.
2151
2152         Ensure the segments inside SharedBuffer are merged before constructing
2153         a CFData with it.
2154
2155         https://bugs.webkit.org/show_bug.cgi?id=50843
2156
2157         * manual-tests/WebKitSite.webarchive: Added.
2158         * manual-tests/webarchive-test.html: Added.
2159         * platform/cf/SharedBufferCF.cpp:
2160         (WebCore::SharedBuffer::createCFData):
2161
2162 2010-03-19  Justin Schuh  <jschuh@chromium.org>
2163
2164         Reviewed by Oliver Hunt.
2165
2166         Security: ReadAV@NULL for negative feMorphology filter radius
2167         https://bugs.webkit.org/show_bug.cgi?id=34566
2168
2169         Prevents building the filter if either radius is negative.
2170         Catches negative radii resulting from conversions.
2171
2172         Test: svg/filters/feMorphology-invalid-radius.svg
2173
2174         * svg/SVGFEMorphologyElement.cpp:
2175         (WebCore::SVGFEMorphologyElement::build):
2176         * svg/graphics/filters/SVGFEMorphology.cpp:
2177         (WebCore::FEMorphology::apply):
2178
2179 2010-03-19  Chris Marrin  <cmarrin@apple.com>
2180
2181         Reviewed by Simon Fraser.
2182
2183         Fixed a crash with AnimationController getting deleted out from under itself.
2184         
2185         It's possible for the Frame that owns an AnimationController to get deleted
2186         in the EndTransitionEvent (or other animation events) to get deleted in the
2187         event handler. Normally this case is protected against by preventing the Frame
2188         from getting deleted until the end of the runloop. But native uses of the 
2189         WebView can subvert this protection. So I added a protector to the 
2190         animation event dispatcher to protect it in those cases.
2191
2192         Test: transitions/transition-end-event-destroy-iframe.html
2193
2194         * page/animation/AnimationController.cpp:
2195         (WebCore::AnimationControllerPrivate::updateStyleIfNeededDispatcherFired):
2196
2197 2010-03-19  Luiz Agostini  <luiz.agostini@openbossa.org>
2198
2199         Reviewed by Antti Koivisto.
2200
2201         Multiselect Popup - PopupMenuClient extension
2202         https://bugs.webkit.org/show_bug.cgi?id=36178
2203
2204         PopupMenuClient class is the interface used by combobox popup implementations.
2205         It needs to be extended to handle <select multiple> needs.
2206
2207         A new interface named ListPopupMenuClient that inherits from PopupMenuClient was created.
2208         The use of this new class instead of adding methods to PopupMenuClient avoids changes
2209         in other non related implementations of PopupMenuClient.
2210
2211         RenderMenuList has changed to inherit ListPopupMenuClient instead of PopupMenuClient
2212         and to have the new methods implemented.
2213
2214         * platform/PopupMenuClient.h:
2215         * rendering/RenderMenuList.cpp:
2216         (WebCore::RenderMenuList::listBoxSelectItem):
2217         (WebCore::RenderMenuList::multiple):
2218         * rendering/RenderMenuList.h:
2219
2220 2010-03-19  Simon Fraser  <simon.fraser@apple.com>
2221
2222         Reviewed by Dimitri Glazkov.
2223
2224         https://bugs.webkit.org/show_bug.cgi?id=36387
2225         REGRESSION: Can "uncheck" radio buttons by clicking on them
2226         
2227         My change in r56174 caused radio buttons and checkboxes to go down the same code path by virtue
2228         of allowsIndeterminate(), but this broke save/restore behavior on radio buttons.
2229         
2230         Fix by saving and restoring both the intermediate and checked state for radio buttons
2231         and checkboxes, as well as the "current radio button" state.
2232
2233         Test: fast/forms/radio-checkbox-restore-indeterminate.html
2234
2235         * html/HTMLInputElement.cpp:
2236         (WebCore::EventHandlingState::EventHandlingState): New struct to hold state between preDispatchEventHandler()
2237         and postDispatchEventHandler().
2238         (WebCore::HTMLInputElement::preDispatchEventHandler): Store intermedate and checked state
2239         and the current radio button.
2240         (WebCore::HTMLInputElement::postDispatchEventHandler): Restore state as appropriate.
2241         * html/HTMLInputElement.h: Add a comment to clarify how 'intermediate' interacts with 'checked', according
2242         to the spec.
2243
2244 2010-03-19  Alexander Pavlov  <apavlov@chromium.org>
2245
2246         Reviewed by Pavel Feldman.
2247
2248         Web Inspector: caret moves past prompt in javascript console
2249         https://bugs.webkit.org/show_bug.cgi?id=26602
2250
2251         Having noticed any Element children besides a leading <br> (which are empty
2252         text nodes), WebCore editing facility thinks it should delete the <br>,
2253         thus clearing away the text prompt contents.
2254
2255         * inspector/front-end/TextPrompt.js:
2256         (WebInspector.TextPrompt.prototype.clearAutoComplete):
2257         (WebInspector.TextPrompt.prototype._completionsReady):
2258         * inspector/front-end/utilities.js:
2259         (Element.prototype.pruneEmptyTextNodes):
2260
2261 2010-03-19  Adam Roben  <aroben@apple.com>
2262
2263         Windows clean build fix after r56192
2264
2265         * WebCore.vcproj/WebCore.vcproj: Copy headers from
2266         platform/graphics/cg to $WebKitOutputDir as part of the post-build
2267         event so that WebKit can use them. (The only one we currently require
2268         is FontPlatformData.h.)
2269
2270         * platform/graphics/win/FontPlatformDataCGWin.cpp: Touched to force a
2271         build.
2272
2273 2010-03-19  Joseph Pecoraro  <joepeck@webkit.org>
2274
2275         Reviewed by David Kilzer.
2276
2277         Assertion failure in media/video-controls-with-mutation-event-handler.html
2278         https://bugs.webkit.org/show_bug.cgi?id=36376
2279
2280         Fix crashing test. Underlying the media element's volume slider is a
2281         range input, which sanitizes values before expected on the media control.
2282
2283         * rendering/RenderMedia.cpp:
2284         (WebCore::RenderMedia::createVolumeSlider):
2285
2286 2010-03-19  Brady Eidson  <beidson@apple.com>
2287
2288         Reviewed by Darin Adler.
2289
2290         3 of the new HTML5 loading events need to be asynchronous.
2291
2292         Laying the groundwork for:
2293         https://bugs.webkit.org/show_bug.cgi?id=36201
2294         https://bugs.webkit.org/show_bug.cgi?id=36202
2295         https://bugs.webkit.org/show_bug.cgi?id=36334
2296         https://bugs.webkit.org/show_bug.cgi?id=36335
2297
2298         Document already had an asynchronous event delivery mechanism for storage events, so
2299         we can repurpose that for all async events.
2300
2301         No new tests. (No change in behavior)
2302
2303         * dom/Document.cpp:
2304         (WebCore::Document::Document):
2305         (WebCore::Document::implicitClose): Use Document::schedule* for the related events.
2306         (WebCore::Document::enqueueEvent): Renamed from enqueueStorageEvent
2307         (WebCore::Document::pendingEventTimerFired): Renamed from "storageEventTimerFired"
2308         (WebCore::Document::statePopped): Use Document::schedulePopstateEvent
2309         (WebCore::Document::enqueuePageshowEvent): All Pageshow events are piped through here.
2310           This will be made asynchronous in a separate patch.
2311         (WebCore::Document::enqueueHashchangeEvent): All Hashchange events are piped through here.
2312           This will be made asynchronous in a separate patch.
2313         (WebCore::Document::enqueuePopstateEvent): All Popstate events are piped through here.
2314           This will be made asynchronous in a separate patch.
2315         * dom/Document.h:
2316         (WebCore::):
2317
2318         * history/CachedFrame.cpp:
2319         (WebCore::CachedFrameBase::restore): Use Document::enqueuePageshowEvent
2320
2321         * loader/FrameLoader.cpp:
2322         (WebCore::FrameLoader::loadInSameDocument): Use Document::enqueueHashchangeEvent
2323
2324         * storage/StorageEventDispatcher.cpp:
2325         (WebCore::StorageEventDispatcher::dispatch): Use Document::enqueueEvent
2326
2327 2010-03-19  Kevin Decker  <kdecker@apple.com>
2328
2329         Reviewed by Darin Adler and Brady Eidson.
2330
2331         First step toward:
2332         https://bugs.webkit.org/show_bug.cgi?id=36328
2333
2334         This is the first step torward eliminating the WebKit WebNullPluginView class. The responsibility for this will soon
2335         be in platform-independent code in WebCore. The plan is to change RenderEmbeddedObject and give it the capability of
2336         drawing the missing plug-in text. 
2337
2338         * loader/FrameLoader.cpp:
2339         (WebCore::FrameLoader::requestObject): Renamed the renderer parameter to requestEmbeddedObject and made it
2340         a RenderEmbeddedObject.
2341         (WebCore::FrameLoader::loadPlugin): Likewise.
2342         * loader/FrameLoader.h: Updated loadPlugin() and requestObject() method signatures accordingly. 
2343
2344 2010-03-19  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
2345
2346         Reviewed by Simon Hausmann.
2347
2348         [Qt] Disable TILED_BACKING_STORE if Qt version is earlier than Qt4.6
2349         https://bugs.webkit.org/show_bug.cgi?id=36348
2350
2351         Backing store implementation for QtWebKit requires at least Qt
2352         version 4.6.
2353
2354         No new tests as there is no new functionality.
2355
2356         * WebCore.pri:
2357
2358 2010-03-19  Joseph Pecoraro  <joepeck@webkit.org>
2359
2360         Reviewed by David Kilzer.
2361
2362         <input type=range> does not validate correctly without a renderer and the tests are incorrect
2363         https://bugs.webkit.org/show_bug.cgi?id=36259
2364
2365         Setting value attribute on an <input type=range> to an out-of-range value fires oninput
2366         https://bugs.webkit.org/show_bug.cgi?id=16990
2367
2368         Part 2 of 2: When setting the range element's value, overflows and underflows
2369         are automatically sanitized to valid values. Moved the general case
2370         sanitization code out of the Renderer into HTMLInputElement::sanitizeValue.
2371
2372         * html/HTMLInputElement.cpp:
2373         (WebCore::HTMLInputElement::value): when getting a default value on reset() ensure the defaultValue is provided
2374         (WebCore::HTMLInputElement::sanitizeValue): clamp the value within the max/min/step range constraints
2375         * html/StepRange.cpp:
2376         (WebCore::StepRange::StepRange): allow const element in the constructor
2377         (WebCore::StepRange::clampValue): clamp from a String value
2378         * html/StepRange.h:
2379         (WebCore::StepRange::defaultValue): easy calculation of the default value for max/min/step range constraints
2380         * rendering/RenderSlider.cpp:
2381         (WebCore::RenderSlider::updateFromElement): no longer handle the general case sanitization in the renderer
2382
2383 2010-03-19  Joseph Pecoraro  <joepeck@webkit.org>
2384
2385         Reviewed by David Kilzer.
2386
2387         <input type=range> does not validate correctly without a renderer and the tests are incorrect
2388         https://bugs.webkit.org/show_bug.cgi?id=36259
2389
2390         Part 1 of 2: Refactoring the SliderRange struct out of RenderSlider
2391         into a more appropriate place. Changed the named to StepRange. Changed
2392         from a struct to a class.
2393
2394           Added new files to the build.
2395
2396         * GNUmakefile.am:
2397         * WebCore.gypi:
2398         * WebCore.pro:
2399         * WebCore.vcproj/WebCore.vcproj:
2400         * WebCore.xcodeproj/project.pbxproj:
2401
2402           Renamed and moved class SliderRange to StepRange.
2403
2404         * html/StepRange.cpp: Added.
2405         (WebCore::StepRange::StepRange):
2406         (WebCore::StepRange::clampValue):
2407         (WebCore::StepRange::valueFromElement):
2408         (WebCore::sliderPosition):
2409         * html/StepRange.h: Added.
2410         (WebCore::StepRange::proportionFromValue):
2411         (WebCore::StepRange::valueFromProportion):
2412         * rendering/RenderSlider.cpp:
2413         (WebCore::RenderSlider::updateFromElement): updated to use StepRange
2414         (WebCore::RenderSlider::setValueForPosition): updated to use StepRange
2415
2416 2010-03-19  Antti Koivisto  <koivisto@iki.fi>
2417
2418         Reviewed by Simon Hausmann.
2419
2420         https://bugs.webkit.org/show_bug.cgi?id=36366
2421         Repaint loop when painting using scaled CTMs with different translations
2422
2423         The code in RenderBoxModelScaleObserver::shouldPaintBackgroundAtLowQuality
2424         tests if the scaling has changed from the previous value by comparing the
2425         transformations. The test fails if the scale is the same but the translation 
2426         changes. This can lead to infinite repaint loop if the document is painted 
2427         in pieces using different translations (for example for tiling).
2428
2429         * rendering/RenderBoxModelObject.cpp:
2430         (WebCore::RenderBoxModelScaleObserver::shouldPaintBackgroundAtLowQuality):
2431
2432 2010-03-19  Pavel Feldman  <pfeldman@chromium.org>
2433
2434         Reviewed by Timothy Hatcher.
2435
2436         Web Inspector: editing shorthands does not always work.
2437
2438         https://bugs.webkit.org/show_bug.cgi?id=36362
2439
2440         * inspector/InspectorDOMAgent.cpp:
2441         (WebCore::InspectorDOMAgent::applyStyleText):
2442         (WebCore::InspectorDOMAgent::populateObjectWithStyleProperties):
2443         (WebCore::InspectorDOMAgent::shorthandValue):
2444         * inspector/InspectorDOMAgent.h:
2445         * inspector/front-end/StylesSidebarPane.js:
2446         (WebInspector.StylePropertyTreeElement.prototype):
2447         * inspector/front-end/inspector.css:
2448         (.section .properties li.disabled .enabled-button):
2449         * inspector/front-end/inspector.js:
2450         (WebInspector.startEditing.editingCommitted):
2451
2452 2010-03-19  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2453
2454         Reviewed by Simon Hausmann.
2455
2456         [Qt] Don't replace clip when drawing complex text
2457
2458         * platform/graphics/qt/FontQt.cpp:
2459
2460 2010-03-18  Darin Fisher  <darin@chromium.org>
2461
2462         Reviewed by Adam Barth.
2463
2464         If a frame is already in the document, then setting its "src" attribute
2465         should add the resultant navigation to history.
2466
2467         https://bugs.webkit.org/show_bug.cgi?id=9166
2468
2469         This behavior is specified in section 4.8.2 of the HTML5 spec.
2470
2471         Test: fast/loader/frame-src-change-added-to-history.html
2472
2473         * html/HTMLFrameElementBase.cpp:
2474         (WebCore::HTMLFrameElementBase::openURL):
2475         (WebCore::HTMLFrameElementBase::setLocation):
2476         * html/HTMLFrameElementBase.h:
2477         * loader/FrameLoader.cpp:
2478         (WebCore::FrameLoader::requestFrame):
2479         * loader/FrameLoader.h:
2480
2481 2010-03-18  Chris Evans  <cevans@chromium.org>
2482
2483         Reviewed by Nikolas Zimmermann.
2484
2485         Fix a minor crash with mismatched array sizes in SVG animation
2486         elements.
2487
2488         https://bugs.webkit.org/show_bug.cgi?id=35606
2489
2490         Test: svg/animations/keypoints-mismatch.svg
2491
2492         * svg/SVGAnimationElement.cpp:
2493         (WebCore::SVGAnimationElement::startedActiveInterval):
2494         Globally apply validations relevant to all animation types.
2495
2496 2010-03-18  Vangelis Kokkevis  <vangelis@chromium.org>
2497
2498         Reviewed by Adam Barth.
2499
2500         Implement software composited graphics layers in Chromium using the Skia library.
2501         https://bugs.webkit.org/show_bug.cgi?id=35557
2502         This is an initial step in the implementation. Layer compositing is functioning
2503         but not optimized in any way. Subsesquent check-ins will be necessary to fine tune
2504         it.
2505
2506         Test: No new exposed functionality so no new tests.
2507
2508         * WebCore.gypi:
2509           Added new source files to the chromium build
2510         * platform/graphics/GraphicsLayer.h:
2511           Added necessary typedef's and forward declarations for Chromium.
2512         * platform/graphics/skia/GraphicsLayerSkia.cpp: Added.
2513         * platform/graphics/skia/GraphicsLayerSkia.h: Added.
2514           Declaration and implementation of the platform-specific GraphicsLayer class.
2515         * platform/graphics/skia/LayerRendererSkia.cpp: Added.
2516         * platform/graphics/skia/LayerRendererSkia.h: Added.
2517           Declaration and implementation of the Skia-based software compositor.
2518         * platform/graphics/skia/LayerSkia.cpp: Added.
2519         * platform/graphics/skia/LayerSkia.h: Added.
2520           Declaration and implementation of a compositable layer that uses a Skia canvas
2521           for backing store.
2522
2523 2010-03-18  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2524
2525         Reviewed by Darin Adler.
2526
2527         Make setPrinting() with printing=false, restore the previous
2528         media type in use.
2529
2530         Test: fast/media/print-restores-previous-mediatype.html
2531
2532         * page/Frame.cpp:
2533         (WebCore::Frame::setPrinting):
2534         * page/FrameView.cpp:
2535         (WebCore::FrameView::adjustMediaTypeForPrinting):
2536         * page/FrameView.h:
2537
2538 2010-03-18  David Kilzer  <ddkilzer@apple.com>
2539
2540         <http://webkit.org/b/36338> Remove unused RenderReplaced::adjustOverflowForBoxShadowAndReflect() declaration
2541
2542         Rubber-stamped by Darin Adler.
2543
2544         This declaration should have been removed in r47440.
2545
2546         * rendering/RenderReplaced.h:
2547         (WebCore::RenderReplaced::adjustOverflowForBoxShadowAndReflect): Removed.
2548
2549 2010-03-18  Jian Li  <jianli@chromium.org>
2550
2551         Reviewed by Dmitry Titov.
2552
2553         Dragging a PDF image triggers assertion in DragController::startDrag()
2554         https://bugs.webkit.org/show_bug.cgi?id=36247
2555
2556         Test: fast/images/drag-pdf-as-image.html
2557
2558         * platform/graphics/cg/PDFDocumentImage.cpp:
2559         (WebCore::PDFDocumentImage::filenameExtension):
2560         * platform/graphics/cg/PDFDocumentImage.h:
2561
2562 2010-03-18  Simon Fraser  <simon.fraser@apple.com>
2563
2564         Reviewed by Dan Bernstein.
2565
2566         Avoid taking a reference to a String owned by a temporary AtomicString.
2567
2568         * css/CSSSelector.cpp:
2569         (WebCore::CSSSelector::RareData::parseNth):
2570
2571 2010-03-18  Chris Marrin  <cmarrin@apple.com>
2572
2573         Reviewed by Simon Fraser.
2574
2575         Fixed parenting issues with HW layers on Windows
2576         https://bugs.webkit.org/show_bug.cgi?id=32449
2577         
2578         CACF can't properly fix superlayer changes, so a layer added
2579         as a sublayer must have a null superlayer. I changed a couple of
2580         places that change sublayers to removeFromSuperlayer while adding
2581         to a new layer. This fixes both the problem of disappearing children
2582         and children getting doubled. Also got rid of removeSublayer(). Layers
2583         should always be removed from their parent with removeFromSuperlayer().
2584         
2585         This also removed moveLayer(), which is not used and may not be safe in how
2586         it copies.
2587
2588         * platform/graphics/win/GraphicsLayerCACF.cpp:Changed setName to be like Mac, to give more debugging info (to fix problems like these)
2589         (WebCore::GraphicsLayerCACF::setName):
2590         * platform/graphics/win/WKCACFLayer.cpp:Make sure superlayer is null before adding
2591         (WebCore::WKCACFLayer::insertSublayer):
2592         (WebCore::WKCACFLayer::replaceSublayer):
2593         (WebCore::WKCACFLayer::removeFromSuperlayer):
2594         (WebCore::WKCACFLayer::setSublayers):
2595         (WebCore::WKCACFLayer::printLayer):print the superlayer for better debugging
2596         * platform/graphics/win/WKCACFLayer.h:
2597
2598 2010-03-18  Dimitri Glazkov  <dglazkov@chromium.org>
2599
2600         Unreviewed, build fix.
2601
2602         [Chromium] Change the order of mac/ and cg/ include dirs to fix compile break
2603         due to http://trac.webkit.org/changeset/56192,
2604
2605         * WebCore.gyp/WebCore.gyp: Changed the order.
2606
2607 2010-03-18  David Hyatt  <hyatt@apple.com>
2608
2609         Reviewed by Oliver Hunt.
2610
2611         https://bugs.webkit.org/show_bug.cgi?id=36325
2612
2613         Add support for stopImmediatePropagation from DOM Level 3 Events.
2614
2615         Added fast/events/stop-immediate-propagation.html.
2616
2617         * dom/Event.cpp:
2618         (WebCore::Event::Event):
2619         * dom/Event.h:
2620         (WebCore::Event::timeStamp):
2621         (WebCore::Event::stopPropagation):
2622         (WebCore::Event::stopImmediatePropagation):
2623         (WebCore::Event::propagationStopped):
2624         (WebCore::Event::immediatePropagationStopped):
2625         * dom/Event.idl:
2626         * dom/EventTarget.cpp:
2627         (WebCore::EventTarget::fireEventListeners):
2628
2629 2010-03-18  Dimitri Glazkov  <dglazkov@chromium.org>
2630
2631         Unreviewed, build fix.
2632
2633         Return frame accessor back to Geolocation, it's used in GeolocationServiceChromium.
2634         The accessor was removed in http://trac.webkit.org/changeset/56188.
2635
2636         * page/Geolocation.h:
2637         (WebCore::Geolocation::frame): Added back.
2638
2639 2010-03-18  Brent Fulgham  <bfulgham@webkit.org>
2640
2641         Reviewed by Adam Roben.
2642
2643         Help reduce build problems due to font declarations.
2644         https://bugs.webkit.org/show_bug.cgi?id=36190
2645
2646         Functions unchanged, no new tests.
2647
2648         * WebCore.vcproj/WebCore.vcproj: Add new file, and show
2649           movement of FontPlatformData.h to cg/ directory.
2650         * platform/graphics/cairo/FontPlatformData.h: Merge in
2651           WinCairo-specific declarations.  Correct constructor
2652           declaration to use type float for font size.
2653         (WebCore::FontPlatformData::FontPlatformData):
2654         (WebCore::FontPlatformData::hfont):
2655         (WebCore::FontPlatformData::useGDI):
2656         (WebCore::FontPlatformData::fontFace):
2657         (WebCore::FontPlatformData::setSize):
2658         (WebCore::FontPlatformData::hash):
2659         (WebCore::FontPlatformData::isHashTableDeletedValue):
2660         * platform/graphics/cairo/FontPlatformDataCairo.cpp:
2661         (WebCore::FontPlatformData::FontPlatformData): Correct
2662           constructor to accept type float for font size.
2663         * platform/graphics/cg/FontPlatformData.h: Copied from WebCore/platform/graphics/win/FontPlatformData.h.
2664         (WebCore::FontPlatformData::FontPlatformData):
2665         (WebCore::FontPlatformData::hfont):
2666         (WebCore::FontPlatformData::cgFont):
2667         (WebCore::FontPlatformData::operator==):
2668         * platform/graphics/win/FontPlatformData.h: Removed.
2669         * platform/graphics/win/FontPlatformDataCairoWin.cpp:
2670         (WebCore::FontPlatformData::operator==): Move implementation
2671           here (previously in header) to match other cairo-based ports.
2672         * platform/graphics/win/RefCountedHFONT.h: Added.  This
2673           was extracted from win/FontPlatformData.h, and is now shared
2674           by the cg/FontPlatformData.h and cairo/FontPlatformData.h
2675         (WebCore::RefCountedHFONT::create):
2676         (WebCore::RefCountedHFONT::createDeleted):
2677         (WebCore::RefCountedHFONT::~RefCountedHFONT):
2678         (WebCore::RefCountedHFONT::hfont):
2679         (WebCore::RefCountedHFONT::hash):
2680         (WebCore::RefCountedHFONT::RefCountedHFONT):
2681
2682 2010-03-18  Simon Fraser  <simon.fraser@apple.com>
2683
2684         No review.
2685
2686         Fix brace style after r56170.
2687         
2688         * css/CSSStyleSelector.cpp:
2689         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
2690
2691 2010-03-18  Simon Fraser  <simon.fraser@apple.com>
2692
2693         Reviewed by Dave Hyatt.
2694
2695         https://bugs.webkit.org/show_bug.cgi?id=36274
2696         CSS3 :nth-child selector 'odd' keyword case sensitivity test fails
2697         
2698         The tests for "odd", "even" etc. for nth-child selectors should be case insensitive.
2699
2700         Test: fast/css/nth-child-odd-case-insensitive.html
2701
2702         * css/CSSSelector.cpp:
2703         (WebCore::CSSSelector::RareData::parseNth):
2704
2705 2010-03-18  David Hyatt  <hyatt@apple.com>
2706
2707         Reviewed by Oliver Hunt.
2708
2709         https://bugs.webkit.org/show_bug.cgi?id=36265
2710
2711         Add support for event.defaultPrevented from DOM level 3.
2712     
2713         Added fast/events/defaultprevented.html
2714
2715         * dom/Event.idl:
2716
2717 2010-03-18  Darin Adler  <darin@apple.com>
2718
2719         Reviewed by Kenneth Rohde Christiansen.
2720
2721         Remove Geolocation.lastPosition, no longer in the spec.
2722         https://bugs.webkit.org/show_bug.cgi?id=36255
2723         rdar://problem/7746357
2724
2725         * WebCore.base.exp: Updated since Geolocation's destructor is now non-virtual.
2726
2727         * page/Geolocation.cpp:
2728         (WebCore::Geolocation::lastPosition): Add an assertion; it's only legal to
2729         call this if access to the location is allowed.
2730
2731         * page/Geolocation.h: Removed unneeded includes. Made destructor non-virtual,
2732         although it will still be virtual if any of the base classes have a virtual
2733         destructor. Made lastPosition, isAllowed, and isDenied functions private.
2734         Removed unused suspend, resume, setShouldClearCache, shouldClearCache,
2735         and frame functions.
2736
2737         * page/Geolocation.idl: Removed lastPosition read-only attribute. No longer in
2738         the Geolocation specification.
2739
2740 2010-03-18  David Hyatt  <hyatt@apple.com>
2741
2742         Reviewed by Simon Fraser.
2743
2744         https://bugs.webkit.org/show_bug.cgi?id=36275
2745
2746         Make sure :not does not allow pseudo-elements inside it. (Hooray for another pointless
2747         restriction on :not.)
2748
2749         Added fast/css/invalid-not-with-pseudo-element.html
2750
2751         * css/CSSGrammar.y:
2752         * css/CSSSelector.h:
2753         (WebCore::CSSSelector::matchesPseudoElement):
2754
2755 2010-03-18  Dan Bernstein  <mitz@apple.com>
2756
2757         Reviewed by Darin Adler.
2758
2759         <rdar://problem/7761400> Rework the fix for
2760         https://bugs.webkit.org/show_bug.cgi?id=18722
2761
2762         Test: fast/dynamic/float-remove-above-line-2.html
2763
2764         * rendering/RenderBlock.cpp:
2765         (WebCore::RenderBlock::removeFloatingObject): Treat 0- and less-than-0-height floats
2766         as having a height of 1 so that they intersect with the line they originate on.
2767         (WebCore::RenderBlock::clearFloats): Use numeric_limits.
2768         * rendering/RenderBlockLineLayout.cpp:
2769         (WebCore::RenderBlock::layoutInlineChildren): Removed the intersection checks here,
2770         so that a float is always included in the float list of the line it originates on, even
2771         if it does not intersect that line. This ensures that every float is accounted for, which
2772         is necessary during incremental layout when adding floats from clean lines.
2773
2774 2010-03-18  Antti Koivisto  <koivisto@iki.fi>
2775
2776         Reviewed by Kenneth Rohde Christiansen.
2777
2778         https://bugs.webkit.org/show_bug.cgi?id=36102
2779         [Qt] Scaling control API for tiled backing store
2780         
2781         Commit the new scale synchronously after unfreeze to avoid ugliness.
2782
2783         * platform/graphics/TiledBackingStore.cpp:
2784         (WebCore::TiledBackingStore::TiledBackingStore):
2785         (WebCore::TiledBackingStore::setContentsScale):
2786         (WebCore::TiledBackingStore::commitScaleChange):
2787         (WebCore::TiledBackingStore::setContentsFrozen):
2788         * platform/graphics/TiledBackingStore.h:
2789
2790 2010-03-18  David Hyatt  <hyatt@apple.com>
2791
2792         Reviewed by Simon Fraser.
2793
2794         https://bugs.webkit.org/show_bug.cgi?id=36281
2795
2796         Make sure an exception is raised if an @import rule is inserted in the wrong place.
2797         
2798         Also make sure (so that this particular test case passes) that rgba(0, 0, 0, 0) is dumped
2799         as transparent by getComputedStyle, since it most commonly occurs in background-color and
2800         that default makes more sense than dumping rgba values.
2801
2802         Added fast/css/invalid-import-insertion.html
2803
2804         * css/CSSPrimitiveValue.cpp:
2805         (WebCore::CSSPrimitiveValue::createColor):
2806         * css/CSSStyleSheet.cpp:
2807         (WebCore::CSSStyleSheet::insertRule):
2808
2809 2010-03-18  Luiz Agostini  <luiz.agostini@openbossa.org>
2810
2811         Reviewed by Kenneth Rohde Christiansen.
2812
2813         Multiselect Popup - Listbox click simulation
2814         https://bugs.webkit.org/show_bug.cgi?id=36177
2815
2816         Listbox popups will need to notify the corresponding select elements that a
2817         selection change happened. The current HTMLSelectElement interface does not
2818         allow multiple selections.
2819
2820         The new method  listBoxSelectItem will be used for that. I have refactored part
2821         of the mouse handling code in bug 36124 and I am now reusing it here for
2822         <select multiple> popups. All the other cases will handled as they were before to be
2823         sure that no side effects will show up.
2824
2825         * dom/SelectElement.cpp:
2826         (WebCore::SelectElement::updateListBoxSelection):
2827         (WebCore::SelectElement::listBoxOnChange):
2828         * dom/SelectElement.h:
2829         * html/HTMLSelectElement.cpp:
2830         (WebCore::HTMLSelectElement::listBoxPopupClick):
2831         * html/HTMLSelectElement.h:
2832
2833 2010-03-12  Ojan Vafai  <ojan@chromium.org>
2834
2835         Reviewed by David Levin.
2836
2837         smartdelete should only occur after double-click
2838         https://bugs.webkit.org/show_bug.cgi?id=35314
2839
2840         1. Consolidate all notions of selection-granularity into SelectionController.
2841         2. Now only mouse-based selections store a selection-granularity. This matches NSTextView.
2842
2843         New tests were added in http://trac.webkit.org/changeset/55913.
2844
2845         * WebCore.base.exp:
2846         * editing/MoveSelectionCommand.cpp:
2847         (WebCore::MoveSelectionCommand::MoveSelectionCommand):
2848         (WebCore::MoveSelectionCommand::doApply):
2849         * editing/MoveSelectionCommand.h:
2850         (WebCore::MoveSelectionCommand::create):
2851         * editing/SelectionController.cpp:
2852         (WebCore::SelectionController::SelectionController):
2853         (WebCore::SelectionController::setSelection):
2854         (WebCore::SelectionController::modify):
2855         (WebCore::SelectionController::clear):
2856         * editing/SelectionController.h:
2857         (WebCore::SelectionController::setSelection):
2858         (WebCore::SelectionController::granularity):
2859         * editing/VisibleSelection.cpp:
2860         (WebCore::VisibleSelection::VisibleSelection):
2861         (WebCore::VisibleSelection::expandUsingGranularity):
2862         (WebCore::VisibleSelection::setStartAndEndFromBaseAndExtentRespectingGranularity):
2863         (WebCore::VisibleSelection::validate):
2864         * editing/VisibleSelection.h:
2865         (WebCore::operator==):
2866         * loader/FrameLoader.cpp:
2867         (WebCore::FrameLoader::clear):
2868         * page/DOMSelection.cpp:
2869         (WebCore::DOMSelection::extend):
2870         * page/DragController.cpp:
2871         (WebCore::DragController::concludeEditDrag):
2872         * page/EventHandler.cpp:
2873         (WebCore::EventHandler::selectClosestWordFromMouseEvent):
2874         (WebCore::EventHandler::selectClosestWordOrLinkFromMouseEvent):
2875         (WebCore::EventHandler::handleMousePressEventTripleClick):
2876         (WebCore::EventHandler::handleMousePressEventSingleClick):
2877         (WebCore::EventHandler::updateSelectionForMouseDrag):
2878         * page/Frame.cpp:
2879         (WebCore::Frame::Frame):
2880         (WebCore::Frame::selectionGranularity):
2881         * page/Frame.h:
2882         * rendering/RenderTextControl.cpp:
2883         (WebCore::RenderTextControl::setSelectionRange):
2884
2885 2010-03-18  Dimitri Glazkov  <dglazkov@chromium.org>
2886
2887         Unreviewed, build fix.
2888
2889         [V8] Turn npObjectTypeInfo into a function, make everyone happy.
2890
2891         * bindings/v8/NPV8Object.cpp:
2892         (WebCore::npObjectTypeInfo): Added new function.
2893         (npCreateV8ScriptObject):
2894         * bindings/v8/NPV8Object.h: Turned npObjectTypeInfo into function.
2895         * bindings/v8/V8NPObject.cpp: Replaced references to function
2896
2897 2010-03-18  David Hyatt  <hyatt@apple.com>
2898
2899         Reviewed by Simon Fraser.
2900
2901         https://bugs.webkit.org/show_bug.cgi?id=36283
2902         
2903         The wrong constants were being used for the code that attempted to compact the background-repeat shorthand to
2904         a single value.
2905
2906         Added fast/backgrounds/background-repeat-computed-style.html
2907
2908         * css/CSSComputedStyleDeclaration.cpp:
2909         (WebCore::fillRepeatToCSSValue):
2910
2911 2010-03-18  Simon Fraser  <simon.fraser@apple.com>
2912
2913         Reviewed by Dave Hyatt.
2914
2915         https://bugs.webkit.org/show_bug.cgi?id=36273
2916         CSS3 :indeterminate and input type=radio test fails
2917
2918         The :indeterminate pseudo-class should apply to both radio buttons and checkboxes.
2919
2920         * html/HTMLInputElement.cpp:
2921         (WebCore::HTMLInputElement::setIndeterminate): Use allowsIndeterminate() to determine if the input
2922         supports the indeterminate state.
2923         (WebCore::HTMLInputElement::preDispatchEventHandler): Use allowsIndeterminate() to determine whether
2924         to handle the indeterminate state.
2925         (WebCore::HTMLInputElement::postDispatchEventHandler): Ditto.
2926         * html/HTMLInputElement.h:
2927         (WebCore::HTMLInputElement::allowsIndeterminate): New utility method, returns true for radio buttons
2928         and checkboxes.
2929
2930 2010-03-18  Simon Fraser  <simon.fraser@apple.com>
2931
2932         Reviewed by Dave Hyatt.
2933
2934         https://bugs.webkit.org/show_bug.cgi?id=36271
2935         CSS3 :enabled on an input type=hidden element fails
2936         
2937         The CSS3 selectors spec now makes it clear that hidden inputs should respect
2938         the :enabled and :disabled pseudo-classes.
2939
2940         Test: fast/forms/hidden-input-enabled.html
2941
2942         * css/CSSStyleSelector.cpp:
2943         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector): Remove checks for hidden inputs.
2944
2945 2010-03-18  Enrica Casucci  <enrica@apple.com>
2946
2947         Reviewed by Simon Fraser.
2948
2949         Intro text at Star Wars demo is clipped.
2950         <rdar://problem/7560979>
2951         https://bugs.webkit.org/show_bug.cgi?id=33909
2952         
2953         Test: compositing/repaint/layer-repaint.html
2954         
2955         We are flipping the coordinates for drawing, therefore
2956         we must flip them also when we invalidate the rectangles.
2957
2958         * platform/graphics/win/GraphicsLayerCACF.cpp:
2959         (WebCore::WebLayer::setNeedsDisplay):
2960
2961 2010-03-18  Nate Chapin  <japhet@chromium.org>
2962
2963         Unreviewed, Chromium build fix.
2964
2965         Missed a #include in V8Collection.h.
2966
2967         * bindings/v8/V8Collection.h:
2968
2969 2010-03-18  David Hyatt  <hyatt@apple.com>
2970
2971         Reviewed by Simon Fraser.
2972
2973         Fix for https://bugs.webkit.org/show_bug.cgi?id=36284.
2974         
2975         Make sure the CSS parser properly rejects negative border widths.
2976
2977         Added fast/borders/negative-border-width.html
2978
2979         * css/CSSParser.cpp:
2980         (WebCore::CSSParser::parseValue):
2981
2982 2010-03-18  Nate Chapin  <japhet@chromium.org>
2983
2984         Reviewed by Dimitri Glazkov.
2985
2986         [V8] Remove V8Index.h and all references to V8ClassIndex.
2987         
2988         https://bugs.webkit.org/show_bug.cgi?id=33477
2989
2990         * WebCore.gypi:
2991         * bindings/scripts/CodeGeneratorV8.pm:
2992         * bindings/v8/NPV8Object.cpp:
2993         * bindings/v8/NPV8Object.h:
2994         * bindings/v8/V8Collection.h:
2995         * bindings/v8/V8DOMWindowShell.cpp:
2996         * bindings/v8/V8DOMWindowShell.h:
2997         * bindings/v8/V8DOMWrapper.cpp:
2998         * bindings/v8/V8DOMWrapper.h:
2999         * bindings/v8/V8GCController.cpp:
3000         * bindings/v8/V8Helpers.cpp:
3001         * bindings/v8/V8Index.h: Removed.
3002         * bindings/v8/V8IsolatedContext.h:
3003         * bindings/v8/V8NPObject.cpp:
3004         * bindings/v8/V8Proxy.cpp:
3005         * bindings/v8/V8Proxy.h:
3006         * bindings/v8/V8SVGPODTypeWrapper.h:
3007         * bindings/v8/WorkerContextExecutionProxy.cpp:
3008         * bindings/v8/WorkerContextExecutionProxy.h:
3009         * bindings/v8/WrapperTypeInfo.h: Move WrapperTypeInfo struct into its own file from V8Index.h.
3010         * bindings/v8/custom/V8CanvasRenderingContext2DCustom.cpp:
3011         * bindings/v8/custom/V8DOMWindowCustom.cpp:
3012         * bindings/v8/custom/V8EventSourceConstructor.cpp:
3013         * bindings/v8/custom/V8HTMLAudioElementConstructor.cpp:
3014         * bindings/v8/custom/V8HTMLAudioElementConstructor.h:
3015         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
3016         * bindings/v8/custom/V8HTMLImageElementConstructor.h:
3017         * bindings/v8/custom/V8HTMLOptionElementConstructor.cpp:
3018         * bindings/v8/custom/V8HTMLOptionElementConstructor.h:
3019         * bindings/v8/custom/V8HistoryCustom.cpp:
3020         * bindings/v8/custom/V8LocationCustom.cpp:
3021         * bindings/v8/custom/V8WebGLArrayCustom.h:
3022         * bindings/v8/custom/V8WebGLByteArrayCustom.cpp:
3023         * bindings/v8/custom/V8WebGLFloatArrayCustom.cpp:
3024         * bindings/v8/custom/V8WebGLIntArrayCustom.cpp:
3025         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
3026         * bindings/v8/custom/V8WebGLShortArrayCustom.cpp:
3027         * bindings/v8/custom/V8WebGLUnsignedByteArrayCustom.cpp:
3028         * bindings/v8/custom/V8WebGLUnsignedIntArrayCustom.cpp:
3029         * bindings/v8/custom/V8WebGLUnsignedShortArrayCustom.cpp:
3030         * bindings/v8/custom/V8WebKitPointConstructor.cpp:
3031
3032 2010-03-18  Yury Semikhatsky  <yurys@chromium.org>
3033
3034         Reviewed by Pavel Feldman.
3035
3036         Preserve console history between debugging sessions.
3037
3038         https://bugs.webkit.org/show_bug.cgi?id=36223
3039
3040         * inspector/front-end/ConsoleView.js:
3041         (WebInspector.ConsoleView.prototype._settingsLoaded):
3042         (WebInspector.ConsoleView.prototype._enterKeyPressed.printResult):
3043         (WebInspector.ConsoleView.prototype._enterKeyPressed):
3044         * inspector/front-end/Settings.js:
3045         (WebInspector.Settings.prototype._load):
3046
3047 2010-03-18  Kim Grönholm  <kim.gronholm@nomovok.com>
3048
3049         Reviewed by Simon Hausmann.
3050
3051         [Qt] GraphicsLayer: Pausing and resuming of animations don't work as expected
3052         https://bugs.webkit.org/show_bug.cgi?id=36219
3053         
3054         addAnimation and pauseAnimation were handling animation state changes in
3055         the wrong way.
3056         Apparently WebCore calls addAnimation for resuming, so we have to make 
3057         sure to resume an existing animation if that happens. Also, timeOffset 
3058         is now used for synchronization of the Qt animation clock with the 
3059         WebCore clock, as opposed to using it as a delay timer. 
3060         Both those fixes were necessary to get the layout test to work.
3061         
3062         LayoutTests/animations/play-state.html now passed on Qt.
3063
3064         * platform/graphics/qt/GraphicsLayerQt.cpp:
3065         (WebCore::AnimationQtBase::AnimationQtBase):
3066         (WebCore::TransformAnimationQt::updateState):
3067         (WebCore::GraphicsLayerQt::addAnimation):
3068         (WebCore::GraphicsLayerQt::pauseAnimation):
3069
3070 2010-03-18  Adam Langley  <agl@chromium.org>
3071
3072         Reviewed by David Levin.
3073
3074         [chromium] Fix inverted logic in per-strike renderer patch.
3075
3076         I screwed up in r55089 and got one of the conditions backwards. Thanks
3077         to Roman Tsisyk for pointing it out.
3078
3079         https://bugs.webkit.org/show_bug.cgi?id=35495
3080
3081         Test: platform/chromium/fast/text/chromium-linux-fontconfig-renderstyle.html
3082
3083         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
3084         (WebCore::FontPlatformData::querySystemForRenderStyle):
3085
3086 2010-03-18  Pavel Feldman  <pfeldman@chromium.org>
3087
3088         Reviewed by Timothy Hatcher.
3089
3090         Web Inspector: Show inherited styles for a selected DOM element
3091
3092         https://bugs.webkit.org/show_bug.cgi?id=28039
3093
3094         * English.lproj/localizedStrings.js:
3095         * inspector/InspectorDOMAgent.cpp:
3096         (WebCore::InspectorDOMAgent::getStyles):
3097         (WebCore::InspectorDOMAgent::populateObjectWithStyleProperties):
3098         * inspector/front-end/DOMAgent.js:
3099         (WebInspector.CSSStyleDeclaration):
3100         * inspector/front-end/StylesSidebarPane.js:
3101         (WebInspector.StylesSidebarPane.prototype._update):
3102         (WebInspector.StylesSidebarPane.prototype._containsInherited):
3103         (WebInspector.StylePropertiesSection):
3104         (WebInspector.StylePropertiesSection.prototype.isPropertyInherited):
3105         (WebInspector.StylePropertiesSection.prototype.onpopulate):
3106
3107 2010-03-15  Antonio Gomes  <tonikitoo@webkit.org>
3108
3109         Reviewed by Gustavo Noronha.
3110         Patch by Antonio Gomes <tonikitoo@webkit.org>
3111
3112         Spatial Navigation: Add isNull() and document() convenience methods to FocusCandidate.
3113         https://bugs.webkit.org/show_bug.cgi?id=36167
3114
3115         It turns out that Spatial Navigation related code (in FocusController.cpp for
3116         instance) can be simplified and look better if FocusCandidate class offer some
3117         convenience method. This patch introduces a couple of them (isNull and a Document
3118         getter). It also adds another constructor that receives a Node as parameter.
3119
3120         A followup refactoring patch will be making use of these helper methods.
3121
3122         * page/SpatialNavigation.h:
3123         (WebCore::FocusCandidate::FocusCandidate): Added a "Node*" parameter
3124         to FocusCandidate's constructor.
3125         (WebCore::FocusCandidate::isNull): In the Spatial Navigation logic, a NULL
3126         FocusCandidate object is one that does not hold a valid reference to a "Node*".
3127         (WebCore::FocusCandidate::document): This method returns a pointer for the FocusCandidate
3128         node's document, if |node| is a valid pointer.
3129
3130 2010-03-18  Noam Rosenthal  <noam.rosenthal@nokia.com>
3131
3132         Reviewed by Antti Koivisto.
3133
3134         [Qt] [Performance] GraphicsLayerQt updates the scene too often
3135         https://bugs.webkit.org/show_bug.cgi?id=36158
3136
3137         This fix makes sure that flushChanges is only called when necessary,
3138         by calling the notifySync function asynchronously, which makes sure flushChanges() is called
3139         after the WebCore compositor has made all its changes.
3140
3141         This has shown a visual improvement on several test-cases.
3142
3143         * Makefile:
3144         * platform/graphics/qt/GraphicsLayerQt.cpp:
3145         (WebCore::GraphicsLayerQtImpl::):
3146         (WebCore::GraphicsLayerQtImpl::notifySyncRequired):
3147         (WebCore::GraphicsLayerQtImpl::notifyChange):
3148         (WebCore::GraphicsLayerQtImpl::flushChanges):
3149         (WebCore::GraphicsLayerQt::setMaskLayer):
3150         (WebCore::GraphicsLayerQt::setPosition):
3151         (WebCore::GraphicsLayerQt::setAnchorPoint):
3152         (WebCore::GraphicsLayerQt::setSize):
3153         (WebCore::GraphicsLayerQt::setTransform):
3154         (WebCore::GraphicsLayerQt::setChildrenTransform):
3155         (WebCore::GraphicsLayerQt::setPreserves3D):
3156         (WebCore::GraphicsLayerQt::setMasksToBounds):
3157         (WebCore::GraphicsLayerQt::setDrawsContent):
3158         (WebCore::GraphicsLayerQt::setBackgroundColor):
3159         (WebCore::GraphicsLayerQt::clearBackgroundColor):
3160         (WebCore::GraphicsLayerQt::setContentsOpaque):
3161         (WebCore::GraphicsLayerQt::setBackfaceVisibility):
3162         (WebCore::GraphicsLayerQt::setOpacity):
3163         (WebCore::GraphicsLayerQt::setContentsRect):
3164
3165 2010-03-18  Stephen White  <senorblanco@chromium.org>
3166
3167         Reviewed by Oliver Hunt.
3168
3169         Parsing of rgb() colors in HTML canvas is still fairly slow.
3170         findNamedColor() was showing up as hot, so this patch attempts to
3171         avoid calling it by putting the rgb() check ahead of the named
3172         colors.  It also removes a call to Color::Color() from
3173         CanvasStyle, which was doing a redundant check for the hex
3174         color and named colors, which CSSParser already does.  Finally, it
3175         changes the ad-hoc parser to check for negative values, and clamps them
3176         at zero.  This avoids the lex/yacc path for rgb() colors with
3177         negative color components.
3178
3179         https://bugs.webkit.org/show_bug.cgi?id=36199
3180
3181         Covered by fast/canvas/set-colors.html.
3182
3183         * css/CSSParser.cpp:
3184         (WebCore::parseInt):
3185         (WebCore::CSSParser::parseColor):
3186         * html/canvas/CanvasStyle.cpp:
3187         (WebCore::CanvasStyle::applyFillColor):
3188
3189 2010-03-18  David Kilzer  <ddkilzer@apple.com>
3190
3191         <http://webkit.org/b/36246> Node::removeAllEventListenersSlowCase is declared but not used
3192
3193         Reviewed by Sam Weinig.
3194
3195         * dom/Node.h:
3196         (WebCore::Node::removeAllEventListenersSlowCase): Removed
3197         declaration.  Implementation was removed in r48701.
3198
3199 2010-03-17  Stephan Aßmus  <superstippi@gmx.de>
3200
3201         Reviewed by Oliver Hunt.
3202
3203         [Haiku] Implement ImageBuffer support
3204         https://bugs.webkit.org/show_bug.cgi?id=35288
3205
3206         Covered by existing tests.
3207
3208         The StillImage class implements WebCore::Image by wrapping a native
3209         BBitmap. It will be needed to implement WebCore::ImageBuffer. This
3210         solution is just like it's done in the Qt port.
3211
3212         * platform/graphics/haiku/StillImageHaiku.cpp: Added.
3213         (WebCore::StillImage::StillImage):
3214         (WebCore::StillImage::destroyDecodedData):
3215         (WebCore::StillImage::decodedSize):
3216         (WebCore::StillImage::size):
3217         (WebCore::StillImage::nativeImageForCurrentFrame):
3218         (WebCore::StillImage::draw):
3219         * platform/graphics/haiku/StillImageHaiku.h: Added.
3220         (WebCore::StillImage::create):
3221
3222 2010-03-17  Holger Hans Peter Freyther  <zecke@selfish.org>
3223
3224         Rubber stamped by Gustavo Noronha Silva.
3225
3226         [Gtk+] Avoid making a copy of the HTTPHeaderMap.
3227
3228         ResourceRequest::httpHeaderFields() is returning a const
3229         reference but we are storing it as a simple value. This
3230         means that we run either the copy constructor or the assignment
3231         operator and make a copy of the RefPtrs.
3232
3233         This extra copy can be avoided easily by storing
3234         the result as a const reference.
3235
3236         * platform/network/soup/ResourceRequestSoup.cpp:
3237         (WebCore::ResourceRequest::toSoupMessage):
3238         * platform/network/soup/ResourceResponseSoup.cpp:
3239         (WebCore::ResourceResponseSoup::toSoupMessage):
3240
3241 2010-03-17  Alexander Pavlov  <apavlov@chromium.org>
3242
3243         Reviewed by Pavel Feldman.
3244
3245         Web Inspector: When switching resources in the Resources panel, the Content tab is always selected
3246         https://bugs.webkit.org/show_bug.cgi?id=36222
3247
3248         * inspector/front-end/ResourcesPanel.js:
3249         (WebInspector.ResourcesPanel.prototype.showResource):
3250
3251 2010-03-17  Brady Eidson  <beidson@apple.com>
3252
3253         Reviewed by Darin Adler.
3254
3255         databaseIdentifiers are not filtered for slashes
3256         <rdar://problem/7708789> and https://bugs.webkit.org/show_bug.cgi?id=36243
3257
3258         In addition to filtering for '/' and '\', to remove the directory vulnerability
3259         on all platforms, it seems worth it to also escape other characters that are
3260         obviously dangerous or illegal to have in a filename (mostly inspired by the 
3261         Windows illegal-character list).
3262
3263         No new tests - It's unclear how a test could possibly work into our testing
3264         infrastructure.
3265
3266         * page/SecurityOrigin.cpp:
3267         (WebCore::): Added a 128-bool table "needsEscaping" that has a true/false answer
3268           for lower-ASCII.
3269         (WebCore::SecurityOrigin::SecurityOrigin):
3270         (WebCore::SecurityOrigin::createFromDatabaseIdentifier): "Unescape" the host
3271           component using the KURL utility.
3272         (WebCore::shouldEscapeUChar): If the char is lower-ASCII, look it up in the 
3273           needsEscaping table. Otherwise, let it pass.
3274         (WebCore::encodedHost): Modeled after KURL's host escaping method, but targeted 
3275           for the escaping considerations for the host component. We don't use the KURL
3276           version because this one is "different" enough because it operates on UTF16 and
3277           has its own "is bad character?" decider.
3278         (WebCore::SecurityOrigin::databaseIdentifier): Create the escaped host if needed,
3279           and use it instead of the unescaped host.
3280         * page/SecurityOrigin.h:
3281
3282 2010-03-17  Dmitry Titov  <dimich@chromium.org>
3283
3284         Reviewed by Dimitri Glazkov.
3285
3286         [v8] Avoid reentry into v8 after TerminateExecution() on a worker thread.
3287         https://bugs.webkit.org/show_bug.cgi?id=36239
3288
3289         Test: fast/workers/termination-with-port-messages.html
3290
3291         * bindings/v8/V8Proxy.h:
3292         (WebCore::throwError): Avoid throwing if v8 execution is terminated anyways.
3293         * bindings/v8/WorkerScriptController.h:
3294         (WebCore::WorkerScriptController::proxy): Return V8 proxy as 0 if execution is terminating. Callers to check for 0 before invoking v8.
3295         * bindings/v8/custom/V8WorkerContextCustom.cpp:
3296         (WebCore::SetTimeoutOrInterval): Bail out if v8 proxy is 0.
3297         (WebCore::toV8): Ditto
3298
3299 2010-03-17  José Millán Soto  <jmillan@igalia.com>
3300
3301         Reviewed by Adam Barth.
3302
3303         Change the way of prefetching DNS to allow prefetching function to use full URL
3304         https://bugs.webkit.org/show_bug.cgi?id=35589
3305
3306         Creates a new function, ResourceHandle::prepareForURL, whose default implementation
3307         calls prefetchDNS with the host of the given URL as the parameter.
3308         Soup implementation of ResourceHandle::prepareForURL executes soup_session_prepare_for_uri.
3309         Soup implementation of prefetchDNS is removed.
3310         Changed various prefetchDNS calls to ResourceHandle::prepareForURL calls.
3311
3312         * GNUmakefile.am:
3313         * html/HTMLAnchorElement.cpp:
3314         (WebCore::HTMLAnchorElement::parseMappedAttribute):
3315         * html/HTMLLinkElement.cpp:
3316         (WebCore::HTMLLinkElement::process):
3317         * page/Chrome.cpp:
3318         (WebCore::Chrome::mouseDidMoveOverElement):
3319         * platform/network/DNS.h:
3320         * platform/network/ResourceHandle.cpp:
3321         (WebCore::ResourceHandle::prepareForURL):
3322         * platform/network/ResourceHandle.h:
3323         * platform/network/chromium/DNSChromium.cpp:
3324         (WebCore::ResourceHandle::prepareForURL):
3325         * platform/network/soup/DNSSoup.cpp: Removed.
3326         * platform/network/soup/ResourceHandleSoup.cpp:
3327         (WebCore::ResourceHandle::prepareForURL):
3328         * wml/WMLAElement.cpp:
3329         (WebCore::WMLAElement::parseMappedAttribute):
3330
3331 2010-03-17  Kenneth Russell  <kbr@google.com>
3332
3333         Reviewed by Darin Fisher.
3334
3335         Revert WebGL context attributes changes 33416 / r56074 and 36200 / r56093
3336         https://bugs.webkit.org/show_bug.cgi?id=36233
3337
3338         The patch for bug 33416, which added multisampling support to the
3339         WebGL back buffer, uncovered some OpenGL driver bugs on the build
3340         bots which need further investigation to determine the appropriate
3341         workaround. Reverting this change, the minor build fix in 36189,
3342         and the skipping of the affected tests in bug 36200.
3343
3344         Built and tested WebKit and Chromium and ran all WebGL layout
3345         tests in both.
3346
3347         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
3348         (WebCore::V8HTMLCanvasElement::getContextCallback):
3349         * platform/graphics/GraphicsContext3D.h:
3350         * platform/graphics/mac/Canvas3DLayer.h:
3351         * platform/graphics/mac/Canvas3DLayer.mm:
3352         (-[Canvas3DLayer drawInCGLContext:pixelFormat:forLayerTime:displayTime:]):
3353         * platform/graphics/mac/GraphicsContext3DMac.cpp:
3354         (WebCore::GraphicsContext3D::GraphicsContext3D):
3355         (WebCore::GraphicsContext3D::~GraphicsContext3D):
3356         (WebCore::GraphicsContext3D::reshape):
3357         (WebCore::GraphicsContext3D::bindFramebuffer):
3358         (WebCore::GraphicsContext3D::readPixels):
3359         * platform/graphics/mac/GraphicsLayerCA.mm:
3360         (WebCore::GraphicsLayerCA::setContentsToGraphicsContext3D):
3361
3362 2010-03-17  Yael Aharon  <yael.aharon@nokia.com>
3363
3364         Reviewed by Darin Adler.
3365
3366         Optimize painting for HTMLProgressElement
3367         https://bugs.webkit.org/show_bug.cgi?id=36113
3368         Cache the progress bar's position, so it is not required to recalculate
3369         it for each repaint. 
3370         Call repaintRectangle() when the position changes.
3371
3372         No new tests, as no new functionality introduced.
3373
3374         * html/HTMLProgressElement.cpp:
3375         (WebCore::HTMLProgressElement::parseMappedAttribute):
3376         * platform/qt/RenderThemeQt.cpp:
3377         (WebCore::RenderThemeQt::getNumberOfPixelsForProgressPosition):
3378         (WebCore::RenderThemeQt::paintProgressBar):
3379         * platform/qt/RenderThemeQt.h:
3380         * rendering/RenderProgress.cpp:
3381         (WebCore::RenderProgress::RenderProgress):
3382         (WebCore::RenderProgress::updateFromElement):
3383         * rendering/RenderProgress.h:
3384         (WebCore::RenderProgress::position):
3385         * rendering/RenderTheme.cpp:
3386         (WebCore::RenderTheme::getNumberOfPixelsForProgressPosition):
3387         * rendering/RenderTheme.h:
3388
3389 2010-03-17  Antonio Gomes  <tonikitoo@webkit.org>
3390
3391         Mac Buildfix: Using ASSERT_UNUSED instead of ASSERT.
3392
3393         Reviewed by Simon fraser.
3394         Patch by Antonio Gomes <tonikitoo@webkit.org>
3395
3396         * dom/SelectElement.cpp:
3397         (WebCore::SelectElement::listBoxDefaultEventHandler):
3398
3399 2010-03-17  Enrica Casucci  <enrica@apple.com>
3400
3401         Reviewed by Darin Adler.
3402
3403         Missing support for showing compositing layers borders and repaint count on Windows.
3404         <rdar://problem/7760736>
3405         <https://bugs.webkit.org/show_bug.cgi?id=36197>
3406
3407         * platform/graphics/win/GraphicsLayerCACF.cpp:
3408         (WebCore::WebLayer::drawInContext): Modified to use the correct font on Windows.
3409
3410 2010-03-16  Luiz Agostini  <luiz.agostini@openbossa.org>
3411
3412         Reviewed by Antti Koivisto.
3413
3414         [Qt] Multiselect Popup - SelectElement refactoring.
3415         https://bugs.webkit.org/show_bug.cgi?id=36124
3416
3417         As it is today it is not possible to the menulists popups to tell SelectElement
3418         that more then one option is selected. If you select one the other ones
3419         selected state will turn off.
3420
3421         For <select multiple> I needed to extend the API used by menulist popups. This
3422         is the first step. Just refactoring SelectElement without any behavior change.
3423         Separating code that will be reused in future patches.
3424
3425         * dom/SelectElement.cpp:
3426         (WebCore::SelectElement::updateSelectedState):
3427         (WebCore::SelectElement::listBoxDefaultEventHandler):
3428         * dom/SelectElement.h:
3429
3430 2010-03-17  Nate Chapin  <japhet@chromium.org>
3431
3432         Unreviewed, Chromium build fix.
3433
3434         Delete the correct file this time.
3435
3436         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp: Copied from WebCore/bindings/v8/custom/V8XMLHttpRequestCustom.cpp.
3437         * bindings/v8/custom/V8XMLHttpRequestUploadCustom.cpp: Removed.
3438
3439 2010-03-17  Nate Chapin  <japhet@chromium.org>
3440
3441         Reviewed by Dimitri Glazkov.
3442
3443         [V8] Remove custom bindings callbacks that aren't in use.
3444         (The relevant .idl doesn't mark them as V8Custom or Custom).
3445         
3446         https://bugs.webkit.org/show_bug.cgi?id=33066
3447
3448         * Android.v8bindings.mk:
3449         * WebCore.gypi:
3450         * bindings/scripts/CodeGeneratorV8.pm:
3451         * bindings/v8/custom/V8DOMWindowCustom.cpp:
3452         * bindings/v8/custom/V8WebGLArrayCustom.h:
3453         * bindings/v8/custom/V8WebGLByteArrayCustom.cpp:
3454         * bindings/v8/custom/V8WebGLFloatArrayCustom.cpp:
3455         * bindings/v8/custom/V8WebGLIntArrayCustom.cpp:
3456         * bindings/v8/custom/V8WebGLShortArrayCustom.cpp:
3457         * bindings/v8/custom/V8WebGLUnsignedByteArrayCustom.cpp:
3458         * bindings/v8/custom/V8WebGLUnsignedIntArrayCustom.cpp:
3459         * bindings/v8/custom/V8WebGLUnsignedShortArrayCustom.cpp:
3460         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
3461         * bindings/v8/custom/V8XMLHttpRequestUploadCustom.cpp: Removed.
3462
3463 2010-03-17  Steve Block  <steveblock@google.com>
3464
3465         Reviewed by Dimitri Glazkov.
3466
3467         Adds ENABLE(WORKERS) guards to V8 bindings
3468         https://bugs.webkit.org/show_bug.cgi?id=36221
3469
3470         Build fix only, no new tests.
3471
3472         * bindings/v8/V8DOMWrapper.cpp:
3473         (WebCore::V8DOMWrapper::instantiateV8Object):
3474         * bindings/v8/V8Proxy.cpp:
3475         (WebCore::toV8Context):
3476
3477 2010-03-17  Yury Semikhatsky  <yurys@chromium.org>
3478
3479         Reviewed by Pavel Feldman.
3480
3481         Remove unused reference to InspectorController from InspectorFrontend.
3482
3483         https://bugs.webkit.org/show_bug.cgi?id=36218
3484
3485         * inspector/InspectorFrontend.h:
3486
3487 2010-03-17 Ilya Tikhonovsky  <loislo@chromium.org>
3488
3489         Reviewed by Pavel Feldman.
3490
3491         WebInspector: Timeline improvements - next iteration.
3492
3493         The top level records should be collapsed.
3494         Virtually linked events should be nested in Timeline like Send Request and
3495         corresponding Received Responce, Timer Install and Timer Fire etc.
3496         It should be possible to see Main Resource request.
3497
3498         https://bugs.webkit.org/show_bug.cgi?id=36122
3499
3500         * inspector/InspectorController.cpp:
3501         (WebCore::InspectorController::resetScriptObjects):
3502         (WebCore::InspectorController::didReceiveResponse):
3503         * inspector/InspectorTimelineAgent.cpp:
3504         (WebCore::InspectorTimelineAgent::willReceiveResourceResponse):
3505         (WebCore::InspectorTimelineAgent::didReceiveResourceResponse):
3506         * inspector/InspectorTimelineAgent.h:
3507         * inspector/front-end/TimelinePanel.js:
3508         (WebInspector.TimelinePanel):
3509         (WebInspector.TimelinePanel.prototype._createStatusbarButtons):
3510         (WebInspector.TimelinePanel.prototype.addRecordToTimeline):
3511         (WebInspector.TimelinePanel.prototype._findParentRecord):
3512         (WebInspector.TimelinePanel.prototype._innerAddRecordToTimeline):
3513         (WebInspector.TimelinePanel.prototype.resize):
3514         (WebInspector.TimelinePanel.prototype._createTopLevelRecord):
3515         (WebInspector.TimelinePanel.prototype.reset):
3516         (WebInspector.TimelinePanel.prototype._clean):
3517         (WebInspector.TimelinePanel.prototype._refresh):
3518         (WebInspector.TimelinePanel.prototype._refreshRecords):
3519         (WebInspector.TimelinePanel.prototype._addToRecordsWindow):
3520         (WebInspector.TimelineCalculator.prototype.computeBarGraphPercentages):
3521         (WebInspector.TimelineCalculator.prototype.updateBoundaries):
3522         (WebInspector.TimelineRecordGraphRow):
3523         (WebInspector.TimelineRecordGraphRow.prototype.update):
3524         (WebInspector.TimelinePanel.FormattedRecord):
3525         (WebInspector.TimelinePanel.FormattedRecord.prototype.get children):
3526         (WebInspector.TimelinePanel.FormattedRecord.prototype._generatePopupContent):
3527         * inspector/front-end/inspector.css:
3528         * loader/ResourceLoader.cpp:
3529         (WebCore::ResourceLoader::didReceiveResponse):
3530
3531 2010-03-17  Alexander Pavlov  <apavlov@chromium.org>
3532
3533         Reviewed by Pavel Feldman.
3534
3535         Web Inspector: Reimplement style-related audits using native API
3536         https://bugs.webkit.org/show_bug.cgi?id=36172
3537
3538         * inspector/InspectorBackend.cpp:
3539         (WebCore::InspectorBackend::getAllStyles):
3540         * inspector/InspectorBackend.h:
3541         * inspector/InspectorBackend.idl:
3542         * inspector/InspectorDOMAgent.cpp:
3543         (WebCore::InspectorDOMAgent::getAllStyles):
3544         (WebCore::InspectorDOMAgent::getMatchedCSSRules):
3545         (WebCore::InspectorDOMAgent::buildObjectForStyleSheet):
3546         (WebCore::InspectorDOMAgent::buildObjectForRule):
3547         * inspector/InspectorDOMAgent.h:
3548         * inspector/InspectorFrontend.cpp:
3549         (WebCore::InspectorFrontend::didGetAllStyles):
3550         * inspector/InspectorFrontend.h:
3551         * inspector/front-end/AuditRules.js:
3552         (WebInspector.AuditRules.evaluateInTargetWindow):
3553         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.evalCallback.selectorsCallback):
3554         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.evalCallback.routine):
3555         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.evalCallback):
3556         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.routine):
3557         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun):
3558         (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun):
3559         (WebInspector.AuditRules.CssInHeadRule.prototype.doRun):
3560         (WebInspector.AuditRules.StylesScriptsOrderRule.prototype.doRun):
3561         * inspector/front-end/DOMAgent.js:
3562         * inspector/front-end/InjectedScript.js:
3563         (injectedScriptConstructor):
3564
3565 2010-03-17  Steve Block  <steveblock@google.com>
3566
3567         Reviewed by Jeremy Orlow.
3568
3569         Replace instances of bzero in WebCore/bridge common code with memset
3570         https://bugs.webkit.org/show_bug.cgi?id=36214
3571
3572         Syntax change only, no new tests.
3573
3574         * bridge/jni/JNIUtility.cpp:
3575         (JSC::Bindings::getJNIField):
3576         * bridge/jni/jsc/JNIBridgeJSC.cpp:
3577         (JavaField::dispatchValueFromInstance):
3578         * bridge/jni/jsc/JNIUtilityPrivate.cpp:
3579         (JSC::Bindings::convertValueToJValue):
3580         * bridge/jni/v8/JNIUtilityPrivate.cpp:
3581         (JSC::Bindings::convertNPVariantToJValue):
3582         * bridge/jni/v8/JavaNPObjectV8.cpp:
3583         (JSC::Bindings::AllocJavaNPObject):
3584
3585 2010-03-17  Yury Semikhatsky  <yurys@chromium.org>
3586
3587         Reviewed by Pavel Feldman.
3588
3589         Mark inspector resources as changed so that they are reloaded on the next frontend connection.
3590         
3591         Split resetScriptObjects into code specific for page navigation and insepctor frontend disconnection.
3592
3593         https://bugs.webkit.org/show_bug.cgi?id=36183
3594
3595         * WebCore.xcodeproj/project.pbxproj: Added InspectorWorkerResource.h to the project file.
3596         * inspector/InspectorController.cpp:
3597         (WebCore::InspectorController::disconnectFrontend):
3598         (WebCore::InspectorController::unbindAllResources):
3599         (WebCore::InspectorController::didCommitLoad):
3600         * inspector/InspectorController.h:
3601         * inspector/InspectorResource.cpp:
3602         (WebCore::InspectorResource::releaseScriptObject):
3603
3604 2010-03-17  Pavel Feldman  <pfeldman@chromium.org>
3605
3606         Reviewed by Timothy Hatcher.
3607
3608         Web Inspector: Capture main resource load events in timeline panel.
3609
3610         https://bugs.webkit.org/show_bug.cgi?id=36188
3611
3612         * inspector/front-end/TimelinePanel.js:
3613         (WebInspector.TimelinePanel.prototype._createStatusbarButtons):
3614         (WebInspector.TimelinePanel.prototype._toggleTimelineButtonClicked):
3615         (WebInspector.TimelinePanel.prototype.timelineWasStopped):
3616         (WebInspector.TimelinePanel.prototype.addRecordToTimeline):
3617         (WebInspector.TimelinePanel.prototype._clearPanel):
3618         (WebInspector.TimelinePanel.FormattedRecord):
3619
3620 2010-03-17  Zoltan Horvath  <zoltan@webkit.org>
3621
3622       &