67ba54e1f6ae0d7a43deeff4e8daa4fb66576d9d
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-06-27  Ryosuke Niwa  <rniwa@webkit.org>
2
3         Reviewed by Kent Tamura.
4
5         Crash in TextIterator
6         https://bugs.webkit.org/show_bug.cgi?id=63334
7
8         Fix a crash in TextIterator. Keep m_sortedTextBoxes and renderer consistent
9         and check !m_offset when handling first letter.
10
11         Also add more assertions to help detecting similar bugs.
12
13         Test: editing/text-iterator/first-letter-rtl-crash.html
14
15         * editing/TextIterator.cpp:
16         (WebCore::TextIterator::handleTextNode):
17         (WebCore::TextIterator::emitText):
18
19 2011-06-27  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
20
21         Reviewed by Andreas Kling.
22
23         [Qt] tst_QWebFrame::overloadedSlots() fails
24         https://bugs.webkit.org/show_bug.cgi?id=37319
25
26         This patch is based on Noam Rosenthal original patch in the same bug.
27
28         When hinted with QWebElement metatype, we qualify the conversion
29         from JSElement as a "perfect match".
30
31         The test was failing because the wrong slot was called, since the QWebElement
32         match was taken as equal to the others and not chosen when the metacall happened.
33
34         * bridge/qt/qt_runtime.cpp:
35         (JSC::Bindings::convertValueToQVariant): Identify the conversion between JSElement
36         to QWebElement as a "perfect match" (dist = 0). Add comments to explain the reason
37         why we have the implicit conversion.
38
39 2011-06-27  ChangSeok Oh  <shivamidow@gmail.com>
40
41         Reviewed by Martin Robinson.
42
43         [GTK] Fix build break to support webgl
44         https://bugs.webkit.org/show_bug.cgi?id=63425
45
46         Some missing files in ANGLE are just added to fix build-break.
47
48         No test reqired
49
50         * GNUmakefile.list.am:
51
52 2011-06-27  Hyowon Kim  <hw1008.kim@samsung.com>
53
54         Reviewed by Martin Robinson.
55
56         [EFL] Add some PLATFORM(EFL) ifdefs to GraphicsContext3D.h
57         https://bugs.webkit.org/show_bug.cgi?id=62959
58
59         Add PLATFORM(EFL) ifdefs to use GraphicsContextInternal.
60
61         * platform/graphics/GraphicsContext3D.h:
62
63 2011-06-27  Alexandru Chiculita  <achicu@adobe.com>
64
65         Reviewed by Ojan Vafai.
66
67         css combinator "+" in combination with NAV tag is buggy
68         https://bugs.webkit.org/show_bug.cgi?id=47971
69
70         Added a new state in css/tokenizer.flex for the "nth" rule. The state begins
71         at nth-*( functions and ends at the first ")". It avoids parsing selectors 
72         like "#div+nav" as: "#div" "+n" "av".
73
74         Test: fast/css/div_plus_nav_bug47971.html
75
76         * css/maketokenizer:
77         * css/tokenizer.flex:
78
79 2011-06-27  Sheriff Bot  <webkit.review.bot@gmail.com>
80
81         Unreviewed, rolling out r89822.
82         http://trac.webkit.org/changeset/89822
83         https://bugs.webkit.org/show_bug.cgi?id=63461
84
85         Broken builds (Requested by apavlov on #webkit).
86
87         * inspector/Inspector.json:
88         * inspector/InspectorCSSAgent.cpp:
89         (WebCore::InspectorCSSAgent::getStylesForNode):
90         * inspector/InspectorCSSAgent.h:
91         * inspector/front-end/AuditRules.js:
92         (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun.getStyles):
93         * inspector/front-end/CSSStyleModel.js:
94         (WebInspector.CSSStyleModel.prototype.getStylesAsync):
95         * inspector/front-end/StylesSidebarPane.js:
96         (WebInspector.StylesSidebarPane.prototype.update):
97
98 2011-06-27  Noel Gordon  <noel.gordon@gmail.com>
99
100         Reviewed by Adam Roben.
101
102         Send keypress events to windowless plugins on the windows port.
103         https://bugs.webkit.org/show_bug.cgi?id=63144
104
105         No new tests.  Covered by existing windowless plugin tests plugins/mouse-events.html
106         and plugins/keyboard-events.html.  Both are not yet working as desired because focus
107         events are not being fowarded to windowed plugins on the win port (bug 62375).  Test
108         plugin logging on the win port was added in bug 61721.  New failing expectations for
109         plugins/keyboard-events.html were subsequently added in bug 33973 so there's no need
110         to update test expectations in this patch.
111
112          * plugins/win/PluginViewWin.cpp:
113         (WebCore::PluginView::handleKeyboardEvent): Add an ASSERT(m_plugin && !m_isWindowed)
114         to indicate that the routine is for windowless plugins.  Remove trailing whitespace.
115         Add handling for keyPress events (map to WM_CHAR).
116         (WebCore::PluginView::handleMouseEvent): Add the ASSERT to indicate that the routine
117         is for windowless plugins.  Add FIXME note.  Remove trailing whitespace.
118
119 2011-06-27  Alexander Pavlov  <apavlov@chromium.org>
120
121         Reviewed by Pavel Feldman.
122
123         Web Inspector: Change the inspector model API and backend to allow CSS pseudoclass inspection
124         https://bugs.webkit.org/show_bug.cgi?id=63446
125
126         * inspector/Inspector.json:
127         * inspector/InspectorCSSAgent.cpp:
128         (WebCore::computePseudoClassMask):
129         (WebCore::InspectorCSSAgent::getStylesForNode):
130         * inspector/InspectorCSSAgent.h:
131         * inspector/front-end/AuditRules.js:
132         (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun.getStyles):
133         * inspector/front-end/CSSStyleModel.js:
134         (WebInspector.CSSStyleModel.prototype.getStylesAsync):
135         * inspector/front-end/StylesSidebarPane.js:
136         (WebInspector.StylesSidebarPane.prototype.update):
137
138 2011-06-27  Pavel Feldman  <pfeldman@google.com>
139
140         Reviewed by Yury Semikhatsky.
141
142         Web Inspector: [REGRESSION r84481] updateLayout called from DrawNodeHighlight
143         https://bugs.webkit.org/show_bug.cgi?id=63405
144
145         We should not call layout from paint.
146
147         * inspector/DOMNodeHighlighter.cpp:
148         (WebCore::DOMNodeHighlighter::drawNodeHighlight):
149         * inspector/DOMNodeHighlighter.h:
150         * inspector/InspectorDOMAgent.cpp:
151         (WebCore::InspectorDOMAgent::drawNodeHighlight):
152
153 2011-06-27  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
154
155         Unreviewed. Fix style error in EFL port.
156
157         * platform/efl/PlatformKeyboardEventEfl.cpp:
158         * platform/efl/PlatformScreenEfl.cpp:
159         * platform/efl/SharedBufferEfl.cpp:
160
161 2011-06-27  Pavel Feldman  <pfeldman@google.com>
162
163         Reviewed by Yury Semikhatsky.
164
165         Web Inspector: node selection is slow in the Elements panel.
166         https://bugs.webkit.org/show_bug.cgi?id=60813
167
168         * inspector/front-end/StylesSidebarPane.js:
169         (WebInspector.StylesSidebarPane.prototype.update.stylesCallback):
170         (WebInspector.StylesSidebarPane.prototype.update.computedStyleCallback):
171         (WebInspector.StylesSidebarPane.prototype.update):
172
173 2011-06-26  Pavel Feldman  <pfeldman@chromium.org>
174
175         Reviewed by Yury Semikhatsky.
176
177         Web Inspector: roll out r88337 for making tests flaky.
178         https://bugs.webkit.org/show_bug.cgi?id=63422
179
180         * inspector/front-end/ElementsPanel.js:
181         (WebInspector.ElementsPanel):
182         (WebInspector.ElementsPanel.prototype.updateStyles):
183         (WebInspector.ElementsPanel.prototype._stylesUpdated):
184         * inspector/front-end/StylesSidebarPane.js:
185         (WebInspector.StylesSidebarPane.prototype.update.stylesCallback):
186         (WebInspector.StylesSidebarPane.prototype.update.computedStyleCallback):
187         (WebInspector.StylesSidebarPane.prototype.update):
188
189 2011-06-27  Huang Dongsung  <luxtella@company100.net>
190
191         Reviewed by Kenneth Rohde Christiansen.
192
193         TiledBackingStore endlessly creates and destroys tiles due to an off-by-one
194         error.
195         https://bugs.webkit.org/show_bug.cgi?id=62422
196
197         REGRESSION(r77286): Remove bottomRight().
198         REGRESSION(r77312): Change the logic to get the bottom right point.
199         REGRESSION(r77928): Cause off-by-one error in TiledBackingStore.
200         REGRESSION(r78783): Cause off-by-one error in TiledDrawingAreaProxy.
201         REGRESSION(r78785): Cause off-by-one error in TiledDrawingAreaProxy.
202
203         If the viewport width equals the contents width, especially in the mobile
204         device, TiledBackingStore endlessly creates and deletes the rightmost
205         column and bottom row of tiles.
206         In the detail, dropTilesOutsideRect() in TiledBackingStore::createTiles()
207         deletes tiles and setTile(coordinate, Tile::create(this, coordinate)) creates
208         tiles infinitely.
209         Modified TiledDrawingAreaProxy also.
210
211         * platform/graphics/TiledBackingStore.cpp:
212         (WebCore::innerBottomRight):
213         (WebCore::TiledBackingStore::invalidate):
214         (WebCore::TiledBackingStore::paint):
215         (WebCore::TiledBackingStore::createTiles):
216
217 2011-06-26  Adam Barth  <abarth@webkit.org>
218
219         Reviewed by Eric Seidel.
220
221         Remove LegacyDefaultOptionalArguments from WebAudio IDL files
222         https://bugs.webkit.org/show_bug.cgi?id=63416
223
224         WebAudio isn't that widely used, so it's seems somewhat safe to remove
225         legacy code generation hacks.  I'm not an expert on WebAudio, but the
226         API doesn't appear to need many optional arguments.
227
228         There are a bunch of APIs that have custom bindings that look like they
229         could be autogenerated.  I've added FIXME comments where appropriate.
230
231         * webaudio/AudioBuffer.idl:
232         * webaudio/AudioContext.idl:
233         * webaudio/AudioListener.idl:
234         * webaudio/AudioNode.idl:
235         * webaudio/AudioPannerNode.idl:
236         * webaudio/AudioParam.idl:
237         * webaudio/RealtimeAnalyserNode.idl:
238
239 2011-06-26  Yury Semikhatsky  <yurys@chromium.org>
240
241         Reviewed by Pavel Feldman.
242
243         Web Inspector: REGRESSION Scripts panel sidebar pane context menu has no "Remove breakpoint" item
244         https://bugs.webkit.org/show_bug.cgi?id=63421
245
246         Show generic sidebar menu only if no pane-specific menu has been shown.
247
248         * inspector/front-end/ScriptsPanel.js:
249         (WebInspector.ScriptsPanel):
250
251 2011-06-26  Adam Barth  <abarth@webkit.org>
252
253         Build fix for clang.  Apparently clang doesn't want us to use the std
254         namespace in headers, which makes sense.
255
256         * svg/SVGAnimatedType.h:
257
258 2011-06-26  Adam Barth  <abarth@webkit.org>
259
260         Reviewed by Eric Seidel.
261
262         Remove LegacyDefaultOptionalArguments from XMLHttpRequest.idl and XMLHttpRequestUpload.idl
263         https://bugs.webkit.org/show_bug.cgi?id=63418
264
265         The XMLHttpRequest.idl interface used to implement the new behavior
266         manually using the RequiresAllArguments attribute.  Now that we have
267         that behavior by default, we can simply remove the
268         LegacyDefaultOptionalArguments attribute.
269
270         * xml/XMLHttpRequest.idl:
271         * xml/XMLHttpRequestUpload.idl:
272
273 2011-06-26  Dirk Schulze  <krit@webkit.org>
274
275         Reviewed by Nikolas Zimmermann.
276
277         SVGAnimatedType should support SVGLengthList animation
278         https://bugs.webkit.org/show_bug.cgi?id=63399
279
280         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
281         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGAnimatedLengthList.
282         
283         Interpolated animations of glyph positions are possible now.
284
285         Tests: svg/animations/svglengthlist-animation-1.html
286                svg/animations/svglengthlist-animation-2.html
287                svg/animations/svglengthlist-animation-3.html
288                svg/animations/svglengthlist-animation-4.html
289
290         * CMakeLists.txt: Add new file to build system.
291         * GNUmakefile.list.am: Ditto.
292         * WebCore.gypi: Ditto.
293         * WebCore.pro: Ditto.
294         * WebCore.xcodeproj/project.pbxproj: Ditto.
295         * svg/SVGAllInOne.cpp: Ditto.
296         * svg/SVGAnimateElement.cpp: Make use of AnimatedLengthList.
297         (WebCore::SVGAnimateElement::determineAnimatedAttributeType):
298         (WebCore::SVGAnimateElement::calculateAnimatedValue):
299         (WebCore::SVGAnimateElement::calculateFromAndToValues):
300         (WebCore::SVGAnimateElement::calculateFromAndByValues):
301         (WebCore::SVGAnimateElement::resetToBaseValue):
302         (WebCore::SVGAnimateElement::applyResultsToTarget):
303         (WebCore::SVGAnimateElement::calculateDistance):
304         * svg/SVGAnimatedLengthList.cpp: Added. New animator for SVGLengthList.
305         (WebCore::SVGAnimatedLengthListAnimator::SVGAnimatedLengthListAnimator):
306         (WebCore::SVGAnimatedLengthListAnimator::constructFromString):
307         (WebCore::SVGAnimatedLengthListAnimator::calculateFromAndToValues):
308         (WebCore::SVGAnimatedLengthListAnimator::calculateFromAndByValues):
309         (WebCore::SVGAnimatedLengthListAnimator::calculateAnimatedValue):
310         (WebCore::SVGAnimatedLengthListAnimator::calculateDistance):
311         * svg/SVGAnimatedLengthList.h:
312         (WebCore::SVGAnimatedLengthListAnimator::~SVGAnimatedLengthListAnimator):
313         * svg/SVGAnimatedType.cpp: Add SVGLengthList.
314         (WebCore::SVGAnimatedType::~SVGAnimatedType):
315         (WebCore::SVGAnimatedType::createLengthList):
316         (WebCore::SVGAnimatedType::lengthList):
317         (WebCore::SVGAnimatedType::valueAsString):
318         (WebCore::SVGAnimatedType::setValueAsString):
319         * svg/SVGAnimatedType.h:
320         * svg/SVGAnimatorFactory.h:
321         (WebCore::SVGAnimatorFactory::create):
322         * svg/SVGLength.cpp: Add new constructor with LengthType, LengthMode and value.
323         (WebCore::SVGLength::SVGLength):
324         * svg/SVGLength.h:
325
326 2011-06-26  Adam Barth  <abarth@webkit.org>
327
328         Reviewed by Eric Seidel.
329
330         window.location should use the holder's prototype chain
331         https://bugs.webkit.org/show_bug.cgi?id=63411
332
333         This patch corrects the prototype chain for Location, but we really
334         should do a complete cleanup of the prototype chain generation, like we
335         did for JavaScriptCore.
336
337         Test: http/tests/security/location-prototype.html
338
339         * bindings/scripts/CodeGeneratorV8.pm:
340
341 2011-06-26  Adam Barth  <abarth@webkit.org>
342
343         Reviewed by Eric Seidel.
344
345         Add [Optional] attributes where appropriate for addEventListener and removeEventListener
346         https://bugs.webkit.org/show_bug.cgi?id=63417
347
348         This patch doesn't actually change behavior because these interfaces
349         have the LegacyDefaultOptionalArguments attribute.  This patch paves
350         the way to removing LegacyDefaultOptionalArguments from some of these
351         interfaces as well as making the project safer for copy-and-pasting
352         these methods into new IDL files that don't have the
353         LegacyDefaultOptionalArguments attribute.
354
355         * bindings/scripts/test/TestObj.idl:
356         * dom/EventTarget.idl:
357         * dom/MediaStream.idl:
358         * dom/MessagePort.idl:
359         * dom/Node.idl:
360         * loader/appcache/DOMApplicationCache.idl:
361         * notifications/Notification.idl:
362         * page/DOMWindow.idl:
363         * page/EventSource.idl:
364         * storage/IDBRequest.idl:
365         * storage/IDBTransaction.idl:
366         * svg/SVGElementInstance.idl:
367         * websockets/WebSocket.idl:
368         * workers/AbstractWorker.idl:
369         * workers/WorkerContext.idl:
370         * xml/XMLHttpRequest.idl:
371         * xml/XMLHttpRequestUpload.idl:
372
373 2011-06-26  Adam Barth  <abarth@webkit.org>
374
375         Reviewed by Kent Tamura.
376
377         m_formElementsWithFormAttribute doesn't ref the objects it holds
378         https://bugs.webkit.org/show_bug.cgi?id=62956
379
380         Test: fast/forms/form-associated-element-crash3.html
381
382         * dom/Document.h:
383
384 2011-06-26  Dimitri Glazkov  <dglazkov@chromium.org>
385
386         Reviewed by Adam Barth.
387
388         FileList::filenames should be FileList::paths, because it's more accurate.
389         https://bugs.webkit.org/show_bug.cgi?id=63414
390
391         Refactoring, no change in behavior.
392
393         * fileapi/FileList.cpp:
394         (WebCore::FileList::paths): Renamed from filenames.
395         * fileapi/FileList.h:
396         * html/FileInputType.cpp:
397         (WebCore::FileInputType::handleDOMActivateEvent): Changed to use filenames, also fixed a reach-unto-thyself whoopsie.
398         (WebCore::FileInputType::requestIcon): Ditto.
399         (WebCore::FileInputType::filesChosen): Ditto.
400         * rendering/RenderFileUploadControl.cpp:
401         (WebCore::RenderFileUploadControl::fileTextValue): Ditto.
402
403 2011-06-26  Young Han Lee  <joybro@company100.net>
404
405         Reviewed by Dirk Schulze.
406
407         SVGAnimation - keyTime value 1 never get animated
408         https://bugs.webkit.org/show_bug.cgi?id=63230
409
410         According to the SMIL 3.0 specification, the index of the keyTimes should be 
411         determined under the end-point-exclusive rule (e.g. Given keyTimes(0;0.5;1) 
412         and t=0.5, the current index of the keyTimes have to be 1 not 0).
413         http://www.w3.org/TR/SMIL3/smil-animation.html#animationNS-InterpolationExamplesAdvanced
414
415         Test: svg/animations/animate-number-calcMode-discrete-keyTimes.html
416
417         * svg/SVGAnimationElement.cpp:
418         (WebCore::SVGAnimationElement::calculateKeyTimesIndex):
419
420 2011-06-26  Dan Bernstein  <mitz@apple.com>
421
422         Reviewed by Darin Adler.
423
424         With word-break: break-all, words do not break correctly before a surrogate pair
425         https://bugs.webkit.org/show_bug.cgi?id=63401
426
427         The code to check for mid-word breaks accumulates width one character at a time. It was actually
428         measuring the two parts of the surrogate pair individually, so they appeared to have zero width.
429         Fixed by checking for surrogate pairs and measuring the pair as one unit.
430
431         Test: fast/text/midword-break-before-surrogate-pair.html
432
433         * rendering/RenderBlockLineLayout.cpp:
434         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
435
436 2011-06-26  Dirk Schulze  <krit@webkit.org>
437
438         Reviewed by Nikolas Zimmermann.
439
440         SVGAnimatedType should support SVGNumberOptionalNumber animation
441         https://bugs.webkit.org/show_bug.cgi?id=63397
442         
443         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
444         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGAnimatedNumberOptionalNumber.
445         
446         Animations of attributes with type SVGAnimatedNumberOptionalNumber can be interpolated now. This can be used for smooth
447         growing shadows with feGaussianBlur, feDropShadow or other filter effects.
448
449         Tests: svg/animations/svgnumberoptionalnumber-animation-1.html
450                svg/animations/svgnumberoptionalnumber-animation-2.html
451                svg/animations/svgnumberoptionalnumber-animation-3.html
452                svg/animations/svgnumberoptionalnumber-animation-4.html
453
454         * CMakeLists.txt: Added new files to build system.
455         * GNUmakefile.list.am: Ditto.
456         * WebCore.gypi: Ditto.
457         * WebCore.pro: Ditto.
458         * WebCore.vcproj/WebCore.vcproj: Ditto.
459         * WebCore.xcodeproj/project.pbxproj: Ditto.
460         * svg/SVGAllInOne.cpp: Ditto.
461         * svg/SVGAnimateElement.cpp: Make use of attribute type AnimatedNumberOptionalNumber.
462         (WebCore::SVGAnimateElement::determineAnimatedAttributeType):
463         (WebCore::SVGAnimateElement::calculateAnimatedValue):
464         (WebCore::SVGAnimateElement::calculateFromAndToValues):
465         (WebCore::SVGAnimateElement::calculateFromAndByValues):
466         (WebCore::SVGAnimateElement::resetToBaseValue):
467         (WebCore::SVGAnimateElement::applyResultsToTarget):
468         (WebCore::SVGAnimateElement::calculateDistance):
469         * svg/SVGAnimatedNumberOptionalNumber.cpp: Added. New animator for SVGAnimatedNumberOptionalNumber.
470         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::SVGAnimatedNumberOptionalNumberAnimator):
471         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::constructFromString):
472         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateFromAndToValues):
473         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateFromAndByValues):
474         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateAnimatedValue):
475         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::calculateDistance):
476         * svg/SVGAnimatedNumberOptionalNumber.h: Added.
477         (WebCore::SVGAnimatedNumberOptionalNumberAnimator::~SVGAnimatedNumberOptionalNumberAnimator):
478         * svg/SVGAnimatedType.cpp: Added new type: pair<float, float>.
479         (WebCore::SVGAnimatedType::~SVGAnimatedType):
480         (WebCore::SVGAnimatedType::createNumberOptionalNumber):
481         (WebCore::SVGAnimatedType::numberOptionalNumber):
482         (WebCore::SVGAnimatedType::valueAsString):
483         (WebCore::SVGAnimatedType::setValueAsString):
484         * svg/SVGAnimatedType.h:
485         * svg/SVGAnimatorFactory.h: Add new animator to factory.
486         (WebCore::SVGAnimatorFactory::create):
487
488 2011-06-25  Dimitri Glazkov  <dglazkov@chromium.org>
489
490         Reviewed by Adam Barth.
491
492         Crash in frameless document with media element.
493         https://bugs.webkit.org/show_bug.cgi?id=63393
494
495         Since MediaControls::create can return 0 (and does for frameless documents), we must anticipate it
496         in the calling code.
497
498         Test: fast/dom/shadow/frameless-media-element-crash.html
499
500         * html/HTMLMediaElement.cpp:
501         (WebCore::HTMLMediaElement::attributeChanged): Changed to bail out if controls weren't successfully created.
502         (WebCore::HTMLMediaElement::createMediaControls): Renamed to better reflect the purpose, changed to handle failure of creation.
503         (WebCore::HTMLMediaElement::preDispatchEventHandler): Changed to bail out if controls weren't successfully created.
504         * html/HTMLMediaElement.h: Adjusted def.
505
506 2011-06-25  Joseph Pecoraro  <joepeck@webkit.org>
507
508         Reviewed by Darin Adler.
509
510         Fix some minor style issues
511         https://bugs.webkit.org/show_bug.cgi?id=63391
512
513         * inspector/DOMNodeHighlighter.cpp:
514         (WebCore::DOMNodeHighlighter::DrawNodeHighlight):
515         The explicit WebCore namespace usage can be dropped.
516
517         * rendering/RenderView.cpp:
518         (WebCore::RenderView::mapLocalToContainer):
519         Use ASSERT_UNUSED for a parameter that we want to ASSERT
520         on for a debug build, but is UNUSED in a release build.
521
522 2011-06-25  Joseph Pecoraro  <joepeck@webkit.org>
523
524         Unreviewed build fix.
525
526         Use UNUSED_PARAM on the correct param!
527
528         * rendering/RenderView.cpp:
529         (WebCore::RenderView::mapLocalToContainer):
530
531 2011-06-25  Joseph Pecoraro  <joepeck@webkit.org>
532
533         Reviewed by Simon Fraser.
534
535         Inspector highlight rect is wrong for contents of transformed iframes
536         https://bugs.webkit.org/show_bug.cgi?id=53627
537
538         Part 2: Only adjust for the FrameView's scroll position when
539         the localToAbsolute mapping did not end with fixed content.
540         Content that is inside of a fixed position container is already
541         adjusted for the FrameView's scrollPosition when RenderView
542         maps local to container.
543
544         This patch uses a "wasFixed" out parameter to determine if
545         the localToAbsolute transformation ended inside a fixed block,
546         and if so does not apply the scroll position.
547
548         * page/FrameView.cpp:
549         (WebCore::FrameView::convertFromRenderer):
550         Respect wasFixed as described above.
551
552         * rendering/RenderBox.h:
553         * rendering/RenderBox.cpp:
554         (WebCore::RenderBox::mapLocalToContainer):
555         This is the only time that "fixed" ever changed. So when
556         fixed changes, update the optional wasFixed out parameter.
557
558         * rendering/RenderObject.cpp:
559         (WebCore::RenderObject::localToAbsolute):
560         (WebCore::RenderObject::mapLocalToContainer):
561         (WebCore::RenderObject::localToContainerQuad):
562         * rendering/RenderObject.h:
563         (WebCore::RenderObject::localToAbsoluteQuad):
564         Ignore wasFixed by default, but pipe it though where needed.
565
566         * rendering/RenderView.h:
567         * rendering/RenderView.cpp:
568         (WebCore::RenderView::mapLocalToContainer):
569         This is the final recursive call, so wasFixed goes no
570         further. We sanity check its value in debug builds.
571
572         * rendering/RenderBlock.cpp:
573         (WebCore::RenderBlock::selectionGapRectsForRepaint):
574         * rendering/RenderInline.cpp:
575         (WebCore::RenderInline::mapLocalToContainer):
576         * rendering/RenderInline.h:
577         * rendering/svg/RenderSVGForeignObject.cpp:
578         (WebCore::RenderSVGForeignObject::mapLocalToContainer):
579         * rendering/svg/RenderSVGForeignObject.h:
580         * rendering/svg/RenderSVGInline.cpp:
581         (WebCore::RenderSVGInline::mapLocalToContainer):
582         * rendering/svg/RenderSVGInline.h:
583         * rendering/svg/RenderSVGModelObject.cpp:
584         (WebCore::RenderSVGModelObject::mapLocalToContainer):
585         * rendering/svg/RenderSVGModelObject.h:
586         * rendering/svg/RenderSVGRoot.cpp:
587         (WebCore::RenderSVGRoot::mapLocalToContainer):
588         * rendering/svg/RenderSVGRoot.h:
589         * rendering/svg/RenderSVGText.cpp:
590         (WebCore::RenderSVGText::mapLocalToContainer):
591         * rendering/svg/RenderSVGText.h:
592         * rendering/svg/SVGRenderSupport.cpp:
593         (WebCore::SVGRenderSupport::mapLocalToContainer):
594         * rendering/svg/SVGRenderSupport.h:
595         Pipe wasFixed through where needed.
596
597 2011-06-25  Joseph Pecoraro  <joepeck@webkit.org>
598
599         Reviewed by Simon Fraser.
600
601         Inspector highlight rect is wrong for contents of transformed iframes
602         https://bugs.webkit.org/show_bug.cgi?id=53627
603
604         Part 1: Provide FloatQuad versions of convertFromRenderer,
605         convertToContainingView, and convertChildToSelf, so that we
606         can get the fully transformed quad of a renderer all the
607         way up to the root widget.
608
609         * page/FrameView.cpp:
610         (WebCore::FrameView::convertFromRenderer):
611         (WebCore::FrameView::convertToContainingView):
612         * page/FrameView.h:
613         * platform/ScrollView.h:
614         (WebCore::ScrollView::convertChildToSelf):
615         * platform/Widget.h:
616         * platform/Widget.cpp:
617         (WebCore::Widget::convertToContainingView):
618         Provide FloatQuad versions of these already existing functions.
619
620         (WebCore::Widget::convertToRootContainingView):
621         Provide a helper conversion function to recursively
622         convert a given FloatQuad up to the root widget.
623
624         * inspector/DOMNodeHighlighter.cpp:
625         (WebCore::DOMNodeHighlighter::DrawNodeHighlight):
626         Use the new methods to convert the FloatQuad for the highlighted
627         node to the root container, without losing transformation
628         information. Add a FIXME for SVG, which is still broken.
629
630         * WebCore.exp.in:
631         Export the new Widget functions so WebKit can link properly.
632
633 2011-06-25  Dirk Schulze  <krit@webkit.org>
634
635         Unreviewed build fix.
636
637         SVGAnimatedType should support SVGNumberList animation
638         https://bugs.webkit.org/show_bug.cgi?id=63387
639
640         * svg/SVGAnimatedNumberList.cpp:
641         (WebCore::SVGAnimatedNumberListAnimator::calculateAnimatedValue):
642
643 2011-06-25  Dirk Schulze  <krit@webkit.org>
644
645         Reviewed by Nikolas Zimmermann.
646
647         SVGAnimatedType should support SVGNumberList animation
648         https://bugs.webkit.org/show_bug.cgi?id=63387
649         
650         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
651         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGNumberList.
652         
653         Animations of attributes with type SVGNumberList can be interpolated now.
654
655         Tests: svg/animations/svgnumberlist-animation-1.html
656                svg/animations/svgnumberlist-animation-2.html
657
658         * CMakeLists.txt: Added new file to build system.
659         * GNUmakefile.list.am: Ditto.
660         * WebCore.gypi: Ditto.
661         * WebCore.pro: Ditto.
662         * WebCore.xcodeproj/project.pbxproj: Ditto.
663         * svg/SVGAllInOne.cpp: Ditto.
664         * svg/SVGAnimateElement.cpp: Make use of attribute type AnimatedNumberList.
665         (WebCore::SVGAnimateElement::determineAnimatedAttributeType):
666         (WebCore::SVGAnimateElement::calculateAnimatedValue):
667         (WebCore::SVGAnimateElement::calculateFromAndToValues):
668         (WebCore::SVGAnimateElement::calculateFromAndByValues):
669         (WebCore::SVGAnimateElement::resetToBaseValue):
670         (WebCore::SVGAnimateElement::applyResultsToTarget):
671         (WebCore::SVGAnimateElement::calculateDistance):
672         * svg/SVGAnimatedNumber.cpp:
673         (WebCore::SVGAnimatedNumberAnimator::calculateAnimatedNumber): Made method static for reuse in SVGAnimatedNumberList (and SVGAnimatedNumberOptionalNumber later).
674         (WebCore::SVGAnimatedNumberAnimator::calculateAnimatedValue): Use new static function.
675         * svg/SVGAnimatedNumber.h:
676         * svg/SVGAnimatedNumberList.cpp: Added. New animator for SVGNumberList.
677         (WebCore::SVGAnimatedNumberListAnimator::SVGAnimatedNumberListAnimator):
678         (WebCore::SVGAnimatedNumberListAnimator::constructFromString):
679         (WebCore::SVGAnimatedNumberListAnimator::calculateFromAndToValues):
680         (WebCore::SVGAnimatedNumberListAnimator::calculateFromAndByValues):
681         (WebCore::SVGAnimatedNumberListAnimator::calculateAnimatedValue):
682         (WebCore::SVGAnimatedNumberListAnimator::calculateDistance):
683         * svg/SVGAnimatedNumberList.h:
684         (WebCore::SVGAnimatedNumberListAnimator::~SVGAnimatedNumberListAnimator):
685         * svg/SVGAnimatedType.cpp: Use new Animator.
686         (WebCore::SVGAnimatedType::~SVGAnimatedType):
687         (WebCore::SVGAnimatedType::createNumberList):
688         (WebCore::SVGAnimatedType::numberList):
689         (WebCore::SVGAnimatedType::valueAsString):
690         (WebCore::SVGAnimatedType::setValueAsString):
691         * svg/SVGAnimatedType.h:
692         * svg/SVGAnimatorFactory.h:
693         (WebCore::SVGAnimatorFactory::create):
694
695 2011-06-25  Nikolas Zimmermann  <nzimmermann@rim.com>
696
697         Reviewed by Dirk Schulze.
698
699         Convert SVGPath to SVGAnimatorFactory concept
700         https://bugs.webkit.org/show_bug.cgi?id=63336
701
702         Convert <animate attributeName="d"> parsing to the new SVGAnimatorFactory concept, removing
703         the last special data types from SVGAnimateElement: SVGPathByteStream m_fromPath/m_toPath/m_animatedPath.
704         All existing non-string primitives have been converted to the new concept.
705
706         Doesn't change any functionality.
707
708         * CMakeLists.txt: Added SVGAnimatedPath.*.
709         * GNUmakefile.list.am: Ditto.
710         * WebCore.gypi: Ditto.
711         * WebCore.pro: Ditto.
712         * WebCore.vcproj/WebCore.vcproj: Ditto.
713         * WebCore.xcodeproj/project.pbxproj: Ditto.
714         * svg/SVGAllInOne.cpp: Ditto.
715         * svg/SVGAnimateElement.cpp:
716         (WebCore::SVGAnimateElement::SVGAnimateElement):
717         (WebCore::SVGAnimateElement::calculateAnimatedValue):
718         (WebCore::SVGAnimateElement::calculateFromAndToValues):
719         (WebCore::SVGAnimateElement::calculateFromAndByValues):
720         (WebCore::SVGAnimateElement::resetToBaseValue):
721         (WebCore::SVGAnimateElement::applyResultsToTarget):
722         * svg/SVGAnimateElement.h:
723         * svg/SVGAnimatedPath.cpp: Added.
724         (WebCore::SVGAnimatedPathAnimator::SVGAnimatedPathAnimator):
725         (WebCore::SVGAnimatedPathAnimator::constructFromString):
726         (WebCore::SVGAnimatedPathAnimator::calculateFromAndToValues):
727         (WebCore::SVGAnimatedPathAnimator::calculateFromAndByValues):
728         (WebCore::SVGAnimatedPathAnimator::calculateAnimatedValue):
729         (WebCore::SVGAnimatedPathAnimator::calculateDistance):
730         * svg/SVGAnimatedPath.h: Added.
731         (WebCore::SVGAnimatedPathAnimator::~SVGAnimatedPathAnimator):
732         * svg/SVGAnimatedType.cpp:
733         (WebCore::SVGAnimatedType::~SVGAnimatedType):
734         (WebCore::SVGAnimatedType::createPath):
735         (WebCore::SVGAnimatedType::path):
736         (WebCore::SVGAnimatedType::valueAsString):
737         (WebCore::SVGAnimatedType::setValueAsString):
738         * svg/SVGAnimatedType.h:
739         * svg/SVGAnimatorFactory.h:
740         (WebCore::SVGAnimatorFactory::create):
741         * svg/SVGPathByteStream.h:
742         (WebCore::SVGPathByteStream::initializeFrom):
743         * svg/SVGPathParserFactory.cpp:
744         (WebCore::SVGPathParserFactory::buildSVGPathByteStreamFromSVGPathSegList):
745         (WebCore::SVGPathParserFactory::buildSVGPathByteStreamFromString):
746         (WebCore::SVGPathParserFactory::buildAnimatedSVGPathByteStream):
747
748 2011-06-25  Jer Noble  <jer.noble@apple.com>
749
750         Reviewed by Maciej Stachowiak.
751
752         SOFT_LINK_POINTER_OPTIONAL isn't optional.
753         https://bugs.webkit.org/show_bug.cgi?id=63378
754
755         Continuation of r89718.  SOFT_LINK_POINTER_OPTIONAL should check the value returned by dlsym before dereferencing it.
756
757         * platform/mac/SoftLinking.h:
758
759 2011-06-25  Rob Buis  <rbuis@rim.com>
760
761         Reviewed by Nikolas Zimmermann.
762
763         SVG1.1SE test linking-uri-01-b.svg fails
764         https://bugs.webkit.org/show_bug.cgi?id=63322
765
766         Allow navigating to internal <view> targets. When choosing Back ensure
767         the <svg> current view is initialized correctly.
768
769         Tests: svg/W3C-SVG-1.1-SE/linking-uri-01-b.svg
770                svg/custom/linking-uri-01-b.svg
771
772         * page/FrameView.cpp: Delegate to setupInitialView.
773         (WebCore::FrameView::scrollToAnchor):
774         * svg/SVGAElement.cpp: Allow navigating to internal <view> targets.
775         (WebCore::SVGAElement::defaultEventHandler):
776         * svg/SVGSVGElement.cpp:
777         (WebCore::SVGSVGElement::setupInitialView): Initialize current view depending on fragment identifier.
778         (WebCore::SVGSVGElement::inheritViewAttributes):
779         * svg/SVGSVGElement.h:
780
781 2011-06-24  Dimitri Glazkov  <dglazkov@chromium.org>
782
783         Reviewed by Darin Adler.
784
785         REGRESSION (r77740): Shadow DOM pseudo elements aren't matching when combined with descendant selectors
786         https://bugs.webkit.org/show_bug.cgi?id=63373
787
788         * css/CSSStyleSelector.cpp:
789         (WebCore::CSSStyleSelector::pushParentStackFrame): Changed to use parentOrHostElement.
790         (WebCore::CSSStyleSelector::pushParent): Ditto.
791         * dom/Node.cpp:
792         (WebCore::Node::parentOrHostElement): Added.
793         * dom/Node.h:
794
795 2011-06-24  Dan Bernstein  <mitz@apple.com>
796
797         Reviewed by Anders Carlsson.
798
799         Add an option to enable legacy rounding hacks
800         https://bugs.webkit.org/show_bug.cgi?id=63363
801
802         Restored most of text rounding hacks which were removed in r78846, with a global flag to control
803         whether rounding hacks are allowed, which defaults to false.
804
805         Test: platform/mac/fast/text/rounding-hacks.html
806
807         * CMakeLists.txt: Added TextRun.cpp.
808         * GNUmakefile.list.am: Ditto.
809         * WebCore.exp.in: Export new TextRun function and global and updated StringTruncator functions.
810         * WebCore.gypi: Added TextRun.cpp.
811         * WebCore.pro: Ditto.
812         * WebCore.vcproj/WebCore.vcproj: Ditto.
813         * WebCore.xcodeproj/project.pbxproj: Ditto.
814         * html/canvas/CanvasRenderingContext2D.cpp:
815         (WebCore::CanvasRenderingContext2D::drawTextInternal): Disable rounding hacks in the one place
816         they used to be disabled.
817         * platform/graphics/Font.cpp: Re-added the rounding character table.
818         * platform/graphics/Font.h:
819         (WebCore::Font::isRoundingHackCharacter): Re-added.
820         * platform/graphics/FontFastPath.cpp:
821         (WebCore::Font::getGlyphsAndAdvancesForSimpleText): Account for final rounding width.
822         * platform/graphics/SimpleFontData.cpp:
823         (WebCore::SimpleFontData::platformGlyphInit): Initialize m_adjustedSpaceWidth.
824         * platform/graphics/SimpleFontData.h:
825         (WebCore::SimpleFontData::adjustedSpaceWidth): Re-added.
826         * platform/graphics/StringTruncator.cpp:
827         (WebCore::stringWidth): Re-added disableRoundingHacks parameter.
828         (WebCore::truncateString): Ditto.
829         (WebCore::StringTruncator::centerTruncate): Added EnableRoundingHacksOrNot parameter.
830         (WebCore::StringTruncator::rightTruncate): Ditto.
831         (WebCore::StringTruncator::width): Ditto.
832         * platform/graphics/StringTruncator.h:
833         * platform/graphics/TextRun.cpp: Added.
834         (WebCore::TextRun::setAllowsRoundingHacks): Added.
835         * platform/graphics/TextRun.h:
836         (WebCore::TextRun::TextRun): Added RoundingHacks parameter to the constructors, used to initialize
837         the m_applyRunRounding and m_applyWordRounding member variables, subject to rounding hacks being allowed.
838         (WebCore::TextRun::applyRunRounding): Re-added this accessor.
839         (WebCore::TextRun::applyWordRounding): Ditto.
840         (WebCore::TextRun::disableRoundingHacks): Re-added.
841         * platform/graphics/WidthIterator.cpp:
842         (WebCore::WidthIterator::WidthIterator): Re-added code to apply rounding hacks.
843         (WebCore::WidthIterator::advance): Ditto.
844         * platform/graphics/WidthIterator.h:
845         * platform/graphics/mac/ComplexTextController.cpp:
846         (WebCore::ceilCGFloat): Re-added.
847         (WebCore::ComplexTextController::ComplexTextController): Re-added code to apply rounding hacks.
848         (WebCore::ComplexTextController::advance): Ditto.
849         (WebCore::ComplexTextController::adjustGlyphsAndAdvances): Ditto.
850         * platform/graphics/mac/ComplexTextController.h:
851         (WebCore::ComplexTextController::finalRoundingWidth): Re-added this accessor.
852         * platform/graphics/mac/FontComplexTextMac.cpp:
853         (WebCore::Font::getGlyphsAndAdvancesForComplexText): Accound for final rounding width.
854         * platform/graphics/qt/SimpleFontDataQt.cpp:
855         (WebCore::SimpleFontData::platformGlyphInit): Initialize m_adjustedSpaceWidth.
856         * platform/gtk/RenderThemeGtk.cpp:
857         (WebCore::RenderThemeGtk::fileListNameForWidth): Enabled rounding hacks in the string truncator.
858         * platform/mac/DragImageMac.mm:
859         (WebCore::widthWithFont): Disable rounding hacks when measuring.
860         (WebCore::drawAtPoint): Disable rounding hacks when drawing.
861         * platform/win/DragImageWin.cpp:
862         (WebCore::createDragImageForLink): Enable rounding hacks in the string truncator.
863         * platform/win/WebCoreTextRenderer.cpp:
864         (WebCore::WebCoreTextFloatWidth): Ditto.
865         * rendering/RenderFileUploadControl.cpp:
866         (WebCore::RenderFileUploadControl::paintObject): Disable rounding hacks.
867         * rendering/RenderListBox.cpp:
868         (WebCore::RenderListBox::updateFromElement): Ditto.
869         (WebCore::RenderListBox::paintItemForeground): Ditto.
870         * rendering/RenderTextControl.cpp:
871         (WebCore::RenderTextControl::getAvgCharWidth): Ditto.
872         * rendering/RenderTheme.cpp:
873         (WebCore::RenderTheme::fileListNameForWidth): Enabled rounding hacks in the string truncator.
874         * rendering/RenderThemeMac.mm:
875         (WebCore::RenderThemeMac::fileListNameForWidth): Ditto.
876         * rendering/svg/SVGInlineTextBox.cpp:
877         (WebCore::SVGInlineTextBox::constructTextRun): Disabled rounding hacks.
878         * rendering/svg/SVGTextMetrics.cpp:
879         (WebCore::constructTextRun): Ditto.
880
881 2011-06-24  Nikolas Zimmermann  <nzimmermann@rim.com>
882
883         Reviewed by Rob Buis.
884
885         Integrate SVG Fonts within GlyphPage concept, removing the special SVG code paths from Font, making it possible to reuse the simple text code path for SVG Fonts
886         https://bugs.webkit.org/show_bug.cgi?id=59085
887
888         font substitution doesn't work for HTML text using SVG fonts
889         https://bugs.webkit.org/show_bug.cgi?id=17608
890
891         Selection rects are wrong for text with SVG fonts
892         https://bugs.webkit.org/show_bug.cgi?id=25460
893
894         With @font-face, SVG fonts only work as primary, non-segmented
895         https://bugs.webkit.org/show_bug.cgi?id=32227
896
897         When using SVG fonts with @font-face word-spacing and text-align: justify are not being honored
898         https://bugs.webkit.org/show_bug.cgi?id=34236
899
900         SVG @font-face breaks text-overflow: ellipsis
901         https://bugs.webkit.org/show_bug.cgi?id=36840
902
903         REGRESSION: SVG Font selection problems
904         https://bugs.webkit.org/show_bug.cgi?id=41934
905
906         Tests: svg/custom/svg-fonts-fallback.xhtml (for bug 17608, extended the original test from Mark Ambachtsheer)
907                svg/custom/svg-fonts-segmented.xhtml (for bug 32227)
908                svg/custom/svg-fonts-word-spacing.html (for bug 34236, from Michael Lewis)
909                svg/text/select-text-svgfont.html (for bug 25460/41934, from Emil Schutte)
910                svg/text/text-overflow-ellipsis-svgfont.html (for 36840, from Emil Schutte)
911
912         Rewrite the SVG Fonts support to fully integrate within the GlyphPage concept and the "simple" code path used to render platform fonts.
913         That means the special logic for measuring text using SVG Fonts, calculating offset for positions, computing selection rects etc. is all gone now.
914         There's no difference anymore between using a native font or a SVG Font, in terms of these operations.
915
916         This makes text selection using SVG Fonts possible again.
917
918         * features.pri: Temporarily turn of SVG Fonts for Qt, as long as QRawFont support is not available and the fast path is disabled.
919         * page/DOMWindow.idl: Touched file to force Qt regenerating the bindings.
920         * platform/graphics/Font.cpp: Remove SVG Font special cases, the simple code path now handles SVG Fonts as well.
921         (WebCore::Font::drawText):
922         (WebCore::Font::drawEmphasisMarks):
923         (WebCore::Font::width):
924         (WebCore::Font::selectionRectForText):
925         (WebCore::Font::offsetForPosition):
926         (WebCore::Font::codePath):
927         * platform/graphics/Font.h: Pass TextRun to drawGlyphBuffer/drawEmphasisMarks. Add new glyphDataAndPageForCharacter() method which returns a pair
928                                     std::pair<GlyphData, GlyphPage*>, so we know the associated GlyphPage for a certain GlyphData object, which is needed to properly
929                                     handle font fallback glyph matching for SVG Fonts..
930         (WebCore::Font::fontList): Add FontFallbackList accessor.
931         * platform/graphics/FontFallbackList.h: Add getters/setters for glyphPageZero -- SVG Fonts support needs access to these objects from SVGTextRunRenderingContext.
932         (WebCore::FontFallbackList::glyphPageZero):
933         (WebCore::FontFallbackList::glyphPages):
934         (WebCore::FontFallbackList::setGlyphPageZero):
935         (WebCore::FontFallbackList::setGlyphPages):
936         * platform/graphics/FontFastPath.cpp:
937         (WebCore::Font::glyphDataForCharacter): Move implementation to glyphDataAndPageForCharacter(), and use that method from here.
938         (WebCore::Font::glyphDataAndPageForCharacter): Does the same as before, just returns an additional GlyphPage* pointer.
939         (WebCore::Font::getEmphasisMarkGlyphData): Remove SVG Fonts special case.
940         (WebCore::Font::drawGlyphBuffer): Ditto.
941         * platform/graphics/FontMetrics.h:
942         (WebCore::scaleEmToUnits): Refactored scaleEmToUnits free function from SimpleFontDataMac/CGWin to share with SVGFontData/SVGTextRunRenderingContext.
943         * platform/graphics/GlyphPageTreeNode.cpp:
944         (WebCore::fill): Stop skipping SVG Fonts, they now also fill the GlyphPage using the glyphs defined in the SVG Font.
945         * platform/graphics/SVGGlyph.h: s/isValid/isPartOfLigature/. Its usage has been changed.
946         (WebCore::SVGGlyph::SVGGlyph):
947         (WebCore::SVGGlyph::operator==):
948         * platform/graphics/SimpleFontData.cpp: Change font size to be a float, not an int.
949         (WebCore::SimpleFontData::SimpleFontData):
950         * platform/graphics/SimpleFontData.h: Add new pure virtual methods to the AdditionalFontData interface, to be implemented in SVGFontData.
951         (WebCore::SimpleFontData::widthForGlyph): Call widthForSVGGlyph, if we encounter a SVG glyph.
952         * platform/graphics/TextRun.h: 
953         * platform/graphics/WidthIterator.cpp:
954         (WebCore::WidthIterator::glyphDataForCharacter):
955         (WebCore::WidthIterator::advance):
956         * platform/graphics/WidthIterator.h: Store several new members needed for SVG Fonts support (last processed glyph name used for kerning pair lookup)
957                                              and a map mapping each character of a text to its arabic-form (if needed, to perform SVG glyph selection for Arabic text).
958         (WebCore::WidthIterator::run):
959         (WebCore::WidthIterator::runWidthSoFar):
960         (WebCore::WidthIterator::lastGlyphName):
961         (WebCore::WidthIterator::setLastGlyphName):
962         (WebCore::WidthIterator::arabicForms):
963         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp: Use new scaleEmToUnits free function from FontMetrics.h.
964         * platform/graphics/mac/SimpleFontDataMac.mm: Ditto.
965         * platform/graphics/win/SimpleFontDataCGWin.cpp: Ditto.
966         * rendering/svg/SVGTextLayoutAttributesBuilder.cpp:
967         (WebCore::SVGTextLayoutAttributesBuilder::propagateLayoutAttributes): Handle UTF-16 surrogate pairs correctly, fixes the previous Acid3 regression.
968         * rendering/svg/SVGTextMetrics.cpp:
969         (WebCore::SVGTextMetrics::SVGTextMetrics):
970         (WebCore::constructTextRun):
971         (WebCore::SVGTextMetrics::measureCharacterRange):
972         * rendering/svg/SVGTextMetrics.h:
973         * rendering/svg/SVGTextRunRenderingContext.cpp: Remove drawTextUsingSVGFont/floatWidthUsingSVGFont/selectionRectForTextUsingSVGFont/offsetForPositionForTextUsingSVGFont.
974         (WebCore::firstParentRendererForNonTextNode): Don't assert node() exists, doesn't hold true for generated render objects.
975         (WebCore::renderObjectFromRun): Renamed from referencingRenderObjectFromRun.
976         (WebCore::SVGTextRunRenderingContext::floatWidthUsingSVGFont): Remove extra "extraCharsAvailable" parameter, now solves via TextRun::charactersLength().
977         (WebCore::calculateEmUnitToPixelScaleFactor): Add helper method.
978         (WebCore::SVGTextRunRenderingContext::drawSVGGlyphs): Main drawing method, this actually creates/renders Paths.
979         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter): Part 1/2 of SVG Glyph selection code.
980         * rendering/svg/SVGTextRunRenderingContext.h:
981         * svg/SVGAltGlyphElement.cpp:
982         (WebCore::SVGAltGlyphElement::hasValidGlyphElement):
983         * svg/SVGAltGlyphElement.h:
984         * svg/SVGFontData.cpp:
985         (WebCore::SVGFontData::initializeFontData): Changed font size from int to float.
986         (WebCore::SVGFontData::widthForSVGGlyph): Lookup a SVGGlyph from a Glyph using the glyph table in SVGFontElement and calculate its width.
987         (WebCore::SVGFontData::applySVGGlyphSelection): Part 2/2 of SVG Glyph selection code.
988         (WebCore::SVGFontData::fillSVGGlyphPage): Fill GlyphPage using glyphs defined in the SVG Font.
989         (WebCore::SVGFontData::fillBMPGlyphs): Moved from the previous fillSVGGlyphPage implementation.
990         (WebCore::SVGFontData::fillNonBMPGlyphs): Add non-bmp glyph handling, fixing the Acid3 regression (support using SVGGlyphs for UTF-16 surrogate pairs).
991         * svg/SVGFontData.h:
992         * svg/SVGFontElement.cpp:
993         (WebCore::SVGFontElement::registerLigaturesInGlyphCache): Enable ligature registration for the use within GlyphPage.
994         (WebCore::SVGFontElement::ensureGlyphCache):
995         * svg/SVGGlyphMap.h: Switch to use SurrogatePairTextIterator, and switch glyph table from UChar to UChar32, just like GlyphPage, to handle glyphs from non-BMP correctly.
996         (WebCore::SVGGlyphMap::addGlyph): Remove setting isValid, it's not needed anymore and gone.
997         (WebCore::SVGGlyphMap::collectGlyphsForString):
998         * svg/svgtags.in: Surround vkern in ENABLE_SVG_FONTS block.
999
1000 2011-06-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1001
1002         Reviewed by Antonio Gomes.
1003
1004         [CMAKE] Replace ";" with space in FEATURE_DEFINES macro
1005         https://bugs.webkit.org/show_bug.cgi?id=62211
1006
1007         html.css file doesn't recognize ENABLE_XXX macro because FEATURE_DEFINES macro has ";"
1008         as separator. So, let the html.css to use new feature macro with space separator.
1009
1010         * CMakeLists.txt:
1011
1012 2011-06-24  Gavin Peters  <gavinp@chromium.org>
1013
1014         Reviewed by Darin Adler.
1015
1016         fix possible race in LinkLoader
1017         https://bugs.webkit.org/show_bug.cgi?id=63360
1018
1019         In chromium bug 80729
1020         http://code.google.com/p/chromium/issues/detail?id=80729 I am
1021         seeing some kind of double triggering of the timer; I am concerned
1022         that it is possible that a Link element errors out or succeeds,
1023         sets a timer, and shortly before the timer is triggered it is
1024         editted, launches another request.  After that, the first timer
1025         triggers, zeroing out m_cachedResource.  Then, the second load
1026         finishes, and *crash*.  If this is the case, this fix should stop
1027         it.
1028
1029         No new tests; I haven't reproduced this.  I hope chrome's crash
1030         telemetry will give good feedback; this crash is occuring many times a
1031         day so the difference should be obvious.
1032
1033         * loader/LinkLoader.cpp:
1034         (WebCore::LinkLoader::LinkLoader):
1035         (WebCore::LinkLoader::linkLoadTimerFired):
1036         (WebCore::LinkLoader::linkLoadingErrorTimerFired):
1037         (WebCore::LinkLoader::notifyFinished):
1038         * loader/LinkLoader.h:
1039
1040 2011-06-24  Jer Noble  <jer.noble@apple.com>
1041
1042         Reviewed by Eric Carlson.
1043
1044         Safari will quit unexpectedly when launching Safari in the first time (crash in initQTSecurityPolicyNoLocalToRemoteSiteAttribute)
1045         https://bugs.webkit.org/show_bug.cgi?id=63332
1046         <rdar://problem/9661650>
1047
1048         No new tests; Only affects machines with QTKit < 7.6.3 installed.
1049
1050         Check to see if QTSecurityPolicyNoRemoteToLocalSiteAttribute is non-NULL before passing it into -[QTMovie initWithAttributes:],
1051         as it is only defined in QTKit >= 7.6.3.  If it is NULL, pass QTSecurityPolicyNoCrossSiteAttribute=YES instead, which has
1052         the same effect in earlier versions of QTKit as the NoLocalToRemote and NoRemoteToLocal keys.  To avoid ASSERTs when running
1053         debug builds with earlier versions of QTKit, add a SOFT_LINK_POINTER_OPTIONAL macro to SoftLinking.h and make these keys optional.
1054
1055         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1056         (WebCore::MediaPlayerPrivateQTKit::commonMovieAttributes):
1057         * platform/mac/SoftLinking.h: Add SOFT_LINK_POINTER_OPTIONAL macro.
1058
1059 2011-06-24  Darin Adler  <darin@apple.com>
1060
1061         Try to fix Windows build failure.
1062
1063         * platform/win/ClipboardUtilitiesWin.cpp:
1064         (WebCore::setFileDescriptorData): Copy string into a local so we
1065         can call charactersWithNullTermination on it.
1066
1067 2011-06-23  Darin Adler  <darin@apple.com>
1068
1069         Reviewed by Adam Barth.
1070
1071         Remove some unneeded functions from FrameLoader
1072         https://bugs.webkit.org/show_bug.cgi?id=63295
1073
1074         Removing 7 of the functions in FrameLoader.h is probably a step
1075         in the right direction.
1076
1077         * loader/DocumentLoader.cpp:
1078         (WebCore::DocumentLoader::handledOnloadEvents):
1079         Moved the call to stopDeferringEvents in here from FrameLoader.
1080         * loader/DocumentLoader.h: Ditto.
1081
1082         * loader/DocumentWriter.h: Fixed a typo.
1083
1084         * loader/FrameLoader.cpp:
1085         (WebCore::FrameLoader::setFirstPartyForCookies): Changed this to
1086         use a non-recursive tree walk instead of recursion.
1087         (WebCore::FrameLoader::stopAllLoaders): Moved the code from
1088         stopLoadingSubframes inline, since it's only two lines of code.
1089         (WebCore::FrameLoader::checkLoadCompleteForThisFrame): Moved
1090         the code from markLoadComplete inline, since it's only one line.
1091         (WebCore::FrameLoader::checkLoadComplete): Changed this to use a
1092         non-recursive tree walk instead of recursion, eliminating the
1093         recursiveCheckLoadComplete function completely.
1094         (WebCore::FrameLoader::handledOnloadEvents): Moved the call to
1095         stopDeferringEvents into DocumentLoader.
1096
1097         * loader/FrameLoader.h: Removed unneeded forward declarations,
1098         and now-unneeded functions setupForReplaceByMIMEType,
1099         isStopping, isLoadingFromCachedPage, stopLoadingSubframes,
1100         markLoadComplete, mainReceivedError, and recursiveCheckLoadComplete.
1101         Also made allChildrenAreComplete private.
1102
1103         * loader/MainResourceLoader.cpp:
1104         (WebCore::MainResourceLoader::continueAfterContentPolicy):
1105         Call DocumentLoader::isStopping so we can remove the function
1106         from FrameLoader that just calls through. Other call sites were
1107         using DocumentLoader::isStopping directly.
1108         (WebCore::MainResourceLoader::didReceiveResponse): Call
1109         DocumentLoader::setupForReplaceByMIMEType so we can remove the
1110         function from FrameLoader that just calls through. This was
1111         the only call site.
1112
1113         * loader/ResourceLoader.cpp:
1114         (WebCore::ResourceLoader::init): Call the
1115         ResourceLoader::cancelledError function instead of calling
1116         directly to FrameLoader.
1117
1118         * loader/ResourceLoader.h: Made response an inline function.
1119
1120 2011-06-24  Alexey Proskuryakov  <ap@apple.com>
1121
1122         Rubber-stamped by Maciej Stachowiak.
1123
1124         REGRESSION (r88984): Infinite recursion in DocumentLoader::detachFromFrame/stopLoading
1125
1126         No new tests, as there is no known way to reproduce this (but we'll keep investigating, as
1127         the rollout will re-introduce the older less frequent crash).
1128
1129         * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::detachFromFrame): Rollout the fix
1130         for bug 62764.
1131
1132 2011-06-24  Tony Chang  <tony@chromium.org>
1133
1134         Reviewed by Ojan Vafai.
1135
1136         add flexbox and inline-flexbox as possible CSS display values
1137         https://bugs.webkit.org/show_bug.cgi?id=63361
1138
1139         Test: css3/flexbox/display-property.html
1140
1141         * css/CSSParser.cpp:
1142         (WebCore::CSSParser::parseValue):
1143         * css/CSSValueKeywords.in:
1144
1145 2011-06-24  Anna Cavender  <annacc@chromium.org>
1146
1147         Reviewed by Eric Carlson.
1148
1149         Loading out-of-band text track files from <track>.
1150         https://bugs.webkit.org/show_bug.cgi?id=62881
1151
1152         Uses the src attribute of <track> urls to load out-of-band text track
1153         files using ThreadableLoader.  Also removes TextTrackPrivateInterface
1154         (as well as LoadableTextTrackImpl and MutableTextTrackImpl) classes.
1155
1156         No new tests because feature is hidden behind VIDEO_TRACK feature
1157         define, which is turned off.
1158
1159         * CMakeLists.txt:
1160         * GNUmakefile.am:
1161         * GNUmakefile.list.am:
1162         * WebCore.gypi:
1163         * WebCore.pro:
1164         * WebCore.xcodeproj/project.pbxproj:
1165         * html/HTMLMediaElement.cpp:
1166         * html/HTMLMediaElement.h:
1167         * html/HTMLTrackElement.cpp:
1168         * html/HTMLTrackElement.h:
1169         * html/LoadableTextTrack.cpp:
1170         * html/LoadableTextTrack.h:
1171         * html/LoadableTextTrackImpl.cpp: Removed.
1172         * html/LoadableTextTrackImpl.h: Removed.
1173         * html/MutableTextTrack.cpp:
1174         * html/MutableTextTrack.h:
1175         * html/MutableTextTrackImpl.cpp: Removed.
1176         * html/MutableTextTrackImpl.h: Removed.
1177         * html/TextTrack.cpp:
1178         * html/TextTrack.h:
1179         * html/TextTrackPrivate.h: Removed.
1180         * platform/track/CueParser.cpp:
1181         * platform/track/CueParser.h:
1182
1183 2011-06-24  Rob Buis  <rbuis@rim.com>
1184
1185         Rubber-stamped by Nikolas Zimmermann.
1186
1187         All pointer-events fail if text has visibility="hidden"
1188         https://bugs.webkit.org/show_bug.cgi?id=62209
1189
1190         Do not use writing mode aware code for SVG Text.
1191
1192         No new tests needed.
1193
1194         * rendering/svg/SVGInlineTextBox.cpp:
1195         (WebCore::SVGInlineTextBox::nodeAtPoint):
1196
1197 2011-06-24  Lukasz Slachciak  <l.slachciak@samsung.com>
1198
1199         Reviewed by Darin Adler.
1200
1201         Change NDEBUG to !LOG_DISABLED macro in databases for logging.
1202         https://bugs.webkit.org/show_bug.cgi?id=63346
1203
1204         Changed NDEBUG to !LOG_DISABLED in databases code which involves logging.
1205         This change resolves also build break in Release build when logging enabled.
1206
1207         No new tests because there is no new behavior or feature exposed.
1208
1209         * loader/icon/IconDatabase.cpp: Macro fixes.
1210         (WebCore::IconDatabase::iconDatabaseSyncThread):
1211         (WebCore::IconDatabase::syncThreadMainLoop):
1212         (WebCore::IconDatabase::readFromDatabase):
1213         (WebCore::IconDatabase::writeToDatabase):
1214         (WebCore::IconDatabase::cleanupSyncThread):
1215         * storage/AbstractDatabase.h: Macro fixes.
1216         * storage/DatabaseTask.cpp: Macro fixes.
1217         * storage/DatabaseTask.h: Macro fixes.
1218         * storage/SQLTransaction.cpp: Macro fixes.
1219         * storage/SQLTransaction.h: Macro fixes.
1220
1221 2011-06-24  Tony Chang  <tony@chromium.org>
1222
1223         Reviewed by Adam Barth.
1224
1225         Pass Strings by const reference to functions
1226         https://bugs.webkit.org/show_bug.cgi?id=63341
1227
1228         Note that since Strings hold a RefPtr to StringImpl, passing Strings
1229         by value isn't horrible, but it does cause ref count churn and using
1230         const references is more consistent with the rest of the code base.
1231
1232         * loader/FrameLoader.cpp:
1233         (WebCore::FrameLoader::addHTTPOriginIfNeeded): Rework the code to not
1234             change the value of the passed in String.
1235         * loader/FrameLoader.h:
1236         * platform/win/ClipboardUtilitiesWin.cpp:
1237         (WebCore::setFileDescriptorData):
1238         * platform/win/ClipboardUtilitiesWin.h:
1239         * storage/DatabaseTracker.h:
1240         * storage/IDBLevelDBBackingStore.cpp:
1241         (WebCore::IDBLevelDBBackingStore::IDBLevelDBBackingStore):
1242         * storage/IDBLevelDBBackingStore.h:
1243         * storage/IDBSQLiteBackingStore.cpp:
1244         (WebCore::IDBSQLiteBackingStore::IDBSQLiteBackingStore):
1245         * storage/IDBSQLiteBackingStore.h:
1246         * storage/chromium/DatabaseTrackerChromium.cpp:
1247         (WebCore::DatabaseTracker::getOpenDatabases):
1248         * svg/SVGPaint.cpp:
1249         (WebCore::SVGPaint::SVGPaint):
1250         * svg/SVGPaint.h:
1251         * svg/animation/SMILTimeContainer.cpp:
1252         (WebCore::SMILTimeContainer::updateAnimations):
1253         * svg/animation/SMILTimeContainer.h:
1254         * websockets/ThreadableWebSocketChannelClientWrapper.cpp:
1255         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageCallback):
1256         * websockets/ThreadableWebSocketChannelClientWrapper.h:
1257
1258 2011-06-24  Abhishek Arya  <inferno@chromium.org>
1259
1260         Reviewed by Darin Adler.
1261
1262         Add clamping for CSSPrimitiveValues and SVGInlineText font size.
1263         https://bugs.webkit.org/show_bug.cgi?id=53449        
1264
1265         Test: svg/text/svg-zoom-large-value.xhtml
1266
1267         * css/CSSPrimitiveValue.cpp:
1268         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): add asserts to detect if the
1269         number created is valid.
1270         * css/CSSPrimitiveValue.h: add clamping checks to prevent overflows.
1271         (WebCore::CSSPrimitiveValue::getFloatValue):
1272         (WebCore::CSSPrimitiveValue::getIntValue):
1273         * css/CSSStyleSelector.cpp:
1274         (WebCore::CSSStyleSelector::getComputedSizeFromSpecifiedSize): split into two
1275         static functions, one specific to CSSStyleSelector and other generic to help
1276         in clamping font size for other callers like svg text, etc.
1277         * css/CSSStyleSelector.h:
1278         * platform/graphics/FontDescription.h: add asserts to detect if the new font
1279         size is valid.
1280         (WebCore::FontDescription::setComputedSize):
1281         (WebCore::FontDescription::setSpecifiedSize):
1282         * rendering/svg/RenderSVGInlineText.cpp:
1283         (WebCore::RenderSVGInlineText::computeNewScaledFontForStyle): use the new helper
1284         from CSSStyleSelector to help in clamping new scaled font size. do not use
1285         "smart minimum" since svg allows really small unreadable fonts (tested by existing
1286         layout tests). Document's minimum font size clamp (0 in my case) and harmless epsilon
1287         check in CSSStyleSelector function should still hold for svg.
1288
1289 2011-06-24  Julien Chaffraix  <jchaffraix@webkit.org>
1290
1291         Reviewed by Darin Adler.
1292
1293         Remove unsafe static_cast inside the InlineBox hierarchy
1294         https://bugs.webkit.org/show_bug.cgi?id=63077
1295
1296         Refactoring only, no new test.
1297
1298         * rendering/InlineFlowBox.h:
1299         (WebCore::toInlineFlowBox):
1300         * rendering/InlineTextBox.h:
1301         (WebCore::toInlineTextBox):
1302         Added the proper cast methods to those 2 classes from an InlineBox.
1303
1304         * rendering/InlineBox.cpp:
1305         (WebCore::InlineBox::nextLeafChild):
1306         (WebCore::InlineBox::prevLeafChild):
1307         * rendering/InlineFlowBox.cpp:
1308         (WebCore::InlineFlowBox::getFlowSpacingLogicalWidth):
1309         (WebCore::InlineFlowBox::addToLine):
1310         (WebCore::InlineFlowBox::determineSpacingForFlowBoxes):
1311         (WebCore::InlineFlowBox::placeBoxesInInlineDirection):
1312         (WebCore::InlineFlowBox::requiresIdeographicBaseline):
1313         (WebCore::InlineFlowBox::adjustMaxAscentAndDescent):
1314         (WebCore::InlineFlowBox::computeLogicalBoxHeights):
1315         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
1316         (WebCore::InlineFlowBox::flipLinesInBlockDirection):
1317         (WebCore::InlineFlowBox::computeOverflow):
1318         (WebCore::InlineFlowBox::firstLeafChild):
1319         (WebCore::InlineFlowBox::lastLeafChild):
1320         (WebCore::InlineFlowBox::computeOverAnnotationAdjustment):
1321         (WebCore::InlineFlowBox::computeUnderAnnotationAdjustment):
1322         * rendering/RenderBlock.cpp:
1323         (WebCore::RenderBlock::positionForBox):
1324         * rendering/RenderBlockLineLayout.cpp:
1325         (WebCore::RenderBlock::createLineBoxes):
1326         (WebCore::RenderBlock::constructLine):
1327         (WebCore::setLogicalWidthForTextRun):
1328         (WebCore::computeExpansionForJustifiedText):
1329         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine):
1330         * rendering/RenderText.cpp:
1331         (WebCore::RenderText::localCaretRect):
1332         (WebCore::RenderText::positionLineBox):
1333         * rendering/RootInlineBox.cpp:
1334         (WebCore::RootInlineBox::ascentAndDescentForBox):
1335         (WebCore::RootInlineBox::includeFontForBox):
1336         (WebCore::RootInlineBox::includeGlyphsForBox):
1337         Replaced the static_cast in those previous call sites with the new cast methods.
1338
1339 2011-06-24  Alexis Menard  <alexis.menard@openbossa.org>
1340
1341         Unreviewed build fix.
1342
1343         Build fix on Linux when using the GStreamer backend.
1344
1345         No new tests, just a build fix.
1346
1347         * platform/graphics/gstreamer/PlatformVideoWindowQt.cpp:
1348         (FullScreenVideoWindow::keyPressEvent):
1349
1350 2011-06-24  Nat Duca  <nduca@chromium.org>
1351
1352         Unreviewed, rolling out r89694.
1353         http://trac.webkit.org/changeset/89694
1354         https://bugs.webkit.org/show_bug.cgi?id=58408
1355
1356         Test shell still not ready for animate changes.
1357
1358         * WebCore.gypi:
1359         * platform/graphics/chromium/LayerRendererChromium.cpp:
1360         (WebCore::LayerRendererChromium::create):
1361         (WebCore::LayerRendererChromium::LayerRendererChromium):
1362         (WebCore::LayerRendererChromium::setViewport):
1363         (WebCore::LayerRendererChromium::updateAndDrawLayers):
1364         * platform/graphics/chromium/LayerRendererChromium.h:
1365         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
1366         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
1367         (WebCore::CCHeadsUpDisplay::setShowFPSCounter):
1368         (WebCore::CCHeadsUpDisplay::setShowPlatformLayerTree):
1369         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp: Removed.
1370         * platform/graphics/chromium/cc/CCLayerTreeHost.h: Removed.
1371         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.cpp: Removed.
1372         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.h: Removed.
1373         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp: Removed.
1374         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h: Removed.
1375         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.cpp: Removed.
1376         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.h: Removed.
1377         * platform/graphics/chromium/cc/CCMainThreadTask.h:
1378         * platform/graphics/chromium/cc/CCThread.cpp:
1379         (WebCore::CCThread::runLoop):
1380         * platform/graphics/chromium/cc/CCThreadTask.h:
1381
1382 2011-06-24  Chris Rogers  <crogers@google.com>
1383
1384         Unreviewed build fix.
1385
1386         Fix Chromium Linux Build
1387         https://bugs.webkit.org/show_bug.cgi?id=63349
1388
1389         * WebCore.gyp/WebCore.gyp:
1390
1391 2011-06-24  Henry Song  <hsong@sisa.samsung.com>
1392
1393         Reviewed by Martin Robinson.
1394
1395         Correct _sharedTimer value in SharedTimerEfl.cpp
1396         https://bugs.webkit.org/show_bug.cgi?id=62380
1397
1398         SharedTimerEfl.cpp set _sharedTimer = 0 is incorrect in 
1399         timerEvent(), we have observed addNewTimer() can be triggered 
1400         by either inside timerFunction() or others that are not within
1401         timerFunction().  We have observed the following case:
1402         1. add a new Timer within timerFunction()
1403         2. timerFunction returns, set _sharedTimer = 0
1404         3. addNewTimer() is triggered again within webkit, don't know
1405            it triggers this.
1406         4. because at this moment, _sharedTimer == 0, the previous
1407            registered timer (in step 1) did not get removed.
1408         5. Now in ecore_timer, there are two timers with same callbacks
1409         6. From now on, timerFunction() will be called twice back-to-back
1410            in each ecore_timer loop.
1411         To correct this, we should set _sharedTimer = 0 before
1412         timerFunction() so that when addNewTimer() triggered within,
1413         we have a valid timer object.
1414
1415         * platform/efl/SharedTimerEfl.cpp:
1416         (WebCore::timerEvent):
1417
1418 2011-05-17  Nat Duca  <nduca@chromium.org>
1419
1420         Reviewed by James Robinson.
1421
1422         [chromium] Implement CCLayerTreeHost and CCLayerTreeHostImpl portions of threaded compositor
1423         https://bugs.webkit.org/show_bug.cgi?id=58408
1424
1425         Create CCLayerTreeHost and CCLayerTreeHostImpl, which are the main
1426         thread and compositor thread halves of a composited view. Communication
1427         between the two is based on the design used in FileStreamProxy.
1428
1429         * WebCore.gypi:
1430         * platform/chromium/TraceEvent.h:
1431         * platform/graphics/chromium/LayerRendererChromium.cpp:
1432         (WebCore::LayerRendererChromium::create):
1433         (WebCore::LayerRendererChromium::LayerRendererChromium):
1434         (WebCore::LayerRendererChromium::setViewport):
1435         (WebCore::LayerRendererChromium::updateLayers):
1436         (WebCore::LayerRendererChromium::drawLayers):
1437         (WebCore::LayerRendererChromiumImpl::create):
1438         (WebCore::LayerRendererChromiumImpl::drawLayersAndPresent):
1439         (WebCore::LayerRendererChromiumImpl::LayerRendererChromiumImpl):
1440         (WebCore::LayerRendererChromiumImpl::drawLayersOnMainThread):
1441         (WebCore::LayerRendererChromiumImplProxy::create):
1442         (WebCore::LayerRendererChromiumImplProxy::createLayerTreeHostImpl):
1443         (WebCore::LayerRendererChromiumImplProxy::LayerRendererChromiumImplProxy):
1444         (WebCore::LayerRendererChromium::createLayerTreeHostImplProxy):
1445         * platform/graphics/chromium/LayerRendererChromium.h:
1446         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
1447         (WebCore::CCHeadsUpDisplay::setShowFPSCounter):
1448         (WebCore::CCHeadsUpDisplay::setShowPlatformLayerTree):
1449         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
1450         (WebCore::CCHeadsUpDisplay::currentFrameNumber):
1451         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
1452         (WebCore::CCLayerTreeHost::CCLayerTreeHost):
1453         (WebCore::CCLayerTreeHost::init):
1454         (WebCore::CCLayerTreeHost::~CCLayerTreeHost):
1455         (WebCore::CCLayerTreeHost::beginCommit):
1456         (WebCore::CCLayerTreeHost::commitComplete):
1457         (WebCore::CCLayerTreeHost::animateAndLayout):
1458         (WebCore::CCLayerTreeHost::createLayerTreeHostCommitter):
1459         (WebCore::CCLayerTreeHost::setNeedsCommitAndRedraw):
1460         (WebCore::CCLayerTreeHost::setNeedsRedraw):
1461         (WebCore::CCLayerTreeHost::updateLayers):
1462         * platform/graphics/chromium/cc/CCLayerTreeHost.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
1463         (WebCore::CCLayerTreeHost::frameNumber):
1464         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.cpp: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
1465         (WebCore::CCLayerTreeHostCommitter::create):
1466         (WebCore::CCLayerTreeHostCommitter::commit):
1467         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
1468         (WebCore::CCLayerTreeHostCommitter::CCLayerTreeHostCommitter):
1469         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp: Added.
1470         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
1471         (WebCore::CCLayerTreeHostImpl::~CCLayerTreeHostImpl):
1472         (WebCore::CCLayerTreeHostImpl::beginCommit):
1473         (WebCore::CCLayerTreeHostImpl::commitComplete):
1474         (WebCore::CCLayerTreeHostImpl::drawLayers):
1475         (WebCore::CCLayerTreeHostImpl::setNeedsCommitAndRedraw):
1476         (WebCore::CCLayerTreeHostImpl::setNeedsRedraw):
1477         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCThread.cpp.
1478         (WebCore::CCLayerTreeHostImplClient::~CCLayerTreeHostImplClient):
1479         (WebCore::CCLayerTreeHostImpl::frameNumber):
1480         (WebCore::CCLayerTreeHostImpl::sourceFrameNumber):
1481         (WebCore::CCLayerTreeHostImpl::setSourceFrameNumber):
1482         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.cpp: Added.
1483         (WebCore::CCLayerTreeHostImplProxy::CCLayerTreeHostImplProxy):
1484         (WebCore::CCLayerTreeHostImplProxy::start):
1485         (WebCore::CCLayerTreeHostImplProxy::~CCLayerTreeHostImplProxy):
1486         (WebCore::CCLayerTreeHostImplProxy::isStarted):
1487         (WebCore::CCLayerTreeHostImplProxy::setNeedsCommitAndRedraw):
1488         (WebCore::CCLayerTreeHostImplProxy::setNeedsRedraw):
1489         (WebCore::CCLayerTreeHostImplProxy::stop):
1490         (WebCore::CCLayerTreeHostImplProxy::postDrawLayersTaskOnCCThread):
1491         (WebCore::CCLayerTreeHostImplProxy::requestFrameAndCommitOnCCThread):
1492         (WebCore::CCLayerTreeHostImplProxy::isMainThread):
1493         (WebCore::CCLayerTreeHostImplProxy::isCCThread):
1494         (WebCore::CCLayerTreeHostImplProxy::requestFrameAndCommit):
1495         (WebCore::CCLayerTreeHostImplProxy::commitOnCCThread):
1496         (WebCore::CCLayerTreeHostImplProxy::drawLayersOnCCThread):
1497         (WebCore::CCLayerTreeHostImplProxy::setNeedsCommitAndRedrawOnCCThread):
1498         (WebCore::CCLayerTreeHostImplProxy::setNeedsRedrawOnCCThread):
1499         (WebCore::CCLayerTreeHostImplProxy::initImplOnCCThread):
1500         (WebCore::CCLayerTreeHostImplProxy::layerTreeHostClosedOnCCThread):
1501         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.h: Added.
1502         (WebCore::CCLayerTreeHostImplProxy::host):
1503         * platform/graphics/chromium/cc/CCMainThreadTask.h:
1504         * platform/graphics/chromium/cc/CCThread.cpp:
1505         (WebCore::CCThread::runLoop):
1506         * platform/graphics/chromium/cc/CCThreadTask.h:
1507
1508 2011-06-24  Adrienne Walker  <enne@google.com>
1509
1510         Unreviewed, remove assertion about root layers in RenderLayerBacking.
1511         https://bugs.webkit.org/show_bug.cgi?id=60741
1512
1513         This was added in r89687, but somehow is not true on Safari Leopard.
1514         However, as the tests that were added with that revision are passing
1515         correctly, the assertion is most likely not correct.
1516
1517         * rendering/RenderLayerBacking.cpp:
1518         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1519
1520 2011-06-24  Nikolas Zimmermann  <nzimmermann@rim.com>
1521
1522         Reviewed by Dirk Schulze.
1523
1524         Refactor text iterator code respecting surrogate pairs from WidthIterator
1525         https://bugs.webkit.org/show_bug.cgi?id=63319
1526
1527         WidthIterator contains a surrogate pair aware text iterator that is needed in other parts of WebCore.
1528         Refactor the code into its own SurrogatePairAwareTextIterator class. It can be used like this:
1529
1530         UChar32 character = 0;
1531         unsigned clusterLength = 0;
1532
1533         SurrogatePairAwareTextIterator textIterator(myString.characters(), 0, myString.length(), myString.length());
1534         while (textIterator.consume(character, clusterLength)) {
1535             // Either clusterLength is 1 and UChar32 fits into a single UChar.
1536             // Or     clusterLength is 2 and the UChar32 has been computed by combining the high & low surrogate pairs
1537             ...
1538         
1539             textIterator.advance(clusterLength);
1540         }
1541
1542         SVGGlyphMap is the next candidate that wants to make use of SurrogatePairAwareTextIterator.
1543         Doesn't affect any tests, just refactoring.
1544
1545         * CMakeLists.txt: Add SurrogatePairAwareTextIterator.* to build.
1546         * GNUmakefile.list.am: Ditto.
1547         * WebCore.gypi: Ditto.
1548         * WebCore.pro: Ditto.
1549         * WebCore.vcproj/WebCore.vcproj: Ditto.
1550         * WebCore.xcodeproj/project.pbxproj: Ditto.
1551         * platform/graphics/SurrogatePairAwareTextIterator.cpp: Copied from platform/graphics/WidthIterator.cpp.
1552         * platform/graphics/SurrogatePairAwareTextIterator.h: Added.
1553         (WebCore::SurrogatePairAwareTextIterator::currentCharacter):
1554         * platform/graphics/WidthIterator.cpp:
1555         (WebCore::WidthIterator::advance):
1556         * platform/graphics/WidthIterator.h:
1557
1558 2011-06-24  Adrienne Walker  <enne@google.com>
1559
1560         Reviewed by Simon Fraser.
1561
1562         Incorrect RenderLayer transforms on overflow RTL pages
1563         https://bugs.webkit.org/show_bug.cgi?id=60741
1564
1565         Fix positioning of the root graphics layer for RTL pages.  The fact
1566         that the left side of the page is negative for pages with overflow is
1567         not taken into account when calculating the position.  This negative
1568         value ends up being double-counted for the root graphics layer (once
1569         in the position and once in the offset) and it shifts child layers
1570         into the wrong place.
1571
1572         Tests: compositing/rtl/rtl-absolute-overflow-scrolled.html
1573                compositing/rtl/rtl-absolute-overflow.html
1574                compositing/rtl/rtl-absolute.html
1575                compositing/rtl/rtl-fixed-overflow-scrolled.html
1576                compositing/rtl/rtl-fixed-overflow.html
1577                compositing/rtl/rtl-fixed.html
1578                compositing/rtl/rtl-iframe-absolute-overflow-scrolled.html
1579                compositing/rtl/rtl-iframe-absolute-overflow.html
1580                compositing/rtl/rtl-iframe-absolute.html
1581                compositing/rtl/rtl-iframe-fixed-overflow-scrolled.html
1582                compositing/rtl/rtl-iframe-fixed-overflow.html
1583                compositing/rtl/rtl-iframe-fixed.html
1584                compositing/rtl/rtl-iframe-relative.html
1585                compositing/rtl/rtl-relative.html
1586
1587         * rendering/RenderLayerBacking.cpp:
1588         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1589
1590 2011-06-24  Ryosuke Niwa  <rniwa@webkit.org>
1591
1592         Reviewed by Enrica Casucci.
1593
1594         Add BeforeChildren and AfterChildren to the Position's anchor types
1595         https://bugs.webkit.org/show_bug.cgi?id=63100
1596
1597         Added PositionIsBeforeChildren and PositionIsAfterChildren to Position::AnchorType and deployed them in
1598         firstPositionInNode and lastPositionInNode.
1599
1600         These new types of positions will let us express the first and the last positions in a non-text node in O(1).
1601
1602         No new tests because there is no new behavior or feature exposed.
1603
1604         * dom/Position.cpp:
1605         (WebCore::Position::Position): Assert that the anchor type is not BeforeChildren and AfterChildren for text nodes.
1606         (WebCore::Position::containerNode): For BeforeChildren and AfterChildren, the anchor node is the container node.
1607         (WebCore::Position::computeOffsetInContainerNode): The offset in the container node is 0 for BeforeChildren and
1608         the offset in the anchor node for AfterChildren.
1609         (WebCore::Position::offsetForPositionAfterAnchor): Called by deprecatedNode; the anchor type could be AfterChildren.
1610         (WebCore::Position::parentAnchoredEquivalent): If the anchor node is before or after children, then do the trick
1611         for table and ignored contents like before or after anchor.
1612         (WebCore::Position::computeNodeBeforePosition): Returns null for BeforeChildren and returns the last child of
1613         the anchor node for AfterChildren.
1614         (WebCore::Position::computeNodeAfterPosition): Returns the first child of the anchor node for BeforeChildren
1615         (WebCore::Position::atFirstEditingPositionForNode): A position is at the last editing position if the anchor type
1616         is BeforeChildren, or the anchor type is AfterChildren or AfterAnchor and the anchor doesn't have any children.
1617         (WebCore::Position::atLastEditingPositionForNode): A position is at the last editing position if the anchor type
1618         is AfterChildren.
1619         (WebCore::Position::showAnchorTypeAndOffset): Supports BeforeChildren and AfterChildren.
1620         * dom/Position.h:
1621         (WebCore::Position::deprecatedEditingOffset): Returns m_offset if the anchor type is BeforeChildren.
1622         (WebCore::firstPositionInNode): Returns a position in offset for a text node. Otherwise returns BeforeChildren.
1623         (WebCore::lastPositionInNode): Returns a position in offset for a text node. Otherwise returns AfterChildren.
1624         * editing/CompositeEditCommand.cpp:
1625         (WebCore::CompositeEditCommand::positionOutsideTabSpan): Since the anchor node was a text node,
1626         the anchor type shouldn't be BeforeChildren or AfterChildren.
1627         * editing/DeleteSelectionCommand.cpp:
1628         (WebCore::updatePositionForNodeRemoval): Supports BeforeChildren and AfterChildren.
1629         (WebCore::DeleteSelectionCommand::handleGeneralDelete): Calls updatePositionForNodeRemoval on m_downstremEnd
1630         when its anchor node is removed instead of manually updating the offset; also avoid calling moveToOffset
1631         on BeforeChildren or AfterChildren position.
1632         * editing/FormatBlockCommand.cpp:
1633         (WebCore::FormatBlockCommand::formatRange): Since lastParagraphInBlockNode is used to insert a placeholder
1634         after paragraphs below the block is moved into, it needs to be the position after the current last child in
1635         the block instead of after children in the block; otherwise the position will move to the end of block.
1636         * editing/VisiblePosition.cpp:
1637         (WebCore::VisiblePosition::characterAfter): Since the container node is never a text for position before/after
1638         children or before/after anchor, just return null for these anchor types.
1639
1640 2011-06-24  Dominic Cooney  <dominicc@chromium.org>
1641
1642         Reviewed by Dimitri Glazkov.
1643
1644         Convert shadow DOM-related tests to use window.internals
1645         https://bugs.webkit.org/show_bug.cgi?id=61671
1646
1647         * WebCore.exp.in: Exports for symbols used by WebCoreTestSupport.
1648         * testing/Internals.cpp: The new home of shadowRoot and friends.
1649         (WebCore::Internals::ensureShadowRoot):
1650         (WebCore::Internals::shadowRoot):
1651         (WebCore::Internals::removeShadowRoot):
1652         (WebCore::Internals::shadowPseudoId):
1653         * testing/Internals.h:
1654         * testing/Internals.idl:
1655
1656 2011-06-24  Tony Chang  <tony@chromium.org>
1657
1658         Reviewed by Darin Adler.
1659
1660         Refactor creation of primitive values in CSSParser
1661         https://bugs.webkit.org/show_bug.cgi?id=63270
1662
1663         Covered by existing tests.
1664
1665         * css/CSSParser.cpp:
1666         (WebCore::CSSParser::createPrimitiveNumericValue): Helper method for creating numeric values
1667             to keep the cast in one place.
1668         (WebCore::CSSParser::createPrimitiveStringValue): Helper method for creating string values.
1669         (WebCore::CSSParser::parseValidPrimitive):
1670         (WebCore::CSSParser::parseValue):
1671         (WebCore::CSSParser::parseWCSSInputProperty):
1672         (WebCore::CSSParser::parsePage):
1673         (WebCore::CSSParser::parseSizeParameter):
1674         (WebCore::CSSParser::parseContent):
1675         (WebCore::CSSParser::parseFillPositionX):
1676         (WebCore::CSSParser::parseFillPositionY):
1677         (WebCore::CSSParser::parseFillPositionComponent):
1678         (WebCore::CSSParser::parseFillSize):
1679         (WebCore::CSSParser::parseAnimationDelay):
1680         (WebCore::CSSParser::parseAnimationDuration):
1681         (WebCore::CSSParser::parseAnimationIterationCount):
1682         (WebCore::CSSParser::parseAnimationName):
1683         (WebCore::CSSParser::parseTransformOriginShorthand):
1684         (WebCore::CSSParser::parseDashboardRegions):
1685         (WebCore::CSSParser::parseCounterContent):
1686         (WebCore::CSSParser::parseShape):
1687         (WebCore::CSSParser::parseFont):
1688         (WebCore::CSSParser::parseReflect):
1689         (WebCore::CSSParser::parseBorderRadius):
1690         (WebCore::CSSParser::parseCounter):
1691         (WebCore::CSSParser::parseDeprecatedGradient):
1692         (WebCore::CSSParser::parseLinearGradient):
1693         (WebCore::CSSParser::parseRadialGradient):
1694         (WebCore::CSSParser::parseGradientColorStops):
1695         (WebCore::CSSParser::parseTransform):
1696         (WebCore::CSSParser::parseTransformOrigin):
1697         (WebCore::CSSParser::parseTextEmphasisStyle):
1698         * css/CSSParser.h:
1699         * css/CSSPrimitiveValueCache.h:
1700         (WebCore::CSSPrimitiveValueCache::createValue): pass String by const reference
1701
1702 2011-06-24  Carlos Garcia Campos  <cgarcia@igalia.com>
1703
1704         Reviewed by Martin Robinson.
1705
1706         [GTK] Fix runtime critical warnings in WebKit2
1707         https://bugs.webkit.org/show_bug.cgi?id=63256
1708
1709         Check whether there's a view widget before trying to use it in
1710         PlatformScreenGtk. If there isn't a view widget, which is the case
1711         in WebKit2, try to use the default GdkScreen and monitor.
1712
1713         * platform/gtk/PlatformScreenGtk.cpp:
1714         (WebCore::getToplevel): Helper function to get the toplevel
1715         widget.
1716         (WebCore::getVisual): Use getToplevel().
1717         (WebCore::getScreen): Helper funtion to get the screen of a
1718         widget.
1719         (WebCore::screenRect): Use getToplevel() and getScreen().
1720
1721 2011-06-24  Yuta Kitamura  <yutak@chromium.org>
1722
1723         Reviewed by Adam Barth.
1724
1725         WebSocket: Add run-time flag for new HyBi protocol
1726         https://bugs.webkit.org/show_bug.cgi?id=60348
1727
1728         Add a flag in Setting so that WebSocket protocols can be switched
1729         dynamically. The protocol we have implemented so far is based on
1730         older Hixie-76 specification. A new protocol is being discussed in
1731         IETF HyBi working group, and I'm planning to implement the new protocol
1732         behind this Settings flag.
1733
1734         I will add a method to LayoutTestController which flips this flag in
1735         a later patch. In this way, we can put tests for both protocols in
1736         the same place and test implementation for both protocols at the same time.
1737
1738         This patch only adds a flag. The flag is not used yet, thus there is
1739         no change in functionality. Therefore, no tests were added.
1740
1741         * page/Settings.cpp:
1742         (WebCore::Settings::Settings):
1743         * page/Settings.h:
1744         (WebCore::Settings::setUseHixie76WebSocketProtocol):
1745         (WebCore::Settings::useHixie76WebSocketProtocol):
1746
1747 2011-06-23  Mikhail Naganov  <mnaganov@chromium.org>
1748
1749         Reviewed by Pavel Feldman.
1750
1751         Web Inspector: [Chromium] Shorten DOMWindow URLs in heap profiles.
1752         https://bugs.webkit.org/show_bug.cgi?id=63238
1753
1754         * inspector/front-end/DetailedHeapshotGridNodes.js:
1755         (WebInspector.HeapSnapshotGridNode.prototype.hasHoverMessage.false.hoverMessage):
1756         (WebInspector.HeapSnapshotGenericObjectNode):
1757         (WebInspector.HeapSnapshotGenericObjectNode.prototype.hoverMessage):
1758         (WebInspector.HeapSnapshotGenericObjectNode.prototype._updateHasChildren):
1759         (WebInspector.HeapSnapshotGenericObjectNode.prototype.isDOMWindow):
1760         (WebInspector.HeapSnapshotGenericObjectNode.prototype.shortenWindowURL):
1761         * inspector/front-end/DetailedHeapshotView.js:
1762         (WebInspector.HeapSnapshotRetainingPathsList.prototype.showNext.pathFound):
1763         (WebInspector.DetailedHeapshotView.prototype._getHoverAnchor):
1764         (WebInspector.DetailedHeapshotView.prototype._showStringContentPopup.displayString):
1765         (WebInspector.DetailedHeapshotView.prototype._showStringContentPopup):
1766         * inspector/front-end/utilities.js:
1767         ():
1768
1769 2011-06-24  Vsevolod Vlasov  <vsevik@chromium.org>
1770
1771         Reviewed by Pavel Feldman.
1772
1773         Web Inspector: HTML preview should delete old iframe on show().
1774         https://bugs.webkit.org/show_bug.cgi?id=63170
1775
1776         * inspector/front-end/ResourceHTMLView.js:
1777         (WebInspector.ResourceHTMLView.prototype._createIFrame):
1778         * inspector/front-end/ResourcePreviewView.js:
1779         (WebInspector.ResourcePreviewView.prototype.contentLoaded):
1780
1781 2011-06-24  Dirk Schulze  <krit@webkit.org>
1782
1783         Reviewed by Nikolas Zimmermann.
1784
1785         Convert AnimatedString to SVGAnimatorFactory concept
1786         https://bugs.webkit.org/show_bug.cgi?id=63296
1787
1788         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
1789         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGString.
1790
1791         No new tests added. No change of functionality.
1792
1793         * CMakeLists.txt: Added new file to build system.
1794         * GNUmakefile.list.am: Ditto.
1795         * WebCore.gypi: Ditto.
1796         * WebCore.pro: Ditto.
1797         * WebCore.xcodeproj/project.pbxproj: Ditto.
1798         * svg/SVGAllInOne.cpp: Ditto.
1799         * svg/SVGAnimateElement.cpp:
1800         (WebCore::SVGAnimateElement::calculateAnimatedValue):
1801         (WebCore::SVGAnimateElement::calculateFromAndToValues):
1802         (WebCore::SVGAnimateElement::calculateFromAndByValues):
1803         (WebCore::SVGAnimateElement::resetToBaseValue):
1804         (WebCore::SVGAnimateElement::applyResultsToTarget):
1805         (WebCore::SVGAnimateElement::calculateDistance):
1806         * svg/SVGAnimateElement.h:
1807         * svg/SVGAnimatedString.cpp: Added. Animator for SVGString.
1808         (WebCore::SVGAnimatedStringAnimator::SVGAnimatedStringAnimator):
1809         (WebCore::SVGAnimatedStringAnimator::constructFromString):
1810         (WebCore::SVGAnimatedStringAnimator::calculateFromAndToValues):
1811         (WebCore::SVGAnimatedStringAnimator::calculateFromAndByValues):
1812         (WebCore::SVGAnimatedStringAnimator::calculateAnimatedValue):
1813         (WebCore::SVGAnimatedStringAnimator::calculateDistance):
1814         * svg/SVGAnimatedString.h:
1815         (WebCore::SVGAnimatedStringAnimator::~SVGAnimatedStringAnimator):
1816         * svg/SVGAnimatedType.cpp:
1817         (WebCore::SVGAnimatedType::~SVGAnimatedType):
1818         (WebCore::SVGAnimatedType::createString):
1819         (WebCore::SVGAnimatedType::string):
1820         (WebCore::SVGAnimatedType::valueAsString):
1821         (WebCore::SVGAnimatedType::setValueAsString):
1822         * svg/SVGAnimatedType.h:
1823         * svg/SVGAnimatorFactory.h:
1824         (WebCore::SVGAnimatorFactory::create):
1825
1826 2011-06-24  Mario Sanchez Prada  <msanchez@igalia.com>
1827
1828         Reviewed by Chris Fleizach.
1829
1830         [GTK] Consider rows being ignored when adding children to tables
1831         https://bugs.webkit.org/show_bug.cgi?id=62718
1832
1833         Hide row objects in tables in GTK's accessibility wrapper.
1834
1835         This is a different approach in the way WebCore's accessible
1836         rows are exposed to assistive technologies in the GTK port,
1837         since from now on those objects are kept in WebCore (they do not
1838         declare to ignore accessibility) and just bypassed in the mapping
1839         to ATK, allowing to hide them in the ATK hierarchy while, at the
1840         same time, keeping them internally to be able to provide enough
1841         information to determine tables related information, such as rows
1842         counting or finding an cell for specific coordinates.
1843
1844         * accessibility/gtk/AccessibilityObjectAtk.cpp:
1845         (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
1846         Do not ignore accessibility for table rows here.
1847
1848         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
1849         (webkit_accessible_get_parent): Bypass rows when needed.
1850         (getNChildrenForTable): New, find the number of children for a
1851         table, which will be the addition of all cells for its rows.
1852         (webkit_accessible_get_n_children): Call to getNChildrenForTable
1853         for accessibility tables if needed.
1854         (getChildForTable): New, bypass rows when needed, retrieving
1855         cells as if they were direct children for tables.
1856         (webkit_accessible_ref_child): Call to refChildForTable if needed.
1857         (getIndexInParentForCellInRow): New, get the index for a given
1858         cell in its parent table, considering other rows' cells.
1859         (webkit_accessible_get_index_in_parent): Call to
1860         getIndexInParentForCellInRow if needed.
1861
1862 2011-06-24  Andrey Kosyakov  <caseq@chromium.org>
1863
1864         Reviewed by Yury Semikhatsky.
1865
1866         Web Inspector: extension panel iframes do not span entire panel client area
1867         https://bugs.webkit.org/show_bug.cgi?id=63165
1868
1869         * inspector/front-end/ExtensionServer.js:
1870         (WebInspector.ExtensionServer.prototype._onCreatePanel):
1871         (WebInspector.ExtensionServer.prototype.createClientIframe):
1872         * inspector/front-end/inspector.css:
1873         (iframe.extension):
1874         (iframe.panel.extension):
1875
1876 2011-06-24  David Grogan  <dgrogan@chromium.org>
1877
1878         Reviewed by Pavel Feldman.
1879
1880         Web Inspector: [REGRESSION r86838] line numbers do not scroll when script paused
1881         https://bugs.webkit.org/show_bug.cgi?id=61653
1882
1883         roll out r86838
1884
1885         No new tests - refactoring.
1886
1887         * dom/Document.h:
1888         * dom/EventQueue.cpp:
1889         (WebCore::EventQueueTimer::EventQueueTimer):
1890         (WebCore::EventQueueTimer::fired):
1891         (WebCore::EventQueue::create):
1892         (WebCore::EventQueue::EventQueue):
1893         (WebCore::EventQueue::~EventQueue):
1894         (WebCore::EventQueue::enqueueEvent):
1895         (WebCore::EventQueue::cancelEvent):
1896         (WebCore::EventQueue::cancelQueuedEvents):
1897         (WebCore::EventQueue::pendingEventTimerFired):
1898         (WebCore::EventQueue::dispatchEvent):
1899         * dom/EventQueue.h:
1900
1901 2011-06-24  Sheriff Bot  <webkit.review.bot@gmail.com>
1902
1903         Unreviewed, rolling out r89594.
1904         http://trac.webkit.org/changeset/89594
1905         https://bugs.webkit.org/show_bug.cgi?id=63316
1906
1907         It broke 5 tests on the Qt bot (Requested by Ossy_DC on
1908         #webkit).
1909
1910         * WebCore.exp.in:
1911         * icu/unicode/uscript.h:
1912         * page/Settings.cpp:
1913         (WebCore::Settings::setStandardFontFamily):
1914         (WebCore::Settings::setFixedFontFamily):
1915         (WebCore::Settings::setSerifFontFamily):
1916         (WebCore::Settings::setSansSerifFontFamily):
1917         (WebCore::Settings::setCursiveFontFamily):
1918         (WebCore::Settings::setFantasyFontFamily):
1919         * page/Settings.h:
1920         (WebCore::Settings::standardFontFamily):
1921         (WebCore::Settings::fixedFontFamily):
1922         (WebCore::Settings::serifFontFamily):
1923         (WebCore::Settings::sansSerifFontFamily):
1924         (WebCore::Settings::cursiveFontFamily):
1925         (WebCore::Settings::fantasyFontFamily):
1926
1927 2011-06-23  Tony Chang  <tony@chromium.org>
1928
1929         Reviewed by Kent Tamura.
1930
1931         Pass Strings by const reference in bindings code
1932         https://bugs.webkit.org/show_bug.cgi?id=63302
1933
1934         Note that since Strings hold a RefPtr to StringImpl, passing Strings
1935         by value isn't horrible, but it does cause ref count churn and using
1936         const references is more consistent with the rest of the code base.
1937
1938         * bindings/generic/BindingSecurity.h:
1939         (WebCore::::allowSettingFrameSrcToJavascriptUrl):
1940         (WebCore::::allowSettingSrcToJavascriptURL):
1941         * bindings/js/SerializedScriptValue.cpp:
1942         (WebCore::CloneSerializer::serialize):
1943         (WebCore::SerializedScriptValue::create):
1944         * bindings/js/SerializedScriptValue.h:
1945         * bindings/v8/SerializedScriptValue.cpp:
1946         (WebCore::SerializedScriptValue::createFromWire):
1947         (WebCore::SerializedScriptValue::create):
1948         (WebCore::SerializedScriptValue::SerializedScriptValue):
1949         * bindings/v8/SerializedScriptValue.h:
1950         * bindings/v8/V8Binding.h:
1951         (WebCore::V8ParameterBase::setString):
1952
1953 2011-06-23  Yury Semikhatsky  <yurys@chromium.org>
1954
1955         Reviewed by Pavel Feldman.
1956
1957         [Chromium] Web Inspector: provide context menu item for enabling native worker inspection
1958         https://bugs.webkit.org/show_bug.cgi?id=63258
1959
1960         Added context menu checkbox item that allows to enable inspection of
1961         native workers. The value will be persisted as other inspector settings
1962         and will be restored after frontend/breowser reopening.
1963
1964         * inspector/Inspector.json:
1965         * inspector/InspectorController.cpp:
1966         (WebCore::InspectorController::restoreInspectorStateFromCookie):
1967         * inspector/InspectorInstrumentation.h:
1968         (WebCore::InspectorInstrumentation::didStartWorkerContext):
1969         * inspector/InspectorWorkerAgent.cpp:
1970         (WebCore::InspectorWorkerAgent::setFrontend):
1971         (WebCore::InspectorWorkerAgent::restore):
1972         (WebCore::InspectorWorkerAgent::setWorkerInspectionEnabled):
1973         * inspector/InspectorWorkerAgent.h:
1974         * inspector/front-end/ScriptsPanel.js:
1975         (WebInspector.ScriptsPanel):
1976         (WebInspector.ScriptsPanel.prototype.reset):
1977         (WebInspector.ScriptsPanel.prototype._toggleFormatSourceFiles):
1978         (WebInspector.ScriptsPanel.prototype._contextMenu.enableWorkerInspection):
1979         (WebInspector.ScriptsPanel.prototype._contextMenu):
1980         * inspector/front-end/Settings.js:
1981         (WebInspector.Settings):
1982         * inspector/front-end/inspector.js:
1983         (WebInspector.didCreateWorker):
1984         (WebInspector.didDestroyWorker):
1985         * workers/Worker.cpp:
1986         (WebCore::Worker::notifyFinished):
1987
1988 2011-06-23  Simon Fraser  <simon.fraser@apple.com>
1989
1990         Reviewed by Dan Bernstein.
1991
1992         Need to turn off default animations for anchorPointZ in PlatformCALayer
1993         https://bugs.webkit.org/show_bug.cgi?id=63159
1994         
1995         When the z-component of transform-origin changed, we ran an implicit
1996         animation of anchorPointZ on the CALayer. Turn this off.
1997
1998         Test: transforms/3d/general/transform-origin-z-change.html
1999
2000         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
2001         (nullActionsDictionary):
2002
2003 2011-06-23  Zhenyao Mo  <zmo@google.com>
2004
2005         Reviewed by Kenneth Russell.
2006
2007         Limit WebGL internal drawingBuffer size to 4k x 4k
2008         https://bugs.webkit.org/show_bug.cgi?id=63304
2009
2010         * html/canvas/WebGLRenderingContext.cpp:
2011         (WebCore::WebGLRenderingContext::reshape): Limit drawing buffer size to 4k x 4k.
2012
2013 2011-06-20  MORITA Hajime  <morrita@google.com>
2014
2015         Reviewed by Dimitri Glazkov.
2016
2017         [ShadowContentElement] should layout child whitespace between span.
2018         https://bugs.webkit.org/show_bug.cgi?id=62202
2019
2020         NodeRenderingContext::nextRenderer() and previousRenderer()
2021         ignored forwarded content tree hierarchies and used render-object
2022         hierarchies instead, that caused some wrong Text node rendering.
2023         
2024         This change uses ShadowContentElement::m_inclusions for the lookup.
2025         In this way, these methods can reflect hierarchies of forward light tree.
2026         
2027         * dom/NodeRenderingContext.cpp:
2028         (WebCore::NodeRenderingContext::NodeRenderingContext):
2029         (WebCore::nextRendererOf): Added. This traverses content element's children for searching neighboring renderer.
2030         (WebCore::previousRendererOf): Added. This traverses content element's children for searching neighboring renderer.
2031         (WebCore::NodeRenderingContext::nextRenderer):
2032         (WebCore::NodeRenderingContext::previousRenderer):
2033         * dom/NodeRenderingContext.h:
2034         * dom/ShadowContentElement.h:
2035         (ShadowContentElement::inclusionIndexOf): Added.
2036         * dom/ShadowContentSelector.cpp:
2037         (WebCore::ShadowContentSelector::activeElement):
2038         * dom/ShadowContentSelector.h:
2039         * dom/ShadowRoot.cpp:
2040         (WebCore::ShadowRoot::activeContentElement):
2041         * dom/ShadowRoot.h:
2042         * rendering/RenderTreeAsText.cpp: 
2043         (WebCore::externalRepresentation): Fixed an apparent bug introduced at r89230.
2044
2045 2011-05-25  James Robinson  <jamesr@chromium.org>
2046
2047         Reviewed by Kenneth Russell.
2048
2049         [chromium] Fix ownership of PlatformImage for ImageLayerChromiums
2050         https://bugs.webkit.org/show_bug.cgi?id=61099
2051
2052         For a composited image, both the ImageLayerChromium and its associated LayerTilerChromium need access to a
2053         PlatformImage - the ImageLayerChromium has to update the PlatformImage's contents and the LayerTilerChromium has
2054         to upload pixels from it.  This patch makes the ImageLayerTextureUpdater have exclusive ownership of the
2055         PlatformImage and moves ownership of the LayerTextureUpdater from the LayerTilerChromium to the owner of the
2056         tiler.  The updater is passed in as a parameter to the relevant tiler calls.
2057
2058         Patch also fixes a number of minor style issues (missing explicit keyword on constructor, etc).
2059
2060         Refactor only, no new tests.
2061
2062         * platform/graphics/chromium/ContentLayerChromium.cpp:
2063         (WebCore::ContentLayerPainter::create):
2064         (WebCore::ContentLayerPainter::ContentLayerPainter):
2065         (WebCore::ContentLayerChromium::paintContentsIfDirty):
2066         (WebCore::ContentLayerChromium::createTextureUpdaterIfNeeded):
2067         (WebCore::ContentLayerChromium::draw):
2068         (WebCore::ContentLayerChromium::createTilerIfNeeded):
2069         (WebCore::ContentLayerChromium::updateCompositorResources):
2070         * platform/graphics/chromium/ContentLayerChromium.h:
2071         * platform/graphics/chromium/ImageLayerChromium.cpp:
2072         (WebCore::ImageLayerTextureUpdater::create):
2073         (WebCore::ImageLayerTextureUpdater::updateFromImage):
2074         (WebCore::ImageLayerTextureUpdater::imageSize):
2075         (WebCore::ImageLayerTextureUpdater::ImageLayerTextureUpdater):
2076         (WebCore::ImageLayerChromium::~ImageLayerChromium):
2077         (WebCore::ImageLayerChromium::paintContentsIfDirty):
2078         (WebCore::ImageLayerChromium::updateCompositorResources):
2079         (WebCore::ImageLayerChromium::setLayerRenderer):
2080         (WebCore::ImageLayerChromium::createTextureUpdaterIfNeeded):
2081         (WebCore::ImageLayerChromium::layerBounds):
2082         * platform/graphics/chromium/ImageLayerChromium.h:
2083         * platform/graphics/chromium/LayerRendererChromium.cpp:
2084         (WebCore::LayerRendererChromium::LayerRendererChromium):
2085         (WebCore::LayerRendererChromium::updateRootLayerContents):
2086         (WebCore::LayerRendererChromium::drawRootLayer):
2087         (WebCore::LayerRendererChromium::updateLayers):
2088         * platform/graphics/chromium/LayerRendererChromium.h:
2089         * platform/graphics/chromium/LayerTextureUpdater.h:
2090         (WebCore::LayerTextureUpdater::LayerTextureUpdater):
2091         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
2092         (WebCore::LayerTextureUpdaterBitmap::create):
2093         (WebCore::LayerTextureUpdaterSkPicture::create):
2094         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
2095         * platform/graphics/chromium/LayerTilerChromium.cpp:
2096         (WebCore::LayerTilerChromium::create):
2097         (WebCore::LayerTilerChromium::LayerTilerChromium):
2098         (WebCore::LayerTilerChromium::prepareToUpdate):
2099         (WebCore::LayerTilerChromium::updateRect):
2100         (WebCore::LayerTilerChromium::draw):
2101         * platform/graphics/chromium/LayerTilerChromium.h:
2102
2103 2011-06-23  Adrienne Walker  <enne@google.com>
2104
2105         Unreviewed, rolling out r89632 and r89640.
2106         http://trac.webkit.org/changeset/89632
2107         http://trac.webkit.org/changeset/89640
2108         https://bugs.webkit.org/show_bug.cgi?id=60741
2109
2110         Breaks ancestor-overflow-change unexpectedly
2111
2112         * rendering/RenderLayerBacking.cpp:
2113         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2114
2115 2011-06-23  John Bates  <jbates@google.com>
2116
2117         Reviewed by James Robinson.
2118
2119         Fix latch deadlock when GPU process crashes or context is lost.
2120         https://bugs.webkit.org/show_bug.cgi?id=63189
2121         The main bug fix is to only set/wait latches if the child context has no errors.
2122         Additionally, the LayerChromium classes needed to be modified to not continue drawing when
2123         their corresponding contexts have errors. Otherwise, they would draw with invalid texture ids.
2124
2125         Test: open particles WebGL demo in chrome, kill GPU process from Task Manager; observe no deadlock.
2126
2127         * platform/graphics/chromium/LayerRendererChromium.cpp:
2128         (WebCore::LayerRendererChromium::LayerRendererChromium):
2129         (WebCore::LayerRendererChromium::updateAndDrawLayers):
2130         (WebCore::LayerRendererChromium::updateLayers):
2131         (WebCore::LayerRendererChromium::isCompositorContextLost):
2132         * platform/graphics/chromium/LayerRendererChromium.h:
2133         * platform/graphics/chromium/WebGLLayerChromium.cpp:
2134         (WebCore::WebGLLayerChromium::drawsContent):
2135         (WebCore::WebGLLayerChromium::updateCompositorResources):
2136         (WebCore::WebGLLayerChromium::setContext):
2137         * platform/graphics/chromium/WebGLLayerChromium.h:
2138         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
2139         (WebCore::Canvas2DLayerChromium::drawsContent):
2140         * platform/graphics/chromium/Canvas2DLayerChromium.h:
2141
2142 2011-06-23  Alok Priyadarshi  <alokp@chromium.org>
2143
2144         Reviewed by James Robinson.
2145
2146         [chromium] Red and Blue channels are swapped in images with accelerated drawing
2147         https://bugs.webkit.org/show_bug.cgi?id=61442
2148
2149         We were uploading BGRA pixels into RGBA textures and swapping the components in the pixel shader.
2150         This strategy does not work with accelerated drawing because we are directly rendering to the texture, not uploading pixels.
2151         This patch uses BGRA textures if available. If not it falls back to the original scheme of swapping the components in the pixel shader. 
2152
2153         Tests: compositing/color-matching/image-color-matching.html (existing)
2154
2155         * WebCore.gypi:
2156         * platform/graphics/chromium/ImageLayerChromium.cpp:
2157         (WebCore::ImageLayerTextureUpdater::sampledTexelFormat):
2158         (WebCore::ImageLayerTextureUpdater::updateTextureRect):
2159         * platform/graphics/chromium/LayerRendererChromium.cpp:
2160         (WebCore::LayerRendererChromium::LayerRendererChromium):
2161         (WebCore::LayerRendererChromium::skiaContext):
2162         (WebCore::LayerRendererChromium::tilerProgram):
2163         (WebCore::LayerRendererChromium::tilerProgramSwizzle):
2164         (WebCore::LayerRendererChromium::cleanupSharedObjects):
2165         * platform/graphics/chromium/LayerRendererChromium.h:
2166         * platform/graphics/chromium/LayerTexture.h:
2167         (WebCore::LayerTexture::format):
2168         * platform/graphics/chromium/LayerTextureSubImage.cpp:
2169         (WebCore::LayerTextureSubImage::upload):
2170         (WebCore::LayerTextureSubImage::uploadWithTexSubImage):
2171         (WebCore::LayerTextureSubImage::uploadWithMapTexSubImage):
2172         * platform/graphics/chromium/LayerTextureSubImage.h:
2173         * platform/graphics/chromium/LayerTextureUpdater.h:
2174         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
2175         (WebCore::LayerTextureUpdaterBitmap::sampledTexelFormat):
2176         (WebCore::LayerTextureUpdaterBitmap::updateTextureRect):
2177         (WebCore::LayerTextureUpdaterSkPicture::sampledTexelFormat):
2178         (WebCore::LayerTextureUpdaterSkPicture::createFrameBuffer):
2179         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
2180         * platform/graphics/chromium/LayerTilerChromium.cpp:
2181         (WebCore::LayerTilerChromium::LayerTilerChromium):
2182         (WebCore::LayerTilerChromium::prepareToUpdate):
2183         (WebCore::LayerTilerChromium::updateRect):
2184         (WebCore::LayerTilerChromium::draw):
2185         (WebCore::LayerTilerChromium::growLayerToContain):
2186         (WebCore::LayerTilerChromium::drawTiles):
2187         (WebCore::LayerTilerChromium::drawTexturedQuad):
2188         * platform/graphics/chromium/LayerTilerChromium.h:
2189         * platform/graphics/chromium/PlatformColor.h: Added.
2190         (WebCore::PlatformColor::format):
2191         (WebCore::PlatformColor::bestTextureFormat):
2192         (WebCore::PlatformColor::sameComponentOrder):
2193         * platform/graphics/chromium/ShaderChromium.cpp:
2194         (WebCore::FragmentShaderRGBATexSwizzleAlpha::getShaderString):
2195         * platform/graphics/chromium/ShaderChromium.h:
2196         * platform/graphics/chromium/cc/CCHeadsUpDisplay.h:
2197
2198 2011-06-23  Adrienne Walker  <enne@google.com>
2199
2200         Reviewed by Simon Fraser.
2201
2202         Incorrect RenderLayer transforms on overflow RTL pages
2203         https://bugs.webkit.org/show_bug.cgi?id=60741
2204
2205         Fix positioning of the root graphics layer for RTL pages.  The fact
2206         that the left side of the page is negative for pages with overflow is
2207         not taken into account when calculating the position.  This negative
2208         value ends up being double-counted for the root graphics layer (once
2209         in the position and once in the offset) and it shifts child layers
2210         into the wrong place.
2211
2212         Tests: compositing/rtl/rtl-absolute-overflow-scrolled.html
2213                compositing/rtl/rtl-absolute-overflow.html
2214                compositing/rtl/rtl-absolute.html
2215                compositing/rtl/rtl-fixed-overflow-scrolled.html
2216                compositing/rtl/rtl-fixed-overflow.html
2217                compositing/rtl/rtl-fixed.html
2218                compositing/rtl/rtl-iframe-absolute-overflow-scrolled.html
2219                compositing/rtl/rtl-iframe-absolute-overflow.html
2220                compositing/rtl/rtl-iframe-absolute.html
2221                compositing/rtl/rtl-iframe-fixed-overflow-scrolled.html
2222                compositing/rtl/rtl-iframe-fixed-overflow.html
2223                compositing/rtl/rtl-iframe-fixed.html
2224                compositing/rtl/rtl-iframe-relative.html
2225                compositing/rtl/rtl-relative.html
2226
2227         * rendering/RenderLayerBacking.cpp:
2228         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2229
2230 2011-06-23  Emil A Eklund  <eae@chromium.org>
2231
2232         Reviewed by Eric Seidel.
2233
2234         FloatRect should implement the same methods as IntRect
2235         https://bugs.webkit.org/show_bug.cgi?id=63273
2236         
2237         Add missing methods from IntRect to FloatRect in preparation for moving
2238         the rendering tree over to floats.
2239
2240         * platform/graphics/FloatPoint.h:
2241         (WebCore::FloatPoint::expandedTo):
2242         (WebCore::FloatPoint::transposedPoint):
2243         * platform/graphics/FloatRect.h:
2244         (WebCore::FloatRect::move):
2245         (WebCore::FloatRect::expand):
2246         (WebCore::FloatRect::contract):
2247         (WebCore::FloatRect::shiftXEdgeTo):
2248         (WebCore::FloatRect::shiftMaxXEdgeTo):
2249         (WebCore::FloatRect::shiftYEdgeTo):
2250         (WebCore::FloatRect::shiftMaxYEdgeTo):
2251         (WebCore::FloatRect::minXMinYCorner):
2252         (WebCore::FloatRect::maxXMinYCorner):
2253         (WebCore::FloatRect::minXMaxYCorner):
2254         (WebCore::FloatRect::maxXMaxYCorner):
2255         (WebCore::FloatRect::transposedRect):
2256         * platform/graphics/FloatSize.h:
2257         (WebCore::FloatSize::expand):
2258         (WebCore::FloatSize::transposedSize):
2259
2260 2011-06-23  Emil A Eklund  <eae@chromium.org>
2261
2262         Reviewed by Darin Adler.
2263
2264         input/textarea onchange doesn't fire if value is set in key listener
2265         https://bugs.webkit.org/show_bug.cgi?id=63092
2266
2267         Change setValue implementation of HTMLInputElement and HTMLTextAreaElement to
2268         not call setTextAsOfLastFormControlChangeEvent unless the value truly changed.
2269         Thus element.value = element.value will no longer reset the state 
2270         m_textAsOfLastFormControlChangeEvent field and suppress the change event.
2271
2272         Test: fast/events/onchange-setvalue.html
2273
2274         * html/HTMLInputElement.cpp:
2275         (WebCore::HTMLInputElement::setValue):
2276         * html/HTMLTextAreaElement.cpp:
2277         (WebCore::HTMLTextAreaElement::setValue):
2278         (WebCore::HTMLTextAreaElement::setNonDirtyValue):
2279         (WebCore::HTMLTextAreaElement::setValueCommon):
2280
2281 2011-06-23  Alexis Menard  <alexis.menard@openbossa.org>
2282
2283         Reviewed by Eric Carlson.
2284
2285         [Qt] Implement fullscreen support on Mac with the QuickTime backend.
2286         https://bugs.webkit.org/show_bug.cgi?id=61728
2287
2288         Implement fullscreen support for Qt when using the QuickTime backend.
2289         We mostly use what is already done for the Mac port.
2290
2291         * DerivedSources.pro: We use the mac files and they have <WebCore/x> type
2292         of includes. We need to generate those headers.
2293         * WebCore.pro:
2294         * platform/mac/WebVideoFullscreenController.h:
2295         * platform/mac/WebVideoFullscreenController.mm:
2296         * platform/mac/WebVideoFullscreenHUDWindowController.h:
2297         * platform/mac/WebVideoFullscreenHUDWindowController.mm:
2298         * platform/qt/WebCoreSystemInterface.h:
2299         * platform/qt/WebCoreSystemInterface.mm:
2300
2301 2011-06-23  Darin Adler  <darin@apple.com>
2302
2303         Reviewed by Ryosuke Niwa.
2304
2305         RefPtr misused as argument type in a few classes
2306         https://bugs.webkit.org/show_bug.cgi?id=62955
2307
2308         * dom/DataTransferItem.cpp:
2309         (WebCore::DataTransferItem::DataTransferItem):
2310         * dom/DataTransferItem.h:
2311         * dom/DataTransferItems.cpp:
2312         (WebCore::DataTransferItems::DataTransferItems):
2313         * dom/DataTransferItems.h:
2314         * editing/CompositeEditCommand.cpp:
2315         (WebCore::CompositeEditCommand::rebalanceWhitespaceOnTextSubstring):
2316         * editing/CompositeEditCommand.h:
2317         * page/WebKitAnimationList.cpp:
2318         (WebCore::WebKitAnimationList::append):
2319         (WebCore::WebKitAnimationList::insertAnimation):
2320         * page/WebKitAnimationList.h:
2321         * svg/graphics/filters/SVGFEImage.cpp:
2322         (WebCore::FEImage::FEImage):
2323         (WebCore::FEImage::create):
2324         * svg/graphics/filters/SVGFEImage.h:
2325         * svg/graphics/filters/SVGFilterBuilder.cpp:
2326         (WebCore::SVGFilterBuilder::SVGFilterBuilder):
2327         (WebCore::SVGFilterBuilder::add):
2328         (WebCore::SVGFilterBuilder::appendEffectToEffectReferences):
2329         * svg/graphics/filters/SVGFilterBuilder.h:
2330         * websockets/ThreadableWebSocketChannelClientWrapper.cpp:
2331         (WebCore::ThreadableWebSocketChannelClientWrapper::didConnectCallback):
2332         (WebCore::ThreadableWebSocketChannelClientWrapper::didReceiveMessageCallback):
2333         (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshakeCallback):
2334         (WebCore::ThreadableWebSocketChannelClientWrapper::didCloseCallback):
2335         * websockets/ThreadableWebSocketChannelClientWrapper.h:
2336         * websockets/WorkerThreadableWebSocketChannel.cpp:
2337         (WebCore::WorkerThreadableWebSocketChannel::Peer::Peer):
2338         (WebCore::WorkerThreadableWebSocketChannel::Bridge::setWebSocketChannel):
2339         (WebCore::WorkerThreadableWebSocketChannel::Bridge::mainThreadCreateWebSocketChannel):
2340         * websockets/WorkerThreadableWebSocketChannel.h:
2341         Use PassRefPtr or raw pointer as appropriate for RefPtr arguments.
2342
2343 2011-06-23  Sheriff Bot  <webkit.review.bot@gmail.com>
2344
2345         Unreviewed, rolling out r89591 and r89593.
2346         http://trac.webkit.org/changeset/89591
2347         http://trac.webkit.org/changeset/89593
2348         https://bugs.webkit.org/show_bug.cgi?id=63279
2349
2350         Caused test crashes in SL and Chromium (Requested by dimich_
2351         on #webkit).
2352
2353         * accessibility/AXObjectCache.cpp:
2354         (WebCore::AXObjectCache::AXObjectCache):
2355         (WebCore::AXObjectCache::remove):
2356         (WebCore::AXObjectCache::childrenChanged):
2357         * accessibility/AXObjectCache.h:
2358         * accessibility/AccessibilityMenuList.cpp:
2359         (WebCore::AccessibilityMenuList::childrenChanged):
2360         * accessibility/AccessibilityMenuList.h:
2361         * accessibility/AccessibilityMenuListPopup.cpp:
2362         (WebCore::AccessibilityMenuListPopup::childrenChanged):
2363         * accessibility/AccessibilityMenuListPopup.h:
2364         * accessibility/AccessibilityObject.h:
2365         (WebCore::AccessibilityObject::childrenChanged):
2366         * accessibility/AccessibilityRenderObject.cpp:
2367         (WebCore::startOfContinuations):
2368         (WebCore::AccessibilityRenderObject::updateAccessibilityRole):
2369         (WebCore::AccessibilityRenderObject::childrenChanged):
2370         * accessibility/AccessibilityRenderObject.h:
2371
2372 2011-06-23  Andreas Kling  <kling@webkit.org>
2373
2374         Reviewed by Benjamin Poulain.
2375
2376         [Qt] Unbreak simple font fast-path after QRawFont API changes.
2377         https://bugs.webkit.org/show_bug.cgi?id=63272
2378
2379         In the Qt 4.8 branch, the QGlyphs class has been renamed to
2380         QGlyphRun, and some other small things have been tweaked.
2381
2382         * WebCore.pro:
2383         * platform/graphics/qt/FontCacheQt.cpp:
2384         (WebCore::rawFontForCharacters):
2385         * platform/graphics/qt/FontQt.cpp:
2386         (WebCore::Font::drawGlyphs):
2387
2388 2011-06-23  Tony Chang  <tony@chromium.org>
2389
2390         Reviewed by Andreas Kling.
2391
2392         Pass Strings as const references in NetworkResourcesData.h
2393         https://bugs.webkit.org/show_bug.cgi?id=63271
2394
2395         * inspector/NetworkResourcesData.h:
2396         (WebCore::NetworkResourcesData::ResourceData::setFrameId):
2397         (WebCore::NetworkResourcesData::ResourceData::setUrl):
2398         (WebCore::NetworkResourcesData::ResourceData::setTextEncodingName):
2399
2400 2011-06-23  Jay Civelli  <jcivelli@chromium.org>
2401
2402         Reviewed by Adam Barth.
2403
2404         Fixing the SharedBufferChunkReader API so it works correctly with
2405         binary data (non printable characters).
2406         Also adding a method to peek at the data (this is needed for MHTML
2407         with binary parts).
2408         https://bugs.webkit.org/show_bug.cgi?id=63231
2409
2410         * loader/archive/mhtml/MHTMLParser.cpp:
2411         (WebCore::skipLinesUntilBoundaryFound):
2412         (WebCore::MHTMLParser::parseNextPart):
2413         * loader/archive/mhtml/MHTMLParser.h:
2414         * platform/SharedBufferChunkReader.cpp:
2415         (WebCore::SharedBufferChunkReader::SharedBufferChunkReader):
2416         (WebCore::SharedBufferChunkReader::setSeparator):
2417         (WebCore::SharedBufferChunkReader::nextChunk):
2418         (WebCore::SharedBufferChunkReader::nextChunkAsUTF8StringWithLatin1Fallback):
2419         (WebCore::SharedBufferChunkReader::peek):
2420         * platform/SharedBufferChunkReader.h:
2421         * platform/network/MIMEHeader.cpp:
2422         (WebCore::retrieveKeyValuePairs):
2423
2424 2011-06-23  Nate Chapin  <japhet@chromium.org>
2425
2426         Unreviewed.
2427
2428         Revert production code part of r89503, since it's causing
2429         crashes on WebKit2/mac and failures on qt.
2430
2431         * dom/Document.cpp:
2432         (WebCore::Document::Document):
2433         (WebCore::Document::dispatchWindowLoadEvent):
2434         * dom/Document.h:
2435         (WebCore::Document::processingLoadEvent):
2436         * loader/DocumentLoader.cpp:
2437         (WebCore::DocumentLoader::isLoadingInAPISense):
2438
2439 2011-06-23  Young Han Lee  <joybro@company100.net>
2440
2441         Reviewed by Simon Fraser.
2442
2443         runAnimationTest always fails if the pause API is enabled and the test target animation has "infinite" iteration count.
2444         https://bugs.webkit.org/show_bug.cgi?id=63152
2445
2446         The pausing conditions are modified. Now it accepts the infinite-iteration-count,
2447         but rejects the zero-iteration-count. There is no reason to consider the zero-count meaning no animation.
2448         
2449         Test: animations/keyframes-infinite-iterations.html
2450
2451         * page/animation/CompositeAnimation.cpp:
2452         (WebCore::CompositeAnimation::pauseAnimationAtTime):
2453
2454 2011-06-23  Abhishek Arya  <inferno@chromium.org>
2455
2456         Reviewed by Adam Barth.
2457
2458         RefPtr m_style in MediaQueryEvaluator in case of callers like
2459         MediaQueryMatcher::prepareEvaluator that do not retain its reference.
2460         https://bugs.webkit.org/show_bug.cgi?id=63264
2461
2462         Test: fast/css/media-query-evaluator-crash.html
2463
2464         * css/MediaQueryEvaluator.cpp:
2465         (WebCore::MediaQueryEvaluator::eval):
2466         * css/MediaQueryEvaluator.h:
2467
2468 2011-06-23  Jungshik Shin  <jshin@chromium.org>
2469
2470         Reviewed by Alexey Proskuryakov.
2471
2472         Allow generic font family settings per script code.
2473         https://bugs.webkit.org/show_bug.cgi?id=20797
2474
2475         Make generic font family getters/setters accept an additional
2476         argument (script code). It has a default value so that if an embedder
2477         does not have/want a per-script font family setting, call-sites
2478         don't have to be changed.
2479         This is to prepare for fixing bug 10874 (font selection is not
2480         language-dependent) and bug 18085.
2481
2482         uscript.h has been updated to that of ICU 3.6 (the version of ICU on
2483         Mac OS 10.5)
2484
2485         There should be no change in layout and no new layout test
2486         is added.
2487
2488         * WebCore.exp.in:
2489         * icu/unicode/uscript.h: updated to ICU 4.6
2490         * page/Settings.cpp:
2491         (WebCore::setGenericFontFamilyMap): helper to set generic family per script
2492         (WebCore::getGenericFontFamilyForScript): helper function used by getters for fooFontFamily.
2493         (WebCore::Settings::standardFontFamily):
2494         (WebCore::Settings::setStandardFontFamily):
2495         (WebCore::Settings::fixedFontFamily):
2496         (WebCore::Settings::setFixedFontFamily):
2497         (WebCore::Settings::serifFontFamily):
2498         (WebCore::Settings::setSerifFontFamily):
2499         (WebCore::Settings::sansSerifFontFamily):
2500         (WebCore::Settings::setSansSerifFontFamily):
2501         (WebCore::Settings::cursiveFontFamily):
2502         (WebCore::Settings::setCursiveFontFamily):
2503         (WebCore::Settings::fantasyFontFamily):
2504         (WebCore::Settings::setFantasyFontFamily):
2505         * page/Settings.h: setter and getter for FooFontFamily have a new optional argument, scriptCode.
2506
2507 2011-06-23  Dan Bernstein  <mitz@apple.com>
2508
2509         Reviewed by Alexey Proskuryakov.
2510
2511         Make line breaking obey the -webkit-locale property
2512         https://bugs.webkit.org/show_bug.cgi?id=63209
2513
2514         Test: platform/mac/fast/text/line-break-locale.html
2515
2516         * platform/text/TextBreakIterator.h:
2517         (WebCore::LazyLineBreakIterator::LazyLineBreakIterator): Take an optional locale identifier and
2518         initialize the m_locale member.
2519         (WebCore::LazyLineBreakIterator::get): Pass the locale to acquireLineBreakIterator().
2520         (WebCore::LazyLineBreakIterator::reset): Pass the locale to releaseLineBreakIterator() and update
2521         the m_locale member.
2522         * platform/text/TextBreakIteratorICU.cpp:
2523         (WebCore::LineBreakIteratorPool::sharedPool): Return a shared instance.
2524         (WebCore::LineBreakIteratorPool::take): Returns a text iterator for the given locale, either a newly-
2525         created one, or an existing one from the pool.
2526         (WebCore::LineBreakIteratorPool::put): Puts an iterator back into the pool, removing the least-recently used
2527         one if needed.
2528         (WebCore::LineBreakIteratorPool::LineBreakIteratorPool):
2529         (WebCore::acquireLineBreakIterator): Changed to take an optional local identifier, and to use the pool.
2530         (WebCore::releaseLineBreakIterator): Changed to use the pool.
2531         * platform/text/brew/TextBreakIteratorBrew.cpp:
2532         (WebCore::acquireLineBreakIterator): Updated for new parameter.
2533         * platform/text/gtk/TextBreakIteratorGtk.cpp:
2534         (WebCore::acquireLineBreakIterator): Ditto.
2535         * platform/text/qt/TextBreakIteratorQt.cpp:
2536         (WebCore::acquireLineBreakIterator): Ditto.
2537         * platform/text/wince/TextBreakIteratorWinCE.cpp:
2538         (WebCore::acquireLineBreakIterator): Ditto.
2539         * rendering/RenderBlockLineLayout.cpp:
2540         (WebCore::RenderBlock::LineBreaker::nextLineBreak): Use the locale from the style for the line break
2541         iterator.
2542         * rendering/RenderText.cpp:
2543         (WebCore::RenderText::computePreferredLogicalWidths): Ditto.
2544
2545 2011-06-23  Chris Fleizach  <cfleizach@apple.com>
2546
2547         Reviewed by Darin Adler.
2548
2549         ARIA live regions don't trigger notifications for elements that aren't in the AX tree
2550         https://bugs.webkit.org/show_bug.cgi?id=62289
2551
2552         If an ARIA Live region udpates an element that is not in the AX object cache, then the Live region
2553         notification is not sent. To fix this, I think the childrenChanged() method needs to actually create
2554         the appropriate objects, but since that method gets called during a render tree update, we've learned 
2555         that it's generally not safe to create objects.
2556  
2557         Instead a one shot timer can be fired that will update and create the necessary objects so that the
2558         correct notification can be sent.
2559
2560         Test: platform/mac/accessibility/aria-liveregion-without-element-access.html
2561
2562         * accessibility/AXObjectCache.cpp:
2563         (WebCore::AXObjectCache::AXObjectCache):
2564         (WebCore::AXObjectCache::remove):
2565         (WebCore::AXObjectCache::childrenUpdateTimerFired):
2566         (WebCore::AXObjectCache::childrenChanged):
2567         * accessibility/AXObjectCache.h:
2568         * accessibility/AccessibilityMenuList.cpp:
2569         (WebCore::AccessibilityMenuList::childrenChanged):
2570         * accessibility/AccessibilityMenuList.h:
2571         * accessibility/AccessibilityMenuListPopup.cpp:
2572         (WebCore::AccessibilityMenuListPopup::childrenChanged):
2573         * accessibility/AccessibilityMenuListPopup.h:
2574         * accessibility/AccessibilityObject.h:
2575         (WebCore::AccessibilityObject::childrenChanged):
2576         * accessibility/AccessibilityRenderObject.cpp:
2577         (WebCore::startOfContinuations):
2578            This changed exposed a case where an object was inlineElementContinuation, but not renderInlined,
2579            which led to an assert.
2580         (WebCore::AccessibilityRenderObject::updateAccessibilityRole):
2581         (WebCore::AccessibilityRenderObject::childrenChanged):
2582         * accessibility/AccessibilityRenderObject.h:
2583
2584 2011-06-23  Dirk Schulze  <krit@webkit.org>
2585
2586         Reviewed by Nikolas Zimmermann.
2587
2588         Convert SVGColor to SVGAnimatorFactory concept
2589         https://bugs.webkit.org/show_bug.cgi?id=63246
2590
2591         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
2592         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGColor.
2593
2594         Changed constructors of animators to take the animation element SVGAnimationsElement as new argument. Removed attribute name argument instead.
2595         This information is already exposed by the animation element. The animators store the pointer of the animation element, so that it is not
2596         necessary to pass it as argument to the functions calculateDistance, calculateAnimatedValue.
2597         
2598         Replace all SVGSMILElement references by SVGAnimationsElement - the common base class of all animation elements.
2599
2600         Added a new method in SVGAnimateElement to determine the property value type of CSS properties (regular value type, inherit or currentColor).
2601         The other two new methods fromPropertyValueType() and toPropertyValueType() avoid passing boolean arguments in calculateAnimatedValue().
2602
2603         No new tests added. Current tests cover the changes.
2604
2605         * CMakeLists.txt: Added new files to build system.
2606         * GNUmakefile.list.am: Ditto.
2607         * WebCore.gypi: Ditto.
2608         * WebCore.pro: Ditto.
2609         * WebCore.vcproj/WebCore.vcproj: Ditto.
2610         * WebCore.xcodeproj/project.pbxproj: Ditto.
2611         * svg/SVGAllInOne.cpp:  Ditto.
2612         * svg/SVGAnimateElement.cpp: Use Animator for SVGColor. 
2613         (WebCore::SVGAnimateElement::SVGAnimateElement):
2614         (WebCore::SVGAnimateElement::determineAnimatedAttributeType):
2615         (WebCore::SVGAnimateElement::calculateAnimatedValue):
2616         (WebCore::SVGAnimateElement::determinePropertyValueTypes):
2617         (WebCore::SVGAnimateElement::calculateFromAndToValues):
2618         (WebCore::SVGAnimateElement::calculateFromAndByValues):
2619         (WebCore::SVGAnimateElement::resetToBaseValue):
2620         (WebCore::SVGAnimateElement::applyResultsToTarget):
2621         (WebCore::SVGAnimateElement::calculateDistance):
2622         (WebCore::SVGAnimateElement::ensureAnimator): Pass the animation element as pointer to animator.
2623         * svg/SVGAnimateElement.h: Removed unnecessary includes. Some cleanup.
2624         (WebCore::SVGAnimateElement::fromPropertyValueType): Get property value type of 'from' property.
2625         (WebCore::SVGAnimateElement::toPropertyValueType): Get property value type of 'to' property.
2626         * svg/SVGAnimatedAngle.cpp:
2627         (WebCore::SVGAnimatedAngleAnimator::SVGAnimatedAngleAnimator): Added SVGSMILElement as new argument, removed attributeName.
2628         (WebCore::SVGAnimatedAngleAnimator::calculateFromAndToValues): Determine property value type.
2629         (WebCore::SVGAnimatedAngleAnimator::calculateFromAndByValues): Ditto.
2630         (WebCore::SVGAnimatedAngleAnimator::calculateAnimatedValue): Use new functions of SVGAnimateElement for handling of 'inherit'.
2631             And removed unnecessary arguments.
2632         (WebCore::SVGAnimatedAngleAnimator::calculateDistance): Removed animation element argument.
2633         * svg/SVGAnimatedAngle.h:
2634         * svg/SVGAnimatedColor.cpp: Added.
2635         (WebCore::SVGAnimatedColorAnimator::SVGAnimatedColorAnimator): Ditto.
2636         (WebCore::SVGAnimatedColorAnimator::constructFromString):
2637         (WebCore::SVGAnimatedColorAnimator::calculateFromAndToValues):
2638         (WebCore::SVGAnimatedColorAnimator::calculateFromAndByValues):
2639         (WebCore::SVGAnimatedColorAnimator::calculateAnimatedValue):
2640         (WebCore::SVGAnimatedColorAnimator::calculateDistance):
2641         * svg/SVGAnimatedColor.h: Added.
2642         (WebCore::SVGAnimatedColorAnimator::~SVGAnimatedColorAnimator):
2643         * svg/SVGAnimatedLength.cpp:
2644         (WebCore::SVGAnimatedLengthAnimator::SVGAnimatedLengthAnimator): Ditto.
2645         (WebCore::SVGAnimatedLengthAnimator::calculateFromAndToValues):
2646         (WebCore::SVGAnimatedLengthAnimator::calculateFromAndByValues):
2647         (WebCore::SVGAnimatedLengthAnimator::calculateAnimatedValue):
2648         (WebCore::SVGAnimatedLengthAnimator::calculateDistance):
2649         * svg/SVGAnimatedLength.h:
2650         * svg/SVGAnimatedNumber.cpp:
2651         (WebCore::SVGAnimatedNumberAnimator::SVGAnimatedNumberAnimator): Ditto.
2652         (WebCore::SVGAnimatedNumberAnimator::calculateFromAndToValues):
2653         (WebCore::SVGAnimatedNumberAnimator::calculateFromAndByValues):
2654         (WebCore::SVGAnimatedNumberAnimator::calculateAnimatedValue):
2655         (WebCore::SVGAnimatedNumberAnimator::calculateDistance):
2656         * svg/SVGAnimatedNumber.h:
2657         * svg/SVGAnimatedPointList.cpp:
2658         (WebCore::SVGAnimatedPointListAnimator::SVGAnimatedPointListAnimator): Ditto.
2659         (WebCore::SVGAnimatedPointListAnimator::calculateAnimatedValue):
2660         (WebCore::SVGAnimatedPointListAnimator::calculateDistance):
2661         * svg/SVGAnimatedPointList.h:
2662         * svg/SVGAnimatedRect.cpp:
2663         (WebCore::SVGAnimatedRectAnimator::SVGAnimatedRectAnimator): Ditto.
2664         (WebCore::SVGAnimatedRectAnimator::calculateAnimatedValue):
2665         (WebCore::SVGAnimatedRectAnimator::calculateDistance):
2666         * svg/SVGAnimatedRect.h:
2667         * svg/SVGAnimatedType.cpp: Added handling of Color values.
2668         (WebCore::SVGAnimatedType::~SVGAnimatedType):
2669         (WebCore::SVGAnimatedType::createColor):
2670         (WebCore::SVGAnimatedType::color):
2671         (WebCore::SVGAnimatedType::valueAsString):
2672         (WebCore::SVGAnimatedType::setValueAsString):
2673         * svg/SVGAnimatedType.h:
2674         * svg/SVGAnimatedTypeAnimator.h:
2675         (WebCore::SVGAnimatedTypeAnimator::SVGAnimatedTypeAnimator):
2676         * svg/SVGAnimatorFactory.h:
2677         (WebCore::SVGAnimatorFactory::create):
2678
2679 2011-06-23  Yael Aharon  <yael.aharon@nokia.com>
2680
2681         Reviewed by Andreas Kling.
2682
2683         [Qt] [WK2] Add drag and drop support
2684         https://bugs.webkit.org/show_bug.cgi?id=62838
2685
2686         Add convenience methods to allow encoding/decoding of DragData.
2687         Move the call to dragEnded() to DragClient, to make WebKit1 and WebKit2 
2688         consistent.
2689
2690         * page/qt/DragControllerQt.cpp:
2691         (WebCore::DragController::cleanupAfterSystemDrag):
2692         * platform/DragData.h:
2693         (WebCore::DragData::flags):
2694         (WebCore::DragData::DragData):
2695         (WebCore::DragData::operator =):
2696
2697 2011-06-23  Vsevolod Vlasov  <vsevik@chromium.org>
2698
2699         Reviewed by Yury Semikhatsky.
2700
2701         Web Inspector: Show "no content" message in network panel when resource does not have content available.
2702         https://bugs.webkit.org/show_bug.cgi?id=63007
2703
2704         * English.lproj/localizedStrings.js:
2705         * WebCore.gypi:
2706         * WebCore.vcproj/WebCore.vcproj:
2707         * inspector/front-end/ApplicationCacheItemsView.js:
2708         (WebInspector.ApplicationCacheItemsView):
2709         (WebInspector.ApplicationCacheItemsView.prototype._updateCallback):
2710         * inspector/front-end/CookieItemsView.js:
2711         (WebInspector.CookieItemsView):
2712         (WebInspector.CookieItemsView.prototype._updateWithCookies):
2713         * inspector/front-end/DatabaseTableView.js:
2714         (WebInspector.DatabaseTableView.prototype._queryFinished):
2715         * inspector/front-end/EmptyView.js: Added.
2716         (WebInspector.EmptyView):
2717         (WebInspector.EmptyView.prototype.show):
2718         (WebInspector.EmptyView.prototype.set text):
2719         * inspector/front-end/NetworkItemView.js:
2720         (WebInspector.NetworkItemView):
2721         (WebInspector.ResourceContentView):
2722         (WebInspector.ResourceContentView.prototype.hasContent):
2723         (WebInspector.ResourceContentView.prototype.get sourceView):
2724         (WebInspector.ResourceContentView.prototype.show):
2725         (WebInspector.ResourceContentView.prototype._ensureInnerViewShown.callback):
2726         (WebInspector.ResourceContentView.prototype._ensureInnerViewShown):
2727         (WebInspector.ResourceContentView.prototype.contentLoaded):
2728         * inspector/front-end/ResourceCookiesView.js:
2729         (WebInspector.ResourceCookiesView.prototype.show):
2730         * inspector/front-end/ResourcePreviewView.js:
2731         (WebInspector.ResourcePreviewView):
2732         (WebInspector.ResourcePreviewView.prototype.contentLoaded):
2733         (WebInspector.ResourcePreviewView.prototype._createInnerView):
2734         * inspector/front-end/ResourceResponseView.js: Added.
2735         (WebInspector.ResourceResponseView):
2736         (WebInspector.ResourceResponseView.prototype.get sourceView):
2737         (WebInspector.ResourceResponseView.prototype.contentLoaded):
2738         * inspector/front-end/ResourceTimingView.js:
2739         (WebInspector.ResourceTimingView.prototype.show):
2740         * inspector/front-end/ResourcesPanel.js:
2741         (WebInspector.StorageCategoryView):
2742         (WebInspector.StorageCategoryView.prototype.setText):
2743         * inspector/front-end/WebKit.qrc:
2744         * inspector/front-end/inspector.html:
2745
2746 2011-06-23  Balazs Kelemen  <kbalazs@webkit.org>
2747
2748         Reviewed by Adam Roben.
2749
2750         PluginView::dispatchNPEvent is deceptive
2751         https://bugs.webkit.org/show_bug.cgi?id=63243
2752
2753         Straighten the inverted logic of dispatchNPEvent
2754         and it's callers.
2755
2756         No change in behaviour so no new tests.
2757         Existing plugin tests cover this.
2758
2759         * plugins/gtk/PluginViewGtk.cpp:
2760         (WebCore::PluginView::dispatchNPEvent):
2761         (WebCore::PluginView::handleKeyboardEvent):
2762         (WebCore::PluginView::handleMouseEvent):
2763         * plugins/qt/PluginViewQt.cpp:
2764         (WebCore::PluginView::dispatchNPEvent):
2765         (WebCore::PluginView::handleKeyboardEvent):
2766         (WebCore::PluginView::handleMouseEvent):
2767         * plugins/symbian/PluginViewSymbian.cpp:
2768         (WebCore::PluginView::dispatchNPEvent):
2769         (WebCore::PluginView::handleKeyboardEvent):
2770         (WebCore::PluginView::handleMouseEvent):
2771         * plugins/win/PluginViewWin.cpp:
2772         (WebCore::PluginView::dispatchNPEvent):
2773         (WebCore::PluginView::handleKeyboardEvent):
2774         (WebCore::PluginView::handleMouseEvent):
2775
2776 2011-06-23  Tommy Widenflycht  <tommyw@google.com>
2777
2778         Reviewed by Tony Gentilcore.
2779
2780         MediaStream API: Rename Stream, GeneratedStream and StreamRecorder to the latest spec
2781         https://bugs.webkit.org/show_bug.cgi?id=63122
2782
2783         Fixing broken makefile.
2784
2785         * GNUmakefile.list.am:
2786
2787 2011-06-23  Tommy Widenflycht  <tommyw@google.com>
2788
2789         Reviewed by Tony Gentilcore.
2790
2791         MediaStream API: Rename Stream, GeneratedStream and StreamRecorder to the latest spec
2792         https://bugs.webkit.org/show_bug.cgi?id=63122
2793
2794         No new tests since no code has actually changed.
2795
2796         * CMakeLists.txt:
2797         * CodeGenerators.pri:
2798         * DerivedSources.cpp:
2799         * DerivedSources.make:
2800         * GNUmakefile.list.am:
2801         * WebCore.gypi:
2802         * WebCore.pro:
2803         * WebCore.vcproj/WebCore.vcproj:
2804         * WebCore.xcodeproj/project.pbxproj:
2805         * bindings/js/JSEventTarget.cpp:
2806         (WebCore::toJS):
2807         * bindings/v8/V8DOMWrapper.cpp:
2808         (WebCore::V8DOMWrapper::convertEventTargetToV8Object):
2809         * dom/DOMAllInOne.cpp:
2810         * dom/EventTarget.cpp:
2811         (WebCore::EventTarget::toMediaStream):
2812         (WebCore::EventTarget::toLocalMediaStream):
2813         * dom/EventTarget.h:
2814         * dom/LocalMediaStream.cpp: Renamed from Source/WebCore/dom/GeneratedStream.cpp.
2815         (WebCore::LocalMediaStream::DispatchUpdateTask::create):
2816         (WebCore::LocalMediaStream::DispatchUpdateTask::performTask):
2817         (WebCore::LocalMediaStream::DispatchUpdateTask::DispatchUpdateTask):
2818         (WebCore::LocalMediaStream::create):
2819         (WebCore::LocalMediaStream::LocalMediaStream):
2820         (WebCore::LocalMediaStream::~LocalMediaStream):
2821         (WebCore::LocalMediaStream::toLocalMediaStream):
2822         (WebCore::LocalMediaStream::detachEmbedder):
2823         (WebCore::LocalMediaStream::streamEnded):
2824         (WebCore::LocalMediaStream::audioTracks):
2825         (WebCore::LocalMediaStream::videoTracks):
2826         (WebCore::LocalMediaStream::stop):
2827         (WebCore::LocalMediaStream::onStop):
2828         * dom/LocalMediaStream.h: Renamed from Source/WebCore/dom/GeneratedStream.h.
2829         * dom/LocalMediaStream.idl: Renamed from Source/WebCore/dom/GeneratedStream.idl.
2830         * dom/MediaStream.cpp: Renamed from Source/WebCore/dom/Stream.cpp.
2831         (WebCore::MediaStream::create):
2832         (WebCore::MediaStream::MediaStream):
2833         (WebCore::MediaStream::~MediaStream):
2834         (WebCore::MediaStream::toMediaStream):
2835         (WebCore::MediaStream::streamEnded):
2836         (WebCore::MediaStream::scriptExecutionContext):
2837         (WebCore::MediaStream::eventTargetData):
2838         (WebCore::MediaStream::ensureEventTargetData):
2839         * dom/MediaStream.h: Renamed from Source/WebCore/dom/Stream.h.
2840         (WebCore::MediaStream::readyState):
2841         (WebCore::MediaStream::label):
2842         (WebCore::MediaStream::refEventTarget):
2843         (WebCore::MediaStream::derefEventTarget):
2844         * dom/MediaStream.idl: Renamed from Source/WebCore/dom/Stream.idl.
2845         * dom/MediaStreamContainer.h: Renamed from Source/WebCore/dom/StreamContainer.h.
2846         (WebCore::MediaStreamContainer::create):
2847         (WebCore::MediaStreamContainer::~MediaStreamContainer):
2848         (WebCore::MediaStreamContainer::length):
2849         (WebCore::MediaStreamContainer::item):
2850         (WebCore::MediaStreamContainer::add):
2851         (WebCore::MediaStreamContainer::remove):
2852         (WebCore::MediaStreamContainer::contains):
2853         (WebCore::MediaStreamContainer::get):
2854         (WebCore::MediaStreamContainer::MediaStreamContainer):
2855         * dom/MediaStreamList.cpp: Renamed from Source/WebCore/dom/StreamList.cpp.
2856         (WebCore::MediaStreamList::create):
2857         (WebCore::MediaStreamList::MediaStreamList):
2858         (WebCore::MediaStreamList::~MediaStreamList):
2859         (WebCore::MediaStreamList::length):
2860         (WebCore::MediaStreamList::item):
2861         * dom/MediaStreamList.h: Renamed from Source/WebCore/dom/StreamList.h.
2862         * dom/MediaStreamList.idl: Renamed from Source/WebCore/dom/StreamList.idl.
2863         * dom/StreamEvent.cpp:
2864         (WebCore::StreamEvent::create):
2865         (WebCore::StreamEvent::StreamEvent):
2866         (WebCore::StreamEvent::initStreamEvent):
2867         (WebCore::StreamEvent::stream):
2868         * dom/StreamEvent.h:
2869         (WebCore::StreamEvent::isMediaStreamEvent):
2870         * dom/StreamEvent.idl:
2871         * page/MediaStreamFrameController.cpp:
2872         (WebCore::MediaStreamFrameController::unregister):
2873         (WebCore::MediaStreamFrameController::getStreamFromLabel):
2874         (WebCore::MediaStreamFrameController::stopGeneratedStream):
2875         (WebCore::MediaStreamFrameController::streamGenerated):
2876         (WebCore::MediaStreamFrameController::audioTrackFailed):
2877         (WebCore::MediaStreamFrameController::videoTrackFailed):
2878         * page/MediaStreamFrameController.h:
2879         (WebCore::MediaStreamFrameController::ClientBase::isMediaStream):
2880         (WebCore::MediaStreamFrameController::ClientBase::isLocalMediaStream):
2881         (WebCore::MediaStreamFrameController::MediaStreamClient::MediaStreamClient):
2882         (WebCore::MediaStreamFrameController::MediaStreamClient::~MediaStreamClient):
2883         (WebCore::MediaStreamFrameController::MediaStreamClient::isMediaStream):
2884         (WebCore::MediaStreamFrameController::MediaStreamClient::isLocalMediaStream):
2885         * page/NavigatorUserMediaSuccessCallback.h:
2886         * page/NavigatorUserMediaSuccessCallback.idl:
2887
2888 2011-06-23  Mikhail Naganov  <mnaganov@chromium.org>
2889
2890         Reviewed by Yury Semikhatsky.
2891
2892         Web Inspector: [Chromium] Fix showing dominator leaf nodes after r89457
2893         https://bugs.webkit.org/show_bug.cgi?id=63250
2894
2895         * inspector/front-end/DetailedHeapshotView.js:
2896         * inspector/front-end/HeapSnapshot.js:
2897         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.get isEmpty):
2898
2899 2011-06-23  Vsevolod Vlasov  <vsevik@chromium.org>
2900
2901         Reviewed by Yury Semikhatsky.
2902
2903         Web Inspector: HTML preview in network panel should take 100% of resource view height.
2904         https://bugs.webkit.org/show_bug.cgi?id=63167
2905
2906         * inspector/front-end/inspector.css:
2907         (.resource-view.html iframe):
2908
2909 2011-06-23  Zoltan Herczeg  <zherczeg@inf.u-szeged.hu>
2910
2911         Reviewed by Pavel Feldman.
2912
2913         Inspector may close at the start of the next inspector test in DRT
2914         https://bugs.webkit.org/show_bug.cgi?id=60881
2915
2916         Add a new function to the inspector, which tests whether the
2917         dispatch queue is empty.
2918
2919         * inspector/front-end/inspector.js:
2920         (WebInspector.dispatchQueueIsEmpty):
2921
2922 2011-06-23  Jeffrey Pfau  <jpfau@apple.com>
2923
2924         Reviewed by Nikolas Zimmermann.
2925
2926         Incorrectly placed SVG gradients can cause crashes when referenced
2927         https://bugs.webkit.org/show_bug.cgi?id=62914
2928
2929         Added a check for gradient rendering contexts. If the contexts can't be found, the gradient must be in an invalid location, so we use the fallback color instead.
2930
2931         Tests: svg/custom/invalid-gradient-with-xlink.svg
2932                svg/custom/xlink-to-invalid-gradient.svg
2933
2934         * rendering/svg/RenderSVGResourceGradient.cpp:
2935         (WebCore::RenderSVGResourceGradient::applyResource):
2936         * rendering/svg/RenderSVGResourceGradient.h:
2937         * rendering/svg/RenderSVGResourceLinearGradient.cpp:
2938         (WebCore::RenderSVGResourceLinearGradient::collectGradientAttributes):
2939         * rendering/svg/RenderSVGResourceLinearGradient.h:
2940         * rendering/svg/RenderSVGResourceRadialGradient.cpp:
2941         (WebCore::RenderSVGResourceRadialGradient::collectGradientAttributes):
2942         * rendering/svg/RenderSVGResourceRadialGradient.h:
2943         * svg/SVGLinearGradientElement.cpp:
2944         (WebCore::SVGLinearGradientElement::collectGradientAttributes):
2945         * svg/SVGLinearGradientElement.h:
2946         * svg/SVGRadialGradientElement.cpp:
2947         (WebCore::SVGRadialGradientElement::collectGradientAttributes):
2948         * svg/SVGRadialGradientElement.h:
2949
2950 2011-06-23  Dmitriy Vyukov  <dvyukov@google.com>
2951
2952         Reviewed by David Levin.
2953
2954         Fix incorrect usage of a condition variable.
2955         https://bugs.webkit.org/show_bug.cgi?id=63127
2956
2957         No new tests. This does not affect existing
2958         functionality.
2959
2960         * storage/DatabaseTask.cpp:
2961         (WebCore::DatabaseTaskSynchronizer::waitForTaskCompletion):
2962
2963 2011-06-23  David Grogan  <dgrogan@chromium.org>
2964
2965         Reviewed by Eric Seidel.
2966
2967         IndexedDB: add detail to an ASSERT error message
2968         https://bugs.webkit.org/show_bug.cgi?id=60407
2969
2970         No new tests, this is just a debug ASSERT.
2971
2972         * storage/IDBRequest.cpp:
2973         (WebCore::IDBRequest::dispatchEvent):
2974
2975 2011-06-22  Dirk Schulze  <krit@webkit.org>
2976
2977         Reviewed by Rob Buis.
2978
2979         Convert SVGPointList to SVGAnimatorFactory concept
2980         https://bugs.webkit.org/show_bug.cgi?id=63171
2981
2982         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
2983         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGPointList.
2984
2985         Added support for from-by animations of SVGPointLists.
2986
2987         Tests: svg/animations/svgpointlist-animation-1.html
2988                svg/animations/svgpointlist-animation-2.html
2989
2990         * CMakeLists.txt: Added new files to build system.
2991         * GNUmakefile.list.am: Ditto.
2992         * WebCore.gypi: Ditto.
2993         * WebCore.pro: Ditto.
2994         * WebCore.vcproj/WebCore.vcproj: Ditto.
2995         * WebCore.xcodeproj/project.pbxproj: Ditto.
2996         * svg/SVGAllInOne.cpp: Added SVGAnimatedPointList.cpp
2997         * svg/SVGAnimateElement.cpp:
2998         (WebCore::SVGAnimateElement::calculateAnimatedValue):
2999         (WebCore::SVGAnimateElement::calculateFromAndToValues):
3000         (WebCore::SVGAnimateElement::calculateFromAndByValues):
3001         (WebCore::SVGAnimateElement::resetToBaseValue):
3002         (WebCore::SVGAnimateElement::applyResultsToTarget):
3003         (WebCore::SVGAnimateElement::calculateDistance):
3004         * svg/SVGAnimateElement.h:
3005         * svg/SVGAnimatedPointList.cpp: Added.
3006         (WebCore::SVGAnimatedPointListAnimator::SVGAnimatedPointListAnimator):
3007         (WebCore::SVGAnimatedPointListAnimator::constructFromString):
3008         (WebCore::SVGAnimatedPointListAnimator::calculateFromAndToValues):
3009         (WebCore::SVGAnimatedPointListAnimator::calculateFromAndByValues):
3010         (WebCore::SVGAnimatedPointListAnimator::calculateAnimatedValue):
3011         (WebCore::SVGAnimatedPointListAnimator::calculateDistance):
3012         * svg/SVGAnimatedPointList.h: Added.
3013         (WebCore::SVGAnimatedPointListAnimator::~SVGAnimatedPointListAnimator):
3014         * svg/SVGAnimatedType.cpp:
3015         (WebCore::SVGAnimatedType::~SVGAnimatedType):
3016         (WebCore::SVGAnimatedType::createPointList):
3017         (WebCore::SVGAnimatedType::pointList):
3018         (WebCore::SVGAnimatedType::valueAsString):
3019         (WebCore::SVGAnimatedType::setValueAsString):
3020         * svg/SVGAnimatedType.h:
3021         * svg/SVGAnimatorFactory.h:
3022         (WebCore::SVGAnimatorFactory::create):
3023
3024 2011-06-22  Dimitri Glazkov  <dglazkov@chromium.org>
3025
3026         Reviewed by Kent Tamura.
3027
3028         Move file-choosing and icon-loading management to FileInputType
3029         https://bugs.webkit.org/show_bug.cgi?id=62069
3030
3031         1) Moved the duties of FileChooserClient and FileIconLoaderClient from
3032         RenderFileUploadControl to FileInputType, along with all of the
3033         supporting functions.
3034
3035         2) Moved Icon ownership to FileInputType and exposed accessor on
3036         HTMInputElement to allow RenderFileUploadControl to query current icon.
3037
3038         As a result, RenderFileUploadControl is now completely stateless, which is
3039         neat and clean.
3040
3041         Refactoring, covered by existing tests.
3042
3043         * html/FileInputType.cpp:
3044         (WebCore::FileInputType::handleDOMActivateEvent): Moved logic here from RenderFileUploadControl.
3045         (WebCore::FileInputType::requestIcon): Ditto.
3046         (WebCore::FileInputType::filesChosen): Ditto.
3047         (WebCore::FileInputType::receiveDropForDirectoryUpload): Ditto.
3048         (WebCore::FileInputType::updateRendering): Ditto.
3049         (WebCore::FileInputType::chrome): Ditto.
3050         (WebCore::FileInputType::receiveDroppedFiles): Ditto.
3051         (WebCore::FileInputType::icon): Added.
3052         * html/FileInputType.h:
3053         * html/HTMLInputElement.cpp:
3054         (WebCore::HTMLInputElement::setValueFromRenderer): Updated comment.
3055         (WebCore::HTMLInputElement::receiveDroppedFiles): Added to replace setFileListFromRenderer.
3056         (WebCore::HTMLInputElement::icon): Added.
3057         * html/HTMLInputElement.h:
3058         * html/InputType.cpp:
3059         (WebCore::InputType::receiveDroppedFiles): Added.
3060         (WebCore::InputType::icon): Added.
3061         * html/InputType.h:
3062         * page/DragController.cpp:
3063         (WebCore::DragController::concludeEditDrag): Changed to use HTMLInputElement. Ahh, nice and clean!
3064         * rendering/RenderFileUploadControl.cpp:
3065         (WebCore::RenderFileUploadControl::RenderFileUploadControl): Removed code that is no longer necessary.
3066         (WebCore::RenderFileUploadControl::updateFromElement): Ditto.
3067         (WebCore::RenderFileUploadControl::maxFilenameWidth): Changed to use HTMLInputElement icon accessor.
3068         (WebCore::RenderFileUploadControl::paintObject): Ditto.
3069         * rendering/RenderFileUploadControl.h:
3070
3071 2011-06-22  Pratik Solanki  <psolanki@apple.com>
3072
3073         Reviewed by Darin Adler.
3074
3075         Add NSError wrapper functions in ResourceError when USE(CFNETWORK) is enabled
3076         https://bugs.webkit.org/show_bug.cgi?id=63155
3077
3078         Add wrapper functions to ResourceError when building with USE(CFNETWORK). We need to create
3079         a new NSError in ResourceError::nsError() since Safari has category methods on NSError and
3080         passing a CFErrorRef back does not work even though CFErrorRef/NSErrror are toll-free
3081         bridged.
3082
3083         No tests because no change in functionality.
3084
3085         * WebCore.exp.in:
3086         * platform/network/cf/ResourceError.h:
3087         * platform/network/mac/ResourceErrorMac.mm:
3088         (WebCore::ResourceError::ResourceError):
3089         (WebCore::ResourceError::nsError):
3090         (WebCore::ResourceError::operator NSError *):
3091
3092 2011-06-22  Dominic Cooney  <dominicc@chromium.org>
3093
3094         Reviewed by Mark Rowe.
3095
3096         Add window.internals to WebKit2's WebKitTestRunner.
3097         https://bugs.webkit.org/show_bug.cgi?id=61073
3098
3099         * Configurations/WebCoreTestSupport.xcconfig:
3100         * WebCore.xcodeproj/project.pbxproj:
3101
3102 2011-06-22  Dimitri Glazkov  <dglazkov@chromium.org>
3103
3104         Reviewed by Kent Tamura.
3105
3106         Convert FileIconLoaderClient to "smart client" pattern, just like FileChooserClient.
3107         https://bugs.webkit.org/show_bug.cgi?id=63224
3108
3109         Refactoring, covered by existing tests.
3110
3111         * platform/FileIconLoader.cpp:
3112         (WebCore::FileIconLoaderClient::~FileIconLoaderClient): Changed to discard loader.
3113         (WebCore::FileIconLoaderClient::newFileIconLoader): Added.
3114         (WebCore::FileIconLoaderClient::discardLoader): Added.
3115         * platform/FileIconLoader.h: Updated defs.
3116         * rendering/RenderFileUploadControl.cpp:
3117         (WebCore::RenderFileUploadControl::RenderFileUploadControl): Removed initialization of icon loader.
3118         (WebCore::RenderFileUploadControl::~RenderFileUploadControl): Remove discarding of loader.
3119         (WebCore::RenderFileUploadControl::requestIcon): Changed to use newFileIconLoader.
3120         * rendering/RenderFileUploadControl.h: Updated defs.
3121
3122 2011-06-22  Yael Aharon  <yael.aharon@nokia.com>
3123
3124         Another unreviewed build fix after r89472.
3125
3126         No new tests, just a build fix.
3127
3128         * rendering/svg/SVGResources.cpp:
3129
3130 2011-06-22  Yael Aharon  <yael.aharon@nokia.com>
3131
3132         Unreviewed build fix after r89472.
3133
3134         No new tests, just a build fix.
3135
3136         * rendering/InlineBox.cpp:
3137         * rendering/RenderCounter.cpp:
3138
3139 2011-06-22  Dimitri Glazkov  <dglazkov@chromium.org>
3140
3141         Reviewed by Kent Tamura.
3142
3143         Add a helper function to FileList to retrieve a list of filenames.
3144         https://bugs.webkit.org/show_bug.cgi?id=63222
3145
3146         Refactoring, covered by existing tests.
3147
3148         * fileapi/FileList.cpp:
3149         (WebCore::FileList::filenames): Added.
3150         * fileapi/FileList.h:
3151         * rendering/RenderFileUploadControl.cpp:
3152         (WebCore::RenderFileUploadControl::RenderFileUploadControl): Changed to use newly added helper.
3153         (WebCore::RenderFileUploadControl::click): Ditto.
3154         (WebCore::RenderFileUploadControl::fileTextValue): Ditto.
3155
3156 2011-06-22  Sam Weinig  <sam@webkit.org>
3157
3158         Reviewed by Adam Barth.
3159
3160         Lower HTML parser DOM depth limit to 2048
3161         https://bugs.webkit.org/show_bug.cgi?id=63219
3162
3163         Lower the default depth limit from 4096 to 2048. There isn't a good
3164         reason to have such pathologically nested content, and by-and-large,
3165         the rendering code is not setup to support it that well. Adding this
3166         aggressive limit now will allow us to see if anything breaks in the
3167         nightlies.
3168
3169         * page/Settings.h:
3170
3171 2011-06-22  Julien Chaffraix  <jchaffraix@webkit.org>
3172
3173         Reviewed by Dimitri Glazkov.
3174
3175         Tighten type usage in the Shadow tree code
3176         https://bugs.webkit.org/show_bug.cgi?id=63210
3177
3178         Refactoring only, no new test required.
3179
3180         * dom/Document.cpp:
3181         (WebCore::Document::buildAccessKeyMap):
3182         * dom/Document.h:
3183         Changed the argument of buildAccessKeyMap to TreeScope.
3184
3185         * dom/Element.cpp:
3186         (WebCore::Element::attach):
3187         (WebCore::Element::removeShadowRoot):
3188         * html/ColorInputType.cpp:
3189         (WebCore::ColorInputType::shadowColorSwatch):
3190         * html/HTMLKeygenElement.cpp:
3191         (WebCore::HTMLKeygenElement::shadowSelect):
3192         * html/shadow/SliderThumbElement.cpp:
3193         (WebCore::sliderThumbElementOf):
3194         Use ShadowRoot for the previous call sites as this is what is
3195         returned by shadowRoot().
3196
3197         * dom/Node.cpp:
3198         (WebCore::traverseTreeAndMark): Renamed the parameter here as it is not
3199         expected to be a shadow object. Just the rootNode of our traversal.
3200
3201         * dom/ShadowRoot.h: Made attach() public as it is public in ContainerNode
3202         and we would do some casting to avoid the private attribute in ShadowRoot.
3203
3204 2011-06-22  Joseph Pecoraro  <joepeck@webkit.org>
3205
3206         Reviewed by Darin Adler.
3207
3208         Remove comment about pages with frames not being page-cachable
3209         https://bugs.webkit.org/show_bug.cgi?id=63207
3210
3211         This comment was out of date. Caching pages with Frames in
3212         the PageCache has worked since 2009:
3213         <http://webkit.org/b/13631> Page Cache should support pages with frames
3214
3215         * history/PageCache.cpp:
3216         (WebCore::PageCache::canCache):
3217
3218 2011-06-22  Yael Aharon  <yael.aharon@nokia.com>
3219
3220         Reviewed by Andreas Kling.
3221
3222         [Qt] Add a build flag for building with libxml2 and libxslt.
3223         https://bugs.webkit.org/show_bug.cgi?id=63113
3224
3225         No new tests. If this new flag was set by default, we could unskip
3226         existing xmlviewer tests.
3227
3228         * CodeGenerators.pri:
3229         * WebCore.pri:
3230         * WebCore.pro:
3231         * features.pri:
3232
3233 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
3234
3235         Yet another build fix after r89472.
3236
3237         * html/parser/HTMLFormattingElementList.cpp:
3238
3239 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
3240
3241         Another build fix after r89472.
3242
3243         * dom/DocumentMarkerController.cpp:
3244
3245 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
3246
3247         Build fix after r89472.
3248
3249         * css/CSSStyleDeclaration.cpp:
3250
3251 2011-06-22  Mark Pilgrim  <pilgrim@chromium.org>
3252
3253         Reviewed by Adam Barth.
3254
3255         IndexedDB open (database) should NOT throw if name is null
3256         https://bugs.webkit.org/show_bug.cgi?id=63110
3257
3258         * storage/IDBFactory.idl: remove ConvertNullToNullString flag on
3259         name argument, let IDL code generator stringify null value to "null"
3260
3261 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
3262
3263         Reviewed by Darin Adler.
3264
3265         Add a Position constructor that takes (Text*, unsigned offset)
3266         https://bugs.webkit.org/show_bug.cgi?id=63181
3267
3268         Added Position::Position(PassRefPtr<Text*>, unsigned offset) and deployed in a couple of places
3269         by replacing the calls to the old constructor.
3270
3271         * dom/Position.cpp:
3272         (WebCore::Position::Position): Added.
3273         * dom/Position.h:
3274         * editing/CompositeEditCommand.cpp:
3275         (WebCore::CompositeEditCommand::replaceSelectedTextInNode): Calls new constructor; extracted
3276         from InsertTextCommand::performTrivialReplace and ReplaceSelectionCommand::performTrivialReplace.
3277         (WebCore::CompositeEditCommand::rebalanceWhitespaceOnTextSubstring): Calls new constructor
3278         * editing/CompositeEditCommand.h:
3279         * editing/InsertTextCommand.cpp:
3280         (WebCore::InsertTextCommand::performTrivialReplace): Calls replaceSelectedTextInNode.
3281         (WebCore::InsertTextCommand::input): Calls new constructor.
3282         (WebCore::InsertTextCommand::insertTab): Use RefPtr instead of a raw pointer.
3283         * editing/ReplaceSelectionCommand.cpp:
3284         (WebCore::ReplaceSelectionCommand::performTrivialReplace): Calls replaceSelectedTextInNode.
3285         * editing/visible_units.cpp:
3286         (WebCore::startPositionForLine): Calls new constructor.
3287         * rendering/RenderTextControl.cpp:
3288         (WebCore::RenderTextControl::visiblePositionForIndex): Calls new constructor; calls endPosition
3289         on Range instead of avoid manually constructing a VisiblePosition out of endContainer and endOffset.
3290
3291 2011-06-22  Adam Barth  <abarth@webkit.org>
3292
3293         Reviewed by Darin Fisher.
3294
3295         [Chromium] Add WebDocument APIs for the functions moving from WebFrame
3296         https://bugs.webkit.org/show_bug.cgi?id=62831
3297
3298         * dom/Document.cpp:
3299         (WebCore::Document::openSearchDescriptionURL):
3300             - This function exists to service a Chromium WebKit API, but it's
3301               generally purpose and might be useful to other ports.  The
3302               algorithm has some strange early exits, which I've marked with
3303               FIXME comments.
3304         * dom/Document.h:
3305
3306 2011-06-22  Nate Chapin  <japhet@chromium.org>
3307
3308         Reviewed by Adam Barth.
3309
3310         Don't let all subresources keep isLoadingInAPISense() from
3311         returning false, only requests that affect
3312         CachedResourceRequest::requestCount().
3313
3314         Also, add a callback to Internals to determine whether
3315         a resource has been preloaded.
3316
3317         https://bugs.webkit.org/show_bug.cgi?id=62066
3318
3319         * WebCore.exp.in:
3320         * dom/Document.cpp: Add m_loadEventFinished.
3321         * dom/Document.h:
3322         * loader/DocumentLoader.cpp:
3323         (WebCore::DocumentLoader::isLoadingInAPISense):
3324         * loader/cache/CachedResourceLoader.cpp:
3325         (WebCore::CachedResourceLoader::isPreloaded):
3326         * loader/cache/CachedResourceLoader.h:
3327         * testing/Internals.cpp:
3328         (WebCore::Internals::isPreloaded):
3329         * testing/Internals.h:
3330         * testing/Internals.idl:
3331
3332 2011-06-22  Chris Rogers  <crogers@google.com>
3333
3334         Reviewed by David Levin.
3335
3336         Use create() method for AsyncAudioDecoder::DecodingTask
3337         https://bugs.webkit.org/show_bug.cgi?id=63198
3338
3339         No new tests.  This doesn't change any JS API.
3340
3341         * webaudio/AsyncAudioDecoder.cpp:
3342         (WebCore::AsyncAudioDecoder::decodeAsync):
3343         (WebCore::AsyncAudioDecoder::DecodingTask::create):
3344         * webaudio/AsyncAudioDecoder.h:
3345
3346 2011-06-22  Sheriff Bot  <webkit.review.bot@gmail.com>
3347
3348         Unreviewed, rolling out r89489.
3349         http://trac.webkit.org/changeset/89489
3350         https://bugs.webkit.org/show_bug.cgi?id=63203
3351
3352         Broke chromium mac build on build.webkit.org (Requested by
3353         abarth on #webkit).
3354
3355         * WebCore.gyp/WebCore.gyp:
3356         * loader/cache/CachedFont.cpp:
3357         * platform/chromium/DragImageRef.h:
3358         * platform/graphics/FloatPoint.h:
3359         * platform/graphics/FloatRect.h:
3360         * platform/graphics/FloatSize.h:
3361         * platform/graphics/FontPlatformData.h:
3362         (WebCore::FontPlatformData::hash):
3363         * platform/graphics/GlyphBuffer.h:
3364         (WebCore::GlyphBuffer::advanceAt):
3365         (WebCore::GlyphBuffer::add):
3366         (WebCore::GlyphBuffer::expandLastAdvance):
3367         * platform/graphics/IntPoint.h:
3368         * platform/graphics/IntRect.h:
3369         * platform/graphics/IntSize.h:
3370         * platform/graphics/SimpleFontData.h:
3371         * platform/graphics/cg/FloatPointCG.cpp:
3372         * platform/graphics/cg/FloatRectCG.cpp:
3373         * platform/graphics/cg/FloatSizeCG.cpp:
3374         * platform/graphics/cg/IntPointCG.cpp:
3375         * platform/graphics/cg/IntRectCG.cpp:
3376         * platform/graphics/cg/IntSizeCG.cpp:
3377         * platform/graphics/mac/FontCustomPlatformData.cpp:
3378         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
3379         (WebCore::createFontCustomPlatformData):
3380         * platform/graphics/mac/FontCustomPlatformData.h:
3381         (WebCore::FontCustomPlatformData::FontCustomPlatformData):
3382
3383 2011-06-22  Luke Macpherson   <macpherson@chromium.org>
3384
3385         Reviewed by James Robinson.
3386
3387         Remove comment that snuck in via copy & paste.
3388         https://bugs.webkit.org/show_bug.cgi?id=63177
3389
3390         No new tests / no code changes.
3391
3392         * css/CSSPrimitiveValueMappings.h:
3393         (WebCore::CSSPrimitiveValue::operator short):
3394         Removed incorrect comment.
3395
3396 2011-06-22  Annie Sullivan  <sullivan@chromium.org>
3397
3398         Reviewed by Ryosuke Niwa.
3399
3400         REGRESSION: Hitting enter in the middle of this span causes the cursor to go to the end of the span
3401         https://bugs.webkit.org/show_bug.cgi?id=61594
3402
3403         When the tree is split at the cursor in InsertParagraphSeparatorCommand, it is possible for the position
3404         split at to be at the end of a text node. The code assumes the position is at the start of the node, so
3405         pass the correct node into splitTreeToNode() in that case.
3406
3407         Tests: editing/inserting/return-key-before-br-in-span.html
3408                editing/inserting/return-key-middle-of-span.html
3409
3410         * editing/InsertParagraphSeparatorCommand.cpp:
3411         (WebCore::InsertParagraphSeparatorCommand::doApply):
3412
3413 2011-06-22  Rob Buis  <rbuis@rim.com>
3414
3415         Reviewed by Nikolas Zimmermann.
3416
3417         SVG1.1SE test with pointer-events and invalid gradient fill fails
3418         https://bugs.webkit.org/show_bug.cgi?id=63109
3419
3420         Properly detect fill/stroke properties of type SVG_PAINTTYPE_URI_NONE, store it in SVGPaint
3421         and don't apply the paint if the uri lookup fails.
3422
3423         Tests: svg/W3C-SVG-1.1-SE/interact-pointer-03-t.svg
3424                svg/custom/pointer-events-invalid-fill.svg
3425
3426         * css/SVGCSSParser.cpp:
3427         (WebCore::CSSParser::parseSVGValue):
3428         * rendering/svg/RenderSVGResource.cpp:
3429         (WebCore::requestPaintingResource):
3430         * svg/SVGPaint.h:
3431         (WebCore::SVGPaint::createURIAndNone):
3432
3433 2011-06-22  Cary Clark  <caryclark@google.com>
3434
3435         Reviewed by Darin Fisher.
3436
3437         Use Skia if Skia on Mac Chrome is enabled
3438         https://bugs.webkit.org/show_bug.cgi?id=62999
3439
3440         No new tests. This does not affect existing
3441         functionality.
3442
3443         * WebCore.gyp/WebCore.gyp:
3444         Include Skia and related files and exclude CG
3445         and related files when building Chromium for Skia
3446         on the Mac.
3447
3448         * loader/cache/CachedFont.cpp:
3449         Rename CHROME to CHROMIUM.
3450
3451         * platform/chromium/DragImageRef.h:
3452         * platform/graphics/FloatPoint.h:
3453         * platform/graphics/FloatRect.h:
3454         * platform/graphics/FloatSize.h:
3455         * platform/graphics/FontPlatformData.h:
3456         (WebCore::FontPlatformData::hash):
3457         * platform/graphics/GlyphBuffer.h:
3458         (WebCore::GlyphBuffer::advanceAt):
3459         (WebCore::GlyphBuffer::add):
3460         (WebCore::GlyphBuffer::expandLastAdvance):
3461         * platform/graphics/IntPoint.h:
3462         * platform/graphics/IntRect.h:
3463         * platform/graphics/IntSize.h:
3464         * platform/graphics/SimpleFontData.h:
3465         * platform/graphics/cg/FloatPointCG.cpp:
3466         * platform/graphics/cg/FloatRectCG.cpp:
3467         * platform/graphics/cg/FloatSizeCG.cpp:
3468         * platform/graphics/cg/IntPointCG.cpp:
3469         * platform/graphics/cg/IntRectCG.cpp:
3470         * platform/graphics/cg/IntSizeCG.cpp:
3471         * platform/graphics/mac/FontCustomPlatformData.cpp:
3472         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
3473         (WebCore::createFontCustomPlatformData):
3474         * platform/graphics/mac/FontCustomPlatformData.h:
3475         (WebCore::FontCustomPlatformData::FontCustomPlatformData):
3476         Ditto.
3477
3478 2011-06-22  Mark Pilgrim  <pilgrim@chromium.org>
3479
3480         Reviewed by Adam Barth.
3481
3482         IndexedDB createIndex should NOT throw if name arg is null
3483         https://bugs.webkit.org/show_bug.cgi?id=63114
3484
3485         * storage/IDBObjectStore.idl: remove ConvertNullToNullString flag
3486         so null values will be stringified as "null", as per WebIDL spec.
3487
3488 2011-06-22  Chris Rogers  <crogers@google.com>
3489
3490         Reviewed by Kenneth Russell.
3491
3492         AudioContext needs non-blocking call to create AudioBuffer from audio file data
3493         https://bugs.webkit.org/show_bug.cgi?id=61947
3494
3495         No new tests since audio API is not yet implemented.
3496
3497         * DerivedSources.make:
3498         * WebCore.gypi:
3499         * WebCore.xcodeproj/project.pbxproj:
3500         * webaudio/AsyncAudioDecoder.cpp: Added.
3501         (WebCore::AsyncAudioDecoder::AsyncAudioDecoder):
3502         (WebCore::AsyncAudioDecoder::~AsyncAudioDecoder):
3503         (WebCore::AsyncAudioDecoder::decodeAsync):
3504         (WebCore::AsyncAudioDecoder::threadEntry):
3505         (WebCore::AsyncAudioDecoder::runLoop):
3506         (WebCore::AsyncAudioDecoder::DecodingTask::DecodingTask):
3507         (WebCore::AsyncAudioDecoder::DecodingTask::decode):
3508         (WebCore::AsyncAudioDecoder::DecodingTask::notifyCompleteDispatch):
3509         (WebCore::AsyncAudioDecoder::DecodingTask::notifyComplete):
3510         * webaudio/AsyncAudioDecoder.h: Added.
3511         (WebCore::AsyncAudioDecoder::DecodingTask::audioData):
3512         (WebCore::AsyncAudioDecoder::DecodingTask::sampleRate):
3513         (WebCore::AsyncAudioDecoder::DecodingTask::successCallback):
3514         (WebCore::AsyncAudioDecoder::DecodingTask::errorCallback):
3515         (WebCore::AsyncAudioDecoder::DecodingTask::audioBuffer):
3516         * webaudio/AudioBufferCallback.h: Added.
3517         (WebCore::AudioBufferCallback::~AudioBufferCallback):
3518         * webaudio/AudioBufferCallback.idl: Added.
3519         * webaudio/AudioContext.cpp:
3520         (WebCore::AudioContext::decodeAudioData):
3521         * webaudio/AudioContext.h:
3522         * webaudio/AudioContext.idl:
3523
3524 2011-06-22  Beth Dakin  <bdakin@apple.com>
3525
3526         Reviewed by Simon Fraser.
3527
3528         https://bugs.webkit.org/show_bug.cgi?id=63174
3529         Don't draw the borders as one path unless there really are 4 borders
3530         -and corresponding-
3531         <rdar://problem/9457997>
3532
3533         If any of the border edges have no width, then allEdgesVisible should be set to 
3534         false since borders without width will not be visible.
3535         * rendering/RenderBoxModelObject.cpp:
3536         (WebCore::RenderBoxModelObject::paintBorder):
3537
3538 2011-06-22  Matthew Delaney  <mdelaney@apple.com>
3539
3540         Reviewed by Oliver Hunt.
3541
3542         Canvas in layer obscures overlapping span
3543         https://bugs.webkit.org/show_bug.cgi?id=63161
3544
3545         Test: compositing/layer-creation/spanOverlapsCanvas.html
3546
3547         * rendering/RenderLayer.cpp: Added checks for canvas to be layered properly.
3548         (WebCore::RenderLayer::shouldBeNormalFlowOnly):
3549         (WebCore::RenderLayer::isSelfPaintingLayer):
3550
3551 2011-06-22  Chris Rogers  <crogers@google.com>
3552
3553         Reviewed by Kenneth Russell.
3554
3555         AudioContext noteGrainOn() method should not apply explicit windowing
3556         https://bugs.webkit.org/show_bug.cgi?id=63005
3557
3558         No new tests since audio API is not yet implemented.
3559
3560         * webaudio/AudioBufferSourceNode.cpp:
3561         (WebCore::AudioBufferSourceNode::readFromBuffer):
3562         * webaudio/AudioBufferSourceNode.h:
3563
3564 2011-06-22  Kentaro Hara  <haraken@google.com>
3565
3566         Reviewed by Tony Chang.
3567
3568         Check |keypath| argument of createObjectStore(). Remove storage/indexeddb/keypath-as-array.html.
3569         https://bugs.webkit.org/show_bug.cgi?id=63054
3570
3571         At the head of createObjectStore(), we parse |keypath| argument and throw an exception
3572         if the |keypath| is invalid. With this parsing, we remove keypath-as-array.html because
3573         the current keypath parser does not support an array of keypath and (more importantly)
3574         the current implementation of ObjectStore does not support multiple keypaths.
3575         We added keypath-basics.html that demonstrates that we do not support an array of keypaths.
3576
3577         Tests: storage/indexeddb/keypath-basics.html
3578
3579         * storage/IDBDatabase.cpp:
3580         (WebCore::IDBDatabase::createObjectStore):
3581         * storage/IDBKeyPath.cpp:
3582         (WebCore::IDBIsValidKeyPath):
3583         * storage/IDBKeyPath.h:
3584
3585 2011-06-22  Young Han Lee  <joybro@company100.net>
3586
3587         Reviewed by Simon Fraser.
3588
3589         animation-timing-function property with a list uses first item for all animations
3590         https://bugs.webkit.org/show_bug.cgi?id=60303
3591
3592         When an element has multiple animations that have different timingFunctions,
3593         the progress of each animation should be calculated using its respective timingFunction.
3594         But at this point, the timingFunction of the first animation is only used for the
3595         calculation, regardless of how many animations the element has.
3596
3597         The code for getting a timingFunction is changed by this patch
3598         so that the timingFunction of the correct animation searched by its name will be used.
3599
3600         Test: animations/multiple-animations-timing-function.html
3601
3602         * page/animation/KeyframeAnimation.cpp:
3603         (WebCore::getAnimationFromStyleByName):
3604         (WebCore::KeyframeAnimation::fetchIntervalEndpointsForProperty):
3605
3606 2011-06-22  Sheriff Bot  <webkit.review.bot@gmail.com>
3607
3608         Unreviewed, rolling out r89407, r89409, r89410, and r89411.
3609         http://trac.webkit.org/changeset/89407
3610         http://trac.webkit.org/changeset/89409
3611         http://trac.webkit.org/changeset/89410
3612         http://trac.webkit.org/changeset/89411
3613         https://bugs.webkit.org/show_bug.cgi?id=63168
3614
3615         Broke Chromium tests for Forms and Autofill (Requested by
3616         dimich on #webkit).
3617
3618         * css/html.css:
3619         (input[type="search"]::-webkit-search-cancel-button):
3620         (input[type="search"]::-webkit-search-decoration):
3621         (input[type="search"]::-webkit-search-results-decoration):
3622         (input[type="search"]::-webkit-search-results-button):
3623         (input::-webkit-inner-spin-button):
3624         (input::-webkit-input-speech-button):
3625         * html/HTMLInputElement.cpp:
3626         * html/HTMLInputElement.h:
3627         * html/InputType.h:
3628         * html/SearchInputType.cpp:
3629         (WebCore::SearchInputType::SearchInputType):
3630         (WebCore::SearchInputType::createShadowSubtree):
3631         (WebCore::SearchInputType::destroyShadowSubtree):
3632         * html/SearchInputType.h:
3633         (WebCore::SearchInputType::innerBlockElement):
3634         * html/TextFieldInputType.cpp:
3635         (WebCore::TextFieldInputType::TextFieldInputType):
3636         (WebCore::TextFieldInputType::createShadowSubtree):
3637         (WebCore::TextFieldInputType::destroyShadowSubtree):
3638         * html/TextFieldInputType.h:
3639         (WebCore::TextFieldInputType::innerTextElement):
3640         (WebCore::TextFieldInputType::innerSpinButtonElement):
3641         (WebCore::TextFieldInputType::speechButtonElement):
3642         (WebCore::TextFieldInputType::setInnerTextElement):
3643         (WebCore::TextFieldInputType::setSpeechButtonElement):
3644         * rendering/RenderTextControlSingleLine.cpp:
3645         (WebCore::RenderTextControlSingleLine::innerTextElement):
3646         (WebCore::RenderTextControlSingleLine::layout):
3647         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
3648         (WebCore::RenderTextControlSingleLine::forwardEvent):
3649         (WebCore::RenderTextControlSingleLine::styleDidChange):
3650         (WebCore::RenderTextControlSingleLine::hasControlClip):
3651         (WebCore::RenderTextControlSingleLine::controlClipRect):
3652         (WebCore::RenderTextControlSingleLine::textBlockWidth):
3653         (WebCore::RenderTextControlSingleLine::createInnerTextStyle):
3654         (WebCore::RenderTextControlSingleLine::createInnerBlockStyle):
3655         (WebCore::RenderTextControlSingleLine::textBlockInsetTop):
3656         * rendering/RenderTextControlSingleLine.h:
3657
3658 2011-06-20  Mikhail Naganov  <mnaganov@chromium.org>
3659
3660         Reviewed by Pavel Feldman.
3661
3662         Web Inspector: [Chromium] Improve speed of heap profiles dominators view.
3663         https://bugs.webkit.org/show_bug.cgi?id=62979
3664
3665         * inspector/front-end/DetailedHeapshotGridNodes.js:
3666         (WebInspector.HeapSnapshotDominatorObjectNode.prototype._createProvider):
3667         * inspector/front-end/HeapSnapshot.js:
3668         (WebInspector.HeapSnapshotArraySlice.prototype.item):
3669         (WebInspector.HeapSnapshotArraySlice.prototype.slice):
3670         (WebInspector.HeapSnapshot.prototype.dispose):
3671         (WebInspector.HeapSnapshot.prototype._dominatedNodesOfNode):
3672         (WebInspector.HeapSnapshot.prototype._buildReverseIndex.var):
3673         (WebInspector.HeapSnapshot.prototype._buildReverseIndex):
3674         (WebInspector.HeapSnapshot.prototype._buildRetainers):
3675         (WebInspector.HeapSnapshot.prototype._buildNodeIndex):
3676         (WebInspector.HeapSnapshot.prototype._buildDominatedNodes):
3677         (WebInspector.HeapSnapshot.prototype._getDominatedIndex):
3678         (WebInspector.HeapSnapshot.prototype.createNodesProviderForClass):
3679         (WebInspector.HeapSnapshot.prototype.createNodesProviderForDominator):
3680         (WebInspector.HeapSnapshotFilteredOrderedIterator):
3681         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype._createIterationOrder):
3682         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.get length):
3683         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.serializeNextItems):
3684         (WebInspector.HeapSnapshotNodesProvider):
3685         * inspector/front-end/HeapSnapshotProxy.js:
3686         (WebInspector.HeapSnapshotProxy.prototype.createNodesProviderForDominator):
3687
3688 2011-06-22  Sreeram Ramachandran  <sreeram@chromium.org>
3689
3690         Reviewed by Pavel Feldman.
3691
3692         Web Inspector: Restore console messages when restoring inspector state
3693         https://bugs.webkit.org/show_bug.cgi?id=63146
3694
3695         No new tests (no change in functionality, only in display).
3696
3697         * inspector/InspectorConsoleAgent.cpp:
3698         (WebCore::InspectorConsoleAgent::restore):
3699         * inspector/InspectorConsoleAgent.h:
3700         * inspector/InspectorController.cpp:
3701         (WebCore::InspectorController::restoreInspectorStateFromCookie):
3702
3703 2011-06-22  Adam Barth  <abarth@webkit.org>
3704
3705         Attempt to fix the GTK build after my incomplete rollout of 88332.
3706
3707         * GNUmakefile.list.am:
3708
3709 2011-06-22  Sam Weinig  <sam@webkit.org>
3710
3711         Reviewed by Adam Barth.
3712
3713         HTML parser should limit element depth of produced tree
3714         https://bugs.webkit.org/show_bug.cgi?id=63082
3715
3716         Test by:
3717             fast/parser/block-nesting-cap.html
3718             fast/parser/element-nesting-cap.html
3719
3720         * html/parser/HTMLConstructionSite.cpp:
3721         (WebCore::HTMLConstructionSite::attach):
3722         (WebCore::HTMLConstructionSite::HTMLConstructionSite):
3723         * html/parser/HTMLConstructionSite.h:
3724         Limit the DOM tree depth by turning attempts to add a child passed a certain
3725         threshold (configurable by Settings::maximumDOMTreeDepth) into a sibling.
3726
3727         * html/parser/HTMLDocumentParser.cpp:
3728         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
3729         (WebCore::HTMLDocumentParser::maximumDOMTreeDepth):
3730         * html/parser/HTMLDocumentParser.h:
3731         Pass the maximumDOMTreeDepth to the TreeBuilder.
3732
3733         * html/parser/HTMLElementStack.cpp:
3734         (WebCore::HTMLElementStack::HTMLElementStack):
3735         (WebCore::HTMLElementStack::popAll):
3736         (WebCore::HTMLElementStack::insertAbove):
3737         (WebCore::HTMLElementStack::pushCommon):
3738         (WebCore::HTMLElementStack::popCommon):
3739         (WebCore::HTMLElementStack::removeNonTopCommon):
3740         * html/parser/HTMLElementStack.h:
3741         (WebCore::HTMLElementStack::size):
3742         Keep track of the size of the element stack.
3743
3744         * html/parser/HTMLTreeBuilder.cpp:
3745         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
3746         * html/parser/HTMLTreeBuilder.h:
3747         (WebCore::HTMLTreeBuilder::create):
3748         Pass the maximumDOMTreeDepth to the construction site.
3749
3750         * page/Settings.cpp:
3751         (WebCore::Settings::Settings):
3752         * page/Settings.h:
3753         (WebCore::Settings::setMaximumHTMLParserDOMTreeDepth):
3754         (WebCore::Settings::maximumHTMLParserDOMTreeDepth):
3755         Add a setting to control the maximum DOM tree depth that the parser will produce.
3756
3757 2011-06-22  Adam Barth  <abarth@webkit.org>
3758
3759         Rollout 88332.  As discussed on webkit-dev, we'd like to iterate on
3760         both the API and it's implementation a bit.
3761
3762         * WebCore.gypi:
3763         * bindings/generic/RuntimeEnabledFeatures.cpp:
3764         * bindings/generic/RuntimeEnabledFeatures.h:
3765         * dom/DocumentMarker.h:
3766         (WebCore::DocumentMarker::activeMatch):
3767         * dom/DocumentMarkerController.cpp:
3768         * dom/DocumentMarkerController.h:
3769         * html/HTMLDivElement.cpp:
3770         * html/HTMLDivElement.h:
3771         * html/HTMLDivElement.idl:
3772         * html/HTMLInputElement.cpp:
3773         * html/HTMLInputElement.h:
3774         * html/HTMLInputElement.idl:
3775         * html/HTMLTextAreaElement.cpp:
3776         * html/HTMLTextAreaElement.h:
3777         * html/HTMLTextAreaElement.idl:
3778         * html/SpellcheckRange.cpp: Removed.
3779         * html/SpellcheckRange.h: Removed.
3780         * html/SpellcheckRange.idl: Removed.
3781         * html/SpellcheckRangeList.cpp: Removed.
3782         * html/SpellcheckRangeList.h: Removed.
3783         * html/SpellcheckRangeList.idl: Removed.
3784         * rendering/InlineTextBox.cpp:
3785         (WebCore::textCheckingLineStyleForMarkerType):
3786         (WebCore::InlineTextBox::paintDocumentMarkers):
3787
3788 2011-06-22  Mark Pilgrim  <pilgrim@chromium.org>
3789
3790         Reviewed by Adam Barth.
3791
3792         IndexedDB: fix multiple issues in IDBDatabase.idl
3793         https://bugs.webkit.org/show_bug.cgi?id=63140
3794
3795         Tests: storage/indexeddb/createObjectStore-name-argument-required.html
3796                storage/indexeddb/createObjectStore-null-name.html
3797                storage/indexeddb/deleteObjectStore-name-argument-required.html
3798                storage/indexeddb/deleteObjectStore-null-name.html
3799                storage/indexeddb/setVersion-null.html
3800                storage/indexeddb/transaction-storeNames-required.html
3801
3802         * storage/IDBDatabase.idl: remove LegacyDefaultOptionalArguments so
3803         all functions will throw TypeError when called with too few arguments,
3804         as per WebIDL spec. Also remove ConvertNullToNullString flags so null
3805         values are stringified as "null" (also as per WebIDL spec).
3806
3807 2011-06-22  Vsevolod Vlasov  <vsevik@chromium.org>
3808
3809         Reviewed by Pavel Feldman.
3810
3811         Web Inspector: Move logic for deciding whether resource content should be base64 encoded on backend.
3812         https://bugs.webkit.org/show_bug.cgi?id=63069
3813
3814         * inspector/Inspector.json:
3815         * inspector/InspectorPageAgent.cpp:
3816         (WebCore::InspectorPageAgent::cachedResourceContent):
3817         (WebCore::InspectorPageAgent::resourceContent):
3818         (WebCore::InspectorPageAgent::getResourceContent):
3819         (WebCore::InspectorPageAgent::searchInResources):
3820         * inspector/InspectorPageAgent.h:
3821         * inspector/InspectorResourceAgent.cpp:
3822         (WebCore::InspectorResourceAgent::getResourceContent):
3823         * inspector/InspectorResourceAgent.h:
3824         * inspector/InspectorStyleSheet.cpp:
3825         (WebCore::InspectorStyleSheet::resourceStyleSheetText):
3826         * inspector/front-end/NetworkManager.js:
3827         (WebInspector.NetworkManager.prototype.requestContent):
3828         * inspector/front-end/Resource.js:
3829         (WebInspector.Resource.prototype._innerRequestContent.onResourceContent):
3830         (WebInspector.Resource.prototype._innerRequestContent):
3831
3832 2011-06-22  Luke Macpherson   <macpherson@chromium.org>
3833
3834         Reviewed by Dimitri Glazkov.
3835
3836         Support cast from CSSPrimitiveValue to short and use for CSSPropertyWidows and CSSPropertyOrphans.
3837         https://bugs.webkit.org/show_bug.cgi?id=62964
3838
3839         No new tests / refactoring only.
3840
3841         * css/CSSPrimitiveValueMappings.h:
3842         Support cast to/from short.
3843         * css/CSSStyleSelector.cpp:
3844         (WebCore::CSSStyleSelector::applyProperty):
3845         Use cast to short to allow CSSPropertWidows and CSSPropertyOrphans to use existing macro.
3846
3847 2011-06-22  Eunmi Lee  <eunmi15.lee@samsung.com>
3848
3849         Reviewed by Martin Robinson.
3850
3851         Change GtkWidgetBackingStore.h to WidgetBackingStore.h in order to use in the EFL port.
3852         https://bugs.webkit.org/show_bug.cgi?id=62848
3853
3854         This patch will make GtkWidgetBackingStore shareable with EFL port.
3855         It is a preparation to integrate WebKit2's BackingStoreGtk.cpp and
3856         BackingStoreEfl.cpp as a BackingStoreCairo.cpp.
3857
3858         * GNUmakefile.am:
3859         * GNUmakefile.list.am:
3860         * platform/graphics/cairo/CairoUtilities.cpp:
3861         (WebCore::copyRectFromOneSurfaceToAnother):
3862         * platform/graphics/cairo/CairoUtilities.h:
3863         * platform/cairo/WidgetBackingStore.h: Added.
3864         * platform/gtk/GtkWidgetBackingStore.h: Removed.
3865         * platform/gtk/GtkWidgetBackingStoreCairo.cpp:
3866         (WebCore::createSurfaceForBackingStore):
3867         (WebCore::WidgetBackingStorePrivate::create):
3868         (WebCore::WidgetBackingStorePrivate::WidgetBackingStorePrivate):
3869         (WebCore::WidgetBackingStore::create):
3870         (WebCore::WidgetBackingStore::WidgetBackingStore):
3871         (WebCore::WidgetBackingStore::~WidgetBackingStore):
3872         (WebCore::WidgetBackingStore::cairoSurface):
3873         (WebCore::WidgetBackingStore::scroll):
3874         * platform/gtk/GtkWidgetBackingStoreX11.cpp:
3875         (WebCore::WidgetBackingStorePrivate::create):
3876         (WebCore::WidgetBackingStorePrivate::~WidgetBackingStorePrivate):
3877         (WebCore::WidgetBackingStorePrivate::WidgetBackingStorePrivate):
3878         (WebCore::WidgetBackingStore::create):
3879         (WebCore::WidgetBackingStore::WidgetBackingStore):
3880         (WebCore::WidgetBackingStore::~WidgetBackingStore):
3881         (WebCore::WidgetBackingStore::cairoSurface):
3882         (WebCore::WidgetBackingStore::scroll):
3883
3884 2011-06-22  Simon Fraser  <simon.fraser@apple.com>
3885
3886         Reviewed by Dan Bernstein.
3887
3888         Update position, bounds and anchor point in GraphicsLayerCA all at once
3889         https://bugs.webkit.org/show_bug.cgi?id=63148
3890
3891         Since position, bounds and anchor point are inter-dependent, avoid
3892         redundant work by simply updating them all at the same time.
3893         
3894         No behavior changes, so no new tests.
3895
3896         * platform/graphics/ca/GraphicsLayerCA.cpp:
3897         (WebCore::GraphicsLayerCA::setPosition):
3898         (WebCore::GraphicsLayerCA::setAnchorPoint):
3899         (WebCore::GraphicsLayerCA::setSize):
3900         (WebCore::GraphicsLayerCA::setBoundsOrigin):
3901         (WebCore::GraphicsLayerCA::setAllowTiledLayer):
3902         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
3903         (WebCore::GraphicsLayerCA::updateGeometry):
3904         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
3905         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
3906         * platform/graphics/ca/GraphicsLayerCA.h:
3907
3908 2011-06-22  Ryosuke Niwa  <rniwa@webkit.org>
3909
3910         Reviewed by Darin Adler.
3911
3912         Make instantiation of legacy editing position more explicit
3913         https://bugs.webkit.org/show_bug.cgi?id=63037
3914
3915         Replaced the constructor of Position class that used to instantiate a legacy editing position
3916         by a function called createLegacyEditingPosition.
3917
3918         * WebCore.exp.in: Removed the constructor from the list.
3919         * accessibility/AXObjectCache.cpp:
3920         (WebCore::AXObjectCache::visiblePositionForTextMarkerData): Calls createLegacyEditingPosition.
3921         * accessibility/gtk/AXObjectCacheAtk.cpp:
3922         (WebCore::AXObjectCache::nodeTextChangePlatformNotification): No longer uses Positions to instantiate a range.
3923         * dom/Position.cpp:
3924         (WebCore::Position::Position): New constructor takes LegacyEditingOffset, which can only be instantiated
3925         by createLegacyEditingPosition.
3926         (WebCore::Position::previous): Calls createLegacyEditingPosition.
3927         (WebCore::Position::next): Ditto.
3928         (WebCore::Position::upstream): Ditto.
3929         (WebCore::Position::downstream): Ditto.
3930         * dom/Position.h: Added new Position::LegacyEditingOffset class to hide the legacy constructor from the world.
3931         (WebCore::Position::LegacyEditingOffset::value): Added.
3932         (WebCore::Position::LegacyEditingOffset::LegacyEditingOffset): Added.
3933         (WebCore::createLegacyEditingPosition): Added.
3934         * dom/PositionIterator.cpp:
3935         (WebCore::PositionIterator::operator Position): Calls createLegacyEditingPosition.
3936         * dom/RangeBoundaryPoint.h:
3937         (WebCore::RangeBoundaryPoint::toPosition): Ditto.
3938         * editing/InsertTextCommand.cpp:
3939         (WebCore::InsertTextCommand::performTrivialReplace): Instantiates new Position instead of old one; this is always
3940         safe since the anchor node is always a text node.
3941         * editing/VisiblePosition.cpp:
3942         (WebCore::VisiblePosition::leftVisuallyDistinctCandidate): Calls createLegacyEditingPosition.
3943         (WebCore::VisiblePosition::rightVisuallyDistinctCandidate): Ditto.
3944         * editing/markup.cpp:
3945         (WebCore::StyledMarkupAccumulator::renderedText): Ditto.
3946         * editing/visible_units.cpp:
3947         (WebCore::previousBoundary): Ditto.
3948         (WebCore::previousLinePosition): Ditto.
3949         (WebCore::nextLinePosition): Ditto.
3950         * page/DOMSelection.cpp:
3951         (WebCore::DOMSelection::collapse): Ditto.
3952         (WebCore::DOMSelection::setBaseAndExtent): Ditto.
3953         (WebCore::DOMSelection::setPosition): Ditto.
3954         (WebCore::DOMSelection::extend): Ditto.
3955         * rendering/RenderBlock.cpp:
3956         (WebCore::RenderBlock::positionForBox): Ditto.
3957         * rendering/RenderBox.cpp:
3958         (WebCore::RenderBox::positionForPoint): Calls Position() instead of Position(0, 0).
3959         * rendering/RenderObject.cpp:
3960         (WebCore::RenderObject::createVisiblePosition): Calls createLegacyEditingPosition.s
3961
3962 2011-06-22  Pavel Feldman  <pfeldman@google.com>
3963
3964         Reviewed by Yury Semikhatsky.
3965
3966         Web Inspector: split setAttributes and setAttributeValue.
3967         https://bugs.webkit.org/show_bug.cgi?id=63138
3968
3969         * inspector/Inspector.json:
3970         * inspector/InspectorDOMAgent.cpp:
3971         (WebCore::InspectorDOMAgent::setAttributeValue):
3972         (WebCore::InspectorDOMAgent::setAttributesText):
3973         * inspector/InspectorDOMAgent.h:
3974         * inspector/front-end/DOMAgent.js:
3975         (WebInspector.DOMNode.prototype.setAttribute):
3976         (WebInspector.DOMNode.prototype.setAttributeValue):
3977
3978 2011-06-22  Dirk Schulze  <krit@webkit.org>
3979
3980         Reviewed by Nikolas Zimmermann.
3981
3982         Animate viewBox attribute in SVG
3983         https://bugs.webkit.org/show_bug.cgi?id=20057
3984
3985         Follow up of "SVGAnimation should use direct unit animation for SVGLength": https://bugs.webkit.org/show_bug.cgi?id=61368
3986         This patch continues the conversion to the new concept of SVGAnimatorFactory with SVGRect. With the new animator we support
3987         interpolation between SVGRects. A feature that can be used to get smooth zooming animations for SVGs.
3988         
3989         Added parseRect() to SVGParserUtilities for parsing Strings to FloatRects.
3990
3991         Tests: svg/animations/svgrect-animation-1.html
3992                svg/animations/svgrect-animation-2.html
3993
3994         * CMakeLists.txt: Added new file SVGAnimatedRect.cpp to build system.
3995         * GNUmakefile.list.am: Ditto.
3996         * WebCore.gypi: Ditto.
3997         * WebCore.pro: Ditto.
3998         * WebCore.xcodeproj/project.pbxproj: Ditto.
3999         * platform/graphics/FloatRect.h: Added new operators + and +=.
4000         (WebCore::operator+=):
4001         (WebCore::operator+):
4002         * svg/SVGAllInOne.cpp: Added SVGAnimatedRect.cpp for Win build.
4003         * svg/SVGAnimateElement.cpp: Handle AnimatedRect explicitly.
4004         (WebCore::SVGAnimateElement::determineAnimatedAttributeType): Ditto.
4005         (WebCore::SVGAnimateElement::calculateAnimatedValue): Ditto.
4006         (WebCore::SVGAnimateElement::calculateFromAndToValues): Ditto.
4007         (WebCore::SVGAnimateElement::calculateFromAndByValues): Ditto.
4008         (WebCore::SVGAnimateElement::resetToBaseValue): Ditto.
4009