hidden attribute on <input type=file /> suppresses the file selection dialog
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-02-02  Rakesh KN  <rakesh.kn@motorola.com>
2
3         hidden attribute on <input type=file /> suppresses the file selection dialog
4         https://bugs.webkit.org/show_bug.cgi?id=58208
5
6         Reviewed by Ryosuke Niwa.
7
8         We want to allow opening file dialog on hidden element when click() is called
9         on the element. The behaviour is similar to Firefox and IE.
10
11         Added manual test as the file dialog opens only on user gesture.
12
13         * html/FileInputType.cpp:
14         (WebCore::FileInputType::handleDOMActivateEvent):
15         Removed renderer check as input can be hidden.
16
17 2012-02-01  Philippe Normand  <pnormand@igalia.com>
18
19         [GStreamer] FFTFrame implementation
20         https://bugs.webkit.org/show_bug.cgi?id=73545
21
22         Reviewed by Chris Rogers.
23
24         FFTFrame implementation based on GStreamer's FFT processing
25         library.
26
27         No new tests, existing WebAudio tests cover this.
28
29         * GNUmakefile.am:
30         * GNUmakefile.list.am:
31         * platform/audio/FFTFrame.h:
32         * platform/audio/FFTFrameStub.cpp:
33         * platform/audio/gstreamer/FFTFrameGStreamer.cpp: Added.
34         (WebCore::FFTFrame::FFTFrame):
35         (WebCore::FFTFrame::initialize):
36         (WebCore::FFTFrame::cleanup):
37         (WebCore::FFTFrame::~FFTFrame):
38         (WebCore::FFTFrame::multiply):
39         (WebCore::FFTFrame::doFFT):
40         (WebCore::FFTFrame::doInverseFFT):
41         (WebCore::FFTFrame::realData):
42         (WebCore::FFTFrame::imagData):
43
44 2012-02-02  Kentaro Hara  <haraken@chromium.org>
45
46         Rename [CheckFrameSecurity] and [SVGCheckSecurity] to [CheckAccessToNode]
47         https://bugs.webkit.org/show_bug.cgi?id=77601
48
49         Reviewed by Adam Barth.
50
51         [CheckFrameSecurity] and [SVGCheckSecurity] have the same meaning; i.e. generate code
52         to check allowAccessToNode() for a given attribute or method. This patch renames them
53         to [CheckAccessToNode].
54
55         No tests. No changes in behavior.
56
57         * bindings/scripts/CodeGeneratorJS.pm:
58         (GenerateImplementation):
59         * bindings/scripts/CodeGeneratorV8.pm:
60         (GenerateNormalAttrGetter):
61         (GenerateFunctionCallback):
62         * html/HTMLEmbedElement.idl:
63         * html/HTMLFrameElement.idl:
64         * html/HTMLIFrameElement.idl:
65         * html/HTMLObjectElement.idl:
66
67         * bindings/scripts/test/TestObj.idl:
68         * bindings/scripts/test/V8/V8TestObj.cpp: Updated the test results.
69         (WebCore):
70
71 2012-02-01  Kentaro Hara  <haraken@chromium.org>
72
73         Rename [V8DisallowShadowing] to [V8Unforgeable]
74         https://bugs.webkit.org/show_bug.cgi?id=77599
75
76         Reviewed by Adam Barth.
77
78         This patch renames [V8DisallowShadowing] to [V8Unforgeable], following the Web IDL
79         spec (http://dev.w3.org/2006/webapi/WebIDL/#Unforgeable).
80
81         No tests. No change in behavior.
82
83         * bindings/scripts/CodeGeneratorV8.pm:
84         (GenerateNormalAttrGetter):
85         (GenerateSingleBatchedAttribute):
86         (GenerateImplementation):
87         * page/DOMWindow.idl:
88         * page/Location.idl:
89
90 2012-02-01  Kentaro Hara  <haraken@chromium.org>
91
92         Rename [ConvertNullToNullString] to [TreatNullAs=EmptyString]
93         https://bugs.webkit.org/show_bug.cgi?id=77602
94
95         Reviewed by Adam Barth.
96
97         This patch renames [ConvertNullToNullString] to [TreatNullAs=EmptyString],
98         according to the spec (http://dev.w3.org/2006/webapi/WebIDL/#TreatNullAs).
99
100         No tests. No changes in behavior.
101
102         * bindings/scripts/CodeGeneratorJS.pm:
103         (JSValueToNative):
104         * bindings/scripts/CodeGeneratorV8.pm:
105         (GetNativeTypeFromSignature):
106
107         * css/CSSCharsetRule.idl:
108         * css/CSSPageRule.idl:
109         * css/CSSRule.idl:
110         * css/CSSStyleDeclaration.idl:
111         * css/CSSStyleRule.idl:
112         * css/CSSValue.idl:
113         * css/MediaList.idl:
114         * css/WebKitCSSKeyframesRule.idl:
115         * dom/Attr.idl:
116         * dom/CharacterData.idl:
117         * dom/DOMImplementation.idl:
118         * dom/Document.idl:
119         * dom/Element.idl:
120         * dom/NamedNodeMap.idl:
121         * dom/Node.idl:
122         * dom/ProcessingInstruction.idl:
123         * dom/ShadowRoot.idl:
124         * html/HTMLAnchorElement.idl:
125         * html/HTMLButtonElement.idl:
126         * html/HTMLDocument.idl:
127         * html/HTMLElement.idl:
128         * html/HTMLFormElement.idl:
129         * html/HTMLFrameElement.idl:
130         * html/HTMLInputElement.idl:
131         * html/HTMLMediaElement.idl:
132         * html/HTMLOutputElement.idl:
133         * html/HTMLScriptElement.idl:
134         * html/HTMLSelectElement.idl:
135         * html/HTMLTextAreaElement.idl:
136         * html/HTMLTitleElement.idl:
137         * html/canvas/CanvasRenderingContext2D.idl:
138         * page/DOMWindow.idl:
139         * storage/StorageEvent.idl:
140         * svg/SVGAngle.idl:
141         * svg/SVGElement.idl:
142         * svg/SVGLength.idl:
143         * svg/SVGScriptElement.idl:
144
145         * bindings/scripts/test/TestObj.idl: No change in the run-bindings-tests results.
146
147 2012-02-01  Kentaro Hara  <haraken@chromium.org>
148
149         Remove [GenerateConstructor] from IDL files
150         https://bugs.webkit.org/show_bug.cgi?id=77598
151
152         Reviewed by Adam Barth.
153
154         [GenerateConstructor] is used in some IDL files but it is not implemented
155         in code generators. I could not find any history about [GenerateConstructor]
156         in code generators. This patch removes them from IDL files.
157
158         Maybe we want to replace [GenerateConstructor] with [Constructor] eventually,
159         but currently no tests are written for their constructors (e.g. "new DOMTokenList()").
160         So simply removing them would make sense.
161
162         No new tests. No change in behavior.
163
164         * dom/DOMStringList.idl:
165         * html/DOMSettableTokenList.idl:
166         * html/DOMTokenList.idl:
167         * svg/SVGFEConvolveMatrixElement.idl:
168         * webaudio/AudioPannerNode.idl:
169
170 2012-02-01  Eric Carlson  <eric.carlson@apple.com>
171
172         Consider user's preferred language when choosing text tracks
173         https://bugs.webkit.org/show_bug.cgi?id=74121
174
175         Reviewed by Alexey Proskuryakov.
176
177         Tests: media/track/track-language-preference.html
178                media/track/track-prefer-captions.html
179
180         * html/HTMLMediaElement.cpp:
181         (WebCore::HTMLMediaElement::loadTimerFired): configureTextTracks -> configureNewTextTracks.
182         (WebCore::HTMLMediaElement::textTracksAreReady): Add more comments.
183         (WebCore::HTMLMediaElement::textTrackModeChanged): Ditto.
184         (WebCore::HTMLMediaElement::showingTrackWithSameKind): Minor restructuring.
185         (WebCore::HTMLMediaElement::userIsInterestedInThisTrackKind): Renamed from userIsInterestedInThisTrack,
186             don't consider user's language preference.
187         (WebCore::HTMLMediaElement::configureTextTrackGroup): New, configure all tracks in a group, 
188             considering user's kind and language preferences.
189         (WebCore::HTMLMediaElement::configureNewTextTracks): New, configure all newly added tracks.
190         * html/HTMLMediaElement.h:
191         (WebCore::HTMLMediaElement::TrackGroup::TrackGroup):
192         (TrackGroup):
193
194         * platform/Language.cpp:
195         (WebCore::canonicalLanguageIdentifier): New, create a canonicalized version of a language string.
196         (WebCore::bestMatchingLanguage): New, return the language from the list that best matches the 
197             specified language.
198         (WebCore::preferredLanguageFromList): New, return the language in the specified list that best
199             matches the user's language preference.
200         * platform/Language.h:
201
202         * testing/Internals.cpp:
203         (WebCore::Internals::setShouldDisplayTrackType): New, allow DRT to set the track type preference.
204         (WebCore::Internals::shouldDisplayTrackType): New, allow DRT to read the track type preference.
205         * testing/Internals.h:
206         * testing/Internals.idl:
207
208 2012-02-01  Hayato Ito  <hayato@chromium.org>
209
210         Change class hierarycy so that ShadowRoot can inherit DocumentFragment.
211         https://bugs.webkit.org/show_bug.cgi?id=76693
212
213         Reviewed by Darin Adler.
214
215         Make ShadowRoot inherit DocumentFragment so that it matches the class hierarchy of IDL in the spec.
216         TreeScope becomes a separated class, which is now inherited by Document and ShadowRoot using multiple-inheritance.
217         This patch is pre-requirement for coming IDL change.
218
219         No tests. No change in behavior.
220
221         * dom/Document.cpp:
222         (WebCore::Document::Document):
223         (WebCore::Document::~Document):
224         (WebCore::Document::buildAccessKeyMap):
225         (WebCore::Document::childrenChanged):
226         (WebCore::Document::attach):
227         (WebCore::Document::detach):
228         * dom/Document.h:
229         (Document):
230         * dom/DocumentFragment.cpp:
231         (WebCore::DocumentFragment::DocumentFragment):
232         * dom/DocumentFragment.h:
233         (DocumentFragment):
234         * dom/DocumentOrderedMap.cpp:
235         (WebCore::DocumentOrderedMap::get):
236         * dom/ShadowRoot.cpp:
237         (WebCore::ShadowRoot::ShadowRoot):
238         (WebCore::ShadowRoot::~ShadowRoot):
239         (WebCore::ShadowRoot::attach):
240         * dom/ShadowRoot.h:
241         * dom/TreeScope.cpp:
242         (WebCore::TreeScope::TreeScope):
243         (WebCore::TreeScope::~TreeScope):
244         (WebCore::TreeScope::setParentTreeScope):
245         (WebCore::TreeScope::getImageMap):
246         (WebCore::TreeScope::findAnchor):
247         * dom/TreeScope.h:
248         (WebCore):
249         (WebCore::TreeScope::rootNode):
250         (TreeScope):
251         * dom/TreeScopeAdopter.cpp:
252         (WebCore::TreeScopeAdopter::moveTreeToNewScope):
253         * page/DragController.cpp:
254         (WebCore::asFileInput):
255         * page/FocusController.cpp:
256         (WebCore::ownerOfTreeScope):
257         (WebCore::FocusController::nextFocusableNode):
258         (WebCore::FocusController::previousFocusableNode):
259
260 2012-02-01  Benjamin Poulain  <bpoulain@apple.com>
261
262         WorkerScriptController::evaluate() should not return anything
263         https://bugs.webkit.org/show_bug.cgi?id=77587
264
265         Reviewed by Adam Barth.
266
267         Remove the return value from WorkerScriptController as it is
268         (and should be) unused.
269
270         * bindings/js/WorkerScriptController.cpp:
271         (WebCore::WorkerScriptController::evaluate):
272         * bindings/js/WorkerScriptController.h:
273         (WorkerScriptController):
274         * bindings/v8/WorkerScriptController.cpp:
275         (WebCore::WorkerScriptController::evaluate):
276         * bindings/v8/WorkerScriptController.h:
277         (WorkerScriptController):
278
279 2012-02-01  Kentaro Hara  <haraken@chromium.org>
280
281         Remove [DelegatingPrototypeGetOwnPropertySlot], [HasCustomIndexGetter],
282         [HasIndexSetter], [JSConstructorTemplate] and [NonEmpty] from code generators
283         https://bugs.webkit.org/show_bug.cgi?id=77585
284
285         Reviewed by Adam Barth.
286
287         This patch removes [DelegatingPrototypeGetOwnPropertySlot], [HasCustomIndexGetter],
288         [HasIndexSetter], [JSConstructorTemplate] and [NonEmpty] from code generators,
289         since they are not used by no IDL files.
290
291         No tests. No change in behavior.
292
293         * bindings/scripts/CodeGenerator.pm:
294         (GetterExpression):
295         * bindings/scripts/CodeGeneratorJS.pm:
296         (GenerateGetOwnPropertySlotBody):
297         (GenerateGetOwnPropertyDescriptorBody):
298         (GenerateHeader):
299         (GenerateImplementation):
300         (IsConstructable):
301         (IsConstructorTemplate):
302
303         * bindings/scripts/test/TestObj.idl:
304         * bindings/scripts/test/CPP/WebDOMTestObj.cpp: Updated the run-bindings-tests results.
305         * bindings/scripts/test/CPP/WebDOMTestObj.h: Ditto.
306         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp: Ditto.
307         (webkit_dom_test_obj_set_property):
308         (webkit_dom_test_obj_get_property):
309         (webkit_dom_test_obj_class_init):
310         * bindings/scripts/test/GObject/WebKitDOMTestObj.h: Ditto.
311         * bindings/scripts/test/JS/JSTestObj.cpp: Ditto.
312         (WebCore):
313         * bindings/scripts/test/JS/JSTestObj.h: Ditto.
314         (WebCore):
315         * bindings/scripts/test/ObjC/DOMTestObj.h: Ditto.
316         * bindings/scripts/test/ObjC/DOMTestObj.mm: Ditto.
317         * bindings/scripts/test/V8/V8TestObj.cpp: Ditto.
318         (WebCore):
319
320 2012-02-01  Shinya Kawanaka  <shinyak@google.com>
321
322         Select attribute of HTMLContentElement should be able be changed dynamically.
323         https://bugs.webkit.org/show_bug.cgi?id=76261
324
325         Reviewed by Hajime Morita.
326
327         When select attribute is changed, the flag to recalc style is set.
328
329         Test: fast/dom/shadow/content-element-select-dynamic.html
330
331         * html/shadow/HTMLContentElement.cpp:
332         (WebCore::HTMLContentElement::parseMappedAttribute):
333           Sets recalc style when select is changed.
334         * html/shadow/HTMLContentElement.h:
335         (HTMLContentElement):
336
337 2012-02-01  Kentaro Hara  <haraken@chromium.org>
338
339         Remove [ImplementationUUID] and [InterfaceUUID] from html/canvas/*.idl
340         https://bugs.webkit.org/show_bug.cgi?id=77589
341
342         Reviewed by Adam Barth.
343
344         [ImplementationUUID] and [InterfaceUUID] are used in html/canvas/*.idl,
345         but they are not implemented in code generators and thus have no meaning.
346         This patch removes them.
347
348         No tests. No change in behavior.
349
350         * html/canvas/CanvasGradient.idl:
351         * html/canvas/CanvasPattern.idl: The file is now empty though.
352         * html/canvas/CanvasRenderingContext.idl:
353         * html/canvas/CanvasRenderingContext2D.idl:
354         * html/canvas/WebGLRenderingContext.idl:
355
356 2012-02-01  Sheriff Bot  <webkit.review.bot@gmail.com>
357
358         Unreviewed, rolling out r106408.
359         http://trac.webkit.org/changeset/106408
360         https://bugs.webkit.org/show_bug.cgi?id=77592
361
362         crashes in chromium mac release tests (Requested by japhet on
363         #webkit).
364
365         * platform/graphics/Region.cpp:
366         * platform/graphics/Region.h:
367         (Region):
368         (Shape):
369
370 2012-02-01  No'am Rosenthal  <noam.rosenthal@nokia.com>
371
372         [Texmap] Use glScissors for clipping in TextureMapperGL when possible
373         https://bugs.webkit.org/show_bug.cgi?id=77575
374
375         Reviewed by Martin Robinson.
376
377         Maintain a clipping stack, that helps us use stencils in conjunction with scissors.
378         We apply scissors when the clip region is rectalinear, and stencil when it's not.
379
380         No behavior changes so no new tests.
381
382         * platform/graphics/opengl/TextureMapperGL.cpp:
383         (SharedGLData):
384         (WebCore::TextureMapperGLData::SharedGLData::SharedGLData):
385         (WebCore::TextureMapperGL::drawTexture):
386         (WebCore::TextureMapperGL::bindSurface):
387         (WebCore):
388         (WebCore::scissorClip):
389         (WebCore::TextureMapperGL::beginScissorClip):
390         (WebCore::TextureMapperGL::endScissorClip):
391         (WebCore::TextureMapperGL::beginClip):
392         (WebCore::TextureMapperGL::endClip):
393         * platform/graphics/opengl/TextureMapperGL.h:
394         (TextureMapperGL):
395
396 2012-02-01  Anders Carlsson  <andersca@apple.com>
397
398         Move the scrolling coordinator to page/scrolling
399         https://bugs.webkit.org/show_bug.cgi?id=77590
400
401         Reviewed by Dan Bernstein.
402
403         Put scrolling related files in page/scrolling to avoid cluttering the page directory.
404
405         * WebCore.xcodeproj/project.pbxproj:
406         * page/scrolling/ScrollingCoordinator.cpp: Renamed from Source/WebCore/page/ScrollingCoordinator.cpp.
407         * page/scrolling/ScrollingCoordinator.h: Renamed from Source/WebCore/page/ScrollingCoordinator.h.
408         * page/scrolling/mac/ScrollingCoordinatorMac.mm: Renamed from Source/WebCore/page/mac/ScrollingCoordinatorMac.mm.
409
410 2012-02-01  Kentaro Hara  <haraken@chromium.org>
411
412         Remove [ObjCPrefix], [V8ConstructorTemplate], [allowAccessToNode],
413         [v8implname] and [v8referenceattr] from code generators
414         https://bugs.webkit.org/show_bug.cgi?id=77588
415
416         Reviewed by Adam Barth.
417
418         This patch removes [ObjCPrefix], [V8ConstructorTemplate], [allowAccessToNode],
419         [v8implname] and [v8referenceattr] from code generators, since they are not used
420         by any IDL files.
421
422         No tests. No changes in behavior.
423
424         * bindings/scripts/CodeGeneratorJS.pm:
425         (GenerateImplementation):
426         * bindings/scripts/CodeGeneratorObjC.pm:
427         (GenerateHeader):
428         (GenerateImplementation):
429         * bindings/scripts/CodeGeneratorV8.pm:
430         (IsConstructable):
431         (IsConstructorTemplate):
432         (GenerateNormalAttrGetter):
433         (GenerateFunctionCallString):
434
435 2012-02-01  Pablo Flouret  <pablof@motorola.com>
436
437         Support targetOrigin = "/" in postMessage for sending messages to same origin as source document.
438         https://bugs.webkit.org/show_bug.cgi?id=77580
439
440         Reviewed by Adam Barth.
441
442         No new tests. Modified http/tests/security/postMessage/target-origin.html
443         to test this case as well.
444
445         * page/DOMWindow.cpp:
446         (WebCore::DOMWindow::postMessage):
447
448 2012-02-01  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
449
450         Avoid creating NamedNodeMap unnecessarily
451         https://bugs.webkit.org/show_bug.cgi?id=77574
452
453         Reviewed by Ryosuke Niwa.
454
455         The method Element::attributes() was being used for multiple things in our
456         codebase: (1) as the getter for NamedNodeMap exposed to DOM, (2) as a way to other WebCore
457         code get the "attribute storage" (currently inside NamedNodeMap), and (3) as a way to
458         get the attribute storage creating one if necessary.
459
460         This commit separate the jobs in different functions:
461
462         1) attributes() keeps being the DOM getter, and loses its boolean parameter.
463
464         2) updatedAttributes() updates the invalid attributes and returns the attribute
465         storage. If we don't have one, return 0.
466
467         3) ensureUpdatedAttributes() updates the invalid attributes and forces the
468         creation of attribute storage to return.
469
470         There is also another way to get to the attribute storage currently, via
471         attributeMap(), which doesn't update the attributes for possible changes in Style
472         or SVG attributes.
473
474         Note that the new functions are not available in Node class, so C++ code manipulating
475         attributes should cast to Element.
476
477         This separation also made easier to spot and fix some places where we do not
478         need to create the attribute storage if it doesn't exist.
479
480         No new tests, this commit shouldn't change the behavior of existing code.
481
482         * css/SelectorChecker.cpp:
483         (WebCore::SelectorChecker::checkOneSelector):
484         * dom/DatasetDOMStringMap.cpp:
485         (WebCore::DatasetDOMStringMap::getNames):
486         (WebCore::DatasetDOMStringMap::item):
487         (WebCore::DatasetDOMStringMap::contains):
488         * dom/Document.cpp:
489         (WebCore::Document::importNode):
490         * dom/Element.cpp:
491         (WebCore::Element::setAttribute):
492         (WebCore::Element::hasAttributes):
493         (WebCore::Element::setAttributeNode):
494         (WebCore::Element::setAttributeNodeNS):
495         (WebCore::Element::removeAttributeNode):
496         (WebCore::Element::getAttributeNode):
497         (WebCore::Element::getAttributeNodeNS):
498         (WebCore::Element::hasAttribute):
499         (WebCore::Element::hasAttributeNS):
500         (WebCore::Element::normalizeAttributes):
501         * dom/Element.h:
502         (Element):
503         (WebCore::Element::attributes):
504         (WebCore::Element::ensureAttributeData):
505         (WebCore::Element::ensureUpdatedAttributes):
506         (WebCore::Element::updatedAttributes):
507         (WebCore::Element::setAttributesFromElement):
508         (WebCore::Element::ensureAttributeMap): Made const to be reused by ensureUpdatedAttributes().
509         (WebCore::Element::updateInvalidAttributes):
510         (WebCore):
511         * dom/NamedNodeMap.cpp:
512         (WebCore::NamedNodeMap::mapsEquivalent): Having no attributes is equivalent to
513         not having an attribute storage because the attribute storage is lazily created.
514         * dom/Node.cpp:
515         (WebCore::Node::isEqualNode): Do not force the creation of attribute storage to
516         compare two nodes.
517         (WebCore::Node::isDefaultNamespace): Use updatedAttributes(). Since we iterate
518         using length, it's OK if the attribute storage is empty.
519         (WebCore::Node::lookupNamespaceURI): Ditto.
520         (WebCore::Node::lookupNamespacePrefix): Ditto.
521         (WebCore::Node::compareDocumentPosition): Ditto.
522         * editing/ApplyStyleCommand.cpp:
523         (WebCore::hasNoAttributeOrOnlyStyleAttribute):
524         (WebCore::isEmptyFontTag):
525         * editing/CompositeEditCommand.cpp:
526         (WebCore::CompositeEditCommand::isRemovableBlock): Use isElementNode() explicitly
527         to identify non-Element nodes, then use hasAttributes() if is Element.
528         * editing/InsertParagraphSeparatorCommand.cpp:
529         (WebCore::highestVisuallyEquivalentDivBelowRoot):
530         * editing/MarkupAccumulator.cpp:
531         (WebCore::MarkupAccumulator::appendElement): Do not create the attribute storage
532         unnecessarily.
533         * editing/htmlediting.cpp:
534         (WebCore::areIdenticalElements): Do not create the attribute storage
535         unnecessarily. Use mapsEquivalent() for comparing the attributes.
536         * editing/markup.cpp:
537         (WebCore::completeURLs): Do not create the attribute storage unnecessarily.
538         (WebCore::StyledMarkupAccumulator::appendElement): Ditto.
539         (WebCore::isPlainTextMarkup): hasAttributes() will avoid creating the attribute
540         storage unnecessarily.
541         * html/HTMLEmbedElement.cpp:
542         (WebCore::HTMLEmbedElement::parametersForPlugin):
543         * html/HTMLObjectElement.cpp:
544         (WebCore::HTMLObjectElement::parametersForPlugin):
545         * html/HTMLParamElement.cpp:
546         (WebCore::HTMLParamElement::isURLAttribute): Do not create the attribute storage
547         unnecessarily.
548         * html/parser/HTMLConstructionSite.cpp:
549         (WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement): Use
550         ensureUpdatedAttributes() since we will add new attributes.
551         (WebCore):
552         * inspector/InspectorCSSAgent.cpp:
553         (WebCore::InspectorCSSAgent::buildArrayForAttributeStyles):
554         * inspector/InspectorDOMAgent.cpp:
555         (WebCore::InspectorDOMAgent::setAttributesAsText):
556         (WebCore::InspectorDOMAgent::performSearch):
557         (WebCore::InspectorDOMAgent::buildArrayForElementAttributes):
558         * page/PageSerializer.cpp:
559         (WebCore::isCharsetSpecifyingNode): Do not assume attributeMap will exist.
560         * svg/properties/SVGAnimatedPropertySynchronizer.h: Use ensureUpdatedAttributes()
561         since we will add new attributes.
562         * xml/XPathFunctions.cpp:
563         (WebCore::XPath::FunLang::evaluate): Do not create the attribute storage
564         unnecessarily.
565         * xml/XPathNodeSet.cpp:
566         (WebCore::XPath::NodeSet::traversalSort):
567         * xml/XPathStep.cpp:
568         (WebCore::XPath::Step::nodesInAxis): Use isElementNode() instead of comparing
569         nodeType() manually. Do not create the attribute storage unnecessarily.
570         * xml/parser/XMLDocumentParserLibxml2.cpp:
571         (WebCore::XMLDocumentParser::XMLDocumentParser): Do not create the attribute
572         storage unnecessarily.
573         * xml/parser/XMLDocumentParserQt.cpp:
574         (WebCore::XMLDocumentParser::XMLDocumentParser): Ditto.
575         * xml/parser/XMLTreeBuilder.cpp:
576         (WebCore::XMLTreeBuilder::XMLTreeBuilder): Ditto.
577
578 2012-02-01  Adam Barth  <abarth@webkit.org>
579
580         contentDispositionType misparses the Content-Disposition header in some obscure corner cases
581         https://bugs.webkit.org/show_bug.cgi?id=77577
582
583         Reviewed by Eric Seidel.
584
585         The contentDispositionType extracts the disposition-type from the
586         Content-Disposition header.  According to RFC 6266 (and previous RFCs),
587         the disposition-type must be an RFC 2616 token.  Rather than enforce
588         this general rule, we had special-cased some examples (including
589         name=foo and filename=bar).  This patch generalizes our check to
590         properly validate that the disposition-type is an RFC 2616 token.
591
592         In conjunction with some other work in the Chromium network stack, this
593         causes Chromium to pass the following tests:
594
595           http://greenbytes.de/tech/tc2231/#inlonlyquoted
596           http://greenbytes.de/tech/tc2231/#attonlyquoted
597
598         Without this patch, these test cases neither trigger a navigation nor a
599         download in Chromium.  This patch does not appear to cause any visible
600         change in Safari.  (Safari passes these tests both before and after
601         this patch.)
602
603         * platform/network/HTTPParsers.cpp:
604         (WebCore::isRFC2616Token):
605         (WebCore::contentDispositionType):
606             - This patch also adds a comment to
607               filenameFromHTTPContentDisposition, which explains some of the
608               was this function incorrectly implements the requirements in
609               RFC 6266.  Resolving these issues is a subject for a future
610               patch.
611         * platform/network/HTTPParsers.h:
612
613 2012-02-01  Dan Bernstein  <mitz@apple.com>
614
615         WebCore part of <rdar://problem/10442663> Paginated display does not respect page-break-{before,after}
616         https://bugs.webkit.org/show_bug.cgi?id=77505
617
618         Reviewed by Darin Adler.
619
620         * page/Page.h:
621         (WebCore::Page::Pagination::Pagination): Added initializer for the behavesLikeColumns member
622         variable.
623         (WebCore::Page::Pagination::operator==): Added comparison of behavesLikeColumns values.
624         (Pagination): Added behavesLikeColumns member variable. When set to false (the default),
625         paginated display respects the page-break-{before,after} properties rather than the
626         column-break-{before,after} ones.
627         * rendering/ColumnInfo.h:
628         (WebCore::ColumnInfo::ColumnInfo): Added initializer for the m_paginationUnit member.
629         (WebCore::ColumnInfo::paginationUnit): Added this getter.
630         (WebCore::ColumnInfo::setPaginationUnit): Added this setter.
631         (ColumnInfo): Added m_paginationUnit member. It defaults to Column.
632         * rendering/LayoutState.h:
633         (WebCore::LayoutState::isPaginatingColumns): Changed to check the pagination unit.
634         * rendering/RenderBlock.cpp:
635         (WebCore::RenderBlock::layoutBlock): Added code to set the pagination unit in the ColumnInfo.
636         (WebCore::RenderBlock::paginationUnit): Added. The base class implementation returns Column.
637         * rendering/RenderBlock.h:
638         * rendering/RenderView.cpp:
639         (WebCore::RenderView::paginationUnit): Added this override that returns Page, unless
640         this is the RenderView for the main frame and pagination is set to behave like columns.
641         * rendering/RenderView.h:
642
643 2012-02-01  Florin Malita  <fmalita@google.com>
644
645         Backgrounds in HTML inside foreignObject don't draw
646         https://bugs.webkit.org/show_bug.cgi?id=23111
647
648         Reviewed by Eric Seidel.
649
650         Test: svg/foreignObject/body-background.svg
651
652         * rendering/RenderBox.cpp:
653         (WebCore::RenderBox::paintBackground):
654         Tweak the <body> background inhibiting logic to allow drawing when the element is embedded in FOs.
655
656
657 2012-02-01  Gustavo Lima Chaves  <glima@profusion.mobi>
658
659         Make one able to set the local storage (tracker) database dir's path
660         https://bugs.webkit.org/show_bug.cgi?id=77006
661
662         Reviewed by Darin Adler.
663
664         There are no behavior changes with the diff, so no need for new tests.
665
666         * storage/StorageTracker.cpp:
667         (WebCore::StorageTracker::setDatabaseDirectoryPath):
668         (WebCore):
669         (WebCore::StorageTracker::databaseDirectoryPath):
670         * storage/StorageTracker.h:
671         (StorageTracker):
672
673 2012-02-01  Anders Carlsson  <andersca@apple.com>
674
675         Fix Window build.
676
677         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
678         (WebCore::LayerClient::platformCALayerDidCreateTiles):
679         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
680         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerDidCreateTiles):
681
682 2012-02-01  John Yani  <vanuan@gmail.com>
683
684         GetMIMEDescription should return const char *
685         https://bugs.webkit.org/show_bug.cgi?id=77297
686
687         Reviewed by Alexey Proskuryakov.
688
689         No new tests. No change in behaviour.
690
691         * plugins/blackberry/PluginPackageBlackBerry.cpp:
692         (WebCore::PluginPackage::fetchInfo):
693         * plugins/efl/PluginPackageEfl.cpp:
694         (WebCore):
695         (WebCore::PluginPackage::fetchInfo):
696         * plugins/npapi.h:
697         * plugins/npfunctions.h:
698         * plugins/qt/PluginPackageQt.cpp:
699         (WebCore::PluginPackage::fetchInfo):
700
701 2012-02-01  Timothy Hatcher  <timothy@apple.com>
702
703         Consolidate duplicate "willHide" functions in DetailedHeapshotView.js to fix
704         a syntax error in JSC and make the Inspector open again in Release builds.
705
706         https://webkit.org/b/77424
707
708         Reviewed by Brian Weinstein.
709
710         * inspector/front-end/DetailedHeapshotView.js:
711         (WebInspector.DetailedHeapshotView.prototype.willHide): Consolidated.
712         (WebInspector.DetailedHeapshotView.prototype.willHide): Removed.
713
714 2012-02-01  Justin Novosad  <junov@chromium.org>
715
716         [Chromium] Enable deferred canvas rendering in the skia port
717         https://bugs.webkit.org/show_bug.cgi?id=76732
718
719         Reviewed by Stephen White.
720
721         No new tests: covered by existing canvas layout tests
722
723         Adding a new setting to enable deferred 2d canvas rendering.
724         Added support for deferred 2d canvas rendering in ImageBufferSkia
725         and Canvas2DLayerChromium, mostly plumbing. Deffered rendering
726         implementation is provided by skia (class SkDeferredCanvas).
727
728         * html/HTMLCanvasElement.cpp:
729         (WebCore::HTMLCanvasElement::shouldDefer):
730         (WebCore):
731         (WebCore::HTMLCanvasElement::createImageBuffer):
732         * html/HTMLCanvasElement.h:
733         (HTMLCanvasElement):
734         * page/Settings.cpp:
735         (WebCore::Settings::Settings):
736         (WebCore::Settings::setAccelerated2dCanvasEnabled):
737         (WebCore):
738         (WebCore::Settings::setDeferred2dCanvasEnabled):
739         * page/Settings.h:
740         (Settings):
741         (WebCore::Settings::deferred2dCanvasEnabled):
742         * platform/graphics/ImageBuffer.h:
743         (WebCore::ImageBuffer::create):
744         (ImageBuffer):
745         * platform/graphics/cairo/ImageBufferCairo.cpp:
746         (WebCore::ImageBuffer::ImageBuffer):
747         * platform/graphics/cg/ImageBufferCG.cpp:
748         (WebCore::ImageBuffer::ImageBuffer):
749         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
750         (WebCore::Canvas2DLayerChromium::Canvas2DLayerChromium):
751         (WebCore):
752         (WebCore::Canvas2DLayerChromium::setCanvas):
753         (WebCore::Canvas2DLayerChromium::paintContentsIfDirty):
754         * platform/graphics/chromium/Canvas2DLayerChromium.h:
755         (Canvas2DLayerChromium):
756         * platform/graphics/qt/ImageBufferQt.cpp:
757         (WebCore::ImageBuffer::ImageBuffer):
758         * platform/graphics/skia/ImageBufferSkia.cpp:
759         (AcceleratedDeviceContext):
760         (WebCore::AcceleratedDeviceContext::AcceleratedDeviceContext):
761         (WebCore::AcceleratedDeviceContext::prepareForDraw):
762         (WebCore::AcceleratedDeviceContext::flush):
763         (WebCore):
764         (WebCore::createAcceleratedCanvas):
765         (WebCore::ImageBuffer::ImageBuffer):
766         * platform/graphics/wince/ImageBufferWinCE.cpp:
767         (WebCore::ImageBuffer::ImageBuffer):
768         * platform/graphics/wx/ImageBufferWx.cpp:
769         (WebCore::ImageBuffer::ImageBuffer):
770
771 2012-02-01  Ryosuke Niwa  <rniwa@webkit.org>
772
773         Gcc build fix after r106482.
774
775         * platform/graphics/ca/GraphicsLayerCA.h:
776         (GraphicsLayerCA):
777
778 2012-02-01  Beth Dakin  <bdakin@apple.com>
779
780         https://bugs.webkit.org/show_bug.cgi?id=77383
781         Add a different didFirstVisuallNonEmptyLayout heuristic to experiment with
782         -and corresponding-
783         <rdar://problem/10709560>
784
785         Reviewed by Sam Weinig.
786
787         The goal is to re-vamp didFirstVisuallyNonEmptyLayout to be more accurate. 
788         This patch adds a new heuristic called didNewFirstVisuallNonEmptyLayout and 
789         leaves the old one for the time being. That is temporary.
790
791         The heuristic for didNewFirstVisuallNonEmptyLayout is to count relevant 
792         painted RenderObjects on Page.
793         * page/Page.cpp:
794         (WebCore::Page::Page):
795         (WebCore::Page::setPaintedObjectsCounterThreshold):
796         (WebCore::Page::addRelevantRepaintedObject):
797         * page/Page.h:
798         (WebCore):
799         (Page):
800         (WebCore::Page::startCountingRepaintedObjects):
801         * WebCore.exp.in:
802
803         Start counting relevant painted RenderObjects on the page once the first 
804         layout is complete.
805         * page/FrameView.cpp:
806         (WebCore::FrameView::performPostLayoutTasks):
807
808         Machinery for firing didNewFirstVisuallNonEmptyLayout.
809         * loader/EmptyClients.h:
810         (WebCore::EmptyFrameLoaderClient::dispatchDidNewFirstVisuallyNonEmptyLayout):
811         * loader/FrameLoader.cpp:
812         (WebCore::FrameLoader::didNewFirstVisuallyNonEmptyLayout):
813         (WebCore):
814         * loader/FrameLoader.h:
815         (FrameLoader):
816         * loader/FrameLoaderClient.h:
817         (WebCore::FrameLoaderClient::dispatchDidNewFirstVisuallyNonEmptyLayout):
818
819         These RenderObjects are the ones that this api currently consider to be 
820         relevant. If their repaint rects intersect with the viewRect, then they are 
821         added to the relevant objects set on the Page.
822         * rendering/InlineBox.cpp:
823         (WebCore::InlineBox::paint):
824         * rendering/InlineTextBox.cpp:
825         (WebCore::InlineTextBox::paint):
826         * rendering/RenderEmbeddedObject.cpp:
827         (WebCore::RenderEmbeddedObject::paintReplaced):
828         * rendering/RenderHTMLCanvas.cpp:
829         (WebCore::RenderHTMLCanvas::paintReplaced):
830         * rendering/RenderImage.cpp:
831         (WebCore::RenderImage::paintReplaced):
832         * rendering/RenderRegion.cpp:
833         (WebCore::RenderRegion::paintReplaced):
834         * rendering/RenderReplaced.cpp:
835         (WebCore::RenderReplaced::paint):
836         * rendering/RenderVideo.cpp:
837         (WebCore::RenderVideo::paintReplaced):
838         * rendering/svg/RenderSVGRoot.cpp:
839         (WebCore::RenderSVGRoot::paintReplaced):
840
841 2012-02-01  Alexis Menard  <alexis.menard@openbossa.org>
842
843         CSSStyleDeclaration.getPropertyPriority() fails for CSS shorthand properties with 'important' priority
844         https://bugs.webkit.org/show_bug.cgi?id=49058
845
846         Reviewed by Andreas Kling.
847
848         CSSMutableStyleDeclaration::getPropertyPriority was not handling shorthands properly. Shorthands are
849         not part of the property list of the style so we need to query the longhands which are the one added
850         in the list. Only if the longhands have equal priority the shorthand priority is known. I also renamed
851         getPropertyPriority (not the CSSOM exposed method) to something more consistent with WebKit naming guidelines.
852
853         Test: fast/css/shorthand-priority.html
854
855         * css/CSSMutableStyleDeclaration.cpp:
856         (WebCore::CSSMutableStyleDeclaration::propertyIsImportant):
857         (WebCore::CSSMutableStyleDeclaration::addParsedProperty):
858         (WebCore::CSSMutableStyleDeclaration::getPropertyPriority):
859         * css/CSSMutableStyleDeclaration.h:
860         (CSSMutableStyleDeclaration):
861         * editing/EditingStyle.cpp:
862         (WebCore::EditingStyle::extractAndRemoveTextDirection):
863         (WebCore::EditingStyle::collapseTextDecorationProperties):
864         (WebCore::EditingStyle::conflictsWithInlineStyleOfElement):
865         (WebCore::setTextDecorationProperty):
866         * editing/RemoveCSSPropertyCommand.cpp:
867         (WebCore::RemoveCSSPropertyCommand::doApply):
868
869 2012-02-01  Ryosuke Niwa  <rniwa@webkit.org>
870
871         Crash in EventHandler::updateDragAndDrop
872         https://bugs.webkit.org/show_bug.cgi?id=77569
873
874         Reviewed by Alexey Proskuryakov.
875
876         Test: fast/events/remove-target-with-shadow-in-drag.html
877
878         * page/EventHandler.cpp:
879         (WebCore::EventHandler::updateDragAndDrop):
880
881 2012-02-01  Sheriff Bot  <webkit.review.bot@gmail.com>
882
883         Unreviewed, rolling out r106382.
884         http://trac.webkit.org/changeset/106382
885         https://bugs.webkit.org/show_bug.cgi?id=77571
886
887         Causing chromium crashes in PNGImageDecoder (Requested by
888         japhet on #webkit).
889
890         * bindings/v8/V8Proxy.cpp:
891         (WebCore::V8Proxy::evaluate):
892         * page/Console.cpp:
893         (WebCore::Console::time):
894         (WebCore::Console::timeEnd):
895         * platform/chromium/PlatformSupport.h:
896         * platform/chromium/TraceEvent.h:
897         (internal):
898         (ScopeTracer):
899         (WebCore::internal::ScopeTracer::ScopeTracer):
900         (WebCore::internal::ScopeTracer::~ScopeTracer):
901
902 2012-02-01  Anders Carlsson  <andersca@apple.com>
903
904         Reviewed by Darin Adler.
905
906         Simplify the code that creates a new tile layer by getting a reference to the RetainPtr<WebTileLayer>&
907         slot in the hash map and assign directly into it.
908
909         * platform/graphics/ca/mac/TileCache.mm:
910         (WebCore::TileCache::revalidateTiles):
911
912 2012-02-01  Anders Carlsson  <andersca@apple.com>
913
914         Tile cache doesn't have an upper limit
915         https://bugs.webkit.org/show_bug.cgi?id=77564
916         <rdar://problem/10710744>
917
918         Reviewed by Darin Adler.
919
920         Cache enough tiles to cover 3x the visible height and 2x the visible width of the page,
921         and drop tiles that are outside that area.
922
923         * platform/graphics/ca/GraphicsLayerCA.cpp:
924         (WebCore::GraphicsLayerCA::platformCALayerDidCreateTiles):
925         Call GraphicsLayerClient::notifySyncRequired here, which will schedule a layer flush and ensure that
926         the page layout is up to date before the new tiles are painted.
927
928         * platform/graphics/ca/PlatformCALayerClient.h:
929         Add platformCALayerDidCreateTiles member function.
930
931         * platform/graphics/ca/mac/TileCache.h:
932         Update for new/removed member functions and member variables.
933
934         * platform/graphics/ca/mac/TileCache.mm:
935         (WebCore::TileCache::TileCache):
936         Initialize the tile revalidation timer.
937
938         (WebCore::TileCache::tileCacheLayerBoundsChanged):
939         If we don't have any tiles at all right now, revalidate the tiles immediately. Otherwise,
940         schedule the revalidation timer.
941
942         (WebCore::TileCache::setNeedsDisplayInRect):
943         Return early if we have no tiles.
944
945         (WebCore::TileCache::visibleRectChanged):
946         Schedule tile revalidation.
947
948         (WebCore::TileCache::rectForTileIndex):
949         New helper function that returns the bounds rect of a tile given its tile index.
950
951         (WebCore::TileCache::getTileIndexRangeForRect):
952         Clamp the rect to the bounds of the tile cache layer.
953
954         (WebCore::TileCache::scheduleTileRevalidation):
955         Schedule the revalidation timer if it hasn't already been scheduled.
956
957         (WebCore::TileCache::tileRevalidationTimerFired):
958         Call revalidateTiles.
959
960         (WebCore::TileCache::revalidateTiles):
961         Compute the tile coverage rect and remove all tiles that are outside. Create new tiles for any
962         parts of the tile coverage rect that don't have tiles already.
963
964         (WebCore::TileCache::tileLayerAtIndex):
965         Remove invalid assertions.
966
967 2012-02-01  Max Vujovic  <mvujovic@adobe.com>
968
969         Add support for fixed and percent min-width on the table element for table-layout: auto to
970         match Firefox and Opera's behavior.
971
972         In FixedTableLayout.cpp, the computePreferredLogicalWidths method looks like it has
973         issues based on the comment: "FIXME: This entire calculation is incorrect for both
974         minwidth and maxwidth." (minwidth and maxwidth refer to the preferred widths, not the
975         min-width and max-width styles). I have not implemented min-width for FixedTableLayout
976         in this patch since it requires some more research around that comment.
977
978         min-width and max-width on the table element was discussed on the www-style list:
979         http://lists.w3.org/Archives/Public/www-style/2012Jan/0684.html
980
981         min-width is not implemented on <table> for table-layout: auto
982         https://bugs.webkit.org/show_bug.cgi?id=76553
983
984         Reviewed by Julien Chaffraix.
985
986         Test: fast/table/min-width.html
987
988         * rendering/AutoTableLayout.cpp:
989         (WebCore::AutoTableLayout::computePreferredLogicalWidths):
990
991             If the min or max preferred logical width is less than a fixed min width style, it is
992             set to the fixed min width style. Like a percent width style, a percent min-width style
993             does not affect the min or max preferred logical widths computed by the table layout
994             algorithm. RenderTable's computeLogicalWidth method handles percent min-width styles.
995
996             min-width for the table-layout: fixed case has been split out into this bug:
997             https://bugs.webkit.org/show_bug.cgi?id=76948
998
999         * rendering/RenderTable.cpp:
1000         (WebCore::RenderTable::computeLogicalWidth):
1001
1002             If the RenderStyle's logical min width is defined and greater than the logical width
1003             calculation, this method sets the logical width to the logical min width.
1004
1005         (WebCore::RenderTable::convertStyleWidthToComputedWidth):
1006
1007             This new method generalizes and factors out logic from RenderTable::computeLogicalWidth
1008             that converted the width style to a computed value in the fixed and percent case.
1009             RenderTable::computeLogicalWidth now calls this method to determine the computed values
1010             for both the width style and the min-width style. In the future, it can also be used for
1011             the max-width style.
1012
1013             Note that this method handles the special CSS table case, which requires borders and
1014             paddings to be included in the computed width calculation. This applies to all width
1015             styles, including width, min-width, and max-width. Before, this special case was handled
1016             in RenderTable::computeLogicalWidth.
1017
1018         * rendering/RenderTable.h:
1019
1020 2012-02-01  Brian Salomon  <bsalomon@google.com>
1021
1022         [SKIA/CHROMIUM] Perform getImageData format conversions using Skia
1023         https://bugs.webkit.org/show_bug.cgi?id=77553
1024
1025         Reviewed by Stephen White.
1026
1027         Many existing canvas tests exercise this functionality.
1028
1029         * platform/graphics/skia/ImageBufferSkia.cpp:
1030         (WebCore::getImageData):
1031
1032 2012-02-01  Nate Chapin  <japhet@chromium.org>
1033
1034         preventDefault() in a mousedown in a subframe should not
1035         prevent the scrollbar from handling mouse movements if the
1036         cursor leaves the subframe.
1037         https://bugs.webkit.org/show_bug.cgi?id=73097
1038
1039         Reviewed by Darin Adler.
1040
1041         Test: fast/events/scroll-div-with-prevent-default-in-subframe.html
1042
1043         * page/EventHandler.cpp:
1044         (WebCore::EventHandler::handleMousePressEvent):
1045
1046 2012-02-01  Mario Sanchez Prada  <msanchez@igalia.com>
1047
1048         [GTK] editing/inserting/4960120-2.html flaky crash
1049         https://bugs.webkit.org/show_bug.cgi?id=76815
1050
1051         Reviewed by Martin Robinson.
1052
1053         Check if the node for the first parent object not ignoring
1054         accessibility is null before using it. This might happen with
1055         certain kind of accessibility objects, such as the root one (the
1056         scroller containing the webArea object as its only child).
1057
1058         * accessibility/gtk/WebKitAccessibleWrapperAtk.cpp:
1059         (objectFocusedAndCaretOffsetUnignored): Add missing null check.
1060
1061 2012-02-01  Antti Koivisto  <antti@apple.com>
1062
1063         Make CSSMappedAttributeDeclaration have CSSMutableStyleDeclaration instead of being one
1064         https://bugs.webkit.org/show_bug.cgi?id=77545
1065
1066         Reviewed by Andreas Kling.
1067
1068         This is the easiest path for eliminating the last remaining subclass of CSSMutableStyleDeclaration.
1069         
1070         On negative side this increases memory use of CSSMappedAttributeDeclaration by one ptr and refcount
1071         (it loses the vptr) in total.
1072         
1073         This is not meant to be the end state, just an intermediate refactoring step. CSSMappedAttributeDeclaration
1074         should clearly be renamed too but this patch doesn't do that. It might not exist in its current form
1075         much longer.
1076
1077         * css/CSSMutableStyleDeclaration.cpp:
1078         (WebCore::CSSMutableStyleDeclaration::setProperty):
1079         (WebCore::CSSMutableStyleDeclaration::merge):
1080         * css/CSSMutableStyleDeclaration.h:
1081
1082             Remove protected section. No subclasses remain.        
1083             Rename setPropertyInternal() to setProperty(). All public methods here are internal.
1084         
1085         (CSSMutableStyleDeclaration):
1086         * css/CSSParser.cpp:
1087         (WebCore::CSSParser::parseMappedAttributeValue):
1088         * dom/Attribute.cpp:
1089         (WebCore::Attribute::clone):
1090         * dom/Attribute.h:
1091         (Attribute):
1092         (WebCore::Attribute::decl):
1093         (WebCore::Attribute::mappedAttributeDeclaration):
1094         (WebCore::Attribute::setMappedAttributeDeclaration):
1095         (WebCore::Attribute::Attribute):
1096         * dom/CSSMappedAttributeDeclaration.cpp:
1097         (WebCore::CSSMappedAttributeDeclaration::setMappedImageProperty):
1098         (WebCore::CSSMappedAttributeDeclaration::setMappedProperty):
1099         (WebCore::CSSMappedAttributeDeclaration::removeMappedProperty):
1100         * dom/CSSMappedAttributeDeclaration.h:
1101         (CSSMappedAttributeDeclaration):
1102         (WebCore::CSSMappedAttributeDeclaration::declaration):
1103         (WebCore::CSSMappedAttributeDeclaration::CSSMappedAttributeDeclaration):
1104         
1105             Make CSSMutableStyleDeclaration a member instead of the base class.
1106         
1107         * dom/StyledElement.cpp:
1108         (WebCore::StyledElement::attributeChanged):
1109         (WebCore::StyledElement::removeCSSProperty):
1110         (WebCore::StyledElement::addCSSProperty):
1111         (WebCore::StyledElement::addCSSImageProperty):
1112         (WebCore::StyledElement::addCSSLength):
1113         (WebCore::StyledElement::addCSSColor):
1114         (WebCore::StyledElement::createMappedDecl):
1115         * svg/SVGStyledElement.cpp:
1116         (WebCore::SVGStyledElement::getPresentationAttribute):
1117
1118 2012-02-01  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1119
1120         [Qt] Set all PlatformTouchPoint values possible from a QTouch event.
1121         https://bugs.webkit.org/show_bug.cgi?id=77442
1122
1123         Reviewed by Kenneth Rohde Christiansen.
1124
1125         * platform/qt/PlatformTouchPointQt.cpp:
1126         (WebCore::PlatformTouchPoint::PlatformTouchPoint):
1127
1128 2012-02-01  Peter Rybin  <peter.rybin@gmail.com>
1129
1130         Web Inspector: CodeGeneratorInspector.py: move type builder code to dedicated InspectorTypeBuilder .h/.cpp
1131         https://bugs.webkit.org/show_bug.cgi?id=77471
1132
1133         Reviewed by Yury Semikhatsky.
1134
1135         Code is moved physically to other file -- generator is changed accrodingly.
1136
1137         * inspector/CodeGeneratorInspector.py:
1138         (String):
1139         (provides):
1140         (typename):
1141         (Array):
1142
1143 2012-02-01  Yury Semikhatsky  <yurys@chromium.org>
1144
1145         Web Inspector: debugger reports wrong sources when paused in inline script on page reload
1146         https://bugs.webkit.org/show_bug.cgi?id=77548
1147
1148         V8 returns treats each script source as ending with \n, now we take
1149         this into account when reporting script line count to the inspector
1150         front-end.
1151
1152         Reviewed by Vsevolod Vlasov.
1153
1154         Test: inspector/debugger/pause-in-inline-script.html
1155
1156         * bindings/js/ScriptDebugServer.cpp:
1157         (WebCore::ScriptDebugServer::dispatchDidParseSource):
1158         * bindings/v8/DebuggerScript.js:
1159
1160 2012-02-01  Shinya Kawanaka  <shinyak@google.com>
1161
1162         Content element should be able to be dynamically added/removed/replaced in a shadow tree.
1163         https://bugs.webkit.org/show_bug.cgi?id=76611
1164
1165         Reviewed by Hajime Morita
1166
1167         When a content element is added/removed/replaced in a shadow tree, we have to recreate
1168         the shadow tree to recalculate inclusions of content elements. Currently we didn't recalculate it
1169         when content element is removed. (When added, it is recalculated.)
1170         This patch enables us to recalcurate the shadow tree when content element is removed.
1171
1172         Test: fast/dom/shadow/content-element-move.html
1173
1174         * dom/Element.cpp:
1175         (WebCore::Element::attach):
1176           If a shadow root exists, attaches shadow tree before attaching child elements.
1177         * dom/ShadowRoot.cpp:
1178           Added a flag to recalculate shadow tree.
1179         (WebCore::ShadowRoot::ShadowRoot):
1180         (WebCore::ShadowRoot::recalcShadowTreeStyle):
1181           Recalculates light children and shadow tree.
1182         (WebCore::ShadowRoot::setNeedsReattachHostChildrenAndShadow):
1183         (WebCore::ShadowRoot::reattachHostChildrenAndShadow):
1184           Detaches shadow tree and host light children, and attaches them again.
1185         * dom/ShadowRoot.h:
1186         (WebCore::ShadowRoot::clearNeedsReattachHostChildrenAndShadow):
1187         (WebCore::ShadowRoot::needsReattachHostChildrenAndShadow):
1188         * html/shadow/HTMLContentElement.cpp:
1189         (WebCore::HTMLContentElement::attach):
1190           Does not need to detach included elements, because they are not attached in ContainerNode anymore.
1191         (WebCore::HTMLContentElement::detach):
1192           When a content element detached, reattaches a shadow tree.
1193
1194 2012-02-01  Peter Beverloo  <peter@chromium.org>
1195
1196         getIntersectionList causes transforms to be recalculated in SVG
1197         https://bugs.webkit.org/show_bug.cgi?id=77179
1198
1199         Reviewed by Nikolas Zimmermann.
1200
1201         Introduce a local variable to store the element's local-to-parent
1202         transformation matrix in, removing the need for the const_cast and
1203         stopping us from modifying any matrices elsewhere.
1204
1205         Test: svg/custom/intersection-list-transforms.svg
1206
1207         * rendering/svg/RenderSVGModelObject.cpp:
1208         (WebCore::getElementCTM):
1209
1210 2012-02-01  Vsevolod Vlasov  <vsevik@chromium.org>
1211
1212         Web Inspector: [InspectorIndexedDB] Add tests for database names and database structure requests.
1213         https://bugs.webkit.org/show_bug.cgi?id=77439
1214
1215         Reviewed by Pavel Feldman.
1216
1217         Tests: http/tests/inspector/indexeddb/database-names.html
1218                http/tests/inspector/indexeddb/database-structure.html
1219
1220         * inspector/front-end/IndexedDBModel.js:
1221         (WebInspector.IndexedDBModel.prototype.refreshDatabase):
1222
1223 2012-01-31  Vsevolod Vlasov  <vsevik@chromium.org>
1224
1225         Web Inspector: Scripts navigator becomes empty after "show folders" settings change.
1226         https://bugs.webkit.org/show_bug.cgi?id=77441
1227
1228         Reviewed by Pavel Feldman.
1229
1230         * inspector/front-end/ScriptsNavigator.js:
1231         (WebInspector.ScriptsNavigator.prototype._reset):
1232         * inspector/front-end/utilities.js:
1233
1234 2012-02-01  Shawn Singh  <shawnsingh@chromium.org>
1235
1236         Fix the semantics of passing contentsVisible flag to GraphicsLayers
1237         https://bugs.webkit.org/show_bug.cgi?id=76975
1238
1239         Reviewed by Simon Fraser.
1240
1241         This patch is covered by existing tests, in particular
1242         compositing/visibility/layer-visible-content.html; its
1243         expectations are rebaselined.
1244
1245         * rendering/RenderLayerBacking.cpp:
1246         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1247
1248 2012-02-01  Philippe Normand  <pnormand@igalia.com>
1249
1250         Unreviewed, another GTK build fix after r106446.
1251
1252         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
1253         Restore webKitWebSrcGetProtocols as it was before r106446.
1254
1255 2012-02-01  Philippe Normand  <pnormand@igalia.com>
1256
1257         Unreviewed, GTK build fix after r106446.
1258
1259         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
1260
1261 2012-02-01  Sheriff Bot  <webkit.review.bot@gmail.com>
1262
1263         Unreviewed, rolling out r106432.
1264         http://trac.webkit.org/changeset/106432
1265         https://bugs.webkit.org/show_bug.cgi?id=77529
1266
1267         it breaks tests (Requested by shinyak on #webkit).
1268
1269         * dom/Element.cpp:
1270         (WebCore::Element::attach):
1271         * dom/ShadowRoot.cpp:
1272         (WebCore::ShadowRoot::recalcShadowTreeStyle):
1273         * dom/ShadowRoot.h:
1274         (ShadowRoot):
1275         * html/shadow/HTMLContentElement.cpp:
1276         (WebCore::HTMLContentElement::attach):
1277         (WebCore::HTMLContentElement::detach):
1278
1279 2012-02-01  Hayato Ito  <hayato@chromium.org>
1280
1281         Remove unnecessary [OldStyleObjC] from ShadowRoot.idl.
1282         https://bugs.webkit.org/show_bug.cgi?id=77516
1283
1284         Reviewed by Kentaro Hara.
1285
1286         No new tests. No change in behavior.
1287
1288         * dom/ShadowRoot.idl:
1289
1290 2012-01-26  Philippe Normand  <pnormand@igalia.com>
1291
1292         [GStreamer] 0.11 webkitwebsrc
1293         https://bugs.webkit.org/show_bug.cgi?id=77086
1294
1295         Port the webkitwebsrc element to GStreamer 0.11 APIs.
1296
1297         Reviewed by Gustavo Noronha Silva.
1298
1299         No new tests, existing http media layout tests should cover this.
1300
1301         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
1302         (webkit_web_src_class_init):
1303
1304 2012-01-31  Hans Wennborg  <hans@chromium.org>
1305
1306         Speech Input: Report speech element rect relative to window rather than frame
1307         https://bugs.webkit.org/show_bug.cgi?id=76443
1308
1309         Reviewed by Darin Fisher.
1310
1311         When requesting speech input, report the speech element rect relative
1312         to the window rather than the frame. The embedder will typically use
1313         this position to show a bubble indicating that speech recognition is
1314         in progress.
1315
1316         Test: fast/speech/bubble-position.html
1317
1318         * html/shadow/TextControlInnerElements.cpp:
1319         (WebCore::InputFieldSpeechButtonElement::startSpeechInput):
1320
1321 2012-01-31  Andreas Kling  <awesomekling@apple.com>
1322
1323         Make elements that don't have attributes smaller.
1324         <http://webkit.org/b/76876>
1325
1326         Reviewed by Sam Weinig and Antti Koivisto.
1327
1328         Move the inline style declaration from StyledElement to ElementAttributeData, since having
1329         an inline style declaration also implies having a style attribute on the element.
1330         This saves one CPU word per element that has no attributes.
1331
1332         This reduces memory consumption by 412 kB (on 64-bit) when viewing the full
1333         HTML5 spec at <http://whatwg.org/c>.
1334
1335         This was rolled out once because of a performance regression which has been averted this
1336         time around by adding an Element::ensureAttributeMap() so we can force creation of the
1337         NamedNodeMap without also serializing the inline style for the "style" attribute.
1338
1339         * dom/Element.h:
1340         (Element):
1341         (WebCore::Element::ensureAttributeMap):
1342         (WebCore):
1343         * dom/ElementAttributeData.h:
1344         (ElementAttributeData):
1345         * dom/NamedNodeMap.cpp:
1346         (WebCore::NamedNodeMap::ensureInlineStyleDecl):
1347         (WebCore):
1348         (WebCore::NamedNodeMap::destroyInlineStyleDecl):
1349         * dom/NamedNodeMap.h:
1350         (WebCore::NamedNodeMap::inlineStyleDecl):
1351         (NamedNodeMap):
1352         * dom/StyledElement.cpp:
1353         (WebCore::StyledElement::addSubresourceAttributeURLs):
1354         * dom/StyledElement.h:
1355         (WebCore::StyledElement::inlineStyleDecl):
1356         (WebCore::StyledElement::ensureInlineStyleDecl):
1357         (StyledElement):
1358         (WebCore::StyledElement::destroyInlineStyleDecl):
1359
1360 2012-01-31  Hayato Ito  <hayato@chromium.org>
1361
1362         Add APIs, getElementsByXXX family, to ShadowRoot IDL.
1363         https://bugs.webkit.org/show_bug.cgi?id=77323
1364
1365         Reviewed by Dimitri Glazkov.
1366
1367         Add APIs (getElementById, getElemesntByTagName, getElementsByClassName and getElementsByTagNameNS)
1368         to ShadowRoot IDL.
1369
1370         * dom/ShadowRoot.idl:
1371
1372 2012-01-31  Shinya Kawanaka  <shinyak@google.com>
1373
1374         Content element should be able to be dynamically added/removed/replaced in a shadow tree.
1375         https://bugs.webkit.org/show_bug.cgi?id=76611
1376
1377         Reviewed by Hajime Morita.
1378
1379         When a content element is added/removed/replaced in a shadow tree, we have to recreate
1380         the shadow tree to recalculate inclusions of content elements. Currently we didn't recalculate it
1381         when content element is removed. (When added, it is recalculated.)
1382         This patch enables us to recalcurate the shadow tree when content element is removed.
1383
1384         Test: fast/dom/shadow/content-element-move.html
1385
1386         * dom/Element.cpp:
1387         (WebCore::Element::attach):
1388           If a shadow root exists, attaches shadow tree before attaching child elements.
1389         * dom/ShadowRoot.cpp:
1390         (WebCore::ShadowRoot::recalcShadowTreeStyle):
1391           Recalculates light children and shadow tree.
1392         (WebCore::ShadowRoot::reattachHostChildrenAndShadow):
1393           Detaches shadow tree and host light children, and attaches them again.
1394         * dom/ShadowRoot.h:
1395           Added a flag to recalculate shadow tree.
1396         (WebCore::ShadowRoot::setNeedsShadowTreeStyleRecalc):
1397         (WebCore::ShadowRoot::clearNeedsShadowTreeStyleRecalc):
1398         (WebCore::ShadowRoot::needsShadowTreeStyleRecalc):
1399         * html/shadow/HTMLContentElement.cpp:
1400         (WebCore::HTMLContentElement::attach):
1401           Does not need to detach included elements, because they are not attached in ContainerNode anymore.
1402         (WebCore::HTMLContentElement::detach):
1403           When a content element detached, reattaches a shadow tree.
1404
1405 2012-01-31  Joe Thomas  <joethomas@motorola.com>
1406
1407         https://bugs.webkit.org/show_bug.cgi?id=76801
1408         Listboxes incorrectly display contents when cleared and then re-populated.
1409
1410         Whenever the number of items in the listbox is less than the size of listbox (number of visible items the listbox can accomodate),
1411         we set the listbox scroll-offset to zero. The scroll-offset of the Scrollbar should also be set to 0 so that when the listbox is re-populated,
1412         scrollbar position and the content inside the listbox are in sync.
1413
1414         Reviewed by Andreas Kling.
1415
1416         Tests: fast/forms/listbox-clear-restore.html
1417
1418         * rendering/RenderListBox.cpp:
1419         (WebCore::RenderListBox::computeLogicalHeight): Setting the scroll-offset of the Scrollbar to 0 when scrollbar is not needed.
1420
1421 2012-01-31  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1422
1423         Unreviewed. Fix build break after r106373.
1424
1425         * CMakeLists.txt:
1426
1427 2012-01-31  Adam Barth  <abarth@webkit.org>
1428
1429         HTMLPreloadScanner should understand the <base> element
1430         https://bugs.webkit.org/show_bug.cgi?id=77231
1431
1432         Reviewed by Eric Seidel.
1433
1434         Previously, the HTMLPreloadScanner would ignore the <base> element when
1435         preloading resources.  If there was a <base> tag, this could cause the
1436         preload scanner to make a bunch of useless requests.
1437
1438         This patch teaches the preload scanner to use <base> tags to better
1439         predict which URLs will be used by the document.
1440
1441         Tests: fast/preloader/first-base-tag-scanned-wins.html
1442                fast/preloader/first-base-tag-wins.html
1443                fast/preloader/understands-base-tag.html
1444
1445         * dom/Document.cpp:
1446         (WebCore::Document::completeURL):
1447         (WebCore):
1448         * dom/Document.h:
1449         (Document):
1450         (WebCore::Document::baseElementURL):
1451         * html/parser/HTMLPreloadScanner.cpp:
1452         (WebCore::HTMLNames::PreloadTask::PreloadTask):
1453         (WebCore::HTMLNames::PreloadTask::processAttributes):
1454         (WebCore::HTMLNames::PreloadTask::preload):
1455         (WebCore::HTMLNames::PreloadTask::baseElementHref):
1456         (PreloadTask):
1457         (WebCore::HTMLPreloadScanner::scan):
1458         (WebCore::HTMLPreloadScanner::processToken):
1459         (WebCore::HTMLPreloadScanner::updatePredictedBaseElementURL):
1460         (WebCore):
1461         * html/parser/HTMLPreloadScanner.h:
1462         (HTMLPreloadScanner):
1463
1464 2012-01-31  Raymond Liu  <raymond.liu@intel.com>
1465
1466         Dynamic allocate AudioBus with required number of channels for AudioNodeInput
1467         https://bugs.webkit.org/show_bug.cgi?id=76516
1468
1469         Reviewed by Kenneth Russell.
1470
1471         No new tests required.
1472
1473         * webaudio/AudioBasicProcessorNode.cpp:
1474         (WebCore::AudioBasicProcessorNode::checkNumberOfChannelsForInput):
1475         * webaudio/AudioChannelMerger.cpp:
1476         (WebCore::AudioChannelMerger::checkNumberOfChannelsForInput):
1477         * webaudio/AudioGainNode.cpp:
1478         (WebCore::AudioGainNode::checkNumberOfChannelsForInput):
1479         * webaudio/AudioNode.cpp:
1480         (WebCore::AudioNode::checkNumberOfChannelsForInput):
1481         * webaudio/AudioNode.h:
1482         * webaudio/AudioNodeInput.cpp:
1483         (WebCore::AudioNodeInput::AudioNodeInput):
1484         (WebCore::AudioNodeInput::updateInternalBus):
1485         (WebCore::AudioNodeInput::internalSummingBus):
1486         * webaudio/AudioNodeInput.h:
1487
1488 2012-01-31  Alexey Proskuryakov  <ap@apple.com>
1489
1490         REGRESSION (WebKit2): event.keyCode is always zero when typing in Russian
1491         https://bugs.webkit.org/show_bug.cgi?id=77473
1492         <rdar://problem/10751357>
1493
1494         Reviewed by Darin Adler.
1495
1496         Test: platform/mac/fast/events/non-roman-key-code.html
1497
1498         * WebCore.exp.in:
1499         * platform/mac/PlatformEventFactoryMac.h:
1500         * platform/mac/PlatformEventFactoryMac.mm:
1501         (WebCore::keyIdentifierForKeyEvent):
1502         (WebCore::windowsKeyCodeForKeyEvent):
1503         Export functions for reuse in WebKit2. I did not attempt any larger refactoring at this time.
1504
1505 2012-01-31  Gregg Tavares  <gman@google.com>
1506
1507         Make WebGL put synthesized errors in the JS console
1508         https://bugs.webkit.org/show_bug.cgi?id=77267
1509
1510         Reviewed by Kenneth Russell.
1511
1512         No new functionality so no new tests.
1513
1514         * html/canvas/WebGLCompressedTextures.cpp:
1515         (WebCore::WebGLCompressedTextures::validateCompressedTexFuncData):
1516         (WebCore::WebGLCompressedTextures::compressedTexImage2D):
1517         (WebCore::WebGLCompressedTextures::compressedTexSubImage2D):
1518         * html/canvas/WebGLCompressedTextures.h:
1519         (WebGLCompressedTextures):
1520         * html/canvas/WebGLDebugShaders.cpp:
1521         (WebCore::WebGLDebugShaders::getTranslatedShaderSource):
1522         * html/canvas/WebGLRenderingContext.cpp:
1523         (WebCore::WebGLRenderingContext::activeTexture):
1524         (WebCore::WebGLRenderingContext::attachShader):
1525         (WebCore::WebGLRenderingContext::bindAttribLocation):
1526         (WebCore::WebGLRenderingContext::checkObjectToBeBound):
1527         (WebCore::WebGLRenderingContext::bindBuffer):
1528         (WebCore::WebGLRenderingContext::bindFramebuffer):
1529         (WebCore::WebGLRenderingContext::bindRenderbuffer):
1530         (WebCore::WebGLRenderingContext::bindTexture):
1531         (WebCore::WebGLRenderingContext::blendEquation):
1532         (WebCore::WebGLRenderingContext::blendEquationSeparate):
1533         (WebCore::WebGLRenderingContext::blendFunc):
1534         (WebCore::WebGLRenderingContext::blendFuncSeparate):
1535         (WebCore::WebGLRenderingContext::bufferData):
1536         (WebCore::WebGLRenderingContext::bufferSubData):
1537         (WebCore::WebGLRenderingContext::checkFramebufferStatus):
1538         (WebCore::WebGLRenderingContext::clear):
1539         (WebCore::WebGLRenderingContext::compileShader):
1540         (WebCore::WebGLRenderingContext::compressedTexImage2D):
1541         (WebCore::WebGLRenderingContext::compressedTexSubImage2D):
1542         (WebCore::WebGLRenderingContext::copyTexImage2D):
1543         (WebCore::WebGLRenderingContext::copyTexSubImage2D):
1544         (WebCore::WebGLRenderingContext::createShader):
1545         (WebCore::WebGLRenderingContext::deleteObject):
1546         (WebCore::WebGLRenderingContext::depthRange):
1547         (WebCore::WebGLRenderingContext::detachShader):
1548         (WebCore::WebGLRenderingContext::disable):
1549         (WebCore::WebGLRenderingContext::disableVertexAttribArray):
1550         (WebCore::WebGLRenderingContext::validateWebGLObject):
1551         (WebCore::WebGLRenderingContext::drawArrays):
1552         (WebCore::WebGLRenderingContext::drawElements):
1553         (WebCore::WebGLRenderingContext::enable):
1554         (WebCore::WebGLRenderingContext::enableVertexAttribArray):
1555         (WebCore::WebGLRenderingContext::framebufferRenderbuffer):
1556         (WebCore::WebGLRenderingContext::framebufferTexture2D):
1557         (WebCore::WebGLRenderingContext::generateMipmap):
1558         (WebCore::WebGLRenderingContext::getActiveAttrib):
1559         (WebCore::WebGLRenderingContext::getActiveUniform):
1560         (WebCore::WebGLRenderingContext::getAttachedShaders):
1561         (WebCore::WebGLRenderingContext::getAttribLocation):
1562         (WebCore::WebGLRenderingContext::getBufferParameter):
1563         (WebCore::WebGLRenderingContext::getFramebufferAttachmentParameter):
1564         (WebCore::WebGLRenderingContext::getParameter):
1565         (WebCore::WebGLRenderingContext::getProgramParameter):
1566         (WebCore::WebGLRenderingContext::getProgramInfoLog):
1567         (WebCore::WebGLRenderingContext::getRenderbufferParameter):
1568         (WebCore::WebGLRenderingContext::getShaderParameter):
1569         (WebCore::WebGLRenderingContext::getShaderInfoLog):
1570         (WebCore::WebGLRenderingContext::getShaderSource):
1571         (WebCore::WebGLRenderingContext::getTexParameter):
1572         (WebCore::WebGLRenderingContext::getUniform):
1573         (WebCore::WebGLRenderingContext::getUniformLocation):
1574         (WebCore::WebGLRenderingContext::getVertexAttrib):
1575         (WebCore::WebGLRenderingContext::hint):
1576         (WebCore::WebGLRenderingContext::isEnabled):
1577         (WebCore::WebGLRenderingContext::linkProgram):
1578         (WebCore::WebGLRenderingContext::pixelStorei):
1579         (WebCore::WebGLRenderingContext::readPixels):
1580         (WebCore::WebGLRenderingContext::renderbufferStorage):
1581         (WebCore::WebGLRenderingContext::scissor):
1582         (WebCore::WebGLRenderingContext::shaderSource):
1583         (WebCore::WebGLRenderingContext::stencilFunc):
1584         (WebCore::WebGLRenderingContext::stencilFuncSeparate):
1585         (WebCore::WebGLRenderingContext::stencilMaskSeparate):
1586         (WebCore::WebGLRenderingContext::texImage2DBase):
1587         (WebCore::WebGLRenderingContext::texImage2DImpl):
1588         (WebCore::WebGLRenderingContext::texImage2D):
1589         (WebCore::WebGLRenderingContext::videoFrameToImage):
1590         (WebCore::WebGLRenderingContext::texParameter):
1591         (WebCore::WebGLRenderingContext::texSubImage2DBase):
1592         (WebCore::WebGLRenderingContext::texSubImage2DImpl):
1593         (WebCore::WebGLRenderingContext::texSubImage2D):
1594         (WebCore::WebGLRenderingContext::uniform1f):
1595         (WebCore::WebGLRenderingContext::uniform1fv):
1596         (WebCore::WebGLRenderingContext::uniform1i):
1597         (WebCore::WebGLRenderingContext::uniform1iv):
1598         (WebCore::WebGLRenderingContext::uniform2f):
1599         (WebCore::WebGLRenderingContext::uniform2fv):
1600         (WebCore::WebGLRenderingContext::uniform2i):
1601         (WebCore::WebGLRenderingContext::uniform2iv):
1602         (WebCore::WebGLRenderingContext::uniform3f):
1603         (WebCore::WebGLRenderingContext::uniform3fv):
1604         (WebCore::WebGLRenderingContext::uniform3i):
1605         (WebCore::WebGLRenderingContext::uniform3iv):
1606         (WebCore::WebGLRenderingContext::uniform4f):
1607         (WebCore::WebGLRenderingContext::uniform4fv):
1608         (WebCore::WebGLRenderingContext::uniform4i):
1609         (WebCore::WebGLRenderingContext::uniform4iv):
1610         (WebCore::WebGLRenderingContext::uniformMatrix2fv):
1611         (WebCore::WebGLRenderingContext::uniformMatrix3fv):
1612         (WebCore::WebGLRenderingContext::uniformMatrix4fv):
1613         (WebCore::WebGLRenderingContext::useProgram):
1614         (WebCore::WebGLRenderingContext::validateProgram):
1615         (WebCore::WebGLRenderingContext::vertexAttrib1f):
1616         (WebCore::WebGLRenderingContext::vertexAttrib1fv):
1617         (WebCore::WebGLRenderingContext::vertexAttrib2f):
1618         (WebCore::WebGLRenderingContext::vertexAttrib2fv):
1619         (WebCore::WebGLRenderingContext::vertexAttrib3f):
1620         (WebCore::WebGLRenderingContext::vertexAttrib3fv):
1621         (WebCore::WebGLRenderingContext::vertexAttrib4f):
1622         (WebCore::WebGLRenderingContext::vertexAttrib4fv):
1623         (WebCore::WebGLRenderingContext::vertexAttribPointer):
1624         (WebCore::WebGLRenderingContext::viewport):
1625         (WebCore::WebGLRenderingContext::forceLostContext):
1626         (WebCore::WebGLRenderingContext::loseContextImpl):
1627         (WebCore::WebGLRenderingContext::forceRestoreContext):
1628         (WebCore::WebGLRenderingContext::validateTextureBinding):
1629         (WebCore::WebGLRenderingContext::validateLocationLength):
1630         (WebCore::WebGLRenderingContext::validateSize):
1631         (WebCore::WebGLRenderingContext::validateString):
1632         (WebCore::WebGLRenderingContext::validateTexFuncFormatAndType):
1633         (WebCore::WebGLRenderingContext::validateTexFuncLevel):
1634         (WebCore::WebGLRenderingContext::validateTexFuncParameters):
1635         (WebCore::WebGLRenderingContext::validateTexFuncData):
1636         (WebCore::WebGLRenderingContext::validateDrawMode):
1637         (WebCore::WebGLRenderingContext::validateStencilSettings):
1638         (WebCore::WebGLRenderingContext::validateStencilFunc):
1639         (WebCore::WebGLRenderingContext::validateFramebufferFuncParameters):
1640         (WebCore::WebGLRenderingContext::validateBlendEquation):
1641         (WebCore::WebGLRenderingContext::validateBlendFuncFactors):
1642         (WebCore::WebGLRenderingContext::validateCapability):
1643         (WebCore::WebGLRenderingContext::validateUniformParameters):
1644         (WebCore::WebGLRenderingContext::validateUniformMatrixParameters):
1645         (WebCore::WebGLRenderingContext::validateBufferDataParameters):
1646         (WebCore::WebGLRenderingContext::validateHTMLImageElement):
1647         (WebCore::WebGLRenderingContext::vertexAttribfImpl):
1648         (WebCore::WebGLRenderingContext::vertexAttribfvImpl):
1649         (WebCore::WebGLRenderingContext::maybeRestoreContext):
1650         (WebCore):
1651         (WebCore::WebGLRenderingContext::synthesizeGLError):
1652         * html/canvas/WebGLRenderingContext.h:
1653         (WebGLRenderingContext):
1654
1655 2012-01-31  Raymond Liu  <raymond.liu@intel.com>
1656
1657         Clean up m_processLock logic in AudioBasicProcessorNode and AudioGainNode
1658         https://bugs.webkit.org/show_bug.cgi?id=76772
1659
1660         Reviewed by Kenneth Russell.
1661
1662         No new tests required.
1663
1664         * webaudio/AudioBasicProcessorNode.cpp:
1665         (WebCore::AudioBasicProcessorNode::process):
1666         (WebCore::AudioBasicProcessorNode::checkNumberOfChannelsForInput):
1667         * webaudio/AudioBasicProcessorNode.h:
1668         * webaudio/AudioGainNode.cpp:
1669         (WebCore::AudioGainNode::process):
1670         (WebCore::AudioGainNode::checkNumberOfChannelsForInput):
1671         * webaudio/AudioGainNode.h:
1672         (AudioGainNode):
1673
1674 2012-01-31  Adam Klein  <adamk@chromium.org>
1675
1676         ProcessingInstruction should not be a ContainerNode
1677         https://bugs.webkit.org/show_bug.cgi?id=75141
1678
1679         Reviewed by Darin Adler.
1680
1681         Per the DOM spec, ProcessingInstruction can't have any children.
1682         And the WebCore behavior already matches the spec by always returning
1683         false for childTypeAllowed(). This change simplifies
1684         ProcessingInstruction's implementation by making it subclass Node
1685         instead of ContainerNode.
1686
1687         Test: fast/dom/processing-instruction-appendChild-exceptions.xhtml
1688
1689         * dom/ContainerNode.cpp: Moved dispatchBeforeLoadEvent up to Node.
1690         * dom/ContainerNode.h:
1691         * dom/Node.cpp:
1692         (WebCore::Node::dispatchBeforeLoadEvent): Moved up from ContainerNode
1693         since it's used both by ProcessingInstruction and various Element
1694         subclasses.
1695         * dom/Node.h:
1696         * dom/ProcessingInstruction.cpp:
1697         (WebCore::ProcessingInstruction::ProcessingInstruction): Call Node constructor.
1698         (WebCore::ProcessingInstruction::insertedIntoDocument): Call Node impl.
1699         (WebCore::ProcessingInstruction::removedFromDocument): ditto.
1700         (WebCore::ProcessingInstruction::finishParsingChildren): ditto.
1701         * dom/ProcessingInstruction.h:
1702
1703 2012-01-31  Matthew Delaney  <mdelaney@apple.com>
1704
1705         Failing 2d.shadow.enable.off.2.html on Lion
1706         https://bugs.webkit.org/show_bug.cgi?id=77489
1707
1708         Reviewed by Dan Bernstein.
1709
1710         The canvas spec requires that shadows not be drawn under certain
1711         circumstances outlined here: http://www.whatwg.org/specs/web-apps/current-work/#shadows
1712         This patch adds in those checks which allows us to pass now (on Lion)
1713         the philip canvas test that was checking that constraint.
1714
1715         No new tests. Unskipping the test on Lion that this patch fixes.
1716
1717         * html/canvas/CanvasRenderingContext2D.cpp:
1718         (WebCore::CanvasRenderingContext2D::setAllAttributesToDefault):
1719         (WebCore::CanvasRenderingContext2D::setShadow):
1720         (WebCore::CanvasRenderingContext2D::applyShadow):
1721         (WebCore::CanvasRenderingContext2D::shouldDrawShadows):
1722         * html/canvas/CanvasRenderingContext2D.h:
1723         (CanvasRenderingContext2D):
1724
1725 2012-01-31  Anders Carlsson  <andersca@apple.com>
1726
1727         TileCache::setNeedsDisplayInRect cleanup
1728         https://bugs.webkit.org/show_bug.cgi?id=77486
1729
1730         Reviewed by Andreas Kling.
1731
1732         * platform/graphics/ca/mac/TileCache.h:
1733         * platform/graphics/ca/mac/TileCache.mm:
1734         (WebCore::TileCache::setNeedsDisplayInRect):
1735         TileCache::tileLayerAtIndex can in the future return nil, so cope with that. Also, replace
1736         nested if statements with continue statements.
1737
1738         (WebCore::TileCache::getTileIndexRangeForRect):
1739         Rename this to better indicate that it returns a range of indices.
1740
1741 2012-01-31  Dana Jansens  <danakj@chromium.org>
1742
1743         Add contains() test to Region
1744         https://bugs.webkit.org/show_bug.cgi?id=72294
1745
1746         Reviewed by Anders Carlsson.
1747
1748         * platform/graphics/Region.cpp:
1749         (WebCore::Region::contains):
1750         (WebCore):
1751         * platform/graphics/Region.h:
1752         (Region):
1753         (Shape):
1754         (WebCore::operator==):
1755         (WebCore):
1756
1757 2012-01-31  Sami Kyostila  <skyostil@chromium.org>
1758
1759         [chromium] Compositor debug borders are not scaled correctly
1760         https://bugs.webkit.org/show_bug.cgi?id=77468
1761
1762         Use CCLayerImpl::contentBounds() instead of CCLayerImpl::bounds() to calculate debug
1763         border geometry so that the borders are properly scaled.
1764
1765         Reviewed by James Robinson.
1766
1767         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
1768         (WebCore::CCLayerImpl::appendDebugBorderQuad):
1769
1770 2012-01-31  Sheriff Bot  <webkit.review.bot@gmail.com>
1771
1772         Unreviewed, rolling out r106376.
1773         http://trac.webkit.org/changeset/106376
1774         https://bugs.webkit.org/show_bug.cgi?id=77481
1775
1776         Broke WebGLLayerChromiumTest in webkit_unit_tests (Requested
1777         by kbr_google on #webkit).
1778
1779         * platform/graphics/gpu/DrawingBuffer.cpp:
1780         (WebCore):
1781         (WebCore::DrawingBuffer::reset):
1782
1783 2012-01-31  Mihnea Ovidenie  <mihnea@adobe.com>
1784
1785         [CSSRegions]Reduce the cases when the box style in region is computed
1786         https://bugs.webkit.org/show_bug.cgi?id=77446
1787
1788         Reviewed by David Hyatt.
1789
1790         Covered by existing region style tests.
1791
1792         * rendering/RenderRegion.cpp:
1793         (WebCore::RenderRegion::setRegionBoxesRegionStyle):
1794         (WebCore::RenderRegion::restoreRegionBoxesOriginalStyle):
1795
1796 2012-01-31  Anders Carlsson  <andersca@apple.com>
1797
1798         Put tiles in a HashMap
1799         https://bugs.webkit.org/show_bug.cgi?id=77480
1800
1801         Reviewed by Antti Koivisto.
1802
1803         Put tiles in a hash map keyed off the tile index.
1804
1805         * platform/graphics/ca/mac/TileCache.h:
1806         Shuffle member variables around so the order makes more sense.
1807         Add the tile map.
1808
1809         * platform/graphics/ca/mac/TileCache.mm:
1810         (WebCore::TileCache::TileCache):
1811         Update member initializers.
1812
1813         (WebCore::TileCache::setNeedsDisplayInRect):
1814         Call tileLayerAtIndex instead of tileLayerAtPosition.
1815
1816         (WebCore::TileCache::setAcceleratesDrawing):
1817         (WebCore::TileCache::setTileDebugBorderWidth):
1818         (WebCore::TileCache::setTileDebugBorderColor):
1819         Iterate over the hash map instead of the sublayers.
1820
1821         (WebCore::TileCache::resizeTileGrid):
1822         Add the created layers to the map.
1823
1824         (WebCore::TileCache::tileLayerAtIndex):
1825         Rename from tileLayerAtPoint to better reflect that this member function
1826         returns a tile layer at the given index and not the given point.
1827
1828 2012-01-31  Antti Koivisto  <antti@apple.com>
1829
1830         Make CSSOM style() return CSSStyleDeclaration*
1831         https://bugs.webkit.org/show_bug.cgi?id=77475
1832
1833         Reviewed by Anders Carlsson
1834
1835         CSSStyleRule::style() and some other places return CSSMutableStyleDeclaration. 
1836         They should return the plain CSSOM type instead.
1837         
1838         CSSMutableStyleDeclaration* should be available through non-CSSOM function.
1839
1840         * css/CSSFontFaceRule.h:
1841         (WebCore::CSSFontFaceRule::style):
1842         (WebCore::CSSFontFaceRule::declaration):
1843         * css/CSSFontSelector.cpp:
1844         (WebCore::CSSFontSelector::addFontFaceRule):
1845         * css/CSSStyleRule.h:
1846         (WebCore::CSSStyleRule::style):
1847         (WebCore::CSSStyleRule::declaration):
1848         * css/CSSStyleSelector.cpp:
1849         (WebCore::CSSStyleSelector::styleForKeyframe):
1850         * css/WebKitCSSKeyframeRule.h:
1851         (WebCore):
1852         (WebCore::WebKitCSSKeyframeRule::style):
1853         (WebCore::WebKitCSSKeyframeRule::declaration):
1854         (WebKitCSSKeyframeRule):
1855         * editing/EditingStyle.cpp:
1856         (WebCore::styleFromMatchedRulesForElement):
1857         * inspector/InspectorStyleSheet.cpp:
1858         (WebCore::InspectorStyleSheet::revalidateStyle):
1859         * page/PageSerializer.cpp:
1860         (WebCore::PageSerializer::retrieveResourcesForCSSRule):
1861         * svg/SVGFontFaceElement.cpp:
1862         (WebCore::SVGFontFaceElement::parseMappedAttribute):
1863         (WebCore::SVGFontFaceElement::fontFamily):
1864         (WebCore::SVGFontFaceElement::rebuildFontFace):
1865
1866 2012-01-31  Scott Graham  <scottmg@chromium.org>
1867
1868         [Chromium] Remove references to gyp cygwin build target
1869         https://bugs.webkit.org/show_bug.cgi?id=77253
1870
1871         Reviewed by Julien Chaffraix.
1872
1873         Target dependency is no longer required, it's done earlier in the
1874         build process.
1875
1876         * WebCore.gyp/WebCore.gyp:
1877
1878 2012-01-31  Jon Lee  <jonlee@apple.com>
1879
1880         Hidden form elements do not save their state prior to form submission
1881         https://bugs.webkit.org/show_bug.cgi?id=77391
1882         <rdar://problem/10563108>
1883
1884         Reviewed by Brady Eidson.
1885
1886         Test: fast/forms/state-restore-hidden.html
1887
1888         * html/HiddenInputType.cpp: Teach hidden inputs to save and restore their state.
1889         (WebCore::HiddenInputType::saveFormControlState):
1890         (WebCore::HiddenInputType::restoreFormControlState):
1891         * html/HiddenInputType.h:
1892         (HiddenInputType):
1893
1894 2012-01-31  Joshua Bell  <jsbell@chromium.org>
1895
1896         IndexedDB: IDBCursor.update() should raise exception if key changed
1897         https://bugs.webkit.org/show_bug.cgi?id=76952
1898
1899         Move the test from the async task to the synchronous call, per spec. Also re-ordered the tests
1900         done during the synchronous call and the asynchronous task to follow the spec order.
1901
1902         Reviewed by Tony Chang.
1903
1904         Tests: storage/indexeddb/cursor-update.html
1905
1906         * storage/IDBObjectStoreBackendImpl.cpp:
1907         (WebCore::IDBObjectStoreBackendImpl::put): Added check during update() call, order checks per spec.
1908         (WebCore::IDBObjectStoreBackendImpl::putInternal): Move effective key calculation inline.
1909         * storage/IDBObjectStoreBackendImpl.h: Removed selectKeyForPut method.
1910
1911 2012-01-31  Anders Carlsson  <andersca@apple.com>
1912
1913         Inform the tile cache whenever the visible rect changes
1914         https://bugs.webkit.org/show_bug.cgi?id=77470
1915
1916         Reviewed by Andreas Kling.
1917
1918         * platform/graphics/GraphicsLayer.h:
1919         (WebCore::GraphicsLayer::visibleRectChanged):
1920         Add empty function.
1921
1922         * platform/graphics/ca/GraphicsLayerCA.cpp:
1923         (WebCore::GraphicsLayerCA::visibleRectChanged):
1924         Call through to the PlatformCALayer.
1925
1926         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
1927         (PlatformCALayer::visibleRectChanged):
1928         Call through to the underlying WebTileCacheLayer.
1929
1930         * platform/graphics/ca/mac/TileCache.mm:
1931         (WebCore::TileCache::visibleRectChanged):
1932         Add empty stub.
1933
1934         (WebCore::TileCache::visibleRect):
1935         Add new (currently unused) helper function that returns the visible rect of the
1936         tile cache layer.
1937
1938         * platform/graphics/ca/mac/WebTileCacheLayer.h:
1939         * platform/graphics/ca/mac/WebTileCacheLayer.mm:
1940         (-[WebTileCacheLayer visibleRectChanged]):
1941         Call through to the TielCache object.
1942
1943         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
1944         (PlatformCALayer::visibleRectChanged):
1945         Add stub.
1946
1947         * rendering/RenderLayerCompositor.cpp:
1948         (WebCore::RenderLayerCompositor::frameViewDidScroll):
1949         Call GraphicsLayer::visibleRectChanged.
1950
1951 2012-01-31  Antti Koivisto  <antti@apple.com>
1952
1953         Remove CSSStyleDeclaration isElementStyleDeclaration bit
1954         https://bugs.webkit.org/show_bug.cgi?id=77460
1955
1956         Reviewed by Andreas Kling.
1957
1958         Inline style declaration is now the only type of style declaration with element parent.
1959         We can remove the bit and the associated logic.
1960
1961         * bindings/js/JSDOMBinding.h:
1962         (WebCore::root):
1963         * css/CSSMutableStyleDeclaration.cpp:
1964         (WebCore::CSSMutableStyleDeclaration::CSSMutableStyleDeclaration):
1965         (WebCore::CSSMutableStyleDeclaration::setNeedsStyleRecalc):
1966         * css/CSSMutableStyleDeclaration.h:
1967         (WebCore::CSSMutableStyleDeclaration::createInline):
1968         (CSSMutableStyleDeclaration):
1969         * css/CSSStyleDeclaration.cpp:
1970         (WebCore::CSSStyleDeclaration::CSSStyleDeclaration):
1971         (WebCore):
1972         (WebCore::CSSStyleDeclaration::parentStyleSheet):
1973         * css/CSSStyleDeclaration.h:
1974         (WebCore::CSSStyleDeclaration::parentRule):
1975         (WebCore::CSSStyleDeclaration::clearParentRule):
1976         (WebCore::CSSStyleDeclaration::parentElement):
1977         (WebCore::CSSStyleDeclaration::clearParentElement):
1978         (CSSStyleDeclaration):
1979
1980 2012-01-31  Dana Jansens  <danakj@chromium.org>
1981
1982         [chromium] Compute occlusion during paint loop
1983         https://bugs.webkit.org/show_bug.cgi?id=76858
1984
1985         Reviewed by James Robinson.
1986
1987         New unit tests in TiledLayerChromiumTest.cpp, CCLayerTreeHostCommonTest.cpp, CCLayerTreeHostTest.cpp
1988
1989         * platform/graphics/FloatRect.cpp:
1990         (WebCore::enclosedIntRect):
1991         (WebCore):
1992         * platform/graphics/FloatRect.h:
1993         (WebCore):
1994         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
1995         (WebCore::Canvas2DLayerChromium::paintContentsIfDirty):
1996         * platform/graphics/chromium/Canvas2DLayerChromium.h:
1997         (Canvas2DLayerChromium):
1998         * platform/graphics/chromium/ContentLayerChromium.cpp:
1999         (WebCore::ContentLayerChromium::paintContentsIfDirty):
2000         * platform/graphics/chromium/ContentLayerChromium.h:
2001         (ContentLayerChromium):
2002         * platform/graphics/chromium/ImageLayerChromium.cpp:
2003         (WebCore::ImageLayerChromium::paintContentsIfDirty):
2004         * platform/graphics/chromium/ImageLayerChromium.h:
2005         (ImageLayerChromium):
2006         * platform/graphics/chromium/LayerChromium.cpp:
2007         (WebCore::LayerChromium::contentToScreenSpaceTransform):
2008         (WebCore):
2009         (WebCore::LayerChromium::addSelfToOccludedScreenSpace):
2010         (WebCore::LayerChromium::isPaintedAxisAlignedInScreen):
2011         * platform/graphics/chromium/LayerChromium.h:
2012         (WebCore):
2013         (WebCore::LayerChromium::paintContentsIfDirty):
2014         (LayerChromium):
2015         * platform/graphics/chromium/RenderSurfaceChromium.h:
2016         (RenderSurfaceChromium):
2017         * platform/graphics/chromium/TiledLayerChromium.cpp:
2018         (WebCore::TiledLayerChromium::addSelfToOccludedScreenSpace):
2019         * platform/graphics/chromium/TiledLayerChromium.h:
2020         (WebCore):
2021         ():
2022         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2023         (WebCore::CCLayerTreeHost::paintContentsIfDirty):
2024         (WebCore::CCLayerTreeHost::paintMaskAndReplicaForRenderSurface):
2025         (RenderSurfaceRegion):
2026         (WebCore):
2027         (WebCore::pushTargetRenderSurfaceRegion):
2028         (WebCore::popAndPushTargetRenderSurfaceRegion):
2029         (WebCore::CCLayerTreeHost::paintLayerContents):
2030         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2031         (WebCore):
2032         ():
2033         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
2034
2035 2012-01-31  John Bates  <jbates@google.com>
2036
2037         [Chromium] Add chromium-style tracing support
2038         https://bugs.webkit.org/show_bug.cgi?id=76885
2039
2040         Reviewed by Darin Fisher.
2041
2042         This code enables WebKit trace events to pass through more data to the
2043         chromium platform tracing API and generally to use the full tracing
2044         API provided by chromium.
2045
2046         * bindings/v8/V8Proxy.cpp:
2047         (WebCore::V8Proxy::evaluate): Replace old tracing API.
2048         * page/Console.cpp:
2049         (WebCore::Console::time): Replace old tracing API.
2050         (WebCore::Console::timeEnd): Replace old tracing API.
2051         * platform/chromium/PlatformSupport.h:
2052         * platform/chromium/TraceEvent.h:
2053         (WebCore::TraceEvent::TraceID::TraceID):
2054         (WebCore::TraceEvent::TraceID::data):
2055         (WebCore::TraceEvent::TraceStringWithCopy::TraceStringWithCopy):
2056         (WebCore::TraceEvent::TraceStringWithCopy::operator const char* ):
2057         (WebCore::TraceEvent::setTraceValue):
2058         (WebCore::TraceEvent::addTraceEvent):
2059         (WebCore::TraceEvent::TraceEndOnScopeClose::TraceEndOnScopeClose):
2060         (WebCore::TraceEvent::TraceEndOnScopeClose::~TraceEndOnScopeClose):
2061         (WebCore::TraceEvent::TraceEndOnScopeClose::initialize):
2062         (WebCore::TraceEvent::TraceEndOnScopeClose::addEventIfEnabled):
2063         (WebCore::TraceEvent::TraceEndOnScopeCloseThreshold::TraceEndOnScopeCloseThreshold):
2064         (WebCore::TraceEvent::TraceEndOnScopeCloseThreshold::~TraceEndOnScopeCloseThreshold):
2065         (WebCore::TraceEvent::TraceEndOnScopeCloseThreshold::initialize):
2066         (WebCore::TraceEvent::TraceEndOnScopeCloseThreshold::addEventIfEnabled):
2067
2068 2012-01-31  Ryosuke Niwa  <rniwa@webkit.org>
2069
2070         Crash in DeleteSelectionCommand::handleGeneralDelete when attempting to delete the start block
2071         https://bugs.webkit.org/show_bug.cgi?id=77077
2072
2073         Reviewed by Enrica Casucci.
2074
2075         The crash was caused by a missing null check after removing the position out of the start block.
2076         Fixed the bug by adding an early return.
2077
2078         Tests: editing/deleting/delete-start-block.html
2079                editing/selection/move-into-empty-root-inline-box.html
2080
2081         * editing/DeleteSelectionCommand.cpp:
2082         (WebCore::DeleteSelectionCommand::handleGeneralDelete):
2083
2084 2012-01-31  Rafael Brandao  <rafael.lobo@openbossa.org>
2085
2086         HTMLIsIndexElement should not expose HTMLInputElement properties
2087         https://bugs.webkit.org/show_bug.cgi?id=76095
2088
2089         Reviewed by Eric Seidel.
2090
2091         This is a buildfix for r106373.
2092
2093         * DerivedSources.pri: Removed reference to HTMLIsIndexElement.idl
2094
2095 2012-01-31  Yongsheng Zhu  <yongsheng.zhu@intel.com>
2096
2097         WebGL must allocate smaller drawing buffer when the allocation fails. 
2098         https://bugs.webkit.org/show_bug.cgi?id=76654
2099
2100         Reviewed by Kenneth Russell.
2101
2102         Test: fast/canvas/webgl/drawingbuffer-test.html
2103
2104         * platform/graphics/gpu/DrawingBuffer.cpp:
2105         (WebCore):
2106         (WebCore::DrawingBuffer::create):
2107         (WebCore::DrawingBuffer::reset):
2108
2109 2012-01-25  Eric Seidel  <eric@webkit.org>
2110
2111         HTMLIsIndexElement should not expose HTMLInputElement properties
2112         https://bugs.webkit.org/show_bug.cgi?id=76095
2113
2114         Reviewed by Adam Barth.
2115
2116         document.createElement("isindex") should produce an HTMLUnknownElement
2117         per the HTML5 spec.  The parser automagically translates <isindex> into
2118         a whole dom tree roughly representing what <isindex> used to do 15 years ago. :)
2119
2120         This patch just removes our support for HTMLIsIndexElement.  The parser
2121         support was already in.  Having support for HTMLIsIndexElement was causing
2122         one of the IE TestCenter tests to fail.
2123
2124         Test: fast/dom/HTMLIsIndexElement/prototype-chain.html
2125
2126         * DerivedSources.cpp:
2127         * DerivedSources.make:
2128         * DerivedSources.pri:
2129         * GNUmakefile.list.am:
2130         * Target.pri:
2131         * WebCore.exp.in:
2132         * WebCore.gypi:
2133         * WebCore.order:
2134         * WebCore.vcproj/WebCore.vcproj:
2135         * WebCore.xcodeproj/project.pbxproj:
2136         * bindings/gobject/GNUmakefile.am:
2137         * bindings/gobject/WebKitHTMLElementWrapperFactory.cpp:
2138         (WebKit::createHTMLElementWrapper):
2139         * bindings/objc/DOM.mm:
2140         (WebCore::createElementClassMap):
2141         * bindings/objc/DOMHTML.h:
2142         * bindings/objc/PublicDOMInterfaces.h:
2143         * html/HTMLElementsAllInOne.cpp:
2144         * html/HTMLIsIndexElement.cpp: Removed.
2145         * html/HTMLIsIndexElement.h: Removed.
2146         * html/HTMLIsIndexElement.idl: Removed.
2147         * html/HTMLTagNames.in:
2148         * page/DOMWindow.idl:
2149
2150 2012-01-31  Alexis Menard  <alexis.menard@openbossa.org>
2151
2152         Unreviewed include cleanup.
2153
2154         Tested locally on Qt and Chromium port.
2155
2156         * dom/Node.cpp:
2157
2158 2012-01-31  Arko Saha  <arko@motorola.com>
2159
2160         The spec renamed addTrack() to addTextTrack().
2161         https://bugs.webkit.org/show_bug.cgi?id=77381
2162
2163         Reviewed by Eric Carlson.
2164
2165         Renamed addTrack() to addTextTrack().
2166         Spec: http://www.whatwg.org/specs/web-apps/current-work/multipage/the-video-element.html#media-elements
2167
2168         * html/HTMLMediaElement.cpp:
2169         (WebCore::HTMLMediaElement::addTextTrack):
2170         * html/HTMLMediaElement.h:
2171         (WebCore::HTMLMediaElement::addTextTrack):
2172         * html/HTMLMediaElement.idl:
2173
2174 2012-01-31  Peter Rybin  <peter.rybin@gmail.com>
2175
2176         Web Inspector: CodeGeneratorInspector.py: reimplement generated array types
2177         https://bugs.webkit.org/show_bug.cgi?id=77289
2178
2179         Reviewed by Vsevolod Vlasov.
2180
2181         Arrays are now rendered as a single template class. Its type-specific
2182         details are provided by an additional ArrayItemHelper class that is
2183         defined using C++ specialization technique.
2184
2185         * inspector/CodeGeneratorInspector.py:
2186         (RawTypes.String):
2187         (RawTypes.String.get_array_item_raw_c_type_text):
2188         (RawTypes.Int):
2189         (RawTypes.Int.get_array_item_raw_c_type_text):
2190         (RawTypes.Number):
2191         (RawTypes.Number.get_array_item_raw_c_type_text):
2192         (RawTypes.Bool):
2193         (RawTypes.Bool.get_array_item_raw_c_type_text):
2194         (RawTypes.Object):
2195         (RawTypes.Object.get_array_item_raw_c_type_text):
2196         (RawTypes.Any):
2197         (RawTypes.Any.get_array_item_raw_c_type_text):
2198         (RawTypes.Array):
2199         (RawTypes.Array.get_array_item_raw_c_type_text):
2200         (RawTypes):
2201         (TypeBindings.create_type_declaration_.EnumBinding):
2202         (TypeBindings.create_type_declaration_.EnumBinding.get_array_item_c_type_text):
2203         (TypeBindings.create_type_declaration_.PlainString):
2204         (TypeBindings.create_type_declaration_.PlainString.get_array_item_c_type_text):
2205         (TypeBindings.create_type_declaration_.TypedefString):
2206         (TypeBindings.create_type_declaration_.TypedefString.get_array_item_c_type_text):
2207         (StructItemTraits):
2208         (get_array_item_c_type_text):
2209         (PlainObjectBinding):
2210         (PlainObjectBinding.get_array_item_c_type_text):
2211         (AdHocTypeContext):
2212         (AdHocTypeContext.get_type_name_fix):
2213         (AdHocTypeContext.add_type):
2214         (ArrayBinding):
2215         (ArrayBinding.resolve_inner):
2216         (ArrayBinding.resolve_inner.ResolveData):
2217         (ArrayBinding.request_user_runtime_cast):
2218         (ArrayBinding.request_internal_runtime_cast):
2219         (ArrayBinding.get_code_generator):
2220         (ArrayBinding.get_code_generator.CodeGenerator):
2221         (ArrayBinding.get_code_generator.CodeGenerator.generate_type_builder):
2222         (ArrayBinding.get_code_generator.CodeGenerator.generate_forward_declaration):
2223         (ArrayBinding.get_code_generator.CodeGenerator.register_use):
2224         (ArrayBinding.get_code_generator.CodeGenerator.get_generate_pass_id):
2225         (ArrayBinding.get_validator_call_text):
2226         (ArrayBinding.get_in_c_type_text):
2227         (ArrayBinding.get_array_item_c_type_text):
2228         (ArrayBinding.get_setter_value_expression_pattern):
2229         (ArrayBinding.reduce_to_raw_type):
2230         (RawTypeBinding.get_array_item_c_type_text):
2231         (ArrayItemHelper):
2232         (typename):
2233         (ArrayOf):
2234         (Traits):
2235
2236 2012-01-31  Antti Koivisto  <antti@apple.com>
2237
2238         Parent SVGFontFaceElements style declaration to the rule
2239         https://bugs.webkit.org/show_bug.cgi?id=77421
2240
2241         Reviewed by Adam Roben.
2242
2243         For some reason the declaration is parented to the element which adds a bunch of unnecessary special case code.
2244         The invalidation on mutation is done explicitly by SVGFontFaceElement so that is not affected. The declaration
2245         is not exposed so the change is not observable with a test.
2246
2247         * css/CSSFontFaceRule.cpp:
2248         (WebCore::CSSFontFaceRule::~CSSFontFaceRule):
2249         * css/CSSMutableStyleDeclaration.h:
2250         (WebCore::CSSMutableStyleDeclaration::createInline):
2251         * svg/SVGFontFaceElement.cpp:
2252         (WebCore::SVGFontFaceElement::SVGFontFaceElement):
2253         (WebCore::SVGFontFaceElement::parseMappedAttribute):
2254         (WebCore::SVGFontFaceElement::fontFamily):
2255         (WebCore::SVGFontFaceElement::rebuildFontFace):
2256         * svg/SVGFontFaceElement.h:
2257         
2258             Remove the unnecessary m_styleDeclaration field, access through m_fontFaceRule instead.
2259
2260 2012-01-31  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2261
2262         Tap highlighting: Support better outlines for multiline inlines
2263         https://bugs.webkit.org/show_bug.cgi?id=77428
2264
2265         Reviewed by Simon Hausmann.
2266
2267         Covered by manual tests.
2268
2269         Do not use the linesBoundingBox anymore but draw a custom path
2270         with rounded corners. Inlines are drawn as max 3 rects, first
2271         line rect, joined middle rect and the rect for the last line.
2272
2273         * page/GestureTapHighlighter.cpp:
2274         * platform/graphics/Path.h: Make addBeziersForRoundedRect public.
2275
2276 2012-01-31  Alexei Filippov  <alexeif@chromium.org>
2277
2278         Web Inspector: show sizes in bytes instead of KB, MB in heap profiler.
2279         https://bugs.webkit.org/show_bug.cgi?id=77199
2280
2281         Reviewed by Pavel Feldman.
2282
2283         * inspector/front-end/DetailedHeapshotGridNodes.js:
2284         (WebInspector.HeapSnapshotGenericObjectNode.prototype.get data):
2285         (WebInspector.HeapSnapshotInstanceNode.prototype._enhanceData):
2286         (WebInspector.HeapSnapshotConstructorNode.prototype.get data):
2287         (WebInspector.HeapSnapshotDiffNode.prototype.get data):
2288         * inspector/front-end/UIUtils.js:
2289         (Number.withThousandsSeparator):
2290
2291 2012-01-26  Hans Wennborg  <hans@chromium.org>
2292
2293         Speech Input: move MockSpeechInputClient into Chromium DumpRenderTree implementation
2294         https://bugs.webkit.org/show_bug.cgi?id=77083
2295
2296         Reviewed by Darin Fisher.
2297
2298         Remove SpeechInputClientMock. The mock is moving to the DumpRenderTree
2299         implementation.
2300
2301         No new tests, just refactoring.
2302
2303         * GNUmakefile.list.am:
2304         * Target.pri:
2305         * WebCore.gypi:
2306         * WebCore.vcproj/WebCore.vcproj:
2307         * WebCore.xcodeproj/project.pbxproj:
2308         * platform/mock/SpeechInputClientMock.cpp: Removed.
2309         * platform/mock/SpeechInputClientMock.h: Removed.
2310
2311 2012-01-31  Pavel Feldman  <pfeldman@google.com>
2312
2313         Web Inspector: boost protocol version to 1.0
2314         https://bugs.webkit.org/show_bug.cgi?id=77408
2315
2316         Reviewed by Yury Semikhatsky.
2317
2318         * inspector/Inspector-1.0.json: Copied from Source/WebCore/inspector/Inspector.json.
2319         * inspector/Inspector.json:
2320
2321 2012-01-31  Roland Steiner  <rolandsteiner@chromium.org>
2322
2323         <style scoped>: Improve shortcut code for cases where <style scoped> isn't used
2324         https://bugs.webkit.org/show_bug.cgi?id=77410
2325
2326         Move shortcut from setupScopingElementStack(), do it at the calling sites instead
2327         (where a larger chunk of work can be skipped).
2328
2329         Reviewed by Antti Koivisto.
2330
2331         No new tests. (refactoring)
2332
2333         * css/CSSStyleSelector.cpp:
2334         (WebCore::CSSStyleSelector::setupScopingElementStack): remove shortcut code
2335         (WebCore::CSSStyleSelector::pushParent): add shortcut code
2336         (WebCore::CSSStyleSelector::matchScopedAuthorRules): factor matching scoped rules out from matchAuthorRules
2337         (WebCore::CSSStyleSelector::matchAuthorRules): add shortcut code
2338         * css/CSSStyleSelector.h:
2339         (CSSStyleSelector): add matchScopedAuthorRules
2340
2341 2012-01-31  Pavel Feldman  <pfeldman@google.com>
2342
2343         Web Inspector: DOMDebugger.setEventListenerBreakpoint should accept regular DOM event names.
2344         https://bugs.webkit.org/show_bug.cgi?id=77409
2345
2346         Reviewed by Yury Semikhatsky.
2347
2348         * inspector/Inspector.json:
2349         * inspector/InspectorDOMDebuggerAgent.cpp:
2350         (WebCore::InspectorDOMDebuggerAgent::setEventListenerBreakpoint):
2351         (WebCore):
2352         (WebCore::InspectorDOMDebuggerAgent::setInstrumentationBreakpoint):
2353         (WebCore::InspectorDOMDebuggerAgent::setBreakpoint):
2354         (WebCore::InspectorDOMDebuggerAgent::removeEventListenerBreakpoint):
2355         (WebCore::InspectorDOMDebuggerAgent::removeInstrumentationBreakpoint):
2356         (WebCore::InspectorDOMDebuggerAgent::removeBreakpoint):
2357         (WebCore::InspectorDOMDebuggerAgent::pauseOnNativeEventIfNeeded):
2358         * inspector/InspectorDOMDebuggerAgent.h:
2359         (InspectorDOMDebuggerAgent):
2360         * inspector/InspectorInstrumentation.cpp:
2361         (WebCore::InspectorInstrumentation::didInstallTimerImpl):
2362         (WebCore::InspectorInstrumentation::didRemoveTimerImpl):
2363         (WebCore::InspectorInstrumentation::willHandleEventImpl):
2364         (WebCore::InspectorInstrumentation::willFireTimerImpl):
2365         (WebCore::InspectorInstrumentation::pauseOnNativeEventIfNeeded):
2366         * inspector/InspectorInstrumentation.h:
2367         (InspectorInstrumentation):
2368         * inspector/front-end/BreakpointsSidebarPane.js:
2369         (WebInspector.EventListenerBreakpointsSidebarPane.prototype._setBreakpoint):
2370         (WebInspector.EventListenerBreakpointsSidebarPane.prototype._removeBreakpoint):
2371
2372 2012-01-31  Pablo Flouret  <pablof@motorola.com>
2373
2374         Fix compilation errors on build-webkit --debug --no-workers on mac.
2375         https://bugs.webkit.org/show_bug.cgi?id=75869
2376
2377         Reviewed by Adam Barth.
2378
2379         * WebCore.exp.in:
2380
2381 2012-01-30  Konrad Piascik  <kpiascik@rim.com>
2382
2383         Web Inspector: [BlackBerry] Add BlackBerry UA Strings to the Inspector's UA switcher
2384         https://bugs.webkit.org/show_bug.cgi?id=77343
2385
2386         Reviewed by Yury Semikhatsky.
2387
2388         * inspector/front-end/SettingsScreen.js:
2389         (WebInspector.SettingsScreen.prototype._createUserAgentSelectRowElement.get const):
2390
2391 2012-01-30  Yury Semikhatsky  <yurys@chromium.org>
2392
2393         Web Inspector: should be possible to step through all event listeners when event listener breakpoint is hit
2394         https://bugs.webkit.org/show_bug.cgi?id=77331
2395
2396         Inspector instrumentation is called before and after each event handler invokation.
2397         In case inspector front-end is closed it is no-op, otherwise it may stop execution
2398         on an event listener breakpoint.
2399
2400         Reviewed by Pavel Feldman.
2401
2402         Test: inspector/debugger/step-through-event-listeners.html
2403
2404         * dom/EventTarget.cpp:
2405         (WebCore::EventTarget::fireEventListeners):
2406         * inspector/InspectorInstrumentation.cpp:
2407         (WebCore::InspectorInstrumentation::willDispatchEventImpl):
2408         (WebCore::InspectorInstrumentation::willHandleEventImpl):
2409         (WebCore):
2410         (WebCore::InspectorInstrumentation::didHandleEventImpl):
2411         (WebCore::InspectorInstrumentation::didDispatchEventImpl):
2412         (WebCore::InspectorInstrumentation::willDispatchEventOnWindowImpl):
2413         (WebCore::InspectorInstrumentation::didDispatchEventOnWindowImpl):
2414         * inspector/InspectorInstrumentation.h:
2415         (InspectorInstrumentation):
2416         (WebCore::InspectorInstrumentation::willHandleEvent):
2417         (WebCore):
2418         (WebCore::InspectorInstrumentation::didHandleEvent):
2419
2420 2011-01-30  Hayato Ito  <hayato@chromium.org>
2421
2422         Attach light children after removing a shadow root.
2423         https://bugs.webkit.org/show_bug.cgi?id=74267
2424
2425         Reviewed by Ryosuke Niwa.
2426
2427         Tests: fast/dom/shadow/dynamically-created-shadow-root-expected.html
2428                fast/dom/shadow/dynamically-created-shadow-root.html:
2429
2430         * dom/Element.cpp:
2431         (WebCore::Element::removeShadowRoot):
2432
2433 2012-01-30  Sheriff Bot  <webkit.review.bot@gmail.com>
2434
2435         Unreviewed, rolling out r106324.
2436         http://trac.webkit.org/changeset/106324
2437         https://bugs.webkit.org/show_bug.cgi?id=77406
2438
2439         Broke CCLayerTreeHostTestLayerOcclusion.runMultiThread and
2440         runSingleThread (Requested by yuzo1 on #webkit).
2441
2442         * platform/graphics/FloatRect.cpp:
2443         * platform/graphics/FloatRect.h:
2444         (WebCore):
2445         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
2446         (WebCore::Canvas2DLayerChromium::paintContentsIfDirty):
2447         * platform/graphics/chromium/Canvas2DLayerChromium.h:
2448         (WebCore):
2449         (Canvas2DLayerChromium):
2450         * platform/graphics/chromium/ContentLayerChromium.cpp:
2451         (WebCore::ContentLayerChromium::paintContentsIfDirty):
2452         * platform/graphics/chromium/ContentLayerChromium.h:
2453         (WebCore):
2454         (ContentLayerChromium):
2455         * platform/graphics/chromium/ImageLayerChromium.cpp:
2456         (WebCore::ImageLayerChromium::paintContentsIfDirty):
2457         * platform/graphics/chromium/ImageLayerChromium.h:
2458         (WebCore):
2459         (ImageLayerChromium):
2460         * platform/graphics/chromium/LayerChromium.cpp:
2461         * platform/graphics/chromium/LayerChromium.h:
2462         (WebCore):
2463         (WebCore::LayerChromium::paintContentsIfDirty):
2464         (LayerChromium):
2465         * platform/graphics/chromium/RenderSurfaceChromium.h:
2466         * platform/graphics/chromium/TiledLayerChromium.cpp:
2467         * platform/graphics/chromium/TiledLayerChromium.h:
2468         (WebCore):
2469         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2470         (WebCore::CCLayerTreeHost::paintContentsIfDirty):
2471         (WebCore::CCLayerTreeHost::paintMaskAndReplicaForRenderSurface):
2472         (WebCore::CCLayerTreeHost::paintLayerContents):
2473         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2474         (WebCore):
2475         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
2476         (WebCore::enclosedIntRect):
2477         (WebCore):
2478
2479 2012-01-30  Raymond Liu  <raymond.liu@intel.com>
2480
2481         Fix ASSERT fail within AudioBus::processWithGainFrom()
2482         https://bugs.webkit.org/show_bug.cgi?id=76685
2483
2484         Reviewed by Daniel Bates.
2485
2486         Test: webaudio/audionode-connect-order.html
2487
2488         * webaudio/AudioBasicProcessorNode.cpp:
2489         (WebCore::AudioBasicProcessorNode::AudioBasicProcessorNode):
2490
2491 2012-01-30  Roland Steiner  <rolandsteiner@chromium.org>
2492
2493         <style scoped>: Implement scoped stylesheets and basic application
2494         https://bugs.webkit.org/show_bug.cgi?id=73190
2495
2496         Implementing support for <style scoped>:
2497         Add a vector stack to CSSStyleSelector that keeps track of encountered scoping elements. This is
2498         used for O(1) access to all relevant style sheets for a given element.
2499         Adapt matching of author style sheets to also consult appropriate scoped sheets.
2500         Finally, prevent style sharing from crossing into/out of scoped style boundaries.
2501
2502         Reviewed by Antti Koivisto.
2503
2504         Tests: fast/css/style-scoped/style-scoped-attach.html
2505                fast/css/style-scoped/style-scoped-basic.html
2506                fast/css/style-scoped/style-scoped-detach.html
2507                fast/css/style-scoped/style-scoped-remove-scoped.html
2508                fast/css/style-scoped/style-scoped-set-scoped.html
2509
2510         * css/CSSStyleSelector.cpp:
2511         (RuleSet):
2512         (WebCore::CSSStyleSelector::CSSStyleSelector): add code for scoped style sheets
2513         (WebCore::CSSStyleSelector::collectFeatures): ditto
2514         (WebCore):
2515         (WebCore::CSSStyleSelector::determineScopingElement): determine whether an author sheet is scoped (and to which scope), or global
2516         (WebCore::CSSStyleSelector::scopedRuleSetForElement): returns the RuleSet for the <style scoped> contained by the passed-in element (if any), or 0
2517         (WebCore::CSSStyleSelector::appendAuthorStylesheets): add code for scoped style sheets
2518         (WebCore::CSSStyleSelector::setupScopingElementStack): determine scoping element ancestors of the given element
2519         (WebCore::CSSStyleSelector::pushParent): simplify and refactor SelectorChecker::pushParent, as code in CSStyleSelector needs partial access
2520         (WebCore::CSSStyleSelector::popParent): ditto
2521         (WebCore::CSSStyleSelector::sortAndTransferMatchedRules): helper function
2522         (WebCore::CSSStyleSelector::matchAuthorRules): use AuthorRuleSetIterator to iterate over all relevant RuleSets
2523         (WebCore::CSSStyleSelector::matchRules): adapt for scoped style rules
2524         (WebCore::CSSStyleSelector::matchAllRules): ditto
2525         (WebCore::CSSStyleSelector::locateCousinList): prevent style sharing across scope boundaries
2526         (WebCore::CSSStyleSelector::canShareStyleWithElement): ditto
2527         (WebCore::CSSStyleSelector::locateSharedStyle): ditto
2528         (WebCore::CSSStyleSelector::pseudoStyleForElement): changed call to matchAuthorRules
2529         (WebCore::CSSStyleSelector::styleForPage): add comment
2530         (WebCore::CSSStyleSelector::checkRegionStyle): add global scope parameter
2531         (WebCore::CSSStyleSelector::pseudoStyleRulesForElement): changed call to matchAuthorRules
2532         (WebCore::RuleSet::addRulesFromSheet): adapt for scoped style rules
2533         * css/CSSStyleSelector.h:
2534         (CSSStyleSelector):
2535         (WebCore::CSSStyleSelector::ScopeStackFrame::ScopeStackFrame): struct holding an Element pointer and a RuleSet pointer, to be used in a Vector
2536         (WebCore::CSSStyleSelector::scopingElementStackIsConsistent): returns if the last seen parent matches the passed-in element
2537         * css/SelectorChecker.cpp:
2538         (WebCore::SelectorChecker::setupParentStack): set up the parent stack (refactoring)
2539         (WebCore::SelectorChecker::pushParent): simplify and refactor
2540         * css/SelectorChecker.h:
2541         (WebCore::SelectorChecker::popParent): ditto
2542         (WebCore::SelectorChecker::parentStackIsEmpty): ditto
2543         (WebCore::SelectorChecker::parentStackIsConsistent): make parameter const
2544
2545 2012-01-30  Dana Jansens  <danakj@chromium.org>
2546
2547         [chromium] Compute occlusion during paint loop
2548         https://bugs.webkit.org/show_bug.cgi?id=76858
2549
2550         Reviewed by James Robinson.
2551
2552         New unit tests in TiledLayerChromiumTest.cpp, CCLayerTreeHostCommonTest.cpp, CCLayerTreeHostTest.cpp
2553
2554         * platform/graphics/FloatRect.cpp:
2555         (WebCore::enclosedIntRect):
2556         (WebCore):
2557         * platform/graphics/FloatRect.h:
2558         (WebCore):
2559         * platform/graphics/chromium/Canvas2DLayerChromium.cpp:
2560         (WebCore::Canvas2DLayerChromium::paintContentsIfDirty):
2561         * platform/graphics/chromium/Canvas2DLayerChromium.h:
2562         (Canvas2DLayerChromium):
2563         * platform/graphics/chromium/ContentLayerChromium.cpp:
2564         (WebCore::ContentLayerChromium::paintContentsIfDirty):
2565         * platform/graphics/chromium/ContentLayerChromium.h:
2566         (ContentLayerChromium):
2567         * platform/graphics/chromium/ImageLayerChromium.cpp:
2568         (WebCore::ImageLayerChromium::paintContentsIfDirty):
2569         * platform/graphics/chromium/ImageLayerChromium.h:
2570         (ImageLayerChromium):
2571         * platform/graphics/chromium/LayerChromium.cpp:
2572         (WebCore::LayerChromium::contentToScreenSpaceTransform):
2573         (WebCore):
2574         (WebCore::LayerChromium::addSelfToOccludedScreenSpace):
2575         (WebCore::LayerChromium::isPaintedAxisAlignedInScreen):
2576         * platform/graphics/chromium/LayerChromium.h:
2577         (WebCore):
2578         (WebCore::LayerChromium::paintContentsIfDirty):
2579         (LayerChromium):
2580         * platform/graphics/chromium/RenderSurfaceChromium.h:
2581         (RenderSurfaceChromium):
2582         * platform/graphics/chromium/TiledLayerChromium.cpp:
2583         (WebCore::TiledLayerChromium::addSelfToOccludedScreenSpace):
2584         * platform/graphics/chromium/TiledLayerChromium.h:
2585         (WebCore):
2586         ():
2587         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2588         (WebCore::CCLayerTreeHost::paintContentsIfDirty):
2589         (WebCore::CCLayerTreeHost::paintMaskAndReplicaForRenderSurface):
2590         (RenderSurfaceRegion):
2591         (WebCore):
2592         (WebCore::pushTargetRenderSurfaceRegion):
2593         (WebCore::popAndPushTargetRenderSurfaceRegion):
2594         (WebCore::CCLayerTreeHost::paintLayerContents):
2595         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2596         (WebCore):
2597         ():
2598         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
2599
2600 2012-01-30  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2601
2602         Add ElementAttributeData class to replace internal uses of NamedNodeMap
2603         https://bugs.webkit.org/show_bug.cgi?id=77233
2604
2605         Reviewed by Andreas Kling.
2606
2607         Move part of non-DOM functionality of NamedNodeMap into a separate class. This is
2608         the first step toward the goal of separating NamedNodeMap from internal attribute
2609         storage, as described in https://bugs.webkit.org/show_bug.cgi?id=75069.
2610
2611         The internal attribute storage is exposed as attributeData() in Element, and when
2612         necessary (because it has no back pointer to Element) via methods in Element.
2613
2614         No new tests. Except from setClass() change this is just moving the code, no new
2615         feature was added.
2616
2617         * CMakeLists.txt:
2618         * GNUmakefile.list.am:
2619         * Target.pri:
2620         * WebCore.gypi:
2621         * WebCore.xcodeproj/project.pbxproj:
2622         * dom/DOMAllInOne.cpp:
2623         * dom/Element.cpp:
2624         (WebCore::Element::idAttributeChanged):
2625         * dom/Element.h:
2626         (WebCore::Element::attributeData):
2627         (WebCore::Element::ensureAttributeData):
2628         (Element):
2629         (WebCore::Element::idForStyleResolution):
2630         * dom/ElementAttributeData.cpp: Added.
2631         (WebCore):
2632         (WebCore::ElementAttributeData::setClass): the only caller of this function
2633         already deal with the case when the element has no class, so don't do it here.
2634         * dom/ElementAttributeData.h: Added.
2635         (WebCore):
2636         (ElementAttributeData):
2637         (WebCore::ElementAttributeData::clearClass):
2638         (WebCore::ElementAttributeData::classNames):
2639         (WebCore::ElementAttributeData::idForStyleResolution):
2640         (WebCore::ElementAttributeData::setIdForStyleResolution):
2641         (WebCore::ElementAttributeData::ElementAttributeData):
2642         * dom/NamedNodeMap.cpp:
2643         (WebCore::NamedNodeMap::clearAttributes):
2644         * dom/NamedNodeMap.h:
2645         (WebCore::NamedNodeMap::attributeData):
2646         (NamedNodeMap):
2647         * dom/StyledElement.cpp:
2648         (WebCore::StyledElement::classAttributeChanged):
2649         * dom/StyledElement.h:
2650         (WebCore::StyledElement::classNames):
2651         * html/ClassList.cpp:
2652         (WebCore::ClassList::classNames):
2653
2654 2012-01-30  Gregg Tavares  <gman@chromium.org>
2655
2656         Add Plumming to get graphics error messages to JS Console
2657         https://bugs.webkit.org/show_bug.cgi?id=77238
2658
2659         Reviewed by Kenneth Russell.
2660
2661         No new tests. No change in behavior.
2662
2663         * html/canvas/WebGLRenderingContext.cpp:
2664         (WebGLRenderingContextErrorMessageCallback):
2665         (WebCore::WebGLRenderingContextErrorMessageCallback::WebGLRenderingContextErrorMessageCallback):
2666         (WebCore::WebGLRenderingContextErrorMessageCallback::onErrorMessage):
2667         (WebCore::WebGLRenderingContextErrorMessageCallback::~WebGLRenderingContextErrorMessageCallback):
2668         (WebCore):
2669         (WebCore::WebGLRenderingContext::create):
2670         (WebCore::WebGLRenderingContext::initializeNewContext):
2671         (WebCore::WebGLRenderingContext::~WebGLRenderingContext):
2672         * html/canvas/WebGLRenderingContext.h:
2673         (WebGLRenderingContext):
2674         * platform/graphics/GraphicsContext3D.h:
2675         (ErrorMessageCallback):
2676         (WebCore::GraphicsContext3D::ErrorMessageCallback::~ErrorMessageCallback):
2677         (GraphicsContext3D):
2678         * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
2679         (WebCore::GraphicsContext3D::setErrorMessageCallback):
2680         (WebCore):
2681         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
2682         (WebCore::GraphicsContext3D::setErrorMessageCallback):
2683         (WebCore):
2684         * platform/graphics/qt/GraphicsContext3DQt.cpp:
2685         (WebCore::GraphicsContext3D::setErrorMessageCallback):
2686         (WebCore):
2687
2688 2012-01-30  Anders Carlsson  <andersca@apple.com>
2689
2690         Simplify RenderLayerCompositor::frameViewDidScroll
2691         https://bugs.webkit.org/show_bug.cgi?id=77398
2692
2693         Reviewed by Sam Weinig.
2694
2695         Remove the scrollPosition parameter from RenderLayerCompositor::frameViewDidScroll; we can just get it
2696         from the associated FrameView object.
2697
2698         * page/FrameView.cpp:
2699         (WebCore::FrameView::scrollPositionChanged):
2700         * rendering/RenderLayerCompositor.cpp:
2701         (WebCore::RenderLayerCompositor::frameViewDidChangeSize):
2702         Call frameViewDidScroll() here instead of setting the scroll layer position explicitly.
2703
2704         (WebCore::RenderLayerCompositor::frameViewDidScroll):
2705         (WebCore::RenderLayerCompositor::ensureRootLayer):
2706         * rendering/RenderLayerCompositor.h:
2707         (RenderLayerCompositor):
2708
2709 2012-01-30  Pablo Flouret  <pablof@motorola.com>
2710
2711         Don't select the next selectable index when deselecting an option in select elements with size set to a value greater than one.
2712         https://bugs.webkit.org/show_bug.cgi?id=76389
2713
2714         Reviewed by Kent Tamura.
2715
2716         This behavior matches the rest of the browsers.
2717
2718         Test: fast/forms/select/option-selecting.html
2719
2720         * html/HTMLSelectElement.cpp:
2721         (WebCore::HTMLSelectElement::optionSelectionStateChanged):
2722
2723 2012-01-30  Anders Carlsson  <andersca@apple.com>
2724
2725         Scrollbars don't show when scrolling on the scrolling thread
2726         https://bugs.webkit.org/show_bug.cgi?id=77396
2727         <rdar://problem/10710736>
2728
2729         Reviewed by Sam Weinig.
2730
2731         Use ScrollAnimator::scrollToOffsetWithoutAnimation when updating the frame view scroll offset,
2732         since that function will end up invalidating the scrollbars correctly.
2733
2734         * page/ScrollingCoordinator.cpp:
2735         (WebCore::ScrollingCoordinator::didUpdateMainFrameScrollPosition):
2736
2737 2012-01-30  Anders Carlsson  <andersca@apple.com>
2738
2739         Show repaint counters in individual tiles
2740         https://bugs.webkit.org/show_bug.cgi?id=77390
2741         <rdar://problem/10767967>
2742
2743         Reviewed by Darin Adler.
2744
2745         * platform/graphics/ca/mac/TileCache.h:
2746         * platform/graphics/ca/mac/TileCache.mm:
2747         (WebCore::TileCache::setNeedsDisplayInRect):
2748         Make sure to invalidate the repaint counter rect if necessary.
2749
2750         (WebCore::TileCache::drawLayer):
2751         Draw the repaint counter.
2752
2753         (WebCore::TileCache::showRepaintCounter):
2754         New function that determines whether we should show repaint counters for the given tile cache.
2755
2756         * platform/graphics/ca/mac/WebTileLayer.h:
2757         * platform/graphics/ca/mac/WebTileLayer.mm:
2758         (-[WebTileLayer incrementRepaintCount]):
2759         Add method for getting the repaint count.
2760
2761 2012-01-30  Dan Bernstein  <mitz@apple.com>
2762
2763         <rdar://problem/10778045> REGRESSION (r91935): text-combine fails
2764         https://bugs.webkit.org/show_bug.cgi?id=77373
2765
2766         Reviewed by Darin Adler.
2767
2768         Removed tests that were failing because of this bug from the Lion skipped
2769         list.
2770
2771         * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
2772         (WebCore::GlyphPage::fill): Changed to use CTFontGetGlyphsForCharacters,
2773         rather than wkGetVerticalGlyphsForCharacters, for non-fullwidth fonts.
2774
2775 2012-01-30  Christopher Hutten-Czapski  <chutten@rim.com>
2776
2777         BlackBerry - Support Proxy-Authenticate headers when a proxy is configured
2778         https://bugs.webkit.org/show_bug.cgi?id=77361
2779
2780         Though we have a proxy configured, we might not have the auth
2781         credentials it requires. Support Proxy-Authenticate for that case.
2782
2783         Reviewed by George Staikos.
2784
2785         * platform/network/blackberry/NetworkJob.cpp:
2786         (WebCore::NetworkJob::handleNotifyHeaderReceived):
2787         (WebCore::NetworkJob::handleAuthHeader):
2788         (WebCore::NetworkJob::sendRequestWithCredentials):
2789         * platform/network/blackberry/NetworkJob.h:
2790         * platform/network/blackberry/NetworkManager.cpp:
2791         (WebCore::NetworkManager::startJob):
2792
2793 2012-01-27  James Robinson  <jamesr@chromium.org>
2794
2795         [chromium] Remove unnecessary retry logic in LayerRendererChromium initialization for accelerated painting
2796         https://bugs.webkit.org/show_bug.cgi?id=77247
2797
2798         Reviewed by Kenneth Russell.
2799
2800         The accelerate painting setting is done differently from other capability-dependent settings for no good reason,
2801         requiring that we retry initialization with different settings. For all other settings we set the capabilities
2802         bit to true if the setting is requested and if the required capabilities exist on the underlying context.
2803
2804         * platform/graphics/chromium/LayerRendererChromium.cpp:
2805         (WebCore::LayerRendererChromium::create):
2806         (WebCore::LayerRendererChromium::initialize):
2807         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
2808         (WebCore::CCLayerTreeHostImpl::initializeLayerRenderer):
2809
2810 2012-01-30  Brady Eidson  <beidson@apple.com>
2811
2812         <rdar://problem/10707072>
2813         Crashes in WebProcess at WebCore::Node::rendererIsNeeded
2814
2815         Reviewed by Darin Adler.
2816
2817         In specific circumstances a plugin element can be without a render style at the point in time where
2818         the page navigated and enters the page cache.
2819
2820         When this is the cash, the element should not enter into the "custom style for renderer" mode and should
2821         instead use the default render style machinery.
2822
2823         Test: plugins/crash-restoring-pluging-page-from-page-cache.html
2824
2825         * html/HTMLPlugInImageElement.cpp:
2826         (WebCore::HTMLPlugInImageElement::documentWillSuspendForPageCache): Only setHasCustomStyleForRenderer and 
2827           forceRecalc if there actually is a custom style to be used.
2828         (WebCore::HTMLPlugInImageElement::documentDidResumeFromPageCache): Only clearHasCustomStyleForRenderer if there
2829           actually was a custom style to be cleared.
2830         (WebCore::HTMLPlugInImageElement::customStyleForRenderer): This should only be called if there actually is a 
2831           custom style to be used. Otherwise the element would have to fallback to the "normal" RenderStyle which might
2832           not exist.
2833
2834 2012-01-30  Anders Carlsson  <andersca@apple.com>
2835
2836         Show debug borders for individual tile cache tiles
2837         https://bugs.webkit.org/show_bug.cgi?id=77388
2838
2839         Reviewed by Sam Weinig.
2840
2841         * platform/graphics/GraphicsLayer.cpp:
2842         (WebCore::GraphicsLayer::updateDebugIndicators):
2843         Give tile cache tiles a thin dark blue border.
2844
2845         * platform/graphics/ca/mac/TileCache.h:
2846         (WebCore::TileCache::tileDebugBorderWidth):
2847         (WebCore::TileCache::tileDebugBorderColor):
2848         Add getters and member variables for the tile debug border width and color.
2849
2850         * platform/graphics/ca/mac/TileCache.mm:
2851         (WebCore::TileCache::TileCache):
2852         Initialize m_tileDebugBorderWidth.
2853
2854         (WebCore::TileCache::setTileDebugBorderWidth):
2855         Update the border width of each tile layer.
2856
2857         (WebCore::TileCache::setTileDebugBorderColor):
2858         Update the border color of each tile layer.
2859
2860         (WebCore::TileCache::createTileLayer):
2861         Set the border color and border width.
2862
2863         * platform/graphics/ca/mac/WebTileCacheLayer.h:
2864         * platform/graphics/ca/mac/WebTileCacheLayer.mm:
2865         (-[WebTileCacheLayer borderColor]):
2866         (-[WebTileCacheLayer setBorderColor:]):
2867         (-[WebTileCacheLayer borderWidth]):
2868         (-[WebTileCacheLayer setBorderWidth:]):
2869         Call through to the TileCache.
2870
2871         * platform/graphics/mac/WebLayer.mm:
2872         (drawLayerContents):
2873         Don't draw the repaint counter for tile cache layers, each tile will maintain its own repaint counter.
2874
2875 2012-01-30  Rakesh KN  <rakesh.kn@motorola.com>
2876
2877         single-file input elements should refuse multi-file drags
2878         https://bugs.webkit.org/show_bug.cgi?id=25913
2879
2880         Reviewed by Eric Seidel.
2881
2882         Refuse the multiple file drags onto a single file input element.
2883
2884         No new tests: Covered by existing tests, updated the expected results.
2885
2886         * page/DragController.cpp:
2887         (WebCore::DragController::tryDocumentDrag):
2888         Setting the dragSession.numberOfItemsToBeAccepted to 0 so that drag operation is none if the
2889         file input element under mouse is single input type and number of files dragged onto that
2890         input element are more than 1.
2891
2892 2012-01-30  Dana Jansens  <danakj@chromium.org>
2893
2894         [chromium] Use region reported painted opaque for draw culling
2895         https://bugs.webkit.org/show_bug.cgi?id=76015
2896
2897         Reviewed by James Robinson.
2898
2899         New unit tests in CCTiledLayerImplTest.cpp, CCQuadCullerTest.cpp, CCLayerTreeHostImplTest.cpp
2900
2901         * platform/graphics/chromium/LayerChromium.cpp:
2902         (WebCore::LayerChromium::setOpaque):
2903         * platform/graphics/chromium/TiledLayerChromium.cpp:
2904         (UpdatableTile):
2905         (WebCore::TiledLayerChromium::pushPropertiesTo):
2906         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
2907         * platform/graphics/chromium/cc/CCDrawQuad.cpp:
2908         (WebCore::CCDrawQuad::opaqueRect):
2909         (WebCore):
2910         * platform/graphics/chromium/cc/CCDrawQuad.h:
2911         (CCDrawQuad):
2912         (WebCore::CCDrawQuad::needsBlending):
2913         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
2914         (WebCore::CCQuadCuller::cullOccludedQuads):
2915         * platform/graphics/chromium/cc/CCSolidColorDrawQuad.cpp:
2916         (WebCore::CCSolidColorDrawQuad::CCSolidColorDrawQuad):
2917         * platform/graphics/chromium/cc/CCTileDrawQuad.cpp:
2918         (WebCore::CCTileDrawQuad::create):
2919         (WebCore::CCTileDrawQuad::CCTileDrawQuad):
2920         * platform/graphics/chromium/cc/CCTileDrawQuad.h:
2921         (CCTileDrawQuad):
2922         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
2923         (DrawableTile):
2924         (WebCore::DrawableTile::opaqueRect):
2925         (WebCore::DrawableTile::setOpaqueRect):
2926         (WebCore::CCTiledLayerImpl::appendQuads):
2927         (WebCore::CCTiledLayerImpl::pushTileProperties):
2928         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
2929         (CCTiledLayerImpl):
2930
2931 2012-01-30  Ryosuke Niwa  <rniwa@webkit.org>
2932
2933         Crash in previousLinePosition when moving into a root inline box without leaves
2934         https://bugs.webkit.org/show_bug.cgi?id=76812
2935
2936         Reviewed by Enrica Casucci.
2937
2938         The crash was caused by us assuming that every root inline box has at least one leaf,
2939         which isn't true when we create inline boxes for an empty text run with margin, border, etc...
2940
2941         Test: editing/selection/move-into-empty-root-inline-box.html
2942
2943         * editing/visible_units.cpp:
2944         (WebCore::previousLinePosition):
2945         (WebCore::nextLinePosition):
2946
2947 2012-01-30  Levi Weintraub  <leviw@chromium.org>
2948
2949         !m_insideRegionPaint assertion in RenderRegion.cpp is invalid
2950         https://bugs.webkit.org/show_bug.cgi?id=77372
2951
2952         Reviewed by David Hyatt.
2953
2954         Removing the !m_insideRegionPaint assertion that's in three functions in
2955         RenderRegion. It's triggering in numerous layout tests and isn't valid.
2956
2957         No new tests as this just removes assertions.
2958
2959         * rendering/RenderRegion.cpp:
2960         (WebCore::RenderRegion::setRenderBoxRegionInfo):
2961         (WebCore::RenderRegion::takeRenderBoxRegionInfo):
2962         (WebCore::RenderRegion::removeRenderBoxRegionInfo):
2963
2964 2012-01-30  Adrienne Walker  <enne@google.com>
2965
2966         [chromium] Always pre-reserve scrollbar and scroll corner textures
2967         https://bugs.webkit.org/show_bug.cgi?id=77251
2968
2969         Reviewed by James Robinson.
2970
2971         Add a flag to LayerChromium that says that a layer's textures should
2972         always be reserved. Prior to painting layers, find all layers marked
2973         as such and reserve their textures. This will prevent texture memory
2974         limits from being hit before the root layer's scrollbars are reserved
2975         and painted.
2976
2977         * platform/graphics/chromium/LayerChromium.cpp:
2978         (WebCore::LayerChromium::LayerChromium):
2979         * platform/graphics/chromium/LayerChromium.h:
2980         (LayerChromium):
2981         (WebCore::LayerChromium::reserveTextures):
2982         (WebCore::LayerChromium::setAlwaysReserveTextures):
2983         (WebCore::LayerChromium::alwaysReserveTextures):
2984         * platform/graphics/chromium/TiledLayerChromium.cpp:
2985         (WebCore::TiledLayerChromium::reserveTextures):
2986         * platform/graphics/chromium/TiledLayerChromium.h:
2987         ():
2988         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2989         (WebCore::CCLayerTreeHost::updateLayers):
2990         (WebCore::CCLayerTreeHost::reserveTextures):
2991         (WebCore):
2992         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2993         ():
2994
2995 2012-01-30  Beth Dakin  <bdakin@apple.com>
2996
2997         Speculative 32-bit build-fix.
2998
2999         * WebCore.exp.in:
3000
3001 2012-01-30  Mihnea Ovidenie  <mihnea@adobe.com>
3002
3003         [CSSRegions]Add support for background-color in region styling
3004         https://bugs.webkit.org/show_bug.cgi?id=71488
3005
3006         Reviewed by David Hyatt.
3007
3008         Based on work by Alexandru Chiculita (achicu@adobe.com).
3009         Previous patches for region styling were touching RenderObject::style() method. After several attempts to avoid regressions
3010         (including caching of RenderObject::style() pointer in most used methods), we decided to attempt a different approach:
3011         Step1: before each region is repainted, we compute the style for each box that falls into the region
3012         Step2: before paint, we store the box original style
3013         Step3: paint the region contents using the style in region
3014         Step4: after paint is finished, we restore the box original style (and store the box style in region for future region paint)
3015
3016         Tests for region styling are also enabled with this patch.
3017
3018         * WebCore.exp.in:
3019         * rendering/RenderFlowThread.cpp:
3020         (WebCore::RenderFlowThread::clearRenderBoxCustomStyle):
3021         (WebCore::RenderFlowThread::setRegionRangeForBox):
3022         * rendering/RenderFlowThread.h:
3023         ():
3024         * rendering/RenderLayer.cpp:
3025         (WebCore::RenderLayer::paint):
3026         (WebCore::RenderLayer::hitTest):
3027         * rendering/RenderObject.cpp:
3028         * rendering/RenderObject.h:
3029         (WebCore::RenderObject::style):
3030         (RenderObject):
3031         * rendering/RenderObjectChildList.cpp:
3032         (WebCore::RenderObjectChildList::removeChildNode):
3033         * rendering/RenderRegion.cpp:
3034         (WebCore::RenderRegion::RenderRegion):
3035         (WebCore::RenderRegion::setRegionBoxesRegionStyle):
3036         (WebCore):
3037         (WebCore::RenderRegion::restoreRegionBoxesOriginalStyle):
3038         (WebCore::RenderRegion::paintReplaced):
3039         (WebCore::RenderRegion::setRenderBoxRegionInfo):
3040         (WebCore::RenderRegion::takeRenderBoxRegionInfo):
3041         (WebCore::RenderRegion::removeRenderBoxRegionInfo):
3042         (WebCore::RenderRegion::renderBoxRegionStyle):
3043         (WebCore::RenderRegion::computeStyleInRegion):
3044         (WebCore::RenderRegion::clearBoxStyleInRegion):
3045         * rendering/RenderRegion.h:
3046         (RenderRegion):
3047         * rendering/RenderView.cpp:
3048         (WebCore::RenderView::RenderView):
3049         * rendering/RenderView.h:
3050         (WebCore):
3051         (RenderView):
3052
3053 2012-01-30  Jessie Berlin  <jberlin@apple.com>
3054
3055         WebCore build exceeds address space on 32-bit Windows builders (again).
3056         https://bugs.webkit.org/show_bug.cgi?id=77357
3057
3058         Reviewed by Adam Roben.
3059
3060         Add an Inspector All-In-One file, but only use it in Release and Production builds.
3061         This differs from our other All-In-One files, but it is a better approach because it makes
3062         debugging possible in the Debug configuration (the symbols will be in the correct .obj file
3063         for the original .cpp files).
3064
3065         * WebCore.vcproj/WebCore.vcproj:
3066         Also, let VS have its way with the vcproj file.
3067         * inspector/InspectorAllInOne.cpp: Added.
3068
3069 2012-01-28  Matthew Delaney  <mdelaney@apple.com>
3070
3071         Limit periodic flushing inside ImageBufferCG to just Lion
3072         https://bugs.webkit.org/show_bug.cgi?id=77353
3073         <rdar://problem/10328309>
3074
3075         Reviewed by Chris Marrin.
3076
3077         * platform/graphics/cg/ImageBufferCG.cpp:
3078         * platform/graphics/cg/ImageBufferDataCG.h:
3079
3080 2012-01-30  Tommy Widenflycht  <tommyw@google.com>
3081
3082         Memory leak caused by PeerConnection add a NULL media stream
3083         https://bugs.webkit.org/show_bug.cgi?id=76150
3084
3085         It was my missunderstanding that the IDL keyword [StrictTypeChecking] also protects against
3086         null or undefined arguments, it doesn't. Added checks for null pointers.
3087
3088         Reviewed by Adam Barth.
3089
3090         Test: fast/mediastream/peerconnection-addstream.html
3091
3092         * mediastream/PeerConnection.cpp:
3093         (WebCore::PeerConnection::addStream):
3094         (WebCore::PeerConnection::removeStream):
3095
3096 2012-01-26  Andy Estes  <aestes@apple.com>
3097
3098         [Windows] Optionally invert colors when drawing to a WebView's backing store.
3099         https://bugs.webkit.org/show_bug.cgi?id=77168
3100
3101         Reviewed by Sam Weinig.
3102
3103         * css/CSSPrimitiveValueMappings.h: Assert that CompositeDifference is
3104         not converted to a CSS value. Exposing a new compositing operation to
3105         CSS is outside the scope of this patch.
3106         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3107         * platform/graphics/GraphicsTypes.h: Add CompositeDifference as a
3108         CompositeOperator. Also, remove an outdated comment.
3109         * platform/graphics/cg/GraphicsContextCG.cpp:
3110         (WebCore::GraphicsContext::setPlatformCompositeOperation): Map
3111         CompositeDifference to kCGBlendModeDifference.
3112
3113 2012-01-28  Matthew Delaney  <mdelaney@apple.com>
3114
3115         Limit the shadow offset CG hack to just SL and Lion
3116         https://bugs.webkit.org/show_bug.cgi?id=77348
3117         <rdar://problem/10158016>
3118
3119         Reviewed by Chris Marrin.
3120
3121         No new tests, current tests cover this.
3122
3123         * platform/graphics/cg/GraphicsContextCG.cpp:
3124         (WebCore::GraphicsContext::setPlatformShadow):
3125
3126 2012-01-30  Beth Dakin  <bdakin@apple.com>
3127
3128         https://bugs.webkit.org/show_bug.cgi?id=77263
3129         PlatformScreenMac should not rely on NSWindow for important bits of data
3130
3131         Reviewed by Geoff Garen.
3132
3133         The main problem is that we cannot rely on the NSWindow for information about 
3134         the deviceScaleFactor because we cannot access an NSWindow from within 
3135         WebCore for WebKit2 windows. Instead, we can fetch it from 
3136         WebCore::deviceScaleFactor(), but we need a Frame to call that. So 
3137         screenAvailableRect and screenRect both now take a FrameView* instead of a 
3138         Widget*. All existing call sites actually sent a FrameView in anyway, so this 
3139         is not a big change, but it does require touching a lot of platforms.
3140         * WebCore.exp.in:
3141         * platform/PlatformScreen.h:
3142         (WebCore):
3143         * platform/blackberry/PlatformScreenBlackBerry.cpp:
3144         (WebCore::screenAvailableRect):
3145         (WebCore::screenRect):
3146         * platform/chromium/PlatformScreenChromium.cpp:
3147         (WebCore::screenRect):
3148         (WebCore::screenAvailableRect):
3149         * platform/chromium/PlatformSupport.h:
3150         (WebCore):
3151         (PlatformSupport):
3152         ():
3153         * platform/efl/PlatformScreenEfl.cpp:
3154         (WebCore::screenRect):
3155         (WebCore::screenAvailableRect):
3156         * platform/gtk/PlatformScreenGtk.cpp:
3157         (WebCore::screenRect):
3158         (WebCore::screenAvailableRect):
3159         * platform/qt/PlatformScreenQt.cpp:
3160         (WebCore::screenRect):
3161         (WebCore::screenAvailableRect):
3162         * platform/win/PlatformScreenWin.cpp:
3163         (WebCore::screenRect):
3164         (WebCore::screenAvailableRect):
3165         * platform/wx/ScreenWx.cpp:
3166         (WebCore::screenRect):
3167         (WebCore::screenAvailableRect):
3168
3169         The Mac-only functions toUserSpace() and toDeviceSpace() were also updated to 
3170         take a parameter for the deviceScaleFactor.
3171         * platform/mac/PlatformScreenMac.mm:
3172         (WebCore::screenRect):
3173         (WebCore::screenAvailableRect):
3174         (WebCore::toUserSpace):
3175         (WebCore::toDeviceSpace):
3176
3177 2012-01-30  Antti Koivisto  <antti@apple.com>
3178
3179         Kill CSSMutableStyleDeclarationConstIterator
3180         https://bugs.webkit.org/show_bug.cgi?id=77342
3181
3182         Reviewed by Sam Weinig.
3183
3184         CSSMutableStyleDeclaration is an array and should be iterated using an index. This simplifies the code.
3185
3186         * css/CSSMutableStyleDeclaration.cpp:
3187         (WebCore::CSSMutableStyleDeclaration::copyPropertiesFrom):
3188         (WebCore::CSSMutableStyleDeclaration::removeProperty):
3189         (WebCore::CSSMutableStyleDeclaration::setProperty):
3190         (WebCore::CSSMutableStyleDeclaration::setPropertyInternal):
3191         (WebCore::CSSMutableStyleDeclaration::parseDeclaration):
3192         (WebCore::CSSMutableStyleDeclaration::addParsedProperties):
3193         (WebCore::CSSMutableStyleDeclaration::addParsedProperty):
3194         (WebCore::CSSMutableStyleDeclaration::merge):
3195         (WebCore::CSSMutableStyleDeclaration::removePropertiesInSet):
3196         * css/CSSMutableStyleDeclaration.h:
3197         (WebCore):
3198         (WebCore::CSSMutableStyleDeclaration::createForSVGFontFaceElement):
3199         (CSSMutableStyleDeclaration):
3200         * css/CSSStyleDeclaration.cpp:
3201         (WebCore::CSSStyleDeclaration::CSSStyleDeclaration):
3202         * css/CSSStyleDeclaration.h:
3203         (CSSStyleDeclaration):
3204         ():
3205         * css/CSSStyleSelector.cpp:
3206         (WebCore::CSSStyleSelector::styleForKeyframe):
3207         (WebCore::CSSStyleSelector::applyDeclaration):
3208         * editing/EditingStyle.cpp:
3209
3210 2012-01-30  Michael Saboff  <msaboff@apple.com>
3211
3212         Dromaeo tests call parseSimpleLengthValue() on 8 bit strings
3213         https://bugs.webkit.org/show_bug.cgi?id=76649
3214
3215         Reviewed by Geoffrey Garen.
3216
3217         No functionality change, therefore no new tests.
3218
3219         Added 8 bit patch for parseSimpleLengthValue().
3220
3221         * css/CSSParser.cpp:
3222         (WebCore::parseSimpleLengthValue):
3223
3224 2012-01-30  Michael Saboff  <msaboff@apple.com>
3225
3226         WebCore decodeEscapeSequences unnecessarily converts 8 bit strings to 16 bit when decoding.
3227         https://bugs.webkit.org/show_bug.cgi?id=76648
3228
3229         Reviewed by Geoffrey Garen.
3230
3231         Using new overloaded append(String&, offset, length)  member to build result string.
3232         The new member properly handles 8/16 bit-ness of strings.
3233
3234         Functionality not changed, therefore no new tests.
3235
3236         * platform/text/DecodeEscapeSequences.h:
3237         (WebCore::decodeEscapeSequences):
3238
3239 2012-01-30  Pavel Feldman  <pfeldman@google.com>
3240
3241         Not reviewed: follow up to r105625, use proper event categoty in inspector frontend.
3242
3243         * inspector/front-end/BreakpointsSidebarPane.js:
3244         (WebInspector.EventListenerBreakpointsSidebarPane):
3245
3246 2012-01-30  Parag Radke  <nrqv63@motorola.com>
3247
3248         REGRESSION (r82580): Reproducible crash in CSSPrimitiveValue::computeLengthDouble
3249         https://bugs.webkit.org/show_bug.cgi?id=61989
3250
3251         Reviewed by Simon Fraser.
3252
3253         According to css3 specs when font-size is specified in 'rems' for an element implies the font-size
3254         of the root element. In this case as HTML element has a property 'display:none' and hence renderer 
3255         is NULL causes this crash.
3256
3257         Test: fast/css/fontsize-unit-rems-crash.html
3258
3259         * css/CSSPrimitiveValue.cpp:
3260         (WebCore::CSSPrimitiveValue::computeLengthDouble):
3261         Added a null check for the root element's RenderStyle as it can be null in case of html has a property
3262         hidden or display:none.
3263
3264 2012-01-26  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3265
3266         [Qt] WKTR: Use a software rendering pipiline when running tests.
3267         https://bugs.webkit.org/show_bug.cgi?id=76708
3268
3269         Reviewed by Kenneth Rohde Christiansen.
3270
3271         * platform/graphics/qt/TextureMapperQt.cpp: Allow setting the context to null.
3272         (WebCore::TextureMapperQt::setGraphicsContext):
3273         * platform/graphics/qt/TextureMapperQt.h:
3274         (WebCore::TextureMapperQt::initialize):
3275
3276 2012-01-27  Enrica Casucci  <enrica@apple.com>
3277
3278         Remove all references to NSPasteboard objects from the Pasteboard
3279         class interface on Mac.
3280         https://bugs.webkit.org/show_bug.cgi?id=77261
3281         
3282         This is cleanup work needed as first step in the direction of
3283         removing access to NSPasteboard from the WebProcess.
3284         This way all access to the NSPasteboard object are internal to
3285         the class.
3286         Removed static methods taking NSPasteboard as paramenter and changed
3287         the constructor of the class to take the pasteboard name instead of
3288         the NSPasteboard object.
3289
3290         Reviewed by Alexey Proskuryakov.
3291
3292         No new tests. There is no change in behavior.
3293
3294         * editing/Editor.cpp: Removed ununsed private method writeSelectionToPasteboard.
3295         (WebCore):
3296         * editing/Editor.h: Ditto.
3297         (Editor):
3298         ():
3299         * editing/mac/EditorMac.mm:
3300         (WebCore::Editor::writeSelectionToPasteboard):
3301         (WebCore::Editor::readSelectionFromPasteboard):
3302         * platform/Pasteboard.h:
3303         (Pasteboard):
3304         * platform/mac/ClipboardMac.mm:
3305         (WebCore::ClipboardMac::writeRange):
3306         (WebCore::ClipboardMac::writePlainText):
3307         (WebCore::ClipboardMac::writeURL):
3308         * platform/mac/DragDataMac.mm:
3309         (WebCore::DragData::asPlainText):
3310         (WebCore::DragData::asURL):
3311         (WebCore::DragData::asFragment):
3312         * platform/mac/PasteboardMac.mm:
3313         (WebCore::Pasteboard::generalPasteboard):
3314         (WebCore::Pasteboard::Pasteboard):
3315         (WebCore::Pasteboard::writeSelectionForTypes): Added.
3316         (WebCore::Pasteboard::writePlainText):
3317         (WebCore::Pasteboard::writeSelection):
3318         (WebCore::Pasteboard::writeURLForTypes): Added.
3319         (WebCore::Pasteboard::writeURL):
3320         (WebCore::Pasteboard::writeImage):
3321
3322 2012-01-29  Antti Koivisto  <antti@apple.com>
3323
3324         Reduce non-CSSOM API of CSSStyleDeclaration
3325         https://bugs.webkit.org/show_bug.cgi?id=77299
3326
3327         Reviewed by Andreas Kling.
3328
3329         CSSStyleDeclaration should expose the CSSOM API only. Subclasses should expose the internal API only. 
3330         This will move us closer to being able to split the CSSOM API from the internal implementation.
3331         
3332         - Make CSSStyleDeclaration CSSOM functions virtual, internal functions non-virtual.
3333         - Move implementations to subclasses (CSSComputedStyleDeclaration, CSSMutableStyleDeclaration).
3334         - Make CSSOM functions in the subclasses private (making it harder to invoke them internally).
3335         - Switch a bunch of places to use internal API instead of CSSOM.
3336
3337         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
3338         (WebCore::V8CSSStyleDeclaration::namedPropertyGetter):
3339         (WebCore::V8CSSStyleDeclaration::namedPropertySetter):
3340         
3341             Switch to *Internal versions of the CSSOM functions.
3342         
3343         * css/CSSComputedStyleDeclaration.cpp:
3344         (WebCore):
3345         (WebCore::CSSComputedStyleDeclaration::length):
3346         (WebCore::CSSComputedStyleDeclaration::cssPropertyMatches):
3347         (WebCore::CSSComputedStyleDeclaration::copyPropertiesInSet):
3348         
3349             Move copyPropertiesInSet to subclasses, devirtualize.
3350             
3351         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3352         (WebCore::CSSComputedStyleDeclaration::getPropertyValue):
3353         (WebCore::CSSComputedStyleDeclaration::getPropertyPriority):
3354         (WebCore::CSSComputedStyleDeclaration::getPropertyShorthand):
3355         (WebCore::CSSComputedStyleDeclaration::isPropertyImplicit):
3356         (WebCore::CSSComputedStyleDeclaration::setProperty):
3357         (WebCore::CSSComputedStyleDeclaration::removeProperty):
3358         * css/CSSComputedStyleDeclaration.h:
3359         (CSSComputedStyleDeclaration):
3360         * css/CSSFontFaceRule.cpp:
3361         (WebCore::CSSFontFaceRule::cssText):
3362         * css/CSSMutableStyleDeclaration.cpp:
3363         (WebCore::CSSMutableStyleDeclaration::length):
3364         (WebCore::CSSMutableStyleDeclaration::asText):
3365         (WebCore::CSSMutableStyleDeclaration::cssText):
3366         (WebCore):
3367         (WebCore::CSSMutableStyleDeclaration::getPropertyCSSValue):
3368         (WebCore::CSSMutableStyleDeclaration::getPropertyValue):
3369         (WebCore::CSSMutableStyleDeclaration::getPropertyPriority):
3370         (WebCore::CSSMutableStyleDeclaration::getPropertyShorthand):
3371         (WebCore::CSSMutableStyleDeclaration::isPropertyImplicit):
3372         (WebCore::CSSMutableStyleDeclaration::setProperty):
3373         (WebCore::CSSMutableStyleDeclaration::removeProperty):
3374         (WebCore::CSSMutableStyleDeclaration::copyPropertiesInSet):
3375         
3376             Move copyPropertiesInSet to subclasses, devirtualize.
3377         
3378         (WebCore::CSSMutableStyleDeclaration::cssPropertyMatches):
3379         (WebCore::CSSMutableStyleDeclaration::removeEquivalentProperties):
3380         
3381             Move diff() to CSSMutableStyleDeclaration, rename to removeEquivalentProperties, switch to mutate
3382             this object instead of the argument object.
3383     
3384         * css/CSSMutableStyleDeclaration.h:
3385         (CSSMutableStyleDeclaration):
3386         (WebCore::CSSMutableStyleDeclaration::propertyCount):
3387         (WebCore::CSSMutableStyleDeclaration::isEmpty):
3388         (WebCore::CSSMutableStyleDeclaration::propertyAt):
3389         
3390             Expose properties and property count internally (iterator should be removed in favor of these).
3391         
3392         * css/CSSStyleDeclaration.cpp:
3393         (WebCore):
3394         * css/CSSStyleDeclaration.h:
3395         (CSSStyleDeclaration):
3396         (WebCore::CSSStyleDeclaration::getPropertyCSSValueInternal):
3397         (WebCore::CSSStyleDeclaration::getPropertyValueInternal):
3398         (WebCore::CSSStyleDeclaration::setPropertyInternal):
3399         
3400             Add *Internal versions of some CSSOM APIs to support some editing and bindings uses.
3401             These take propertyIDs instead of strings names.
3402
3403         * css/CSSStyleRule.cpp:
3404         (WebCore::CSSStyleRule::cssText):
3405         * css/CSSStyleSelector.cpp:
3406         (WebCore::leftToRightDeclaration):
3407         (WebCore::rightToLeftDeclaration):
3408         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
3409         (WebCore::CSSStyleSelector::matchPageRulesForList):
3410         * css/WebKitCSSKeyframeRule.cpp:
3411         (WebCore::WebKitCSSKeyframeRule::cssText):
3412         * dom/StyledElement.cpp:
3413         (WebCore::StyledElement::updateStyleAttribute):
3414         * editing/ApplyStyleCommand.cpp:
3415         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
3416         (WebCore::ApplyStyleCommand::removeEmbeddingUpToEnclosingBlock):
3417         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
3418         (WebCore::ApplyStyleCommand::applyInlineStyleToPushDown):
3419         (WebCore::ApplyStyleCommand::addBlockStyle):
3420         (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded):
3421         * editing/EditingStyle.cpp:
3422         ():
3423         (WebCore::copyEditingProperties):
3424         (WebCore):
3425         (WebCore::propertyCSSValue):
3426         (WebCore::getRGBAFontColor):
3427         (WebCore::EditingStyle::overrideWithStyle):
3428         (WebCore::EditingStyle::removeStyleAddedByNode):
3429         (WebCore::EditingStyle::removeStyleConflictingWithStyleOfNode):
3430         (WebCore::EditingStyle::triStateOfStyle):
3431         (WebCore::EditingStyle::styleIsPresentInComputedStyleOfNode):
3432         (WebCore::EditingStyle::prepareToApplyAt):
3433         (WebCore::removePropertiesInStyle):
3434         (WebCore::EditingStyle::removeStyleFromRulesAndContext):
3435         (WebCore::EditingStyle::removePropertiesInElementDefaultStyle):
3436         (WebCore::StyleChange::StyleChange):
3437         (WebCore::fontWeightIsBold):
3438         (WebCore::getPropertiesNotIn):
3439         (WebCore::getIdentifierValue):
3440         (WebCore::hasTransparentBackgroundColor):
3441         * editing/EditingStyle.h:
3442         
3443             Adapt to changes.
3444     
3445         (WebCore):
3446         * editing/ReplaceSelectionCommand.cpp:
3447         (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline):
3448         (WebCore::handleStyleSpansBeforeInsertion):
3449         (WebCore::ReplaceSelectionCommand::handleStyleSpans):
3450         * editing/mac/EditorMac.mm:
3451         (WebCore::styleForSelectionStart):
3452         * editing/markup.cpp:
3453         (WebCore::StyledMarkupAccumulator::appendStyleNodeOpenTag):
3454         (WebCore::StyledMarkupAccumulator::appendElement):
3455         * html/ImageDocument.cpp:
3456         (WebCore::ImageDocument::resizeImageToFit):
3457         (WebCore::ImageDocument::restoreImageSize):
3458         (WebCore::ImageDocument::windowSizeChanged):
3459         * html/canvas/CanvasRenderingContext2D.cpp:
3460         (WebCore::CanvasRenderingContext2D::setFont):
3461         * html/canvas/CanvasStyle.cpp:
3462         (WebCore::currentColor):
3463         * inspector/InspectorStyleSheet.cpp:
3464         (WebCore::InspectorStyleSheet::revalidateStyle):
3465         * page/PageSerializer.cpp:
3466         (WebCore::PageSerializer::retrieveResourcesForCSSDeclaration):
3467         * rendering/RenderTreeAsText.cpp:
3468         (WebCore::isEmptyOrUnstyledAppleStyleSpan):
3469         * svg/SVGStyledElement.cpp:
3470         (WebCore::SVGStyledElement::getPresentationAttribute):
3471
3472 2012-01-30  Pavel Feldman  <pfeldman@google.com>
3473
3474         Web Inspector: protocol validator should fail if one of response fields turns optional
3475         https://bugs.webkit.org/show_bug.cgi?id=76452
3476
3477         Reviewed by Yury Semikhatsky.
3478
3479         * inspector/Inspector-0.1.json:
3480         * inspector/Inspector.json:
3481         * inspector/generate-inspector-protocol-version:
3482         (compare_commands):
3483         (compare_events):
3484         (compare_params_list):
3485         (compare_types):
3486         (self_test):
3487
3488 2012-01-30  Yury Semikhatsky  <yurys@chromium.org>
3489
3490         Web Inspector: keyboard navigation through comparison view in heap profiler should update retainers view
3491         https://bugs.webkit.org/show_bug.cgi?id=77326
3492
3493         Keyboard navigation in the detailed heap snapshot view now updates retainers view.
3494
3495         Reviewed by Pavel Feldman.
3496
3497         * inspector/front-end/DataGrid.js: Added SelectedNode/DeselectedNode events to DataGrid.