239688fbbb32eb632d9f40ddd9620c688f1752fb
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-01-18  Stephen Chenney  <schenney@chromium.org>
2
3         Asserts when textPath is used with no path
4         https://bugs.webkit.org/show_bug.cgi?id=107324
5
6         Reviewed by Eric Seidel.
7
8         We assert when there is no path associated with an SVG text path
9         element. Instead, this patch detects the condition and stops trying to
10         layout text for that textPath  element.
11
12         Test: svg/text/tpath-without-path.svg
13
14         * rendering/svg/SVGTextLayoutEngine.cpp:
15         (WebCore::SVGTextLayoutEngine::beginTextPathLayout):
16         (WebCore::SVGTextLayoutEngine::layoutTextOnLineOrPath):
17
18 2013-01-22  Andrey Adaikin  <aandrey@chromium.org>
19
20         Web Inspector: [Canvas] jump to prev/next drawing call in the replay
21         https://bugs.webkit.org/show_bug.cgi?id=107551
22
23         Reviewed by Pavel Feldman.
24
25         Implement jumping to the next(previous) drawing call in the WebGL and canvas 2D replay.
26
27         * English.lproj/localizedStrings.js:
28         * inspector/InjectedScriptCanvasModuleSource.js:
29         (.):
30         * inspector/Inspector.json:
31         * inspector/front-end/CanvasProfileView.js:
32         (WebInspector.CanvasProfileView):
33         (WebInspector.CanvasProfileView.prototype.dispose):
34         (WebInspector.CanvasProfileView.prototype._onReplayDrawingCallClick):
35         * inspector/front-end/canvasProfiler.css:
36         (.canvas-replay-prev-draw img):
37         (.canvas-replay-next-draw img):
38
39 2013-01-22  Andrey Lushnikov  <lushnikov@chromium.org>
40
41         Web Inspector: remove asynchronous behavior from DTE paintLines method
42         https://bugs.webkit.org/show_bug.cgi?id=107550
43
44         Reviewed by Pavel Feldman.
45
46         Remove paintLinesOperationCredit and all asynchronous behaviour from paintLines method;
47         also, remove paintLineChunks method.
48
49         * inspector/front-end/DefaultTextEditor.js:
50         (WebInspector.TextEditorMainPanel.prototype.expandChunks):
51         (WebInspector.TextEditorMainPanel.prototype._highlightDataReady):
52         (WebInspector.TextEditorMainPanel.prototype._paintLines):
53         (WebInspector.TextEditorMainPanel.prototype._renderRanges):
54         (WebInspector.TextEditorMainPanel.prototype._paintLine):
55         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
56
57 2013-01-22  Eugene Klyuchnikov  <eustas@chromium.org>
58
59         Web Inspector: [Network] "Secure" cookies can not be deleted.
60         https://bugs.webkit.org/show_bug.cgi?id=107543
61
62         Reviewed by Pavel Feldman.
63
64         To delete secure cookie URL schema need to be "https" instead of "http".
65
66         * inspector/front-end/CookieItemsView.js:
67         (WebInspector.CookieItemsView.prototype._deleteCookie):
68         Take care of secure cookies.
69
70 2013-01-22  Sheriff Bot  <webkit.review.bot@gmail.com>
71
72         Unreviewed, rolling out r140420.
73         http://trac.webkit.org/changeset/140420
74         https://bugs.webkit.org/show_bug.cgi?id=107557
75
76         Still causes crashes (EFL this time) (Requested by kov on
77         #webkit).
78
79         * platform/graphics/gstreamer/GStreamerVersioning.cpp:
80         * platform/graphics/gstreamer/GStreamerVersioning.h:
81         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
82         (StreamingClient):
83         (_WebKitWebSrcPrivate):
84         (webKitWebSrcFinalize):
85         (webKitWebSrcStop):
86         (StreamingClient::didReceiveData):
87         * platform/network/ResourceHandleClient.h:
88         (ResourceHandleClient):
89         * platform/network/ResourceHandleInternal.h:
90         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
91         (ResourceHandleInternal):
92         * platform/network/soup/ResourceHandleSoup.cpp:
93         (WebCore::cleanupSoupRequestOperation):
94         (WebCore::nextMultipartResponsePartCallback):
95         (WebCore::sendRequestCallback):
96         (WebCore::readCallback):
97
98 2013-01-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
99
100         [Qt] Crash in PasteboardQt.cpp Pasteboard::writeSelection
101         https://bugs.webkit.org/show_bug.cgi?id=102192
102
103         Patch by Fabien Valée
104         Reviewed by Jocelyn Turcotte.
105
106         QClipboard::setMimeData transfers ownership of QMimeData to the clipboard,
107         so we should not access it afterwards.
108
109         * platform/qt/PasteboardQt.cpp:
110         (WebCore::Pasteboard::writeSelection):
111         (WebCore::Pasteboard::writePlainText):
112
113 2013-01-22  Christophe Dumez  <christophe.dumez@intel.com>
114
115         Regression(r140414): It is causing crashes with gstreamer 0.10
116         https://bugs.webkit.org/show_bug.cgi?id=107554
117
118         Reviewed by Philippe Normand.
119
120         gstreamer 0.10 doc led me to believe that gst_element_factory_make()
121         was not returning a floating reference. However, based on testing
122         (and results on Qt port) it does so we should NOT adopt the
123         returned GstElement object.
124
125         No new tests, already covered by existing tests.
126
127         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
128
129 2013-01-22  Andrey Lushnikov  <lushnikov@chromium.org>
130
131         Web Inspector: do not highlight really long lines in DTE.
132         https://bugs.webkit.org/show_bug.cgi?id=107531
133
134         Reviewed by Pavel Feldman.
135
136         Improve TextEditorHighlighter.orderedRangesPerLine method to return
137         only ranges that start before particular column.
138
139         Test: inspector/editor/text-editor-long-line.html
140
141         * inspector/front-end/TextEditorHighlighter.js:
142         (WebInspector.TextEditorHighlighter):
143         (WebInspector.TextEditorHighlighter.prototype.setHighlightLineLimit):
144         (WebInspector.TextEditorHighlighter.prototype.orderedRangesPerLine.comparator):
145         (WebInspector.TextEditorHighlighter.prototype.orderedRangesPerLine):
146
147 2013-01-22  Gustavo Noronha Silva  <gustavo.noronha@collabora.com>
148
149         [GStreamer][Soup] Let GStreamer provide the buffer data is downloaded to, to avoid copying
150         https://bugs.webkit.org/show_bug.cgi?id=105552
151
152         Reviewed by Philippe Normand.
153
154         Makes it possible for the GStreamer media backend to provide the buffer to which
155         the Soup networking backend will use to download data to. This makes copying
156         memory unnecessary when ResourceHandle hands data over to the media player's
157         StreamingClient. Thanks to Dan Winship for help designing the interface.
158
159         No behaviour change, covered by existing tests.
160
161         * platform/graphics/gstreamer/GStreamerVersioning.cpp:
162         (createGstBufferForData): New helper to create a GstBuffer when
163         we have a data pointer and a length.
164         (getGstBufferSize): Abstract obtaining the size of the buffer, so the code
165         is cleaner while still working for both GST 0.10 and 1.0.
166         (setGstBufferSize): Ditto, but for setting the size.
167         (getGstBufferDataPointer): Ditto, but for grabbing the data pointer.
168         (mapGstBuffer): Convenience method to take care of mapping the buffer so that
169         we can provide the data pointer to ResourceHandle.
170         (unmapGstBuffer): Convenience method which takes care of unmapping the buffer
171         and properly freeing the GstMapInfo.
172         * platform/graphics/gstreamer/GStreamerVersioning.h:
173         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
174         (StreamingClient): New methods.
175         (_WebKitWebSrcPrivate): We now store the GstBuffer we provided the data pointer from
176         so we can later unmap it and push it to the pipeline.
177         (webKitWebSrcDispose): Deal with the GstBuffer in case it exists when the source is
178         destroyed.
179         (webKitWebSrcStop): Also clear the GstBuffer in this case.
180         (StreamingClient::didReceiveData): Handle the hand-over of the buffer.
181         (StreamingClient::getBuffer): Provide ResourceHandle with a new GstBuffer's data pointer.
182         * platform/network/ResourceHandleClient.h:
183         (ResourceHandleClient):
184         (WebCore::ResourceHandleClient::ResourceHandleClient): Constructor to initialize the buffer
185         member variable to 0.
186         (WebCore::ResourceHandleClient::~ResourceHandleClient): Destructor to free the buffer if it
187         has been allocated.
188         (WebCore::ResourceHandleClient::getBuffer): Default implementation which returns a
189         newly allocated char pointer.
190         * platform/network/ResourceHandleInternal.h:
191         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
192         (ResourceHandleInternal): Store actual buffer size, which is no longer a constant.
193         * platform/network/soup/ResourceHandleSoup.cpp:
194         (WebCore::cleanupSoupRequestOperation): Clear the buffer pointer, the life-cycle of the
195         buffer is handled by the ResourceHandleClient.
196         (WebCore::nextMultipartResponsePartCallback): Get a new buffer from the client before reading.
197         (WebCore::sendRequestCallback): Ditto.
198         (WebCore::readCallback): Ditto.
199
200 2013-01-22  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
201
202         [EFL] Fix context menu localized string
203         https://bugs.webkit.org/show_bug.cgi?id=107536
204
205         One of localized string has a marker. Since EFL port does not support them
206         it has to be removed, so the string will be displayed properly.
207
208         Reviewed by Laszlo Gombos.
209
210         * platform/efl/LocalizedStringsEfl.cpp:
211         (WebCore::contextMenuItemTagCheckSpellingWhileTyping)
212
213 2013-01-22  Sheriff Bot  <webkit.review.bot@gmail.com>
214
215         Unreviewed, rolling out r140412.
216         http://trac.webkit.org/changeset/140412
217         https://bugs.webkit.org/show_bug.cgi?id=107549
218
219         Broke rendering of buttons on gmail (Requested by carewolf on
220         #webkit).
221
222         * platform/graphics/qt/TransparencyLayer.h:
223         (WebCore::TransparencyLayer::TransparencyLayer):
224
225 2013-01-22  Christophe Dumez  <christophe.dumez@intel.com>
226
227         [gstreamer] MediaPlayerPrivateGStreamer should take ownership of the playbin
228         https://bugs.webkit.org/show_bug.cgi?id=107445
229
230         Reviewed by Philippe Normand.
231
232         In gstreamer 1.0, gst_element_factory_make() now returns a floating reference.
233         MediaPlayerPrivateGStreamer calls gst_element_factory_make() to create the
234         playbin object but does not take ownership of the object. As a consequence,
235         the object keeps floating until it is unref'd in the
236         MediaPlayerPrivateGStreamer destructor.
237
238         This patch uses a GRefPtr<GstElement> to store the playbin object and only
239         adopt the object returned by gst_element_factory_make() if gstreamer 0.10
240         is used. When gstreamer 1.0 is used, the returned object will not be adopted,
241         which will remove the floating reference. This way, we ensure that the
242         playbin object is owned by MediaPlayerPrivateGStreamer.
243
244         No new tests, no behavior change for layout tests.
245
246         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
247         (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer):
248         (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer):
249         (WebCore::MediaPlayerPrivateGStreamer::load):
250         (WebCore::MediaPlayerPrivateGStreamer::playbackPosition):
251         (WebCore::MediaPlayerPrivateGStreamer::changePipelineState):
252         (WebCore::MediaPlayerPrivateGStreamer::duration):
253         (WebCore::MediaPlayerPrivateGStreamer::seek):
254         (WebCore::MediaPlayerPrivateGStreamer::paused):
255         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo):
256         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio):
257         (WebCore::MediaPlayerPrivateGStreamer::setVolume):
258         (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVolumeChange):
259         (WebCore::MediaPlayerPrivateGStreamer::setRate):
260         (WebCore::MediaPlayerPrivateGStreamer::buffered):
261         (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
262         (WebCore::MediaPlayerPrivateGStreamer::fillTimerFired):
263         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
264         (MediaPlayerPrivateGStreamer):
265
266 2013-01-22  Yury Semikhatsky  <yurys@chromium.org>
267
268         Unreviewed. Fix closure compiler warning in inspector front-end after r140390.
269
270         * inspector/front-end/HeapSnapshotView.js:
271
272 2013-01-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
273
274         [Qt] Box shadows on a transparency layer is very slow
275         https://bugs.webkit.org/show_bug.cgi?id=107547
276
277         Reviewed by Noam Rosenthal.
278
279         Set an initial clip on the transparency layer, so that the clipping
280         bounds will never end up larger than the layer.
281
282         * platform/graphics/qt/TransparencyLayer.h:
283         (WebCore::TransparencyLayer::TransparencyLayer):
284
285 2013-01-22  Matt Falkenhagen  <falken@chromium.org>
286
287         Move top layer flag from ElementRareData to NodeFlags
288         https://bugs.webkit.org/show_bug.cgi?id=107542
289
290         Reviewed by Hajime Morita.
291
292         This is a speculative fix for a perf regression (https://bugs.webkit.org/show_bug.cgi?id=106726)
293         likely due to checking the top layer flag in Element::removedFrom. It
294         also simplifies code dealing with top layer and makes it no longer
295         necessary to allocate rare data for top layer.
296
297         * dom/Element.cpp:
298         (WebCore::Element::removedFrom): Check isInTopLayer first in case it helps fix the perf regression.
299         (WebCore):
300         * dom/Element.h: Move top layer functions from Element to Node.
301         * dom/ElementRareData.h:
302         (ElementRareData):
303         (WebCore::ElementRareData::ElementRareData): Remove top layer flag from ElementRareData.
304         * dom/Node.cpp: Move top layer functions from Element to Node.  
305         (WebCore):
306         (WebCore::Node::setIsInTopLayer):
307         * dom/Node.h:
308         (Node):
309         (WebCore::Node::isInTopLayer):
310         * dom/NodeRenderingContext.cpp: Remove unnecessary casts to Element for isInTopLayer().
311         (WebCore::isRendererReparented):
312         (WebCore::NodeRenderingContext::previousRenderer):
313         (WebCore::NodeRenderingContext::parentRenderer):
314         * rendering/RenderLayer.cpp: Ditto.
315         (WebCore::RenderLayer::isInTopLayer):
316         (WebCore::RenderLayer::rebuildZOrderLists):
317
318 2013-01-22  Mark Lam  <mark.lam@apple.com>
319
320         Fix broken mac builds due to <http://trac.webkit.org/changeset/140399>.
321         https://bugs.webkit.org/show_bug.cgi?id=100710.
322
323         Not reviewed.
324
325         No new tests.
326
327         * WebCore.xcodeproj/project.pbxproj:
328
329 2013-01-22  Dan Carney  <dcarney@google.com>
330
331         [v8] Convert string conversion calls to one byte versions
332         https://bugs.webkit.org/show_bug.cgi?id=107524
333
334         Reviewed by Kentaro Hara.
335
336         No new tests. No change in functionality.
337
338         * bindings/v8/SerializedScriptValue.cpp:
339         * bindings/v8/V8StringResource.cpp:
340         (WebCore::WebCoreStringResourceBase::toWebCoreStringResourceBase):
341         (StringTraits):
342         (WebCore::true):
343         (WebCore::v8StringToWebCoreString):
344
345 2013-01-22  Eugene Klyuchnikov  <eustas@chromium.org>
346
347         Web Inspector: [Network] CookiesTable refactoring.
348         https://bugs.webkit.org/show_bug.cgi?id=107511
349
350         Reviewed by Pavel Feldman.
351
352         CookiesTable uses integer indexes as column identifiers.
353         This leads to cryptic code.
354
355         Descriptive column identifiers will make code clearer.
356         Also "addCookiesFolder" replaced with "setCookieFolders" to avoid
357         repetitive "_rebuildTable" invocation.
358
359         * inspector/front-end/CookiesTable.js:
360         (WebInspector.CookiesTable): Use descriptive column identifiers.
361         (WebInspector.CookiesTable.prototype.setCookieFolders):
362         Accept multiple folders.
363         (WebInspector.CookiesTable.prototype._rebuildTable):
364         Use descriptive column identifiers.
365         (WebInspector.CookiesTable.prototype._sortCookies):
366         Ditto.
367         (WebInspector.CookiesTable.prototype._createGridNode):
368         Ditto.
369         * inspector/front-end/RequestCookiesView.js:
370         (WebInspector.RequestCookiesView.prototype._buildCookiesTable):
371         Use "setCookieFolders".
372
373 2013-01-22  Zan Dobersek  <zdobersek@igalia.com>
374
375         [GTK] Disable support for unprefixed CSS animations, transitions, transforms in release builds
376         https://bugs.webkit.org/show_bug.cgi?id=107436
377
378         Reviewed by Alexis Menard.
379
380         Disable the unprefixed CSS animations, transitions and transforms support
381         in the release builds for now. The work in this area is not yet complete
382         and should not ship in such state.
383
384         No new tests - no new functionality.
385
386         * GNUmakefile.features.am.in:
387
388 2013-01-22  Alexander Pavlov  <apavlov@chromium.org>
389
390         Web Inspector: [REGRESSION] SASSSourceMapping broken: _bindUISourceCode method is absent
391         https://bugs.webkit.org/show_bug.cgi?id=107529
392
393         Reviewed by Pavel Feldman.
394
395         * inspector/front-end/SASSSourceMapping.js:
396         (WebInspector.SASSSourceMapping.prototype._fileSaveFinished):
397
398 2013-01-22  Adam Barth  <abarth@webkit.org>
399
400         AtomicMarkupTokenBase must die
401         https://bugs.webkit.org/show_bug.cgi?id=107513
402
403         Reviewed by Eric Seidel.
404
405         Now that NEW_XML has been removed from the tree, there is no reason to
406         have AtomicMarkupTokenBase exist as a templated base class for
407         AtomicHTMLToken. This patch just merges the code back into
408         AtomicHTMLToken.
409
410         * html/parser/HTMLToken.h:
411         (AtomicHTMLToken):
412         (WebCore::AtomicHTMLToken::type):
413         (WebCore::AtomicHTMLToken::name):
414         (WebCore::AtomicHTMLToken::setName):
415         (WebCore::AtomicHTMLToken::selfClosing):
416         (WebCore::AtomicHTMLToken::getAttributeItem):
417         (WebCore::AtomicHTMLToken::attributes):
418         (WebCore::AtomicHTMLToken::characters):
419         (WebCore::AtomicHTMLToken::charactersLength):
420         (WebCore::AtomicHTMLToken::isAll8BitData):
421         (WebCore::AtomicHTMLToken::comment):
422         (WebCore::AtomicHTMLToken::publicIdentifier):
423         (WebCore::AtomicHTMLToken::systemIdentifier):
424         (WebCore::AtomicHTMLToken::clearExternalCharacters):
425         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
426         (WebCore::AtomicMarkupTokenBase::initializeAttributes):
427         (WebCore):
428         * xml/parser/MarkupTokenBase.h:
429
430 2013-01-22  Eric Seidel  <eric@webkit.org>
431
432         Turn on ENABLE_THREADED_HTML_PARSER for Chromium (it's still disabled at runtime)
433         https://bugs.webkit.org/show_bug.cgi?id=107519
434
435         Reviewed by Adam Barth.
436
437         Add some ASSERTs to be double-dog-sure that we're never using
438         any of the threading code when threading is not enabled.
439
440         I also removed an if-branch in the !ENABLE_THREADED_HTML_PARSER case
441         as it's not needed.
442
443         * html/parser/HTMLDocumentParser.cpp:
444         (WebCore::HTMLDocumentParser::prepareToStopParsing):
445         (WebCore::HTMLDocumentParser::startBackgroundParser):
446         (WebCore::HTMLDocumentParser::stopBackgroundParser):
447
448 2013-01-22  Kentaro Hara  <haraken@chromium.org>
449
450         [V8] Make an Isolate parameter mandatory in toV8()
451         https://bugs.webkit.org/show_bug.cgi?id=107520
452
453         Reviewed by Adam Barth.
454
455         Now it's safe to remove an optional Isolate parameter.
456
457         No tests. No change in behavior.
458
459         * bindings/scripts/CodeGeneratorV8.pm:
460         (GenerateHeader):
461         * bindings/scripts/test/V8/V8Float64Array.h:
462         (WebCore::toV8):
463         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
464         (WebCore::toV8):
465         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
466         (WebCore::toV8):
467         * bindings/scripts/test/V8/V8TestEventConstructor.h:
468         (WebCore::toV8):
469         * bindings/scripts/test/V8/V8TestEventTarget.h:
470         (WebCore::toV8):
471         * bindings/scripts/test/V8/V8TestException.h:
472         (WebCore::toV8):
473         * bindings/scripts/test/V8/V8TestInterface.h:
474         (WebCore::toV8):
475         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
476         (WebCore::toV8):
477         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
478         (WebCore::toV8):
479         * bindings/scripts/test/V8/V8TestNode.h:
480         (WebCore::toV8):
481         * bindings/scripts/test/V8/V8TestObj.h:
482         (WebCore::toV8):
483         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
484         (WebCore::toV8):
485         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
486         (WebCore::toV8):
487         * css/MediaQueryListListener.cpp:
488         (WebCore::MediaQueryListListener::queryChanged):
489         * testing/v8/WebCoreTestSupport.cpp:
490         (WebCoreTestSupport::injectInternalsObject):
491
492 2013-01-22  Mihnea Ovidenie  <mihnea@adobe.com>
493
494         [CSS Regions] min-max height will not trigger a relayout when set on a region with auto-height
495         https://bugs.webkit.org/show_bug.cgi?id=103738
496
497         Reviewed by David Hyatt.
498
499         When the style of an auto-height region changes with different min/max-height, we have to make sure
500         that the 2-pass layout algorithm is run so that the region height is properly computed. When doing a 2-pass layout 
501         for auto-height regions, we have to make sure that in the first pass, all auto-height regions start without a previously
502         computed overrideLogicalContentHeight, otherwise we may end-up with incorrect results, illustrated by tests
503         autoheight-two-pass-layout-complex-001.html and autoheight-two-pass-layout-complex-002.html.
504
505         If we do not have auto height regions, a single pass layout in enough to correctly flow content inside regions.
506         When we have auto height regions, the algorithm to lay out content should be:
507         1. If the flow thread content does not need lay out, we do a single pass layout.
508         If during the layout, an auto-height region needs layout or a normal (not auto height) region changes its box dimensions,
509         we need to perform a new 2-pass layout after this layout completes. If not, we bail out and skip step 2.
510         2. Do a full two pass layout and make sure that all auto height regions start the 2-pass layout without a previously computed
511         override logical content height.
512
513         Tests: fast/regions/autoheight-region-decrease-maxheight.html
514                fast/regions/autoheight-region-decrease-minheight.html
515                fast/regions/autoheight-region-decrease-width.html
516                fast/regions/autoheight-region-increase-maxheight.html
517                fast/regions/autoheight-region-increase-minheight.html
518                fast/regions/autoheight-region-increase-width.html
519                fast/regions/autoheight-region-new-maxheight-vrl.html
520                fast/regions/autoheight-region-new-maxheight.html
521                fast/regions/autoheight-region-new-minheight-vlr.html
522                fast/regions/autoheight-region-new-minheight.html
523                fast/regions/autoheight-region-remove-maxheight.html
524                fast/regions/autoheight-region-remove-minheight.html
525                fast/regions/autoheight-two-pass-layout-complex-001.html
526                fast/regions/autoheight-two-pass-layout-complex-002.html
527                fast/regions/region-height-auto-to-defined.html
528                fast/regions/region-height-defined-to-auto.html
529
530         * rendering/FlowThreadController.cpp: Added a flag that is needed to mark whether we need a full 2-pass layout.
531         (WebCore::FlowThreadController::FlowThreadController):
532         * rendering/FlowThreadController.h:
533         (WebCore::FlowThreadController::needsTwoPassLayoutForAutoHeightRegions):
534         (WebCore::FlowThreadController::setNeedsTwoPassLayoutForAutoHeightRegions):
535         * rendering/RenderFlowThread.cpp:
536         (WebCore::RenderFlowThread::resetRegionsOverrideLogicalContentHeight): Use invalidateRegions because we need also to mark the flow thread as needing layout.
537         (WebCore::RenderFlowThread::markAutoLogicalHeightRegionsForLayout):
538         * rendering/RenderRegion.cpp:
539         (WebCore::RenderRegion::layout): Make sure we do a 2-pass layout if needed.
540         * rendering/RenderView.cpp:
541         (WebCore::RenderView::layoutContentInAutoLogicalHeightRegions): Added a new function that models the layout algorithm for the case when we have auto height regions
542         and flow threads.
543         (WebCore::RenderView::layout):
544         (WebCore::RenderView::checkTwoPassLayoutForAutoHeightRegions):
545         * rendering/RenderView.h:
546
547 2013-01-22  Adam Barth  <abarth@webkit.org>
548
549         ENABLE(NEW_XML) isn't used by anyone and no one is actively working on it
550         https://bugs.webkit.org/show_bug.cgi?id=100710
551
552         Reviewed by Eric Seidel.
553
554         As discussed on webkit-dev
555         <http://lists.webkit.org/pipermail/webkit-dev/2012-August/022103.html>,
556         ENABLE(NEW_XML) isn't used by anyone and no one is actively working on
557         it. We should remove it from the code base for the time being. If folks
558         want to work on it again, we can restore it from SVN history.
559
560         * GNUmakefile.list.am:
561         * Target.pri:
562         * WebCore.gypi:
563         * WebCore.vcproj/WebCore.vcproj:
564         * WebCore.xcodeproj/project.pbxproj:
565         * dom/Document.cpp:
566         (WebCore::Document::createParser):
567         * dom/DocumentFragment.cpp:
568         (WebCore::DocumentFragment::parseXML):
569         * xml/parser/NewXMLDocumentParser.cpp: Removed.
570         * xml/parser/NewXMLDocumentParser.h: Removed.
571         * xml/parser/XMLCharacterReferenceParser.cpp: Removed.
572         * xml/parser/XMLCharacterReferenceParser.h: Removed.
573         * xml/parser/XMLToken.h: Removed.
574         * xml/parser/XMLTokenizer.cpp: Removed.
575         * xml/parser/XMLTokenizer.h: Removed.
576         * xml/parser/XMLTreeBuilder.cpp: Removed.
577         * xml/parser/XMLTreeBuilder.h: Removed.
578
579 2013-01-22  Kentaro Hara  <haraken@chromium.org>
580
581         [V8] Pass an Isolate to toV8() of event listeners
582         https://bugs.webkit.org/show_bug.cgi?id=107517
583
584         Reviewed by Adam Barth.
585
586         By using Context::GetIsolate(), this patch passes an Isolate to toV8().
587         I think this would be the last patch to pass an Isolate to toV8().
588         In the next patch, I will make an Isolate parameter mandatory for toV8().
589
590         No tests. No change in behavior.
591
592         * bindings/v8/V8AbstractEventListener.cpp:
593         (WebCore::V8AbstractEventListener::getReceiverObject):
594         * bindings/v8/V8AbstractEventListener.h:
595         (V8AbstractEventListener):
596         * bindings/v8/V8EventListener.cpp:
597         (WebCore::V8EventListener::callListenerFunction):
598         * bindings/v8/V8LazyEventListener.cpp:
599         (WebCore::toObjectWrapper):
600         (WebCore::V8LazyEventListener::callListenerFunction):
601         (WebCore::V8LazyEventListener::prepareListenerObject):
602         * bindings/v8/V8WorkerContextEventListener.cpp:
603         (WebCore::V8WorkerContextEventListener::getReceiverObject):
604
605 2013-01-22  Tim Horton  <timothy_horton@apple.com>
606
607         PDFPlugin: Build PDFPlugin everywhere, enable at runtime
608         https://bugs.webkit.org/show_bug.cgi?id=107117
609
610         Reviewed by Alexey Proskuryakov.
611
612         Since PDFLayerController SPI is all forward-declared, the plugin should build
613         on all Mac platforms, and can be enabled at runtime.
614
615         * Configurations/FeatureDefines.xcconfig:
616
617 2013-01-22  Dominic Mazzoni  <dmazzoni@google.com>
618
619         AX: Should assert if we try to create two AXObjects that point to the same renderer or node
620         https://bugs.webkit.org/show_bug.cgi?id=107504
621
622         Reviewed by Chris Fleizach.
623
624         If two accessibility objects get created that point to the
625         same widget, renderer, or node, that can lead to crashes or
626         memory corruption later; make it assert instead of crashing.
627
628         * accessibility/AXObjectCache.cpp:
629         (WebCore::AXObjectCache::getOrCreate):
630
631 2013-01-22  Kentaro Hara  <haraken@chromium.org>
632
633         [V8] Pass an Isolate to toV8()
634         https://bugs.webkit.org/show_bug.cgi?id=107512
635
636         Reviewed by Adam Barth.
637
638         By using Context::GetIsolate(), this patch passes an Isolate to toV8().
639
640         No tests. No change in behavior.
641
642         * bindings/v8/IDBBindingUtilities.cpp:
643         (WebCore::injectIDBKeyIntoScriptValue):
644         (WebCore::idbKeyToScriptValue):
645         * bindings/v8/ScriptController.cpp:
646         (WebCore::createScriptObject):
647         (WebCore::ScriptController::createScriptObjectForPluginElement):
648         * bindings/v8/ScriptDebugServer.cpp:
649         (WebCore::ScriptDebugServer::currentCallFrame):
650         * bindings/v8/ScriptObject.cpp:
651         (WebCore::ScriptGlobalObject::set):
652         * bindings/v8/V8AbstractEventListener.cpp:
653         (WebCore::V8AbstractEventListener::handleEvent):
654         * bindings/v8/V8DOMWindowShell.cpp:
655         (WebCore::V8DOMWindowShell::updateDocumentProperty):
656         * bindings/v8/V8MutationCallback.cpp:
657         (WebCore::V8MutationCallback::handleEvent):
658         * bindings/v8/V8NodeFilterCondition.cpp:
659         (WebCore::V8NodeFilterCondition::acceptNode):
660         * bindings/v8/V8WorkerContextEventListener.cpp:
661         (WebCore::V8WorkerContextEventListener::handleEvent):
662         * bindings/v8/custom/V8CustomSQLStatementErrorCallback.cpp:
663         (WebCore::V8SQLStatementErrorCallback::handleEvent):
664         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
665         (WebCore::InjectedScriptHost::nodeAsScriptValue):
666
667 2013-01-22  Sergey Ryazanov  <serya@chromium.org>
668
669         Web Inspector: Show requests in `curl` syntax in DevTools → Network → Headers
670         https://bugs.webkit.org/show_bug.cgi?id=107276
671
672         Reviewed by Pavel Feldman.
673
674         Test: inspector/curl-command.html
675
676         * inspector/front-end/NetworkPanel.js:
677         (WebInspector.NetworkLogView.prototype._generateCurlCommand):
678
679 2013-01-22  Yury Semikhatsky  <yurys@chromium.org>
680
681         Web Inspector: reuse JS heap profiler UI for native heap graph representaion
682         https://bugs.webkit.org/show_bug.cgi?id=107452
683
684         Reviewed by Pavel Feldman.
685
686         NativeHeapSnapshot is introduced to leverage JS heap snapshot processing algorithms
687         for native heap graph. New snapshot type ("Native Heap Snapshot") is added to the
688         profiles panel. It will represent native heap snapshots using the same UI as we use
689         for JS heap snapshots.
690
691         * WebCore.gypi:
692         * WebCore.vcproj/WebCore.vcproj:
693         * inspector/compile-front-end.py:
694         * inspector/front-end/HeapSnapshot.js:
695         (WebInspector.HeapSnapshot):
696         (WebInspector.HeapSnapshot.prototype._init):
697         * inspector/front-end/HeapSnapshotProxy.js:
698         (WebInspector.HeapSnapshotWorker):
699         * inspector/front-end/HeapSnapshotView.js:
700         (WebInspector.HeapProfileHeader.prototype.load):
701         (WebInspector.HeapProfileHeader.prototype.startSnapshotTransfer): extracted a few methods
702         to support overrides for native heap snapshots.
703         (WebInspector.HeapProfileHeader.prototype.snapshotConstructorName):
704         (WebInspector.HeapProfileHeader.prototype._setupWorker):
705         * inspector/front-end/NativeHeapSnapshot.js: Added.
706         (WebInspector.NativeHeapSnapshot):
707         (WebInspector.NativeHeapSnapshot.prototype.createNode):
708         (WebInspector.NativeHeapSnapshot.prototype.createEdge):
709         (WebInspector.NativeHeapSnapshot.prototype.createRetainingEdge):
710         (WebInspector.NativeHeapSnapshot.prototype._markInvisibleEdges):
711         (WebInspector.NativeHeapSnapshot.prototype._calculateFlags):
712         (WebInspector.NativeHeapSnapshot.prototype.canHaveDistanceOne):
713         (WebInspector.NativeHeapSnapshot.prototype.userObjectsMapAndFlag):
714         (WebInspector.NativeHeapSnapshotNode):
715         (WebInspector.NativeHeapSnapshotNode.prototype.canBeQueried):
716         (WebInspector.NativeHeapSnapshotNode.prototype.isUserObject):
717         (WebInspector.NativeHeapSnapshotNode.prototype.className):
718         (WebInspector.NativeHeapSnapshotNode.prototype.classIndex):
719         (WebInspector.NativeHeapSnapshotNode.prototype.id):
720         (WebInspector.NativeHeapSnapshotNode.prototype.name):
721         (WebInspector.NativeHeapSnapshotNode.prototype.isHidden):
722         (WebInspector.NativeHeapSnapshotNode.prototype.isSynthetic):
723         (WebInspector.NativeHeapSnapshotNode.prototype.isWindow):
724         (WebInspector.NativeHeapSnapshotNode.prototype.isDetachedDOMTreesRoot):
725         (WebInspector.NativeHeapSnapshotNode.prototype.isDetachedDOMTree):
726         (WebInspector.NativeHeapSnapshotEdge):
727         (WebInspector.NativeHeapSnapshotEdge.prototype.clone):
728         (WebInspector.NativeHeapSnapshotEdge.prototype.hasStringName):
729         (WebInspector.NativeHeapSnapshotEdge.prototype.isElement):
730         (WebInspector.NativeHeapSnapshotEdge.prototype.isHidden):
731         (WebInspector.NativeHeapSnapshotEdge.prototype.isWeak):
732         (WebInspector.NativeHeapSnapshotEdge.prototype.isInternal):
733         (WebInspector.NativeHeapSnapshotEdge.prototype.isInvisible):
734         (WebInspector.NativeHeapSnapshotEdge.prototype.isShortcut):
735         (WebInspector.NativeHeapSnapshotEdge.prototype.name):
736         (WebInspector.NativeHeapSnapshotEdge.prototype.toString):
737         (WebInspector.NativeHeapSnapshotEdge.prototype._nameOrIndex):
738         (WebInspector.NativeHeapSnapshotRetainerEdge):
739         (WebInspector.NativeHeapSnapshotRetainerEdge.prototype.clone):
740         (WebInspector.NativeHeapSnapshotRetainerEdge.prototype.isElement):
741         (WebInspector.NativeHeapSnapshotRetainerEdge.prototype.isHidden):
742         (WebInspector.NativeHeapSnapshotRetainerEdge.prototype.isInternal):
743         (WebInspector.NativeHeapSnapshotRetainerEdge.prototype.isInvisible):
744         (WebInspector.NativeHeapSnapshotRetainerEdge.prototype.isShortcut):
745         (WebInspector.NativeHeapSnapshotRetainerEdge.prototype.isWeak):
746         * inspector/front-end/NativeMemorySnapshotView.js:
747         (WebInspector.NativeSnapshotProfileType):
748         (WebInspector.NativeSnapshotProfileType.prototype.get buttonTooltip):
749         (WebInspector.NativeSnapshotProfileType.prototype.buttonClicked.didReceiveMemorySnapshot):
750         (WebInspector.NativeSnapshotProfileType.prototype.buttonClicked):
751         (WebInspector.NativeSnapshotProfileType.prototype.get treeItemTitle):
752         (WebInspector.NativeSnapshotProfileType.prototype.get description):
753         (WebInspector.NativeSnapshotProfileType.prototype.createTemporaryProfile):
754         (WebInspector.NativeSnapshotProfileType.prototype.createProfile):
755         (WebInspector.NativeSnapshotProfileHeader):
756         (WebInspector.NativeSnapshotProfileHeader.prototype.createView):
757         (WebInspector.NativeSnapshotProfileHeader.prototype.startSnapshotTransfer):
758         (WebInspector.NativeSnapshotProfileHeader.prototype.snapshotConstructorName):
759         (WebInspector.NativeSnapshotProfileHeader.prototype._takeNativeSnapshot): build a datastructure
760         resembling one used for JS heap snapshots but populated with the data from the native snaphot.
761         (WebInspector.NativeHeapSnapshotView):
762         (WebInspector.NativeHeapSnapshotView.prototype.get profile):
763         (WebInspector.NativeMemoryProfileType):
764         (WebInspector.NativeMemoryProfileType.prototype.get buttonTooltip):
765         * inspector/front-end/ProfilesPanel.js:
766         (WebInspector.ProfilesPanel):
767         * inspector/front-end/WebKit.qrc:
768
769 2013-01-21  Kentaro Hara  <haraken@chromium.org>
770
771         [V8] ScriptState::isolate() should use Context::GetIsolate()
772         https://bugs.webkit.org/show_bug.cgi?id=107490
773
774         Reviewed by Adam Barth.
775
776         Now V8 provides Context::GetIsolate(). We should use it
777         in ScriptState::isolate().
778
779         * bindings/v8/ScriptState.h:
780         (WebCore::ScriptState::isolate):
781         (ScriptState):
782
783 2013-01-21  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
784
785         [EFL] Missing context menus strings
786         https://bugs.webkit.org/show_bug.cgi?id=107104
787
788         Reviewed by Kenneth Rohde Christiansen.
789
790         Add 5 missing localization strings for text direction context menus.
791
792         * platform/efl/LocalizedStringsEfl.cpp:
793         (WebCore::contextMenuItemTagRightToLeft):
794         (WebCore::contextMenuItemTagLeftToRight):
795         (WebCore::contextMenuItemTagWritingDirectionMenu):
796         (WebCore::contextMenuItemTagTextDirectionMenu):
797         (WebCore::contextMenuItemTagDefaultDirection):
798
799 2013-01-21  Kent Tamura  <tkent@chromium.org>
800
801         Date selection from calendar picker should dispatch 'input' event in addition to 'change' event
802         https://bugs.webkit.org/show_bug.cgi?id=107427
803
804         Reviewed by Kentaro Hara.
805
806         According to the specification and Opera's behavior, we should dispatch
807         not only 'change' event but also 'input' event when a user chooses a
808         date from the calender picker.
809
810         http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#common-event-behaviors
811         > When the user agent changes the element's value on behalf of the user
812         > (e.g. as part of a form prefilling feature), the user agent must follow
813         > these steps:
814         > 1. If the input event applies, queue a task to fire a simple event
815         > that bubbles named input at the input element.
816         > 2. If the change event applies, queue a task to fire a simple event
817         > that bubbles named change at the input element.
818
819         Tests: platform/chromium/fast/forms/calendar-picker/date-picker-events.html
820                platform/chromium/fast/forms/calendar-picker/datetimelocal-picker-events.html
821
822         * html/InputType.cpp:
823         (WebCore::InputType::setValue): Add DispatchInputAndChangeEvent support.
824         * html/BaseChooserOnlyDateAndTimeInputType.cpp:
825         (WebCore::BaseChooserOnlyDateAndTimeInputType::didChooseValue):
826         Use DispatchInputAndChangeEvent, not DispatchChangeEvent.
827         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
828         (WebCore::BaseMultipleFieldsDateAndTimeInputType::pickerIndicatorChooseValue):
829         Ditto.
830
831 2013-01-21  Justin Schuh  <jschuh@chromium.org>
832
833         [CHROMIUM] Suppress c4267 build warnings for Win64 targets
834         https://bugs.webkit.org/show_bug.cgi?id=107499
835
836         Reviewed by Abhishek Arya.
837
838         No new tests. No code changes.
839
840         * WebCore.gyp/WebCore.gyp:
841
842 2013-01-21  Andreas Kling  <akling@apple.com>
843
844         CSSSelector::value() should assert that m_match != Tag.
845         <http://webkit.org/b/107500>
846
847         Reviewed by Anders Carlsson.
848
849         Add an assertion to catch anyone trying to extract a value() from a Tag selector.
850
851         * css/CSSSelector.h:
852         (CSSSelector):
853         (WebCore::CSSSelector::value):
854
855 2013-01-21  Dimitri Glazkov  <dglazkov@chromium.org>
856
857         Move HTML Attribute case-sensitivity logic out of SelectorChecker to HTMLDocument.
858         https://bugs.webkit.org/show_bug.cgi?id=107460
859
860         The case-sensitivity of HTML attributes is defined in HTML spec and is only applicable in HTML documents,
861         so having this logic in HTMLDocument seems like a good thing.
862
863         Reviewed by Eric Seidel.
864
865         Refactoring, covered by existing tests.
866
867         * css/SelectorChecker.cpp:
868         (WebCore): Moved code out of here.
869         (WebCore::isFastCheckableMatch): Changed the callsite to use new location.
870         (WebCore::SelectorChecker::checkOne): Ditto.
871         * html/HTMLDocument.cpp:
872         (WebCore::addLocalNameToSet): Moved the code into here.
873         (WebCore): Ditto.
874         (WebCore::createHtmlCaseInsensitiveAttributesSet): Ditto.
875         (WebCore::HTMLDocument::isCaseSensitiveAttribute): Ditto.
876         * html/HTMLDocument.h:
877         (HTMLDocument): Added decl for the newly moved function.
878
879 2013-01-21  Shinya Kawanaka  <shinyak@chromium.org>
880
881         FrameSelection should use shadowHost instead of shadowAncestorNode
882         https://bugs.webkit.org/show_bug.cgi?id=107220
883
884         Reviewed by Kent Tamura.
885
886         shadowAncestorNode() is deprecated and we want to use shadowHost.
887         Here, all objects calling shadowAncestorNode() is in ShadowDOM, we can safely convert
888         the call to shadowHost().
889
890         No new tests, simple refactoring.
891
892         * editing/FrameSelection.cpp:
893         (WebCore::FrameSelection::selectAll):
894
895 2013-01-21  Dirk Schulze  <dschulze@adobe.com>
896
897         Add build flag for Canvas's Path object (disabled by default)
898         https://bugs.webkit.org/show_bug.cgi?id=107473
899
900         Reviewed by Dean Jackson.
901
902         Add CANVAS_PATH build flag to build systems.
903
904         * Configurations/FeatureDefines.xcconfig:
905         * GNUmakefile.am:
906
907 2013-01-21  Andreas Kling  <akling@apple.com>
908
909         CSS: Make tag sub-selectors standalone CSSSelectors.
910         <http://webkit.org/b/107111>
911
912         Reviewed by Antti Koivisto.
913
914         TL;DR: Instead of storing a QualifiedName with every CSSSelector, special-case tag selectors
915                by promoting them to stand-alone CSSSelectors.
916                33% reduction in CSS selector memory usage, 4.77 MB progression on Membuster3.
917                Fixed some bugs in Shadow DOM that were exposed by these changes.
918
919         A selector like this:
920
921             div.tripp.trapp#trull { }
922
923         Would previously be represented by a chain of 3 CSSSelector objects like so:
924
925             [ Tag: "div",  Type: Class,  Value: "tripp" ]
926             [ Tag:     *,  Type: Class,  Value: "trapp" ]
927             [ Tag:     *,  Type: ID,     Value: "trull" ]
928
929         After this change, the memory layout becomes:
930
931             [ Type: Tag,    Value: "div"   ]
932             [ Type: Class,  Value: "tripp" ]
933             [ Type: Class,  Value: "trapp" ]
934             [ Type: ID,     Value: "trull" ]
935
936         This is a huge net memory win since the majority of selectors don't even have a tag name
937         and those that do now have a flat cost of one more CSSSelector.
938         Traversal is also slightly cleaner since any tag name will now be in a predictable place.
939
940         * css/SelectorChecker.cpp:
941         (WebCore::isFastCheckableMatch):
942         * html/shadow/HTMLContentElement.cpp:
943         (WebCore::validateSubSelector):
944
945             Renamed CSSSelector::None to CSSSelector::Tag.
946
947         * css/SelectorChecker.h:
948         (WebCore::SelectorChecker::tagMatches):
949         * css/StyleResolver.cpp:
950         (WebCore::StyleResolver::ruleMatches):
951
952             Changed SelectorChecker::tagMatches() to take a QualifiedName instead of a CSSSelector.
953
954         * dom/QualifiedName.cpp:
955         (WebCore::QualifiedName::deref):
956         (WebCore::QualifiedName::QualifiedNameImpl::~QualifiedNameImpl):
957         * dom/QualifiedName.h:
958         (QualifiedNameImpl):
959
960             Give QualifiedNameImpl a destructor so it can remove itself from the global cache instead of
961             having QualifiedName do it. This makes it possible to participate in ownership of QualifiedNames
962             via a QualifiedNameImpl pointer, as used by the union member in CSSSelector.
963
964         * css/CSSGrammar.y.in:
965         * css/CSSParser.cpp:
966         (WebCore::CSSParser::createFloatingSelectorWithTagName):
967         (WebCore::CSSParser::updateSpecifiersWithNamespaceIfNeeded):
968         (WebCore::CSSParser::updateSpecifiersWithElementName):
969         * css/CSSParser.h:
970         * css/CSSParserValues.h:
971         (CSSParserSelector):
972         * css/CSSParserValues.cpp:
973         (WebCore::CSSParserSelector::CSSParserSelector):
974         (WebCore::CSSParserSelector::prependTagSelector):
975
976             Make the CSS parser slap a CSSSelector with m_match=Tag at the head of all selectors that match
977             one or more of these criteria:
978
979             - The selector starts with a tag, e.g "div.foo" or just plain "span"
980             - There is a @namespace rule in effect, and the override namespace needs to be stored with the selector.
981               These will have CSSSelectors::m_isTagForNamespaceRule set, this is only so that selector serialization
982               can avoid outputting a '*' tag where we previously didn't.
983
984         (WebCore::CSSParserSelector::isSimple):
985
986             Merged the CSSSelector::isSimple() logic into CSSParserSelector, since it's only needed during parsing
987             to figure out if a selector is allowed within :not().
988
989         * css/CSSSelector.h:
990         (CSSSelector):
991         (WebCore::CSSSelector::setValue):
992         (WebCore::CSSSelector::CSSSelector):
993         (WebCore::CSSSelector::~CSSSelector):
994         (WebCore::CSSSelector::tagQName):
995         * css/CSSSelector.cpp:
996         (WebCore::CSSSelector::createRareData):
997         (WebCore::CSSSelector::operator==):
998
999             Add a QualifiedNameImpl* m_tagQName member to the CSSSelector data union. This union pointer is used
1000             if m_match == Tag. tagQName() is used to retrieve the tag (renamed from tag().) 
1001
1002         (WebCore::CSSSelector::selectorText):
1003
1004             Only serialize Tag selector components that aren't namespace placeholders. This behavior is web-facing
1005             so we make an effort to stay consistent.
1006
1007         (WebCore::CSSSelector::specificityForOneSelector):
1008         (WebCore::CSSSelector::specificityForPage):
1009         * css/CSSSelectorList.cpp:
1010         (WebCore::SelectorNeedsNamespaceResolutionFunctor::operator()):
1011         * css/RuleSet.cpp:
1012         (WebCore::isSelectorMatchingHTMLBasedOnRuleHash):
1013         * css/SelectorFilter.cpp:
1014         (WebCore::collectDescendantSelectorIdentifierHashes):
1015         (WebCore::SelectorFilter::collectIdentifierHashes):
1016
1017             Adapt algorithms to having Tag selectors.
1018
1019         (WebCore::selectorListContainsUncommonAttributeSelector):
1020
1021             Loop through all selector components when looking for uncommon attributes.
1022
1023         (WebCore::determinePropertyWhitelistType):
1024
1025             Loop through all selector components when looking for ::cue().
1026
1027         (WebCore::RuleSet::addRule):
1028         (WebCore::RuleSet::findBestRuleSetAndAdd):
1029
1030             Break addRule into two methods to be able to peek ahead if the first selector is a Tag.
1031             Otherwise we'd end up sticking most selectors in m_tagRules, breaking the class/ID/etc optimizations.
1032
1033         * css/SelectorChecker.cpp:
1034         (WebCore::SelectorChecker::fastCheck):
1035         (WebCore::SelectorChecker::fastCheckSingleSelector):
1036
1037             It's no longer necessary to check the tagQName for every selector component, so don't.
1038             Also simplified the signature of the template argument function.
1039
1040         (WebCore::SelectorChecker::fastCheckRightmostSelector):
1041
1042             Updated for Tag selectors.
1043
1044         (WebCore::SelectorChecker::checkOne):
1045         (WebCore::SelectorChecker::matches):
1046         (WebCore::SelectorChecker::match):
1047
1048             Have match() take a SiblingTraversalStrategy so it can forward that to checkOne().
1049             This is necessary for shadow DOM code that was incorrectly calling checkOne() instead of match().
1050
1051         * css/StyleResolver.cpp:
1052         (WebCore::StyleResolver::ruleMatches):
1053
1054             The meaning of "single-part selector" changes a bit with this patch, and no longer includes "div.foo"
1055             as that is now a Tag, followed by a Class. Given that, we can't assume the tag check is unnecessary
1056             just because the rightmost descendant was found in one of the hashes.
1057
1058         (WebCore::StyleResolver::matchPageRulesForList):
1059
1060             Loop through all selector components when matching @page since pseudo types may not always be in
1061             the first subselector now.
1062
1063         * html/shadow/ContentDistributor.cpp:
1064         (WebCore::ContentDistributor::collectSelectFeatureSetFrom):
1065
1066             Collect feature information from subselectors to make sure nothing is missed. (This bug was exposed
1067             by offsetting the subselectors.)
1068
1069         * html/shadow/ContentSelectorQuery.cpp:
1070         (WebCore::ContentSelectorChecker::checkContentSelector):
1071
1072             Call SelectorChecker::match() instead of checkOne() to make subselector traversal work properly.
1073
1074 2013-01-21  Levi Weintraub  <leviw@chromium.org>
1075
1076         Event target rects on the top level document shouldn't be clipped.
1077         https://bugs.webkit.org/show_bug.cgi?id=107339
1078
1079         Reviewed by James Robinson.
1080
1081         clippedOverflowRectForRepaint clips the top-level RenderView to the viewport, which
1082         is wrong for generating event target rects, as the result will not extend to the bounds
1083         of the document on pages that scroll. Changing the top-level view to use documentRect
1084         instead.
1085
1086         Tests updated to cover bug: platform/chromium/fast/events/touch/touch-hit-rects-in-iframe.html
1087                                     platform/chromium/fast/events/touch/compositor-touch-hit-rects.html
1088
1089         * page/scrolling/ScrollingCoordinator.cpp:
1090         (WebCore::accumulateRendererTouchEventTargetRects): Use converToRootView instead of
1091         a loop around convertToContaining view. This is not a change in behavior.
1092         (WebCore::accumulateDocumentEventTargetRects): Switch to use documentRect instead of
1093         clippedOverflowRectForRepaint for the top-level Document, and use converToRootView
1094         to put rects in the coordinates of the top-level document.
1095
1096 2013-01-17  Andy Estes  <aestes@apple.com>
1097
1098         Add a USE() macro for content filtering code
1099         https://bugs.webkit.org/show_bug.cgi?id=107098
1100
1101         Reviewed by Mark Rowe.
1102
1103         * WebCore.exp.in: Use USE(CONTENT_FILTERING).
1104         * loader/MainResourceLoader.cpp:
1105         (WebCore::MainResourceLoader::MainResourceLoader): Ditto.
1106         (WebCore::MainResourceLoader::~MainResourceLoader): Ditto.
1107         (WebCore::MainResourceLoader::cancel): Ditto.
1108         (WebCore::MainResourceLoader::responseReceived): Ditto.
1109         (WebCore::MainResourceLoader::dataReceived): Ditto.
1110         (WebCore::MainResourceLoader::didFinishLoading): Ditto.
1111         (WebCore::MainResourceLoader::notifyFinished): Ditto.
1112         * loader/MainResourceLoader.h:
1113         (MainResourceLoader): Ditto.
1114         * platform/mac/WebCoreSystemInterface.h: Ditto.
1115         * platform/mac/WebCoreSystemInterface.mm: Ditto.
1116
1117 2013-01-21  Bem Jones-Bey  <bjonesbe@adobe.com>
1118
1119         [CSS Exclusions] shape-outside on floats for rectangle shapes positioning
1120         https://bugs.webkit.org/show_bug.cgi?id=100399
1121
1122         Reviewed by David Hyatt.
1123
1124         When a float has a shape-outside with non-zero x or y, the float's
1125         exclusion behavior can happen at a completely different location than
1126         where the float's content is painted. This patch brings initial
1127         support for this behavior.
1128
1129         Test: fast/exclusions/shape-outside-floats/shape-outside-floats-positioning.html
1130
1131         * rendering/RenderBlock.cpp:
1132         (WebCore::RenderBlock::flipFloatForWritingModeForChild): If called
1133             during painting, make sure to pass that state down to the float
1134             positioning so that it can use the proper position.
1135         (WebCore::RenderBlock::paintFloats): Since this is concerned with
1136             painting, use the position of the float, not the shape.
1137         (WebCore::RenderBlock::positionNewFloats): Set the correct location
1138             for the float, relative to the location of the shape.
1139         (WebCore::RenderBlock::addOverhangingFloats): Add FIXME.
1140         * rendering/RenderBlock.h:
1141         (WebCore::RenderBlock::xPositionForFloatIncludingMargin): 
1142         (WebCore::RenderBlock::yPositionForFloatIncludingMargin): Since the 
1143             position of the shape (FloatingObject) can be different from the
1144             position of the float's box (RenderBox), the position needs to be
1145             computed differently for painting than for determining layout.
1146         (WebCore::RenderBlock::flipFloatForWritingModeForChild): Change
1147             signature to take painting flag.
1148
1149 2013-01-21  Eric Carlson  <eric.carlson@apple.com>
1150
1151         Support non-WebVTT cues from in-band text tracks
1152         https://bugs.webkit.org/show_bug.cgi?id=107046
1153
1154         Reviewed by Sam Weinig.
1155
1156         * CMakeLists.txt: Add new files.
1157         * GNUmakefile.list.am: Ditto.
1158         * Target.pri: Ditto.
1159         * WebCore.gypi: Ditto.
1160         * WebCore.vcproj/WebCore.vcproj: Ditto.
1161         * WebCore.xcodeproj/project.pbxproj: Ditto.
1162
1163         * html/shadow/MediaControlElements.cpp:
1164         (WebCore::MediaControlTextTrackContainerElement::updateDisplay): Pass video size to getDisplayTree.
1165
1166         * html/track/InbandTextTrack.cpp:
1167         (WebCore::InbandTextTrack::addGenericCue): New, create a generic cue if it doesn't already exist.
1168         (WebCore::InbandTextTrack::addWebVTTCue): Renamed from addCue.
1169         * html/track/InbandTextTrack.h:
1170
1171         * html/track/TextTrack.cpp:
1172         (WebCore::TextTrack::hasCue): Moved from InbandTextTrack.cpp, use operator == instead of inline
1173             comparison so derived TextTrackCues can be compared.
1174         * html/track/TextTrack.h:
1175
1176         * html/track/TextTrackCue.cpp:
1177         (WebCore::TextTrackCueBox::applyCSSProperties): Interface change.
1178         (WebCore::TextTrackCue::TextTrackCue): Don't create the display tree in the constructor, it may
1179             never be needed.
1180         (WebCore::TextTrackCue::createDisplayTree): New, create the display tree.
1181         (WebCore::TextTrackCue::displayTreeInternal): Display tree accessor, allows it to be created lazily.
1182         (WebCore::TextTrackCue::setAlign): Alignment -> CueAlignment.
1183         (WebCore::TextTrackCue::setIsActive): Use displayTreeInternal().
1184         (WebCore::TextTrackCue::getDisplayTree): Use displayTreeInternal(), pass video size to applyCSSProperties.
1185         (WebCore::TextTrackCue::removeDisplayTree): Use displayTreeInternal().
1186         (WebCore::TextTrackCue::operator==): New.
1187         * html/track/TextTrackCue.h:
1188         (WebCore::TextTrackCue::getAlignment): Alignment -> CueAlignment.
1189         (WebCore::TextTrackCue::operator!=): New.
1190         (WebCore::TextTrackCue::cueType): New, cue type identified needed by operator==.
1191         (WebCore::TextTrackCue::ownerDocument): New.
1192
1193         * html/track/TextTrackCueGeneric.cpp: Added.
1194         (WebCore::TextTrackCueGenericBox::create):
1195         (WebCore::TextTrackCueGenericBox::TextTrackCueGenericBox):
1196         (WebCore::TextTrackCueGenericBox::applyCSSProperties):
1197         (WebCore:::TextTrackCue):
1198         (WebCore::TextTrackCueGeneric::createDisplayTree):
1199         (WebCore::TextTrackCueGeneric::operator==):
1200         * html/track/TextTrackCueGeneric.h: Added.
1201         (WebCore::TextTrackCueGeneric::create):
1202         (WebCore::TextTrackCueGeneric::~TextTrackCueGeneric):
1203         (WebCore::TextTrackCueGeneric::baseFontSizeRelativeToVideoHeight):
1204         (WebCore::TextTrackCueGeneric::setBaseFontSizeRelativeToVideoHeight):
1205         (WebCore::TextTrackCueGeneric::fontSizeMultiplier):
1206         (WebCore::TextTrackCueGeneric::setFontSizeMultiplier):
1207         (WebCore::TextTrackCueGeneric::fontName):
1208         (WebCore::TextTrackCueGeneric::setFontName):
1209         (WebCore::TextTrackCueGeneric::operator!=):
1210         (WebCore::TextTrackCueGeneric::cueType):
1211
1212         * platform/graphics/InbandTextTrackPrivateClient.h:
1213         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
1214         (WebCore::InbandTextTrackPrivateAVF::processCueAttributes): Copy cue attributes into GenericCueData
1215             struct instead of trying to convert to WebVTT settings string. Process font size,font base
1216             size, font name, and vertical layout attributes,
1217         (WebCore::InbandTextTrackPrivateAVF::processCue): Create separate cues for each attributed
1218             string in the array because each one can be at a different screen location.
1219         (WebCore::InbandTextTrackPrivateAVF::resetCueValues):
1220         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
1221         (InbandTextTrackPrivateAVF):
1222
1223         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
1224         (WebCore::MediaPlayerPrivateAVFoundation::seekCompleted): Reset any partially accumulated cues
1225             delivered since the seek was started.
1226         (WebCore::MediaPlayerPrivateAVFoundation::addGenericCue): Renamed from flushCurrentCue.
1227         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
1228
1229         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
1230         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Whitespace cleanup.
1231         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Ditto.
1232         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Tell legible output to deliver cues
1233             without any additional styling needed by the internal renderer.
1234         (WebCore::MediaPlayerPrivateAVFoundationObjC::processTextTracks):
1235         (WebCore::MediaPlayerPrivateAVFoundationObjC::setCurrentTrack): Do nothing if asked to change
1236             to the track that is already current.
1237         (-[WebCoreAVFMovieObserver legibleOutput:didOutputAttributedStrings:nativeSampleBuffers:forItemTime:]):
1238             Check to make sure that the client callback isn't NULL.
1239
1240 2013-01-21  Robert Hogan  <robert@webkit.org>
1241
1242         Misaligned logo on www.nzherald.co.nz possibly due to negative margin-top
1243         https://bugs.webkit.org/show_bug.cgi?id=14664
1244
1245         Reviewed by David Hyatt.
1246
1247         Test: fast/block/float/clear-negative-margin-top.html
1248
1249         * rendering/RenderBlock.cpp:
1250         (WebCore::RenderBlock::collapseMargins): If a negative margin pulls a block up so that floats from
1251         siblings overhang, then ensure addOverHangingFloats() uses the revised logical top position when
1252         deciding whether a float does indeed overhang into the block after margin-collapsing.
1253         (WebCore::RenderBlock::clearFloatsIfNeeded):
1254
1255 2013-01-21  Rik Cabanier  <cabanier@adobe.com>
1256
1257         Proposal: Add support for even-odd fill and clip to Canvas
1258         https://bugs.webkit.org/show_bug.cgi?id=106188
1259
1260         Reviewed by Dirk Schulze.
1261
1262         This patch adds support for an optional winding rule to fill, clip
1263         and isPointInPath in canvas 2d. By default, the fill is non-zero but
1264         you can now pass in an optional winding rule string ("nonzero" or "evenodd")
1265         to make an explicit choice.
1266
1267         Tests: fast/canvas/canvas-clip-rule.html
1268                fast/canvas/canvas-fill-rule.html
1269                fast/canvas/canvas-isPointInPath-winding.html
1270
1271         * html/canvas/CanvasRenderingContext2D.cpp: Change implementation so it sets the windig rule in the context.
1272         (WebCore::parseWinding):
1273         (WebCore):
1274         (WebCore::CanvasRenderingContext2D::fill):
1275         (WebCore::CanvasRenderingContext2D::clip):
1276         (WebCore::CanvasRenderingContext2D::isPointInPath):
1277         * html/canvas/CanvasRenderingContext2D.h: 
1278         (CanvasRenderingContext2D):
1279         * html/canvas/CanvasRenderingContext2D.idl: Change the idl so the new API is exposed to JavaScript.
1280         * platform/graphics/cg/GraphicsContextCG.cpp: Fixes a bug where the wrong winding rule was set for clipping in Core Graphics.
1281         (WebCore::GraphicsContext::clip):
1282
1283 2013-01-21  ChangSeok Oh  <shivamidow@gmail.com>
1284
1285         [GTK][AC] setOpacity doesn't work for GraphicsLayerClutter
1286         https://bugs.webkit.org/show_bug.cgi?id=105436
1287
1288         Reviewed by Gustavo Noronha Silva.
1289
1290         Implement GraphicsLayerClutter::setOpacity based on Mac's GraphicsLayer implementation.
1291
1292         No new tests since this patch can be covered by already existing gtk ac tests.
1293
1294         * platform/graphics/clutter/GraphicsLayerClutter.cpp:
1295         (WebCore::GraphicsLayerClutter::setOpacity):
1296         (WebCore):
1297         (WebCore::GraphicsLayerClutter::updateOpacityOnLayer):
1298         (WebCore::GraphicsLayerClutter::commitLayerChangesBeforeSublayers):
1299         * platform/graphics/clutter/GraphicsLayerClutter.h:
1300
1301 2013-01-21  ChangSeok Oh  <shivamidow@gmail.com>
1302
1303         [Texmap][GTK] The poster-circle doesn't appear.
1304         https://bugs.webkit.org/show_bug.cgi?id=106672
1305
1306         Reviewed by Noam Rosenthal.
1307
1308         We need to call setNeedsDisplay to redraw GraphicsLayer after we set drawsContent
1309         a new value for the layer. Otherwise we can't get a chance for first drawing the layer.
1310
1311         Test: compositing/visibility/visibility-composited-animation.html
1312
1313         * platform/graphics/texmap/TextureMapperLayer.cpp:
1314         (WebCore::TextureMapperLayer::flushCompositingStateForThisLayerOnly):
1315
1316 2013-01-21  Viatcheslav Ostapenko  <sl.ostapenko@samsung.com>
1317
1318         [EFL][Qt][WebGl] Random crash in GraphicsContext3D::drawArrays
1319         https://bugs.webkit.org/show_bug.cgi?id=107178
1320
1321         Reviewed by Noam Rosenthal.
1322
1323         Workaround for the problem in mesa when internal llvm pipe object is deleted
1324         later than the screen object. Screen object is deleted because the corresponding 
1325         X server display connection closed.
1326         Keep X server display connection open until program shutdown. 
1327         OffScreenRootWindow::display is now static, so there is no need to create
1328         OffScreenRootWindow object on client side.
1329
1330         Fixes crash that appears during run of fast/canavs/webgl tests.
1331
1332         * platform/graphics/surfaces/glx/GraphicsSurfaceGLX.cpp:
1333         (OffScreenRootWindow):
1334         (WebCore::OffScreenRootWindow::DisplayConnection::DisplayConnection):
1335         (DisplayConnection):
1336         (WebCore::OffScreenRootWindow::DisplayConnection::~DisplayConnection):
1337         (WebCore::OffScreenRootWindow::DisplayConnection::display):
1338         (WebCore::OffScreenRootWindow::display):
1339         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
1340         (WebCore):
1341         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
1342         (WebCore::GraphicsSurfacePrivate::createSurface):
1343         (WebCore::GraphicsSurfacePrivate::createPixmap):
1344         (WebCore::GraphicsSurfacePrivate::makeCurrent):
1345         (WebCore::GraphicsSurfacePrivate::doneCurrent):
1346         (WebCore::GraphicsSurfacePrivate::swapBuffers):
1347         (WebCore::GraphicsSurfacePrivate::display):
1348         (WebCore::GraphicsSurfacePrivate::size):
1349         (WebCore::GraphicsSurfacePrivate::findFBConfigWithAlpha):
1350         (WebCore::GraphicsSurfacePrivate::clear):
1351         (GraphicsSurfacePrivate):
1352
1353 2013-01-21  Michael[tm] Smith  <mike@w3.org>
1354
1355         Implement the HTML <main> element.
1356         https://bugs.webkit.org/show_bug.cgi?id=103172
1357
1358         Reviewed by Chris Fleizach.
1359
1360         Authored by Steve Faulkner <faulkner.steve@gmail.com>
1361
1362         <main> should behave the same as <nav>, <section>, and <article>, and <aside>.
1363         <main> should expose AXLandmarkMain correctly on each platform.
1364
1365         Tests: fast/html/main-element.html
1366                platform/chromium/accessibility/main-element.html
1367                platform/mac/accessibility/main-element.html
1368
1369         * accessibility/AccessibilityRenderObject.cpp:
1370         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
1371         * css/html.css:
1372         (article, aside, footer, header, hgroup, main, nav, section):
1373         * editing/FormatBlockCommand.cpp:
1374         (WebCore::isElementForFormatBlock):
1375         * html/HTMLTagNames.in:
1376         * html/parser/HTMLStackItem.h:
1377         (WebCore::HTMLStackItem::isSpecialNode):
1378         * html/parser/HTMLTreeBuilder.cpp:
1379         (WebCore::HTMLTreeBuilder::processStartTagForInBody):
1380         (WebCore::HTMLTreeBuilder::processEndTagForInBody):
1381
1382 2013-01-21  Joanmarie Diggs  <jdiggs@igalia.com>
1383
1384         Crash in AccessibilityTableCell::parentTable()
1385         https://bugs.webkit.org/show_bug.cgi?id=107261
1386
1387         Reviewed by Chris Fleizach.
1388
1389         Test: accessibility/table-destroyed-crash.html
1390
1391         Getting the parent table in order to get the role value should not be
1392         done when objects are being destroyed. Also, it does not seem safe to
1393         assume we have an AXObjectCache.
1394
1395         Moving the logic from roleValue() to determineAccessibilityRole() has
1396         the side effect of not being able to verify the cell is in an AXTable
1397         when that AXTable has not yet been created. Therefore isTableCell()
1398         should look to see if it is the descendant of an AXRow.
1399
1400         * accessibility/AccessibilityTableCell.cpp:
1401         (WebCore::AccessibilityTableCell::parentTable):
1402         (WebCore::AccessibilityTableCell::isTableCell):
1403         (WebCore::AccessibilityTableCell::determineAccessibilityRole):
1404         * accessibility/AccessibilityTableCell.h:
1405         (AccessibilityTableCell):
1406
1407 2013-01-21  Halton Huo  <halton.huo@intel.com>
1408
1409         [GTK] Volume button should not be shown for videos without audio
1410         https://bugs.webkit.org/show_bug.cgi?id=106436
1411
1412         Reviewed by Philippe Normand.
1413
1414         The volume control is no longer shown for videos with no audio.
1415
1416         No new tests, tested by media/video-no-audio.html.
1417
1418         * platform/gtk/RenderThemeGtk.cpp:
1419         (WebCore::RenderThemeGtk::hasOwnDisabledStateHandlingFor):
1420         (WebCore):
1421         * platform/gtk/RenderThemeGtk.h:
1422
1423 2013-01-21  Dan Winship  <danw@gnome.org>
1424
1425         [Soup] Work around a glib bug
1426         https://bugs.webkit.org/show_bug.cgi?id=106789
1427
1428         Reviewed by Martin Robinson.
1429
1430         In glib <= 2.35.4, g_input_stream_skip_async() applied to a
1431         libsoup response stream will do a synchronous skip() in another
1432         thread, which libsoup isn't expecting and doesn't have proper
1433         locking for. Work around this until the next time we bump the glib
1434         requirement by using read_async() (and throwing away the result)
1435         instead of skip_async().
1436
1437         No new tests; fixes a race condition in existing tests with older
1438         glib
1439
1440         * platform/network/soup/ResourceHandleSoup.cpp:
1441         (WebCore::redirectSkipCallback):
1442         (WebCore::sendRequestCallback):
1443
1444 2013-01-18  Andrey Kosyakov  <caseq@chromium.org>
1445
1446         Web Inspector: data grid resize is slow
1447         https://bugs.webkit.org/show_bug.cgi?id=107291
1448
1449         Reviewed by Pavel Feldman.
1450
1451         - avoid (most of) unnecessary relayouts and style recalculation when dragging data grid resizer.
1452
1453         * inspector/front-end/DataGrid.js:
1454         (WebInspector.DataGrid.prototype._positionResizers):
1455         (WebInspector.DataGrid.prototype._resizerDragging):
1456
1457 2013-01-21  Vladislav Kaznacheev  <kaznacheev@chromium.org>
1458
1459         [Inspector] Layout Elements panel in a single column when docked right.
1460         https://bugs.webkit.org/show_bug.cgi?id=107129
1461
1462         Reviewed by Pavel Feldman.
1463
1464         If the Inspector is docked right, the style panes in the Elements panel
1465         are put below the DOM tree pane, not to the right. This behavior
1466         is experimental (hidden behind a new flag "elementsPanelSingleColumn").
1467
1468         No new tests.
1469
1470         * inspector/front-end/DockController.js:
1471         (WebInspector.DockController.prototype.dockSide):
1472         (WebInspector.DockController.prototype._updateUI):
1473         (WebInspector.DockController.prototype._toggleDockState):
1474         * inspector/front-end/ElementsPanel.js:
1475         (WebInspector.ElementsPanel.prototype.onResize):
1476         (WebInspector.ElementsPanel.prototype._onDockStateChanged):
1477         (WebInspector.ElementsPanel.prototype._sidebarPosition):
1478         * inspector/front-end/Panel.js:
1479         (WebInspector.Panel.prototype.createSidebarView):
1480         * inspector/front-end/Settings.js:
1481         (WebInspector.ExperimentsSettings):
1482         * inspector/front-end/SidebarView.js:
1483         (WebInspector.SidebarView):
1484         (WebInspector.SidebarView.prototype.get mainElement):
1485         (WebInspector.SidebarView.prototype.get sidebarElement):
1486         (WebInspector.SidebarView.prototype._setSidebarElementStyle):
1487         (WebInspector.SidebarView.prototype.setSidebarPosition):
1488         (WebInspector.SidebarView.prototype._innerSetSidebarPosition):
1489         (WebInspector.SidebarView.prototype.setMinimumSidebarHeight):
1490         (WebInspector.SidebarView.prototype.setMinimumMainHeightPercent):
1491         (WebInspector.SidebarView.prototype.applyConstraints):
1492         (WebInspector.SidebarView.prototype.hideMainElement):
1493         (WebInspector.SidebarView.prototype.hideSidebarElement):
1494         * inspector/front-end/SplitView.js:
1495         (WebInspector.SplitView):
1496         * inspector/front-end/splitView.css:
1497         (.split-view-sidebar-top):
1498         (.split-view-sidebar-top.maximized):
1499         (.split-view-sidebar-bottom):
1500         (.split-view-sidebar-bottom.maximized):
1501
1502 2013-01-21  Yury Semikhatsky  <yurys@chromium.org>
1503
1504         Web Inspector: do not serialize native heap graph when collecting information about memory distribution
1505         https://bugs.webkit.org/show_bug.cgi?id=107450
1506
1507         Reviewed by Pavel Feldman.
1508
1509         Native heap graph is not reported when we need to show only high-level memory distribution.
1510
1511         * inspector/front-end/NativeMemorySnapshotView.js:
1512         (WebInspector.NativeMemorySnapshotView):
1513         (WebInspector.NativeMemoryProfileType.prototype.buttonClicked.didReceiveMemorySnapshot):
1514         (WebInspector.NativeMemoryProfileType.prototype.buttonClicked):
1515
1516 2013-01-21  Alexander Pavlov  <apavlov@chromium.org>
1517
1518         Web Inspector: [REGRESSION] Forced :visited pseudoclass has no effect on A elements
1519         https://bugs.webkit.org/show_bug.cgi?id=107448
1520
1521         Reviewed by Antti Koivisto.
1522
1523         * css/StyleResolver.cpp:
1524         (WebCore::StyleResolver::sortAndTransferMatchedRules): Remove totally bad code.
1525         (WebCore::StyleResolver::styleForElement):
1526           Use InsideVisitedLink if PseudoVisited has been forced by Inspector.
1527
1528 2013-01-18  Andrey Adaikin  <aandrey@chromium.org>
1529
1530         Web Inspector: modify generate_protocol_externs.py to generate JSON typedef's for @constructors
1531         https://bugs.webkit.org/show_bug.cgi?id=107287
1532
1533         Reviewed by Pavel Feldman.
1534
1535         Modify generate_protocol_externs.py to generate @typedefs instead of @constructors,
1536
1537         * inspector/InjectedScriptCanvasModuleSource.js:
1538         (.):
1539         * inspector/InjectedScriptSource.js:
1540         * inspector/compile-front-end.py:
1541         * inspector/generate_protocol_externs.py:
1542         (param_type):
1543
1544 2013-01-21  Oleg Smirnov  <oleg.smirnov@lge.com>
1545
1546         [Gtk] [Cairo] Memory leak when is WebView destroy.
1547         https://bugs.webkit.org/show_bug.cgi?id=107112
1548
1549         Reviewed by Martin Robinson.
1550
1551         Make createSurfaceForBackingStore return a smart pointer in all supported
1552         build configurations to avoid a memory leak.
1553         
1554         No new tests. There is memory leak only.
1555
1556         * platform/cairo/WidgetBackingStoreCairo.cpp:
1557         (WebCore::createSurfaceForBackingStore):
1558
1559 2013-01-21  Kent Tamura  <tkent@chromium.org>
1560
1561         INPUT_MULTIPLE_FIELDS_UI: should not dispatch 'input' events if the element value is not updated
1562         https://bugs.webkit.org/show_bug.cgi?id=107429
1563
1564         Reviewed by Kentaro Hara.
1565
1566         http://www.whatwg.org/specs/web-apps/current-work/multipage/common-input-element-attributes.html#common-event-behaviors
1567         > any time the user causes the element's value to change, the user agent
1568         > must queue a task to fire a simple event that bubbles named input at the
1569         > input element.
1570
1571         Tests:
1572         fast/forms/time-multiple-fields/time-multiple-fields-keyboard-event.html
1573         is updated to cover this change.
1574
1575         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
1576         (WebCore::BaseMultipleFieldsDateAndTimeInputType::editControlValueChanged):
1577         If the new value is equivalent to the old value, don't dispatch events.
1578         However we should recalculate validity and call notifyFormStateChanged
1579         because input.validity.badInput state might be changed.
1580
1581 2013-01-21  Alexander Pavlov  <apavlov@chromium.org>
1582
1583         Web Inspector: Do not dispatch mousemove when emulating touch event and no touch is active
1584         https://bugs.webkit.org/show_bug.cgi?id=107419
1585
1586         Reviewed by Pavel Feldman.
1587
1588         mousemove event should not be dispatched when emulating touch events and mouse button is not pressed
1589
1590         * page/EventHandler.cpp:
1591         (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
1592
1593 2013-01-21  Andrey Lushnikov  <lushnikov@chromium.org>
1594
1595         Web Inspector: fix highlight bug in DTE.
1596         https://bugs.webkit.org/show_bug.cgi?id=107433
1597
1598         Reviewed by Pavel Feldman.
1599
1600         Do not re-create |state.ranges| array when it already contains highlight.
1601
1602         Test: inpector/editor/highlighter-chunk-limit.txt
1603
1604         * inspector/front-end/TextEditorHighlighter.js:
1605         (WebInspector.TextEditorHighlighter.prototype._highlightLines):
1606
1607 2013-01-21  Takashi Sakamoto  <tasak@google.com>
1608
1609         [Refactoring] rename StyleRuleBlock -> StyleRuleGroup
1610         https://bugs.webkit.org/show_bug.cgi?id=107415
1611
1612         Reviewed by Antti Koivisto.
1613
1614         StyleRuleBlock should be renamed StyleRuleGroup, because
1615         CSSGroupingRule (not CSSBlockRule) is an interface for an at-rule that
1616         contains other rules nested inside itself:
1617         http://www.w3.org/TR/2012/WD-css3-conditional-20121213/#the-cssgroupingrule-interface
1618         To match the name: CSSGroupingRule, StyleRuleGroup looks better.
1619
1620         No new tests, because just refactoring.
1621
1622         * css/CSSGroupingRule.cpp:
1623         (WebCore::CSSGroupingRule::CSSGroupingRule):
1624         (WebCore::CSSGroupingRule::reattach):
1625         * css/CSSGroupingRule.h:
1626         (CSSGroupingRule):
1627         * css/StyleRule.cpp:
1628         (WebCore::StyleRuleGroup::StyleRuleGroup):
1629         (WebCore::StyleRuleGroup::wrapperInsertRule):
1630         (WebCore::StyleRuleGroup::wrapperRemoveRule):
1631         (WebCore::StyleRuleGroup::reportDescendantMemoryUsage):
1632         (WebCore::StyleRuleMedia::StyleRuleMedia):
1633         (WebCore::StyleRuleSupports::StyleRuleSupports):
1634         (WebCore::StyleRuleRegion::StyleRuleRegion):
1635         * css/StyleRule.h:
1636         (StyleRuleGroup):
1637         (WebCore::StyleRuleHost::StyleRuleHost):
1638         (WebCore::toStyleRuleMedia):
1639         (WebCore::toStyleRuleSupports):
1640         (WebCore::toStyleRuleRegion):
1641         Just replaced StyleRuleBlock with StyleRuleGroup.
1642
1643 2013-01-21  Andrey Lushnikov  <lushnikov@chromium.org>
1644
1645         Web Inspector: refactoring to use string as argument for highlightRegex API
1646         https://bugs.webkit.org/show_bug.cgi?id=107243
1647
1648         Reviewed by Pavel Feldman.
1649
1650         Use string as argument for highlightRegex API instead of using regex object.
1651
1652         No new tests: no change in behaviour.
1653
1654         * inspector/front-end/DefaultTextEditor.js:
1655         (WebInspector.TextEditorMainPanel.prototype.highlightRegex):
1656         * inspector/front-end/TextEditor.js:
1657
1658 2013-01-21  Sheriff Bot  <webkit.review.bot@gmail.com>
1659
1660         Unreviewed, rolling out r140311.
1661         http://trac.webkit.org/changeset/140311
1662         https://bugs.webkit.org/show_bug.cgi?id=107431
1663
1664         Broke selection-related tests (Requested by apavlov on
1665         #webkit).
1666
1667         * page/EventHandler.cpp:
1668         (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
1669
1670 2013-01-21  Kentaro Hara  <haraken@chromium.org>
1671
1672         Unreviewed. Build fix.
1673
1674         * bindings/v8/V8NPObject.cpp:
1675         (WebCore::createV8ObjectForNPObject):
1676
1677 2013-01-20  Alexander Pavlov  <apavlov@chromium.org>
1678
1679         Web Inspector: Do not dispatch mousemove when emulating touch event and no touch is active
1680         https://bugs.webkit.org/show_bug.cgi?id=107419
1681
1682         Reviewed by Pavel Feldman.
1683
1684         mousemove event should not be dispatched when emulating touch events and mouse button is not pressed
1685
1686         * page/EventHandler.cpp:
1687         (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
1688
1689 2013-01-21  Tommy Widenflycht  <tommyw@google.com>
1690
1691         MediaStream API: Update the RTCPeerConnection states to match the latest specification
1692         https://bugs.webkit.org/show_bug.cgi?id=107120
1693
1694         Reviewed by Adam Barth.
1695
1696         http://dev.w3.org/2011/webrtc/editor/webrtc.html#interface-definition
1697
1698         RTCPeerConnection::readyState and iceState are history and instead signalingState,
1699         iceConnectionState and iceGatheringState have been introduced.
1700
1701         Existing tests updated to cover this patch.
1702
1703         * Modules/mediastream/RTCPeerConnection.cpp:
1704         (WebCore::RTCPeerConnection::RTCPeerConnection):
1705         (WebCore::RTCPeerConnection::createOffer):
1706         (WebCore::RTCPeerConnection::createAnswer):
1707         (WebCore::RTCPeerConnection::setLocalDescription):
1708         (WebCore::RTCPeerConnection::localDescription):
1709         (WebCore::RTCPeerConnection::setRemoteDescription):
1710         (WebCore::RTCPeerConnection::remoteDescription):
1711         (WebCore::RTCPeerConnection::updateIce):
1712         (WebCore::RTCPeerConnection::addIceCandidate):
1713         (WebCore::RTCPeerConnection::readyState):
1714         (WebCore):
1715         (WebCore::RTCPeerConnection::signalingState):
1716         (WebCore::RTCPeerConnection::iceConnectionState):
1717         (WebCore::RTCPeerConnection::addStream):
1718         (WebCore::RTCPeerConnection::removeStream):
1719         (WebCore::RTCPeerConnection::createDataChannel):
1720         (WebCore::RTCPeerConnection::close):
1721         (WebCore::RTCPeerConnection::didChangeSignalingState):
1722         (WebCore::RTCPeerConnection::didChangeIceGatheringState):
1723         (WebCore::RTCPeerConnection::didChangeIceConnectionState):
1724         (WebCore::RTCPeerConnection::didAddRemoteStream):
1725         (WebCore::RTCPeerConnection::didRemoveRemoteStream):
1726         (WebCore::RTCPeerConnection::didAddRemoteDataChannel):
1727         (WebCore::RTCPeerConnection::stop):
1728         (WebCore::RTCPeerConnection::changeSignalingState):
1729         (WebCore::RTCPeerConnection::changeIceGatheringState):
1730         (WebCore::RTCPeerConnection::changeIceConnectionState):
1731         * Modules/mediastream/RTCPeerConnection.h:
1732         (RTCPeerConnection):
1733         * Modules/mediastream/RTCPeerConnection.idl:
1734         * platform/mediastream/RTCPeerConnectionHandlerClient.h:
1735         (RTCPeerConnectionHandlerClient):
1736         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
1737         (WebCore::RTCPeerConnectionHandlerChromium::didChangeSignalingState):
1738         (WebCore::RTCPeerConnectionHandlerChromium::didChangeICEConnectionState):
1739         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
1740         (RTCPeerConnectionHandlerChromium):
1741
1742 2013-01-21  Kent Tamura  <tkent@chromium.org>
1743
1744         Use ISO8601 date/time formats as fallbacks for date/time input types
1745         https://bugs.webkit.org/show_bug.cgi?id=107418
1746
1747         Reviewed by Kentaro Hara.
1748
1749         We obtain date/time formats from OSes to build date/time input type
1750         UIs. If something wrong happens in the code, fallback formats are
1751         used. Such fallback formats should not be English formats in order that
1752         we can find defects easily.
1753
1754         No new tests. These formats should not be used unless the current code
1755         has defects.
1756
1757         * html/DateTimeInputType.cpp:
1758         (WebCore::DateTimeInputType::setupLayoutParameters):
1759         Use an ISO8601 format which is same as a format used in HTML5.
1760         * html/DateTimeLocalInputType.cpp:
1761         (WebCore::DateTimeLocalInputType::setupLayoutParameters): Ditto.
1762         * html/MonthInputType.cpp:
1763         (WebCore::MonthInputType::setupLayoutParameters): Ditto.
1764         * html/WeekInputType.cpp:
1765         (WebCore::WeekInputType::setupLayoutParameters): Ditto.
1766         * platform/text/LocaleICU.cpp:
1767         (WebCore::LocaleICU::dateFormat): Ditto.
1768         * platform/text/LocaleNone.cpp:
1769         (WebCore::LocaleNone::dateFormat): Ditto.
1770         (WebCore::LocaleNone::dateTimeFormatWithSeconds): Ditto.
1771         (WebCore::LocaleNone::dateTimeFormatWithoutSeconds): Ditto.
1772
1773 2013-01-20  Matt Falkenhagen  <falken@chromium.org>
1774
1775         Elements must be reattached when inserted/removed from top layer
1776         https://bugs.webkit.org/show_bug.cgi?id=105489
1777
1778         Relanding r139402 as rollout due to suspected perf regression did not help (bug 106726).
1779
1780         Reviewed by Julien Chaffraix.
1781
1782         Ensure a reattach occurs when an element is inserted/removed from top layer, so its renderer can be inserted correctly:
1783         as a child of RenderView in top layer sibling order if it's in the top layer, and in the usual place otherwise.
1784
1785         We previously relied on style recalc to catch when an element is inserted/removed from the top layer, because it
1786         only happens on dialog.show/close which toggle display: none. But that is incorrect because, for example, close()
1787         followed immediately by show() results in no style change.
1788
1789         Tests: fast/dom/HTMLDialogElement/removed-element-is-removed-from-top-layer.html
1790                fast/dom/HTMLDialogElement/top-layer-stacking-correct-order-remove-readd.html
1791
1792         * dom/Element.cpp:
1793         (WebCore::Element::removedFrom): Call Document::removeFromTopLayer to let the element be removed from the top layer vector.
1794         removeFromTopLayer calls Element::setIsInTopLayer(false) itself if needed.
1795         (WebCore::Element::setIsInTopLayer): Ensure a reattach occurs if the element is already attached.
1796
1797 2013-01-20  Yury Semikhatsky  <yurys@chromium.org>
1798
1799         Web Inspector: change HeapSnapshotLoader to allow loading native heap snapshots
1800         https://bugs.webkit.org/show_bug.cgi?id=107282
1801
1802         Reviewed by Pavel Feldman.
1803
1804         Conctete heap snapshot constructor name is passed as a parameter to HeapSnapshotLoaderProxy and
1805         propagated to HeapSnapshotLoader.buildSnapshot to support different types of heap snapshots.
1806
1807         * inspector/front-end/HeapSnapshotLoader.js:
1808         (WebInspector.HeapSnapshotLoader.prototype.buildSnapshot):
1809         * inspector/front-end/HeapSnapshotProxy.js:
1810         (WebInspector.HeapSnapshotWorker.prototype.createLoader):
1811         (WebInspector.HeapSnapshotLoaderProxy):
1812         (WebInspector.HeapSnapshotLoaderProxy.prototype.close):
1813         * inspector/front-end/HeapSnapshotView.js:
1814         (WebInspector.HeapProfileHeader.prototype._setupWorker):
1815
1816 2013-01-20  Kentaro Hara  <haraken@chromium.org>
1817
1818         Implement MediaStreamEvent constructor
1819         https://bugs.webkit.org/show_bug.cgi?id=107411
1820
1821         Reviewed by Adam Barth.
1822
1823         Spec: http://www.w3.org/TR/webrtc/#mediastreamevent
1824
1825         Test: fast/events/constructors/media-stream-event-constructor.html
1826
1827         * Modules/mediastream/MediaStreamEvent.cpp:
1828         (WebCore::MediaStreamEventInit::MediaStreamEventInit):
1829         (WebCore):
1830         (WebCore::MediaStreamEvent::create):
1831         (WebCore::MediaStreamEvent::MediaStreamEvent):
1832         * Modules/mediastream/MediaStreamEvent.h:
1833         (MediaStreamEventInit):
1834         (WebCore):
1835         (MediaStreamEvent):
1836         * Modules/mediastream/MediaStreamEvent.idl:
1837         * bindings/js/JSDictionary.cpp:
1838         (WebCore):
1839         (WebCore::JSDictionary::convertValue):
1840         * bindings/js/JSDictionary.h:
1841         (WebCore):
1842         * bindings/v8/Dictionary.cpp:
1843         (WebCore):
1844         (WebCore::Dictionary::get):
1845         * bindings/v8/Dictionary.h:
1846         (Dictionary):
1847
1848 2013-01-20  Vladislav Kaznacheev  <kaznacheev@chromium.org>
1849
1850         Web Inspector: Allow SplitView to change orientation after the construction.
1851         https://bugs.webkit.org/show_bug.cgi?id=107263
1852
1853         Added SplitView.prototype.setIsVertical to change the orientation on the fly.
1854         Instead of passing default sidebar size to the constructor the client
1855         may now pass separate defaults for the sidebar width and height. Passing
1856         just one default works as before.
1857
1858         Reviewed by Pavel Feldman.
1859
1860         No new tests.
1861
1862         * inspector/front-end/SplitView.js:
1863         (WebInspector.SplitView):
1864         (WebInspector.SplitView.prototype.isVertical):
1865         (WebInspector.SplitView.prototype.setIsVertical):
1866         (WebInspector.SplitView.prototype._innerSetIsVertical):
1867         (WebInspector.SplitView.prototype._updateLayout):
1868         (WebInspector.SplitView.prototype.isSidebarSecond):
1869         (WebInspector.SplitView.prototype.showBoth):
1870         (WebInspector.SplitView.prototype._updateTotalSize):
1871         (WebInspector.SplitView.prototype._innerSetSidebarSize):
1872         (WebInspector.SplitView.prototype.wasShown):
1873         (WebInspector.SplitView.prototype.onResize):
1874         (WebInspector.SplitView.prototype.installResizer):
1875         (WebInspector.SplitView.prototype._onDragStart):
1876         (WebInspector.SplitView.prototype._sizeSetting):
1877         (WebInspector.SplitView.prototype._lastSidebarSize):
1878         (WebInspector.SplitView.prototype.get _saveSidebarSize):
1879
1880 2013-01-20  Kentaro Hara  <haraken@chromium.org>
1881
1882         Add a [ConstructorConditional] IDL attribute
1883         https://bugs.webkit.org/show_bug.cgi?id=107407
1884
1885         Reviewed by Adam Barth.
1886
1887         Per discussion in webkit-dev, we need to implement DOM4 event constructors
1888         under a enable flag. For that purpose, we implement a [ConstructorConditional]
1889         IDL attribute.
1890
1891         Test: bindings/scripts/test/TestInterface.idl
1892
1893         * bindings/scripts/CodeGenerator.pm:
1894         (GenerateConstructorConditionalString):
1895         * bindings/scripts/CodeGeneratorJS.pm:
1896         (GenerateConstructorDeclaration):
1897         (GenerateConstructorHelperMethods):
1898         * bindings/scripts/CodeGeneratorV8.pm:
1899         (GenerateHeader):
1900         (GenerateImplementation):
1901         * bindings/scripts/IDLAttributes.txt:
1902         * bindings/scripts/test/JS/JSTestInterface.cpp:
1903         (WebCore):
1904         * bindings/scripts/test/JS/JSTestInterface.h:
1905         (JSTestInterfaceConstructor):
1906         * bindings/scripts/test/TestInterface.idl:
1907         * bindings/scripts/test/V8/V8TestInterface.cpp:
1908         (WebCore::ConfigureV8TestInterfaceTemplate):
1909         * bindings/scripts/test/V8/V8TestInterface.h:
1910         (V8TestInterface):
1911
1912 2013-01-20  Kentaro Hara  <haraken@chromium.org>
1913
1914         [V8] We should set a class id for a NPObject wrapper
1915         https://bugs.webkit.org/show_bug.cgi?id=107249
1916
1917         Reviewed by Adam Barth.
1918
1919         This is one of steps to avoid hitting an ASSERT()
1920         that will be added in https://bugs.webkit.org/show_bug.cgi?id=107137 .
1921
1922         No tests. No change in behavior.
1923
1924         * bindings/v8/V8DOMWrapper.h:
1925         (V8DOMWrapper):
1926         (WebCore::V8DOMWrapper::setWrapperClass):
1927         (WebCore):
1928         * bindings/v8/V8NPObject.cpp:
1929         (WebCore::createV8ObjectForNPObject):
1930
1931 2013-01-20  Mike Lawther  <mikelawther@chromium.org>
1932
1933         CSS3 calc: unprefix implementation
1934         https://bugs.webkit.org/show_bug.cgi?id=91951
1935
1936         Reviewed by Ojan Vafai.
1937
1938         Add support for the unprefixed 'calc()' function, while retaining support for the prefixed version.
1939
1940         Test: css3/calc/simple-calcs-prefixed.html
1941
1942         * css/CSSCalculationValue.cpp:
1943         (WebCore::buildCssText):
1944         (WebCore::CSSCalcValue::create):
1945         * css/CSSParser.cpp:
1946         (WebCore::CSSParser::isCalculation):
1947         (WebCore::CSSParser::detectFunctionTypeToken):
1948
1949 2013-01-20  Shinya Kawanaka  <shinyak@chromium.org>
1950
1951         Distribution state becomes inconsistent with content/shadow reprojection
1952         https://bugs.webkit.org/show_bug.cgi?id=106634
1953
1954         Reviewed by Hajime Morita.
1955
1956         Distribution should be resolved from shallower ShadowDOM to deeper Shadow DOM. However, in the current implementation,
1957         there is a case that distribution for deeper ShadowDOM happens to be resolved before distribution
1958         for shallower ShadowDOM is resolved.
1959
1960         Here, we have 2 problems about distribution.
1961         1) Invalidation state is not propagated to nested (= deeper) ShadowDOM.
1962             - This causes deeper ShadowDOM looks having a valid distribution though it should be invalid.
1963         2) We are not resolving shallower ShadowDOM when deeper ShadowDOM's distribution is needed.
1964             - Because of (1), we have to check all the ancestor ShadowDOM.
1965
1966         For (1), we change invalidate() to invalidate nested ShadowDOM's distribution as well.
1967         For (2), when resolving distribution, we will check the ancestor ShadowDOM's distribution state. If the ancestor's
1968         distribution is not valid, we resolve it first.
1969
1970         For optimization of (1), actually we can skip invalidating distribution of some ShadowDOMs.
1971         If ShadowRoot of deeper ShadowDOM does not have an InsertionPoint as children, we can skip invalidating
1972         its distribution, because only children can be distributed to InsertionPoint.
1973
1974         Tests: fast/dom/shadow/distribution-crash.html
1975                fast/dom/shadow/nested-reprojection-inconsistent.html
1976
1977         * dom/ElementShadow.cpp:
1978         (WebCore::ElementShadow::attach): Should resolve distribution from ancestor.
1979         * dom/ElementShadow.h:
1980         * html/shadow/ContentDistributor.cpp:
1981         (WebCore::ContentDistributor::distribute): Added ASSERT that the parent ShadowRoot's distribution is resolved.
1982         (WebCore::ContentDistributor::invalidate): For each InsertionPoint, we have to invalidate
1983         its parent element's distribution (if it has ElementShadow).
1984         (WebCore::ContentDistributor::ensureDistribution):
1985         * html/shadow/ContentDistributor.h:
1986         (WebCore::ContentDistributor::isValid):
1987         * html/shadow/HTMLShadowElement.cpp:
1988         (WebCore::HTMLShadowElement::olderShadowRoot): Should resolve distribution from ancestor.
1989         * html/shadow/InsertionPoint.cpp:
1990         (WebCore::InsertionPoint::attach): ditto.
1991         (WebCore::InsertionPoint::detach): ditto.
1992         (WebCore::InsertionPoint::getDistributedNodes): ditto.
1993         (WebCore::resolveReprojection): ditto.
1994
1995 2013-01-20  Dominic Mazzoni  <dmazzoni@google.com>
1996
1997         Make SpeechSynthesis compile in the Chromium port
1998         https://bugs.webkit.org/show_bug.cgi?id=107382
1999
2000         Reviewed by Adam Barth.
2001
2002         Add stubs for the Chromium implementation of speech synthesis,
2003         and add all source and header files to WebCore.gypi. Everything
2004         is behind the ENABLE_SPEECH_SYNTHESIS flag.
2005
2006         * Modules/speech/chromium/SpeechSynthesisChromium.cpp: Added.
2007         (WebCore):
2008         (WebCore::SpeechSynthesis::initializeVoiceList):
2009         (WebCore::SpeechSynthesis::pending):
2010         (WebCore::SpeechSynthesis::speaking):
2011         (WebCore::SpeechSynthesis::paused):
2012         (WebCore::SpeechSynthesis::speak):
2013         (WebCore::SpeechSynthesis::cancel):
2014         (WebCore::SpeechSynthesis::pause):
2015         (WebCore::SpeechSynthesis::resume):
2016         * WebCore.gypi:
2017
2018 2013-01-20  Kent Tamura  <tkent@chromium.org>
2019
2020         Re-layout child blocks when border/padding of the box-sizing:border-box parent is updated
2021         https://bugs.webkit.org/show_bug.cgi?id=104997
2022
2023         Reviewed by Tony Chang.
2024
2025         When padding or border is updated for a parent block with
2026         box-sizing:border-box and width, the width of its child block was not
2027         updated.
2028
2029         Tests: fast/css/box-sizing-border-box-dynamic-padding-border-update.html
2030                fast/forms/text/text-padding-dynamic-change.html
2031
2032         * rendering/RenderBox.cpp:
2033         (WebCore::RenderBox::styleDidChange):
2034         If box-sizing of the old style and/or the new style is border-box and
2035         padding or border is changed, apply setChildNeedsLayout(true) for child
2036         boxes.
2037
2038 2013-01-20  Kentaro Hara  <haraken@chromium.org>
2039
2040         [V8] Remove custom V8ScriptProfileCustom::toV8()
2041         https://bugs.webkit.org/show_bug.cgi?id=107246
2042
2043         Reviewed by Adam Barth.
2044
2045         V8ScriptProfileCustom::toV8() needs not to be custom.
2046         Furthermore, the current custom toV8() is wrong in that
2047         it doesn't use a creationContext and it doesn't set a
2048         wrapper class id. This is one of steps to avoiding
2049         ASSERT()s that will be added in
2050         https://bugs.webkit.org/show_bug.cgi?id=107137 .
2051
2052         No tests. No change in behavior.
2053
2054         * UseV8.cmake:
2055         * WebCore.gypi:
2056         * bindings/v8/custom/V8ScriptProfileCustom.cpp: Removed.
2057         * inspector/ScriptProfile.idl:
2058
2059 2013-01-20  Sheriff Bot  <webkit.review.bot@gmail.com>
2060
2061         Unreviewed, rolling out r140290.
2062         http://trac.webkit.org/changeset/140290
2063         https://bugs.webkit.org/show_bug.cgi?id=107412
2064
2065         Broke tests of inspector and calendar picker in debug build
2066         (Requested by tkent on #webkit).
2067
2068         * rendering/RenderBox.cpp:
2069         (WebCore::RenderBox::styleDidChange):
2070
2071 2013-01-20  Yongsheng Zhu  <yongsheng.zhu@intel.com>
2072
2073         Dispatch LongPress to inner frames
2074         https://bugs.webkit.org/show_bug.cgi?id=106874
2075
2076         Reviewed by Antonio Gomes.
2077
2078         Do check whether a LongPress gesture event should be passed
2079         to inner frames. If needed, dispatch it.
2080
2081         Tests: fast/events/touch/gesture/long-press-on-draggable-element-in-iframe-triggers-drag.html
2082                fast/events/touch/gesture/long-press-on-draggable-element-in-nested-iframes-triggers-drag.html
2083
2084         * page/EventHandler.cpp:
2085         (WebCore::EventHandler::handleGestureLongPress):
2086
2087 2013-01-20  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2088
2089         Clean up missing *explicit* keyword in ctors of WebCore/rendering.
2090         https://bugs.webkit.org/show_bug.cgi?id=107373
2091
2092         Reviewed by Darin Adler.
2093
2094         Need to add *explicit* keyword to avoid implicit type conversion.
2095
2096         * rendering/RenderApplet.h:
2097         (RenderApplet):
2098         * rendering/RenderArena.h:
2099         (RenderArena):
2100         * rendering/RenderBR.h:
2101         (RenderBR):
2102         * rendering/RenderBlock.h:
2103         (RenderBlock):
2104         * rendering/RenderBox.h:
2105         (RenderBox):
2106         * rendering/RenderDetailsMarker.h:
2107         (RenderDetailsMarker):
2108         * rendering/RenderFlexibleBox.h:
2109         (RenderFlexibleBox):
2110         * rendering/RenderFlowThread.h:
2111         * rendering/RenderFullScreen.h:
2112         (RenderFullScreen):
2113         * rendering/RenderGeometryMap.h:
2114         (WebCore::RenderGeometryMapStep::RenderGeometryMapStep):
2115         * rendering/RenderGrid.h:
2116         (RenderGrid):
2117         * rendering/RenderImage.h:
2118         (RenderImage):
2119         * rendering/RenderLayerBacking.h:
2120         (RenderLayerBacking):
2121         * rendering/RenderLayerCompositor.h:
2122         (RenderLayerCompositor):
2123         * rendering/RenderLayerModelObject.h:
2124         (RenderLayerModelObject):
2125         * rendering/RenderListBox.h:
2126         (RenderListBox):
2127         * rendering/RenderListMarker.h:
2128         (RenderListMarker):
2129         * rendering/RenderMedia.h:
2130         (RenderMedia):
2131         * rendering/RenderMeter.h:
2132         (RenderMeter):
2133         * rendering/RenderMultiColumnBlock.h:
2134         (RenderMultiColumnBlock):
2135         * rendering/RenderMultiColumnFlowThread.h:
2136         (RenderMultiColumnFlowThread):
2137         * rendering/RenderObject.h:
2138         (RenderObject):
2139         * rendering/RenderPart.h:
2140         (RenderPart):
2141         * rendering/RenderProgress.h:
2142         (RenderProgress):
2143         * rendering/RenderReplaced.h:
2144         (RenderReplaced):
2145         * rendering/RenderReplica.h:
2146         (RenderReplica):
2147         * rendering/RenderRuby.h:
2148         (RenderRubyAsInline):
2149         * rendering/RenderRubyBase.h:
2150         (RenderRubyBase):
2151         * rendering/RenderRubyRun.h:
2152         (RenderRubyRun):
2153         * rendering/RenderRubyText.h:
2154         (RenderRubyText):
2155         * rendering/RenderSearchField.h:
2156         (RenderSearchField):
2157         * rendering/RenderSlider.h:
2158         (RenderSlider):
2159         * rendering/RenderSnapshottedPlugIn.h:
2160         (RenderSnapshottedPlugIn):
2161         * rendering/RenderTextControlMultiLine.h:
2162         (RenderTextControlMultiLine):
2163         * rendering/RenderTextControlSingleLine.h:
2164         (RenderTextControlSingleLine):
2165         * rendering/RenderView.h:
2166         (RenderView):
2167         * rendering/RenderWidgetProtector.h:
2168         (WebCore::RenderWidgetProtector::RenderWidgetProtector):
2169         * rendering/RootInlineBox.h:
2170         (RootInlineBox): Remove meaningless parameter name.
2171         * rendering/TableLayout.h:
2172         (WebCore::TableLayout::TableLayout):
2173
2174 2013-01-20  Kent Tamura  <tkent@chromium.org>
2175
2176         Re-layout child blocks when border/padding of the box-sizing:border-box parent is updated
2177         https://bugs.webkit.org/show_bug.cgi?id=104997
2178
2179         Reviewed by Tony Chang.
2180
2181         When padding or border is updated for a parent block with
2182         box-sizing:border-box and width, the width of its child block was not
2183         updated.
2184
2185         Tests: fast/css/box-sizing-border-box-dynamic-padding-border-update.html
2186                fast/forms/text/text-padding-dynamic-change.html
2187
2188         * rendering/RenderBox.cpp:
2189         (WebCore::RenderBox::styleDidChange):
2190         If box-sizing of the old style and/or the new style is border-box and
2191         padding or border is changed, apply setChildNeedsLayout(true) for child
2192         boxes.
2193
2194 2013-01-20  Kentaro Hara  <haraken@chromium.org>
2195
2196         Unreviewed, rolling out r140270.
2197         http://trac.webkit.org/changeset/140270
2198         https://bugs.webkit.org/show_bug.cgi?id=107253
2199
2200         Hit asserts in a debug build
2201
2202         * bindings/v8/V8DOMWindowShell.cpp:
2203         (WebCore::V8DOMWindowShell::installDOMWindow):
2204
2205 2013-01-20  Shinya Kawanaka  <shinyak@chromium.org>
2206
2207         [Shadow DOM] Specifying scrollbar style of an element having RenderLayer in ShadowDOM does not work.
2208         https://bugs.webkit.org/show_bug.cgi?id=107222
2209
2210         Reviewed by Simon Fraser.
2211
2212         When specifying scrollbar style in ShadowDOM, it's not used. If the host element of ShadowDOM has scrollbar style,
2213         it's used instead.
2214
2215         The root cause of this bug is that RenderLayer always see shadowAncestorNode's style. Some elements having
2216         UserAgent ShadowDOM (e.g. <textarea>) should see host's style, but most of elements should see its style.
2217
2218         Test: fast/dom/shadow/scrollbar.html
2219
2220         * rendering/RenderLayer.cpp:
2221         (WebCore::rendererForScrollbar):
2222         (WebCore):
2223         (WebCore::RenderLayer::createScrollbar):
2224         (WebCore::RenderLayer::updateScrollCornerStyle):
2225         (WebCore::RenderLayer::updateResizerStyle):
2226
2227 2013-01-20  Yoshifumi Inoue  <yosin@chromium.org>
2228
2229         Dragging over an element with scrollbars should scroll the element when dragging near edges
2230         https://bugs.webkit.org/show_bug.cgi?id=39725
2231
2232         Reviewed by Hajime Morita.
2233
2234         This patch introduces auto scrolling functionality during drag-and-drop
2235         when drop source is near edge of scrollable element.
2236
2237         When drop source is inside 20px of scrollable element more than 200ms,
2238         scrollable element is automatically scrolled every 50ms toward drop
2239         source position, e.g. vertically scroll up when drop source is in top
2240         edge.
2241
2242         Test: fast/events/drag-and-drop-autoscroll.html
2243
2244         * page/AutoscrollController.cpp:
2245         (WebCore::AutoscrollController::AutoscrollController): Changed to initialize m_dragAndDropAutoscrollStartTime.
2246         (WebCore::AutoscrollController::updateDragAndDrop): Added for start/stop autoscroll during drag-and-drop.
2247         (WebCore::AutoscrollController::autoscrollTimerFired): Changed to add autoscroll for drag-and-drop, and to pass last know position to RenderBox::autoscroll().
2248         * page/AutoscrollController.h:
2249         (AutoscrollController): Changed to add updateDragAndDrop() and m_dragAndDropAutoscrollReferencePosition and m_dragAndDropAutoscrollStartTime.
2250         * page/ChromeClient.h:
2251         (WebCore::ChromeClient): Changed to add new function shouldAutoscrollForDragAndDrop().
2252         * page/EventHandler.cpp:
2253         (WebCore::EventHandler::updateDragAndDrop): Changed to call AutoscrollController::updateDragAndDrop().
2254         (WebCore::EventHandler::clearDragState): Changed to call stopAutoscrollTimer().
2255         * rendering/RenderBox.cpp:
2256         (WebCore::RenderBox::autoscroll): Changed for new parameter position.
2257         (WebCore::RenderBox::calculateAutoscrollDirection): Added for autoscroll.
2258         * rendering/RenderBox.h:
2259         (RenderBox):
2260         * rendering/RenderLayer.cpp:
2261         (WebCore::RenderLayer::autoscroll):  Changed for new parameter position and move updateSelectionForMouseDrag() to AutoscrollController.
2262         * rendering/RenderLayer.h:
2263         (RenderLayer):
2264         * rendering/RenderListBox.cpp:
2265         (WebCore::RenderListBox::autoscroll):  Changed for new parameter position.
2266         * rendering/RenderListBox.h:
2267         (RenderListBox):
2268         * rendering/RenderTextControlSingleLine.cpp:
2269         (WebCore::RenderTextControlSingleLine::autoscroll):  Changed for new parameter position.
2270         * rendering/RenderTextControlSingleLine.h:
2271         (RenderTextControlSingleLine):
2272
2273 2013-01-20  Laszlo Gombos  <l.gombos@samsung.com>
2274
2275         Simplify a list of negative PLATFORM() tests
2276         https://bugs.webkit.org/show_bug.cgi?id=107365
2277
2278         Reviewed by Eric Seidel.
2279
2280         Simplify a list of negative PLATFORM() tests into a simpler list
2281         of positive tests for better readability and maintenance.
2282
2283         No new tests as there is no new functionality.
2284
2285         * config.h:
2286
2287 2013-01-20  Simon Fraser  <simon.fraser@apple.com>
2288
2289         Avoid filling a rounded rect when radii are zero
2290         https://bugs.webkit.org/show_bug.cgi?id=107402
2291         <rdar://problem/12793315>
2292
2293         Reviewed by Sam Weinig.
2294
2295         It's more efficient to clip and fill rects than rounded rects,
2296         so optimize for the case where rounded rect radii are zero.
2297
2298         * platform/graphics/GraphicsContext.cpp:
2299         (WebCore::GraphicsContext::clipRoundedRect):
2300         (WebCore::GraphicsContext::clipOutRoundedRect):
2301         (WebCore::GraphicsContext::fillRoundedRect):
2302
2303 2013-01-20  Alexey Proskuryakov  <ap@apple.com>
2304
2305         Remove obsolete plug-in sandboxing code.
2306         https://bugs.webkit.org/show_bug.cgi?id=107362
2307
2308         Reviewed by Darin Adler.
2309
2310         * WebCore.xcodeproj/project.pbxproj:
2311         * plugins/npapi-sandbox.h: Removed.
2312
2313 2013-01-20  Peter Rybin  <peter.rybin@gmail.com>
2314
2315         Web Inspector: Make V8 LiveEdit API disabled by default
2316         https://bugs.webkit.org/show_bug.cgi?id=106668
2317
2318         Reviewed by Yury Semikhatsky.
2319
2320         Initialize method is patched accordingly.
2321
2322         * bindings/v8/JavaScriptCallFrame.cpp:
2323         (WebCore::JavaScriptCallFrame::restart): missing enable/disable calls added for restart
2324         * bindings/v8/V8Initializer.cpp:
2325         (WebCore::initializeV8Common): initializer method patched
2326
2327 2013-01-20  Christophe Dumez  <christophe.dumez@intel.com>
2328
2329         [gstreamer]  assertion in g_object_unref from _WebKitWebAudioSourcePrivate destructor
2330         https://bugs.webkit.org/show_bug.cgi?id=107374
2331
2332         Reviewed by Philippe Normand.
2333
2334         WebKitWebAudioSrc object gets unrefed one time too many in
2335         _WebKitWebAudioSourcePrivate destructor, causing an assertion
2336         in g_object_unref. This patch passes NULL instead of
2337         g_object_unref to gst_task_new() so that the WebKitWebAudioSrc
2338         object does not get unrefed when the GstTask is destroyed.
2339
2340         No new tests, already covered by webaudio tests.
2341
2342         * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
2343         (webkit_web_audio_src_init):
2344
2345 2013-01-20  Kentaro Hara  <haraken@chromium.org>
2346
2347         [V8] Create a persistent wrapper for Window.prototype and innerGlobalObject
2348         https://bugs.webkit.org/show_bug.cgi?id=107253
2349
2350         Reviewed by Adam Barth.
2351
2352         This is one of steps to avoid hitting an ASSERT()
2353         that will be added in https://bugs.webkit.org/show_bug.cgi?id=107137 .
2354         We should have a persistent wrapper for all DOM objects
2355         and set a class id on the wrapper.
2356
2357         No tests. No change in behavior.
2358
2359         * bindings/v8/V8DOMWindowShell.cpp:
2360         (WebCore::V8DOMWindowShell::installDOMWindow):
2361
2362 2013-01-19  Philip Rogers  <pdr@google.com>
2363
2364         Refactor SVGSVGElement to inherit from SVGStyledTransformableElement
2365         https://bugs.webkit.org/show_bug.cgi?id=107393
2366
2367         Reviewed by Dirk Schulze.
2368
2369         This patch refactors SVGSVGElement to inherit from SVGStyledTransformableElement instead
2370         of SVGStyledLocatableElement. In a followup patch, SVGStyledTransformableElement will
2371         be refactored into SVGGraphicsElement which will match the spec:
2372         https://svgwg.org/svg2-draft/single-page.html#struct-InterfaceSVGSVGElement
2373
2374         Tests: svg/transforms/svgsvgelement-transform-expected.svg
2375                svg/transforms/svgsvgelement-transform.svg
2376
2377         * svg/SVGSVGElement.cpp:
2378         (WebCore):
2379         (WebCore::SVGSVGElement::SVGSVGElement):
2380         (WebCore::SVGSVGElement::didMoveToNewDocument):
2381         (WebCore::SVGSVGElement::parseAttribute):
2382         (WebCore::SVGSVGElement::insertedInto):
2383         (WebCore::SVGSVGElement::removedFrom):
2384         * svg/SVGSVGElement.h:
2385         (SVGSVGElement):
2386         * svg/SVGSVGElement.idl:
2387
2388 2013-01-19  Philip Rogers  <pdr@google.com>
2389
2390         Merge SVGStylable into SVGStyledElement
2391         https://bugs.webkit.org/show_bug.cgi?id=106877
2392
2393         Reviewed by Dirk Schulze.
2394
2395         SVG2 changes element inheritance so all SVGElements are stylable. As a first-step towards a
2396         cleaner class hierarchy, this patch moves SVGStylable into SVGStyledElement.
2397
2398         No new tests as this is just a refactoring.
2399
2400         * CMakeLists.txt:
2401         * DerivedSources.make:
2402         * GNUmakefile.list.am:
2403         * Target.pri:
2404         * WebCore.exp.in:
2405         * WebCore.gyp/WebCore.gyp:
2406         * WebCore.gypi:
2407         * WebCore.vcproj/WebCore.vcproj:
2408         * WebCore.xcodeproj/project.pbxproj:
2409         * bindings/objc/DOMSVG.h:
2410         * bindings/scripts/CodeGeneratorObjC.pm:
2411         * page/DOMWindow.idl:
2412         * svg/SVGAElement.idl:
2413         * svg/SVGAllInOne.cpp:
2414         * svg/SVGCircleElement.idl:
2415         * svg/SVGClipPathElement.idl:
2416         * svg/SVGDefsElement.idl:
2417         * svg/SVGDescElement.idl:
2418         * svg/SVGEllipseElement.idl:
2419         * svg/SVGFEBlendElement.idl:
2420         * svg/SVGFEColorMatrixElement.idl:
2421         * svg/SVGFEComponentTransferElement.idl:
2422         * svg/SVGFECompositeElement.idl:
2423         * svg/SVGFEConvolveMatrixElement.idl:
2424         * svg/SVGFEDiffuseLightingElement.idl:
2425         * svg/SVGFEDisplacementMapElement.idl:
2426         * svg/SVGFEDropShadowElement.idl:
2427         * svg/SVGFEFloodElement.idl:
2428         * svg/SVGFEGaussianBlurElement.idl:
2429         * svg/SVGFEImageElement.idl:
2430         * svg/SVGFEMergeElement.idl:
2431         * svg/SVGFEMorphologyElement.idl:
2432         * svg/SVGFEOffsetElement.idl:
2433         * svg/SVGFESpecularLightingElement.idl:
2434         * svg/SVGFETileElement.idl:
2435         * svg/SVGFETurbulenceElement.idl:
2436         * svg/SVGFilterElement.idl:
2437         * svg/SVGFilterPrimitiveStandardAttributes.idl:
2438         * svg/SVGForeignObjectElement.idl:
2439         * svg/SVGGElement.idl:
2440         * svg/SVGGlyphRefElement.idl:
2441         * svg/SVGGradientElement.idl:
2442         * svg/SVGImageElement.idl:
2443         * svg/SVGLineElement.idl:
2444         * svg/SVGMarkerElement.idl:
2445         * svg/SVGMaskElement.idl:
2446         * svg/SVGMissingGlyphElement.idl:
2447         * svg/SVGPathElement.idl:
2448         * svg/SVGPatternElement.idl:
2449         * svg/SVGPolygonElement.idl:
2450         * svg/SVGPolylineElement.idl:
2451         * svg/SVGRectElement.idl:
2452         * svg/SVGSVGElement.idl:
2453         * svg/SVGStopElement.idl:
2454         * svg/SVGStylable.cpp: Removed.
2455         * svg/SVGStylable.h: Removed.
2456         * svg/SVGStylable.idl: Removed.
2457         * svg/SVGStyledElement.h:
2458         (WebCore):
2459         * svg/SVGStyledElement.idl: Added.
2460         * svg/SVGSwitchElement.idl:
2461         * svg/SVGSymbolElement.idl:
2462         * svg/SVGTextContentElement.idl:
2463         * svg/SVGTitleElement.idl:
2464         * svg/SVGUseElement.idl:
2465
2466 2013-01-19  Tim Horton  <timothy_horton@apple.com>
2467
2468         CanvasRenderingContext2D::drawTextInternal should create a mask buffer compatible with that of the canvas
2469         https://bugs.webkit.org/show_bug.cgi?id=107372
2470
2471         Reviewed by Simon Fraser.
2472
2473         No new tests, just matching acceleration modes.
2474
2475         * html/canvas/CanvasRenderingContext2D.cpp:
2476         (WebCore::CanvasRenderingContext2D::drawTextInternal): Create a buffer with the same acceleration mode as the canvas
2477         instead of forcing the use of an accelerated buffer if we support acceleration; the canvas could be unaccelerated
2478         even if USE(IOSURFACE_CANVAS_BACKING_STORE) is on.
2479
2480 2013-01-19  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
2481
2482         Delegated scrolling: Assertion on attempt to show a CSS sticky element
2483         https://bugs.webkit.org/show_bug.cgi?id=106890
2484
2485         Reviewed by Kenneth Rohde Christiansen.
2486
2487         The problem was that frame view (when delegated scrolling enabled) calculated the positions of sticky elements for
2488         a scroll event before sending scroll request. In case of multiple scroll events that caused assertion as the response
2489         for previous scroll request was received after the expected sticky elements positions had been already updated for the following
2490         scroll request.
2491
2492         No new tests. Covered by existing 'fast/css/sticky' tests.
2493
2494         * page/FrameView.cpp:
2495         (WebCore::FrameView::setFixedVisibleContentRect):
2496         * platform/ScrollView.cpp:
2497         (WebCore::ScrollView::scrollTo):
2498
2499 2013-01-19  Kondapally Kalyan  <kalyan.kondapally@intel.com>
2500
2501         [EFL][WebGL] Regression: WebGL Content is not drawn after resizing the canvas.
2502         https://bugs.webkit.org/show_bug.cgi?id=107366
2503
2504         Reviewed by Kenneth Rohde Christiansen.
2505
2506         Window is shared between GraphicsSurface and its client.
2507         Client doesn't own the Window. This patch ensures that client
2508         doesn't delete the shared Window handle.
2509
2510         Covered by existing WebGL tests.
2511
2512         * platform/graphics/surfaces/glx/GraphicsSurfaceGLX.cpp:
2513         (WebCore::GraphicsSurfacePrivate::clear):
2514
2515 2013-01-18  Antti Koivisto  <antti@apple.com>
2516
2517         Make renderer constructors take Element where possible
2518         https://bugs.webkit.org/show_bug.cgi?id=107138
2519
2520         Reviewed by David Hyatt.
2521         
2522         Tighter typing prevents bugs and enables optimizations.
2523
2524         The patch changes how anonymous rendererer are constructed. Previously Document* as the node parameter
2525         indicated that the renderer was anonymous. This forced the code to operate on ContainerNodes (Document
2526         is not an Element). Now anonymous renderers are constructed by passing null and the document is set by
2527         separate setDocumentForAnonymous() call. The patch uses RenderFoo::createAnonymous() pattern consistently.
2528
2529         Most constructors are switched to take Element. RenderBlock still takes ContainerNode due to a few subclasses
2530         (RenderView and RenderFlowThread) that pass in a Document.
2531
2532         * page/FrameView.cpp:
2533         (WebCore::FrameView::updateScrollCorner):
2534         * rendering/RenderBlock.cpp:
2535         (WebCore::RenderBlock::createAnonymous):
2536         (WebCore::RenderBlock::createReplacementRunIn):
2537         (WebCore::RenderBlock::updateFirstLetterStyle):
2538         (WebCore::RenderBlock::createFirstLetterRenderer):
2539         (WebCore::RenderBlock::createAnonymousWithParentRendererAndDisplay):
2540         (WebCore::RenderBlock::createAnonymousColumnsWithParentRenderer):
2541         (WebCore::RenderBlock::createAnonymousColumnSpanWithParentRenderer):
2542         * rendering/RenderBlock.h:
2543         * rendering/RenderDeprecatedFlexibleBox.cpp:
2544         (WebCore::RenderDeprecatedFlexibleBox::RenderDeprecatedFlexibleBox):
2545         (WebCore::RenderDeprecatedFlexibleBox::createAnonymous):
2546         * rendering/RenderDeprecatedFlexibleBox.h:
2547         (RenderDeprecatedFlexibleBox):
2548         * rendering/RenderDetailsMarker.cpp:
2549         (WebCore::RenderDetailsMarker::RenderDetailsMarker):
2550         * rendering/RenderDetailsMarker.h:
2551         (RenderDetailsMarker):
2552         * rendering/RenderDialog.h:
2553         (WebCore::RenderDialog::RenderDialog):
2554         * rendering/RenderFieldset.cpp:
2555         (WebCore::RenderFieldset::RenderFieldset):
2556         * rendering/RenderFieldset.h:
2557         * rendering/RenderFlexibleBox.cpp:
2558         (WebCore::RenderFlexibleBox::RenderFlexibleBox):
2559         * rendering/RenderFlexibleBox.h:
2560         (RenderFlexibleBox):
2561         * rendering/RenderFlowThread.cpp:
2562         (WebCore::RenderFlowThread::RenderFlowThread):
2563         * rendering/RenderFlowThread.h:
2564         * rendering/RenderFullScreen.cpp:
2565         (RenderFullScreenPlaceholder::RenderFullScreenPlaceholder):
2566         (RenderFullScreen::RenderFullScreen):
2567         (RenderFullScreen::createAnonymous):
2568         (RenderFullScreen::wrapRenderer):
2569         * rendering/RenderFullScreen.h:
2570         (RenderFullScreen):
2571         * rendering/RenderGrid.cpp:
2572         (WebCore::RenderGrid::RenderGrid):
2573         * rendering/RenderGrid.h:
2574         * rendering/RenderImage.cpp:
2575         (WebCore::RenderImage::RenderImage):
2576         (WebCore::RenderImage::createAnonymous):
2577         * rendering/RenderImage.h:
2578         * rendering/RenderInline.cpp:
2579         (WebCore::RenderInline::RenderInline):
2580         (WebCore::RenderInline::createAnonymous):
2581         (WebCore::RenderInline::addChildIgnoringContinuation):
2582         * rendering/RenderInline.h:
2583         (RenderInline):
2584         (WebCore::RenderInline::node):
2585         
2586             Add version with covariant Element return type.
2587
2588         * rendering/RenderLayer.cpp:
2589         (WebCore::RenderLayer::updateScrollCornerStyle):
2590         (WebCore::RenderLayer::updateResizerStyle):
2591         (WebCore::RenderLayer::createReflection):
2592         (WebCore::RenderListItem::RenderListItem):
2593         (WebCore::RenderListItem::styleDidChange):
2594         * rendering/RenderListItem.h:
2595         * rendering/RenderListMarker.cpp:
2596         (WebCore::RenderListMarker::RenderListMarker):
2597         (WebCore::RenderListMarker::createAnonymous):
2598         * rendering/RenderListMarker.h:
2599         * rendering/RenderMediaControlElements.cpp:
2600         (WebCore::RenderMediaVolumeSliderContainer::RenderMediaVolumeSliderContainer):
2601         (WebCore::RenderMediaControlTimeDisplay::RenderMediaControlTimeDisplay):
2602         (WebCore::RenderTextTrackContainerElement::RenderTextTrackContainerElement):
2603         * rendering/RenderMediaControlElements.h:
2604         (RenderMediaVolumeSliderContainer):
2605         (RenderMediaControlTimeDisplay):
2606         (RenderTextTrackContainerElement):
2607         * rendering/RenderMultiColumnBlock.cpp:
2608         (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
2609         (WebCore::RenderMultiColumnBlock::ensureColumnSets):
2610         * rendering/RenderMultiColumnBlock.h:
2611         * rendering/RenderMultiColumnFlowThread.cpp:
2612         (WebCore::RenderMultiColumnFlowThread::RenderMultiColumnFlowThread):
2613         * rendering/RenderMultiColumnFlowThread.h:
2614         (RenderMultiColumnFlowThread):
2615         * rendering/RenderMultiColumnSet.cpp:
2616         (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
2617         (WebCore::RenderMultiColumnSet::createAnonymous):
2618         * rendering/RenderMultiColumnSet.h:
2619         (RenderMultiColumnSet):
2620         * rendering/RenderNamedFlowThread.cpp:
2621         (WebCore::RenderNamedFlowThread::RenderNamedFlowThread):
2622         * rendering/RenderNamedFlowThread.h:
2623         (RenderNamedFlowThread):
2624         * rendering/RenderObject.cpp:
2625         (WebCore::RenderObject::RenderObject):
2626         * rendering/RenderObject.h:
2627         
2628              Passed in null node indicates that the renderer is anonymous. Remove now unnecessary setIsAnonymous() function.
2629
2630         (WebCore::RenderObject::isAnonymous):
2631         (WebCore::RenderObject::setDocumentForAnonymous):
2632         (WebCore::RenderObject::RenderObjectBitfields::RenderObjectBitfields):
2633         * rendering/RenderRegion.cpp:
2634         (WebCore::RenderRegion::RenderRegion):
2635         * rendering/RenderRegion.h:
2636         * rendering/RenderRegionSet.cpp:
2637         (WebCore::RenderRegionSet::RenderRegionSet):
2638         * rendering/RenderRegionSet.h:
2639         * rendering/RenderReplaced.cpp:
2640         (WebCore::RenderReplaced::RenderReplaced):
2641         * rendering/RenderReplaced.h:
2642         * rendering/RenderReplica.cpp:
2643         (WebCore::RenderReplica::RenderReplica):
2644         (WebCore::RenderReplica::createAnonymous):
2645         * rendering/RenderReplica.h:
2646         (RenderReplica):
2647         * rendering/RenderRuby.cpp:
2648         (WebCore::createAnonymousRubyInlineBlock):
2649         (WebCore::RenderRubyAsInline::RenderRubyAsInline):
2650         (WebCore::RenderRubyAsBlock::RenderRubyAsBlock):
2651         * rendering/RenderRuby.h:
2652         (RenderRubyAsInline):
2653         (RenderRubyAsBlock):
2654         * rendering/RenderRubyBase.cpp:
2655         (WebCore::RenderRubyBase::RenderRubyBase):
2656         (WebCore::RenderRubyBase::createAnonymous):
2657         * rendering/RenderRubyBase.h:
2658         (RenderRubyBase):
2659         * rendering/RenderRubyRun.cpp:
2660         (WebCore::RenderRubyRun::RenderRubyRun):
2661         (WebCore::RenderRubyRun::createRubyBase):
2662         (WebCore::RenderRubyRun::staticCreateRubyRun):
2663         * rendering/RenderRubyRun.h:
2664         * rendering/RenderRubyText.cpp:
2665         (WebCore::RenderRubyText::RenderRubyText):
2666         * rendering/RenderRubyText.h:
2667         * rendering/RenderScrollbar.cpp:
2668         (WebCore::RenderScrollbar::updateScrollbarPart):
2669         * rendering/RenderScrollbarPart.cpp:
2670         (WebCore::RenderScrollbarPart::RenderScrollbarPart):
2671         (WebCore::RenderScrollbarPart::createAnonymous):
2672         * rendering/RenderScrollbarPart.h:
2673         (RenderScrollbarPart):
2674         * rendering/RenderSearchField.cpp:
2675         (WebCore::RenderSearchField::RenderSearchField):
2676         * rendering/RenderSearchField.h:
2677         (RenderSearchField):
2678         * rendering/RenderTable.cpp:
2679         (WebCore::RenderTable::RenderTable):
2680         (WebCore::RenderTable::createAnonymousWithParentRenderer):
2681         * rendering/RenderTable.h:
2682         * rendering/RenderTableCaption.cpp:
2683         (WebCore::RenderTableCaption::RenderTableCaption):
2684         * rendering/RenderTableCaption.h:
2685         * rendering/RenderTableCell.cpp:
2686         (WebCore::RenderTableCell::RenderTableCell):
2687         (WebCore::RenderTableCell::createAnonymousWithParentRenderer):
2688         * rendering/RenderTableCell.h:
2689         * rendering/RenderTableCol.cpp:
2690         (WebCore::RenderTableCol::RenderTableCol):
2691         * rendering/RenderTableCol.h:
2692         * rendering/RenderTableRow.cpp:
2693         (WebCore::RenderTableRow::RenderTableRow):
2694         (WebCore::RenderTableRow::createAnonymousWithParentRenderer):
2695         * rendering/RenderTableRow.h:
2696         * rendering/RenderTableSection.cpp:
2697         (WebCore::RenderTableSection::RenderTableSection):
2698         (WebCore::RenderTableSection::createAnonymousWithParentRenderer):
2699         * rendering/RenderTableSection.h:
2700         * rendering/RenderText.cpp:
2701         (WebCore::RenderText::RenderText):
2702         
2703             Pass null and use setDocumentForAnonymous() if a RenderText is created with the Document as renderer
2704             to keep them working. Text renderers should be factored similarly to the rest.
2705
2706         * rendering/RenderTextControl.cpp:
2707         (WebCore::RenderTextControl::RenderTextControl):
2708         * rendering/RenderTextControl.h:
2709         * rendering/RenderTextControlMultiLine.cpp:
2710         (WebCore::RenderTextControlMultiLine::RenderTextControlMultiLine):
2711         * rendering/RenderTextControlMultiLine.h:
2712         (RenderTextControlMultiLine):
2713         * rendering/RenderTextControlSingleLine.cpp:
2714         (WebCore::RenderTextControlSingleLine::RenderTextControlSingleLine):
2715         * rendering/RenderTextControlSingleLine.h:
2716         (RenderTextControlSingleLine):
2717         (WebCore::RenderTextControlInnerBlock::RenderTextControlInnerBlock):
2718         * rendering/RenderTextTrackCue.cpp:
2719         (WebCore::RenderTextTrackCue::RenderTextTrackCue):
2720         * rendering/RenderView.cpp:
2721         (WebCore::RenderView::RenderView):
2722         * rendering/RenderWidget.cpp:
2723         (WebCore::RenderWidget::RenderWidget):
2724         * rendering/RenderWidget.h:
2725         * rendering/mathml/RenderMathMLBlock.cpp:
2726         (WebCore::RenderMathMLBlock::RenderMathMLBlock):
2727         (WebCore::RenderMathMLBlock::createAnonymousMathMLBlock):
2728         * rendering/mathml/RenderMathMLBlock.h:
2729         * rendering/mathml/RenderMathMLFenced.cpp:
2730         (WebCore::RenderMathMLFenced::createMathMLOperator):
2731         * rendering/mathml/RenderMathMLOperator.cpp:
2732         (WebCore::RenderMathMLOperator::RenderMathMLOperator):
2733         (WebCore::RenderMathMLOperator::updateFromElement):
2734         (WebCore::RenderMathMLOperator::createGlyph):
2735         * rendering/mathml/RenderMathMLOperator.h:
2736         * rendering/mathml/RenderMathMLRow.cpp:
2737         (WebCore::RenderMathMLRow::RenderMathMLRow):
2738         (WebCore::RenderMathMLRow::createAnonymousWithParentRenderer):
2739         * rendering/mathml/RenderMathMLRow.h:
2740         * rendering/style/ContentData.cpp:
2741         (WebCore::ImageContentData::createRenderer):
2742         * rendering/svg/RenderSVGBlock.cpp:
2743         (WebCore::RenderSVGBlock::RenderSVGBlock):
2744         * rendering/svg/RenderSVGInline.cpp:
2745         (WebCore::RenderSVGInline::RenderSVGInline):
2746         * rendering/svg/RenderSVGInline.h:
2747         * rendering/svg/RenderSVGTSpan.cpp:
2748         (WebCore::RenderSVGTSpan::RenderSVGTSpan):
2749         * rendering/svg/RenderSVGTSpan.h:
2750         * rendering/svg/RenderSVGTextPath.cpp:
2751         (WebCore::RenderSVGTextPath::RenderSVGTextPath):
2752         * rendering/svg/RenderSVGTextPath.h:
2753
2754 2013-01-19  Zan Dobersek  <zdobersek@igalia.com>
2755
2756         Unreviewed GTK build fix.
2757
2758         Add the build targets introduced in r140231 to the list.
2759
2760         * GNUmakefile.list.am:
2761
2762 2013-01-18  Huang Dongsung  <luxtella@company100.net>
2763
2764         [Mac] Remove unused pageScaleFactor and positionRelativeToBase arguments in GraphicsLayerCA.
2765         https://bugs.webkit.org/show_bug.cgi?id=107357
2766
2767         Reviewed by Ryosuke Niwa.
2768
2769         Several methods in GraphicsLayerCA receive a pageScaleFactor or a
2770         positionRelativeToBase argument but don't use the arguments, so this patch
2771         removes them.
2772
2773         No new tests. This is just a refactoring of the existing code.
2774
2775         * platform/graphics/ca/GraphicsLayerCA.cpp:
2776         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
2777         (WebCore::GraphicsLayerCA::updateGeometry):
2778         (WebCore::GraphicsLayerCA::updateStructuralLayer):
2779         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
2780         (WebCore::GraphicsLayerCA::updateLayerDrawsContent):
2781         (WebCore::GraphicsLayerCA::updateContentsScale):
2782         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
2783         * platform/graphics/ca/GraphicsLayerCA.h:
2784         (GraphicsLayerCA):
2785
2786 2013-01-18  Dimitri Glazkov  <dglazkov@chromium.org>
2787
2788         Move attributeNameMatches from SelectorChecker to its proper place on Attribute.
2789         https://bugs.webkit.org/show_bug.cgi?id=107358
2790
2791         Reviewed by Andreas Kling.
2792
2793         Refactoring, covered by existing tests.
2794
2795         * css/SelectorChecker.cpp:
2796         (WebCore::anyAttributeMatches): Changed to use the new name.
2797         * css/SelectorChecker.h:
2798         (SelectorChecker): Moved attributeNameMatches out of here.
2799         (WebCore::SelectorChecker::checkExactAttribute): Changed to use the new name.
2800         * dom/Attribute.h:
2801         (WebCore::Attribute::matches): Moved attributeNameMatches to here.
2802
2803 2013-01-18  Simon Fraser  <simon.fraser@apple.com>
2804
2805         Fix bug that caused pages with fixed backgrounds to not be fast scrollable
2806         https://bugs.webkit.org/show_bug.cgi?id=107354
2807
2808         Reviewed by Sam Weinig.
2809
2810         Correct the change to RenderObject::styleWillChange() made in r140223. This
2811         condition is checking that we're painting the root background, so it checks if
2812         the renderer is the root, or if it's the body, and the document element's renderer
2813         has no background (which means that the body's background propagates to the root).
2814
2815         * rendering/RenderObject.cpp:
2816         (WebCore::RenderObject::styleWillChange):
2817
2818 2013-01-18  Dima Gorbik  <dgorbik@apple.com>
2819
2820         Remove a TextTrack.h include from the Element.h and move WebVTT related stuff outside the Element
2821         https://bugs.webkit.org/show_bug.cgi?id=107080
2822
2823         Reviewed by Sam Weinig.
2824
2825         WebVTT objects are now subclasses of the Element. This allows us to remove major WebVTT chunks of code from
2826         Element.h and NodeRareData. WebVTTElement is deriving from HTMLElement and not Element to prevent possible
2827         problems that could happen because we reuse qTags that are being used in HTML like <b>, <i> and <u>.
2828
2829         No new tests. This is just a refactoring of the existing code.
2830
2831         * CMakeLists.txt:
2832         * WebCore.gypi:
2833         * WebCore.xcodeproj/project.pbxproj:
2834         * css/SelectorChecker.cpp:
2835         (WebCore::SelectorChecker::checkOne):
2836         * css/StyleResolver.cpp:
2837         (WebCore::StyleResolver::collectMatchingRules):
2838         (WebCore::StyleResolver::canShareStyleWithElement):
2839         * dom/Element.cpp:
2840         * dom/Element.h:
2841         * dom/ElementRareData.h:
2842         (WebCore::ElementRareData::ElementRareData):
2843         * dom/Node.h:
2844         (WebCore::Node::isWebVTTElement):
2845         * html/track/TextTrack.h:
2846         * html/track/TextTrackCue.cpp:
2847         (WebCore::TextTrackCue::copyWebVTTNodeToDOMTree):
2848         (WebCore::TextTrackCue::markFutureAndPastNodes):
2849         * html/track/WebVTTElement.cpp: Added.
2850         (WebCore::WebVTTElement::create):
2851         (WebCore::WebVTTElement::cloneElementWithoutAttributesAndChildren):
2852         * html/track/WebVTTElement.h: Added.
2853         (WebCore::WebVTTElement::setWebVTTNodeType):
2854         (WebCore::WebVTTElement::webVTTNodeType):
2855         (WebCore::WebVTTElement::WebVTTElement):
2856         (WebCore::toWebVTTElement):
2857         * html/track/WebVTTParser.cpp:
2858         (WebCore::WebVTTParser::constructTreeFromToken):
2859
2860 2013-01-18  Beth Dakin  <bdakin@apple.com>
2861
2862         https://bugs.webkit.org/show_bug.cgi?id=106946
2863         Sticky-position elements can jump around/hide on rubber-banding
2864
2865         Reviewed by Simon Fraser.
2866
2867         This patch adds a new function called viewportConstrainedVisibleContentRect() 
2868         since there are a number of places where we need a visibleContectRect() that does 
2869         not allow scroll offsets that indicate the rubber-banding that is happening. And 
2870         this patch fixes the bug for sticky by calling this function in two new places.
2871
2872         * page/FrameView.cpp:
2873         (WebCore::FrameView::viewportConstrainedVisibleContentRect):
2874         (WebCore):
2875         * page/FrameView.h:
2876         (FrameView):
2877         * page/scrolling/ScrollingCoordinator.cpp:
2878         (WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):
2879         * rendering/RenderBoxModelObject.cpp:
2880         (WebCore::RenderBoxModelObject::stickyPositionOffset):
2881         * rendering/RenderLayerCompositor.cpp:
2882         (WebCore::RenderLayerCompositor::computeFixedViewportConstraints):
2883         (WebCore::RenderLayerCompositor::computeStickyViewportConstraints):
2884
2885 2013-01-18  Sheriff Bot  <webkit.review.bot@gmail.com>
2886
2887         Unreviewed, rolling out r140206.
2888         http://trac.webkit.org/changeset/140206
2889         https://bugs.webkit.org/show_bug.cgi?id=107346
2890
2891         Caused crash on wordpress.com (Requested by smfr on #webkit).
2892
2893         * rendering/RenderBox.cpp:
2894         (WebCore::RenderBox::removeFloatingOrPositionedChildFromBlockLists):
2895
2896 2013-01-18  Simon Fraser  <simon.fraser@apple.com>
2897
2898         Allow fixed background layers to be moved by the ScrollingCoordinator
2899         https://bugs.webkit.org/show_bug.cgi?id=107213
2900
2901         Reviewed by Tim Horton.
2902         
2903         Start using the RenderView's RenderLayerBacking's background layer for
2904         fixed root backgrounds (those which have background images all of which have
2905         background-attachment: fixed).
2906         
2907         The background-layer is contained in the RenderLayer's RenderLayerBacking's
2908         containment view, so it gets page scale applied to it, but scrolling happens
2909         above this layer, so the background has to be counter-scrolled. We plumb
2910         this layer through to the ScrollingCoordinator so that this counter-scrolling
2911         can be done on the scrolling thread.
2912         
2913         Test: platform/mac/tiled-drawing/fixed-background/fixed-body-background-positioned.html
2914
2915         * WebCore.xcodeproj/project.pbxproj: Add ScrollingStateScrollingNodeMac.mm
2916         * page/scrolling/ScrollingCoordinator.cpp:
2917         (WebCore::ScrollingCoordinator::counterScrollingLayerForFrameView): New function to get
2918         the counter-scrolling layer.
2919         (WebCore::ScrollingCoordinator::updateMainFrameScrollPosition): Sync or set the position of the
2920         counter-scrolling layer just like we do for the main scrolling layer.
2921         * page/scrolling/ScrollingCoordinator.h:
2922         (WebCore::ScrollingCoordinator::updateScrollingNode):
2923         * page/scrolling/ScrollingStateNode.cpp:
2924         (WebCore::ScrollingStateNode::ScrollingStateNode): setScrollLayer() renamed to setScrollPlatformLayer(),
2925         and added a FIXME comment because this code is confusing and possibly wrong.
2926         * page/scrolling/ScrollingStateNode.h: Renamed setScrollLayer() to setScrollPlatformLayer().
2927         * page/scrolling/ScrollingStateScrollingNode.cpp:
2928         (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
2929         * page/scrolling/ScrollingStateScrollingNode.h:
2930         (ScrollingStateScrollingNode): Track the counter-scrolling layer.
2931         (WebCore::ScrollingStateScrollingNode::counterScrollingLayer):
2932         (WebCore::ScrollingStateScrollingNode::counterScrollingLayerDidChange):
2933         (WebCore::ScrollingStateScrollingNode::setCounterScrollingLayerDidChange):
2934         * page/scrolling/mac/ScrollingCoordinatorMac.h:
2935         (ScrollingCoordinatorMac): Add updateScrollingNode() which is less expensive than frameViewRootLayerDidChange()
2936         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
2937         (WebCore::ScrollingCoordinatorMac::frameViewRootLayerDidChange): Fetch the counter-scrolling layer if we have one.
2938         (WebCore::ScrollingCoordinatorMac::setCounterScrollingLayerForNode):
2939         (WebCore::ScrollingCoordinatorMac::updateScrollingNode):
2940         * page/scrolling/mac/ScrollingStateNodeMac.mm:
2941         (WebCore::ScrollingStateNode::setScrollPlatformLayer):
2942         * page/scrolling/mac/ScrollingStateScrollingNodeMac.mm: New file for implementation of setCounterScrollingLayer().
2943         (WebCore::ScrollingStateScrollingNode::counterScrollingPlatformLayer):
2944         (WebCore::ScrollingStateScrollingNode::setCounterScrollingLayer):
2945         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h:
2946         (ScrollingTreeScrollingNodeMac):
2947         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
2948         (WebCore::ScrollingTreeScrollingNodeMac::update):
2949         (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
2950         * rendering/RenderBoxModelObject.cpp:
2951         (WebCore::RenderBoxModelObject::fixedBackgroundPaintsInLocalCoordinates):
2952         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry): If we're painting into the fixed root layer,
2953         we want to always paint with the top,left at 0,0.
2954         * rendering/RenderBoxModelObject.h:
2955         * rendering/RenderLayerBacking.cpp:
2956         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry): In the fixed root background case,
2957         we can make the background layer viewport-sized, and we have to set its counter-scrolled position.
2958         (WebCore::RenderLayerBacking::updateBackgroundLayer): If the background layer was created or destroyed,
2959         we have to tell the ScrollingCoordinator.
2960         (WebCore::RenderLayerBacking::didCommitChangesForLayer): Send the GraphicsLayer down.
2961         * rendering/RenderLayerCompositor.cpp:
2962         (WebCore::RenderLayerCompositor::didFlushChangesForLayer): If the background layer changed (e.g. it became
2963         tiled) we need to tell the ScrollingCoordinator.
2964         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree): We failed to update the borders on new
2965         layers sometimes; this fixes that.
2966         (WebCore::RenderLayerCompositor::frameViewDidScroll): In the non-threaded scrolling case, if we have
2967         a fixed background layer, we need to update its position.
2968         (WebCore::RenderLayerCompositor::fixedRootBackgroundLayerChanged): Feed the newly created/destroyed layer
2969         down to the ScrollingCoordinator.
2970         (WebCore::RenderLayerCompositor::supportsFixedRootBackgroundCompositing):
2971         (WebCore::RenderLayerCompositor::needsFixedRootBackgroundLayer):
2972         * rendering/RenderLayerCompositor.h:
2973         * rendering/RenderObject.cpp:
2974         (WebCore::rendererHasBackground):
2975         (WebCore::RenderObject::styleWillChange): If the compositor supports fixed root backgrounds, we no longer
2976         treat these as slow repaint objects.
2977         * rendering/RenderView.cpp:
2978         (WebCore::RenderView::rootBackgroundIsEntirelyFixed): Helper function called by RLC.
2979         * rendering/RenderView.h:
2980
2981 2013-01-18  Alec Flett  <alecflett@chromium.org>
2982
2983         IndexedDB: Switch to new createTransaction call
2984         https://bugs.webkit.org/show_bug.cgi?id=107311
2985
2986         Reviewed by Tony Chang.
2987
2988         Convert frontend callers to use the new backend createTransaction
2989         call which is the final divorce between the frontend and backend
2990         transaction objects. This allows an asynchronous call in Chromium
2991         and allows the front and backend to have their own lifecycle,
2992         allowing the backend to be cleaned up as soon as a transaction is complete,
2993         rather than waiting for the JS object to get cleaned up.
2994
2995         No new tests, this is a refactor covered by existing tests.
2996
2997         * Modules/indexeddb/IDBDatabase.cpp:
2998         (WebCore::IDBDatabase::transaction):
2999         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
3000         (WebCore::IDBDatabaseBackendImpl::commit):
3001         (WebCore::IDBDatabaseBackendImpl::abort):
3002         (WebCore::IDBDatabaseBackendImpl::createTransaction):
3003         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
3004         * Modules/indexeddb/IDBDatabaseCallbacksImpl.cpp:
3005         (WebCore::IDBDatabaseCallbacksImpl::onAbort):
3006         (WebCore::IDBDatabaseCallbacksImpl::onComplete):
3007         * Modules/indexeddb/IDBOpenDBRequest.cpp:
3008         (WebCore::IDBOpenDBRequest::onUpgradeNeeded):
3009         * Modules/indexeddb/IDBTransaction.cpp:
3010         (WebCore::IDBTransaction::create):
3011         (WebCore::IDBTransaction::IDBTransaction):
3012         (WebCore::IDBTransaction::setActive):
3013         (WebCore::IDBTransaction::abort):
3014         * Modules/indexeddb/IDBTransaction.h:
3015         (WebCore):
3016         (IDBTransaction):
3017         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
3018         (WebCore::IDBTransactionBackendImpl::create):
3019         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
3020         (WebCore::IDBTransactionBackendImpl::abort):
3021         (WebCore::IDBTransactionBackendImpl::commit):
3022         * Modules/indexeddb/IDBTransactionBackendImpl.h:
3023         (IDBTransactionBackendImpl):
3024         (WebCore::IDBTransactionBackendImpl::setCallbacks):
3025
3026 2013-01-18  Brady Eidson  <beidson@apple.com>
3027
3028         Rework NetworkProcess resource load identifiers.
3029         <rdar://problem/12934449> and https://bugs.webkit.org/show_bug.cgi?id=107192
3030
3031         Reviewed by Alexey Proskuryakov.
3032
3033         No new tests (No effect in tested configs).
3034
3035         * WebCore.exp.in:
3036
3037         Include an identifier argument for synchronous loads:
3038         * loader/LoaderStrategy.cpp:
3039         (WebCore::LoaderStrategy::loadResourceSynchronously):
3040         * loader/LoaderStrategy.h:
3041
3042         Pass along a unique identifier to the synchronous load:
3043         * loader/FrameLoader.cpp:
3044         (WebCore::FrameLoader::loadResourceSynchronously):
3045
3046         Remove the "setIdentifier" method:
3047         * loader/ResourceLoader.cpp:
3048         * loader/ResourceLoader.h:
3049
3050 2013-01-18  Shinya Kawanaka  <shinyak@chromium.org>
3051
3052         Introduce isHTMLTextFormControlElement and toHTMLTextFormControlElement instead of toTextFormControl
3053         https://bugs.webkit.org/show_bug.cgi?id=107089
3054
3055         Reviewed by Kent Tamura.
3056
3057         toTextFormControl(node) returns 0 if node is not HTMLTextFormControl. In recent coding convention,
3058         we only have ASSERT and statc_cast in this kind of conversion function. So this code looks like
3059         having a bad cast, though it does not.
3060
3061         In this patch, we convert toTextFromControl to isHTMLTextFormControlElement and toHTMLFormControlElement,
3062         which aligns our coding convention.
3063
3064         No new tests, simple refactoring.
3065
3066         * editing/Editor.cpp:
3067         (WebCore::Editor::selectionForCommand):
3068         (WebCore::Editor::setBaseWritingDirection):
3069         * html/HTMLElement.cpp:
3070         (WebCore::HTMLElement::directionality):
3071         * html/HTMLTextFormControlElement.cpp:
3072         (WebCore::enclosingTextFormControl):
3073         * html/HTMLTextFormControlElement.h:
3074         (WebCore::isHTMLTextFormControlElement):
3075         (WebCore):
3076         (WebCore::toHTMLTextFormControlElement):
3077         * rendering/RenderTextControl.cpp:
3078         (WebCore::RenderTextControl::RenderTextControl):
3079         (WebCore::RenderTextControl::layoutSpecialExcludedChild):
3080         * testing/Internals.cpp:
3081         (WebCore::Internals::visiblePlaceholder):
3082
3083 2013-01-18  Emil A Eklund  <eae@chromium.org>
3084
3085         Change RenderStyle::getRoundedInnerBorderFor to take ints for border widths
3086         https://bugs.webkit.org/show_bug.cgi?id=107331
3087
3088         Reviewed by Levi Weintraub.
3089         
3090         Borders are always represented as ints yet RenderStyle::
3091         getRoundedInnerBorderFor upcasts from int to LayoutUnit when
3092         calling getRoundedInnerBorderFor.
3093
3094         No new tests, no change in functionality.
3095
3096         * rendering/style/RenderStyle.cpp:
3097         (WebCore::RenderStyle::getRoundedInnerBorderFor):
3098         * rendering/style/RenderStyle.h:
3099         Change getRoundedInnerBorderFor to use ints for border widths.
3100
3101 2013-01-18  Adam Barth  <abarth@webkit.org>
3102
3103         BackgroundHTMLParser shouldn't create AtomicStrings
3104         https://bugs.webkit.org/show_bug.cgi?id=107150
3105
3106         Reviewed by Tony Gentilcore.
3107
3108         Previously, we were creating an AtomicString from the HTMLToken for
3109         every start and end tag. This caused us to have a static dependency on
3110         the parser thread's atomic string table. We want to avoid static
3111         dependencies because we want to eventually run the background parser
3112         using a library like libdispatch that will let us run many version in
3113         parallel.
3114
3115         This patch uses a different approach whereby we use the tag name from
3116         the CompactHTMLToken. In order to avoid calling strcmp excessively, we
3117         use StringImpl::hash to quickly reject matches with some common tag
3118         names. As a side effect, the hash value will be cached in the
3119         StringImpl, speeding up atomization once these StringImpls arrive on
3120         the main thread.
3121
3122         This patch also improves the performance on html-parser-srcdoc.html.
3123         With the patch in bug 107236 applied (which focuses the benchmark more
3124         tightly on the parser), we spend 2.3% less time on the main thread
3125         (likely due to pre-caching the hash values) and 11.5% less time on the
3126         parser thread.
3127
3128         * html/parser/BackgroundHTMLParser.cpp:
3129         (WebCore):
3130         (WebCore::threadSafeEqual):
3131         (WebCore::threadSafeMatch):
3132         (WebCore::BackgroundHTMLParser::pumpTokenizer):
3133
3134 2013-01-18  Tony Gentilcore  <tonyg@chromium.org>
3135
3136         Run defer scripts in the threaded HTML parser
3137         https://bugs.webkit.org/show_bug.cgi?id=107320
3138
3139         Reviewed by Eric Seidel.
3140
3141         No new tests because covered by http/tests/misc/script-defer.html.
3142
3143         * html/parser/HTMLDocumentParser.cpp:
3144         (WebCore::HTMLDocumentParser::prepareToStopParsing):
3145         (WebCore::HTMLDocumentParser::didReceiveTokensFromBackgroundParser):
3146
3147 2013-01-18  Robert Hogan  <robert@webkit.org>
3148
3149         fast/inline/fixed-pos-moves-with-abspos-parent-relative-ancestor.html is crashing after r140024
3150         https://bugs.webkit.org/show_bug.cgi?id=107209
3151
3152         Reviewed by David Hyatt.
3153
3154         * rendering/RenderBlock.cpp:
3155         (WebCore::RenderBlock::layoutPositionedObjects): r140024 forgot to layout the fixedpos object after
3156         marking it.
3157
3158 2013-01-18  Abhishek Arya  <inferno@chromium.org>
3159
3160         Heap-use-after-free in WebCore::RenderObject::isDescendantOf
3161         https://bugs.webkit.org/show_bug.cgi?id=107226
3162
3163         Reviewed by David Hyatt.
3164
3165         Test: fast/block/float/overhanging-float-not-removed-crash.html
3166
3167         * rendering/RenderBox.cpp:
3168         (WebCore::RenderBox::removeFloatingOrPositionedChildFromBlockLists):
3169         Skip anonymous blocks in the chain to get the enclosing block and
3170         be able to correctly mark the overhanging floats in the next siblings.
3171
3172 2013-01-18  Chris Hopman  <cjhopman@google.com>
3173
3174         Fix scrollRectToVisible in the presence of transforms
3175         https://bugs.webkit.org/show_bug.cgi?id=105574
3176
3177         Reviewed by Simon Fraser.
3178
3179         When scrolling to reveal an overflow layer, the required scroll was
3180         being calculated in absolute coordinates. To properly account for
3181         transforms, this calculation should be done in the local coordinates
3182         of the renderBox.
3183
3184         Tests: editing/input/reveal-selection-transformed-overflow-parent.html
3185                editing/input/reveal-selection-transformed-textarea.html
3186
3187         * rendering/RenderLayer.cpp:
3188         (WebCore::RenderLayer::scrollRectToVisible):
3189         When scrolling to reveal an overflow layer, calculate the required
3190         scroll in the local coordinates of the RenderBox.
3191         * rendering/RenderObject.cpp:
3192         (WebCore::RenderObject::absoluteToLocalQuad):
3193         (WebCore):
3194         * rendering/RenderObject.h:
3195         (RenderObject):
3196         Add function to convert an absolute quad to a local quad.
3197
3198 2013-01-18  Julien Chaffraix  <jchaffraix@webkit.org>
3199
3200         [CSS Grid Layout] Add support for min-content
3201         https://bugs.webkit.org/show_bug.cgi?id=106474
3202
3203         Reviewed by Ojan Vafai.
3204
3205         Tests: fast/css-grid-layout/minmax-min-content-column-resolution-columns.html
3206                fast/css-grid-layout/minmax-min-content-column-resolution-rows.html
3207
3208         This change adds support to properly size min-content as long as the grid items and the grid element
3209         don't have orthogonal writing-modes. Orthogonal writing modes will be handled in a follow-up bug
3210         to keep the patch small-ish.
3211
3212         This change implements a subset of the specification's algorithm, taking some shortcuts where the
3213         extra complexity wasn't a clear win for now: e.g. the specification relies on behavior customization
3214         through functors to share code among more complex cases - like spanning columns / rows. These shortcuts
3215         have been marked as FIXME / comments in the code so that they can be evaluated and fixed as we implement
3216         more of the complexity.
3217
3218         * platform/Length.h:
3219         (WebCore::Length::isMinContent):
3220         (WebCore::Length::isMaxContent):
3221         Helper functions.
3222
3223         * rendering/RenderGrid.cpp:
3224         (WebCore::GridTrack::maxBreadthIfNotInfinite):
3225         Helper function that returns the max breadth if finite and the used breadth otherwise.
3226
3227         (WebCore::RenderGrid::computedUsedBreadthOfGridTracks):
3228         Updated to call resolveContentBasedTrackSizingFunctions.
3229
3230         (WebCore::RenderGrid::computeUsedBreadthOfMinLength):
3231         (WebCore::RenderGrid::computeUsedBreadthOfMaxLength):
3232         (WebCore::RenderGrid::computeUsedBreadthOfSpecifiedLength):
3233         Split computeUsedBreadthOfLength into min and max side so that we can return the default values accordingly.
3234         computeUsedBreadthOfSpecifiedLength shares the common code. Also made these functions 'const'.
3235
3236         (WebCore::RenderGrid::minContentForChild):
3237         This function returns the 'min-content' value based on layout / compute preferred logical widths information.
3238
3239         (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctions):
3240         This is the core function that implements the sizing. It currently doesn't share much code between the branches,
3241         which will be done as we implement more of the algorithm.
3242
3243         (WebCore::RenderGrid::distributeSpaceToTracks):
3244         Clamped the growthShare to positive value only. This is required to handle cases where min-content is bigger
3245         than max track breadth. Added a comment about this deviation from the specification.
3246
3247         (WebCore::RenderGrid::tracksAreWiderThanMinTrackBreadth):
3248         Debug only method. It is a sanity check as our algorithm should *never* shrink the used breadth to a value
3249         smaller than the computed min track breadth.
3250
3251         (WebCore::RenderGrid::layoutGridItems):
3252         Added 2 ASSERT using tracksAreWiderThanMinTrackBreadth.
3253
3254         (WebCore::RenderGrid::resolveGridPosition):
3255         Helper overriden instance.
3256         * rendering/RenderGrid.h:
3257         Added the new functions. Also made more core functions take both grid tracks.
3258
3259 2013-01-18  Geoffrey Garen  <ggaren@apple.com>
3260
3261         Weak GC maps should be easier to use
3262         https://bugs.webkit.org/show_bug.cgi?id=107312
3263
3264         Reviewed by Sam Weinig.
3265
3266         Since weak GC maps are so easy to use now, let's use them for the DOM
3267         string cache.
3268
3269         * WebCore.exp.in:
3270         * bindings/js/DOMWrapperWorld.cpp:
3271         (WebCore):
3272         (WebCore::DOMWrapperWorld::DOMWrapperWorld):
3273         * bindings/js/DOMWrapperWorld.h:
3274         (WebCore):
3275         (WebCore::DOMWrapperWorld::globalData):
3276         (DOMWrapperWorld):
3277         * bindings/js/JSDOMBinding.cpp:
3278         (WebCore):
3279         * bindings/js/JSDOMBinding.h:
3280         (WebCore):
3281         (WebCore::jsStringWithCache):
3282
3283 2013-01-18  Tim Volodine  <timvolodine@chromium.org>
3284
3285         Text Autosizing: don't autosize headers with multiple inline links.
3286         https://bugs.webkit.org/show_bug.cgi?id=106792
3287
3288         Reviewed by Kenneth Rohde Christiansen.
3289
3290         This patch includes code for detecting rows of links typically seen
3291         in headers or footers of webpages. Such rows of links should not be
3292         autosized.
3293
3294         The heuristics to detect such rows of links are based on the appearance
3295         of headers in most websites: i.e. links are inline, there are at least three
3296         of them, they should have the same font size with possibly only short textual
3297         separators between them (max 3 characters) and there should be no line breaks
3298         (i.e. <br> elements) between them.
3299
3300         Tests: fast/text-autosizing/header-li-links-autosizing.html
3301                fast/text-autosizing/header-links-autosizing-different-fontsize.html
3302                fast/text-autosizing/header-links-autosizing.html
3303
3304         * rendering/TextAutosizer.cpp:
3305         (WebCore::TextAutosizer::containerShouldBeAutosized):
3306         (WebCore::TextAutosizer::containerIsRowOfLinks):
3307         (WebCore):
3308         * rendering/TextAutosizer.h:
3309
3310 2013-01-18  Levi Weintraub  <leviw@chromium.org>
3311
3312         LayoutUnit should round half consistently, not away from zero
3313         https://bugs.webkit.org/show_bug.cgi?id=107208
3314
3315         Reviewed by Eric Seidel.
3316
3317         The current implementation of LayoutUnit::round() always rounds half away from zero. This can result in
3318         a shift of 1 pixel moving an element aligned at a half-pixel by 2. This problem is particularly common with
3319         RenderLayers, which pass the sub-pixel accumulation into their renderers after translating the graphics
3320         context passed in by their rounded location. This changes round() to always round 0.5 up.
3321
3322         Test: fast/sub-pixel/sub-pixel-root-layer.html
3323
3324         * platform/LayoutUnit.h:
3325         (WebCore::LayoutUnit::round): Always round 0.5 up.
3326         * rendering/RenderLayer.cpp:
3327         (WebCore::RenderLayer::paintLayerContents): We no longer need to prevent rootLayers from passing in a
3328         sub-pixel offset. This eliminates the shifting of elements when applying translateZ(0) or similar.
3329
3330 2013-01-18  Kentaro Hara  <haraken@chromium.org>
3331
3332         [V8] Remove custom V8ScriptProfileNodeCustom::toV8()
3333         https://bugs.webkit.org/show_bug.cgi?id=107245
3334
3335         Reviewed by Adam Barth.
3336
3337         V8ScriptProfileNodeCustom::toV8() needs not to be custom.
3338         Furthermore, the current custom toV8() is wrong in that
3339         it doesn't use a creationContext and it doesn't set a wrapper
3340         class id. This is one of steps to avoiding ASSERT()s
3341         that will be added in https://bugs.webkit.org/show_bug.cgi?id=107137 .
3342
3343         No tests. No change in behavior.
3344
3345         * UseV8.cmake:
3346         * WebCore.gypi:
3347         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp: Removed.
3348         * inspector/ScriptProfileNode.idl:
3349
3350 2013-01-18  Ali Juma  <ajuma@chromium.org>
3351
3352         [chromium] Convert WebTransformOperations into pure virtual
3353         https://bugs.webkit.org/show_bug.cgi?id=105553
3354
3355         Reviewed by James Robinson.
3356
3357         This removes the implementation of WebTransformOperations and updates
3358         users to construct instances using a factory function. This also adds
3359         the implementation of WebTransformKeyFrame.
3360
3361         No new tests, no change in functionality.
3362
3363         * WebCore.gypi:
3364         * platform/chromium/support/WebTransformKeyframe.cpp: Copied from Source/Platform/chromium/public/WebTransformKeyframe.h.
3365         (WebKit):
3366         (WebKit::WebTransformKeyframe::WebTransformKeyframe):
3367         (WebKit::WebTransformKeyframe::~WebTransformKeyframe):
3368         (WebKit::WebTransformKeyframe::time):
3369         (WebKit::WebTransformKeyframe::value):
3370         * platform/chromium/support/WebTransformOperations.cpp: Removed.
3371         * platform/graphics/chromium/AnimationTranslationUtil.cpp:
3372         (WebCore::toWebTransformOperations):
3373         (WebCore::WebTransformAnimationCurve):
3374
3375 2013-01-18  Arko Saha  <arko@motorola.com>
3376
3377         PropertyCollection test fails on JavaScriptCore
3378         https://bugs.webkit.org/show_bug.cgi?id=106997
3379
3380         Reviewed by Kentaro Hara.
3381
3382         Made changes in CodeGeneratorJS.pm so that it can use
3383         toJS(JSC::ExecState*, JSDOMGlobalObject*, PropertyNodeList*)
3384         to wrap the object and return PropertyNodeList instead of NodeList.
3385
3386         Test: fast/dom/MicroData/propertiescollection-crash.html
3387               fast/dom/MicroData/properties-collection-namedgetter-with-invalid-name.html
3388
3389         * bindings/scripts/CodeGeneratorJS.pm:
3390         (GenerateImplementation):
3391
3392 2013-01-18  Dominic Mazzoni  <dmazzoni@google.com>
3393
3394         AX: Improve table-guessing heuristics
3395         https://bugs.webkit.org/show_bug.cgi?id=107042
3396
3397         Reviewed by Chris Fleizach.
3398
3399         Adds some more rules so that tables with cell borders, empty-cells,
3400         col, colgroup, or >= 20 rows are all considered data tables, not
3401         layout tables.
3402
3403         Test: accessibility/table-detection.html (modified)
3404
3405         * accessibility/AccessibilityTable.cpp:
3406         (WebCore::AccessibilityTable::isDataTable):
3407
3408 2013-01-18  Terry Anderson  <tdanderson@chromium.org>
3409
3410         Scroll gestures should not create wheel events
3411         https://bugs.webkit.org/show_bug.cgi?id=103952
3412
3413         Reviewed by James Robinson.
3414
3415         Tests: fast/events/touch/gesture/touch-gesture-scroll-div-propagated.html
3416                fast/events/touch/gesture/touch-gesture-scroll-div-twice-propagated.html
3417                fast/events/touch/gesture/touch-gesture-scroll-iframe-editable.html
3418                fast/events/touch/gesture/touch-gesture-scroll-iframe-propagated.html
3419                fast/events/touch/gesture/touch-gesture-scroll-page-propagated.html
3420
3421         In EventHandler::handleGestureEvent(), scroll gestures should not be handled by synthesizing
3422         and dispatching wheel events; we should instead scroll the relevant layer directly.
3423
3424         Note that this patch should be landed together with the patch for
3425         https://bugs.webkit.org/show_bug.cgi?id=106589.
3426
3427         * page/EventHandler.cpp:
3428         (WebCore::EventHandler::EventHandler):
3429         (WebCore::EventHandler::clear):
3430         (WebCore::EventHandler::handleGestureEvent):
3431         (WebCore::EventHandler::passGestureEventToWidget):
3432         (WebCore::EventHandler::passGestureEventToWidgetIfPossible):
3433         (WebCore):
3434         (WebCore::closestScrollableNodeInDocumentIfPossibleOrSelfIfNotScrollable):
3435         (WebCore::EventHandler::handleGestureScrollBegin):
3436         (WebCore::EventHandler::handleGestureScrollUpdate):
3437         (WebCore::EventHandler::isScrollbarHandlingGestures):
3438         * page/EventHandler.h:
3439         (EventHandler):
3440         * rendering/RenderLayer.cpp:
3441         (WebCore::RenderLayer::scrollByRecursively):
3442         * rendering/RenderLayer.h:
3443
3444 2013-01-18  Nate Chapin  <japhet@chromium.org>
3445
3446         Cannot abort multiple XHR POSTs made to same url
3447         https://bugs.webkit.org/show_bug.cgi?id=106937
3448
3449         Reviewed by Alexey Proskuryakov.
3450
3451         Test: http/tests/cache/cancel-multiple-post-xhrs.html
3452
3453         * loader/cache/CachedResource.cpp:
3454         (WebCore::CachedResource::removeClient): Call allClientsRemoved() regardless
3455             of whether this resource is inCache(). Otherwise, CachedRawResources will
3456             not have the opportunity to cancel as expected. However, don't cancel
3457             if the last client was removed because we're in the middle of switching
3458             the clients over to a successfully revalidated resource.
3459
3460 2013-01-18  Dima Gorbik  <dgorbik@apple.com>
3461
3462         Implement ::cue() pseudo element property whitelist
3463         https://bugs.webkit.org/show_bug.cgi?id=105477
3464
3465         Reviewed by Antti Koivisto.
3466
3467         Only allowed by specs properties are applied to WebVTT nodes. We used whitelists before for the region
3468         style rule so this refactors the code a little bit to pass bitfields that contain the information on which 
3469         whitelists should be used.
3470
3471         Test: media/track/track-css-property-whitelist.html
3472
3473         * css/RuleSet.cpp: 
3474         (WebCore::RuleData::RuleData): set a region bit when creating a RuleData.
3475         (WebCore::RuleSet::addRule): set a cue bit when PseudoCue type is set for a selector.
3476         * css/RuleSet.h: add the new bitfield as an ivar and setters/getters to access it.
3477         (WebCore::RuleData::isInRegionRule):
3478         (WebCore::RuleData::whitelistType):
3479         (WebCore::RuleData::isInCueRule):
3480         (WebCore::RuleData::setIsInCueRule):
3481         * css/StyleResolver.cpp: refactor the code to pass a bitfield instead of single bits.
3482         (WebCore::StyleResolver::addMatchedProperties):
3483         (WebCore::StyleResolver::sortAndTransferMatchedRules):
3484         (WebCore::StyleResolver::applyProperties):
3485         (WebCore::StyleResolver::applyMatchedProperties):
3486         (WebCore::StyleResolver::isValidCueStyleProperty): 
3487         * css/StyleResolver.h:
3488
3489 2013-01-18  Tony Chang  <tony@chromium.org>
3490
3491         Incorrect scrollable height during simplified layout
3492         https://bugs.webkit.org/show_bug.cgi?id=107193
3493
3494         Reviewed by Ojan Vafai.
3495
3496         Test: fast/overflow/height-during-simplified-layout.html
3497
3498         When computing overflow, we use the height of the block before it was clamped
3499         (i.e., before updateLogicalHeight() has been called).
3500
3501         During simplfied layout, we use the previous sizes rather than doing a full
3502         layout. We still compute overflow, but we were using the clamped height rather
3503         than the full height.
3504
3505         This caused us to incorrectly compute the overflow by the vertical padding.
3506         Since we were passing in the already clamped clientHeight to RenderBlock::computeOverflow,
3507         we would only include the overflow from our children sizes and not include the overflow
3508         from ourselves caused by padding + content.
3509
3510         * rendering/RenderBlock.cpp:
3511         (WebCore::RenderBlock::simplifiedLayout): Use the scrollable height rather than the
3512         already clamped height.
3513
3514 2013-01-18  Joe Mason  <jmason@rim.com>
3515
3516         [BlackBerry] fix compile warnings in NetworkJob
3517         https://bugs.webkit.org/show_bug.cgi?id=107293
3518
3519         Reviewed by Yong Li.
3520
3521         Internal PR: 283096
3522
3523         * platform/network/blackberry/NetworkJob.cpp:
3524         (WebCore):
3525         (WebCore::isAppendableHeader):
3526
3527 2013-01-18  Dominic Mazzoni  <dmazzoni@google.com>
3528
3529         REGRESSION (r132699): Crashes in WebCore::TextIterator::handleTextNodeFirstLetter
3530         https://bugs.webkit.org/show_bug.cgi?id=100688
3531
3532         Reviewed by Martin Robinson.
3533
3534         Prevent crashes when accessibilityObjectIsIgnored calls textUnderElement
3535         while a subtree is being destroyed.
3536
3537         Covered by existing tests.
3538
3539         * accessibility/atk/AccessibilityObjectAtk.cpp:
3540         (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
3541
3542 2013-01-18  Joe Mason  <jmason@rim.com>
3543
3544         [BlackBerry] Only clear credentials when purgeCredentials is called
3545         https://bugs.webkit.org/show_bug.cgi?id=107124
3546
3547         Reviewed by Yong Li.
3548
3549         Stop clearing credentials when sending out a request just in case they're wrong. That's stupid and
3550         has race conditions. Only clear them when we know they're wrong.
3551
3552         Internal PR: 231158
3553         Internal Reviewer: George Staikos
3554
3555         * platform/network/blackberry/NetworkJob.cpp:
3556         (WebCore::NetworkJob::sendRequestWithCredentials):
3557         (WebCore::NetworkJob::purgeCredentials):
3558
3559 2013-01-18  Andrey Adaikin  <aandrey@chromium.org>
3560
3561         Web Inspector: [Canvas] UI: add a context selector to show screenshot of any canvas in the log
3562         https://bugs.webkit.org/show_bug.cgi?id=107274
3563
3564         Reviewed by Pavel Feldman.
3565
3566         Adding a canvas context selector to display in the replay image screenshot.
3567         Drive-by: Reuse common CSS class "status-bar-item" to remove a lot of CSS duplication.
3568
3569         * English.lproj/localizedStrings.js:
3570         * inspector/front-end/CanvasProfileView.js:
3571         (WebInspector.CanvasProfileView):
3572         (WebInspector.CanvasProfileView.prototype._createControlButton):
3573         (WebInspector.CanvasProfileView.prototype._onReplayContextChanged):
3574         (WebInspector.CanvasProfileView.prototype._onReplayFirstStepClick):
3575         (WebInspector.CanvasProfileView.prototype._onReplayLastStepClick):
3576         (WebInspector.CanvasProfileView.prototype._enableWaitIcon):
3577         (WebInspector.CanvasProfileView.prototype._replayTraceLog.didReplayTraceLog):
3578         (WebInspector.CanvasProfileView.prototype._replayTraceLog):
3579         (WebInspector.CanvasProfileView.prototype._didReceiveTraceLog):
3580         (WebInspector.CanvasProfileView.prototype._requestReplayContextInfo.didReceiveResourceInfo):
3581         (WebInspector.CanvasProfileView.prototype._requestReplayContextInfo):
3582         * inspector/front-end/canvasProfiler.css:
3583         * inspector/front-end/inspector.css:
3584         (.status-bar button.status-bar-item img):
3585
3586 2013-01-18  Andrey Adaikin  <aandrey@chromium.org>
3587
3588         Web Inspector: [Canvas] add getResourceInfo and getResourceState methods to the protocol
3589         https://bugs.webkit.org/show_bug.cgi?id=107280
3590
3591         Reviewed by Pavel Feldman.
3592
3593         We need to expose replayable resource info and replay state via the protocol.
3594         The ResourceInfo describes a replayable resource, i.e. the info about a resource that was stored to replay it later.
3595         The ResourceState describes a current state of a resource being replayed on the back-end.
3596
3597         * inspector/CodeGeneratorInspector.py:
3598         * inspector/InjectedScriptCanvasModule.cpp:
3599         (WebCore::InjectedScriptCanvasModule::replayTraceLog):
3600         (WebCore):
3601         (WebCore::InjectedScriptCanvasModule::resourceInfo):
3602         (WebCore::InjectedScriptCanvasModule::resourceState):
3603         * inspector/InjectedScriptCanvasModule.h:
3604         (InjectedScriptCanvasModule):
3605         * inspector/InjectedScriptCanvasModuleSource.js:
3606         (.):
3607         * inspector/Inspector.json:
3608         * inspector/InspectorCanvasAgent.cpp:
3609         (WebCore::InspectorCanvasAgent::replayTraceLog):
3610         (WebCore):
3611         (WebCore::InspectorCanvasAgent::getResourceInfo):
3612         (WebCore::InspectorCanvasAgent::getResourceState):
3613         * inspector/InspectorCanvasAgent.h:
3614         (InspectorCanvasAgent):
3615         * inspector/front-end/CanvasProfileView.js:
3616         (WebInspector.CanvasProfileView.prototype._replayTraceLog.didReplayTraceLog):
3617         (WebInspector.CanvasProfileView.prototype._replayTraceLog):
3618
3619 2013-01-18  Sergio Villar Senin  <svillar@igalia.com>
3620
3621         [Soup] Frequent crashes on redirections
3622         https://bugs.webkit.org/show_bug.cgi?id=107240
3623
3624         Reviewed by Martin Robinson.
3625
3626         We must ensure that the ResourceHandle has not being cancelled
3627         before performing a redirect. This could happen while we close the
3628         stream used to read the redirect response because it is done
3629         asynchronously.
3630
3631         * platform/network/soup/ResourceHandleSoup.cpp:
3632         (WebCore::redirectCloseCallback): also renamed res to result.
3633
3634 2013-01-18  Andrey Adaikin  <aandrey@chromium.org>
3635
3636         Web Inspector: array grouping does not work big sparse arrays
3637         https://bugs.webkit.org/show_bug.cgi?id=106897
3638
3639         Reviewed by Pavel Feldman.
3640
3641         Now we will choose between array index iteration and object properties iteration for sparse arrays.
3642
3643         * inspector/front-end/ObjectPropertiesSection.js:
3644         (.doLoop):
3645         (.countIterationCallback):
3646         (.loopIterationCallback):
3647
3648 2013-01-18  Kondapally Kalyan  <kalyan.kondapally@intel.com>
3649
3650         [EFL][WebGL] Fix Memory leaks in EGL and GLX surface.
3651         https://bugs.webkit.org/show_bug.cgi?id=107100
3652
3653         Reviewed by Laszlo Gombos.
3654
3655         GLX and EGL surface don't release GL resources created by them.
3656         This patch ensures that the leaks are fixed and
3657         native display is not closed before releasing the current
3658         context and surface.
3659
3660         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
3661         (GraphicsContext3DPrivate::releaseResources):
3662         * platform/graphics/surfaces/egl/EGLSurface.cpp:
3663         (WebCore::EGLWindowTransportSurface::destroy): Call base class to free any allocated GL resources.
3664         * platform/graphics/surfaces/glx/GLXContext.cpp:
3665         (WebCore::GLXOffScreenContext::platformReleaseCurrent):
3666         (WebCore::GLXOffScreenContext::freeResources): Don't reset the display to null.
3667         * platform/graphics/surfaces/glx/GLXSurface.cpp:
3668         (WebCore::GLXTransportSurface::destroy): Call base class to free any allocated GL resources.
3669         (WebCore::GLXPBuffer::freeResources): Call base class to free any allocated GL resources.
3670
3671 2013-01-18  Andrey Adaikin  <aandrey@chromium.org>
3672
3673         Web Inspector: [Canvas] introduce Resource.toDataURL
3674         https://bugs.webkit.org/show_bug.cgi?id=107019
3675
3676         Reviewed by Pavel Feldman.
3677
3678         Resource.toDataURL will return string data url representation of a resource, if applicable.
3679         For example, for a rendering context resource (2D or WebGL) it will return canvas.toDataURL().
3680
3681         * inspector/InjectedScriptCanvasModuleSource.js:
3682         (.):
3683
3684 2013-01-18  Csaba Osztrogonác  <ossy@webkit.org>
3685
3686         One more unreviewed Windows buildfix after r140097.
3687
3688         * html/HTMLPlugInElement.h: Remove non-existent include.
3689
3690 2013-01-18  Csaba Osztrogonác  <ossy@webkit.org>
3691
3692         Unreviewed Windows buildfix after r140097.
3693
3694         * html/HTMLPlugInElement.h:
3695
3696 2013-01-18  Yury Semikhatsky  <yurys@chromium.org>
3697
3698         Web Inspector: remove dead code from heap profiler front-end
3699         https://bugs.webkit.org/show_bug.cgi?id=107265
3700
3701         Reviewed by Pavel Feldman.
3702
3703         * inspector/front-end/HeapSnapshotView.js: removed unused methods.
3704
3705 2013-01-18  Yury Semikhatsky  <yurys@chromium.org>
3706
3707         Unreviewed. Fix Qt minimal compilation after r140127
3708
3709         * inspector/InspectorInstrumentation.h:
3710         (InspectorInstrumentationCookie):
3711
3712 2013-01-18  Yury Semikhatsky  <yurys@chromium.org>
3713
3714         Web Inspector: make sure InspectorInstrumentationCookie is invalidated if inspected page was destroyed
3715         https://bugs.webkit.org/show_bug.cgi?id=107232
3716
3717         Reviewed by Pavel Feldman.
3718
3719         Made InstrumentingAgents reference counted to make sure it is not deleted while there is
3720         InspectorInstrumentationCookie with reference to it.
3721
3722         Introduced InstrumentingAgents::reset that is called from inspector controller destructor
3723         to double check that references to all deleted agents are cleared.
3724
3725         InspectorInstrumentationCookie turned from std::pair into a custom class so that
3726         we can avoid inclusion of InstrumentingAgents.h into InspectorInstrumentation.h
3727
3728         * inspector/InspectorController.cpp:
3729         (WebCore::InspectorController::InspectorController):
3730         (WebCore::InspectorController::~InspectorController):
3731         * inspector/InspectorController.h:
3732         (InspectorController):
3733         * inspector/InspectorInstrumentation.cpp:
3734         (WebCore):
3735         (WebCore::InspectorInstrumentationCookie::InspectorInstrumentationCookie):
3736         (WebCore::InspectorInstrumentationCookie::operator=):
3737         (WebCore::InspectorInstrumentationCookie::~InspectorInstrumentationCookie):
3738         (WebCore::InspectorInstrumentation::didHandleEventImpl):
3739         (WebCore::InspectorInstrumentation::didFireTimerImpl):
3740         (WebCore::InspectorInstrumentation::didLayoutImpl):
3741         (WebCore::InspectorInstrumentation::didPaintImpl):
3742         (WebCore::InspectorInstrumentation::didRecalculateStyleImpl):
3743         (WebCore::InspectorInstrumentation::didMatchRuleImpl):
3744         (WebCore::InspectorInstrumentation::didProcessRuleImpl):
3745         (WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
3746         (WebCore::InspectorInstrumentation::retrieveTimelineAgent):
3747         * inspector/InspectorInstrumentation.h:
3748         (InspectorInstrumentationCookie):
3749         (WebCore::InspectorInstrumentation::didCallFunction):
3750         (WebCore::InspectorInstrumentation::didDispatchXHRReadyStateChangeEvent):
3751         (WebCore::InspectorInstrumentation::didDispatchEvent):
3752         (WebCore::InspectorInstrumentation::didHandleEvent):
3753         (WebCore::InspectorInstrumentation::didDispatchEventOnWindow):
3754         (WebCore::InspectorInstrumentation::didEvaluateScript):
3755         (WebCore::InspectorInstrumentation::didFireTimer):
3756         (WebCore::InspectorInstrumentation::didLayout):
3757         (WebCore::InspectorInstrumentation::didDispatchXHRLoadEvent):
3758         (WebCore::InspectorInstrumentation::didPaint):
3759         (WebCore::InspectorInstrumentation::didRecalculateStyle):
3760         (WebCore::InspectorInstrumentation::didMatchRule):
3761         (WebCore::InspectorInstrumentation::didProcessRule):
3762         (WebCore::InspectorInstrumentation::didReceiveResourceData):
3763         (WebCore::InspectorInstrumentation::didWriteHTML):
3764         (WebCore::InspectorInstrumentation::didFireAnimationFrame):
3765         * inspector/InstrumentingAgents.cpp:
3766         (WebCore::InstrumentingAgents::InstrumentingAgents):
3767         (WebCore):
3768         (WebCore::InstrumentingAgents::reset):
3769         * inspector/InstrumentingAgents.h:
3770         (WebCore::InstrumentingAgents::create):
3771         (InstrumentingAgents):
3772         * inspector/WorkerInspectorController.cpp:
3773         (WebCore::WorkerInspectorController::WorkerInspectorController):
3774         (WebCore::WorkerInspectorController::~WorkerInspectorController):
3775         * inspector/WorkerInspectorController.h:
3776         (WorkerInspectorController):
3777
3778 2013-01-18  Jussi Kukkonen  <jussi.kukkonen@intel.com>
3779
3780         [CMake] Fix indexeddb module build
3781         https://bugs.webkit.org/show_bug.cgi?id=107247
3782
3783         Reviewed by Kentaro Hara.
3784
3785         Add missing files to WebCore_SOURCES so the indexeddb module
3786         can be built.
3787
3788         * CMakeLists.txt:
3789
3790 2013-01-17  Vsevolod Vlasov  <vsevik@chromium.org>
3791
3792         Web Inspector: Add early version of file system mappings editor to settings.
3793         https://bugs.webkit.org/show_bug.cgi?id=107136
3794
3795         Reviewed by Pavel Feldman.
3796
3797         FileMapping simplified to use only one type of entries.
3798         Added start/stopBatchUpdates to FileSystemWorkspaceProvider for better TabbedPane performance.
3799         Added fileSystemProject experiment for file system support and (early and ugly) file system mappings editor behind this experiment.
3800
3801         * English.lproj/localizedStrings.js:
3802         * WebCore.gypi:
3803         * inspector/front-end/FileMapping.js:
3804         (WebInspector.FileMapping):
3805         (WebInspector.FileMapping.prototype._entryMatchesURL):
3806         (WebInspector.FileMapping.prototype._entryURIPrefix):
3807         (WebInspector.FileMapping.prototype.hasMappingForURL):
3808         (WebInspector.FileMapping.prototype._innerURIForURL):
3809         (WebInspector.FileMapping.prototype.uriForURL):
3810         (WebInspector.FileMapping.prototype.urlForURI):
3811         (WebInspector.FileMapping.prototype.mappingEntries):
3812         (WebInspector.FileMapping.prototype.setMappingEntries):
3813         (WebInspector.FileMapping.prototype.set _loadFromSettings.get this):
3814         (WebInspector.FileMapping.prototype.set _loadFromSettings):
3815         (WebInspector.FileMapping.Entry):
3816         * inspector/front-end/FileSystemWorkspaceProvider.js:
3817         (WebInspector.FileSystemWorkspaceProvider.prototype._fileSystemRemoved):
3818         * inspector/front-end/IsolatedFileSystemModel.js:
3819         (WebInspector.IsolatedFileSystemModel.prototype._fileSystemAdded):
3820         * inspector/front-end/Settings.js:
3821         (WebInspector.ExperimentsSettings):
3822         * inspector/front-end/SettingsScreen.js:
3823         (WebInspector.WorkspaceSettingsTab):
3824         (WebInspector.WorkspaceSettingsTab.prototype._createFileSystemsEditor):
3825         (WebInspector.WorkspaceSettingsTab.prototype._createShowTextInput):
3826         (WebInspector.WorkspaceSettingsTab.prototype._createEditTextInput):
3827         (WebInspector.WorkspaceSettingsTab.prototype._createRemoveButton):
3828         (WebInspector.WorkspaceSettingsTab.prototype._createAddButton):
3829         (WebInspector.WorkspaceSettingsTab.prototype._addFileSystemRow.removeFileSystemClicked):
3830         (WebInspector.WorkspaceSettingsTab.prototype._addFileSystemRow.fileSystemRemoved):
3831         (WebInspector.WorkspaceSettingsTab.prototype._addFileSystemRow):
3832         (WebInspector.WorkspaceSettingsTab.prototype._addFileSystemClicked):
3833         (WebInspector.WorkspaceSettingsTab.prototype._fileSystemAdded):
3834         (WebInspector.WorkspaceSettingsTab.prototype._createFileMappingEditor):
3835         (WebInspector.WorkspaceSettingsTab.prototype._addMappingRow.removeMappingClicked):
3836         (WebInspector.WorkspaceSettingsTab.prototype._addMappingRow):
3837         (WebInspector.WorkspaceSettingsTab.prototype._addFileMappingClicked):
3838         * inspector/front-end/helpScreen.css:
3839         (.settings-tab .file-systems-editor input.file-system-path):
3840         (.settings-tab .file-mappings-editor .workspace-settings-row input):
3841         (.settings-tab .file-mappings-editor .workspace-settings-row input.file-mapping-url):
3842         (#workspace-tab-content .button:hover):
3843         (#workspace-tab-content .workspace-settings-row:hover .button):
3844         (#workspace-tab-content .workspace-settings-row .button):
3845         (#workspace-tab-content .workspace-settings-row .remove-button):
3846         (#workspace-tab-content .workspace-settings-row .add-button):
3847         (#workspace-tab-content .workspace-settings-row .file-system-add-button):
3848         (#workspace-tab-content .workspace-settings-row .file-system-add-button:hover):
3849         * inspector/front-end/addIcon.png: Added.
3850
3851 2013-01-18  Eugene Klyuchnikov  <eustas.bug@gmail.com>
3852
3853         Web Inspector: Timeline: nest time/timeEnd records when possible (in glue-mode)
3854         https://bugs.webkit.org/show_bug.cgi?id=100114
3855
3856         Reviewed by Pavel Feldman.
3857
3858         Nesting time/timeEnd intervals will provide a better overview on
3859         what is happening.
3860
3861         * inspector/front-end/TimelinePresentationModel.js: Added logic that
3862         reparents "time" record when "timeEnd" arrives.
3863
3864 2013-01-18  Pavel Feldman  <pfeldman@chromium.org>
3865
3866         Web Inspector: do not use localeCompare unless necessary
3867         https://bugs.webkit.org/show_bug.cgi?id=107242
3868
3869         Reviewed by Vsevolod Vlasov.
3870
3871         Saving on performance here.
3872
3873         * inspector/front-end/CSSSelectorProfileView.js:
3874         (WebInspector.CSSSelectorProfileView.prototype._sortProfile.selectorComparator):
3875         (WebInspector.CSSSelectorProfileView.prototype._sortProfile.sourceComparator):
3876         * inspector/front-end/CookiesTable.js:
3877         (WebInspector.CookiesTable.prototype._sortCookies.compareTo):
3878         (WebInspector.CookiesTable.prototype._sortCookies):
3879         * inspector/front-end/DirectoryContentView.js:
3880         (.nameCompare):
3881         (.typeCompare):
3882         * inspector/front-end/FileSystemModel.js:
3883         (WebInspector.FileSystemModel.Entry.compare):
3884         * inspector/front-end/FileSystemView.js:
3885         (WebInspector.FileSystemView.EntryTreeElement.prototype._directoryContentReceived):
3886         * inspector/front-end/FilteredItemSelectionDialog.js:
3887         (WebInspector.OpenResourceDialog.compareFunction):
3888         (WebInspector.OpenResourceDialog):
3889         * inspector/front-end/NetworkRequest.js:
3890         * inspector/front-end/ScriptsSearchScope.js:
3891         (WebInspector.ScriptsSearchScope.prototype._sortedUISourceCodes.comparator):
3892         (WebInspector.ScriptsSearchScope.prototype._sortedUISourceCodes):
3893         * inspector/front-end/StylesSidebarPane.js:
3894         (WebInspector.ComputedStylePropertiesSection.prototype.onpopulate):
3895         * inspector/front-end/utilities.js:
3896
3897 2013-01-18  Andrey Lushnikov  <lushnikov@chromium.org>
3898
3899         Web Inspector: fix Closure r2388 warnings
3900         https://bugs.webkit.org/show_bug.cgi?id=107252
3901
3902         Reviewed by Pavel Feldman.
3903
3904         Surround all casts with brackets to avoid Closure warnings.
3905
3906         No new tests: no change in behaviour.
3907
3908         * inspector/front-end/BottomUpProfileDataGridTree.js:
3909         (WebInspector.BottomUpProfileDataGridTree):
3910         * inspector/front-end/BreakpointManager.js:
3911         (WebInspector.BreakpointManager.prototype._filteredBreakpointLocations):
3912         (WebInspector.BreakpointManager.prototype.toggleAllBreakpoints):
3913         (WebInspector.BreakpointManager.prototype.removeAllBreakpoints):
3914         * inspector/front-end/DOMAgent.js:
3915         (WebInspector.DOMAgent.prototype.pushNodeToFrontend):
3916         (WebInspector.DOMAgent.prototype.pushNodeByPathToFrontend):
3917         (WebInspector.DOMAgent.prototype.querySelector):
3918         (WebInspector.DOMAgent.prototype.querySelectorAll):
3919         * inspector/front-end/DefaultScriptMapping.js:
3920         (WebInspector.DefaultScriptMapping.prototype._scriptEdited):
3921         * inspector/front-end/ScriptSnippetModel.js:
3922         (WebInspector.SnippetScriptMapping.prototype.rawLocationToUILocation):
3923         * inspector/front-end/TopDownProfileDataGridTree.js:
3924         (WebInspector.TopDownProfileDataGridTree):
3925         (WebInspector.TopDownProfileDataGridTree.prototype.exclude):
3926
3927 2013-01-18  Takashi Sakamoto  <tasak@google.com>
3928
3929         Implement CSSHostRule for @host @-rules.
3930         https://bugs.webkit.org/show_bug.cgi?id=102344
3931
3932         Reviewed by Dimitri Glazkov.
3933
3934         CSSHostRule is defined in Shadow DOM spec:
3935         http://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html#css-host-rule-interface
3936         To see or to modify @host @-rules by using inspector, we need to
3937         implement CSSHostRule interface.
3938
3939         Test: fast/dom/shadow/css-hostrule-api.html
3940
3941         * DerivedSources.cpp:
3942         Modified to include JSCSSHostRule.cpp.
3943         * CMakeLists.txt:
3944         * DerivedSources.make:
3945         * DerivedSources.pri:
3946         * GNUmakefile.list.am:
3947         * Target.pri:
3948         * WebCore.gypi:
3949         * WebCore.vcproj/WebCore.vcproj:
3950         * WebCore.xcodeproj/project.pbxproj:
3951         Added CSSHostRule.cpp, CSSHostRule.h, and CSSHostRule.idl.
3952         * bindings/js/JSCSSRuleCustom.cpp:
3953         (WebCore::toJS):
3954         Add a new case that the given rule is @host @-rules to support @host
3955         @-rules.
3956         * bindings/objc/DOMCSS.mm:
3957         (kitClass):
3958         Add a new case that the given rule is @host @-rules to support @host
3959         @-rules.
3960         * bindings/v8/custom/V8CSSRuleCustom.cpp:
3961         (WebCore::wrap):
3962         * css/CSSAllInOne.cpp:
3963         * css/CSSHostRule.cpp: Added.
3964         (WebCore):
3965         (WebCore::CSSHostRule::CSSHostRule):
3966         (WebCore::CSSHostRule::cssText):
3967         * css/CSSHostRule.h: Added.
3968         (WebCore):
3969         (CSSHostRule):
3970         (WebCore::CSSHostRule::create):
3971         Implemented class CSSHostRule which inherits CSSGroupingRule.
3972         Since CSSHostRule has the same interface as CSSGroupingRule, it is
3973         required to implement its constructor and to override only type
3974         method and cssText method.
3975         * css/CSSHostRule.idl: Added.
3976         * css/CSSRule.h:
3977         * css/CSSRule.idl:
3978         Added internal HOST_RULE type number.
3979         * css/StyleResolver.cpp:
3980         (WebCore::collectCSSOMWrappers):
3981         * css/StyleRule.cpp:
3982         (WebCore::StyleRuleBase::reportMemoryUsage):
3983         (WebCore::StyleRuleBase::destroy):
3984         (WebCore::StyleRuleBase::copy):
3985         (WebCore::StyleRuleBase::createCSSOMWrapper):
3986         Modified to handle StyleRuleHost.
3987         * css/StyleRule.h:
3988         (WebCore::StyleRuleBase::isHostRule):
3989         (WebCore::StyleRuleHost::StyleRuleHost):
3990         * css/StyleSheetContents.cpp:
3991         (WebCore::childRulesHaveFailedOrCanceledSubresources):
3992         * page/DOMWindow.idl:
3993         Added CSSHostRule constructor.
3994
3995 2013-01-18  John J. Barton  <johnjbarton@chromium.org>
3996
3997         Web Inspector: inspectedWindow.eval("IamUndefined.prop", callback) fails to give exception text
3998         https://bugs.webkit.org/show_bug.cgi?id=106926
3999
4000         Reviewed by Pavel Feldman.
4001
4002         Return .description from exceptions rather than .value (which is undefined)
4003
4004         New test added to extensions/extensions-eval.html
4005
4006         * inspector/front-end/ExtensionServer.js:
4007         (WebInspector.ExtensionServer.prototype.):
4008         (WebInspector.ExtensionServer.prototype._onEvaluateOnInspectedPage):
4009
4010 2013-01-14  Dominik Röttsches  <dominik.rottsches@intel.com>
4011
4012         [EFL] Update freetype in jhbuild to 2.4.11 and activate subpixel layout
4013         https://bugs.webkit.org/show_bug.cgi?id=106774
4014
4015         In order to fix a long standing linespacing/font ascent & descent issue
4016         we found that FreeType commit b0962ac34e660 solves that problem.
4017         Let's update FreeType accordingly, but bump it to 2.4.11 due to the
4018         maintainer recommending several security updates after that said commit.
4019
4020         Also, in order to avoid extra rebaselining, let's activate subpixel
4021         layout at the same time. With subpixel layout I propose to remove
4022         rounding of the linespacing value in order to not introduce rounding
4023         inaccuracies at the SimpleFontData level. Other platforms don't do that
4024         anymore, furthermore the linegap value is not rounded either.
4025
4026         Reviewed by Martin Robinson.
4027
4028         No new tests, affects a large number of tests that will require rebaselining.
4029
4030         * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
4031         (WebCore::SimpleFontData::platformInit): Remove rounding when setting linespacing.
4032
4033 2013-01-18  Vivek Galatage  <vivek.vg@samsung.com>
4034
4035         Web Inspector: Search shortcut clears the current search box contents
4036         https://bugs.webkit.org/show_bug.cgi?id=107109
4037
4038         Reviewed by Pavel Feldman.
4039
4040         The search box contents should be changed only when the current f