f5acdb3d45866890e6424e1dab7ccf99869c140d
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-02-25  Alpha Lam  <hclam@chromium.org>
2
3         GIFImageReader to read from source data directly
4         https://bugs.webkit.org/show_bug.cgi?id=109662
5
6         Reviewed by Stephen White.
7
8         This is the first patch to improve GIF image decoding.
9
10         GIFImageReader has an internal 256 bytes buffer to saving incoming
11         bytes. This mechanism is out-dated because WebKit holds the entire
12         file in memory and it is not necessary to hold data in an intermediate
13         buffer.
14
15         This is also a blocker for later work to parse and decode GIF
16         incrementally.
17
18         This change removed the imtermediate 'hold' buffer and uses an index
19         for data position to keep track of parsing of the GIF file. Buffer for
20         global colormap and local colormap are also removed because they can be
21         referenced from the data stream.
22
23         This change is tested by:
24
25         Layout tests
26         All tests passed under fast/images.
27
28         Unit tests
29         Added GIFImageDecoderTest for Chromium.
30
31         Local testing
32         I tested this implementation against a set of 50k GIF images and
33         there's no crashes and produces bit-exact results as previous code.
34
35         * platform/image-decoders/gif/GIFImageDecoder.cpp:
36         (WebCore::GIFImageDecoder::setData):
37         (WebCore::GIFImageDecoder::frameCount):
38         (WebCore::GIFImageDecoder::haveDecodedRow):
39         (WebCore::GIFImageDecoder::decode):
40         * platform/image-decoders/gif/GIFImageReader.cpp:
41         (GIFImageReader::doLZW):
42         (GIFImageReader::decode):
43         (GIFImageReader::decodeInternal):
44         (GIFImageReader::setRemainingBytes):
45         * platform/image-decoders/gif/GIFImageReader.h:
46         (GIFFrameContext):
47         (GIFFrameContext::GIFFrameContext):
48         (GIFFrameContext::~GIFFrameContext):
49         (GIFImageReader::GIFImageReader):
50         (GIFImageReader::~GIFImageReader):
51         (GIFImageReader::setData):
52         (GIFImageReader):
53         (GIFImageReader::globalColormap):
54         (GIFImageReader::localColormap):
55         (GIFImageReader::localColormapSize):
56         (GIFImageReader::data):
57         (GIFImageReader::colormap):
58
59 2013-02-25  Sergio Villar Senin  <svillar@igalia.com>
60
61         [soup] "Too many redirects" error loading chat in plus.google.com
62         https://bugs.webkit.org/show_bug.cgi?id=64575
63
64         Reviewed by Martin Robinson.
65
66         Set the firstPartyForCookies for the new request on redirects to
67         the URL used for redirection.
68
69         Test: http/tests/cookies/set-cookie-on-redirect.html
70
71         * platform/network/soup/ResourceHandleSoup.cpp:
72         (WebCore::doRedirect):
73
74 2013-02-25  Andreas Kling  <akling@apple.com>
75
76         Reduce amount of code that includes StylePropertySet.h
77         <http://webkit.org/b/101149>
78
79         Reviewed by Antti Koivisto.
80
81         StylePropertySet.h and dependents were getting included by the majority of WebKit
82         through either StyledElement.h or CSSStyleDeclaration.h. This change removes those includes
83         and moves inclusion to .cpp files instead. After this change, it's possible to hack most
84         of WebCore/css/ and rebuild <100 files instead of >1000.
85
86         The only real code change in here is changing CSSStyleDeclaration::cssPropertyMatches()
87         to take a CSSPropertyID/CSSValue* combo instead of a StylePropertySet::Reference.
88
89         * css/CSSComputedStyleDeclaration.cpp:
90         (WebCore::CSSComputedStyleDeclaration::cssPropertyMatches):
91         * css/CSSComputedStyleDeclaration.h:
92         (CSSComputedStyleDeclaration):
93         * css/CSSStyleDeclaration.h:
94         (CSSStyleDeclaration):
95         * css/PropertySetCSSStyleDeclaration.cpp:
96         (WebCore::PropertySetCSSStyleDeclaration::cssPropertyMatches):
97         * css/PropertySetCSSStyleDeclaration.h:
98         * css/SelectorChecker.h:
99         * css/SelectorCheckerFastPath.cpp:
100         * css/SelectorFilter.cpp:
101         * css/SelectorFilter.h:
102         * css/StylePropertySet.cpp:
103         (WebCore::StylePropertySet::propertyMatches):
104         (WebCore::StylePropertySet::removeEquivalentProperties):
105         * css/StylePropertySet.h:
106         * css/StyleResolver.cpp:
107         (WebCore::StyleResolver::MatchedProperties::MatchedProperties):
108         (WebCore::StyleResolver::MatchedProperties::~MatchedProperties):
109         * css/StyleResolver.h:
110         (MatchedProperties):
111         * css/StyleRule.cpp:
112         * css/ViewportStyleResolver.cpp:
113         (WebCore::ViewportStyleResolver::~ViewportStyleResolver):
114         * css/ViewportStyleResolver.h:
115         (ViewportStyleResolver):
116         * css/WebKitCSSKeyframeRule.cpp:
117         (WebCore::StyleKeyframe::StyleKeyframe):
118         (WebCore::StyleKeyframe::~StyleKeyframe):
119         * css/WebKitCSSKeyframeRule.h:
120         (StyleKeyframe):
121         * dom/Attr.cpp:
122         * dom/Document.cpp:
123         * dom/Element.cpp:
124         * dom/StyledElement.cpp:
125         (WebCore::StyledElement::addPropertyToPresentationAttributeStyle):
126         * dom/StyledElement.h:
127         (StyledElement):
128         * editing/FrameSelection.cpp:
129         * editing/RemoveCSSPropertyCommand.cpp:
130         (WebCore::RemoveCSSPropertyCommand::~RemoveCSSPropertyCommand):
131         * editing/RemoveCSSPropertyCommand.h:
132         (RemoveCSSPropertyCommand):
133         * editing/RemoveFormatCommand.cpp:
134         * html/HTMLBodyElement.cpp:
135         * html/HTMLElement.cpp:
136         (WebCore::HTMLElement::addHTMLLengthToStyle):
137         (WebCore::HTMLElement::addHTMLColorToStyle):
138         * html/HTMLElement.h:
139         (HTMLElement):
140         * html/HTMLFontElement.cpp:
141         * html/HTMLHRElement.cpp:
142         * html/HTMLPreElement.cpp:
143         * html/HTMLTableElement.cpp:
144         * html/HTMLTablePartElement.cpp:
145         * html/canvas/CanvasStyle.cpp:
146         * html/shadow/MediaControlElementTypes.cpp:
147         * inspector/InspectorStyleSheet.cpp:
148         * page/PageSerializer.cpp:
149         * rendering/RenderTableCell.cpp:
150         * svg/SVGAnimateElement.cpp:
151         * svg/SVGElementRareData.h:
152         * svg/SVGFontFaceElement.cpp:
153
154 2013-02-25  Alexei Filippov  <alph@chromium.org>
155
156         Web Inspector: Remove CPU profile from a group causes exception
157         https://bugs.webkit.org/show_bug.cgi?id=110466
158
159         Reviewed by Yury Semikhatsky.
160
161         WebInspector.ProfilesPanel._removeProfileHandle did not handle
162         profile removal from a group. The fix takes care of this case.
163
164         Test: inspector/profiler/cpu-profiler-profile-removal.html
165
166         * inspector/front-end/ProfilesPanel.js:
167         (WebInspector.ProfilesPanel.prototype.addProfileHeader):
168         (WebInspector.ProfilesPanel.prototype._removeProfileHeader):
169
170 2013-02-23  Ilya Tikhonovsky  <loislo@chromium.org>
171
172         Web Inspector: Native Memory Instrumentation: replace String with const char* in MemoryObjectInfo
173         https://bugs.webkit.org/show_bug.cgi?id=110599
174
175         Reviewed by Yury Semikhatsky.
176
177         Due to potentially dynamic nature of names and classNames we need to make a copy of the strings
178         that were given us via MemoryInstrumentation calls.
179         So I extended client api with registerString method that pushes the strings
180         down to the serializer.
181
182         * css/InspectorCSSOMWrappers.h:
183         * inspector/HeapGraphSerializer.cpp:
184         (WebCore::HeapGraphSerializer::HeapGraphSerializer):
185         (WebCore::HeapGraphSerializer::reportNodeImpl):
186         (WebCore::HeapGraphSerializer::reportEdgeImpl):
187         (WebCore::HeapGraphSerializer::registerString):
188         (WebCore::HeapGraphSerializer::registerTypeString):
189         (WebCore::HeapGraphSerializer::addRootNode):
190         * inspector/HeapGraphSerializer.h:
191         (HeapGraphSerializer):
192         * inspector/MemoryInstrumentationImpl.cpp:
193         (WebCore::MemoryInstrumentationClientImpl::registerString):
194         (WebCore):
195         * inspector/MemoryInstrumentationImpl.h:
196         (MemoryInstrumentationClientImpl):
197         * loader/cache/CachedResource.cpp:
198         (WebCore::CachedResource::reportMemoryUsage):
199
200 2013-02-25  Keishi Hattori  <keishi@webkit.org>
201
202         Add a scrollbar class for the new calendar picker
203         https://bugs.webkit.org/show_bug.cgi?id=110589
204
205         Reviewed by Kent Tamura.
206
207         Adding a scrollbar to be used in the new calendar picker (Bug 109439).
208
209         No new tests. Code is not used yet.
210
211         * Resources/pagepopups/calendarPicker.js:
212         (ScrubbyScrollBar):
213         (ScrubbyScrollBar.prototype.height):
214         (ScrubbyScrollBar.prototype.setHeight):
215         (ScrubbyScrollBar.prototype.setThumbHeight): Sets the height of the scroll bar thumb.
216         (ScrubbyScrollBar.prototype._setThumbPositionFromEvent): Sets the thumb position from a mouse event.
217         (ScrubbyScrollBar.prototype.onMouseDown):
218         (ScrubbyScrollBar.prototype.onWindowMouseMove):
219         (ScrubbyScrollBar.prototype.onWindowMouseUp):
220         (ScrubbyScrollBar.prototype.onThumbStyleTopAnimationStep): Animates the thumb back to the center position.
221         (ScrubbyScrollBar.prototype.onScrollTimer): Fires repeatedly while the thumb is being dragged.
222
223 2013-02-25  Ilya Tikhonovsky  <loislo@chromium.org>
224
225         Unreviewed. Fix of closure type annotations.
226
227         * inspector/front-end/UISourceCode.js:
228         * inspector/front-end/utilities.js:
229
230 2013-02-25  Eugene Klyuchnikov  <eustas@chromium.org>
231
232         Web Inspector: [Network] Timeline bars and dividers are positioned in different coordinate systems.
233         https://bugs.webkit.org/show_bug.cgi?id=109943
234
235         Reviewed by Pavel Feldman.
236
237         Look at network log: red bar (on load) is positioned to the right of
238         the last required load.
239         
240         This is incorrect. For exmaple, in case of short event it should be
241         positioned in the center of the bar.
242
243         * inspector/front-end/DataGrid.js:
244         Fix - hidden columns can have non-zero width.
245         * inspector/front-end/NetworkPanel.js: Use correct width for calculator.
246         * inspector/front-end/networkLogView.css: Removed parasite paddinds.
247         Extracted common absolute "paddings".
248
249 2013-02-25  Keishi Hattori  <keishi@webkit.org>
250
251         Add list view for new calendar picker
252         https://bugs.webkit.org/show_bug.cgi?id=110140
253
254         Reviewed by Kent Tamura.
255
256         Adding list view class to be used in the new calendar picker (Bug 109439).
257
258         No new tests. Code is not yet used.
259
260         * Resources/pagepopups/calendarPicker.js:
261         (ListCell): One row inside the list view. We reuse
262         list cells to avoid animation hiccups caused by memory allocation.
263         (ListCell.prototype._recycleBin): Returns array to
264         store thrown away list cells so we can reuse them.
265         (ListCell.prototype.throwAway): Hides the cell and puts it in the recycle bin.
266         (ListCell.prototype.show):
267         (ListCell.prototype.hide): Hide the cell when we don't need the cell any more.
268         (ListCell.prototype.width):
269         (ListCell.prototype.setWidth):
270         (ListCell.prototype.position):
271         (ListCell.prototype.setPosition): Sets the CSS transform to position the cell.
272         (ListCell.prototype.setSelected): Adds selected CSS class.
273         (ListView): Shows a scrolling list.
274         (ListView.prototype.onAnimationFrameWillFinish): Calls updateCells if the cells need to be updated.
275         (ListView.prototype.setNeedsUpdateCells): Mark the cells as need to be updated.
276         (ListView.prototype.cellAtRow): Returns the cell at a given row. If the cell is not visible and doesn't exist, returns undefined.
277         (ListView.prototype.rowAtScrollOffset): The row that is displayed at the given scroll offset.
278         (ListView.prototype.scrollOffsetForRow): The scroll offset for the top of a given row.
279         (ListView.prototype.addCellIfNecessary): Adds the cell for a given row.
280         (ListView.prototype.prepareNewCell): Prepares a new or recycled cell for a given row.
281         (ListView.prototype.throwAwayCell): Throws a way a cell.
282         (ListView.prototype.firstVisibleRow): The first visible row at the top of the view.
283         (ListView.prototype.lastVisibleRow): The last visible row at the bottom of the view.
284         (ListView.prototype.scrollViewDidChangeContentOffset):
285         (ListView.prototype.scrollViewDidChangeHeight):
286         (ListView.prototype.scrollViewDidChangePartition):
287         (ListView.prototype.updateCells): Updates all the cells that are visible.
288         (ListView.prototype.width):
289         (ListView.prototype.setWidth):
290         (ListView.prototype.height):
291         (ListView.prototype.setHeight):
292         (ListView.prototype.onClick): Clicking on a row selects it.
293         (ListView.prototype.select):
294         (ListView.prototype.deselect):
295         (ListView.prototype.scrollToRow): Scrolls to a given row.
296
297 2013-02-25  Alexei Filippov  <alph@chromium.org>
298
299         Web Inspector: move profile type specific code out of ProfilesPanel (refactor)
300         https://bugs.webkit.org/show_bug.cgi?id=110597
301
302         Reviewed by Yury Semikhatsky.
303
304         Move profile type specific functionality out of ProfilesPanel class.
305         This is a first part of WebInspector.ProfilesPanel refactoring.
306
307         No new tests as the functionality isn't changed.
308
309         * English.lproj/localizedStrings.js:
310         * inspector/front-end/CPUProfileView.js:
311         (WebInspector.CPUProfileType):
312         (WebInspector.CPUProfileType.prototype.addProfileHeader):
313         (WebInspector.CPUProfileType.prototype.removeProfile):
314         (WebInspector.CPUProfileType.prototype._requestProfilesFromBackend):
315         (WebInspector.CPUProfileType.prototype.resetProfiles):
316         (WebInspector.CPUProfileType.prototype.addHeapSnapshotChunk):
317         (WebInspector.CPUProfileType.prototype.finishHeapSnapshot):
318         (WebInspector.CPUProfileType.prototype.reportHeapSnapshotProgress):
319         * inspector/front-end/CSSSelectorProfileView.js:
320         (WebInspector.CSSSelectorProfileType.prototype.buttonClicked):
321         (WebInspector.CSSSelectorProfileType.prototype._startRecordingProfile):
322         (WebInspector.CSSSelectorProfileType.prototype._stopRecordingProfile):
323         * inspector/front-end/CanvasProfileView.js:
324         (WebInspector.CanvasProfileType.prototype.buttonClicked):
325         (WebInspector.CanvasProfileType.prototype._runSingleFrameCapturing):
326         (WebInspector.CanvasProfileType.prototype._startFrameCapturing):
327         (WebInspector.CanvasProfileType.prototype._didStartCapturingFrame):
328         (WebInspector.CanvasProfileType.prototype._reset):
329         (WebInspector.CanvasProfileType.prototype.removeProfile):
330         (WebInspector.CanvasProfileHeader.prototype.dispose):
331         * inspector/front-end/HeapSnapshotView.js:
332         (WebInspector.HeapSnapshotView.prototype._profiles):
333         (WebInspector.HeapSnapshotProfileType):
334         (WebInspector.HeapSnapshotProfileType.prototype.buttonClicked):
335         (WebInspector.HeapSnapshotProfileType.prototype.addProfileHeader):
336         (WebInspector.HeapSnapshotProfileType.prototype.addHeapSnapshotChunk):
337         (WebInspector.HeapSnapshotProfileType.prototype.finishHeapSnapshot):
338         (WebInspector.HeapSnapshotProfileType.prototype.reportHeapSnapshotProgress):
339         (WebInspector.HeapSnapshotProfileType.prototype.resetProfiles):
340         (WebInspector.HeapSnapshotProfileType.prototype.removeProfile):
341         (WebInspector.HeapSnapshotProfileType.prototype._requestProfilesFromBackend):
342         (WebInspector.HeapProfileHeader.prototype._updateTransferProgress):
343         * inspector/front-end/NativeMemorySnapshotView.js:
344         (WebInspector.NativeSnapshotProfileType):
345         (WebInspector.NativeSnapshotProfileType.prototype.addNativeSnapshotChunk):
346         * inspector/front-end/ProfilesPanel.js:
347         (WebInspector.ProfileType):
348         (WebInspector.ProfileType.prototype.buttonClicked):
349         (WebInspector.ProfileType.prototype.get description):
350         (WebInspector.ProfileType.prototype.getProfiles):
351         (WebInspector.ProfileType.prototype.getProfile):
352         (WebInspector.ProfileType.prototype._makeKey):
353         (WebInspector.ProfileType.prototype.addProfile):
354         (WebInspector.ProfileType.prototype.removeProfile):
355         (WebInspector.ProfileType.prototype.findTemporaryProfile):
356         (WebInspector.ProfileType.prototype._reset):
357         (WebInspector.ProfileType.prototype._requestProfilesFromBackend):
358         (WebInspector.ProfileHeader):
359         (WebInspector.ProfileHeader.prototype.dispose):
360         (WebInspector.ProfilesPanel):
361         (WebInspector.ProfilesPanel.prototype._loadFromFile):
362         (WebInspector.ProfilesPanel.prototype.toggleRecordButton):
363         (WebInspector.ProfilesPanel.prototype._populateAllProfiles):
364         (WebInspector.ProfilesPanel.prototype.wasShown):
365         (WebInspector.ProfilesPanel.prototype._profilerWasEnabled):
366         (WebInspector.ProfilesPanel.prototype._reset):
367         (WebInspector.ProfilesPanel.prototype._registerProfileType.onAddProfileHeader):
368         (WebInspector.ProfilesPanel.prototype._registerProfileType.onRemoveProfileHeader):
369         (WebInspector.ProfilesPanel.prototype._registerProfileType.onProgressUpdated):
370         (WebInspector.ProfilesPanel.prototype._registerProfileType):
371         (WebInspector.ProfilesPanel.prototype._addProfileHeader):
372         (WebInspector.ProfilesPanel.prototype._removeProfileHeader):
373         (WebInspector.ProfilesPanel.prototype._createTemporaryProfile):
374         (WebInspector.ProfilesPanel.prototype._removeTemporaryProfile):
375         (WebInspector.ProfilesPanel.prototype.getProfile):
376         (WebInspector.ProfilesPanel.prototype.showProfile):
377         (WebInspector.ProfilesPanel.prototype._getAllProfiles):
378         (WebInspector.ProfilesPanel.prototype._searchableViews):
379         (WebInspector.ProfilesPanel.prototype.searchCanceled):
380         (WebInspector.ProfilesPanel.prototype.setRecordingProfile):
381         (WebInspector.ProfilesPanel.prototype._reportProfileProgress):
382
383 2013-02-25  Ilya Tikhonovsky  <loislo@chromium.org>
384
385         Unreviewed fix of type annotation for this._liveLocations.
386
387         * inspector/front-end/UISourceCode.js:
388         (WebInspector.UISourceCode):
389
390 2013-02-25  Kent Tamura  <tkent@chromium.org>
391
392         Fix style errors in WebCore/editing/{htmlediting,markup,visible_units}.*
393         https://bugs.webkit.org/show_bug.cgi?id=110721
394
395         Reviewed by Ryosuke Niwa.
396
397         No new tests. This should not make any bahevior changes.
398
399         * editing/htmlediting.cpp:
400         (WebCore::lowestEditableAncestor):
401         (WebCore):
402         (WebCore::isSpecialElement):
403         (WebCore::enclosingListChild):
404         (WebCore::canMergeLists):
405         (WebCore::tabSpanNode):
406         (WebCore::isNodeRendered):
407         (WebCore::caretMaxOffset):
408         * editing/htmlediting.h:
409         (WebCore):
410         * editing/markup.cpp:
411         (WebCore::StyledMarkupAccumulator::appendElement):
412         * editing/markup.h:
413         (WebCore):
414         * editing/visible_units.cpp:
415         (WebCore::previousRootInlineBoxCandidatePosition):
416         (WebCore::nextRootInlineBoxCandidatePosition):
417         (WebCore::wordBreakIteratorForMinOffsetBoundary):
418         (WebCore::previousBoundary):
419         (WebCore::endOfLine):
420         (WebCore::previousLinePosition):
421         (WebCore::nextLinePosition):
422         (WebCore::nextSentencePositionBoundary):
423         (WebCore::startOfParagraph):
424         (WebCore::endOfParagraph):
425
426 2013-02-24  Ilya Tikhonovsky  <loislo@chromium.org>
427
428         Web Inspector: Improve speed of Linkifier.reset operation.
429         https://bugs.webkit.org/show_bug.cgi?id=110696
430
431         Reviewed by Yury Semikhatsky.
432
433         Linkifier calls Location.dispose N times and each dispose method calls Array.remove
434         which scans entire array and does splice. So the complexity of Linkifier.reset
435         is O(N^2). I replaced the arrays with Set and got O(N) complexity.
436
437         Drive by fix: The identifier generator was slightly changed.
438         Now it produces identifiers that couldn't be converted into a number.
439         So the engine will never convert Set/Map object into an array.
440
441         * inspector/front-end/Script.js:
442         (WebInspector.Script):
443         (WebInspector.Script.prototype.updateLocations):
444         (WebInspector.Script.prototype.createLiveLocation):
445         * inspector/front-end/UISourceCode.js:
446         (WebInspector.UISourceCode):
447         (WebInspector.UISourceCode.prototype.addLiveLocation):
448         (WebInspector.UISourceCode.prototype.updateLiveLocations):
449         * inspector/front-end/utilities.js:
450
451 2013-02-24  Sheriff Bot  <webkit.review.bot@gmail.com>
452
453         Unreviewed, rolling out r143797.
454         http://trac.webkit.org/changeset/143797
455         https://bugs.webkit.org/show_bug.cgi?id=110724
456
457         Causes assertion failures in multiple tests. (Requested by
458         vsevik on #webkit).
459
460         * dom/DocumentParser.h:
461         (DocumentParser):
462         * html/parser/HTMLDocumentParser.cpp:
463         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
464         * html/parser/HTMLDocumentParser.h:
465         (HTMLDocumentParser):
466         (WebCore::HTMLDocumentParser::shouldUseThreading):
467         * loader/DocumentWriter.cpp:
468         (WebCore::DocumentWriter::replaceDocument):
469
470 2013-02-24  Hajime Morrita  <morrita@google.com>
471
472         Rollout r143556, it regressed html5-full-render perf.
473         https://bugs.webkit.org/show_bug.cgi?id=110719
474
475         Unreviewed rollout.
476         
477         * css/BasicShapeFunctions.cpp:
478         (WebCore::convertToLength):
479         (WebCore::basicShapeForValue):
480         * css/BasicShapeFunctions.h:
481         (WebCore):
482         * css/CSSGradientValue.cpp:
483         (WebCore::CSSGradientValue::gradientWithStylesResolved):
484         * css/CSSGradientValue.h:
485         (CSSGradientValue):
486         * css/CSSToStyleMap.cpp:
487         (WebCore::CSSToStyleMap::style):
488         (WebCore::CSSToStyleMap::rootElementStyle):
489         (WebCore::CSSToStyleMap::useSVGZoomRules):
490         (WebCore::CSSToStyleMap::styleImage):
491         * css/CSSToStyleMap.h:
492         (WebCore):
493         (WebCore::CSSToStyleMap::CSSToStyleMap):
494         (CSSToStyleMap):
495         * css/SVGCSSStyleSelector.cpp:
496         (WebCore::StyleResolver::applySVGProperty):
497         * css/StyleBuilder.cpp:
498         (WebCore::ApplyPropertyExpanding::applyInheritValue):
499         (WebCore::ApplyPropertyExpanding::applyInitialValue):
500         (WebCore::ApplyPropertyExpanding::applyValue):
501         (WebCore::ApplyPropertyDefaultBase::applyInheritValue):
502         (WebCore::ApplyPropertyDefaultBase::applyInitialValue):
503         (WebCore::ApplyPropertyDefaultBase::applyValue):
504         (WebCore::ApplyPropertyDefault::applyValue):
505         (WebCore::ApplyPropertyNumber::applyValue):
506         (WebCore::ApplyPropertyStyleImage::applyValue):
507         (WebCore::ApplyPropertyAuto::applyInheritValue):
508         (WebCore::ApplyPropertyAuto::applyInitialValue):
509         (WebCore::ApplyPropertyAuto::applyValue):
510         (WebCore::ApplyPropertyClip::convertToLength):
511         (WebCore::ApplyPropertyClip::applyInheritValue):
512         (WebCore::ApplyPropertyClip::applyInitialValue):
513         (WebCore::ApplyPropertyClip::applyValue):
514         (WebCore::ApplyPropertyColor::applyInheritValue):
515         (WebCore::ApplyPropertyColor::applyInitialValue):
516         (WebCore::ApplyPropertyColor::applyValue):
517         (WebCore::ApplyPropertyColor::applyColorValue):
518         (WebCore::ApplyPropertyDirection::applyValue):
519         (WebCore::ApplyPropertyLength::applyValue):
520         (WebCore::ApplyPropertyString::applyValue):
521         (WebCore::ApplyPropertyBorderRadius::applyValue):
522         (WebCore::ApplyPropertyFillLayer::applyInheritValue):
523         (WebCore::ApplyPropertyFillLayer::applyInitialValue):
524         (WebCore::ApplyPropertyFillLayer::applyValue):
525         (WebCore::ApplyPropertyComputeLength::applyValue):
526         (WebCore::ApplyPropertyFont::applyInheritValue):
527         (WebCore::ApplyPropertyFont::applyInitialValue):
528         (WebCore::ApplyPropertyFont::applyValue):
529         (WebCore::ApplyPropertyFontSize::applyInheritValue):
530         (WebCore::ApplyPropertyFontSize::applyInitialValue):
531         (WebCore::ApplyPropertyFontSize::applyValue):
532         (WebCore::ApplyPropertyFontWeight::applyValue):
533         (WebCore::ApplyPropertyFontVariantLigatures::applyInheritValue):
534         (WebCore::ApplyPropertyFontVariantLigatures::applyInitialValue):
535         (WebCore::ApplyPropertyFontVariantLigatures::applyValue):
536         (WebCore::ApplyPropertyBorderImage::applyValue):
537         (WebCore::ApplyPropertyBorderImageModifier::applyInheritValue):
538         (WebCore::ApplyPropertyBorderImageModifier::applyInitialValue):
539         (WebCore::ApplyPropertyBorderImageModifier::applyValue):
540         (WebCore::ApplyPropertyBorderImageSource::applyValue):
541         (WebCore::ApplyPropertyCounter::emptyFunction):
542         (WebCore::ApplyPropertyCounter::applyInheritValue):
543         (WebCore::ApplyPropertyCounter::applyValue):
544         (WebCore::ApplyPropertyCursor::applyInheritValue):
545         (WebCore::ApplyPropertyCursor::applyInitialValue):
546         (WebCore::ApplyPropertyCursor::applyValue):
547         (WebCore::ApplyPropertyTextAlign::applyValue):
548         (WebCore::ApplyPropertyTextDecoration::applyValue):
549         (WebCore::ApplyPropertyLineHeight::applyValue):
550         (WebCore::ApplyPropertyPageSize::applyInheritValue):
551         (WebCore::ApplyPropertyPageSize::applyInitialValue):
552         (WebCore::ApplyPropertyPageSize::applyValue):
553         (WebCore::ApplyPropertyTextEmphasisStyle::applyInheritValue):
554         (WebCore::ApplyPropertyTextEmphasisStyle::applyInitialValue):
555         (WebCore::ApplyPropertyTextEmphasisStyle::applyValue):
556         (WebCore::ApplyPropertyAnimation::map):
557         (WebCore::ApplyPropertyAnimation::applyInheritValue):
558         (WebCore::ApplyPropertyAnimation::applyInitialValue):
559         (WebCore::ApplyPropertyAnimation::applyValue):
560         (WebCore::ApplyPropertyOutlineStyle::applyInheritValue):
561         (WebCore::ApplyPropertyOutlineStyle::applyInitialValue):
562         (WebCore::ApplyPropertyOutlineStyle::applyValue):
563         (WebCore::ApplyPropertyResize::applyValue):
564         (WebCore::ApplyPropertyVerticalAlign::applyValue):
565         (WebCore::ApplyPropertyAspectRatio::applyInheritValue):
566         (WebCore::ApplyPropertyAspectRatio::applyInitialValue):
567         (WebCore::ApplyPropertyAspectRatio::applyValue):
568         (WebCore::ApplyPropertyZoom::resetEffectiveZoom):
569         (WebCore::ApplyPropertyZoom::applyInheritValue):
570         (WebCore::ApplyPropertyZoom::applyInitialValue):
571         (WebCore::ApplyPropertyZoom::applyValue):
572         (WebCore::ApplyPropertyDisplay::isValidDisplayValue):
573         (WebCore::ApplyPropertyDisplay::applyInheritValue):
574         (WebCore::ApplyPropertyDisplay::applyInitialValue):
575         (WebCore::ApplyPropertyDisplay::applyValue):
576         (WebCore::ApplyPropertyClipPath::applyValue):
577         (WebCore::ApplyPropertyExclusionShape::applyValue):
578         (WebCore::ApplyPropertyImageResolution::applyInheritValue):
579         (WebCore::ApplyPropertyImageResolution::applyInitialValue):
580         (WebCore::ApplyPropertyImageResolution::applyValue):
581         * css/StyleBuilder.h:
582         (WebCore):
583         (PropertyHandler):
584         (WebCore::PropertyHandler::applyInheritValue):
585         (WebCore::PropertyHandler::applyInitialValue):
586         (WebCore::PropertyHandler::applyValue):
587         * css/StyleResolver.cpp:
588         (WebCore):
589         (WebCore::StyleResolver::StyleResolver):
590         (WebCore::StyleResolver::collectMatchingRules):
591         (WebCore::StyleResolver::collectMatchingRulesForRegion):
592         (WebCore::StyleResolver::sortAndTransferMatchedRules):
593         (WebCore::StyleResolver::matchScopedAuthorRules):
594         (WebCore::StyleResolver::styleSharingCandidateMatchesHostRules):
595         (WebCore::StyleResolver::matchHostRules):
596         (WebCore::StyleResolver::matchAuthorRules):
597         (WebCore::StyleResolver::matchUserRules):
598         (WebCore::StyleResolver::matchUARules):
599         (WebCore::StyleResolver::collectMatchingRulesForList):
600         (WebCore::StyleResolver::sortMatchedRules):
601         (WebCore::StyleResolver::matchAllRules):
602         (WebCore::StyleResolver::initElement):
603         (WebCore::StyleResolver::styleSharingCandidateMatchesRuleSet):
604         (WebCore::StyleResolver::canShareStyleWithControl):
605         (WebCore::StyleResolver::sharingCandidateHasIdenticalStyleAffectingAttributes):
606         (WebCore::StyleResolver::canShareStyleWithElement):
607         (WebCore::StyleResolver::findSiblingForStyleSharing):
608         (WebCore::StyleResolver::locateSharedStyle):
609         (WebCore::StyleResolver::styleForElement):
610         (WebCore::StyleResolver::styleForKeyframe):
611         (WebCore::StyleResolver::keyframeStylesForAnimation):
612         (WebCore::StyleResolver::pseudoStyleForElement):
613         (WebCore::StyleResolver::styleForPage):
614         (WebCore::StyleResolver::defaultStyleForElement):
615         (WebCore::StyleResolver::adjustRenderStyle):
616         (WebCore::StyleResolver::updateFont):
617         (WebCore::StyleResolver::pseudoStyleRulesForElement):
618         (WebCore::StyleResolver::ruleMatches):
619         (WebCore::StyleResolver::checkRegionSelector):
620         (WebCore::StyleResolver::applyProperties):
621         (WebCore::StyleResolver::applyMatchedProperties):
622         (WebCore::StyleResolver::isLeftPage):
623         (WebCore::StyleResolver::applyPropertyToStyle):
624         (WebCore::StyleResolver::applyPropertyToCurrentStyle):
625         (WebCore::StyleResolver::useSVGZoomRules):
626         (WebCore::StyleResolver::resolveVariables):
627         (WebCore::StyleResolver::applyProperty):
628         (WebCore::StyleResolver::styleImage):
629         (WebCore::StyleResolver::cachedOrPendingFromValue):
630         (WebCore::StyleResolver::generatedOrPendingFromValue):
631         (WebCore::StyleResolver::setOrPendingFromValue):
632         (WebCore::StyleResolver::cursorOrPendingFromValue):
633         (WebCore::StyleResolver::checkForTextSizeAdjust):
634         (WebCore::StyleResolver::checkForZoomChange):
635         (WebCore::StyleResolver::checkForGenericFamilyChange):
636         (WebCore::StyleResolver::initializeFontStyle):
637         (WebCore::StyleResolver::setFontSize):
638         (WebCore::StyleResolver::colorFromPrimitiveValue):
639         (WebCore::StyleResolver::loadPendingSVGDocuments):
640         (WebCore::StyleResolver::styleShader):
641         (WebCore::StyleResolver::cachedOrPendingStyleShaderFromValue):
642         (WebCore::StyleResolver::loadPendingShaders):
643         (WebCore::StyleResolver::parseCustomFilterTransformParameter):
644         (WebCore::StyleResolver::parseCustomFilterParameter):
645         (WebCore::StyleResolver::parseCustomFilterParameterList):
646         (WebCore::StyleResolver::createCustomFilterOperationWithInlineSyntax):
647         (WebCore::StyleResolver::createCustomFilterOperation):
648         (WebCore::StyleResolver::createFilterOperations):
649         (WebCore::StyleResolver::loadPendingImage):
650         (WebCore::StyleResolver::loadPendingImages):
651         (WebCore::StyleResolver::loadPendingResources):
652         (WebCore::StyleResolver::reportMemoryUsage):
653         * css/StyleResolver.h:
654         (WebCore::StyleResolver::style):
655         (WebCore::StyleResolver::parentStyle):
656         (WebCore::StyleResolver::rootElementStyle):
657         (WebCore::StyleResolver::element):
658         (WebCore::StyleResolver::hasParentNode):
659         (StyleResolver):
660         (WebCore::StyleResolver::isRightPage):
661         (WebCore::StyleResolver::State::State):
662         (WebCore::StyleResolver::State::document):
663         (State):
664         (WebCore::StyleResolver::applyPropertyToRegularStyle):
665         (WebCore::StyleResolver::applyPropertyToVisitedLinkStyle):
666         (WebCore::StyleResolver::styleMap):
667         (WebCore::StyleResolver::fontDescription):
668         (WebCore::StyleResolver::parentFontDescription):
669         (WebCore::StyleResolver::setFontDescription):
670         (WebCore::StyleResolver::setZoom):
671         (WebCore::StyleResolver::setEffectiveZoom):
672         (WebCore::StyleResolver::setTextSizeAdjust):
673         (WebCore::StyleResolver::setWritingMode):
674         (WebCore::StyleResolver::setTextOrientation):
675         * html/canvas/CanvasRenderingContext2D.cpp:
676         (WebCore::CanvasRenderingContext2D::setFont):
677
678 2013-02-24  Eric Carlson  <eric.carlson@apple.com>
679
680         [Mac] cleanup MediaPlayerPrivateAVFoundation and InbandTextTrackPrivateAVF
681         https://bugs.webkit.org/show_bug.cgi?id=110716
682
683         Reviewed by Alexey Proskuryakov.
684
685         No new tests, no functionality changed.
686
687         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
688         (WebCore::InbandTextTrackPrivateAVF::InbandTextTrackPrivateAVF): Take AVFInbandTrackParent*
689             instead of MediaPlayerPrivateAVFoundation*.
690         (WebCore::InbandTextTrackPrivateAVF::processCue): Pass new cues directly to the client.
691         (WebCore::InbandTextTrackPrivateAVF::disconnect): m_player -> m_owner.
692         (WebCore::InbandTextTrackPrivateAVF::setMode):  m_player -> m_owner.
693         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
694
695         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
696         (WebCore::MediaPlayerPrivateAVFoundation::addGenericCue): Delete, no longer needed.
697         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
698
699         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h: Don't include 
700             CachedResourceClient.h, it isn't needed.
701
702 2013-02-24  Kihong Kwon  <kihong.kwon@samsung.com>
703
704         Add an ASSERT to didChangeDeviceProximity
705         https://bugs.webkit.org/show_bug.cgi?id=110317
706
707         Reviewed by Hajime Morrita.
708
709         Add An ASSERT to didChangeDeviceProximity function to check range of value.
710
711         Change exist test cases.
712
713         * Modules/proximity/DeviceProximityController.cpp:
714         (WebCore::DeviceProximityController::didChangeDeviceProximity):
715
716 2013-02-24  Alexey Proskuryakov  <ap@apple.com>
717
718         Clarify meaning of default default encoding localizable string
719         https://bugs.webkit.org/show_bug.cgi?id=110714
720
721         Reviewed by Eric Carlson.
722
723         * English.lproj/Localizable.strings: This string is only used on Windows, and it's
724         very confusing to everyone involved.
725
726 2013-02-24  Mike West  <mkwst@chromium.org>
727
728         CSP 1.1: Experiment with 'reflected-xss' directive.
729         https://bugs.webkit.org/show_bug.cgi?id=104479
730
731         Reviewed by Adam Barth.
732
733         Content Security Policy 1.1 defines a 'reflected-xss' directive that
734         works in much the same way as WebKit's current 'X-XSS-Protection'
735         header[1]. This patch implements the new directive by parsing it
736         inside ContentSecurityPolicy, and exposing that state to XSSAuditor.
737
738         XSSAuditor now grabs the CSP directive's state, and mixes it with the
739         X-XSS-Protection header's state to determine how the page should be
740         handled. Moreover, both headers' states are now expressed in terms of
741         ContentSecurityPolicy::ReflectedXSSDisposition.
742
743         [1]: https://dvcs.w3.org/hg/content-security-policy/raw-file/tip/csp-specification.dev.html#reflected-xss--experimental
744
745         Tests: http/tests/security/contentSecurityPolicy/1.1/reflected-xss-allow.html
746                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-allow-allow.html
747                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-allow-block.html
748                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-allow-filter.html
749                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-allow-invalid.html
750                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-allow-unset.html
751                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-allow.html
752                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-block.html
753                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-filter.html
754                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-invalid.html
755                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-block-unset.html
756                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-allow.html
757                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-block.html
758                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-filter.html
759                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-invalid.html
760                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-filter-unset.html
761                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-allow.html
762                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-block.html
763                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-filter.html
764                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-invalid.html
765                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-invalid-unset.html
766                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-allow.html
767                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-block.html
768                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-filter.html
769                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-invalid.html
770                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-and-xss-protection-unset-unset.html
771                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-block.html
772                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-empty.html
773                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-filter.html
774                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-invalid.html
775                http/tests/security/contentSecurityPolicy/1.1/reflected-xss-parsing.html
776
777         * html/parser/XSSAuditor.cpp:
778         (WebCore::combineXSSProtectionHeaderAndCSP):
779             Given both headers' states, return the state which the XSSAuditor
780             should use when parsing a page. Blocking overrides filtering, which
781             overrides disabling.
782         (WebCore):
783         (WebCore::XSSAuditor::init):
784             Process the 'X-XSS-Protection' header before grabbing the CSP
785             header's state. Both are passed into the new
786             combineXSSProtectionHeaderAndCSP method to generate the final
787             state that ought to be used.
788         (WebCore::XSSAuditor::XSSAuditor):
789         (WebCore::XSSAuditor::filterToken):
790         * html/parser/XSSAuditor.h:
791             Switch to ContentSecurityPolicy::ReflectedXSSDisposition internally
792             in XSSAuditor.
793         * page/ContentSecurityPolicy.cpp:
794         (WebCore::CSPDirectiveList::reflectedXSSDisposition):
795             Enum defining the possible state of the 'reflected-xss' CSP directive.
796         (CSPDirectiveList):
797         (WebCore::CSPDirectiveList::CSPDirectiveList):
798         (WebCore::CSPDirectiveList::parseReflectedXSS):
799             Given a 'reflected-xss' directive's value, set the
800             ReflectedXSSDisposition into a new property on the CSPDirectiveList.
801         (WebCore):
802         (WebCore::CSPDirectiveList::addDirective):
803             Accept 'reflected-xss' as a valid directive if we're in
804             experimental mode.
805         (WebCore::ContentSecurityPolicy::reflectedXSSDisposition):
806             Expose the directive's state via the public API.
807         (WebCore::ContentSecurityPolicy::reportInvalidReflectedXSS):
808             Generate console errors when invalid reflected-xss directive values
809             are encounted during parsing.
810         * page/ContentSecurityPolicy.h:
811         * platform/network/HTTPParsers.cpp:
812         (WebCore::parseXSSProtectionHeader):
813         * platform/network/HTTPParsers.h:
814         (WebCore):
815             Start using ContentSecurityPolicy::ReflectedXSSDisposition rather
816             than the XSSProtectionDisposition enum.
817
818 2013-02-24  Zan Dobersek  <zdobersek@igalia.com>
819
820         Updating GObject bindings baselines after r143863.
821
822         Unreviewed.
823
824         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
825         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
826         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
827         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
828         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
829         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
830         * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
831         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
832         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
833         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
834         * bindings/scripts/test/GObject/WebKitDOMTestNode.cpp:
835         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
836         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.cpp:
837         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
838         * bindings/scripts/test/GObject/WebKitDOMTestTypedefs.cpp:
839
840 2013-02-24  Zan Dobersek  <zdobersek@igalia.com>
841
842         [GTK] Stop generating UserAgentGtk.h
843         https://bugs.webkit.org/show_bug.cgi?id=110582
844
845         Reviewed by Martin Robinson.
846
847         No new tests - no new functionality.
848
849         * GNUmakefile.list.am: Move the UserAgentGtk.h build target from the derived sources list to
850         the list of the WebCore platform sources.
851         * platform/gtk/UserAgentGtk.cpp:
852         (WebCore::standardUserAgent): Rename WEBKIT_USER_AGENT_(MAJOR|MINOR)_VERSION to
853         USER_AGENT_GTK_(MAJOR|MINOR)_VERSION.
854         * platform/gtk/UserAgentGtk.h: Renamed from Source/WebCore/platform/gtk/UserAgentGtk.h.in.
855         Same as the input file expect for removed WEBKIT_USER_AGENT_(MAJOR|MINOR)_VERSION defines that
856         are now replaced by using the USER_AGENT_GTK_(MAJOR|MINOR)_VERSION defines placed in autotoolsconfig.h.
857
858 2013-02-24  Gustavo Noronha Silva  <gns@gnome.org>
859
860         [GTK] GTK+ 2 build broken since GTK_API_VERSION_2 moved to autoconfig.h
861         https://bugs.webkit.org/show_bug.cgi?id=110702
862
863         Reviewed by Martin Robinson.
864
865         No tests. Build fix, no behaviour change.
866
867         * platform/gtk/GtkVersioning.h: include the autotoolsconfig.h header,
868         which contains the GTK_API_VERSION_2 define now.
869
870 2013-02-24  Andreas Kling  <akling@apple.com>
871
872         StyledElement: Don't expose a mutable direct interface to the inline style.
873         <http://webkit.org/b/110711>
874
875         Reviewed by Antti Koivisto.
876
877         Remove the ability to grab at a mutable StylePropertySet* for a StyledElement's inline style
878         from the outside world. It's now private and returns MutableStylePropertySet* for future convenience.
879
880         Three paths to changing the inline style remain:
881
882             - Setting the "style" attribute
883             - Via CSSOM (element.style)
884             - setInlineStyleProperty/removeInlineStyleProperty helpers
885
886         * dom/StyledElement.cpp:
887         (WebCore::StyledElement::ensureMutableInlineStyle):
888         * dom/StyledElement.h:
889         (StyledElement):
890         * editing/ApplyStyleCommand.cpp:
891         (WebCore::copyStyleOrCreateEmpty):
892         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
893         (WebCore::ApplyStyleCommand::removeEmbeddingUpToEnclosingBlock):
894         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
895         * editing/ReplaceSelectionCommand.cpp:
896         (WebCore::ReplaceSelectionCommand::handleStyleSpans):
897         * html/canvas/CanvasStyle.cpp:
898         (WebCore::currentColor):
899
900 2013-02-24  Keishi Hattori  <keishi@webkit.org>
901
902         Add methods to date types for new calendar picker
903         https://bugs.webkit.org/show_bug.cgi?id=110454
904
905         Reviewed by Kent Tamura.
906
907         Adding some methods to date types as part of the calendar picker redesign (Bug 109439).
908
909         Test: platform/chromium/fast/forms/calendar-picker/calendar-picker-date-types.html
910
911         * Resources/pagepopups/calendarPicker.js:
912         (createUTCDate):
913         (DateType): Base class for Day, Week and Month.
914         (Day): Simplified constructor to only accept year, month, date.
915         (Day.createFromValue): Creates a new Day from a value.
916         (Day.createFromDate): Throw an error if the given date is invalid.
917         (Day.createFromDay):
918         (Day.prototype.equals): Accept non Day objects.
919         (Day.prototype.previous): Modified to take an offset value.
920         (Day.prototype.next): Ditto.
921         (Day.prototype.firstDay): Returns the first day in the range. For Day's case, returns itself.
922         (Day.prototype.middleDay): Returns the middle day in the range. For Day's case, returns itself.
923         (Day.prototype.lastDay): Returns the middle day in the range. For Day's case, returns itself.
924         (Day.prototype.valueOf):
925         (Day.prototype.weekDay): Returns the week day.
926         (Week): Simplified constructor to only accept year, month, date.
927         (Week.createFromValue):
928         (Week.createFromDate):
929         (Week.createFromDay):
930         (Week.weekOneStartDateForYear):
931         (Week.weekOneStartDayForYear):
932         (Week._numberOfWeeksSinceDate):
933         (Week.prototype.equals):
934         (Week.prototype.previous):
935         (Week.prototype.next):
936         (Week.prototype.firstDay): Returns the first day in the week.
937         (Week.prototype.middleDay): Returns the the day for Thursday.
938         (Week.prototype.lastDay): Returns the last day in the week.
939         (Week.prototype.valueOf):
940         (Month):
941         (Month.createFromValue):
942         (Month.createFromDate):
943         (Month.createFromDay):
944         (Month.prototype.containsDay):
945         (Month.prototype.equals):
946         (Month.prototype.previous):
947         (Month.prototype.next):
948         (Month.prototype.firstDay): Returns the first day in the month.
949         (Month.prototype.middleDay): Returns the middle day in the month.
950         (Month.prototype.lastDay): Returns the last day in the month.
951         (Month.prototype.valueOf):
952         (Month.prototype.toLocaleString): Moved location.
953         (Month.prototype.toShortLocaleString): Returns the month string in short format.
954         (CalendarPicker): Use createFromValue.
955         (YearMonthController.prototype.setMonth): Ditto.
956         (YearMonthController.prototype.moveRelatively): Ditto.
957
958 2013-02-24  Hajime Morrita  <morrita@google.com>
959
960         [Custom Elements] Implement bare-bone document.register()
961         https://bugs.webkit.org/show_bug.cgi?id=100229
962
963         Reviewed by Adam Barth.
964
965         This change implements a prefixed version of document.register(), with minimal feature support.
966         - The feature is guarded by ENABLE(CUSTOM_ELEMENTS) and RuntimeEnabledFeatures::customDOMElementsEnabled().
967         - This bare-bone version only recognizes "name" and "prototype" parameters. It doesn't support default value of "prototype" parameter.
968         - Currently only V8 is supported. JSC binding needs its own binding implementation.
969
970         = Major new classes under dom/:
971
972         The dom module gets two new classes:
973         - CustomElementConstructor: A return value of document.register()
974           which holds the custom element definition.
975         - CustomElementRegistry: A collection of CustomElementConstructor objects.
976           CustomElementRegistry instance is created per Document and is owned by the Document.
977
978         CustomElementConstructor knows the definition of each custom
979         element, which is registered by document.register(). The name and
980         other options are held by this object. CustomElementRegistry owns a set
981         of the registered constructors. The registry guarantees invariants
982         like validity and uniqueness of the element names.
983
984         = A change on make_names.pl
985
986         This change tweaks make_names.pl (or generated HTMLElementFactory)
987         to hook the creations of unknown elements. Some of element names
988         which come to the fallback path can be one of registered custom
989         element.
990
991         = [V8WrapAsFunction] extended attribute:
992
993         The document.register() API returns a constructor
994         function. However, the V8 binding currently doesn't support it. To
995         make it possible, this change introduces "V8WrapAsFunction"
996         extended attribute for annotating CustomElementConstructor IDL
997         interface.
998
999         V8WrapAsFunction wraps the annotated interface with a JavaScript
1000         function, which calls the original object as a function, or as a
1001         constructor depends on the context.
1002
1003         With this wrapper function, there are two levels of indirection
1004         between native C++ object and author-visible JS function:
1005
1006         [JS Adaptor Function] <-(hidden property)-> [JS Wrapper Object] -(internal field)-> [C++ Native object]
1007
1008         The code generator generates the binding code which deals with
1009         this indirection.  Also, there is a set of helper functions in
1010         V8AdaptorFunction.h/cpp which takes care of this indirection.
1011         V8DOMWrapper.cpp/h works as a facade for these APIs and is used from
1012         the generated code.
1013
1014         This redundancy comes from limitations of both V8 bindings and V8
1015         embedding API. See bug 108138 for details.
1016
1017         = V8HTMLCustomElement
1018
1019         Unlike built-in HTML elements, any custom element has no
1020         corresponding C++ class. Instead, document.register() should allow
1021         passing a prototype object for the elements being registered.
1022
1023         V8HTMLCustomElement handles this lack of native class.  It behaves
1024         like a native side proxy of non-native HTMLElement subclasses.  It
1025         connects each custom element to an appropriate native element,
1026         which is HTMLElement at this time. This restriction will be
1027         relaxed later. See Bug 110436 for details.
1028
1029         = Custom DOM elements and multiple worlds
1030
1031         In this patch, custom element registration and instantiation is not allowed
1032         in non-main world and document.register() API just fails there.
1033
1034         Reviewed by Adam Barth.
1035
1036         Tests: fast/dom/custom/document-register-basic.html
1037                fast/dom/custom/document-register-reentrant-null-constructor.html
1038                fast/dom/custom/document-register-reentrant-returning-fake.html
1039                fast/dom/custom/document-register-reentrant-throwing-constructor.html
1040
1041         * DerivedSources.make:
1042         * WebCore.gypi:
1043         * bindings/generic/RuntimeEnabledFeatures.cpp:
1044         * bindings/generic/RuntimeEnabledFeatures.h:
1045         (RuntimeEnabledFeatures):
1046         (WebCore::RuntimeEnabledFeatures::customDOMElementsEnabled):
1047         (WebCore::RuntimeEnabledFeatures::setCustomDOMElements):
1048         * bindings/scripts/CodeGeneratorV8.pm:
1049         (GenerateHeader):
1050         * bindings/scripts/IDLAttributes.txt:
1051         * bindings/v8/CustomElementHelpers.cpp: Added.
1052         (WebCore::CustomElementHelpers::initializeConstructorWrapper):
1053         (WebCore::hasNoBuiltinsInPrototype):
1054         (WebCore::CustomElementHelpers::isValidPrototypeParameter):
1055         (WebCore::CustomElementHelpers::isFeatureAllowed):
1056         * bindings/v8/CustomElementHelpers.h: Copied from Source/WebCore/bindings/v8/V8HiddenPropertyName.h.
1057         (CustomElementHelpers):
1058         * bindings/v8/V8AdaptorFunction.cpp: Added.
1059         (WebCore::V8AdaptorFunction::getTemplate):
1060         (WebCore::V8AdaptorFunction::configureTemplate):
1061         (WebCore::V8AdaptorFunction::invocationCallback):
1062         (WebCore::V8AdaptorFunction::wrap):
1063         * bindings/v8/V8AdaptorFunction.h: Added.
1064         (V8AdaptorFunction):
1065         (WebCore::V8AdaptorFunction::unwrap):
1066         (WebCore::V8AdaptorFunction::get):
1067         * bindings/v8/V8DOMConfiguration.cpp:
1068         (WebCore::V8DOMConfiguration::configureTemplate):
1069         * bindings/v8/V8DOMWrapper.cpp:
1070         (WebCore::V8DOMWrapper::toFunction):
1071         (WebCore::V8DOMWrapper::fromFunction):
1072         * bindings/v8/V8DOMWrapper.h:
1073         (V8DOMWrapper):
1074         * bindings/v8/V8HTMLCustomElement.cpp: Added.
1075         (WebCore::V8HTMLCustomElement::createWrapper):
1076         * bindings/v8/V8HTMLCustomElement.h: Copied from Source/WebCore/bindings/v8/V8HiddenPropertyName.h.
1077         (V8HTMLCustomElement):
1078         (WebCore::V8HTMLCustomElement::toV8):
1079         (WebCore::HTMLCustomElement::toV8):
1080         * bindings/v8/V8HiddenPropertyName.h:
1081         * bindings/v8/custom/V8CustomElementConstructorCustom.cpp: Added.
1082         (WebCore::V8CustomElementConstructor::callAsFunctionCallback):
1083         * dom/CustomElementConstructor.cpp: Copied from Source/WebCore/bindings/v8/V8HiddenPropertyName.h.
1084         (WebCore::CustomElementConstructor::create):
1085         (WebCore::CustomElementConstructor::CustomElementConstructor):
1086         (WebCore::CustomElementConstructor::~CustomElementConstructor):
1087         (WebCore::CustomElementConstructor::createElement):
1088         * dom/CustomElementConstructor.h: Copied from Source/WebCore/bindings/v8/V8HiddenPropertyName.h.
1089         (CustomElementConstructor):
1090         (WebCore::CustomElementConstructor::document):
1091         (WebCore::CustomElementConstructor::tagName):
1092         (WebCore::CustomElementConstructor::name):
1093         * dom/CustomElementConstructor.idl: Added.
1094         * dom/CustomElementRegistry.cpp: Added.
1095         (WebCore::CustomElementRegistry::CustomElementRegistry):
1096         (WebCore::CustomElementRegistry::~CustomElementRegistry):
1097         (WebCore::CustomElementRegistry::constructorOf):
1098         (WebCore::CustomElementRegistry::isValidName):
1099         (WebCore::CustomElementRegistry::registerElement):
1100         (WebCore::CustomElementRegistry::find):
1101         (WebCore::CustomElementRegistry::createElement):
1102         (WebCore::CustomElementRegistry::document):
1103         * dom/CustomElementRegistry.h: Added.
1104         (CustomElementRegistry):
1105         * dom/Document.cpp:
1106         (WebCore::Document::removedLastRef):
1107         (WebCore::Document::registerElement):
1108         (WebCore::Document::registry):
1109         * dom/Document.h:
1110         (Document):
1111         * dom/make_names.pl:
1112         (printWrapperFactoryCppFile):
1113         * html/HTMLDocument.idl:
1114
1115 2013-02-24  Eugene Klyuchnikov  <eustas@chromium.org>
1116
1117         Web Inspector: [Timeline] Shrink CPU bars to make it easier to see frame information popup.
1118         https://bugs.webkit.org/show_bug.cgi?id=110561
1119
1120         Reviewed by Pavel Feldman.
1121
1122         Area that causes frame information popup is overly "shaded" by CPU bars.
1123
1124         * inspector/front-end/timelinePanel.css:
1125         (.timeline-cpu-bars .timeline-graph-bar): Reduce height and opacity.
1126
1127 2013-02-24  Andreas Kling  <akling@apple.com>
1128
1129         Reduce include graph of JSDOMBinding.h
1130         <http://webkit.org/b/110709>
1131
1132         Reviewed by Antti Koivisto.
1133
1134         Move WebCore::root(Foo*) to the custom JSFooCustom.h headers.
1135         This reduces the number of headers pulled in by JSDOMBinding.h.
1136
1137         * WebCore.xcodeproj/project.pbxproj:
1138         * bindings/js/JSCSSRuleCustom.cpp:
1139         * bindings/js/JSCSSRuleCustom.h: Added.
1140         (WebCore::root):
1141         * bindings/js/JSCSSRuleListCustom.cpp:
1142         * bindings/js/JSCSSStyleDeclarationCustom.h:
1143         (WebCore::root):
1144         * bindings/js/JSDOMBinding.h:
1145         * bindings/js/JSMediaListCustom.h: Added.
1146         (WebCore::root):
1147         * bindings/js/JSMutationObserverCustom.cpp:
1148         * bindings/js/JSNodeCustom.h:
1149         (WebCore::root):
1150         * bindings/js/JSSVGElementInstanceCustom.cpp:
1151         * bindings/js/JSStyleSheetCustom.h: Added.
1152         (WebCore::root):
1153         * bindings/js/JSTextTrackCustom.h:
1154         * bindings/js/JSTextTrackListCustom.cpp:
1155         * bindings/js/JSXPathResultCustom.cpp:
1156         * bindings/js/SerializedScriptValue.cpp:
1157         * bindings/scripts/CodeGeneratorGObject.pm:
1158         (Generate):
1159         * bindings/scripts/CodeGeneratorJS.pm:
1160         (GenerateImplementation):
1161         * bindings/scripts/CodeGeneratorObjC.pm:
1162         (AddIncludesForType):
1163         * css/CSSRule.idl:
1164         * css/CSSStyleDeclaration.idl:
1165         * css/MediaList.idl:
1166         * css/StyleSheet.idl:
1167         * editing/mac/EditorMac.mm:
1168
1169 2013-02-23  Alexey Proskuryakov  <ap@apple.com>
1170
1171         ResourceRequestBase unnecessarily updates when nothing changes
1172         https://bugs.webkit.org/show_bug.cgi?id=110665
1173
1174         Reviewed by Dan Bernstein.
1175
1176         Don't mark platform data for update if nothing really changed. This avoids ever doing
1177         doUpdatePlatformRequest() in NetworkProcess during normal browsing for me, which is
1178         good for performance.
1179
1180         * platform/network/ResourceRequestBase.cpp:
1181         (WebCore::ResourceRequestBase::removeCredentials):
1182         (WebCore::ResourceRequestBase::setCachePolicy):
1183         (WebCore::ResourceRequestBase::setTimeoutInterval):
1184         (WebCore::ResourceRequestBase::setFirstPartyForCookies):
1185         (WebCore::ResourceRequestBase::setHTTPMethod):
1186         (WebCore::ResourceRequestBase::clearHTTPAuthorization):
1187         (WebCore::ResourceRequestBase::setAllowCookies):
1188         (WebCore::ResourceRequestBase::setPriority):
1189
1190 2013-02-23  Philip Rogers  <pdr@google.com>
1191
1192         Prevent crash in animated transform lists
1193         https://bugs.webkit.org/show_bug.cgi?id=110704
1194
1195         Reviewed by Abhishek Arya.
1196
1197         This change prevents accessing values off the end of toAtEndOfDuration by adding a check
1198         for this case. Similar checks were added in r116458 but the author failed to catch this
1199         case. WK110706 has been filed to handle this case in general.
1200
1201         This change also makes a trivial change that marks effectiveFrom as const.
1202
1203         Test: svg/animations/animateTransform-list-crash.html
1204
1205         * svg/SVGAnimatedTransformList.cpp:
1206         (WebCore::SVGAnimatedTransformListAnimator::calculateAnimatedValue):
1207
1208 2013-02-23  Dimitri Glazkov  <dglazkov@chromium.org>
1209
1210         SelectorChecker should not know about SelectorCheckerFastPath.
1211         https://bugs.webkit.org/show_bug.cgi?id=110663
1212
1213         Both SelectorChecker and it's speedy cousin unfortunately include each other.
1214         Luckily, the particular way in which SelectorQuery uses SelectorChecker yields
1215         to a fairly simple decoupling. Now only the cousin knows of SelectorChecker.
1216
1217         Reviewed by Antti Koivisto.
1218
1219         No new functionality, covered by existing tests.
1220
1221         * css/SelectorChecker.cpp:
1222         (WebCore::SelectorChecker::matches): Removed.
1223         * css/SelectorChecker.h:
1224         (SelectorChecker): Updated the decls to remove fast-path flag.
1225         * dom/SelectorQuery.cpp:
1226         (WebCore::SelectorDataList::selectorMatches): Added a helper just for SelectorQuery.
1227         (WebCore::SelectorDataList::matches): Changed the callsite to use new helper.
1228         (WebCore::SelectorDataList::execute): Ditto.
1229         * dom/SelectorQuery.h:
1230         (SelectorDataList): Updated decls.
1231
1232 2013-02-23  Eric Carlson  <eric.carlson@apple.com>
1233
1234         [Mac] user preference caption style applied incorrectly
1235         https://bugs.webkit.org/show_bug.cgi?id=110707
1236         <rdar://problem/13281096>
1237
1238         Reviewed by Maciej Stachowiak.
1239
1240         * html/shadow/MediaControlElements.cpp:
1241         (WebCore::MediaControlTextTrackContainerElement::textTrackContainerElementShadowPseudoId): New
1242             static function so the pseudo ID is available.
1243         (WebCore::MediaControlTextTrackContainerElement::shadowPseudoId): Call textTrackContainerElementShadowPseudoId.
1244         * html/shadow/MediaControlElements.h:
1245
1246         * page/CaptionUserPreferencesMac.mm:
1247         (WebCore::CaptionUserPreferencesMac::captionsStyleSheetOverride): Style the text track container
1248             element for cue color, edge style, and font name.
1249
1250 2013-02-22  Kentaro Hara  <haraken@chromium.org>
1251
1252         [V8] Generate xxxAttrGetterCallback()
1253         https://bugs.webkit.org/show_bug.cgi?id=110676
1254
1255         Reviewed by Adam Barth.
1256
1257         This is one of steps to insert TRACE_EVENT_STATE() macros
1258         into DOM bindings. This patch introduces an indirection
1259         function for xxxAttrGetter(), like this:
1260
1261         // For non-custom getters
1262         Handle<Value> xxxAttrGetterCallback(...) {
1263           return xxxAttrGetter(...);
1264         }
1265
1266         // For custom getters.
1267         Handle<Value> xxxAttrGetterCallback(...) {
1268           return xxxAttrGetterCustom(...);
1269         }
1270
1271         No tests. No change in behavior.
1272
1273         * bindings/scripts/CodeGeneratorV8.pm:
1274         (GenerateDomainSafeFunctionGetter):
1275         (GenerateNormalAttrGetterCallback):
1276         (GenerateNormalAttrGetter):
1277         (GenerateSingleBatchedAttribute):
1278         (GenerateNonStandardFunction):
1279         (GenerateImplementation):
1280         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1281         (WebCore::TestActiveDOMObjectV8Internal::excitingAttrAttrGetterCallback):
1282         (TestActiveDOMObjectV8Internal):
1283         (WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetterCallback):
1284         (WebCore):
1285         (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
1286         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
1287         (WebCore::TestEventConstructorV8Internal::attr1AttrGetterCallback):
1288         (TestEventConstructorV8Internal):
1289         (WebCore::TestEventConstructorV8Internal::attr2AttrGetterCallback):
1290         (WebCore):
1291         * bindings/scripts/test/V8/V8TestException.cpp:
1292         (WebCore::TestExceptionV8Internal::nameAttrGetterCallback):
1293         (TestExceptionV8Internal):
1294         (WebCore):
1295         * bindings/scripts/test/V8/V8TestInterface.cpp:
1296         (WebCore::TestInterfaceV8Internal::supplementalStaticReadOnlyAttrAttrGetterCallback):
1297         (TestInterfaceV8Internal):
1298         (WebCore::TestInterfaceV8Internal::supplementalStaticAttrAttrGetterCallback):
1299         (WebCore::TestInterfaceV8Internal::supplementalStr1AttrGetterCallback):
1300         (WebCore::TestInterfaceV8Internal::supplementalStr2AttrGetterCallback):
1301         (WebCore::TestInterfaceV8Internal::supplementalStr3AttrGetterCallback):
1302         (WebCore::TestInterfaceV8Internal::supplementalNodeAttrGetterCallback):
1303         (WebCore):
1304         * bindings/scripts/test/V8/V8TestObj.cpp:
1305         (WebCore::TestObjV8Internal::readOnlyLongAttrAttrGetterCallback):
1306         (TestObjV8Internal):
1307         (WebCore::TestObjV8Internal::readOnlyStringAttrAttrGetterCallback):
1308         (WebCore::TestObjV8Internal::readOnlyTestObjAttrAttrGetterCallback):
1309         (WebCore::TestObjV8Internal::staticReadOnlyLongAttrAttrGetterCallback):
1310         (WebCore::TestObjV8Internal::staticStringAttrAttrGetterCallback):
1311         (WebCore::TestObjV8Internal::enumAttrAttrGetterCallback):
1312         (WebCore::TestObjV8Internal::shortAttrAttrGetterCallback):
1313         (WebCore::TestObjV8Internal::unsignedShortAttrAttrGetterCallback):
1314         (WebCore::TestObjV8Internal::longAttrAttrGetterCallback):
1315         (WebCore::TestObjV8Internal::longLongAttrAttrGetterCallback):
1316         (WebCore::TestObjV8Internal::unsignedLongLongAttrAttrGetterCallback):
1317         (WebCore::TestObjV8Internal::stringAttrAttrGetterCallback):
1318         (WebCore::TestObjV8Internal::testObjAttrAttrGetter):
1319         (WebCore::TestObjV8Internal::testObjAttrAttrGetterCallback):
1320         (WebCore::TestObjV8Internal::XMLObjAttrAttrGetterCallback):
1321         (WebCore::TestObjV8Internal::createAttrGetterCallback):
1322         (WebCore::TestObjV8Internal::reflectedStringAttrAttrGetterCallback):
1323         (WebCore::TestObjV8Internal::reflectedIntegralAttrAttrGetterCallback):
1324         (WebCore::TestObjV8Internal::reflectedUnsignedIntegralAttrAttrGetterCallback):
1325         (WebCore::TestObjV8Internal::reflectedBooleanAttrAttrGetterCallback):
1326         (WebCore::TestObjV8Internal::reflectedURLAttrAttrGetterCallback):
1327         (WebCore::TestObjV8Internal::reflectedCustomIntegralAttrAttrGetterCallback):
1328         (WebCore::TestObjV8Internal::reflectedCustomBooleanAttrAttrGetterCallback):
1329         (WebCore::TestObjV8Internal::reflectedCustomURLAttrAttrGetterCallback):
1330         (WebCore::TestObjV8Internal::typedArrayAttrAttrGetterCallback):
1331         (WebCore::TestObjV8Internal::attrWithGetterExceptionAttrGetterCallback):
1332         (WebCore::TestObjV8Internal::attrWithSetterExceptionAttrGetterCallback):
1333         (WebCore::TestObjV8Internal::stringAttrWithGetterExceptionAttrGetterCallback):
1334         (WebCore::TestObjV8Internal::stringAttrWithSetterExceptionAttrGetterCallback):
1335         (WebCore::TestObjV8Internal::customAttrAttrGetterCallback):
1336         (WebCore::TestObjV8Internal::withScriptStateAttributeAttrGetterCallback):
1337         (WebCore::TestObjV8Internal::withScriptExecutionContextAttributeAttrGetterCallback):
1338         (WebCore::TestObjV8Internal::withScriptStateAttributeRaisesAttrGetterCallback):
1339         (WebCore::TestObjV8Internal::withScriptExecutionContextAttributeRaisesAttrGetterCallback):
1340         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateAttributeAttrGetterCallback):
1341         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateAttributeRaisesAttrGetterCallback):
1342         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateWithSpacesAttributeAttrGetterCallback):
1343         (WebCore::TestObjV8Internal::withScriptArgumentsAndCallStackAttributeAttrGetterCallback):
1344         (WebCore::TestObjV8Internal::conditionalAttr1AttrGetterCallback):
1345         (WebCore::TestObjV8Internal::conditionalAttr2AttrGetterCallback):
1346         (WebCore::TestObjV8Internal::conditionalAttr3AttrGetterCallback):
1347         (WebCore::TestObjV8Internal::cachedAttribute1AttrGetterCallback):
1348         (WebCore::TestObjV8Internal::cachedAttribute2AttrGetterCallback):
1349         (WebCore::TestObjV8Internal::anyAttributeAttrGetterCallback):
1350         (WebCore::TestObjV8Internal::enabledAtRuntimeAttr1AttrGetterCallback):
1351         (WebCore::TestObjV8Internal::enabledAtRuntimeAttr2AttrGetterCallback):
1352         (WebCore::TestObjV8Internal::enabledPerContextAttr1AttrGetterCallback):
1353         (WebCore::TestObjV8Internal::enabledPerContextAttr2AttrGetterCallback):
1354         (WebCore::TestObjV8Internal::floatArrayAttrGetterCallback):
1355         (WebCore::TestObjV8Internal::doubleArrayAttrGetterCallback):
1356         (WebCore::TestObjV8Internal::contentDocumentAttrGetterCallback):
1357         (WebCore::TestObjV8Internal::mutablePointAttrGetterCallback):
1358         (WebCore::TestObjV8Internal::immutablePointAttrGetterCallback):
1359         (WebCore::TestObjV8Internal::strawberryAttrGetterCallback):
1360         (WebCore::TestObjV8Internal::strictFloatAttrGetterCallback):
1361         (WebCore::TestObjV8Internal::descriptionAttrGetterCallback):
1362         (WebCore::TestObjV8Internal::idAttrGetterCallback):
1363         (WebCore::TestObjV8Internal::hashAttrGetterCallback):
1364         (WebCore::TestObjV8Internal::replaceableAttributeAttrGetterCallback):
1365         (WebCore):
1366         (WebCore::ConfigureV8TestObjTemplate):
1367         (WebCore::V8TestObj::installPerContextProperties):
1368         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1369         (WebCore::TestSerializedScriptValueInterfaceV8Internal::valueAttrGetterCallback):
1370         (TestSerializedScriptValueInterfaceV8Internal):
1371         (WebCore::TestSerializedScriptValueInterfaceV8Internal::readonlyValueAttrGetterCallback):
1372         (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedValueAttrGetterCallback):
1373         (WebCore::TestSerializedScriptValueInterfaceV8Internal::portsAttrGetterCallback):
1374         (WebCore::TestSerializedScriptValueInterfaceV8Internal::cachedReadonlyValueAttrGetterCallback):
1375         (WebCore):
1376         * bindings/scripts/test/V8/V8TestTypedefs.cpp:
1377         (WebCore::TestTypedefsV8Internal::unsignedLongLongAttrAttrGetterCallback):
1378         (TestTypedefsV8Internal):
1379         (WebCore::TestTypedefsV8Internal::immutableSerializedScriptValueAttrGetterCallback):
1380         (WebCore::TestTypedefsV8Internal::attrWithGetterExceptionAttrGetterCallback):
1381         (WebCore::TestTypedefsV8Internal::attrWithSetterExceptionAttrGetterCallback):
1382         (WebCore::TestTypedefsV8Internal::stringAttrWithGetterExceptionAttrGetterCallback):
1383         (WebCore::TestTypedefsV8Internal::stringAttrWithSetterExceptionAttrGetterCallback):
1384         (WebCore):
1385
1386 2013-02-23  Kentaro Hara  <haraken@chromium.org>
1387
1388         WebCore fails to link in Chromium official build
1389         https://bugs.webkit.org/show_bug.cgi?id=110701
1390
1391         Reviewed by Abhishek Arya.
1392
1393         This is a follow-up fix for r143853. In WebCore.gyp, we need to
1394         increase the shard of 'webcore_rendering' as well.
1395
1396         No tests. No change in behavior.
1397
1398         * WebCore.gyp/WebCore.gyp:
1399
1400 2013-02-23  Kentaro Hara  <haraken@chromium.org>
1401
1402         Unreviewed, rolling out r143844.
1403         http://trac.webkit.org/changeset/143844
1404         https://bugs.webkit.org/show_bug.cgi?id=110241
1405
1406         It broke Chromium Mac Release Build
1407
1408         * WebCore.gyp/WebCore.gyp:
1409         * WebCore.gyp/WebCoreGTK.gyp: Removed.
1410         * WebCore.gypi:
1411
1412 2013-02-23  Adam Barth  <abarth@webkit.org>
1413
1414         WebCore fails to link in Chromium official build
1415         https://bugs.webkit.org/show_bug.cgi?id=110697
1416
1417         Reviewed by Eric Seidel.
1418
1419         Apparently we need to use more shards to work around linker limitations
1420         on Windows again.
1421
1422         * WebCore.gyp/WebCore.gyp:
1423
1424 2013-02-23  Kentaro Hara  <haraken@chromium.org>
1425
1426         [V8] Rename constructorCallbackCustom() to constructorCustom()
1427         https://bugs.webkit.org/show_bug.cgi?id=110671
1428
1429         Reviewed by Adam Barth.
1430
1431         his is one of steps to insert TRACE_EVENT_STATE() macros
1432         into DOM bindings.
1433         See https://bugs.webkit.org/show_bug.cgi?id=110667#c0
1434
1435         In the new world, "Callback" is used to indicate that it
1436         is a function called back by V8. Currently "Callback" is
1437         used for both V8 callbacks, DOM methods and DOM constructors.
1438         This patch fixes the inconsistency.
1439
1440         No tests. No change in behavior.
1441
1442         * bindings/scripts/CodeGeneratorV8.pm:
1443         (GenerateHeader):
1444         (GenerateCustomConstructorCallback):
1445         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
1446         (WebCore::V8ArrayBuffer::constructorCustom):
1447         * bindings/v8/custom/V8AudioContextCustom.cpp:
1448         (WebCore::V8AudioContext::constructorCustom):
1449         * bindings/v8/custom/V8BlobCustom.cpp:
1450         (WebCore::V8Blob::constructorCustom):
1451         * bindings/v8/custom/V8DOMFormDataCustom.cpp:
1452         (WebCore::V8DOMFormData::constructorCustom):
1453         * bindings/v8/custom/V8DataViewCustom.cpp:
1454         (WebCore::V8DataView::constructorCustom):
1455         * bindings/v8/custom/V8MessageChannelCustom.cpp:
1456         (WebCore::V8MessageChannel::constructorCustom):
1457         * bindings/v8/custom/V8MutationObserverCustom.cpp:
1458         (WebCore::V8MutationObserver::constructorCustom):
1459         * bindings/v8/custom/V8WebKitPointCustom.cpp:
1460         (WebCore::V8WebKitPoint::constructorCustom):
1461         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
1462         (WebCore::V8XMLHttpRequest::constructorCustom):
1463
1464 2013-02-23  Kentaro Hara  <haraken@chromium.org>
1465
1466         [V8] Rename xxxCallback() to xxxMethod(), and xxxCallbackCustom() to xxxMethodCustom()
1467         https://bugs.webkit.org/show_bug.cgi?id=110669
1468
1469         Reviewed by Adam Barth.
1470
1471         This is one of steps to insert TRACE_EVENT_STATE()
1472         macros into DOM bindings.
1473         See https://bugs.webkit.org/show_bug.cgi?id=110667#c0
1474
1475         In the new world, "Callback" is used to refer that it
1476         is a function called back by V8. Currently "Callback" is
1477         used for both V8 callbacks, DOM methods and DOM constructors.
1478         This patch fixes the inconsistency.
1479
1480         No tests. No change in behavior.
1481
1482         * bindings/scripts/CodeGeneratorV8.pm:
1483         (GenerateHeader):
1484         (GenerateDomainSafeFunctionGetter):
1485         (GenerateOverloadedFunctionCallback):
1486         (GenerateFunctionCallback):
1487         (GenerateNonStandardFunction):
1488         (GenerateImplementation):
1489         * bindings/scripts/test/V8/V8Float64Array.cpp:
1490         (WebCore::Float64ArrayV8Internal::fooMethod):
1491         (WebCore::Float64ArrayV8Internal::setMethod):
1492         (WebCore):
1493         (WebCore::ConfigureV8Float64ArrayTemplate):
1494         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1495         (WebCore::TestActiveDOMObjectV8Internal::excitingFunctionMethod):
1496         (WebCore::TestActiveDOMObjectV8Internal::postMessageMethod):
1497         (WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
1498         (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
1499         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
1500         (WebCore::TestCustomNamedGetterV8Internal::anotherFunctionMethod):
1501         (WebCore):
1502         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1503         (WebCore::TestEventTargetV8Internal::itemMethod):
1504         (WebCore::TestEventTargetV8Internal::addEventListenerMethod):
1505         (WebCore::TestEventTargetV8Internal::removeEventListenerMethod):
1506         (WebCore::TestEventTargetV8Internal::dispatchEventMethod):
1507         (WebCore):
1508         (WebCore::ConfigureV8TestEventTargetTemplate):
1509         * bindings/scripts/test/V8/V8TestInterface.cpp:
1510         (WebCore::TestInterfaceV8Internal::supplementalMethod1Method):
1511         (WebCore::TestInterfaceV8Internal::supplementalMethod2Method):
1512         (WebCore::TestInterfaceV8Internal::supplementalMethod3Method):
1513         (WebCore::TestInterfaceV8Internal::supplementalMethod4Method):
1514         (WebCore):
1515         (WebCore::ConfigureV8TestInterfaceTemplate):
1516         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1517         (WebCore::TestMediaQueryListListenerV8Internal::methodMethod):
1518         (WebCore):
1519         * bindings/scripts/test/V8/V8TestObj.cpp:
1520         (WebCore::TestObjV8Internal::voidMethodMethod):
1521         (WebCore::TestObjV8Internal::voidMethodWithArgsMethod):
1522         (WebCore::TestObjV8Internal::longMethodMethod):
1523         (WebCore::TestObjV8Internal::longMethodWithArgsMethod):
1524         (WebCore::TestObjV8Internal::objMethodMethod):
1525         (WebCore::TestObjV8Internal::objMethodWithArgsMethod):
1526         (WebCore::TestObjV8Internal::methodWithSequenceArgMethod):
1527         (WebCore::TestObjV8Internal::methodReturningSequenceMethod):
1528         (WebCore::TestObjV8Internal::methodThatRequiresAllArgsAndThrowsMethod):
1529         (WebCore::TestObjV8Internal::serializedValueMethod):
1530         (WebCore::TestObjV8Internal::optionsObjectMethod):
1531         (WebCore::TestObjV8Internal::methodWithExceptionMethod):
1532         (WebCore::TestObjV8Internal::customMethodMethod):
1533         (WebCore::TestObjV8Internal::customMethodWithArgsMethod):
1534         (WebCore::TestObjV8Internal::addEventListenerMethod):
1535         (WebCore::TestObjV8Internal::removeEventListenerMethod):
1536         (WebCore::TestObjV8Internal::withScriptStateVoidMethod):
1537         (WebCore::TestObjV8Internal::withScriptStateObjMethod):
1538         (WebCore::TestObjV8Internal::withScriptStateVoidExceptionMethod):
1539         (WebCore::TestObjV8Internal::withScriptStateObjExceptionMethod):
1540         (WebCore::TestObjV8Internal::withScriptExecutionContextMethod):
1541         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateMethod):
1542         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateObjExceptionMethod):
1543         (WebCore::TestObjV8Internal::withScriptExecutionContextAndScriptStateWithSpacesMethod):
1544         (WebCore::TestObjV8Internal::withScriptArgumentsAndCallStackMethod):
1545         (WebCore::TestObjV8Internal::methodWithOptionalArgMethod):
1546         (WebCore::TestObjV8Internal::methodWithNonOptionalArgAndOptionalArgMethod):
1547         (WebCore::TestObjV8Internal::methodWithNonOptionalArgAndTwoOptionalArgsMethod):
1548         (WebCore::TestObjV8Internal::methodWithOptionalStringMethod):
1549         (WebCore::TestObjV8Internal::methodWithOptionalStringIsUndefinedMethod):
1550         (WebCore::TestObjV8Internal::methodWithOptionalStringIsNullStringMethod):
1551         (WebCore::TestObjV8Internal::methodWithCallbackArgMethod):
1552         (WebCore::TestObjV8Internal::methodWithNonCallbackArgAndCallbackArgMethod):
1553         (WebCore::TestObjV8Internal::methodWithCallbackAndOptionalArgMethod):
1554         (WebCore::TestObjV8Internal::conditionalMethod1Method):
1555         (WebCore::TestObjV8Internal::conditionalMethod2Method):
1556         (WebCore::TestObjV8Internal::conditionalMethod3Method):
1557         (WebCore::TestObjV8Internal::overloadedMethod1Method):
1558         (WebCore::TestObjV8Internal::overloadedMethod2Method):
1559         (WebCore::TestObjV8Internal::overloadedMethod3Method):
1560         (WebCore::TestObjV8Internal::overloadedMethod4Method):
1561         (WebCore::TestObjV8Internal::overloadedMethod5Method):
1562         (WebCore::TestObjV8Internal::overloadedMethod6Method):
1563         (WebCore::TestObjV8Internal::overloadedMethod7Method):
1564         (WebCore::TestObjV8Internal::overloadedMethod8Method):
1565         (WebCore::TestObjV8Internal::overloadedMethod9Method):
1566         (WebCore::TestObjV8Internal::overloadedMethod10Method):
1567         (WebCore::TestObjV8Internal::overloadedMethod11Method):
1568         (WebCore::TestObjV8Internal::overloadedMethodMethod):
1569         (WebCore::TestObjV8Internal::classMethodMethod):
1570         (WebCore::TestObjV8Internal::classMethodWithOptionalMethod):
1571         (WebCore::TestObjV8Internal::classMethod2Method):
1572         (WebCore::TestObjV8Internal::overloadedMethod12Method):
1573         (WebCore::TestObjV8Internal::classMethodWithClampMethod):
1574         (WebCore::TestObjV8Internal::enabledAtRuntimeMethod1Method):
1575         (WebCore::TestObjV8Internal::enabledAtRuntimeMethod2Method):
1576         (WebCore::TestObjV8Internal::enabledPerContextMethod1Method):
1577         (WebCore::TestObjV8Internal::enabledPerContextMethod2Method):
1578         (WebCore::TestObjV8Internal::stringArrayFunctionMethod):
1579         (WebCore::TestObjV8Internal::domStringListFunctionMethod):
1580         (WebCore::TestObjV8Internal::getSVGDocumentMethod):
1581         (WebCore::TestObjV8Internal::convert1Method):
1582         (WebCore::TestObjV8Internal::convert2Method):
1583         (WebCore::TestObjV8Internal::convert4Method):
1584         (WebCore::TestObjV8Internal::convert5Method):
1585         (WebCore::TestObjV8Internal::mutablePointFunctionMethod):
1586         (WebCore::TestObjV8Internal::immutablePointFunctionMethod):
1587         (WebCore::TestObjV8Internal::orangeMethod):
1588         (WebCore::TestObjV8Internal::strictFunctionMethod):
1589         (WebCore::TestObjV8Internal::variadicStringMethodMethod):
1590         (WebCore::TestObjV8Internal::variadicDoubleMethodMethod):
1591         (WebCore::TestObjV8Internal::variadicNodeMethodMethod):
1592         (WebCore):
1593         (WebCore::ConfigureV8TestObjTemplate):
1594         (WebCore::V8TestObj::installPerContextPrototypeProperties):
1595         * bindings/scripts/test/V8/V8TestObj.h:
1596         (V8TestObj):
1597         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1598         (WebCore::TestSerializedScriptValueInterfaceV8Internal::acceptTransferListMethod):
1599         (WebCore::TestSerializedScriptValueInterfaceV8Internal::multiTransferListMethod):
1600         (WebCore):
1601         * bindings/scripts/test/V8/V8TestTypedefs.cpp:
1602         (WebCore::TestTypedefsV8Internal::funcMethod):
1603         (WebCore::TestTypedefsV8Internal::multiTransferListMethod):
1604         (WebCore::TestTypedefsV8Internal::setShadowMethod):
1605         (WebCore::TestTypedefsV8Internal::methodWithSequenceArgMethod):
1606         (WebCore::TestTypedefsV8Internal::nullableArrayArgMethod):
1607         (WebCore::TestTypedefsV8Internal::funcWithClampMethod):
1608         (WebCore::TestTypedefsV8Internal::immutablePointFunctionMethod):
1609         (WebCore::TestTypedefsV8Internal::stringArrayFunctionMethod):
1610         (WebCore::TestTypedefsV8Internal::stringArrayFunction2Method):
1611         (WebCore::TestTypedefsV8Internal::methodWithExceptionMethod):
1612         (WebCore):
1613         (WebCore::ConfigureV8TestTypedefsTemplate):
1614         * bindings/v8/custom/V8ClipboardCustom.cpp:
1615         (WebCore::V8Clipboard::clearDataMethodCustom):
1616         (WebCore::V8Clipboard::setDragImageMethodCustom):
1617         * bindings/v8/custom/V8ConsoleCustom.cpp:
1618         (WebCore::V8Console::traceMethodCustom):
1619         (WebCore::V8Console::assertMethodCustom):
1620         (WebCore::V8Console::profileMethodCustom):
1621         (WebCore::V8Console::profileEndMethodCustom):
1622         * bindings/v8/custom/V8CryptoCustom.cpp:
1623         (WebCore::V8Crypto::getRandomValuesMethodCustom):
1624         * bindings/v8/custom/V8DOMFormDataCustom.cpp:
1625         (WebCore::V8DOMFormData::appendMethodCustom):
1626         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1627         (WebCore::V8DOMWindow::addEventListenerMethodCustom):
1628         (WebCore::V8DOMWindow::removeEventListenerMethodCustom):
1629         (WebCore::V8DOMWindow::postMessageMethodCustom):
1630         (WebCore::V8DOMWindow::toStringMethodCustom):
1631         (WebCore::V8DOMWindow::releaseEventsMethodCustom):
1632         (WebCore::V8DOMWindow::captureEventsMethodCustom):
1633         (WebCore::V8DOMWindow::showModalDialogMethodCustom):
1634         (WebCore::V8DOMWindow::openMethodCustom):
1635         (WebCore::V8DOMWindow::setTimeoutMethodCustom):
1636         (WebCore::V8DOMWindow::setIntervalMethodCustom):
1637         * bindings/v8/custom/V8DataViewCustom.cpp:
1638         (WebCore::V8DataView::getInt8MethodCustom):
1639         (WebCore::V8DataView::getUint8MethodCustom):
1640         (WebCore::V8DataView::setInt8MethodCustom):
1641         (WebCore::V8DataView::setUint8MethodCustom):
1642         * bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
1643         (WebCore::V8DedicatedWorkerContext::postMessageMethodCustom):
1644         * bindings/v8/custom/V8DeviceMotionEventCustom.cpp:
1645         (WebCore::V8DeviceMotionEvent::initDeviceMotionEventMethodCustom):
1646         * bindings/v8/custom/V8DeviceOrientationEventCustom.cpp:
1647         (WebCore::V8DeviceOrientationEvent::initDeviceOrientationEventMethodCustom):
1648         * bindings/v8/custom/V8DocumentCustom.cpp:
1649         (WebCore::V8Document::evaluateMethodCustom):
1650         (WebCore::V8Document::createTouchListMethodCustom):
1651         * bindings/v8/custom/V8GeolocationCustom.cpp:
1652         (WebCore::V8Geolocation::getCurrentPositionMethodCustom):
1653         (WebCore::V8Geolocation::watchPositionMethodCustom):
1654         * bindings/v8/custom/V8HTMLAllCollectionCustom.cpp:
1655         (WebCore::V8HTMLAllCollection::itemMethodCustom):
1656         (WebCore::V8HTMLAllCollection::namedItemMethodCustom):
1657         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
1658         (WebCore::V8HTMLCanvasElement::getContextMethodCustom):
1659         (WebCore::V8HTMLCanvasElement::toDataURLMethodCustom):
1660         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
1661         (WebCore::V8HTMLDocument::writeMethodCustom):
1662         (WebCore::V8HTMLDocument::writelnMethodCustom):
1663         (WebCore::V8HTMLDocument::openMethodCustom):
1664         * bindings/v8/custom/V8HTMLFormControlsCollectionCustom.cpp:
1665         (WebCore::V8HTMLFormControlsCollection::namedItemMethodCustom):
1666         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
1667         (WebCore::v8HTMLImageElementConstructorMethodCustom):
1668         (WebCore::V8HTMLImageElementConstructor::GetTemplate):
1669         * bindings/v8/custom/V8HTMLInputElementCustom.cpp:
1670         (WebCore::V8HTMLInputElement::setSelectionRangeMethodCustom):
1671         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
1672         (WebCore::V8HTMLOptionsCollection::namedItemMethodCustom):
1673         (WebCore::V8HTMLOptionsCollection::removeMethodCustom):
1674         (WebCore::V8HTMLOptionsCollection::addMethodCustom):
1675         * bindings/v8/custom/V8HTMLSelectElementCustom.cpp:
1676         (WebCore::V8HTMLSelectElement::removeMethodCustom):
1677         * bindings/v8/custom/V8HistoryCustom.cpp:
1678         (WebCore::V8History::pushStateMethodCustom):
1679         (WebCore::V8History::replaceStateMethodCustom):
1680         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1681         (WebCore::V8InjectedScriptHost::inspectedObjectMethodCustom):
1682         (WebCore::V8InjectedScriptHost::internalConstructorNameMethodCustom):
1683         (WebCore::V8InjectedScriptHost::isHTMLAllCollectionMethodCustom):
1684         (WebCore::V8InjectedScriptHost::typeMethodCustom):
1685         (WebCore::V8InjectedScriptHost::functionDetailsMethodCustom):
1686         (WebCore::V8InjectedScriptHost::getInternalPropertiesMethodCustom):
1687         (WebCore::V8InjectedScriptHost::getEventListenersMethodCustom):
1688         (WebCore::V8InjectedScriptHost::inspectMethodCustom):
1689         (WebCore::V8InjectedScriptHost::databaseIdMethodCustom):
1690         (WebCore::V8InjectedScriptHost::storageIdMethodCustom):
1691         (WebCore::V8InjectedScriptHost::evaluateMethodCustom):
1692         (WebCore::V8InjectedScriptHost::setFunctionVariableValueMethodCustom):
1693         * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp:
1694         (WebCore::V8InspectorFrontendHost::platformMethodCustom):
1695         (WebCore::V8InspectorFrontendHost::portMethodCustom):
1696         (WebCore::V8InspectorFrontendHost::showContextMenuMethodCustom):
1697         (WebCore::V8InspectorFrontendHost::recordActionTakenMethodCustom):
1698         (WebCore::V8InspectorFrontendHost::recordPanelShownMethodCustom):
1699         (WebCore::V8InspectorFrontendHost::recordSettingChangedMethodCustom):
1700         * bindings/v8/custom/V8JavaScriptCallFrameCustom.cpp:
1701         (WebCore::V8JavaScriptCallFrame::evaluateMethodCustom):
1702         (WebCore::V8JavaScriptCallFrame::restartMethodCustom):
1703         (WebCore::V8JavaScriptCallFrame::setVariableValueMethodCustom):
1704         (WebCore::V8JavaScriptCallFrame::scopeTypeMethodCustom):
1705         * bindings/v8/custom/V8LocationCustom.cpp:
1706         (WebCore::V8Location::reloadAttrGetterCustom):
1707         (WebCore::V8Location::replaceAttrGetterCustom):
1708         (WebCore::V8Location::assignAttrGetterCustom):
1709         (WebCore::V8Location::reloadMethodCustom):
1710         (WebCore::V8Location::replaceMethodCustom):
1711         (WebCore::V8Location::assignMethodCustom):
1712         (WebCore::V8Location::valueOfMethodCustom):
1713         (WebCore::V8Location::toStringMethodCustom):
1714         * bindings/v8/custom/V8MessageEventCustom.cpp:
1715         (WebCore::V8MessageEvent::initMessageEventMethodCustom):
1716         (WebCore::V8MessageEvent::webkitInitMessageEventMethodCustom):
1717         * bindings/v8/custom/V8MessagePortCustom.cpp:
1718         (WebCore::V8MessagePort::postMessageMethodCustom):
1719         * bindings/v8/custom/V8NodeCustom.cpp:
1720         (WebCore::V8Node::insertBeforeMethodCustom):
1721         (WebCore::V8Node::replaceChildMethodCustom):
1722         (WebCore::V8Node::removeChildMethodCustom):
1723         (WebCore::V8Node::appendChildMethodCustom):
1724         * bindings/v8/custom/V8NotificationCenterCustom.cpp:
1725         (WebCore::V8NotificationCenter::requestPermissionMethodCustom):
1726         * bindings/v8/custom/V8NotificationCustom.cpp:
1727         (WebCore::V8Notification::requestPermissionMethodCustom):
1728         * bindings/v8/custom/V8SQLResultSetRowListCustom.cpp:
1729         (WebCore::V8SQLResultSetRowList::itemMethodCustom):
1730         * bindings/v8/custom/V8SQLTransactionCustom.cpp:
1731         (WebCore::V8SQLTransaction::executeSqlMethodCustom):
1732         * bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
1733         (WebCore::V8SQLTransactionSync::executeSqlMethodCustom):
1734         * bindings/v8/custom/V8SVGLengthCustom.cpp:
1735         (WebCore::V8SVGLength::convertToSpecifiedUnitsMethodCustom):
1736         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
1737         (WebCore::V8WebGLRenderingContext::getAttachedShadersMethodCustom):
1738         (WebCore::V8WebGLRenderingContext::getBufferParameterMethodCustom):
1739         (WebCore::V8WebGLRenderingContext::getExtensionMethodCustom):
1740         (WebCore::V8WebGLRenderingContext::getFramebufferAttachmentParameterMethodCustom):
1741         (WebCore::V8WebGLRenderingContext::getParameterMethodCustom):
1742         (WebCore::V8WebGLRenderingContext::getProgramParameterMethodCustom):
1743         (WebCore::V8WebGLRenderingContext::getRenderbufferParameterMethodCustom):
1744         (WebCore::V8WebGLRenderingContext::getShaderParameterMethodCustom):
1745         (WebCore::V8WebGLRenderingContext::getSupportedExtensionsMethodCustom):
1746         (WebCore::V8WebGLRenderingContext::getTexParameterMethodCustom):
1747         (WebCore::V8WebGLRenderingContext::getUniformMethodCustom):
1748         (WebCore::V8WebGLRenderingContext::getVertexAttribMethodCustom):
1749         (WebCore::V8WebGLRenderingContext::uniform1fvMethodCustom):
1750         (WebCore::V8WebGLRenderingContext::uniform1ivMethodCustom):
1751         (WebCore::V8WebGLRenderingContext::uniform2fvMethodCustom):
1752         (WebCore::V8WebGLRenderingContext::uniform2ivMethodCustom):
1753         (WebCore::V8WebGLRenderingContext::uniform3fvMethodCustom):
1754         (WebCore::V8WebGLRenderingContext::uniform3ivMethodCustom):
1755         (WebCore::V8WebGLRenderingContext::uniform4fvMethodCustom):
1756         (WebCore::V8WebGLRenderingContext::uniform4ivMethodCustom):
1757         (WebCore::V8WebGLRenderingContext::uniformMatrix2fvMethodCustom):
1758         (WebCore::V8WebGLRenderingContext::uniformMatrix3fvMethodCustom):
1759         (WebCore::V8WebGLRenderingContext::uniformMatrix4fvMethodCustom):
1760         (WebCore::V8WebGLRenderingContext::vertexAttrib1fvMethodCustom):
1761         (WebCore::V8WebGLRenderingContext::vertexAttrib2fvMethodCustom):
1762         (WebCore::V8WebGLRenderingContext::vertexAttrib3fvMethodCustom):
1763         (WebCore::V8WebGLRenderingContext::vertexAttrib4fvMethodCustom):
1764         * bindings/v8/custom/V8WorkerContextCustom.cpp:
1765         (WebCore::V8WorkerContext::importScriptsMethodCustom):
1766         (WebCore::V8WorkerContext::setTimeoutMethodCustom):
1767         (WebCore::V8WorkerContext::setIntervalMethodCustom):
1768         * bindings/v8/custom/V8WorkerCustom.cpp:
1769         (WebCore::V8Worker::postMessageMethodCustom):
1770         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
1771         (WebCore::V8XMLHttpRequest::openMethodCustom):
1772         (WebCore::V8XMLHttpRequest::sendMethodCustom):
1773         * bindings/v8/custom/V8XSLTProcessorCustom.cpp:
1774         (WebCore::V8XSLTProcessor::setParameterMethodCustom):
1775         (WebCore::V8XSLTProcessor::getParameterMethodCustom):
1776         (WebCore::V8XSLTProcessor::removeParameterMethodCustom):
1777
1778 2013-02-23  Dimitri Glazkov  <dglazkov@chromium.org>
1779
1780         Scrollbar style resolution arguments should not passed via statics.
1781         https://bugs.webkit.org/show_bug.cgi?id=110690
1782
1783         Use PseudoStyleRequest to pass scrollbar params for style resolve.
1784
1785         Reviewed by Eric Seidel.
1786
1787         No change in functionality, covered by existing tests.
1788
1789         * css/SelectorChecker.cpp:
1790         (WebCore::SelectorChecker::match): Changed to use context params, rather than statics.
1791         (WebCore::SelectorChecker::checkOne): Changed to pass context to checkScrollbarPseudoClass.
1792         (WebCore::SelectorChecker::checkScrollbarPseudoClass): Changed to use context params, rather than statics.
1793         * css/SelectorChecker.h:
1794         (WebCore::SelectorChecker::SelectorCheckingContext::SelectorCheckingContext): Added scrollbar style args.
1795         (SelectorCheckingContext): Ditto.
1796         * css/StyleResolver.cpp:
1797         (WebCore::StyleResolver::collectMatchingRulesForList): Changed to use PseudoStyleRequest.
1798         (WebCore::StyleResolver::State::initForStyleResolve): Ditto.
1799         (WebCore::StyleResolver::pseudoStyleForElement): Ditto.
1800         (WebCore::StyleResolver::ruleMatches): Ditto and added stuffing scrollbar style resolve args into SelectorCheckingContext.
1801         * css/StyleResolver.h:
1802         (PseudoStyleRequest): Added.
1803         (State): Changed to hold and use PseudoStyleRequest instead of just PseudoId
1804         * dom/Element.cpp:
1805         (WebCore::Element::pseudoStyleCacheIsInvalid): Changed to use PseudoStyleRequest.
1806         * page/FrameView.cpp: Ditto.
1807         (WebCore::FrameView::updateScrollCorner): Ditto.
1808         * rendering/RenderLayer.cpp:
1809         (WebCore::RenderLayer::updateScrollCornerStyle): Ditto.
1810         (WebCore::RenderLayer::updateResizerStyle): Ditto.
1811         * rendering/RenderObject.cpp:
1812         (WebCore::RenderObject::selectionBackgroundColor): Ditto.
1813         (WebCore::RenderObject::selectionColor): Ditto.
1814         (WebCore::firstLineStyleForCachedUncachedType): Ditto.
1815         (WebCore::RenderObject::getCachedPseudoStyle): Ditto.
1816         (WebCore::RenderObject::getUncachedPseudoStyle): Ditto.
1817         * rendering/RenderObject.h:
1818         (RenderObject): Ditto.
1819         * rendering/RenderScrollbar.cpp:
1820         (WebCore::RenderScrollbar::getScrollbarPseudoStyle): Ditto.
1821         * rendering/RenderScrollbar.h:
1822         (RenderScrollbar): Removed static members that are now obsolete.
1823
1824 2013-02-23  Adam Barth  <abarth@webkit.org>
1825
1826         Threaded HTML parser should pass fast/parser/parser-yield-timing.html
1827         https://bugs.webkit.org/show_bug.cgi?id=110647
1828
1829         Reviewed by Eric Seidel.
1830
1831         Previously, the threaded HTML parser would run for an arbitrary amount
1832         of time without yielding after speculation succeeded. This might be the
1833         cause of the good DOMContentLoaded numbers.
1834
1835         Note: This patch also demonstrates that the ParseHTML_max numbers
1836         aren't correct currently because they're measuring the interior of this
1837         loop instead of all the time spent in the loop. We should move the
1838         instrumentation in a followup patch.
1839
1840          * html/parser/HTMLDocumentParser.cpp:
1841         (WebCore::HTMLDocumentParser::resumeParsingAfterYield):
1842         (WebCore::HTMLDocumentParser::pumpPendingSpeculations):
1843         (WebCore):
1844         (WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution):
1845         * html/parser/HTMLDocumentParser.h:
1846         (HTMLDocumentParser):
1847         * html/parser/HTMLParserScheduler.cpp:
1848
1849 2013-02-23  Martin Robinson  <mrobinson@igalia.com>
1850
1851         [GTK] Allow sharing the WebCore include list with the Chromium build
1852         https://bugs.webkit.org/show_bug.cgi?id=110241
1853
1854         Reviewed by Dirk Pranke.
1855
1856         * WebCore.gyp/WebCore.gyp: Moved shared include directories to
1857         WebCore.gypi.
1858         * WebCore.gyp/WebCoreGTK.gyp: Added. A skeleton gyp file for WebCoreGTK+.
1859         * WebCore.gypi: Added shared include directories.
1860
1861 2013-02-23  Andreas Kling  <akling@apple.com>
1862
1863         StyledElement: Tweak signature of collectStyleForPresentationAttribute().
1864         <http://webkit.org/b/110687>
1865
1866         Reviewed by Antti Koivisto.
1867
1868         Out with the old:
1869             collectStyleForPresentationAttribute(const Attribute&, StylePropertySet*)
1870
1871         In with the new:
1872             collectStyleForPresentationAttribute(const QualifiedName&, const AtomicString&, MutableStylePropertySet*)
1873
1874         This is primarily about switching to using MutableStylePropertySet* in preparation for
1875         removing mutating functions from the StylePropertySet base class.
1876
1877 2013-02-23  Kondapally Kalyan  <kalyan.kondapally@intel.com>
1878
1879         [EFL][WebGL] Refactor GLPlatformSurface.
1880         https://bugs.webkit.org/show_bug.cgi?id=110616
1881
1882         Reviewed by Kenneth Rohde Christiansen.
1883
1884         Covered by existing WebGL tests.
1885  
1886         With recent changes, there is a clear separation between 
1887         transport surface and off-screen surface. PlatformSurface 
1888         has the logic to render content to transport surface. 
1889         We currently rely on EXT_framebuffer_blit for this. This 
1890         extension is not exposed on GLES2.0. PlatformSurface was 
1891         supposed to be an abstraction layer without any knowledge 
1892         of the type of surface. This patch addresses the issues 
1893         in PlatformSurface class. We use shaders to draw texture 
1894         content to the surface. Any transport surface related 
1895         code in PlatformSurface is moved to GLTransportSurface class.
1896
1897         * PlatformEfl.cmake:
1898         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
1899         (WebCore::GraphicsContext3DPrivate::didResizeCanvas):
1900         * platform/graphics/surfaces/GLTransportSurface.cpp: Added.
1901         (WebCore):
1902         (WebCore::GLTransportSurface::GLTransportSurface):
1903         (WebCore::GLTransportSurface::~GLTransportSurface):
1904         (WebCore::GLTransportSurface::updateContents):
1905         (WebCore::GLTransportSurface::setGeometry):
1906         (WebCore::GLTransportSurface::destroy):
1907         (WebCore::GLTransportSurface::draw):
1908         (WebCore::GLTransportSurface::bindArrayBuffer):
1909         (WebCore::GLTransportSurface::updateTransformationMatrix):
1910         (WebCore::GLTransportSurface::initializeShaderProgram):
1911         * platform/graphics/surfaces/GLTransportSurface.h:
1912         (WebCore):
1913         (GLTransportSurface):
1914         * platform/graphics/surfaces/egl/EGLSurface.cpp:
1915         (WebCore::EGLWindowTransportSurface::EGLWindowTransportSurface):
1916         (WebCore::EGLWindowTransportSurface::destroy):
1917         (WebCore::EGLWindowTransportSurface::setGeometry):
1918         * platform/graphics/surfaces/egl/EGLSurface.h:
1919         * platform/graphics/surfaces/glx/GLXSurface.cpp:
1920         (WebCore::GLXTransportSurface::GLXTransportSurface):
1921         (WebCore::GLXTransportSurface::setGeometry):
1922         (WebCore::GLXTransportSurface::destroy):
1923         (WebCore::GLXOffScreenSurface::freeResources):
1924         * platform/graphics/surfaces/glx/GLXSurface.h:
1925
1926 2013-02-23  Hajime Morrita  <morrita@google.com>
1927
1928         ShadowRoot needs guardRef() and guardDeref()
1929         https://bugs.webkit.org/show_bug.cgi?id=109777
1930
1931         Reviewed by Dimitri Glazkov.
1932
1933         This change moves m_guardRefCount from Document to TreeScope,
1934         which allows ShadowRoot to be guarded by guardRef() mechanism as
1935         Document. After r137524, Node referes TreeScope instead of
1936         Document. This is natural consequence of the change: It no longer
1937         makes sense to guardRef() Document pointer from Node.
1938
1939         Detail:
1940
1941         - Document::m_guardRefCount and related funcdtions are moved to TreeScope
1942         - Document::removedLastRef is factored out into TreeScope::removedLastRefToScope(),
1943           TreeScope::dispose() and Docuent::dispose(). ShadowRoot also got its own dispose() implementation.
1944         - Moved guardRef() and guardDeref() calls to TreeScope and Node.
1945           Note that there are two "guarded" TreeScope references. One is
1946           Node::m_treeScope and another is TreeScope::m_parentTreeScope.
1947           The guarded-ref management is now encapsulated in these two classes.
1948
1949         No new tests. Covered by existing tests.
1950
1951         * WebCore.exp.in:
1952         * dom/Document.cpp:
1953         (WebCore::Document::Document):
1954         (WebCore::Document::~Document):
1955         (WebCore::Document::dispose): Extracted from removedLastRef()
1956         * dom/Document.h:
1957         (WebCore::Node::isTreeScope):
1958         (WebCore::Node::Node):
1959         * dom/DocumentFragment.cpp:
1960         (WebCore::DocumentFragment::DocumentFragment): Remove ASSERT() and move it to ...
1961         (WebCore::DocumentFragment::create): ... here, to allow NULL document from ShadowRoot.
1962         * dom/Node.cpp:
1963         (WebCore::Node::~Node):
1964         (WebCore::Node::removedLastRef):
1965         * dom/Node.h:
1966         (WebCore::Node::setTreeScope):
1967         * dom/ShadowRoot.cpp:
1968         (WebCore::ShadowRoot::ShadowRoot): Passed NULL document to superclass. This aligns what Document is doing.
1969         (WebCore::ShadowRoot::dispose): Added.
1970         * dom/ShadowRoot.h:
1971         (ShadowRoot):
1972         * dom/TreeScope.cpp:
1973         (SameSizeAsTreeScope):
1974         (WebCore::TreeScope::TreeScope):
1975         (WebCore::TreeScope::~TreeScope):
1976         (WebCore::TreeScope::dispose): Added.
1977         (WebCore::TreeScope::setParentTreeScope):
1978         (WebCore::TreeScope::deletionHasBegun):
1979         (WebCore::TreeScope::beginDeletion):
1980         (WebCore::TreeScope::refCount): Added.
1981         * dom/TreeScope.h: Turned m_rootNode to Node* from ContainerNode* for Node::isTreeScope to be inlined.
1982         (WebCore::TreeScope::guardRef): Pulled up from Document.
1983         (WebCore::TreeScope::guardDeref): Ditto.
1984         (WebCore::TreeScope::hasGuardRefCount): Added to hide m_guardRefCount.
1985         (WebCore::TreeScope::deletionHasBegun): Added.
1986         (WebCore::TreeScope::beginDeletion): Added.
1987         (WebCore::TreeScope::removedLastRefToScope): Pulled up from Document.
1988         * dom/TreeScopeAdopter.cpp:
1989         (WebCore::TreeScopeAdopter::moveTreeToNewScope):
1990         (WebCore::TreeScopeAdopter::moveNodeToNewDocument):
1991
1992 2013-02-23  Alexey Proskuryakov  <ap@apple.com>
1993
1994         Don't include ResourceHandle.h in ResourceLoaderOptions.h
1995         https://bugs.webkit.org/show_bug.cgi?id=110662
1996
1997         Reviewed by Tim Horton.
1998
1999         * loader/ResourceLoaderOptions.h: Include ResourceHandleTypes.h instead.
2000
2001 2013-02-23  Jason Anderssen  <janderssen@gmail.com>
2002
2003         Move setAutofilled from TestRunner to WebCore
2004         https://bugs.webkit.org/show_bug.cgi?id=110521
2005
2006         Reviewed by Benjamin Poulain.
2007
2008         * testing/Internals.cpp:
2009         (WebCore):
2010         (WebCore::Internals::setAutofilled):
2011         * testing/Internals.h:
2012         (Internals):
2013         * testing/Internals.idl:
2014
2015 2013-02-22  Andreas Kling  <akling@apple.com>
2016
2017         Attr: Simplify modification callbacks.
2018         <http://webkit.org/b/110598>
2019
2020         Reviewed by Antti Koivisto.
2021
2022         Instead of Attr being a friend of Element and grabbing at various internal storage and callbacks,
2023         let Attr simply call Element::setAttribute() when its value is changed, and do all that business
2024         from Element.
2025
2026         * dom/Element.h:
2027         * dom/Element.cpp:
2028         (WebCore::Element::setAttributeInternal):
2029
2030             Call Attr::recreateTextChildAfterAttributeValueChanged() after modifying an attribute value instead
2031             of doing the modification through the Attr node.
2032
2033         * dom/Attr.h:
2034         * dom/Attr.cpp:
2035         (WebCore::Attr::Attr):
2036         (WebCore::Attr::childrenChanged):
2037
2038             Added an m_inChildrenChanged flag so we can prevent infinite callback recursion in childrenChanged().
2039
2040         (WebCore::Attr::setValue):
2041
2042             Call Element::setAttribute() instead of modifying the attribute storage directly.
2043
2044         (WebCore::Attr::recreateTextChildAfterAttributeValueChanged):
2045
2046             Factored out the "remove all children / create a new text child with attribute value" logic into
2047             a separate function.
2048
2049 2013-02-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2050
2051         [EFL] Use EINA_LOG instead of fprintf 
2052         https://bugs.webkit.org/show_bug.cgi?id=110313
2053
2054         Reviewed by Laszlo Gombos.
2055
2056         Replace fprintf with EINA_LOG.
2057
2058         * platform/efl/NetworkInfoProviderEfl.cpp:
2059         (WebCore::NetworkInfoProviderEfl::startUpdating):
2060         * platform/graphics/efl/CairoUtilitiesEfl.cpp:
2061         (WebCore::evasObjectFromCairoImageSurface):
2062
2063 2013-02-22  Tony Gentilcore  <tonyg@chromium.org>
2064
2065         Threaded HTML parser fails resources/plain-text-unsafe.dat
2066         https://bugs.webkit.org/show_bug.cgi?id=110538
2067
2068         Reviewed by Eric Seidel.
2069
2070         With this patch, the background HTML parser passes all tests in plain-text-unsafe.dat.
2071
2072         No new tests because covered by existing tests.
2073
2074         * html/parser/BackgroundHTMLParser.cpp:
2075         (WebCore::tokenExitsSVG):
2076         (WebCore):
2077         (WebCore::tokenExitsMath):
2078         (WebCore::BackgroundHTMLParser::simulateTreeBuilder):
2079
2080 2013-02-22  Tony Gentilcore  <tonyg@chromium.org>
2081
2082         Correct InspectorInstrumentation for background HTML parser
2083         https://bugs.webkit.org/show_bug.cgi?id=110678
2084
2085         Reviewed by Adam Barth.
2086
2087         resumeParsingAfterScriptExecution potentially calls processParsedChunkFromBackgroundParser multiple times
2088         without yielding. So it is not correct to count each of those as a separate ParseHTML event.
2089
2090         This patch moves the instrumentation outside of the loop.
2091
2092         No new tests because no new functionality.
2093
2094         * html/parser/HTMLDocumentParser.cpp:
2095         (WebCore::HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser):
2096         (WebCore::HTMLDocumentParser::processParsedChunkFromBackgroundParser):
2097         (WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution):
2098
2099 2013-02-22  Aaron Colwell  <acolwell@chromium.org>
2100
2101         Factor MediaSource methods out of MediaPlayer & MediaPlayerPrivate and into a new MediaSourcePrivate interface.
2102         https://bugs.webkit.org/show_bug.cgi?id=109857
2103
2104         Reviewed by Adam Barth.
2105
2106         This is a simple refactor that moves MediaSource related methods out of MediaPlayer & MediaPlayerPrivate
2107         so that the MediaSource implementation can be updated without further polluting these interfaces.
2108         MediaSourcePrivate is the new WebCore interface that ports must implement to support the MediaSource API.
2109
2110         No new tests. No user visible behavior has changed.
2111
2112         * Modules/mediasource/MediaSource.cpp:
2113         (WebCore::MediaSource::MediaSource):
2114         (WebCore::MediaSource::duration):
2115         (WebCore::MediaSource::setDuration):
2116         (WebCore::MediaSource::addSourceBuffer):
2117         (WebCore::MediaSource::removeSourceBuffer):
2118         (WebCore::MediaSource::setReadyState):
2119         (WebCore::MediaSource::endOfStream):
2120         (WebCore::MediaSource::buffered):
2121         (WebCore::MediaSource::append):
2122         (WebCore::MediaSource::abort):
2123         (WebCore::MediaSource::setTimestampOffset):
2124         (WebCore::MediaSource::setPrivateAndOpen):
2125         (WebCore):
2126         (WebCore::MediaSource::hasPendingActivity):
2127         (WebCore::MediaSource::stop):
2128         * Modules/mediasource/MediaSource.h:
2129         (MediaSource):
2130         * html/HTMLMediaElement.cpp:
2131         (WebCore::HTMLMediaElement::HTMLMediaElement):
2132         (WebCore::HTMLMediaElement::loadResource):
2133         (WebCore::HTMLMediaElement::createMediaPlayer):
2134         (WebCore::HTMLMediaElement::reportMemoryUsage):
2135         * html/HTMLMediaElement.h:
2136         (HTMLMediaElement):
2137         * platform/graphics/MediaPlayer.cpp:
2138         (NullMediaPlayerPrivate):
2139         (WebCore::NullMediaPlayerPrivate::load):
2140         (WebCore::MediaPlayer::load):
2141         (WebCore):
2142         (WebCore::MediaPlayer::loadWithNextMediaEngine):
2143         * platform/graphics/MediaPlayer.h:
2144         (WebCore):
2145         (MediaPlayerClient):
2146         (MediaPlayer):
2147         * platform/graphics/MediaPlayerPrivate.h:
2148         (MediaPlayerPrivateInterface):
2149         * platform/graphics/MediaSourcePrivate.h: Added.
2150         (WebCore):
2151         (MediaSourcePrivate): Contains the MediaSource methods extracted from MediaPlayer.
2152         (WebCore::MediaSourcePrivate::MediaSourcePrivate):
2153         (WebCore::MediaSourcePrivate::~MediaSourcePrivate):
2154
2155 2013-02-22  Beth Dakin  <bdakin@apple.com>
2156
2157         RenderLayer::scrollTo() should call FrameLoaderClient::didChangeScrollOffset()
2158         https://bugs.webkit.org/show_bug.cgi?id=110673
2159         -and corresponding-
2160         <rdar://problem/13258596>
2161
2162         Reviewed by Sam Weinig.
2163
2164         FrameLoaderClient::didChangeScrollOffset() doesn't get called for web pages that
2165         have overflow on the body. We can easily address this by calling it at the 
2166         end of RenderLayer::scrollTo().
2167
2168         * rendering/RenderLayer.cpp:
2169         (WebCore::RenderLayer::scrollTo):
2170
2171 2013-02-22  Ryosuke Niwa  <rniwa@webkit.org>
2172
2173         WebKit can erroneously strip font-size CSS property from font element with size attribute
2174         https://bugs.webkit.org/show_bug.cgi?id=110657
2175
2176         Reviewed by Justin Garcia.
2177
2178         The bug was caused by ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline
2179         erroneously removing style attributes even on an element such as font that implicitly adds
2180         editing style.
2181
2182         Fixed the bug by removing these elements or attributes when they conflict with the inline
2183         style of the element. This is always safe because implicit style of an element is always
2184         overridden by that of inline style.
2185
2186         Note that when the font element becomes "empty" (i.e. doesn't have any attributes), then
2187         we also want to delete this font element as it doesn't contribute anything to the style.
2188
2189         Test: editing/pasteboard/insert-u-with-text-decoration-none.html
2190               editing/pasteboard/insert-font-with-size-and-css.html
2191
2192         * editing/ApplyStyleCommand.cpp:
2193         (WebCore::isEmptyFontTag): Added ShouldStyleAttributeBeEmpty as an argument. This will
2194         allow removeRedundantStylesAndKeepStyleSpanInline to ignore style attribute when we know
2195         the attribute can be removed.
2196
2197         * editing/ApplyStyleCommand.h: Expose isEmptyFontTag and ShouldStyleAttributeBeEmpty.
2198
2199         * editing/ReplaceSelectionCommand.cpp:
2200         (WebCore::ReplaceSelectionCommand::InsertedNodes::didReplaceNode): Added.
2201         (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline): See above.
2202         * editing/ReplaceSelectionCommand.h:
2203         (InsertedNodes): Added a declaration of didReplaceNode.
2204
2205 2013-02-22  Laszlo Gombos  <l.gombos@samsung.com>
2206
2207         Remove unused make variable from DerivedSources.make
2208         https://bugs.webkit.org/show_bug.cgi?id=110306
2209
2210         Reviewed by Alexey Proskuryakov.
2211
2212         r107026 removed the last piece of logic that was guarded with
2213         ENABLE_DASHBOARD_SUPPORT, so now it can be removed from
2214         DerivedSources.make. 
2215
2216         Also combined the way ENABLE_ORIENTATION_EVENTS is set to 0
2217         to make it more readable.
2218
2219         No new tests, no new functionality.
2220
2221         * DerivedSources.make:
2222
2223 2013-02-22  Dimitri Glazkov  <dglazkov@chromium.org>
2224
2225         REGRESSION(r130089): Scrollbar thumb no longer re-rendered on hover
2226         https://bugs.webkit.org/show_bug.cgi?id=109230
2227
2228         In r130089, I accidentally removed the extra check that made scrollbar
2229         parts styles sad. I put it back and made them happy.
2230
2231         Reviewed by Eric Seidel.
2232
2233         Test: fast/css/pseudo-element-selector-scrollbar-hover.html
2234
2235         * css/SelectorChecker.cpp:
2236         (WebCore::SelectorChecker::match): Added the check back.
2237
2238 2013-02-22  Tim Horton  <timothy_horton@apple.com>
2239
2240         [WK2] The root and page overlay layers should be the size of the view, not the content
2241         https://bugs.webkit.org/show_bug.cgi?id=110660
2242         <rdar://problem/13096456>
2243
2244         Reviewed by Simon Fraser.
2245
2246         * WebCore.exp.in:
2247
2248 2013-02-22  Anders Carlsson  <andersca@apple.com>
2249
2250         pluginLoadStrategy should take a WKDictionaryRef for extensibility
2251         https://bugs.webkit.org/show_bug.cgi?id=110656
2252         <rdar://problem/13265303>
2253
2254         Reviewed by Jessie Berlin.
2255
2256         Export a symbol needed by WebKit2.
2257
2258         * WebCore.exp.in:
2259
2260 2013-02-22  Levi Weintraub  <leviw@chromium.org>
2261
2262         Add descriptive names for different addMidpoint use cases
2263         https://bugs.webkit.org/show_bug.cgi?id=110644
2264
2265         Reviewed by Ryosuke Niwa.
2266
2267         Midpoints are used to delineate ranges where we don't add line boxes for contents (collapsed spaces),
2268         and to explicitly split a RenderText into multiple text runs so that text paragraph seperators get
2269         their own line boxes. This patch encapsulates the different cases where midpoints are added to
2270         lineMidpointState into 4 helper functions to make it clearer what's going on in each case.
2271
2272         No new tests. No change in functionality.
2273
2274         * rendering/RenderBlockLineLayout.cpp:
2275         (WebCore::deprecatedAddMidpoint): Original function simply adds a midpoint to the lineMidpointState.
2276         Renaming to deprecated to discourage callers.
2277         (WebCore::startIgnoringSpaces): Adds a midpoint to start collapsing subsequent spaces. Asserts that
2278         we have an even number of midpoints.
2279         (WebCore::stopIgnoringSpaces): Adds the corresponding midpoint from startIgnoringSpaces and asserts
2280         that it's an odd number.
2281         (WebCore::ensureLineBoxInsideIgnoredSpaces): When ignoring spaces and we come across a RenderInline
2282         that needs a line box, this function adds a pair of midpoints which ensures we'll later add a line
2283         box for it.
2284         (WebCore::ensureCharacterGetsLineBox): Adds a pair of midpoints in a text renderer to mark that
2285         the current character needs its own line box. This is used by svg for absolutely positioned
2286         characters, or for text paragraph seperators.
2287
2288 2013-02-22  Justin Schuh  <jschuh@chromium.org>
2289
2290         RenderArena masking has low entropy
2291         https://bugs.webkit.org/show_bug.cgi?id=110394
2292
2293         Reviewed by Oliver Hunt.
2294
2295         No new tests. This is a hardening measure.
2296
2297         * rendering/RenderArena.cpp:
2298         (WebCore::RenderArena::RenderArena):
2299
2300 2013-02-22  Min Qin  <qinmin@chromium.org>
2301
2302         Fix the overlay play button position on android
2303         https://bugs.webkit.org/show_bug.cgi?id=110638
2304
2305         Reviewed by Ojan Vafai.
2306
2307         Because we are using flex box, specifying the height is not necessary.
2308         Setting height to 100% will make the enclosure go outside the control panel.
2309         There are no media layout test expecations for android, will do that in another patch.
2310
2311         * css/mediaControlsChromiumAndroid.css:
2312         (video::-webkit-media-controls-overlay-enclosure):
2313
2314 2013-02-22  Kentaro Hara  <haraken@chromium.org>
2315
2316         Unreviewed build fix. Added missing #if PLATFORM(CHROMIUM).
2317
2318         * dom/Document.cpp:
2319         (WebCore::Document::recalcStyle):
2320         * page/FrameView.cpp:
2321         (WebCore::FrameView::layout):
2322
2323 2013-02-22  Kentaro Hara  <haraken@chromium.org>
2324
2325         Document::styleRecalc() and FrameView::layout() should be traced
2326         https://bugs.webkit.org/show_bug.cgi?id=110646
2327
2328         Reviewed by Ojan Vafai.
2329
2330         Document::styleRecalc() and FrameView::layout() are key factors
2331         for web page rendering performance. We should add TRACE_EVENT()
2332         macros to these functions.
2333
2334         * dom/Document.cpp:
2335         (WebCore::Document::recalcStyle):
2336         * page/FrameView.cpp:
2337         (WebCore::FrameView::layout):
2338
2339 2013-02-22  Eric Seidel  <eric@webkit.org>
2340
2341         Teach the html5lib tests how to test the threaded HTML parser
2342         https://bugs.webkit.org/show_bug.cgi?id=110643
2343
2344         Reviewed by Adam Barth.
2345
2346         This adds a way to force data: url parsing to go through
2347         the threaded parser, to enable us to test the threaded parser
2348         using the html5lib test harness.
2349
2350         * html/parser/HTMLParserOptions.cpp:
2351         (WebCore::HTMLParserOptions::HTMLParserOptions):
2352         * page/Settings.in:
2353
2354 2013-02-21  Ojan Vafai  <ojan@chromium.org>
2355
2356         Increase the max preferred width of tables to 1000000
2357         https://bugs.webkit.org/show_bug.cgi?id=110545
2358
2359         Reviewed by Emil A Eklund.
2360
2361         Test: fast/table/large-shrink-wrapped-width.html
2362
2363         The old limit of 15000 was picked arbitrarily to avoid overflow.
2364         No need to pick such a small number.
2365
2366         * rendering/AutoTableLayout.cpp:
2367         (WebCore::AutoTableLayout::computeInstrinsicLogicalWidths):
2368         As best I can tell, this code is just wrong. Removing this makes the
2369         new test pass and doesn't cause any test failure. While we have many
2370         tests that hit this codepath, this code would only
2371         show a difference in the cases where the available container width is
2372         greater then 15000, and I don't think we have any tests that hit that case
2373         other than this new one.
2374         * rendering/TableLayout.h:
2375
2376 2013-02-22  Adam Barth  <abarth@webkit.org>
2377
2378         Threaded HTML parser should pass fast/parser/iframe-sets-parent-to-javascript-url.html
2379         https://bugs.webkit.org/show_bug.cgi?id=110637
2380
2381         Reviewed by Eric Seidel.
2382
2383         With the main thread parser, we always parse the first chunk of content
2384         returned as the result of evaluating a JavaScript URL synchronously. In
2385         particular, if the first chunk has an inline script, we'll execute it
2386         synchronously.
2387
2388         Previous to this patch, the threaded parser would always parse this
2389         content asynchronously. It's conceivable that there could be some
2390         content relying on the synchronous behavior, so this patch introduces
2391         the notion of "pinning" a parser to the main thread and uses that
2392         concept to force the result of JavaScript URLs to be parsed on the main
2393         thread (which is probably desirable anyway because they're likely to be
2394         quite short).
2395
2396         This patch fixes fast/parser/iframe-sets-parent-to-javascript-url.html
2397         and fast/dom/javascript-url-crash-function.html with the threaded
2398         parser with --enable-threaded-html-parser.
2399
2400         * dom/DocumentParser.h:
2401         (WebCore::DocumentParser::pinToMainThread):
2402         (DocumentParser):
2403         * html/parser/HTMLDocumentParser.cpp:
2404         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
2405         (WebCore):
2406         (WebCore::HTMLDocumentParser::pinToMainThread):
2407         * html/parser/HTMLDocumentParser.h:
2408         (HTMLDocumentParser):
2409         (WebCore::HTMLDocumentParser::shouldUseThreading):
2410         * loader/DocumentWriter.cpp:
2411         (WebCore::DocumentWriter::replaceDocument):
2412
2413 2013-02-22  Joe Mason  <jmason@rim.com>
2414
2415         [BlackBerry] Reread cookies when retrying a request with new auth credentials
2416         https://bugs.webkit.org/show_bug.cgi?id=110628
2417
2418         Reviewed by George Staikos.
2419
2420         Internal PR: 298805
2421         Internally Reviewed By: Leo Yang
2422
2423         The "isRedirect" parameter of initializePlatformRequest is only used to decide whether to
2424         reread cookies. Since we must reread cookies when resending a request with new auth
2425         credentials as well, rename this to "rereadCookies".
2426
2427         The only caller which sets this parameter rather than using the default value is
2428         NetworkManager::startJob, which also has other processing on redirect. So add a new
2429         "rereadCookies" parameter to startJob and ensure it is always set to true on a redirect, but
2430         can also be set to true on a non-redirect. And when startJob is called due to new auth
2431         credentials, set it to true.
2432
2433         * platform/network/blackberry/NetworkJob.cpp:
2434         (WebCore::NetworkJob::startNewJobWithRequest): Add rereadCookies parameter, pass it to
2435         startJob.
2436         (WebCore::NetworkJob::handleRedirect): Set new rereadCookies param of startNewJob to true.
2437         (WebCore::NetworkJob::notifyChallengeResult): Set new rereadCookies param of startNewJob to
2438         true.
2439         * platform/network/blackberry/NetworkJob.h:
2440         (NetworkJob): Add rereadCookies parameter to startNewJobWithRequest.
2441         * platform/network/blackberry/NetworkManager.cpp:
2442         (WebCore::NetworkManager::startJob): Add rereadCookies parameter, pass it instead of
2443         redirectCount to initializePlatformRequest.
2444         * platform/network/blackberry/NetworkManager.h:
2445         (NetworkManager): Add rereadCookies parameter to startJob.
2446         * platform/network/blackberry/ResourceRequest.h:
2447         (ResourceRequest): Rename isRedirect parameter to rereadCookies.
2448         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
2449         (WebCore::ResourceRequest::initializePlatformRequest): Rename isRedirect to rereadCookies.
2450
2451 2013-02-22  Benjamin Poulain  <bpoulain@apple.com>
2452
2453         Use CFNotificationCenter instead of NSNotificationCenter for SharedTimerIOS
2454         https://bugs.webkit.org/show_bug.cgi?id=110544
2455
2456         Reviewed by Daniel Bates.
2457
2458         Previously, we were instantiating the Obj-C object WebCoreResumeNotifierIOS
2459         with the only purpose of forwarding one notification to a C function.
2460
2461         This patch updates the code to use CFNotificationCenter to dispatch the notification
2462         without the intermediary object.
2463
2464         * platform/ios/SharedTimerIOS.mm:
2465         (WebCore::applicationDidBecomeActive):
2466         (WebCore::setSharedTimerFireInterval):
2467
2468 2013-02-22  Kenneth Russell  <kbr@google.com>
2469
2470         Uint8ClampedArray constructor is wrong in WorkerContext.idl
2471         https://bugs.webkit.org/show_bug.cgi?id=110634
2472
2473         Reviewed by Adam Barth.
2474
2475         Tests: fast/canvas/webgl/typed-arrays-in-workers.html
2476                webgl/conformance/typedarrays/typed-arrays-in-workers.html
2477
2478         * workers/WorkerContext.idl:
2479
2480 2013-02-21  Mark Lam  <mark.lam@apple.com>
2481
2482         Add some checks to DatabaseTracker::getMaxSizeForDatabase() to ensure
2483         that it returns a sane value.
2484         https://bugs.webkit.org/show_bug.cgi?id=110557.
2485
2486         Reviewed by Geoffrey Garen.
2487
2488         No layout test, but there is a quota-test.html attached to bugzilla.
2489         The test is a webpage that can be loaded into multiple tabs to
2490         consuming storage space. Once the test webpages are loaded, you will
2491         need to monitor the database directory and its files to confirm that
2492         growth is bounded. Also try reloading the test in the tabs. At no
2493         time should any database file ever exceed the quota.
2494
2495         * Modules/webdatabase/DatabaseTracker.cpp:
2496         (WebCore::DatabaseTracker::getMaxSizeForDatabase):
2497
2498 2013-02-22  James Simonsen  <simonjam@chromium.org>
2499
2500         Preloads should be cleared when JavaScript cancels loading prematurely.
2501         https://bugs.webkit.org/show_bug.cgi?id=110388
2502
2503         Reviewed by Antti Koivisto.
2504
2505         If a page preloads a resource, but JavaScript aborts parsing for any reason (for example, a
2506         redirect or document.write()), the resource is forever marked a preload and won't be reloaded
2507         even if it's explicitly marked no-cache and the page is reloaded.
2508
2509         Test: http/tests/cache/preload-cleared-after-parrsing-canceled-by-js.html
2510
2511         * dom/Document.cpp:
2512         (WebCore::Document::implicitClose):
2513         (WebCore::Document::finishedParsing):
2514
2515 2013-02-22  Antoine Quint  <graouts@apple.com>
2516
2517         Expose a list of all reasons that qualify a RenderLayer to be composited
2518         https://bugs.webkit.org/show_bug.cgi?id=110505
2519
2520         Expose the various reasons that can qualify a RenderLayer to be composited
2521         via a new bitmask returned by the reasonForCompositing() method on
2522         RenderLayerCompositor. This method already existed and was used for logging
2523         purposes, but the previous functionality is now accessed via the
2524         logReasonForCompositing() method.
2525
2526         This will allow the the InspectorLayerTreeAgent to provide this information
2527         to the front-end on a per-layer basis as requested by the front-end.
2528
2529         Reviewed by Simon Fraser.
2530
2531         No new tests.
2532
2533         * rendering/RenderLayerCompositor.cpp:
2534         (WebCore::RenderLayerCompositor::logLayerInfo):
2535         (WebCore::RenderLayerCompositor::reasonsForCompositing):
2536         (WebCore):
2537         (WebCore::RenderLayerCompositor::logReasonsForCompositing):
2538         * rendering/RenderLayerCompositor.h:
2539         (RenderLayerCompositor):
2540
2541 2013-02-22  Beth Dakin  <bdakin@apple.com>
2542
2543         ScrollingStateTree::rootStateNode() should be null-checked since it can be null
2544         https://bugs.webkit.org/show_bug.cgi?id=110631
2545
2546         Reviewed by Simon Fraser.
2547
2548         This is a speculative fix for <rdar://problem/13233090> and 
2549         <rdar://problem/12519348>. It is totally possible for rootStateNode() to be null, 
2550         so we should null-check it.
2551
2552         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
2553         (WebCore::ScrollingCoordinatorMac::setShouldUpdateScrollLayerPositionOnMainThread):
2554         (WebCore::ScrollingCoordinatorMac::syncChildPositions):
2555
2556 2013-02-22  Mike Reed  <reed@google.com>
2557
2558         Check for null-device when calling createCompatibleDevice
2559         https://bugs.webkit.org/show_bug.cgi?id=107981
2560
2561         Reviewed by James Robinson.
2562
2563         No new tests. Current tests provided coverage. Site in the wild triggered the failure
2564         (cairo failed to allocate a huge surface).
2565
2566         * platform/graphics/skia/ImageBufferSkia.cpp:
2567         (WebCore::ImageBuffer::ImageBuffer):
2568
2569 2013-02-22  Chris Rogers  <crogers@google.com>
2570
2571         AudioDestination::create() needs extra device identification information for live/local input streams
2572         https://bugs.webkit.org/show_bug.cgi?id=109494
2573
2574         Reviewed by James Robinson.
2575
2576         AudioDestination::create() supports live/local audio input.  But, since there may be multiple
2577         audio input devices available, an identifier for the requested input device needs to be
2578         passed in.  The embedder may then use this information so that the proper audio hardware is
2579         accessed.
2580
2581         * Modules/webaudio/AudioContext.cpp:
2582         (WebCore::AudioContext::createMediaStreamSource):
2583         * Modules/webaudio/AudioDestinationNode.h:
2584         (AudioDestinationNode):
2585         * Modules/webaudio/DefaultAudioDestinationNode.cpp:
2586         (WebCore::DefaultAudioDestinationNode::initialize):
2587         (WebCore::DefaultAudioDestinationNode::createDestination):
2588         (WebCore::DefaultAudioDestinationNode::enableInput):
2589         * Modules/webaudio/DefaultAudioDestinationNode.h:
2590         (DefaultAudioDestinationNode):
2591         * Modules/webaudio/OfflineAudioDestinationNode.h:
2592         * platform/audio/AudioDestination.h:
2593         (AudioDestination):
2594         * platform/audio/chromium/AudioDestinationChromium.cpp:
2595         (WebCore::AudioDestination::create):
2596         (WebCore::AudioDestinationChromium::AudioDestinationChromium):
2597         * platform/audio/chromium/AudioDestinationChromium.h:
2598         (AudioDestinationChromium):
2599         * platform/audio/gstreamer/AudioDestinationGStreamer.cpp:
2600         (WebCore::AudioDestination::create):
2601         * platform/audio/mac/AudioDestinationMac.cpp:
2602         (WebCore::AudioDestination::create):
2603         * platform/chromium/support/WebMediaStreamSource.cpp:
2604         (WebKit::WebMediaStreamSource::deviceId):
2605         (WebKit):
2606         (WebKit::WebMediaStreamSource::setDeviceId):
2607         * platform/mediastream/MediaStreamSource.h:
2608         (WebCore::MediaStreamSource::deviceId):
2609         (WebCore::MediaStreamSource::setDeviceId):
2610         (MediaStreamSource):
2611
2612 2013-02-22  Ryosuke Niwa  <rniwa@webkit.org>
2613
2614         Binding tests rebaseline after r143737.
2615
2616         * bindings/scripts/test/V8/V8Float64Array.cpp:
2617         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
2618         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
2619         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
2620         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
2621         * bindings/scripts/test/V8/V8TestException.cpp:
2622         * bindings/scripts/test/V8/V8TestInterface.cpp:
2623         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
2624         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
2625         * bindings/scripts/test/V8/V8TestNode.cpp:
2626         * bindings/scripts/test/V8/V8TestObj.cpp:
2627         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
2628         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
2629         * bindings/scripts/test/V8/V8TestTypedefs.cpp:
2630
2631 2013-02-22  Kunihiko Sakamoto  <ksakamoto@chromium.org>
2632
2633         INPUT_MULTIPLE_FIELDS_UI: Unable to enter "24" to hour field
2634         https://bugs.webkit.org/show_bug.cgi?id=110431
2635
2636         Reviewed by Kent Tamura.
2637
2638         Fixed a bug that hour-field does not accept "24" as a valid input when hour format is 1-24.
2639         To test <input> against different time formats, added "pattern" attribute to DateTimeEditElement.
2640
2641         Test: fast/forms/time-multiple-fields/time-multiple-fields-stepup-stepdown-from-renderer.html
2642
2643         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
2644         (WebCore::BaseMultipleFieldsDateAndTimeInputType::updateInnerTextValue): Overwrites layoutParameters.dateTimeFormat by pattern attribute of DateTimeEditElement (if exists).
2645         * html/shadow/DateTimeFieldElements.cpp:
2646         (WebCore::DateTimeHourFieldElement::populateDateTimeFieldsState): Fixed a bug where AM/PM value was passed to setHour().
2647         (WebCore::DateTimeHourFieldElement::setValueAsInteger): Clamps the given value to 0-24 when the range of the field is 1-12 or 1-24. Renamed the parameter as it may not be an hour23 value (0-23).
2648
2649 2013-02-21  Zoltan Horvath  <zoltan@webkit.org>
2650
2651         [CSS Regions] Region boxes should respect -shape-inside CSS property
2652         https://bugs.webkit.org/show_bug.cgi?id=107880
2653
2654         Reviewed by David Hyatt.
2655
2656         The shape-inside CSS property modifies the shape of the inner inline flow content from rectangular content box
2657         to an arbitrary geometry. The detailed documentation is located in the CSS-Exclusions specification:
2658         http://dev.w3.org/csswg/css3-exclusions/#shape-inside-property. This change adds support for the shape-inside property
2659         on CSS Regions.
2660
2661         Test: fast/regions/shape-inside-on-regions.html
2662
2663         * rendering/ExclusionShapeInfo.cpp:
2664         (WebCore):
2665         (WebCore::::logicalTopOffset): Shape dimension should be relative to the current region.
2666         * rendering/ExclusionShapeInfo.h:
2667         (ExclusionShapeInfo):
2668         (WebCore::::logicalTopOffset): Move the implementation to ExclusionShapeInfo.cpp.
2669         * rendering/RenderBlockLineLayout.cpp:
2670         (WebCore::logicalHeightForLine): Move the function prior to layoutExclusionShapeInsideInfo, since we need to use it there.
2671         (WebCore):
2672         (WebCore::layoutExclusionShapeInsideInfo): Add support for cases when shape-inside is a region-block property.
2673         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Update the exclusion shape information for every line, since the content
2674         could flow through several region containers which can have different shape-inside properties.
2675
2676 2013-02-21  Ojan Vafai  <ojan@chromium.org>
2677
2678         Add computeInstrinsicLogicalWidths functions to TableLayout subclasses
2679         https://bugs.webkit.org/show_bug.cgi?id=110520
2680
2681         Reviewed by Tony Chang.
2682
2683         This is just a refactor in preparation for adding RenderTable::computeIntinsicLogicalWidths.
2684         No change in behavior.
2685
2686         Split the computePreferredLogicalWidths functions into a computeIntinsicLogicalWidths
2687         and a applyPreferredLogicalWidthQuirks. Also, move the addition of bordersPaddingAndSpacing
2688         into RenderTable since both TableLayout subclasses need this.
2689
2690         This has the added readability benefit of better isolating the quirks that each table layout
2691         mode requires.
2692
2693         * rendering/AutoTableLayout.cpp:
2694         (WebCore::AutoTableLayout::computeIntrinsicLogicalWidths):
2695         (WebCore::AutoTableLayout::applyPreferredLogicalWidthQuirks):
2696         * rendering/AutoTableLayout.h:
2697         (AutoTableLayout):
2698         * rendering/FixedTableLayout.cpp:
2699         (WebCore::FixedTableLayout::computeIntrinsicLogicalWidths):
2700         (WebCore::FixedTableLayout::applyPreferredLogicalWidthQuirks):
2701         * rendering/FixedTableLayout.h:
2702         (FixedTableLayout):
2703         * rendering/RenderTable.cpp:
2704         (WebCore::RenderTable::computePreferredLogicalWidths):
2705         * rendering/TableLayout.h:
2706         (TableLayout):
2707
2708 2013-02-22  David Hyatt  <hyatt@apple.com>
2709
2710         [New Multicolumn] Correctly track whether or not a layer is paginated.
2711         https://bugs.webkit.org/show_bug.cgi?id=110625.
2712
2713         Taking the first step towards implementing the correct spec-compliant painting
2714         model for the new multi-column layout. Add code to make sure the paginated
2715         bits in RenderLayer get propagated correctly for the new layout.
2716         
2717         The main difference in bit propagation between the old multicolumn layout and
2718         the new multicolumn layout is that the old layout only tracked pagination "roots",
2719         since it has a broken layer painting model. It incorrectly treats a pagination
2720         "root" inside a multi-column block as establishing a stacking context in each
2721         column. This is incorrect.
2722         
2723         The new multicolumn code is going to paint each paginated layer individually,
2724         and this means the bits can't just be about roots. Instead they have to be set
2725         on every layer that may be split across columns, without regard for whether parent
2726         layers are also split or not. This is actually a simpler bit propagation model
2727         than the old code.
2728
2729         Reviewed by Beth Dakin.
2730
2731         * rendering/RenderLayer.cpp:
2732         (WebCore::RenderLayer::updateLayerPositions):
2733         Add code to set the m_isPaginated bit for in-flow RenderFlowThreads. This includes
2734         only RenderMultiColumnFlowThread for now, but eventually it will also include
2735         RenderPageFlowThread.
2736
2737         (WebCore::RenderLayer::useRegionBasedColumns):
2738         Add a helper method to check if region-based columns are turned on, since we're
2739         not attempting to alter the old column pagination model.
2740
2741         (WebCore::RenderLayer::updatePagination):
2742         Added the code to propagate bits under the new model. Whether or not you're paginated
2743         just depends on whether or not your enclosing layer along the containing block chain
2744         is paginated.
2745
2746         (WebCore::RenderLayer::paintList):
2747         (WebCore::RenderLayer::hitTestList):
2748         Add code that avoids the old multi-column pagination model when the new column model
2749         is enabled. For now there is no code in the new model that does anything with the bits,
2750         but we're avoiding calling the old code, since it is broken for the new columns.
2751
2752         * rendering/RenderLayer.h:
2753         (RenderLayer):
2754         Added the useRegionBasedColumns method to check the Setting.
2755
2756         * rendering/RenderMultiColumnFlowThread.h:
2757         * rendering/RenderObject.h:
2758         (WebCore::RenderObject::isInFlowRenderFlowThread):
2759         (RenderObject):
2760         Implement isInFlowRenderFlowThread, a virtual function for asking if a renderer is
2761         an in-flow RenderFlowThread, which means that it is going to need paginated layers
2762         because the flow thread has to split across "pages" that do not establish stacking
2763         contexts.
2764
2765 2013-02-22  Bem Jones-Bey  <bjonesbe@adobe.com>
2766
2767         text-overflow:ellipsis is not applied when the block contains nested blocks
2768         https://bugs.webkit.org/show_bug.cgi?id=101879
2769
2770         Reviewed by Eric Seidel.
2771
2772         Since text-overflow is not an inherited property, the anonymous blocks
2773         don't know they should ellipse. This causes the anonymous blocks
2774         created in the nested block situation to check their parent to find
2775         out if they should ellipse.
2776
2777         Test: fast/css/text-overflow-ellipsis-anonymous-blocks.html
2778
2779         * rendering/RenderBlockLineLayout.cpp:
2780         (WebCore::RenderBlock::layoutInlineChildren):
2781
2782 2013-02-22  Eric Seidel  <eric@webkit.org>
2783
2784         REGRESSION(r143664, r143681): http/tests/security/feed-urls-from-remote.html fails
2785         https://bugs.webkit.org/show_bug.cgi?id=110554
2786
2787         Reviewed by Adam Barth.
2788
2789         Will fix http/tests/security/feed-urls-from-remote.html for Mac WK1.
2790
2791         * loader/DocumentLoader.cpp:
2792         (WebCore::DocumentLoader::isLoading):
2793
2794 2013-02-22  Mark Rowe  <mrowe@apple.com>
2795
2796         Build fix after r143637.
2797
2798         * WebCore.exp.in: Unconditionally export ScriptController::javaScriptContext.
2799         * bindings/js/ScriptController.h: Unconditionally define javaScriptContext for Mac builds.
2800         * bindings/js/ScriptControllerMac.mm:
2801         (WebCore::ScriptController::javaScriptContext): Move the #if inside the function, and return 0 when false.
2802
2803 2013-02-22  Anton Vayvod  <avayvod@chromium.org>
2804
2805         [TextAutosizing] Refactoring to eliminate boolean parameter.
2806         https://bugs.webkit.org/show_bug.cgi?id=110490
2807
2808         Reviewed by Julien Chaffraix.
2809
2810         A follow-up to the recent change that introduced a boolean parameter to
2811         processClusterInternal method of TextAutosizer. Boolean parameters are discouraged by the
2812         WebKit style guide. See http://trac.webkit.org/changeset/142866
2813
2814         Refactoring so no new tests.
2815
2816         * rendering/TextAutosizer.cpp:
2817         (WebCore::TextAutosizer::clusterMultiplier):
2818
2819                 Calculates the font size multiplier for the specified cluster.
2820
2821         (WebCore::TextAutosizer::processClusterInternal):
2822
2823                 Accepts the font size multiplier instead of |shouldBeAutosized|.
2824
2825         (WebCore::TextAutosizer::processCluster):
2826         (WebCore::TextAutosizer::processCompositeCluster):
2827
2828                 Both methods above now calculate the multiplier and then pass it to
2829                 processClusterInternal.
2830
2831         * rendering/TextAutosizer.h:
2832
2833                 Updated method declarations.
2834
2835 2013-02-22  Carlos Garcia Campos  <cargarcia@rim.com>
2836
2837         [BlackBerry] Use KURL::protocolIsInHTTPFamily instead of KURL::protocolInHTTPFamily
2838         https://bugs.webkit.org/show_bug.cgi?id=110581
2839
2840         Reviewed by Rob Buis.
2841
2842         KURL::protocolInHTTPFamily() was removed in r109670.
2843
2844         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
2845         (WebCore::ResourceRequest::clearHTTPContentLength):
2846         (WebCore::ResourceRequest::clearHTTPContentType):
2847
2848 2013-02-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2849
2850         Unreviewed build-fix after r143744.
2851
2852         * dom/Document.cpp:
2853         (WebCore::Document::updateHoverActiveState):
2854
2855 2013-02-22  Andrey Adaikin  <aandrey@chromium.org>
2856
2857         Web Inspector: [Canvas] throttle replayTraceLog messages to backend
2858         https://bugs.webkit.org/show_bug.cgi?id=110591
2859
2860         Reviewed by Pavel Feldman.
2861
2862         The replayTraceLog message may be quite expensive. So, while such a request is processed by the
2863         backend, user may well generate a dozen of new ones simply by walking through the DataGrid.
2864         We should actually send to the backend only the last event from the queue.
2865
2866         * inspector/front-end/CanvasProfileView.js:
2867         (WebInspector.CanvasProfileView.prototype._replayTraceLog.didReplayTraceLog):
2868         (WebInspector.CanvasProfileView.prototype._replayTraceLog):
2869
2870 2013-02-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2871
2872         Multiple Layout Test crashes (ASSERT) on chromium linux debug after r143727
2873         https://bugs.webkit.org/show_bug.cgi?id=110609
2874
2875         Reviewed by Antonio Gomes.
2876
2877         Revert r128869. InnerNode may now again be from a child document, 
2878         and should be handled and not asserted against.
2879
2880         * dom/Document.cpp:
2881         (WebCore::Document::updateHoverActiveState):
2882
2883 2013-02-22  Andreas Kling  <akling@apple.com>
2884
2885         Element: Make updateName/updateId/updateLabel private.
2886         <http://webkit.org/b/110603>
2887
2888         Reviewed by Antti Koivisto.
2889
2890         These methods are only called from inside Element so make them private and
2891         move them to the .cpp file.
2892
2893         * dom/Element.cpp:
2894         (WebCore::Element::updateName):
2895         (WebCore::Element::updateId):
2896         * dom/Element.h:
2897
2898 2013-02-21  Zhenyao Mo  <zmo@google.com>
2899
2900         Roll ANGLE to r1833
2901         https://bugs.webkit.org/show_bug.cgi?id=110513
2902
2903         Reviewed by Kenneth Russell.
2904
2905         * CMakeLists.txt:
2906         * GNUmakefile.list.am:
2907
2908 2013-02-22  Carlos Garcia Campos  <cargarcia@rim.com>
2909
2910         [BlackBerry] Rename first/second to key/value in HashMap iterators
2911         https://bugs.webkit.org/show_bug.cgi?id=110577
2912
2913         Reviewed by Rob Buis.
2914
2915         Iterators were renamed to key/value in r130612.
2916
2917         * platform/blackberry/AuthenticationChallengeManager.cpp:
2918         (WebCore::AuthenticationChallengeManager::pageVisibilityChanged):
2919         * platform/network/blackberry/NetworkJob.cpp:
2920         (WebCore::NetworkJob::handleNotifyMultipartHeaderReceived):
2921
2922 2013-02-22  Kentaro Hara  <haraken@chromium.org>
2923
2924         [V8] Add comments to checkTypeOrDieTrying()
2925         https://bugs.webkit.org/show_bug.cgi?id=110553
2926
2927         Reviewed by Adam Barth.
2928
2929         It is mysterious how the check is helpful. We need comments.
2930
2931         No tests. Just added comments.
2932
2933         * bindings/scripts/CodeGeneratorV8.pm:
2934         (GenerateImplementation):
2935         * bindings/v8/ScriptWrappable.h:
2936         (ScriptWrappable):
2937
2938 2013-02-22  Jessie Berlin  <jberlin@apple.com>
2939
2940         32-bit build fix after r143706
2941
2942         * fileapi/FileReaderLoader.cpp:
2943         (WebCore::FileReaderLoader::didReceiveData):
2944
2945 2013-02-22  Andrey Adaikin  <aandrey@chromium.org>
2946
2947         Web Inspector: [Canvas] do no show a single frame node in data grid
2948         https://bugs.webkit.org/show_bug.cgi?id=110473
2949
2950         Reviewed by Pavel Feldman.
2951
2952         In a single canvas frame capture mode do not show the single "Frame #1" node.
2953         Drive-by: Fix a wrong "this" pointer.
2954
2955         * inspector/front-end/CanvasProfileView.js:
2956         (WebInspector.CanvasProfileView.prototype._didReceiveTraceLog):
2957         (WebInspector.CanvasProfileView.prototype.appendDrawCallGroup):
2958         (WebInspector.CanvasProfileView.prototype._flattenSingleFrameNode):
2959
2960 2013-02-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2961
2962         Multiple Layout Test crashes (ASSERT) on chromium linux debug after r143727
2963         https://bugs.webkit.org/show_bug.cgi?id=110609
2964
2965         Reviewed by Antonio Gomes.
2966
2967         Point based hit tests should not append but assign HitTestResults.
2968
2969         * rendering/RenderFrameBase.cpp:
2970         (WebCore::RenderFrameBase::nodeAtPoint):
2971
2972 2013-02-22  Andrey Lushnikov  <lushnikov@chromium.org>
2973
2974         Web Inspector: show source location after drawer views
2975         https://bugs.webkit.org/show_bug.cgi?id=110156
2976
2977         Reviewed by Pavel Feldman.
2978
2979         - Add statusBarText method
2980         - Add #drawer-view-anchor, which determines layout position of
2981         drawerView
2982         - Fix layout in #panel-status-bar to avoid floating elements.
2983
2984         No new tests.
2985
2986         * inspector/front-end/Panel.js:
2987         (WebInspector.Panel.prototype.wasShown): Add statusBarItems before
2988         drawer-view-anchor and statusBarText after.
2989         (WebInspector.Panel.prototype.willHide): Remove statusBarText from DOM in the
2990         way it's done for statusBarItems
2991         * inspector/front-end/ScriptsPanel.js:
2992         (WebInspector.ScriptsPanel.prototype.statusBarText): Added.
2993         * inspector/front-end/SourceFrame.js:
2994         (WebInspector.SourceFrame.prototype.statusBarText): Added.
2995         (WebInspector.SourceFrame.prototype.statusBarItems):
2996         * inspector/front-end/TimelinePanel.js:
2997         (WebInspector.TimelinePanel.prototype.get statusBarItems):
2998         * inspector/front-end/View.js:
2999         (WebInspector.View.prototype.statusBarText):
3000         * inspector/front-end/inspector.css:
3001         (#drawer-view-anchor):
3002         (.source-frame-cursor-position):
3003         * inspector/front-end/inspector.html:
3004         * inspector/front-end/inspector.js:
3005         (WebInspector.showViewInDrawer):
3006         * inspector/front-end/timelinePanel.css:
3007         (.timeline-records-stats):
3008         (.timeline-records-stats-container):
3009
3010 2013-02-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
3011
3012         Allow child-frame content in hit-tests.
3013         https://bugs.webkit.org/show_bug.cgi?id=95204
3014
3015         Reviewed by Julien Chaffraix.
3016
3017         Refactors how EventHandler::hitTestResultAtPoint handles child-frame content,
3018         it is now handled by the hit test itself controlled by the AllowChildFrameContent
3019         flag in HitTestRequest.
3020
3021         This means that area-based hit-tests can now return elements from all the child frames
3022         they intersect instead of just the one frame containing the center point. The improved
3023         results from area-based hit-tests will among other things also improve touch adjustment
3024         near frame boundaries.
3025
3026         Tests: fast/dom/nodesFromRect/nodesFromRect-child-frame-content.html
3027
3028         * page/EventHandler.cpp:
3029         (WebCore::EventHandler::hitTestResultAtPoint):
3030             Recursion into child-frames have been moved to RenderFrameBase::nodeAtPoint, so
3031             now hitTestResultAtPoint just needs to set AllowChildFrameContent.
3032         * page/TouchAdjustment.cpp:
3033         (WebCore::TouchAdjustment::parentShadowHostOrOwner):
3034             New function to iterate up across frame boundaries.
3035         (WebCore::TouchAdjustment::compileSubtargetList):
3036             We need to iterate up across frame boundaries to avoid iframes competing with their
3037             own content for touch adjustment.
3038         * rendering/HitTestRequest.h:
3039         (WebCore::HitTestRequest::allowsChildFrameContent):
3040         (WebCore::HitTestRequest::isChildFrameHitTest):
3041         * rendering/HitTestResult.cpp:
3042         (WebCore::HitTestResult::HitTestResult):
3043         (WebCore::HitTestResult::operator=):
3044         (WebCore::HitTestResult::append):
3045         (WebCore::HitTestResult::dictationAlternatives):
3046         * rendering/HitTestResult.h:
3047         (WebCore::HitTestResult::pointInMainFrame):
3048         (WebCore::HitTestResult::pointInInnerNodeFrame):
3049         (HitTestResult):
3050             m_hitTestLocation is now in main frame coordinates, which make m_pointInMainFrame
3051             unnecessary, but requires the introduction of m_pointInInnerFrame, to remember
3052             the coordinates of inner-node in its own frame.
3053         * rendering/RenderFrameBase.cpp:
3054         (WebCore::RenderFrameBase::nodeAtPoint):
3055             The recursion into child-frames is now handled here instead of in hitTestResultAtPoint, this
3056             allows us to recurse into multiple frames, instead of just one.
3057         * rendering/RenderFrameBase.h:
3058         (RenderFrameBase):
3059         * rendering/RenderLayer.cpp:
3060         (WebCore::RenderLayer::hitTest):
3061             RenderLayer should not lie about being hit if the request is child-frame request.
3062         * testing/Internals.cpp:
3063         (WebCore::Internals::nodesFromRect):
3064         * testing/Internals.h:
3065         (Internals):
3066         * testing/Internals.idl:
3067             Extended so nodesFromRect with child-frame content can be tested.
3068
3069 2013-02-22  Andreas Kling  <akling@apple.com>
3070
3071         ShareableElementData should use zero-length array for storage.
3072         <http://webkit.org/b/109959>
3073
3074         Reviewed by Anders Carlsson.
3075
3076         Use a zero-length Attribute array instead of always casting from void* to an array.
3077         It was done this way originally because I didn't know we could sidestep the MSVC
3078         build error with some #pragma hackery and a default constructor for Attribute.
3079
3080         * dom/Attribute.cpp:
3081         (WebCore::Attribute::Attribute):
3082         * dom/DocumentSharedObjectPool.cpp:
3083         (WebCore::DocumentSharedObjectPool::cachedShareableElementDataWithAttributes):
3084         * dom/Element.cpp:
3085         (WebCore::sizeForShareableElementDataWithAttributeCount):
3086         (WebCore::ShareableElementData::ShareableElementData):
3087         (WebCore::ShareableElementData::~ShareableElementData):
3088         (WebCore::UniqueElementData::UniqueElementData):
3089         * dom/Element.h:
3090         (ShareableElementData):
3091         (WebCore::ElementData::attributeItem):
3092
3093 2013-02-22  Andreas Kling  <akling@apple.com>
3094
3095         Remove unused declaration: Element::removeCachedHTMLCollection()
3096
3097         Not reviewed by Antti Koivisto.
3098
3099         * dom/Element.h:
3100         (Element):
3101
3102 2013-02-22  Keishi Hattori  <keishi@webkit.org>
3103
3104         Add scroll view for new calendar picker
3105         https://bugs.webkit.org/show_bug.cgi?id=110137
3106
3107         Reviewed by Kent Tamura.
3108
3109         Adding a scroll view class as part of the new calendar picker (Bug 109439).
3110
3111         No new tests. Code not yet used.
3112
3113         * Resources/pagepopups/calendarPicker.js:
3114         (View):
3115         (View.prototype.offsetRelativeTo): Returns the offset position of this view relative to the given ancestor element.
3116         (View.prototype.attachTo): Attaches view to a node or view.
3117         (View.prototype.bindCallbackMethods): Binds all methods starting with "on" to this.
3118         (ScrollView): A custom scroll view that can contain extremely long content. CSS values have a limit. This can go beyond that.
3119         (ScrollView.prototype.setWidth): Sets the view width.
3120         (ScrollView.prototype.width):
3121         (ScrollView.prototype.setHeight):Sets the view height.
3122         (ScrollView.prototype.height):
3123         (ScrollView.prototype.onScrollAnimatorStep): Callback for scroll animator step.
3124         (ScrollView.prototype.scrollTo): Scrolls to a certain offset.
3125         (ScrollView.prototype.scrollBy): Scrolls by a certain amount.
3126         (ScrollView.prototype.contentOffset): Current content offset.
3127         (ScrollView.prototype.onMouseWheel): Scroll with the mouse wheel.
3128         (ScrollView.prototype.setContentOffset): Sets the content offset.
3129         (ScrollView.prototype.contentPositionForContentOffset): Returns where the content element should be positioned.
3130
3131 2013-02-22  Alexander Pavlov  <apavlov@chromium.org>
3132
3133         Web Inspector: InspectorPageAgent::disable() should not update view metrics regardless of the override state
3134         https://bugs.webkit.org/show_bug.cgi?id=110593
3135
3136         Reviewed by Vsevolod Vlasov.
3137
3138         InspectorPageAgent::disable() now checks if the device metrics are overridden before
3139         telling the client to disable the override.
3140
3141         * inspector/InspectorPageAgent.cpp:
3142         (WebCore::InspectorPageAgent::disable):
3143         (WebCore::InspectorPageAgent::setDeviceMetricsOverride):
3144         (WebCore::InspectorPageAgent::deviceMetricsChanged):
3145         * inspector/InspectorPageAgent.h:
3146         (InspectorPageAgent):
3147
3148 2013-02-22  Zan Dobersek  <zdobersek@igalia.com>
3149
3150         Unreviewed, rolling out r143695.
3151         http://trac.webkit.org/changeset/143695
3152         https://bugs.webkit.org/show_bug.cgi?id=110554
3153
3154         Crashes in DocumentLoader::checkLoadComplete on AppleMac WK1, EFL, GTK.
3155
3156         * loader/DocumentLoader.cpp:
3157         (WebCore::DocumentLoader::isLoading):
3158
3159 2013-02-22  Balazs Kelemen  <kbalazs@webkit.org>
3160
3161         [CoordGfx] Minor cleanup in CoordinatedGraphicsScene::paintToGraphicsContext
3162         https://bugs.webkit.org/show_bug.cgi?id=109824
3163
3164         Reviewed by Andreas Kling.
3165
3166         Avoid ugly ifdefs by using PlatformGraphicsContext.
3167
3168         No new tests, only refactoring.
3169
3170         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
3171         (WebCore::CoordinatedGraphicsScene::paintToGraphicsContext):
3172         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
3173         (CoordinatedGraphicsScene):
3174
3175 2013-02-22  Carlos Garcia Campos  <cgarcia@igalia.com>
3176
3177         Unreviewed. Fix make distcheck.
3178
3179         * GNUmakefile.am: Add CodeGeneratorInspectorStrings.py to
3180         EXTRA_DIST.
3181
3182 2013-02-22  Andreas Kling  <akling@apple.com>
3183
3184         GlyphPage: ALWAYS_INLINE all performance-relevant getters.
3185
3186         REGRESSION(r143125): ~5% performance hit on Chromium's intl2 page cycler
3187         <http://webkit.org/b/108835>
3188
3189         Reviewed by Antti Koivisto.
3190
3191         Unreviewed desperate hack. Since I can't reproduce the problem and it's only showing
3192         up on two bots, one Linux and one Snow Leopard, I'm thinking it may be GCC related.
3193         Let's see what happens if we tell it to force inline all the GlyphPage getters.
3194
3195         * platform/graphics/GlyphPage.h:
3196         (WebCore::GlyphPage::indexForCharacter):
3197         (WebCore::GlyphPage::glyphDataForCharacter):
3198         (WebCore::GlyphPage::glyphDataForIndex):
3199         (WebCore::GlyphPage::glyphAt):
3200         (WebCore::GlyphPage::fontDataForCharacter):
3201
3202 2013-02-22  Zach Kuznia  <zork@chromium.org>
3203
3204         Update FileReaderLoader to allow specifying a range and reading as a blob.
3205         https://bugs.webkit.org/show_bug.cgi?id=110556
3206
3207         This is part of a series of patches to implement Stream support.  See:
3208         https://bugs.webkit.org/show_bug.cgi?id=110194
3209
3210         Reviewed by Hajime Morrita.
3211
3212         Tests: will be added when js binding is added.
3213
3214         * fileapi/FileReaderLoader.cpp:
3215         * fileapi/FileReaderLoader.h:
3216
3217 2013-02-22  Kondapally Kalyan  <kalyan.kondapally@intel.com>
3218
3219         [WebGL][EFL] Support for creating surface with alpha disabled.
3220         https://bugs.webkit.org/show_bug.cgi?id=110067
3221
3222         Reviewed by Kenneth Rohde Christiansen.
3223
3224         Covered by compositing/webgl/webgl-no-alpha.html
3225
3226         We currently always create a surface supporting alpha channel. 
3227         With this patch we create the surface with alpha only if
3228         required.
3229
3230         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
3231         (WebCore::GraphicsContext3DPrivate::initialize):
3232         * platform/graphics/efl/GraphicsContext3DPrivate.h:
3233         (GraphicsContext3DPrivate):
3234         * platform/graphics/opengl/GLPlatformSurface.cpp:
3235         (WebCore::GLPlatformSurface::createOffScreenSurface):
3236         (WebCore::GLPlatformSurface::createTransportSurface):
3237         (WebCore::GLPlatformSurface::GLPlatformSurface):
3238         (WebCore::GLPlatformSurface::attributes):
3239         (WebCore):
3240         * platform/graphics/opengl/GLPlatformSurface.h:
3241         * platform/graphics/surfaces/egl/EGLConfigSelector.cpp:
3242         (WebCore):
3243         (WebCore::EGLConfigSelector::EGLConfigSelector):
3244         (WebCore::EGLConfigSelector::pBufferContextConfig):
3245         (WebCore::EGLConfigSelector::surfaceContextConfig):
3246         * platform/graphics/surfaces/egl/EGLConfigSelector.h:
3247         (EGLConfigSelector):
3248         * platform/graphics/surfaces/egl/EGLSurface.cpp:
3249         (WebCore::EGLWindowTransportSurface::EGLWindowTransportSurface):
3250         * platform/graphics/surfaces/egl/EGLSurface.h:
3251         (EGLWindowTransportSurface):
3252         * platform/graphics/surfaces/glx/GLXConfigSelector.h:
3253         (WebCore):
3254         (WebCore::GLXConfigSelector::GLXConfigSelector):
3255         (WebCore::GLXConfigSelector::pixmapContextConfig):
3256         (WebCore::GLXConfigSelector::surfaceContextConfig):
3257         (WebCore::GLXConfigSelector::surfaceClientConfig):
3258         (WebCore::GLXConfigSelector::validateAttributes):
3259         (WebCore::GLXConfigSelector::findMatchingConfig):
3260         (WebCore::GLXConfigSelector::findMatchingConfigWithVisualId):
3261         (GLXConfigSelector):
3262         * platform/graphics/surfaces/glx/GLXContext.cpp:
3263         (WebCore::GLXOffScreenContext::initialize):
3264         * platform/graphics/surfaces/glx/GLXSurface.cpp:
3265         (WebCore::GLXTransportSurface::GLXTransportSurface):
3266         (WebCore::GLXOffScreenSurface::GLXOffScreenSurface):
3267         (WebCore::GLXOffScreenSurface::initialize):
3268         * platform/graphics/surfaces/glx/GLXSurface.h:
3269         (GLXTransportSurface):
3270         (GLXOffScreenSurface):
3271         * platform/graphics/surfaces/glx/GraphicsSurfaceGLX.cpp:
3272         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
3273         (WebCore::GraphicsSurfacePrivate::createPixmap):
3274
3275 2013-02-22  Pavel Feldman  <pfeldman@chromium.org>
3276
3277         Web Inspector: allow opting out from vertical split in the dock-to-right mode
3278         https://bugs.webkit.org/show_bug.cgi?id=110564
3279
3280         Reviewed by Vsevolod Vlasov.
3281
3282         * English.lproj/localizedStrings.js:
3283         * inspector/front-end/ElementsPanel.js:
3284         (WebInspector.ElementsPanel.prototype._splitVertically):
3285         * inspector/front-end/ScriptsPanel.js:
3286         * inspector/front-end/Settings.js:
3287         (WebInspector.Settings):
3288         * inspector/front-end/SettingsScreen.js:
3289         (WebInspector.GenericSettingsTab):
3290
3291 2013-02-21  Claudio Saavedra  <csaavedra@igalia.com>
3292
3293         [GTK] Control+Shift+Up/Down selection works backwards
3294         https://bugs.webkit.org/show_bug.cgi?id=110459
3295
3296         Reviewed by Martin Robinson.
3297
3298         * platform/gtk/KeyBindingTranslator.cpp:
3299         (WebCore): The translation table for paragraph selection
3300         commands is backwards, fix it.
3301
3302 2013-02-21  Eric Seidel  <eric@webkit.org>
3303
3304         REGRESSION(r143664, r143681): http/tests/security/feed-urls-from-remote.html fails
3305         https://bugs.webkit.org/show_bug.cgi?id=110554
3306
3307         Reviewed by Ryosuke Niwa.
3308
3309         Will fix http/tests/security/feed-urls-from-remote.html for Mac WK1.
3310
3311         * loader/DocumentLoader.cpp:
3312         (WebCore::DocumentLoader::isLoading):
3313
3314 2013-02-21  Alec Flett  <alecflett@chromium.org>
3315
3316         IndexedDB: Implement SharedBuffer version of put() / onSuccess()
3317         https://bugs.webkit.org/show_bug.cgi?id=110398
3318
3319         Reviewed by Tony Chang.
3320
3321         This avoids all unnecessary data copies within the context of
3322         IndexedDB proper, and removes all references to
3323         SerializedScriptValue from the IndexedDB "backend".
3324
3325         No new tests because this is just a refactor.
3326
3327         * bindings/v8/IDBBindingUtilities.cpp:
3328         (WebCore::deserializeIDBValueBuffer): New version of deserializeIDBValue which takes SharedBuffer.
3329
3330 2013-02-21  Sheriff Bot  <webkit.review.bot@gmail.com>
3331
3332         Unreviewed, rolling out r143691.
3333         http://trac.webkit.org/changeset/143691
3334         https://bugs.webkit.org/show_bug.cgi?id=110559
3335
3336         Breaks compilation on mac. (Requested by vsevik on #webkit).
3337
3338         * rendering/RenderLayerCompositor.cpp:
3339         (WebCore::RenderLayerCompositor::logLayerInfo):
3340         (WebCore):
3341         (WebCore::RenderLayerCompositor::reasonForCompositing):
3342         * rendering/RenderLayerCompositor.h:
3343         (RenderLayerCompositor):
3344
3345 2013-02-21  Philip Rogers  <pdr@google.com>
3346
3347         Remove deep copy of ImageBuffer in tiled SVG backgrounds
3348         https://bugs.webkit.org/show_bug.cgi?id=110549
3349
3350         Reviewed by Dirk Schulze.
3351
3352         SVGImage::drawPatternForContainer creates a temporary ImageBuffer for stamping out tiled
3353         backgrounds. Previously this ImageBuffer was unnecessarily deep-copied! This patch uses a
3354         shallow copy, taking advantage of the fact that the temporary ImageBuffer is never modified.
3355
3356         This patch is covered with existing tests.
3357
3358         * svg/graphics/SVGImage.cpp:
3359         (WebCore::SVGImage::drawPatternForContainer):
3360
3361 2013-02-21  Antoine Quint  <graouts@apple.com>
3362
3363         Expose a list of all reasons that qualify a RenderLayer to be composited
3364         https://bugs.webkit.org/show_bug.cgi?id=110505
3365
3366         Expose the various reasons that can qualify a RenderLayer to be composited
3367         via a new bitmask returned by the reasonForCompositing() method on
3368         RenderLayerCompositor. This method already existed and was used for logging
3369         purposes, but the previous functionality is now accessed via the
3370         logReasonForCompositing() method.
3371
3372         This will allow the the InspectorLayerTreeAgent to provide this information
3373         to the front-end on a per-layer basis as requested by the front-end.
3374
3375         Reviewed by Simon Fraser.
3376
3377         No new tests.
3378
3379         * rendering/RenderLayerCompositor.cpp:
3380         (WebCore::RenderLayerCompositor::logLayerInfo):
3381         (WebCore::RenderLayerCompositor::reasonsForCompositing):
3382         (WebCore):
3383         (WebCore::RenderLayerCompositor::logReasonsForCompositing):
3384         * rendering/RenderLayerCompositor.h:
3385         (RenderLayerCompositor):
3386
3387 2013-02-21  Takashi Sakamoto  <tasak@google.com>
3388
3389         RenderTable::paintBoxDecorations sometimes draws box-shadow twice.
3390         https://bugs.webkit.org/show_bug.cgi?id=110196
3391
3392         Reviewed by Simon Fraser.
3393
3394         When RenderTable::paintBoxDecorations draws box-shadow, paintBackground
3395         should not draw box-shadow. So we have to provide bleedAvoidance
3396         parameter for RenderBox::paintBackground.
3397
3398         Test: fast/css/table-border-radius-with-box-shadow.html
3399
3400         * rendering/RenderTable.cpp:
3401         (WebCore::RenderTable::paintBoxDecorations):
3402         Provide bleedAvoidance, which determineBackgroundBleedAvoidance
3403         returns, for paintBackground.
3404
3405 2013-02-21  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
3406
3407         Allow to retrieve the request data from abstract TextCheckingRequest to be accessible for WK2
3408         https://bugs.webkit.org/show_bug.cgi?id=110208
3409
3410         Reviewed by Hajime Morrita.
3411
3412         The WebCore changes are required to implement asynchronous spell checking in WK2.
3413         The idea of asynchronous spell checking in WK1 is to pass the pointer to the abstract object
3414         to the client who is able to verify the given text and notify the WebCore about results.
3415         WK2 will extract the request data and pass it (with additional information) to the UIProcess.
3416
3417         No new tests, covered by editing/spelling tests.
3418
3419         * editing/Editor.cpp:
3420         (WebCore::Editor::markAndReplaceFor):
3421         Extract the request data as it is the member of 'TextCheckingRequest'.
3422
3423         * editing/SpellChecker.cpp:
3424         (WebCore):
3425         (WebCore::SpellCheckRequest::didCancel):
3426         (WebCore::SpellCheckRequest::setCheckerAndSequence):
3427         (WebCore::SpellChecker::requestCheckingFor):
3428         (WebCore::SpellChecker::enqueueRequest):
3429         (WebCore::SpellChecker::didCheck):
3430         (WebCore::SpellChecker::didCheckSucceed):
3431         * platform/text/TextChecking.h:
3432         (WebCore):
3433         (TextCheckingRequestData):
3434         Introduce a new 'TextCheckingRequestData' class to keep the request data and to
3435         easy extract it from the 'TextCheckingRequest'.
3436
3437         (WebCore::TextCheckingRequestData::TextCheckingRequestData):
3438         (TextCheckingRequest):
3439         (WebCore::TextCheckingRequest::~TextCheckingRequest):
3440
3441 2013-02-21  Brady Eidson  <beidson@apple.com>
3442
3443         Move fastlog2() to WTF/MathExtras.h so it can be used from multiple projects.
3444
3445         Rubberstamped by Geoff Garen.
3446
3447         * loader/cache/MemoryCache.cpp:
3448         (WebCore::MemoryCache::lruListFor): Remove the inline fastlog2 and use WTF::fastlog2.
3449
3450 2013-02-21  Dimitri Glazkov  <dglazkov@chromium.org>
3451
3452         Split SelectorChecker's fast-checking logic into its own class.
3453         https://bugs.webkit.org/show_bug.cgi?id=106860
3454
3455         Reviewed by Antti Koivisto.
3456
3457         No functional changes, covered by existing tests.
3458
3459         * CMakeLists.txt: Added new class to existing build system.
3460         * GNUmakefile.list.am: Ditto.
3461         * Target.pri: Ditto.
3462         * WebCore.gypi: Ditto.
3463         * WebCore.xcodeproj/project.pbxproj: Ditto.
3464         * css/CSSAllInOne.cpp: Ditto.
3465         * css/RuleSet.cpp:
3466         (WebCore::RuleData::RuleData): Changed to use SelectorCheckerFastPath.
3467         * css/SelectorChecker.cpp:
3468         (WebCore::SelectorChecker::matches): Ditto.
3469         * css/SelectorChecker.h:
3470         (SelectorChecker): Move fast path code into SelectorCheckerFastPath.
3471         * css/SelectorCheckerFastPath.cpp: Added.
3472         * css/SelectorCheckerFastPath.h: Added.
3473         * css/StyleResolver.cpp:
3474         (WebCore::StyleResolver::ruleMatches): Changed to use SelectorCheckerFastPath.
3475         * dom/SelectorQuery.cpp:
3476         (WebCore::SelectorDataList::initialize): Ditto.
3477
3478 2013-02-21  Tony Gentilcore  <tonyg@chromium.org>
3479
3480         Invalidate outstanding checkpoints for the background input stream and preload scanner
3481         https://bugs.webkit.org/show_bug.cgi?id=110537
3482
3483         Reviewed by Adam Barth.
3484
3485         fast/tokenizer/write-before-load.html caused duplicate didFailSpeculation() calls for the same checkpoint.
3486         One was triggered by processParsedChunkFromBackgroundParser and the other by resumeParsingAfterScriptExecution.
3487         This change ensures that after we send a checkpoint, it is cleared so it won't be sent again until the next
3488         processParsedChunkFromBackgroundParser().
3489
3490         No new tests because no new functionality.
3491
3492         * html/parser/BackgroundHTMLInputStream.cpp:
3493         (WebCore::BackgroundHTMLInputStream::rewindTo):
3494         * html/parser/HTMLDocumentParser.cpp:
3495         (WebCore::HTMLDocumentParser::didFailSpeculation):
3496         * html/parser/HTMLPreloadScanner.cpp:
3497         (WebCore::TokenPreloadScanner::rewindTo):
3498
3499 2013-02-21  Dean Jackson  <dino@apple.com>
3500
3501         Followup commit for https://bugs.webkit.org/show_bug.cgi?id=110541
3502         from a comment by Jon Lee.
3503
3504         * html/HTMLPlugInImageElement.cpp:
3505         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Logic
3506         in conditional was unnecessarily complex.
3507
3508 2013-02-21  Ojan Vafai  <ojan@chromium.org>
3509
3510         Clean up computePreferredLogicalWidths functions in TableLayout subclasses
3511         https://bugs.webkit.org/show_bug.cgi?id=110515
3512
3513         Reviewed by Tony Chang.
3514
3515         No change in behavior. This is just a cleanup in preparation for other
3516         refactoring to this code.
3517
3518         * rendering/FixedTableLayout.cpp:
3519         (WebCore::FixedTableLayout::calcWidthArray):
3520         Move a FIXME here from computePreferredLogicalWidths. It makes more sense here.
3521         (WebCore::FixedTableLayout::computePreferredLogicalWidths):
3522         -Remove outdated or unhelpful comments.
3523         -Isolate the fixed width codepath to make it a bit less convoluted.
3524         (WebCore::FixedTableLayout::layout):
3525         * rendering/FixedTableLayout.h:
3526         The argument to calcWidthArray is never used. Remove it.
3527
3528 2013-02-21  Eric Seidel  <eric@webkit.org>
3529
3530         LayoutTests/fast/encoding/parser-tests-*.html timeout with threaded HTML parser
3531         https://bugs.webkit.org/show_bug.cgi?id=109995
3532
3533         Unreviewed speculative fix for Mac WK1.
3534
3535         It appears that m_frame can be null for Mac WK1.
3536
3537         * loader/DocumentLoader.cpp:
3538         (WebCore::DocumentLoader::isLoading):
3539
3540 2013-02-21  Dean Jackson  <dino@apple.com>
3541
3542         Better sizing model for Snapshotted plugins
3543         https://bugs.webkit.org/show_bug.cgi?id=110541
3544
3545         Reviewed by Simon Fraser.
3546
3547         Clarify the way we apply sizing rules to snapshotted plug-ins. In
3548         testing we've found that plug-ins smaller than 40px in either
3549         dimension should never be frozen. Also, larger plugins should
3550         be explicitly marked, because often they are the single dominant
3551         element on the page.
3552
3553         As a drive-by, I removed the flag that indicated whether or not
3554         the label should show automatically. It wasn't being used. This is
3555         all determined from the shadow root and its CSS now.
3556
3557         * html/HTMLPlugInImageElement.cpp:
3558         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): New values for size thresholds.
3559         (WebCore::HTMLPlugInImageElement::createRenderer): Remove call to setShouldShowSnapshotLabelAutomatically.
3560         (WebCore::classNameForShadowRoot): Remove logging and clearly assign sizing classes.
3561         (WebCore::HTMLPlugInImageElement::updateSnapshotInfo): We don't need the page size any more.
3562         (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Use new constant names.
3563         * html/HTMLPlugInImageElement.h:
3564         (HTMLPlugInImageElement): Remove setShouldShowSnapshotLabelAutomatically.
3565
3566 2013-02-21  Benjamin Poulain  <benjamin@webkit.org>
3567
3568         Fix the build after r143664.
3569
3570         Unreviewed.
3571
3572         * WebCore.exp.in:
3573
3574 2013-02-21  Eric Seidel  <eric@webkit.org>
3575
3576         tables/mozilla/bugs/bug8950.html fails with threaded parser due to attribute duplication
3577         https://bugs.webkit.org/show_bug.cgi?id=110532
3578
3579         Reviewed by Adam Barth.
3580
3581         This is a very basic failure which we should have caught earlier with the html5lib parser
3582         tests, except those use document.write and thus avoid the threaded parser.
3583
3584         AtomicHTMLToken expects its attributes to be unique.  We were not doing that for the
3585         CompactHTMLToken path, and this ancient mozilla table test caught that.
3586
3587         Fixes tables/mozilla/bugs/bug8950.html.
3588
3589         * html/parser/AtomicHTMLToken.h:
3590         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
3591         (WebCore::AtomicHTMLToken::initializeAttributes):
3592
3593 2013-02-21  Adam Barth  <abarth@webkit.org>
3594
3595         Threaded HTML Parser fails fast/dom/Document/readystate.html
3596         https://bugs.webkit.org/show_bug.cgi?id=110529
3597
3598         Reviewed by Eric Seidel.
3599
3600         We need to create the tokenizer even when we finish a script-created
3601         parser. Most of the time, the tokenizer has already been created at
3602         this point because it is created by calls to document.write.
3603
3604         Test: fast/parser/body-should-exist-after-open-close.html
3605
3606         * html/parser/HTMLDocumentParser.cpp:
3607         (WebCore::HTMLDocumentParser::finish):
3608
3609 2013-02-21  Emil A Eklund  <eae@chromium.org>
3610
3611         Lots of LayoutUnit assertions when loading a Wikipedia article
3612         https://bugs.webkit.org/show_bug.cgi?id=110270
3613
3614         Reviewed by Levi Weintraub.
3615         
3616         Change RenderBlock::adjustRectForColumns to ensure that the
3617         endColumn calculation does not overflow.
3618
3619         No new tests, covered by existing tests.
3620
3621         * rendering/RenderBlock.cpp:
3622         (WebCore::RenderBlock::adjustRectForColumns):
3623         Make the endOffset value be no less than the beforeBorderPadding
3624         value to ensure that endColumn is not negative.
3625
3626 2013-02-21  Eric Seidel  <eric@webkit.org>
3627
3628         LayoutTests/fast/encoding/parser-tests-*.html timeout with threaded HTML parser
3629         https://bugs.webkit.org/show_bug.cgi?id=109995
3630
3631         Reviewed by Adam Barth.
3632
3633         In the case where during main document onload, we
3634         load a new iframe, and then from within that iframe
3635         we run script to remove the iframe and call testRunner.notifyDone()
3636         the notifyDone() will not correctly dump because
3637         the testRunner does not yet realize that the main resource
3638         has completed loading.
3639
3640         In the main-thread parser, the testRunner does correctly know
3641         that the main thread has completed, because removing the iframe
3642         causes a didFailLoad callback to the embedder, because when
3643         the iframe is being removed, the DocumentLoader for that iframe
3644         is still on the stack and believe's its loading
3645         (because it has a MainResourceLoader which is also on the stack
3646         delivering us the bytes which contain this inline script).
3647
3648         In the threaded-parser case, the DocumentLoader and MainResourceLoader
3649         are no longer on the stack, as we are parsing the iframe asynchronously
3650         after all the bytes have been delivered, and the MainResourceLoader destroyed.
3651         Thus when DocumentLoader::stopLoading() is called, loading() returns
3652         false, and it returns early.  One might argue that we should remove that
3653         early return entirely, but it seemed safer to extend the idea of
3654         when we're loading to include the time when the parser is active.
3655
3656         This patch solves this by teaching the DocumentLoader that it is still
3657         "loading" so long as the parser is still active.
3658
3659         Also added a call to DocumentLoader::checkLoadComplete from
3660         Document::decrementActiveParserCount which seemed to cause
3661         http/tests/multipart/policy-ignore-crash.php to pass.
3662
3663         This causes http/tests/security/feed-urls-from-remote.html to timeout
3664         on chromium (but no other platforms that I'm aware of).  I believe this
3665         is due to a bug in our DRT implementation in the policyDelegate case
3666         (which AFAIK is not a codepath which Chromium actually uses in the wild).
3667         The test already times out on TOT if you remove the setCustomPolicyDelegate calls!
3668
3669         * loader/DocumentLoader.cpp:
3670         (WebCore::DocumentLoader::isLoading):
3671         (WebCore):
3672         * loader/DocumentLoader.h:
3673         (DocumentLoader):
3674
3675 2013-02-21  Erik Arvidsson  <arv@chromium.org>
3676
3677         Nodes should not have attributes property
3678         https://bugs.webkit.org/show_bug.cgi?id=110510
3679
3680         Reviewed by Adam Barth.
3681
3682         According to http://dom.spec.whatwg.org/ attributes and hasAttributes
3683         should be defined on Element and not on Node.
3684
3685         Test: fast/dom/Text/text-should-not-have-attributes.html
3686
3687         * dom/Element.idl:
3688         * dom/Node.idl:
3689
3690 2013-02-21  Tony Gentilcore  <tonyg@chromium.org>
3691
3692         Make BackgroundHTMLParser rewind the preload scanner instead of clear it
3693         https://bugs.webkit.org/show_bug.cgi?id=110517
3694
3695         Reviewed by Adam Barth.
3696
3697         No new tests becuase no new functionality.
3698
3699         * html/parser/BackgroundHTMLParser.cpp:
3700         (WebCore::BackgroundHTMLParser::resumeFrom):
3701         (WebCore::BackgroundHTMLParser::pumpTokenizer):
3702         (WebCore::BackgroundHTMLParser::sendTokensToMainThread):
3703         * html/parser/BackgroundHTMLParser.h:
3704         (Checkpoint):
3705         * html/parser/HTMLDocumentParser.cpp:
3706         (WebCore::HTMLDocumentParser::didFailSpeculation):
3707         * html/parser/HTMLDocumentParser.h:
3708         (ParsedChunk):
3709         * html/parser/HTMLPreloadScanner.cpp:
3710         (WebCore::TokenPreloadScanner::createCheckpoint):
3711         (WebCore):
3712         (WebCore::TokenPreloadScanner::rewindTo):
3713         * html/parser/HTMLPreloadScanner.h:
3714         (WebCore):
3715         (TokenPreloadScanner):
3716         (WebCore::TokenPreloadScanner::Checkpoint::Checkpoint):
3717         (Checkpoint):
3718
3719 2013-02-21  Sheriff Bot  <webkit.review.bot@gmail.com>
3720
3721         Unreviewed, rolling out r143536.
3722         http://trac.webkit.org/changeset/143536
3723         https://bugs.webkit.org/show_bug.cgi?id=110523
3724
3725         Causing a bunch of tests to fail on Windows, requires
3726         rebaselining (Requested by rfong on #webkit).
3727
3728         * config.h:
3729         * page/Settings.cpp:
3730         (WebCore):
3731         (WebCore::Settings::setShouldPaintNativeControls):
3732         * page/Settings.h:
3733         (Settings):
3734         (WebCore::Settings::shouldPaintNativeControls):
3735         * platform/win/ScrollbarThemeWin.cpp:
3736         (WebCore):
3737         * rendering/RenderThemeWin.cpp:
3738         (WebCore):
3739
3740 2013-02-21  Simon Fraser  <simon.fraser@apple.com>
3741
3742         Don't make an overhang shadow layer when the WKView has a transparent background
3743         https://bugs.webkit.org/show_bug.cgi?id=110429
3744
3745         Reviewed by Anders Carlsson.
3746
3747         When in coordinated scrolling mode, RenderLayerCompositor makes a layer to show
3748         the shadow around the content when rubber-banding. However, if the view is
3749         transparent, we don't want to make this layer, since it darkens the entire view.
3750
3751         * rendering/RenderLayerBacking.cpp:
3752         (WebCore::RenderLayerBacking::updateRootLayerConfiguration): Code was moved
3753         into viewHasTransparentBackground(), so just call that here.
3754         * rendering/RenderLayerCompositor.cpp:
3755         (WebCore::RenderLayerCompositor::requiresContentShadowLayer): Don't make
3756         a shadow layer when the view is transparent.
3757         (WebCore::RenderLayerCompositor::viewHasTransparentBackground): Return
3758         true if the view is transparent or has a non-opaque background color,
3759         and optionally return that color.
3760         * rendering/RenderLayerCompositor.h:
3761
3762 2013-02-21  Simon Fraser  <simon.fraser@apple.com>
3763
3764         [Safari] Crash with opacity + drop shadow filter + child element extending beyond filter outsets
3765         https://bugs.webkit.org/show_bug.cgi?id=107467
3766
3767         Reviewed by Dean Jackson.
3768         
3769         The filter code plays games with the current GraphicsContext, replacing the current
3770         context with one which will get filtered.
3771         
3772         This doesn't play nicely with the RenderLayer code which lazily starts transparency
3773         layers. If we don't start a transparency layer until painting a child of the filtered
3774         layer, then the transparency layer is started using the wrong context.
3775         
3776         Fix by eagerly starting transparency layers if we have both a filter and opacity.
3777
3778         Test: css3/filters/filter-with-opacity-and-children.html
3779
3780         * rendering/RenderLayer.cpp:
3781         (WebCore::RenderLayer::paintLayerContents):
3782
3783 2013-02-21  Tony Chang  <tony@chromium.org>
3784
3785         Autogenerate Settings that call setNeedsRecalcStyleInAllFrames when set
3786         https://bugs.webkit.org/show_bug.cgi?id=109989
3787
3788         Reviewed by Ryosuke Niwa.
3789
3790         Start generating the code for settings that call m_page->setNeedsRecalcStyleInAllFrames()
3791         when the value is changed. This allows us to generate 10 more settings. As a follow up, we
3792         can remove some methods from DRT/WTR after this.
3793
3794         No new tests, this is a build refactor and should not impact any test results.
3795
3796         * page/Settings.cpp:
3797         (WebCore::Settings::Settings): Remove member variables. Add SETTINGS_SETTER_BODIES macro that
3798         has the generated setter bodies.
3799         * page/Settings.h:
3800         (Settings): Remove code that is now generated.
3801         * page/Settings.in: Add new entries with setNeedsStyleRecalcWhenSetting=1
3802         * page/make_settings.pl:
3803         (defaultItemFactory): Add setNeedsStyleRecalcWhenSetting flag.
3804         (generateSettingsMacrosHeader): Print macro for setter bodies.
3805         (printConditionalMacros): Add setter body code.
3806         (printGettersAndSetters): Pass in setNeedsStyleRecalcWhenSetting so we know whether to inline the
3807         setter in the header or not.
3808         (printGetterAndSetter): Ditto.
3809         (printSetterBodies): Print macro for setter bodies.
3810         (printSetterBody): Print setter body for a single setting.
3811
3812 2013-02-21  Dean Jackson  <dino@apple.com>
3813
3814         Plug-in snapshotting code always accepts first snapshot
3815         https://bugs.webkit.org/show_bug.cgi?id=110495
3816
3817         Reviewed by Tim Horton.
3818
3819         When we detect a plugin that can be snapshotted we start capturing
3820         images until we find one that we believe isn't blank, or we timeout.
3821         I introduced a regression recently where we swap renderers as
3822         soon as the snapshot arrives, whether or not is is blank.
3823
3824         The fix was to have the embedder (currently only WK2) be the one
3825         who tells the HTMLPlugInElement to start displaying snapshots.
3826
3827         I also reduced the number of snapshot attempts we will make before
3828         giving up. We don't want to sit around for 66 seconds displaying nothing.
3829
3830         * html/HTMLPlugInElement.h:
3831         (WebCore::HTMLPlugInElement::setDisplayState): Make this a virtual function.
3832         * html/HTMLPlugInImageElement.cpp:
3833         (WebCore::HTMLPlugInImageElement::setDisplayState): Override to call the
3834             base class version, but swap renderers if we should move to the snapshot.
3835         (WebCore::HTMLPlugInImageElement::updateSnapshot): Don't swap renderers here any more.
3836         * html/HTMLPlugInImageElement.h: New virtual version of setDisplayState.
3837
3838 2013-02-21  Tony Gentilcore  <tonyg@chromium.org>
3839
3840         Tune BackgroundHTMLParser's pendingTokenLimit based on a benchmark
3841         https://bugs.webkit.org/show_bug.cgi?id=110408
3842
3843         Reviewed by Adam Barth.
3844
3845         This constant was tuned by running the top 25 sites in Telemetry on a Nexus 7 device.
3846         The new value decreases the maximum time spent parsing by 40% without significantly impacting total parse time or DOMContentLoaded.
3847
3848         No new tests because no new functionality.
3849
3850         * html/parser/BackgroundHTMLParser.cpp:
3851         (WebCore):
3852
3853 2013-02-21  Sheriff Bot  <webkit.review.bot@gmail.com>
3854
3855         Unreviewed, rolling out r143419.
3856         http://trac.webkit.org/changeset/143419
3857         https://bugs.webkit.org/show_bug.cgi?id=110507
3858
3859         Broke border-image on Mac (Requested by jpfau on #webkit).
3860
3861         * platform/graphics/GraphicsContext.cpp:
3862         (WebCore::GraphicsContext::drawTiledImage):
3863         * platform/graphics/GraphicsContext.h:
3864         (GraphicsContext):
3865         * platform/graphics/Image.cpp:
3866         (WebCore::Image::drawTiled):
3867         * platform/graphics/Image.h:
3868         (Image):
3869         * rendering/RenderBoxModelObject.cpp:
3870         (WebCore::RenderBoxModelObject::paintNinePieceImage):
3871
3872 2013-02-21  Tom Sepez  <tsepez@chromium.org>
3873
3874         XSSAuditor should block pages by redirecting to a sandboxed data: URL.
3875         https://bugs.webkit.org/show_bug.cgi?id=110406
3876
3877         Reviewed by Adam Barth.
3878
3879         Patch originally by mkwst@chromium.org. 
3880         Tests: http/tests/security/xssAuditor/block-does-not-leak-location.html
3881                http/tests/security/xssAuditor/block-does-not-leak-referrer.html
3882                http/tests/security/xssAuditor/full-block-script-tag-cross-domain.html
3883
3884         * html/parser/XSSAuditorDelegate.cpp:
3885         (WebCore::XSSAuditorDelegate::didBlockScript):
3886             When blocking entire pages via the XSSAuditor, redirect to a data:
3887             URL to ensure that requests for properties don't leak information.
3888         
3889 2013-02-21  Christian Biesinger  <cbiesinger@chromium.org>
3890
3891         Convert buttons from DeprecatedFlexBox to nondeprecated FlexibleBox
3892         https://bugs.webkit.org/show_bug.cgi?id=109994
3893
3894         Reviewed by Ojan Vafai.
3895
3896         Covered by existing tests for <button> and <input
3897         type="button|submit|reset">
3898
3899         * css/html.css:
3900         (input[type="button"], input[type="submit"], input[type="reset"], input[type="file"]::-webkit-file-upload-button, button):
3901         Convert from box-align to align-items. We are using flex-start here in
3902         conjunction with an auto margin for correct centering. See
3903         RenderButton.cpp below for the margin & more explanation.
3904
3905         * rendering/RenderBlock.cpp:
3906         (WebCore::RenderBlock::createAnonymousWithParentRendererAndDisplay):
3907         Add a case for creating a non-deprecated flex box.
3908
3909         * rendering/RenderButton.cpp:
3910         (WebCore::RenderButton::RenderButton):
3911         (WebCore::RenderButton::addChild):
3912         (WebCore::RenderButton::removeChild):
3913         Forward to new base class
3914         (WebCore::RenderButton::styleWillChange):
3915         (WebCore::RenderButton::setupInnerStyle):
3916         We are now using flexbox properties.
3917         - min-width is needed for correct shrinking of the contents
3918         - margin-top and margin-bottom are used for correct centering. We
3919         can't use align-items: center because results are incorrect when the
3920         content overflows. See LayoutTests/fast/forms/control-clip.html
3921
3922         * rendering/RenderButton.h:
3923         Inherit from RenderFlexibleBox
3924
3925         * rendering/RenderFlexibleBox.cpp:
3926         (WebCore::RenderFlexibleBox::createAnonymous):
3927         (WebCore):
3928         * rendering/RenderFlexibleBox.h:
3929         (RenderFlexibleBox):
3930         Add a createAnonymous function to RenderFlexibleBox.
3931
3932 2013-02-21  John Mellor  <johnme@chromium.org>
3933
3934         [chromium] Simplify computation of screenRect/windowRect.
3935         https://bugs.webkit.org/show_bug.cgi?id=110456
3936
3937         Reviewed by Adam Barth.
3938
3939         This patch removes applyDeviceScaleFactorInCompositor checks
3940         added by http://trac.webkit.org/changeset/139356 because
3941         Chrome for Android now sizes its screen and window in DIP
3942         units (like other platforms), so they are no longer necessary.
3943
3944         No new tests, since this is just removing an unused codepath.
3945
3946         * platform/chromium/PlatformScreenChromium.cpp:
3947         (WebCore::screenRect):
3948         (WebCore::screenAvailableRect):
3949         * rendering/TextAutosizer.cpp:
3950         (WebCore::TextAutosizer::processSubtree):
3951
3952 2013-02-21  Beth Dakin  <bdakin@apple.com>
3953
3954         Out-of-view fixed position check should not be affected by page scale at all on Mac
3955         https://bugs.webkit.org/show_bug.cgi?id=110294
3956         -and corresponding-
3957         <rdar://problem/13247582>
3958
3959         Reviewed by Simon Fraser.
3960
3961         Don't scale the layerBounds. Generally, the layerBounds should be relative to the 
3962         viewBounds which are also unscaled. Chromium used to want this behavior, but it is 
3963         covered by their pageScaleFactorAppliedInCompositor implementation now.
3964
3965         * rendering/RenderLayerCompositor.cpp:
3966         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
3967
3968 2013-02-21  Philip Rogers  <pdr@google.com>
3969
3970         Stop starting animations when leaving a page
3971         https://bugs.webkit.org/show_bug.cgi?id=110257
3972
3973         Reviewed by Stephen Chenney.
3974
3975         SVGImage::resetAnimation() incorrectly started animations which could cause a crash
3976         when leaving the page. This patch fixes resetAnimation to only stop the animation,
3977         similar to BitmapImage::resetAnimation().
3978
3979         Additionally, this patch removes an unneeded call to Document::updateStyleForAllDocuments()
3980         that was present in the animation loop. This makes the animation code more resistant to
3981         similar bugs in the future.
3982
3983         Both of these changes are functionally covered with existing tests.
3984
3985         Test: svg/animations/reset-animation-crash.html
3986
3987         * svg/animation/SMILTimeContainer.cpp:
3988         (WebCore::SMILTimeContainer::updateAnimations):
3989         * svg/graphics/SVGImage.cpp:
3990         (WebCore::SVGImage::resetAnimation):
3991
3992 2013-02-19  Mark Hahnenberg  <mhahnenberg@apple.com>
3993
3994         Objective-C API: Need a way to use the Objective-C JavaScript API with WebKit
3995         https://bugs.webkit.org/show_bug.cgi?id=106059
3996
3997         Reviewed by Geoffrey Garen.
3998
3999         * WebCore.exp.in:
4000         * bindings/js/JSDOMWindowShell.cpp:
4001         (WebCore::JSDOMWindowShell::setWindow): Since we're basically abandoning a JSDOMWindow here, we call
4002         garbageCollectSoon().
4003         * bindings/js/JSDOMWindowShell.h:
4004         * bindings/js/ScriptController.h: New function to get the JSContext for the global object of the current main world.
4005         * bindings/js/ScriptControllerMac.mm: 
4006         (WebCore::ScriptController::javaScriptContext): Ditto.
4007         * bindings/objc/WebScriptObject.h: Added ifdef guards. Also new convenience conversion function for the JSC Obj-C API.
4008         * bindings/objc/WebScriptObject.mm: JSC::JSValue and JSValue conflict with one another, so we have to be more specific.
4009         (-[WebScriptObject _globalContextRef]): Useful helper function for getting the JSGlobalContextRef of a particular WebScriptObject.
4010         (-[WebScriptObject callWebScriptMethod:withArguments:]):
4011         (-[WebS