ddc9379b8c6ebe94a54ce7bad7647bb4dee9d7aa
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-12-07  Sujin Park  <sujjin.park@gmail.com>
2
3         [EFL] Fix build warning in StyleResolver.cpp using gcc 4.7.2
4         https://bugs.webkit.org/show_bug.cgi?id=104262
5
6         Reviewed by Alexis Menard.
7
8         EFL port treats build warning as compile error and there are
9         maybe-uninitialized when building with gcc 4.7.2.
10         This patch adds default case to resolve a build break.
11
12         * css/StyleResolver.cpp:
13         (WebCore::getFontAndGlyphOrientation):
14
15 2012-12-06  Alexander Pavlov  <apavlov@chromium.org>
16
17         Web Inspector: [Chromium] Ctrl + ']' "Goto right panel" keyboard shortcut doesn't work
18         https://bugs.webkit.org/show_bug.cgi?id=104250
19
20         Reviewed by Pavel Feldman.
21
22         Ignore "keypress" event resulting from a WM_CHAR message emitted by Win7 upon Ctrl + ']' keypress.
23
24         * inspector/front-end/InspectorView.js:
25         (WebInspector.InspectorView.prototype._keyPress): Ignore all events with charCode < 32.
26
27 2012-10-03  Pavel Feldman  <pfeldman@chromium.org>
28
29         Web Inspector: provide a way to reload page with given script preprocessor.
30         https://bugs.webkit.org/show_bug.cgi?id=80992
31
32         Reviewed by Yury Semikhatsky.
33
34         This change introduces a way to inject 'preprocessor' script that would process
35         each JavaScript file before it gets into the VM for compilation. That way inspector
36         can expose capabilities such as assessing code coverage or tracing all the calls.
37
38         Preprocessor script is stored in the page agent where it waits for reload to happen.
39         Upon reload, ScriptDebugServer is using it to patch the script sources.
40
41         
42         Test: inspector/debugger/debugger-script-preprocessor.html
43
44         * bindings/js/ScriptDebugServer.h:
45         (WebCore::ScriptDebugServer::setScriptPreprocessor):
46         (ScriptDebugServer):
47         * bindings/v8/DebuggerScript.js:
48         * bindings/v8/ScriptDebugServer.cpp:
49         (ScriptDebugServer::ScriptPreprocessor):
50         (WebCore::ScriptDebugServer::ScriptPreprocessor::ScriptPreprocessor):
51         (WebCore::ScriptDebugServer::ScriptPreprocessor::preprocessSourceCode):
52         (WebCore::ScriptDebugServer::ScriptPreprocessor::~ScriptPreprocessor):
53         (WebCore):
54         (WebCore::ScriptDebugServer::~ScriptDebugServer):
55         (WebCore::ScriptDebugServer::setScriptSource):
56         (WebCore::ScriptDebugServer::setScriptPreprocessor):
57         (WebCore::ScriptDebugServer::handleV8DebugEvent):
58         * bindings/v8/ScriptDebugServer.h:
59         (ScriptDebugServer):
60         * bindings/v8/custom/V8InjectedScriptManager.cpp:
61         (WebCore::InjectedScriptManager::createInjectedScript):
62         * inspector/Inspector.json:
63         * inspector/InspectorController.cpp:
64         (WebCore::InspectorController::InspectorController):
65         * inspector/InspectorDebuggerAgent.h:
66         (InspectorDebuggerAgent):
67         * inspector/InspectorPageAgent.cpp:
68         (WebCore::InspectorPageAgent::reload):
69         (WebCore::InspectorPageAgent::frameNavigated):
70         * inspector/InspectorPageAgent.h:
71         (WebCore::InspectorPageAgent::page):
72         (WebCore::InspectorPageAgent::scriptPreprocessor):
73         (InspectorPageAgent):
74         * inspector/PageDebuggerAgent.cpp:
75         (WebCore::PageDebuggerAgent::create):
76         (WebCore::PageDebuggerAgent::PageDebuggerAgent):
77         (WebCore::PageDebuggerAgent::startListeningScriptDebugServer):
78         (WebCore::PageDebuggerAgent::stopListeningScriptDebugServer):
79         (WebCore::PageDebuggerAgent::injectedScriptForEval):
80         (WebCore::PageDebuggerAgent::didClearMainFrameWindowObject):
81         (WebCore):
82         * inspector/PageDebuggerAgent.h:
83         (WebCore):
84         (PageDebuggerAgent):
85
86 2012-12-07  Alexander Pavlov  <apavlov@chromium.org>
87
88         Web Inspector: the "Sources" column is always empty in CSS selector profiles
89         https://bugs.webkit.org/show_bug.cgi?id=104225
90
91         Reviewed by Pavel Feldman.
92
93         r112923 and preceding changesets modified the CSSOM wrapper creation for StyleRules in a way
94         that would not specify the parent CSSStyleSheet for the CSSStyleRules created. Instead,
95         styleResolver->ensureFullCSSOMWrapperForInspector(rule) is now used to make sure the CSSStyleRule
96         has a valid parent CSSStyleSheet.
97
98         Test: inspector/profiler/selector-profiler-url.html
99
100         * css/StyleResolver.cpp:
101         (WebCore::StyleResolver::collectMatchingRulesForList):
102         (WebCore::StyleResolver::applyProperties):
103         * inspector/InspectorInstrumentation.cpp:
104         (WebCore):
105         (WebCore::InspectorInstrumentation::willMatchRuleImpl):
106         (WebCore::InspectorInstrumentation::willProcessRuleImpl):
107         * inspector/InspectorInstrumentation.h:
108         (WebCore):
109         (InspectorInstrumentation):
110         (WebCore::InspectorInstrumentation::willMatchRule):
111         (WebCore::InspectorInstrumentation::willProcessRule):
112
113 2012-12-05  Antonio Gomes  <a1.gomes@sisa.samsung.com>
114
115         Rework bug 97927 to not depend on RenderLayer::allowsScrolling
116         https://bugs.webkit.org/show_bug.cgi?id=103999
117
118         Reviewed by James Robinson.
119
120         Patch makes it possible for methods like
121         RenderLayer::{updateScrollbarsAfterLayout,updateScrollbarsAfterStyleChange}
122         to not depend on RenderLayer::allowsScrolling to determine if a layer should
123         be added or removed from its FrameView's ScrollableArea set.
124
125         Following the same logic, the patch also fixes RenderBox::canBeScrolledAndHasScrollableArea
126         method to take into account the box' scroll allowance in a given direction only
127         when it overflows. This allows simplifying custom methods like InRegionScrollerPrivate::canScrollRenderBox
128         (@WebKit/blackberry/Api/InRegionScroller.cpp).
129
130         The naming pattern for the newly added methods were chosen to keep the consistency
131         with the existing ones, in the same class.
132
133         No new test: it is already covered by ScrollingCoordinatorChromiumTest.clippedBodyTest.
134
135         * rendering/RenderBox.cpp:
136         (WebCore::RenderBox::canBeScrolledAndHasScrollableArea):
137         * rendering/RenderBox.h:
138         (RenderBox):
139         (WebCore::RenderBox::hasScrollableOverflowX):
140         (WebCore::RenderBox::hasScrollableOverflowY):
141         * rendering/RenderLayer.cpp:
142         (WebCore::RenderLayer::hasScrollableHorizontalOverflow):
143         (WebCore):
144         (WebCore::RenderLayer::hasScrollableVerticalOverflow):
145         (WebCore::RenderLayer::updateScrollbarsAfterLayout):
146         (WebCore::RenderLayer::updateScrollbarsAfterStyleChange):
147         * rendering/RenderLayer.h:
148         (RenderLayer):
149
150 2012-12-07  Max Feil  <mfeil@rim.com>
151
152         [BlackBerry] make "isVideo" information available to platform media player
153         https://bugs.webkit.org/show_bug.cgi?id=104334
154
155         Reviewed by Rob Buis.
156
157         The platform player needs to know whether the element is <video>
158         or <audio>, so it can make certain decisions before metadata
159         is ready. This is part of a performance optimization refactor
160         which does not change functionality so no new tests are required.
161
162         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
163         (WebCore::MediaPlayerPrivate::load):
164
165 2012-12-07  Kondapally Kalyan  <kalyan.kondapally@intel.com>
166
167         [EFL] [AC] Implement ImageExtractor::extractImage in GraphicsContext3DEfl.
168         https://bugs.webkit.org/show_bug.cgi?id=104271.
169
170         Reviewed by Kenneth Rohde Christiansen.
171
172         This patch implements ImageExtractor::extractImage in GraphicsContext3DEfl.
173
174         Covered by existing tests.
175
176         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
177         (WebCore::GraphicsContext3D::ImageExtractor::~ImageExtractor):
178         (WebCore::GraphicsContext3D::ImageExtractor::extractImage):
179
180 2012-12-06  Carlos Garcia Campos  <cgarcia@igalia.com>
181
182         Use always the order iterator from data member in RenderFlexibleBox
183         https://bugs.webkit.org/show_bug.cgi?id=104112
184
185         Reviewed by Tony Chang.
186
187         Some methods receive it as parameter and others use the data
188         member.
189
190         * rendering/RenderFlexibleBox.cpp:
191         (WebCore::RenderFlexibleBox::layoutBlock):
192         (WebCore::RenderFlexibleBox::repositionLogicalHeightDependentFlexItems):
193         (WebCore::RenderFlexibleBox::layoutFlexItems):
194         (WebCore::RenderFlexibleBox::computeNextFlexLine):
195         (WebCore::RenderFlexibleBox::alignFlexLines):
196         (WebCore::RenderFlexibleBox::alignChildren):
197         (WebCore::RenderFlexibleBox::flipForRightToLeftColumn):
198         (WebCore::RenderFlexibleBox::flipForWrapReverse):
199         * rendering/RenderFlexibleBox.h:
200
201 2012-12-07  Kent Tamura  <tkent@chromium.org>
202
203         Improve confusing code in BaseMultipleFieldsDateAndTimeInputType
204         https://bugs.webkit.org/show_bug.cgi?id=104353
205
206         Reviewed by Kentaro Hara.
207
208         This doesn't change any behavior because call sites of
209         isEditControlOwnerDisabled and isEditControlOwnerReadOnly treat them
210         similarly.
211
212         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
213         (WebCore::BaseMultipleFieldsDateAndTimeInputType::isEditControlOwnerDisabled):
214         Checks element()->disabled, not readOnly.
215         (WebCore::BaseMultipleFieldsDateAndTimeInputType::isEditControlOwnerReadOnly):
216         Checks element()->readOnly, not disabled.
217
218 2012-12-07  Jon Lee  <jonlee@apple.com>
219
220         Build fix.
221
222         * plugins/PlugInOriginHash.cpp:
223         (WebCore::PlugInOriginHash::hash):
224
225 2012-12-04  Jon Lee  <jonlee@apple.com>
226
227         Add PlugInOriginHash
228         https://bugs.webkit.org/show_bug.cgi?id=103655
229         <rdar://problem/12778949>
230
231         Reviewed by Alexey Proskuryakov.
232
233         Add the concept of plug-in origin hashes, which are based on a combination of the base domains of the
234         page's main frame and the plug-in, and the plug-in MIME type.
235
236         * plugins/PlugInOriginHash.cpp: Added.
237         (WebCore::addCaseFoldedCharacters): Add the case-folded string to the hash.
238         (WebCore::PlugInOriginHash::hash): The hash is based on the concatenation of the page's host, the plug-in
239         URL's host, and the MIME type. We use StringHasher to get all 32-bits of the hash, since using StringImpl's hash
240         masks out 8 of the hash bits to make room for bit flags.
241         * plugins/PlugInOriginHash.h: Added.
242
243         * CMakeLists.txt:
244         * GNUmakefile.list.am:
245         * Target.pri:
246         * WebCore.gypi:
247         * WebCore.vcproj/WebCore.vcproj:
248         * WebCore.xcodeproj/project.pbxproj:
249
250 2012-12-06  Kent Tamura  <tkent@chromium.org>
251
252         Refactoring: Clean up placeholder attribute usage
253         https://bugs.webkit.org/show_bug.cgi?id=104337
254
255         Reviewed by Kentaro Hara.
256
257         No new tests. This doesn't change any behavior.
258
259         * html/HTMLInputElement.cpp: Remove placeholder and setPlacehodler.
260         * html/HTMLInputElement.h: Ditto.
261         * html/HTMLTextFormControlElement.cpp:
262         (WebCore::HTMLTextFormControlElement::strippedPlaceholder):
263         We can use fastGetAttribute for placeholder.
264         (WebCore::HTMLTextFormControlElement::isPlaceholderEmpty):
265         Ditto.
266
267 2012-12-06  Kent Tamura  <tkent@chromium.org>
268
269         Refactoring: Rename HTMLFormControlElement::required to isRequired
270         https://bugs.webkit.org/show_bug.cgi?id=104336
271
272         Reviewed by Kentaro Hara.
273
274         m_required should be m_isRequired, and required() should be
275         isRequired. It's safe to rename them because HTML*Element::required IDL
276         attributes are [Reflected].
277         http://www.webkit.org/coding/coding-style.html#names-bool
278
279         * accessibility/AccessibilityNodeObject.cpp:
280         (WebCore::AccessibilityNodeObject::isRequired):
281         * css/StyleResolver.cpp:
282         (WebCore::StyleResolver::canShareStyleWithControl):
283         * dom/CheckedRadioButtons.cpp:
284         (WebCore::RadioButtonGroup::add):
285         (WebCore::RadioButtonGroup::requiredAttributeChanged):
286         (WebCore::RadioButtonGroup::remove):
287         * html/CheckboxInputType.cpp:
288         (WebCore::CheckboxInputType::valueMissing):
289         * html/FileInputType.cpp:
290         (WebCore::FileInputType::valueMissing):
291         * html/HTMLFormControlElement.cpp:
292         (WebCore::HTMLFormControlElement::HTMLFormControlElement):
293         (WebCore::HTMLFormControlElement::parseAttribute):
294         (WebCore::HTMLFormControlElement::isRequired):
295         * html/HTMLFormControlElement.h:
296         (HTMLFormControlElement):
297         * html/HTMLInputElement.cpp:
298         (WebCore::HTMLInputElement::isRequiredFormControl):
299         (WebCore::HTMLInputElement::setupDateTimeChooserParameters):
300         * html/HTMLSelectElement.cpp:
301         (WebCore::HTMLSelectElement::valueMissing):
302         (WebCore::HTMLSelectElement::isRequiredFormControl):
303         * html/HTMLTextAreaElement.h:
304         (WebCore::HTMLTextAreaElement::isRequiredFormControl):
305         * html/TextFieldInputType.cpp:
306         (WebCore::TextFieldInputType::valueMissing):
307
308 2012-12-06  Hajime Morrita  <morrita@google.com>
309
310         [Shadow DOM] Implement Element::shadowRoot with prefix
311         https://bugs.webkit.org/show_bug.cgi?id=102912
312
313         Reviewed by Dimitri Glazkov.
314
315         - Added Element::shadowRoot() which return the youngest author shadow root.
316         - Renamed existing Node::shadowRoot() to containingShadowRoot() to avoid name shadowing.
317           The name shadowRoot() is confusing anyway so this is good opportunity to rename it.
318
319         Test: fast/dom/shadow/shadow-aware-shadow-root.html
320
321         * css/SelectorChecker.cpp:
322         (WebCore::SelectorChecker::checkSelector):
323         * css/StyleScopeResolver.cpp:
324         (WebCore::StyleScopeResolver::scopeFor):
325         (WebCore::StyleScopeResolver::addHostRule):
326         * dom/Element.cpp:
327         (WebCore::Element::shadowRoot):
328         (WebCore):
329         * dom/Element.h:
330         (Element):
331         * dom/Element.idl:
332         * dom/ElementShadow.cpp:
333         (WebCore::ElementShadow::setShouldCollectSelectFeatureSet):
334         * dom/Node.cpp:
335         (WebCore::Node::rendererIsEditable):
336         (WebCore::Node::shadowHost):
337         (WebCore::Node::shadowAncestorNode):
338         (WebCore::Node::containingShadowRoot):
339         * dom/Node.h:
340         (Node):
341         * dom/Range.cpp:
342         (WebCore::Range::shadowRoot):
343         * dom/ShadowRoot.cpp:
344         (WebCore::ShadowRoot::insertedInto):
345         (WebCore::ShadowRoot::removedFrom):
346         * dom/ShadowRoot.h:
347         (WebCore::ShadowRoot::isAccessible):
348         * editing/TextIterator.cpp:
349         (WebCore::TextIterator::handleReplacedElement):
350         * editing/htmlediting.cpp:
351         (WebCore::indexForVisiblePosition):
352         * html/HTMLStyleElement.cpp:
353         (WebCore::HTMLStyleElement::scopedAttributeChanged):
354         (WebCore::HTMLStyleElement::registerWithScopingNode):
355         (WebCore::HTMLStyleElement::removedFrom):
356         * html/shadow/ContentDistributor.cpp:
357         (WebCore::ContentDistributor::distribute):
358         * html/shadow/HTMLContentElement.cpp:
359         (WebCore::HTMLContentElement::parseAttribute):
360         (WebCore::HTMLContentElement::insertedInto):
361         (WebCore::HTMLContentElement::removedFrom):
362         * html/shadow/HTMLShadowElement.cpp:
363         (WebCore::HTMLShadowElement::insertedInto):
364         (WebCore::HTMLShadowElement::removedFrom):
365         * html/shadow/InsertionPoint.cpp:
366         (WebCore::InsertionPoint::attach):
367         (WebCore::InsertionPoint::detach):
368         (WebCore::InsertionPoint::isActive):
369         (WebCore::InsertionPoint::childrenChanged):
370         (WebCore::InsertionPoint::insertedInto):
371         (WebCore::InsertionPoint::removedFrom):
372         (WebCore::InsertionPoint::setResetStyleInheritance):
373         * page/EventHandler.cpp:
374         (WebCore::instanceAssociatedWithShadowTreeElement):
375         * svg/SVGElement.cpp:
376         (WebCore::SVGElement::correspondingElement):
377         (WebCore::collectInstancesForSVGElement):
378
379 2012-12-06  Michael Pruett  <michael@68k.org>
380
381         IndexedDB: Replace int64 with int64_t
382         https://bugs.webkit.org/show_bug.cgi?id=104338
383
384         Reviewed by Kentaro Hara.
385
386         Cleaning up coding inconsistencies, no change in behavior.
387
388         Tests: storage/indexeddb/*
389
390         * Modules/indexeddb/IDBFactory.cpp:
391         (WebCore::IDBFactory::openInternal):
392
393 2012-12-06  James Simonsen  <simonjam@chromium.org>
394
395         [Resource Timing] Allow detailed timing on same origin sites
396         https://bugs.webkit.org/show_bug.cgi?id=104328
397
398         Reviewed by Tony Gentilcore.
399
400         This block was lost when I moved it to PerformanceResourceTiming.cpp.
401
402         Test: http/tests/w3c/webperf/submission/resource-timing/html/test_resource_attribute_order.html
403
404         * page/PerformanceResourceTiming.cpp:
405         (WebCore::passesTimingAllowCheck):
406
407 2012-12-06  Rick Byers  <rbyers@chromium.org>
408
409         CSS cursor property should support webkit-image-set
410         https://bugs.webkit.org/show_bug.cgi?id=99493
411
412         Reviewed by Beth Dakin.
413
414         Add support for image scale factors attached to custom mouse cursor images
415         behind ENABLE(MOUSE_CURSOR_SCALE).
416
417         This required refactoring CSSCursorImageValue to derive directly from
418         CSSValue since it can contain either a CSSImageValue or a CSSImageSetValue.
419         If it contains an image-set, then we can plumb directly through to the
420         CSSImageSetValue.  If it contains an image, then either we can plumb directly
421         through to the CSSImageValue, or if the URL represents an SVG cursor we have
422         to intercept the image loading in order to substitute the actual SVG image URL
423         and do the appropriate lifetime management.
424
425         Tests: fast/css/cursor-parsing-image-set.html
426                fast/events/mouse-cursor-image-set.html
427
428         * Configurations/FeatureDefines.xcconfig: Add ENABLE_MOUSE_CURSOR_SCALE - disabled
429         * GNUmakefile.features.am: ditto
430         * css/CSSCursorImageValue.cpp: Refactor to inherit directly from CSSValue and support image sets
431         (WebCore::CSSCursorImageValue::CSSCursorImageValue):
432         (WebCore::CSSCursorImageValue::~CSSCursorImageValue):
433         (WebCore::CSSCursorImageValue::customCssText):
434         (WebCore::CSSCursorImageValue::updateIfSVGCursorIsUsed):
435         (WebCore::CSSCursorImageValue::cachedImage):
436         (WebCore::CSSCursorImageValue::cachedOrPendingImage):
437         (WebCore::CSSCursorImageValue::isSVGCursor):
438         (WebCore::CSSCursorImageValue::cachedImageURL):
439         (WebCore::CSSCursorImageValue::clearCachedImage):
440         (WebCore::CSSCursorImageValue::reportDescendantMemoryUsage):
441         * css/CSSCursorImageValue.h: Remove cursor-specific hacks
442         (WebCore::CSSCursorImageValue::create):
443         (CSSCursorImageValue):
444         * css/CSSImageValue.cpp:
445         (WebCore::CSSImageValue::cachedImage):
446         * css/CSSImageValue.h:
447         (CSSImageValue):
448         * css/CSSParser.cpp:
449         (WebCore::CSSParser::parseValue): Parse cursor(-webkit-image-set(...)) rules
450         * css/CSSValue.h:
451         (WebCore::CSSValue::isImageValue):
452         * css/StyleBuilder.cpp:
453         (WebCore::ApplyPropertyCursor::applyValue):
454         * css/StyleResolver.cpp: Hook up new CSSCursorImageValue support since it can't be handled like other images any more.
455         (WebCore::StyleResolver::styleImage):
456         (WebCore::StyleResolver::cursorOrPendingFromValue):
457         (WebCore::StyleResolver::loadPendingImage):
458         * css/StyleResolver.h:
459         (StyleResolver):
460         * page/EventHandler.cpp:
461         (WebCore::EventHandler::selectCursor): Handle StyleCachedImageSet images and plumb scale factor through
462         * platform/Cursor.cpp:
463         (WebCore::Cursor::Cursor): Add imageScaleFactor
464         * platform/Cursor.h: Add imageScaleFactor
465         (Cursor):
466         (WebCore::Cursor::imageScaleFactor):
467         * platform/chromium/CursorChromium.cpp: Add imageScaleFactor
468         (WebCore::Cursor::Cursor):
469         (WebCore::Cursor::operator=):
470         * rendering/style/CursorData.h: Clarify hotspot units
471         (CursorData):
472         * rendering/style/StyleCachedImage.h:
473         (StyleCachedImage::cachedImage): Override new virtual.
474         * rendering/style/StyleCachedImageSet.h:
475         (StyleCachedImageSet::cachedImage): Override new virtual.
476         * rendering/style/StyleImage.h:
477         (StyleImage::cachedImage): Add new virtual method to avoid lots of casts and typechecks.
478         * rendering/style/StylePendingImage.h: Add CSSCursorImageValue support
479         (WebCore::StylePendingImage::cssCursorImageValue):
480         * testing/Internals.cpp:
481         (WebCore::Internals::getCurrentCursorInfo): Print non-identity scale factors for testing
482
483 2012-12-06  Hayato Ito  <hayato@chromium.org>
484
485         Event's relatedTarget re-targeting does not occur for manually fired mouse events created by event.initMouseEvent().
486         https://bugs.webkit.org/show_bug.cgi?id=102681
487
488         Reviewed by Dimitri Glazkov.
489
490         Make sure that event's relatedTarget re-targeting occurs for mouse
491         events created by event.initMouseEvent().  Since user-generated
492         mouse events can have a relatedTarget which is same to the target
493         node, the algorithm which calculates event's ancestors is also
494         updated so that ancestors are not shrunk wrongly.
495
496         Test: fast/events/dispatch-synthetic-mouseevent.html
497               fast/dom/shadow/shadow-dom-event-dispatching.html
498
499         * dom/EventDispatcher.cpp:
500         (WebCore::EventRelatedTargetAdjuster::adjust):
501         * dom/MouseEvent.cpp:
502         (WebCore::MouseEventDispatchMediator::create):
503         (WebCore::MouseEventDispatchMediator::MouseEventDispatchMediator):
504         (WebCore::MouseEventDispatchMediator::dispatchEvent):
505         * dom/MouseEvent.h:
506         (WebCore::MouseEventDispatchMediator::isSyntheticMouseEvent):
507         (MouseEventDispatchMediator):
508         * dom/Node.cpp:
509         (WebCore::Node::dispatchEvent):
510
511 2012-12-06  Kunihiko Sakamoto  <ksakamoto@chromium.org>
512
513         Disabled file input box stops a certain other div from being rendered
514         https://bugs.webkit.org/show_bug.cgi?id=104226
515
516         Reviewed by Dimitri Glazkov.
517
518         The bug was caused by setNeedsStyleRecalc() call during style recalculation,
519         which resulted in inconsistent ChildNeedsStyleRecalc flags in DOM tree.
520
521         When reattach of file input happens during style recalculation,
522         RenderFileUploadControl::updateFromElement() is called from attach().
523         It may change the disabled state of the upload button in its shadow tree,
524         but it triggers style recalculation.
525
526         This patch solves this issue by setting disabled state of the upload button in
527         FileInputType::disabledAttributeChanged instead of RenderFileUploadControl.
528
529         Test: fast/forms/file/sibling-of-disabled-file-input.html
530
531         * html/FileInputType.cpp:
532         (WebCore::FileInputType::disabledAttributeChanged): Added.
533         * html/FileInputType.h:
534         (FileInputType): Declare disabledAttributeChanged.
535         * rendering/RenderFileUploadControl.cpp:
536         (WebCore::RenderFileUploadControl::updateFromElement): Remove call to button->setDisabled().
537
538 2012-12-06  Dominic Cooney  <dominicc@chromium.org>
539
540         Element.pseudo property should be prefixed
541         https://bugs.webkit.org/show_bug.cgi?id=104060
542
543         Reviewed by Hajime Morita.
544
545         Other Shadow DOM properties are prefixed; pseudo should be too.
546
547         Covered by updated tests in fast/dom/shadow.
548
549         * dom/Element.idl:
550
551 2012-12-06  Andrei Bucur  <abucur@adobe.com>
552
553         [CSS Regions] Remove the sanitize mechanism from LineFragmentationData
554         https://bugs.webkit.org/show_bug.cgi?id=104234
555
556         Reviewed by David Hyatt.
557
558         Remove previous work that ensured an invalid region is never returned by the containingRegion getter. After r136793 the blocks always
559         relayout children if the region chain changes. This means the sanitize() method is only necessary when all the regions are removed.
560         This case is treated separately in layoutInlineChildren.
561
562         Tests: no new functionality, no bug fixed.
563
564         * rendering/RenderBlock.cpp:
565         (WebCore::RenderBlock::lineWidthForPaginatedLineChanged):
566         * rendering/RenderBlockLineLayout.cpp:
567         (WebCore::RenderBlock::layoutInlineChildren):
568         * rendering/RootInlineBox.cpp:
569         (WebCore::RootInlineBox::containingRegion):
570         (WebCore):
571         (WebCore::RootInlineBox::setContainingRegion):
572         * rendering/RootInlineBox.h:
573         (RootInlineBox):
574         (WebCore::RootInlineBox::LineFragmentationData::LineFragmentationData):
575         (LineFragmentationData):
576
577 2012-12-06  Kenneth Russell  <kbr@google.com>
578
579         Associate URLs with GraphicsContext3D instances created for WebGL
580         https://bugs.webkit.org/show_bug.cgi?id=103793
581
582         Reviewed by Adam Barth.
583
584         Pass down the URL of the topmost frame's document creating the
585         WebGL context to the platform layer through
586         GraphicsContext3D::Attributes.
587
588         Not feasible to write a layout test for this change; has no
589         user-visible effect. Tested manually with failure injection in
590         Chromium port.
591
592         * html/canvas/WebGLRenderingContext.cpp:
593         (WebCore):
594         (WebCore::WebGLRenderingContext::create):
595             Pass top document's URL in context creation attributes.
596         * platform/chromium/support/GraphicsContext3DChromium.cpp:
597         (WebCore::GraphicsContext3D::create):
598             Pass URL through WebKit API.
599         * platform/graphics/GraphicsContext3D.h:
600         (Attributes):
601             Add top document's URL to context creation attributes.
602
603 2012-12-06  Philip Rogers  <pdr@google.com>
604
605         Unify SVG's animation and target tracking systems.
606         https://bugs.webkit.org/show_bug.cgi?id=102655
607
608         Reviewed by Dirk Schulze.
609
610         This patch unifies our animation target tracking system and regular target tracking system.
611         This simplifies the code, fixes a bug, and cleans up a historically security-sensitive area.
612
613         Background: When <use>, <mpath>, <animate>, etc. reference another element using
614         xlink:href="#id", we need to track when #id changes to #otherId, when #id is removed, etc.
615         This bookkeeping of element -> target is done in SVGDocumentExtensions. Additionally, when
616         a target changes that causes layout (e.g., rect.x is changed), all dependent elements with
617         renderers are notified (<animate> has no renderer and will not use this).
618
619         Previously, xlink:href changes were lazily resolved when targetElement() was called, target
620         changes were tracked using the animation tracking framework, and pending targets did not
621         work (e.g., <animate xlink:href="#p"><!--animate is now pending #p --><rect id="p"/>).
622
623         After this patch, we no longer lazily resolve targetElement() but instead change it when
624         our xlink:href attribute changes. Instead of using the animation tracking framework in
625         SVGDocumentExtensions, we now use the regular target tracking framework. Lastly, by using
626         the regular target tracking framework we are able to hook into the pending resource handling
627         which fixes a bug (see the test).
628
629         A test has been added to test that the order of animation elements does not matter. A second
630         test has been added to show we do not regress a pending-while-pending case.
631
632         Tests: svg/animations/svg-animation-order.html
633                svg/custom/svg-pending-twice.html
634
635         * svg/SVGAnimateElement.cpp:
636         (WebCore::SVGAnimateElement::setTargetElement):
637
638             setTargetElement and setAttributeName now work similarly. When the corresponding attribute
639             changes, we update our internal state (target or attributeName) and save it instead of
640             looking these values up on each iteration.
641
642         (WebCore::SVGAnimateElement::setAttributeName):
643         (WebCore):
644         (WebCore::SVGAnimateElement::resetAnimatedPropertyType):
645         * svg/SVGAnimateElement.h:
646         (SVGAnimateElement):
647         * svg/SVGAnimationElement.cpp:
648         (WebCore::SVGAnimationElement::setAttributeType):
649         (WebCore::SVGAnimationElement::setTargetElement):
650         (WebCore::SVGAnimationElement::setAttributeName):
651         * svg/SVGAnimationElement.h:
652         (SVGAnimationElement):
653         * svg/SVGDocumentExtensions.cpp:
654         (WebCore::SVGDocumentExtensions::~SVGDocumentExtensions):
655         (WebCore):
656         * svg/SVGDocumentExtensions.h:
657         (SVGDocumentExtensions):
658         * svg/SVGElement.cpp:
659         (WebCore::SVGElement::~SVGElement):
660         (WebCore::SVGElement::removedFrom):
661         (WebCore::SVGElement::attributeChanged):
662         * svg/SVGElementInstance.cpp:
663         (WebCore::SVGElementInstance::invalidateAllInstancesOfElement):
664
665             This can be removed after r131631 landed.
666
667         * svg/SVGMPathElement.cpp:
668         (WebCore::SVGMPathElement::buildPendingResource):
669         * svg/SVGTextPathElement.cpp:
670         (WebCore::SVGTextPathElement::buildPendingResource):
671
672             A bug was discovered in review with our resource tracking in a pending-while-pending
673             case. SVGMpathElement and SVGTextPathElement have been updated to fix this as well.
674
675         * svg/animation/SVGSMILElement.cpp:
676
677             The changes in SVGSMILElement should look very similar to SVGFEImageElement,
678             SVGMPathElement, etc. The idea is to build pending resources when added or
679             removed from the document, or when the href attribute changes.
680
681         (WebCore::SVGSMILElement::~SVGSMILElement):
682         (WebCore):
683         (WebCore::SVGSMILElement::clearResourceReferences):
684         (WebCore::SVGSMILElement::buildPendingResource):
685         (WebCore::SVGSMILElement::insertedInto):
686         (WebCore::SVGSMILElement::removedFrom):
687         (WebCore::SVGSMILElement::svgAttributeChanged):
688         (WebCore::SVGSMILElement::setAttributeName):
689         (WebCore::SVGSMILElement::setTargetElement):
690         * svg/animation/SVGSMILElement.h:
691         (WebCore):
692         (WebCore::SVGSMILElement::targetElement):
693         (SVGSMILElement):
694
695 2012-12-06  Jon Lee  <jonlee@apple.com>
696
697         Retry snapshots if they are too empty
698         https://bugs.webkit.org/show_bug.cgi?id=104174
699         <rdar://problem/12820146>
700
701         Reviewed by Simon Fraser.
702
703         * html/HTMLPlugInImageElement.cpp:
704         (WebCore::HTMLPlugInImageElement::updateSnapshot): Change the state machine check so that even
705         when the plug-in is displaying a snapshot, the snapshot can still be updated. This allows for the
706         retries to be drawn.
707
708 2012-12-06  Adam Klein  <adamk@chromium.org>
709
710         [HTMLTemplateElement] make content readonly and cloneNode(deep) clone content
711         https://bugs.webkit.org/show_bug.cgi?id=104181
712
713         Reviewed by Adam Barth.
714
715         Note that this patch also adds IDL attributes/custom code to tie the lifetime
716         of the content DocumentFragment wrapper to the lifetime of the template element wrapper
717         via a hidden JS property.
718
719         Based on a patch by Rafael Weinstein.
720
721         Test: fast/dom/HTMLTemplateElement/contentWrappers.html
722
723         * DerivedSources.cpp:
724         * Target.pri:
725         * UseJSC.cmake:
726         * WebCore.gypi:
727         * WebCore.xcodeproj/project.pbxproj:
728         * bindings/js/JSBindingsAllInOne.cpp:
729         * bindings/js/JSHTMLTemplateElementCustom.cpp: Copied from Source/WebCore/html/HTMLTemplateElement.idl.
730         (WebCore):
731         (WebCore::JSHTMLTemplateElement::content):
732         * bindings/scripts/CodeGeneratorV8.pm: Add support for new V8CacheAttributeForGC attribute.
733         * dom/Element.h:
734         (Element): Annotate cloneNode() with OVERRIDE
735         * html/HTMLTemplateElement.cpp:
736         (WebCore::HTMLTemplateElement::cloneNode):
737         * html/HTMLTemplateElement.h:
738         (HTMLTemplateElement): override cloneNode
739         * html/HTMLTemplateElement.idl: Make content readonly and add custom attributes.
740
741 2012-12-06  Brent Fulgham  <bfulgham@webkit.org>
742
743         [Windows, WinCairo] Unreviewed build correction.
744
745         Exclude 'DocumentSharedObjectPool.cpp' from build, since it is
746         built as part of DOMAllInOne.cpp.  The build (besides wasting
747         time) generates a bunch of build warnings for duplicate symbols.
748
749         * WebCore.vcproj/WebCore.vcproj: Mark DocumentSharedObjectPool.cpp
750         to not build independently of DOMAllInOne.cpp.
751
752 2012-12-06  David Grogan  <dgrogan@chromium.org>
753
754         IndexedDB: Abort transactions because of leveldb errors part 4
755         https://bugs.webkit.org/show_bug.cgi?id=103964
756
757         Reviewed by Tony Chang.
758
759         deleteDatabase, open, and deleteObjectStore will now fire more aborts
760         and errors in case of leveldb problems
761
762         * Modules/indexeddb/IDBBackingStore.cpp:
763         (WebCore::getVarInt): Make return value indicate leveldb error.
764         (WebCore::getString): ditto.
765         (WebCore::IDBBackingStore::getIDBDatabaseMetaData):
766         Change return value to indicate leveldb error.
767
768         (WebCore::IDBBackingStore::deleteDatabase):
769         Already had the desired return value semantics. As a consumer of
770         getIDBDatabaseMetadata, will return an error (causing an abort) more
771         often.
772
773         (WebCore::IDBBackingStore::deleteObjectStore):
774         Needed return value change. Will return error to DatabaseBackend to
775         indicate leveldb problems.
776
777         * Modules/indexeddb/IDBBackingStore.h:
778         (IDBBackingStore):
779         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
780         (WebCore::IDBDatabaseBackendImpl::openInternal):
781         Pass leveldb errors up to callers, who already handle internal errors.
782
783         (WebCore::IDBDatabaseBackendImpl::DeleteObjectStoreOperation::perform):
784         Abort transaction if there were leveldb problems deleting an object
785         store.
786
787 2012-12-06  David Grogan  <dgrogan@chromium.org>
788
789         IndexedDB: Add webkitErrorMessage to IDBTransaction
790         https://bugs.webkit.org/show_bug.cgi?id=104199
791
792         Reviewed by Tony Chang.
793
794         Don't drop error messages on the floor.
795
796         Expose an error message on IDBTransaction to give developers more
797         information than the opaque error code currently available. This is
798         exactly what is done in IDBRequest. 
799
800         Tests - transaction-error.html
801
802         * Modules/indexeddb/IDBDatabaseError.h:
803         (WebCore::IDBDatabaseError::create):
804         * Modules/indexeddb/IDBRequest.cpp:
805         (WebCore::IDBRequest::dispatchEvent):
806         (WebCore::IDBRequest::uncaughtExceptionInEventHandler):
807         * Modules/indexeddb/IDBTransaction.cpp:
808         (WebCore::IDBTransaction::setError):
809         (WebCore):
810         (WebCore::IDBTransaction::webkitErrorMessage):
811         (WebCore::IDBTransaction::onAbort):
812         * Modules/indexeddb/IDBTransaction.h:
813         (IDBTransaction):
814         * Modules/indexeddb/IDBTransaction.idl:
815
816 2012-12-06  Alexander Shalamov  <alexander.shalamov@intel.com>
817
818         XMLHttpRequest Content-Type should be taken from Blob type
819         https://bugs.webkit.org/show_bug.cgi?id=99983
820
821         Reviewed by Alexey Proskuryakov.
822
823         Fix XMLHttpRequest::send(Blob*) method, so that the Content-Type is set according to W3C specification.
824         http://www.w3.org/TR/XMLHttpRequest/#the-send-method
825
826         Added test that check if content type is set correctly when blob object is sent.
827
828         Test: http/tests/xmlhttprequest/post-blob-content-type.html
829
830         * xml/XMLHttpRequest.cpp:
831         (WebCore::XMLHttpRequest::send):
832             Set correct MIME type for Blob objects.
833         * WebCore.vcproj/WebCore.vcproj:
834             Added ParsedContentType to project file.
835
836 2012-12-06  Min Qin  <qinmin@chromium.org>
837
838         Make LazyDecodingPixelRef inherit from skia::LazyPixelRef so that cc thread can access it
839         https://bugs.webkit.org/show_bug.cgi?id=103555
840
841         Reviewed by Stephen White.
842
843         Expose LazyDecodingPixelRef to the cc thread by inheriting from skia::LazyPixelRef.
844         No test added for now as impl side paiting is still WIP.
845
846         * platform/graphics/chromium/LazyDecodingPixelRef.cpp:
847         (WebCore::LazyDecodingPixelRef::LazyDecodingPixelRef):
848         (WebCore::LazyDecodingPixelRef::PrepareToDecode):
849         (WebCore):
850         (WebCore::LazyDecodingPixelRef::Decode):
851         * platform/graphics/chromium/LazyDecodingPixelRef.h:
852         (LazyDecodingPixelRef):
853
854 2012-12-06  Kentaro Hara  <haraken@chromium.org>
855
856         [V8] Make an Isolate mandatory in v8UnsignedInteger()
857         https://bugs.webkit.org/show_bug.cgi?id=104235
858
859         Reviewed by Adam Barth.
860
861         No tests. No change in behavior.
862
863         * bindings/v8/ArrayValue.cpp:
864         (WebCore::ArrayValue::get):
865         * bindings/v8/V8Binding.h:
866         (WebCore::v8UnsignedInteger):
867         * bindings/v8/V8LazyEventListener.cpp:
868         (WebCore::V8LazyEventListener::prepareListenerObject):
869
870 2012-12-06  David Hyatt  <hyatt@apple.com>
871
872         [New Multicolumn] Add requiresBalancing booleans to track which column sets need to rebalance.
873         https://bugs.webkit.org/show_bug.cgi?id=104297
874
875         Reviewed by Simon Fraser.
876
877         Add requiresBalancing booleans to RenderMultiColumnBlock and RenderMultiColumnSet. For now the former is just propagated
878         to the latter, but eventually RenderMultiColumnSets will have a notion of balancing that has to be independent of the
879         owning block (e.g., maybe only the last set rebalances, or maybe only a set that contains the content between two forced
880         breaks wants to rebalance, etc.).
881
882         * rendering/RenderMultiColumnBlock.cpp:
883         (WebCore::RenderMultiColumnBlock::RenderMultiColumnBlock):
884         (WebCore::RenderMultiColumnBlock::checkForPaginationLogicalHeightChange):
885         (WebCore::RenderMultiColumnBlock::ensureColumnSets):
886         * rendering/RenderMultiColumnBlock.h:
887         (WebCore::RenderMultiColumnBlock::requiresBalancing):
888         (RenderMultiColumnBlock):
889         * rendering/RenderMultiColumnSet.cpp:
890         (WebCore::RenderMultiColumnSet::RenderMultiColumnSet):
891         * rendering/RenderMultiColumnSet.h:
892         (WebCore::RenderMultiColumnSet::requiresBalancing):
893         (WebCore::RenderMultiColumnSet::setRequiresBalancing):
894         (RenderMultiColumnSet):
895         (WebCore::toRenderMultiColumnSet):
896         (WebCore):
897
898 2012-12-06  Sheriff Bot  <webkit.review.bot@gmail.com>
899
900         Unreviewed, rolling out r136871.
901         http://trac.webkit.org/changeset/136871
902         https://bugs.webkit.org/show_bug.cgi?id=104293
903
904         crashes on bots and memory leaks (Requested by esprehn on
905         #webkit).
906
907         * dom/Document.h:
908         (WebCore::Node::treeScope):
909         * dom/Element.cpp:
910         (WebCore::Element::createRareData):
911         * dom/ElementRareData.h:
912         (ElementRareData):
913         (WebCore::ElementRareData::ElementRareData):
914         * dom/Node.cpp:
915         (WebCore::Node::setTreeScope):
916         (WebCore::Node::ensureRareData):
917         (WebCore::Node::createRareData):
918         (WebCore::Node::clearRareData):
919         * dom/Node.h:
920         (WebCore::NodeRareDataBase::~NodeRareDataBase):
921         (WebCore::NodeRareDataBase::NodeRareDataBase):
922         (NodeRareDataBase):
923         (WebCore::Node::renderer):
924         (WebCore::Node::setRenderer):
925         (Node):
926         (WebCore::Node::hasRareData):
927         * dom/NodeRareData.h:
928         (WebCore::NodeRareData::NodeRareData):
929         (NodeRareData):
930
931 2012-12-06  Adam Klein  <adamk@chromium.org>
932
933         Remove non-v8 binding files from WebCore.gypi
934         https://bugs.webkit.org/show_bug.cgi?id=104288
935
936         Reviewed by Adam Barth.
937
938         Since the gyp build is only used by the Chromium project,
939         there's no need for cpp, gobject, objc, or jsc bindings
940         in these build files.
941
942         * WebCore.gypi:
943
944 2012-12-06  Tony Chang  <tony@chromium.org>
945
946         REGRESSION(r135082): Restore the ability to insert author level style sheets from script
947         https://bugs.webkit.org/show_bug.cgi?id=104042
948
949         Reviewed by Antti Koivisto.
950
951         Add DocumentStyleSheetCollection::addAuthorSheet so embedders can allow scripts
952         to insert author level styles. Expose the method to window.interals for testing.
953
954         Test: userscripts/insert-stylesheets.html
955
956         * WebCore.exp.in: Update exports for Internals.cpp.
957         * WebCore.order: Update exports for Internals.cpp.
958         * dom/DocumentStyleSheetCollection.cpp:
959         (WebCore::DocumentStyleSheetCollection::~DocumentStyleSheetCollection):
960         (WebCore::DocumentStyleSheetCollection::addAuthorSheet): Add the stylesheet and force a style recalc.
961         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets): Include author level styles.
962         (WebCore::DocumentStyleSheetCollection::reportMemoryUsage): Include author styles.
963         * dom/DocumentStyleSheetCollection.h:
964         (WebCore::DocumentStyleSheetCollection::documentAuthorStyleSheets): Accessor.
965         (DocumentStyleSheetCollection): Keep track of author styles added by script.
966         * testing/Internals.cpp:
967         (WebCore::Internals::insertAuthorCSS): Testing addAuthorSheet.
968         (WebCore::Internals::insertUserCSS): Testing addUserSheet.
969         * testing/Internals.h:
970         * testing/Internals.idl: Add addAuthorSheet and addUserSheet.
971
972 2012-12-06  Elliott Sprehn  <esprehn@gmail.com>
973
974         Create only NodeRareDataBase when setting TreeScope
975         https://bugs.webkit.org/show_bug.cgi?id=104202
976
977         Reviewed by Dimitri Glazkov.
978
979         Move many fields from NodeRareData into NodeRareDataBase and rename it
980         UncommonNodeData and add a flag to determine if a UncommonNodeData is
981         actually a full NodeRareData instance. By moving fields up from NodeRareData
982         we ensure that this new flag in the base class doesn't make NodeRareData
983         grow in size.
984
985         We then make setting the tree scope only allocate the UncommonNodeData
986         instead of creating the full NodeRareData or ElementRareData. This is
987         important because when putting nodes into ShadowRoot or any descendant
988         we must associate the node with a tree scope which adds rare data to the
989         node making NodeRareData and ElementRareData not very rare.
990
991         On 64bit, this reduces the overhead per element from 136 bytes to
992         32 bytes for a 76% savings, and on other nodes from 64 bytes to 32 bytes
993         for a 50% savings.
994
995         No new tests, no change in behavior.
996
997         * dom/Document.h:
998         (WebCore::Node::treeScope):
999         * dom/Element.cpp:
1000         (WebCore::Element::createRareData):
1001         * dom/ElementRareData.h:
1002         (ElementRareData):
1003         (WebCore::ElementRareData::ElementRareData):
1004         * dom/Node.cpp:
1005         (WebCore::Node::setTreeScope):
1006         (WebCore::Node::ensureRareData):
1007         (WebCore::Node::createRareData):
1008         (WebCore::Node::clearRareData):
1009         * dom/Node.h:
1010         (WebCore::UncommonNodeData::create):
1011         (UncommonNodeData):
1012         (WebCore::UncommonNodeData::~UncommonNodeData):
1013         (WebCore::UncommonNodeData::isNodeRareData):
1014         (WebCore::UncommonNodeData::UncommonNodeData):
1015         (WebCore::Node::renderer):
1016         (WebCore::Node::setRenderer):
1017         (Node):
1018         (WebCore::Node::hasRareData):
1019         (WebCore::Node::hasUncommonNodeData):
1020         * dom/NodeRareData.h:
1021         (WebCore::NodeRareData::NodeRareData):
1022         (NodeRareData):
1023
1024 2012-12-06  Joshua Bell  <jsbell@chromium.org>
1025
1026         IndexedDB: Remove IDBDatabaseException.idl
1027         https://bugs.webkit.org/show_bug.cgi?id=102961
1028
1029         Reviewed by Adam Barth.
1030
1031         Delete the IDL and references to it. No longer needed as a enum member
1032         in the autogenerated ExceptionCodeDescription.h so removed from the ".in"
1033         file; only direct references are retained in the autogenerated cpp file.
1034
1035         Ideally the code generator would handle these new-style DOMExceptions,
1036         but we don't have any other examples yet to know what pattern to follow.
1037
1038         No new tests - just removing dead code.
1039
1040         * CMakeLists.txt:
1041         * DerivedSources.cpp:
1042         * DerivedSources.make:
1043         * DerivedSources.pri:
1044         * GNUmakefile.list.am:
1045         * Modules/indexeddb/IDBDatabaseException.idl: Removed.
1046         * WebCore.gypi:
1047         * WebCore.vcproj/WebCore.vcproj:
1048         * WebCore.xcodeproj/project.pbxproj:
1049         * dom/DOMExceptions.in:
1050         * dom/make_dom_exceptions.pl:
1051         (generateImplementation):
1052
1053 2012-12-06  Andreas Kling  <akling@apple.com>
1054
1055         [Mac] Drain the CSSValuePool on memory pressure.
1056         <http://webkit.org/b/104274>
1057
1058         Reviewed by Antti Koivisto.
1059
1060         Add a drain() mechanism to CSSValuePool and call it when we're under memory pressure.
1061
1062         * WebCore.xcodeproj/project.pbxproj:
1063         * css/CSSValuePool.cpp:
1064         (WebCore::CSSValuePool::drain):
1065         * css/CSSValuePool.h:
1066         * platform/mac/MemoryPressureHandlerMac.mm:
1067         (WebCore::MemoryPressureHandler::releaseMemory):
1068
1069 2012-12-05  Adam Klein  <adamk@chromium.org>
1070
1071         Remove gyp config for incomplete and unused Apple Mac gyp build
1072         https://bugs.webkit.org/show_bug.cgi?id=104068
1073
1074         Reviewed by Adam Barth.
1075
1076         As part of the removal, move some files to the proper sections
1077         of the gypi file.
1078
1079         * WebCore.gyp/WebCore.gyp:
1080         * WebCore.gypi:
1081
1082 2012-12-06  Hans Muller  <hmuller@adobe.com>
1083
1084         [CSS Exclusions] Add support for computing the first included interval position.
1085         https://bugs.webkit.org/show_bug.cgi?id=103327
1086
1087         Reviewed by Levi Weintraub.
1088
1089         If the first "word" in a line doesn't fit within the shape-inside when lineTop
1090         is the top of the shape's logical bounding box, adjust lineTop downwards to where
1091         the word fits.  Currently only rounded rectangle shapes are supported.
1092
1093         Added ExclusionShape::firstIncludedIntervalLogicalTop(). The new virtual method
1094         computes the topmost/leftmost location where a line segment with the specified
1095         minLogicalIntervalSize will fit within the exclusion shape and returns the
1096         corresponding logical Y coordinate.  The result is additionally constrained to
1097         be at or below minLogicalIntervalTop. If the segment will not fit anywhere within
1098         the shape, then false is returned.
1099
1100         During layout, minLogicalIntervalTop is the nominal top of the line being laid
1101         out within the exclusion shape.
1102
1103         RenderBlock::layoutRunsAndFloatsInRange() now calls a new ExclusionShapeInsideInfo
1104         method, adjustLogicalLineTop(), which uses firstIncludedIntervalLogicalTop() to
1105         decide if the logical top of the line has to be moved downwards, for the first
1106         word to fit within the exclusion shape.
1107
1108         Tests: fast/exclusions/shape-inside/shape-inside-rounded-rectangle-fit-001.html
1109                fast/exclusions/shape-inside/shape-inside-rounded-rectangle-fit-002.html
1110
1111         * rendering/ExclusionPolygon.cpp:
1112         (WebCore::ExclusionPolygon::firstIncludedIntervalLogicalTop): This is a stub implementation.
1113         * rendering/ExclusionPolygon.h:
1114         * rendering/ExclusionRectangle.cpp:
1115         (WebCore::ellipseXIntercept): Added spaces to conform to webkit style and to be consistent with ellipseYIntercept()
1116         (WebCore::ellipseYIntercept): Compute an ellipse's Y intercept for an X coordinate.
1117         (WebCore::ExclusionRectangle::firstIncludedIntervalLogicalTop): See the description above.
1118         * rendering/ExclusionRectangle.h:
1119         * rendering/ExclusionShape.h:
1120         (ExclusionShape):
1121         (WebCore::ExclusionShape::logicalTopForMinY): Internal to logical coordinate conversion.
1122         * rendering/ExclusionShapeInsideInfo.cpp:
1123         (WebCore::ExclusionShapeInsideInfo::adjustLogicalLineTop): A new method that updates m_lineTop with firstIncludedIntervalPosition().
1124         * rendering/ExclusionShapeInsideInfo.h:
1125         (ExclusionShapeInsideInfo):
1126         (WebCore::ExclusionShapeInsideInfo::logicalLineTop): This is just a cover for the private m_lineTop field.
1127         * rendering/RenderBlockLineLayout.cpp:
1128         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Added code that restarts the layout loop if it's necessary to adjust the line's logicalTop.
1129         (WebCore::RenderBlock::restartLayoutRunsAndFloatsInRange): Factored newly common code into this helper function.
1130
1131 2012-12-06  Ryosuke Niwa  <rniwa@webkit.org>
1132
1133         Use ownerNode() instead of base() in HTMLCollection
1134         https://bugs.webkit.org/show_bug.cgi?id=104244
1135
1136         Reviewed by Adam Barth.
1137
1138         Use ownerNode() instead of base() in HTMLCollection to match LiveNodeList.
1139         Notice that the definition of base(), which this patch removes, is "return ownerNode()".
1140
1141         * bindings/js/JSHTMLFormControlsCollectionCustom.cpp:
1142         (WebCore::getNamedItems):
1143         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
1144         (WebCore::JSHTMLOptionsCollection::indexSetter):
1145         (WebCore::JSHTMLOptionsCollection::remove):
1146         * bindings/scripts/CodeGeneratorJS.pm:
1147         (GenerateImplementation):
1148         * bindings/scripts/CodeGeneratorV8.pm:
1149         (GenerateOpaqueRootForGC):
1150         * bindings/scripts/IDLAttributes.txt:
1151         * bindings/v8/custom/V8HTMLFormControlsCollectionCustom.cpp:
1152         (WebCore::getNamedItems):
1153         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
1154         (WebCore::V8HTMLOptionsCollection::removeCallback):
1155         (WebCore::V8HTMLOptionsCollection::indexedPropertySetter):
1156         * dom/WebKitNamedFlow.cpp:
1157         (WebCore::WebKitNamedFlow::ownerNode):
1158         * dom/WebKitNamedFlow.h:
1159         (WebKitNamedFlow):
1160         * dom/WebKitNamedFlow.idl:
1161         * html/HTMLAllCollection.idl:
1162         * html/HTMLCollection.h:
1163         (HTMLCollection):
1164         * html/HTMLCollection.idl:
1165         * html/HTMLFormControlsCollection.cpp:
1166         (WebCore::HTMLFormControlsCollection::HTMLFormControlsCollection):
1167         (WebCore::HTMLFormControlsCollection::create):
1168         (WebCore::HTMLFormControlsCollection::formControlElements):
1169         (WebCore::HTMLFormControlsCollection::formImageElements):
1170         (WebCore::HTMLFormControlsCollection::namedItem):
1171         (WebCore::HTMLFormControlsCollection::updateNameCache):
1172         * html/HTMLFormControlsCollection.idl:
1173         * html/HTMLNameCollection.cpp:
1174         (WebCore::HTMLNameCollection::~HTMLNameCollection):
1175         (WebCore::HTMLNameCollection::virtualItemAfter):
1176         * html/HTMLOptionsCollection.cpp:
1177         (WebCore::HTMLOptionsCollection::add):
1178         (WebCore::HTMLOptionsCollection::remove):
1179         (WebCore::HTMLOptionsCollection::selectedIndex):
1180         (WebCore::HTMLOptionsCollection::setSelectedIndex):
1181         (WebCore::HTMLOptionsCollection::setLength):
1182         * html/HTMLOptionsCollection.idl:
1183         * html/HTMLPropertiesCollection.cpp:
1184         (WebCore::HTMLPropertiesCollection::updateRefElements):
1185         (WebCore::HTMLPropertiesCollection::namedItem):
1186         * html/HTMLTableRowsCollection.cpp:
1187         (WebCore::HTMLTableRowsCollection::virtualItemAfter):
1188
1189 2012-12-06  Tommy Widenflycht  <tommyw@google.com>
1190
1191         Speech Recognition API: Change the error code to a string on SpeechRecognitionError
1192         https://bugs.webkit.org/show_bug.cgi?id=104254
1193
1194         Reviewed by Adam Barth.
1195
1196         SpeechRecognitionError::code (numeric value) has been changed to SpeechRecognitionError::error (string)
1197         in the latest specification.
1198
1199         http://dvcs.w3.org/hg/speech-api/raw-file/tip/speechapi.html#speechreco-error
1200
1201         Existing tests modified to cover this patch.
1202
1203         * Modules/speech/SpeechRecognitionError.cpp:
1204         (WebCore::ErrorCodeToString):
1205         (WebCore):
1206         (WebCore::SpeechRecognitionError::create):
1207         (WebCore::SpeechRecognitionError::SpeechRecognitionError):
1208         * Modules/speech/SpeechRecognitionError.h:
1209         (SpeechRecognitionErrorInit):
1210         (WebCore::SpeechRecognitionError::error):
1211         (SpeechRecognitionError):
1212         * Modules/speech/SpeechRecognitionError.idl:
1213
1214 2012-12-06  Stephen Chenney  <schenney@chromium.org>
1215
1216         SVG <use> element inside an svg-as-image fails
1217         https://bugs.webkit.org/show_bug.cgi?id=104007
1218
1219         Reviewed by Eric Seidel.
1220
1221         Upon redraw, SVGImage calls layout on the document it is drawing into
1222         the image if the image, provided it believes the redraw does not need
1223         to be delayed. Unfortunately, when an SVG <use> element is modified
1224         (by animation, say) and regenerates its shadow tree, the destructors
1225         invoke redraw, causing the SVGImage to call layout on something that
1226         is in the process of being deleted. That's bad.
1227
1228         This change causes SVGImage to always delay the redraw. It is the most robust
1229         way to protect against this problem, as there may be any number of
1230         ways to cause this issue (a node being deleted in an svg-as-image
1231         target) and this protects against them all.
1232
1233         The test case crashes in Asan Chromium.
1234
1235         Test: svg/as-image/animated-use-as-image-crash.html
1236
1237         * svg/graphics/SVGImageCache.cpp:
1238         (WebCore::SVGImageCache::imageContentChanged): Always redraw on the timer.
1239
1240 2012-12-06  Antoine Quint  <graouts@apple.com>
1241
1242         TextTrack's .cues not ordered correctly when two cues have the same .startTime
1243         https://bugs.webkit.org/show_bug.cgi?id=103266
1244
1245         Reviewed by Eric Carlson.
1246
1247         Adding a new method TextTrackCueList::updateCueIndex() to update the list of
1248         cues after changing the .startTime or .endTime of a TextTrackCue. I elected to
1249         add a new method to TextTrackCueList rather than calling remove() and then add()
1250         on the list from TextTrack::cueDidChange() so that the nature of the operation
1251         is abstracted and we can easily change the way we keep the cue list sorted at
1252         a later time should we choose to.
1253
1254         * html/track/TextTrack.cpp:
1255         (WebCore::TextTrack::cueDidChange):
1256         * html/track/TextTrackCueList.cpp:
1257         (WebCore::TextTrackCueList::updateCueIndex):
1258         (WebCore):
1259         * html/track/TextTrackCueList.h:
1260         (TextTrackCueList):
1261
1262 2012-12-06  Andras Becsi  <andras.becsi@digia.com>
1263
1264         [Qt][Mac] Fix libxslt and libxml2 config tests
1265         https://bugs.webkit.org/show_bug.cgi?id=104164
1266
1267         Reviewed by Simon Hausmann.
1268
1269         Since libxml2 is a dependency for libxslt and is not used
1270         standalone the configurations for it should also depend on
1271         whether XSLT is enabled.
1272         Also avoid using pkg-config on Mac, instead use direct
1273         include paths and add needed libraries to the linker.
1274
1275         No new tests needed.
1276
1277         * WebCore.pri:
1278
1279 2012-12-06  Shinya Kawanaka  <shinyak@chromium.org>
1280
1281         Internals.getElementByIdInShadowRoot is nonsense now.
1282         https://bugs.webkit.org/show_bug.cgi?id=104241
1283
1284         Reviewed by Kent Tamura.
1285
1286         Since we have ShadowRoot.getElementById() now, we don't need Internals.getElementByIdInShadowRoot, which is
1287         the same functionality of ShadowRoot.getElementById().
1288
1289         Test: fast/dom/shadow/get-element-by-id-in-shadow-root.html
1290
1291         * WebCore.exp.in:
1292         * testing/Internals.cpp:
1293         * testing/Internals.h:
1294         (Internals):
1295         * testing/Internals.idl:
1296
1297 2012-12-06  Kondapally Kalyan  <kalyan.kondapally@intel.com>
1298
1299         [EFL] Active texture state gets corrupted after updating graphics surface contents.
1300         https://bugs.webkit.org/show_bug.cgi?id=104248.
1301
1302         Reviewed by Kenneth Rohde Christiansen.
1303
1304         GraphicsContext3DPrivate::copyToGraphicsSurface() doesn't restore the previously bound texture
1305         after copying texture contents. This corrupts the texture state.
1306
1307         Existing Tests should cover this.
1308
1309         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
1310         (GraphicsContext3DPrivate::copyToGraphicsSurface):
1311         * platform/graphics/opengl/GLPlatformSurface.cpp:
1312         (WebCore::GLPlatformSurface::updateContents):
1313         * platform/graphics/opengl/GLPlatformSurface.h:
1314         (GLPlatformSurface):
1315
1316 2012-12-06  Alexander Pavlov  <apavlov@chromium.org>
1317
1318         Web Inspector: Goto panel shortcuts and description are reversed
1319         https://bugs.webkit.org/show_bug.cgi?id=103988
1320
1321         Reviewed by Pavel Feldman.
1322
1323         Swap the square brackets in the shortcuts.
1324
1325         * inspector/front-end/inspector.js:
1326         (WebInspector._registerShortcuts):
1327
1328 2012-12-06  Sheriff Bot  <webkit.review.bot@gmail.com>
1329
1330         Unreviewed, rolling out r136818.
1331         http://trac.webkit.org/changeset/136818
1332         https://bugs.webkit.org/show_bug.cgi?id=104249
1333
1334         simulatedClick does not work as per #chrmium irc. (Requested
1335         by hayato on #webkit).
1336
1337         * dom/EventDispatcher.cpp:
1338         (WebCore::EventRelatedTargetAdjuster::adjust):
1339         * dom/MouseEvent.cpp:
1340         (WebCore::MouseEventDispatchMediator::create):
1341         (WebCore::MouseEventDispatchMediator::MouseEventDispatchMediator):
1342         (WebCore::MouseEventDispatchMediator::dispatchEvent):
1343         * dom/MouseEvent.h:
1344         (MouseEventDispatchMediator):
1345         * dom/Node.cpp:
1346         (WebCore::Node::dispatchEvent):
1347
1348 2012-12-06  Ulan Degenbaev  <ulan@chromium.org>
1349
1350         [v8] Fix hidden property name of V8ArrayBufferView flag.
1351         https://bugs.webkit.org/show_bug.cgi?id=104099
1352
1353         Reviewed by Kentaro Hara.
1354
1355         Fix hidden property name of V8ArrayBufferView hidden copy method.
1356
1357         * bindings/v8/V8HiddenPropertyName.h:
1358         (WebCore):
1359         * bindings/v8/custom/V8ArrayBufferViewCustom.cpp:
1360         (WebCore::getHiddenCopyMethod):
1361         (WebCore::installHiddenCopyMethod):
1362
1363 2012-12-06  Kentaro Hara  <haraken@chromium.org>
1364
1365         Unreviewed. Fixed a wrong comment landed in r136822.
1366
1367         * bindings/v8/V8Binding.h:
1368         (WebCore):
1369
1370 2012-12-05  Kentaro Hara  <haraken@chromium.org>
1371
1372         [V8] Implement deprecatedV8String()
1373         https://bugs.webkit.org/show_bug.cgi?id=104230
1374
1375         Reviewed by Adam Barth.
1376
1377         To make an Isolate mandatory in v8String(), we implement
1378         deprecatedV8String() for call sites that don't have
1379         an Isolate. Eventually we want to kill the method though.
1380
1381         No tests. No change in behavior.
1382
1383         * bindings/scripts/test/V8/V8TestCallback.cpp:
1384         (WebCore::V8TestCallback::callbackWithClass2Param):
1385         * bindings/v8/Dictionary.cpp:
1386         (WebCore::Dictionary::getKey):
1387         * bindings/v8/IDBBindingUtilities.cpp:
1388         (WebCore::get):
1389         (WebCore::set):
1390         * bindings/v8/JavaScriptCallFrame.cpp:
1391         (WebCore::JavaScriptCallFrame::evaluate):
1392         * bindings/v8/ScriptController.cpp:
1393         (WebCore::ScriptController::compileAndRunScript):
1394         (WebCore::ScriptController::bindToWindowObject):
1395         (WebCore::ScriptController::disableEval):
1396         * bindings/v8/ScriptDebugServer.cpp:
1397         (WebCore::ScriptDebugServer::setBreakpoint):
1398         (WebCore::ScriptDebugServer::removeBreakpoint):
1399         (WebCore::ScriptDebugServer::setScriptSource):
1400         (WebCore::ScriptDebugServer::ensureDebuggerScriptCompiled):
1401         (WebCore::ScriptDebugServer::compileScript):
1402         * bindings/v8/ScriptFunctionCall.cpp:
1403         (WebCore::ScriptCallArgumentHandler::appendArgument):
1404         (WebCore::ScriptFunctionCall::call):
1405         (WebCore::ScriptFunctionCall::construct):
1406         * bindings/v8/ScriptProfiler.cpp:
1407         (WebCore::ScriptProfiler::start):
1408         (WebCore::ScriptProfiler::stop):
1409         (WebCore::ScriptProfiler::takeHeapSnapshot):
1410         * bindings/v8/ScriptSourceCode.cpp:
1411         (WebCore::ScriptSourceCode::compileScript):
1412         * bindings/v8/V8Binding.h:
1413         (WebCore):
1414         (WebCore::deprecatedV8String):
1415         * bindings/v8/V8DOMWindowShell.cpp:
1416         (WebCore::V8DOMWindowShell::initializeIfNeeded):
1417         (WebCore::V8DOMWindowShell::namedItemAdded):
1418         (WebCore::V8DOMWindowShell::namedItemRemoved):
1419         * bindings/v8/V8LazyEventListener.cpp:
1420         (WebCore::V8LazyEventListener::prepareListenerObject):
1421         * bindings/v8/V8WindowErrorHandler.cpp:
1422         (WebCore::V8WindowErrorHandler::callListenerFunction):
1423         * bindings/v8/V8WorkerContextErrorHandler.cpp:
1424         (WebCore::V8WorkerContextErrorHandler::callListenerFunction):
1425         * bindings/v8/WorkerScriptController.cpp:
1426         (WebCore::WorkerScriptController::evaluate):
1427         * bindings/v8/custom/V8ArrayBufferViewCustom.cpp:
1428         (WebCore::installHiddenCopyMethod):
1429         (WebCore::copyElements):
1430         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
1431         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
1432         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1433         (WebCore::V8InjectedScriptHost::getEventListenersCallback):
1434         * bindings/v8/custom/V8InjectedScriptManager.cpp:
1435         (WebCore::InjectedScriptManager::createInjectedScript):
1436         * bindings/v8/custom/V8MessageEventCustom.cpp:
1437         (WebCore::V8MessageEvent::dataAccessorGetter):
1438         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
1439         (WebCore::toV8Object):
1440         (WebCore::V8WebGLRenderingContext::getSupportedExtensionsCallback):
1441
1442 2012-12-06  Keishi Hattori  <keishi@webkit.org>
1443
1444         Page popup should align to the right when the anchor element is rtl
1445         https://bugs.webkit.org/show_bug.cgi?id=104219
1446
1447         Reviewed by Kent Tamura.
1448
1449         Page popup should align to the right edge of the anchor element when the anchor element is rtl.
1450
1451         No new tests. Mock page popup can't test popup window position.
1452
1453         * Resources/pagepopups/pickerCommon.js:
1454         (_adjustWindowRectHorizontally): Align to the right edge when anchor element is rtl. Removed some redundant lines.
1455         (setWindowRect): If the window is hidden we want to move first then resize so the popup doesn't flicker.
1456         (isWindowHidden): Returns true if the window is hidden using hideWindow().
1457
1458 2012-12-06  Kentaro Hara  <haraken@chromium.org>
1459
1460         [V8] Make an Isolate mandatory for v8StringOrNull() and v8StringOrUndefined()
1461         https://bugs.webkit.org/show_bug.cgi?id=104213
1462
1463         Reviewed by Adam Barth.
1464
1465         All call sites of v8StringOrNull() and v8StringOrUndefined() have an Isolate.
1466
1467         No tests. No change in behavior.
1468
1469         * bindings/v8/V8Binding.h:
1470         (WebCore::v8StringOrNull):
1471         (WebCore::v8StringOrUndefined):
1472
1473 2012-12-05  Kentaro Hara  <haraken@chromium.org>
1474
1475         [V8] Implement deprecatedV8Integer(int i)
1476         https://bugs.webkit.org/show_bug.cgi?id=104220
1477
1478         Reviewed by Adam Barth.
1479
1480         To make an Isolate mandatory in v8Integer(), we implement
1481         deprecatedV8Integer(int i) for call sites that don't have
1482         an Isolate. Eventually we want to kill deprecatedV8Integer(int i).
1483
1484         No new tests. No change in behavior.
1485
1486         * bindings/v8/Dictionary.cpp:
1487         (WebCore::Dictionary::get):
1488         * bindings/v8/NPV8Object.cpp:
1489         (_NPN_Enumerate):
1490         * bindings/v8/PageScriptDebugServer.cpp:
1491         (WebCore::PageScriptDebugServer::addListener):
1492         * bindings/v8/ScriptDebugServer.cpp:
1493         (WebCore::ScriptDebugServer::setBreakpoint):
1494         (WebCore::ScriptDebugServer::compileScript):
1495         * bindings/v8/ScriptSourceCode.cpp:
1496         (WebCore::ScriptSourceCode::compileScript):
1497         * bindings/v8/V8Binding.h:
1498         (WebCore):
1499         (WebCore::deprecatedV8Integer):
1500         * bindings/v8/V8DOMConfiguration.cpp:
1501         (WebCore::V8DOMConfiguration::batchConfigureConstants):
1502         * bindings/v8/V8NPUtils.cpp:
1503         (WebCore::convertNPVariantToV8Object):
1504         * bindings/v8/V8Utilities.cpp:
1505         (WebCore::createHiddenDependency):
1506         (WebCore::removeHiddenDependency):
1507         * bindings/v8/V8WindowErrorHandler.cpp:
1508         (WebCore::V8WindowErrorHandler::callListenerFunction):
1509         * bindings/v8/V8WorkerContextErrorHandler.cpp:
1510         (WebCore::V8WorkerContextErrorHandler::callListenerFunction):
1511         * bindings/v8/WorkerScriptDebugServer.cpp:
1512         (WebCore::WorkerScriptDebugServer::addListener):
1513         * bindings/v8/custom/V8MutationCallbackCustom.cpp:
1514         (WebCore::V8MutationCallback::handleEvent):
1515
1516 2012-12-06  Hayato Ito  <hayato@chromium.org>
1517
1518         Event's relatedTarget re-targeting does not occur for manually fired mouse events created by event.initMouseEvent().
1519         https://bugs.webkit.org/show_bug.cgi?id=102681
1520
1521         Reviewed by Dimitri Glazkov.
1522
1523         Make sure that event's relatedTarget re-targeting occurs for mouse
1524         events created by event.initMouseEvent().  Since user-generated
1525         mouse events can have a relatedTarget which is same to the target
1526         node, the algorithm which calculates event's ancestors is also
1527         updated so that ancestors are not shrunk wrongly.
1528
1529         Test: fast/events/dispatch-synthetic-mouseevent.html
1530               fast/dom/shadow/shadow-dom-event-dispatching.html
1531
1532         * dom/EventDispatcher.cpp:
1533         (WebCore::EventRelatedTargetAdjuster::adjust):
1534         * dom/MouseEvent.cpp:
1535         (WebCore::MouseEventDispatchMediator::create):
1536         (WebCore::MouseEventDispatchMediator::MouseEventDispatchMediator):
1537         (WebCore::MouseEventDispatchMediator::dispatchEvent):
1538         * dom/MouseEvent.h:
1539         (WebCore::MouseEventDispatchMediator::isSyntheticMouseEvent):
1540         (MouseEventDispatchMediator):
1541         * dom/Node.cpp:
1542         (WebCore::Node::dispatchEvent):
1543
1544 2012-12-06  Michael Pruett  <michael@68k.org>
1545
1546         [JSC] Check whether property is an array before attempting conversion to array in JSDictionary
1547         https://bugs.webkit.org/show_bug.cgi?id=96614
1548
1549         Reviewed by Kentaro Hara.
1550
1551         JSDictionary should check whether the property being accessed in get()
1552         is an array before attempting to convert the value to an array.
1553
1554         Previously calling get() with a result type of Vector<String> when
1555         the named property could not be converted to an array would generate
1556         an exception.
1557
1558         Tests: storage/indexeddb/*
1559
1560         * bindings/js/JSDictionary.cpp:
1561         (WebCore::JSDictionary::convertValue):
1562         * bindings/js/JSDictionary.h:
1563         (WebCore::JSDictionary::tryGetPropertyAndResult):
1564
1565 2012-12-05  Kentaro Hara  <haraken@chromium.org>
1566
1567         [V8] Pass Isolate to toDOMStringList()
1568         https://bugs.webkit.org/show_bug.cgi?id=104224
1569
1570         Reviewed by Adam Barth.
1571
1572         No tests. No change in behavior.
1573
1574         * bindings/scripts/CodeGeneratorV8.pm:
1575         (JSValueToNative):
1576         * bindings/scripts/test/V8/V8TestObj.cpp:
1577         (WebCore::TestObjV8Internal::overloadedMethod6Callback):
1578         (WebCore::TestObjV8Internal::overloadedMethod7Callback):
1579         (WebCore::TestObjV8Internal::overloadedMethod9Callback):
1580         (WebCore::TestObjV8Internal::stringArrayFunctionCallback):
1581         * bindings/v8/V8Binding.cpp:
1582         (WebCore::toDOMStringList):
1583         * bindings/v8/V8Binding.h:
1584         (WebCore):
1585
1586 2012-12-06  Kentaro Hara  <haraken@chromium.org>
1587
1588         Remove JSDependentRetained.h and V8DependentRetained.h
1589         https://bugs.webkit.org/show_bug.cgi?id=104232
1590
1591         Reviewed by Adam Barth.
1592
1593         Although (JS|V8)DependentRetained.h were introduced for MutationObservers,
1594         they are not going to be used (See the discussion in bug 95519).
1595         We can remove them.
1596
1597         No tests. No change in behavior.
1598
1599         * GNUmakefile.list.am:
1600         * WebCore.gypi:
1601         * WebCore.vcproj/WebCore.vcproj:
1602         * WebCore.xcodeproj/project.pbxproj:
1603         * bindings/js/JSDependentRetained.h: Removed.
1604         * bindings/v8/V8DependentRetained.h: Removed.
1605         * bindings/v8/V8PerIsolateData.cpp:
1606         (WebCore::V8PerIsolateData::V8PerIsolateData):
1607         * bindings/v8/V8PerIsolateData.h:
1608         (V8PerIsolateData):
1609
1610 2012-12-06  Kentaro Hara  <haraken@chromium.org>
1611
1612         [V8] Replace v8String("symbol") with v8::String::NewSymbol("symbol")
1613         https://bugs.webkit.org/show_bug.cgi?id=104209
1614
1615         Reviewed by Adam Barth.
1616
1617         V8 can look up symbols faster than strings.
1618
1619         No tests. No change in behavior.
1620
1621         * bindings/v8/JavaScriptCallFrame.cpp:
1622         (WebCore::JavaScriptCallFrame::caller):
1623         (WebCore::JavaScriptCallFrame::sourceID):
1624         (WebCore::JavaScriptCallFrame::line):
1625         (WebCore::JavaScriptCallFrame::column):
1626         (WebCore::JavaScriptCallFrame::functionName):
1627         (WebCore::JavaScriptCallFrame::scopeChain):
1628         (WebCore::JavaScriptCallFrame::scopeType):
1629         (WebCore::JavaScriptCallFrame::thisObject):
1630         (WebCore::JavaScriptCallFrame::evaluate):
1631         (WebCore::JavaScriptCallFrame::restart):
1632         * bindings/v8/V8ThrowException.cpp:
1633         (WebCore::domExceptionStackGetter):
1634         (WebCore::domExceptionStackSetter):
1635         (WebCore::V8ThrowException::setDOMException):
1636         * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp:
1637         (WebCore::V8InspectorFrontendHost::platformCallback):
1638         * bindings/v8/custom/V8JavaScriptCallFrameCustom.cpp:
1639         (WebCore::V8JavaScriptCallFrame::typeAccessorGetter):
1640
1641 2012-12-06  Sheriff Bot  <webkit.review.bot@gmail.com>
1642
1643         Unreviewed, rolling out r136784 and r136802.
1644         http://trac.webkit.org/changeset/136784
1645         http://trac.webkit.org/changeset/136802
1646         https://bugs.webkit.org/show_bug.cgi?id=104231
1647
1648         breaks chromium canary (Requested by morrita on #webkit).
1649
1650         * WebCore.gyp/WebCore.gyp:
1651         * WebCore.gypi:
1652         * platform/chromium/PlatformThemeChromiumLinux.cpp: Added.
1653         (WebCore):
1654         (WebCore::PlatformThemeChromiumLinux::setScrollbarColors):
1655         (WebCore::clamp):
1656         (WebCore::PlatformThemeChromiumLinux::saturateAndBrighten):
1657         (WebCore::PlatformThemeChromiumLinux::outlineColor):
1658         (WebCore::PlatformThemeChromiumLinux::paintArrowButton):
1659         * platform/chromium/PlatformThemeChromiumLinux.h: Added.
1660         (WebCore):
1661         (PlatformThemeChromiumLinux):
1662         (WebCore::PlatformThemeChromiumLinux::thumbInactiveColor):
1663         (WebCore::PlatformThemeChromiumLinux::thumbActiveColor):
1664         (WebCore::PlatformThemeChromiumLinux::trackColor):
1665         (WebCore::PlatformThemeChromiumLinux::PlatformThemeChromiumLinux):
1666         * platform/chromium/ScrollbarThemeChromiumLinux.cpp: Added.
1667         (WebCore):
1668         (WebCore::ScrollbarTheme::nativeTheme):
1669         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
1670         (WebCore::ScrollbarThemeChromiumLinux::paintTrackPiece):
1671         (WebCore::ScrollbarThemeChromiumLinux::paintButton):
1672         (WebCore::ScrollbarThemeChromiumLinux::paintThumb):
1673         (WebCore::ScrollbarThemeChromiumLinux::shouldCenterOnThumb):
1674         (WebCore::ScrollbarThemeChromiumLinux::buttonSize):
1675         (WebCore::ScrollbarThemeChromiumLinux::minimumThumbLength):
1676         * platform/chromium/ScrollbarThemeChromiumLinux.h: Added.
1677         (ScrollbarThemeChromiumLinux):
1678         * rendering/RenderThemeChromiumAndroid.cpp:
1679         (WebCore::RenderThemeChromiumAndroid::extraDefaultStyleSheet):
1680         * rendering/RenderThemeChromiumAndroid.h:
1681         * rendering/RenderThemeChromiumLinux.cpp: Added.
1682         (WebCore):
1683         (WebCore::getWebThemeState):
1684         (WebCore::RenderThemeChromiumLinux::create):
1685         (WebCore::RenderTheme::themeForPage):
1686         (WebCore::RenderThemeChromiumLinux::RenderThemeChromiumLinux):
1687         (WebCore::RenderThemeChromiumLinux::~RenderThemeChromiumLinux):
1688         (WebCore::RenderThemeChromiumLinux::systemColor):
1689         (WebCore::RenderThemeChromiumLinux::extraDefaultStyleSheet):
1690         (WebCore::RenderThemeChromiumLinux::controlSupportsTints):
1691         (WebCore::RenderThemeChromiumLinux::activeListBoxSelectionBackgroundColor):
1692         (WebCore::RenderThemeChromiumLinux::activeListBoxSelectionForegroundColor):
1693         (WebCore::RenderThemeChromiumLinux::inactiveListBoxSelectionBackgroundColor):
1694         (WebCore::RenderThemeChromiumLinux::inactiveListBoxSelectionForegroundColor):
1695         (WebCore::RenderThemeChromiumLinux::platformActiveSelectionBackgroundColor):
1696         (WebCore::RenderThemeChromiumLinux::platformInactiveSelectionBackgroundColor):
1697         (WebCore::RenderThemeChromiumLinux::platformActiveSelectionForegroundColor):
1698         (WebCore::RenderThemeChromiumLinux::platformInactiveSelectionForegroundColor):
1699         (WebCore::RenderThemeChromiumLinux::sliderTickSize):
1700         (WebCore::RenderThemeChromiumLinux::sliderTickOffsetFromTrackCenter):
1701         (WebCore::RenderThemeChromiumLinux::adjustSliderThumbSize):
1702         (WebCore::RenderThemeChromiumLinux::supportsControlTints):
1703         (WebCore::RenderThemeChromiumLinux::setCaretBlinkInterval):
1704         (WebCore::RenderThemeChromiumLinux::caretBlinkIntervalInternal):
1705         (WebCore::RenderThemeChromiumLinux::setSelectionColors):
1706         (WebCore::RenderThemeChromiumLinux::paintCheckbox):
1707         (WebCore::RenderThemeChromiumLinux::setCheckboxSize):
1708         (WebCore::RenderThemeChromiumLinux::paintRadio):
1709         (WebCore::RenderThemeChromiumLinux::setRadioSize):
1710         (WebCore::RenderThemeChromiumLinux::paintButton):
1711         (WebCore::RenderThemeChromiumLinux::paintTextField):
1712         (WebCore::RenderThemeChromiumLinux::paintMenuList):
1713         (WebCore::RenderThemeChromiumLinux::paintSliderTrack):
1714         (WebCore::RenderThemeChromiumLinux::paintSliderThumb):
1715         (WebCore::RenderThemeChromiumLinux::adjustInnerSpinButtonStyle):
1716         (WebCore::RenderThemeChromiumLinux::paintInnerSpinButton):
1717         (WebCore::RenderThemeChromiumLinux::paintProgressBar):
1718         (WebCore::RenderThemeChromiumLinux::shouldOpenPickerWithF4Key):
1719         * rendering/RenderThemeChromiumLinux.h: Added.
1720         (WebCore):
1721         (RenderThemeChromiumLinux):
1722
1723 2012-12-05  Sankeerth V S  <sankeerth.vs@samsung.com>
1724
1725         Web Inspector: Title of "Record Timeline" status button on "Timeline
1726         Panel" should reflect the recording state.
1727         https://bugs.webkit.org/show_bug.cgi?id=104108
1728
1729         Reviewed by Alexander Pavlov.
1730
1731         Title should be toggled between "Record"/"Stop" to reflect current
1732         state of the Status bar button.
1733
1734         No new tests as UI related change.
1735
1736         * inspector/front-end/TimelinePanel.js:
1737         (WebInspector.TimelinePanel.prototype.get _toggleTimelineButtonClicked):
1738
1739 2012-12-03  Kent Tamura  <tkent@chromium.org>
1740
1741         INPUT_MULTIPLE_FIELDS_UI doesn't show digits well in RTL locales
1742         https://bugs.webkit.org/show_bug.cgi?id=103869
1743
1744         Reviewed by Hajime Morita.
1745
1746         We need to use display:inline elements to wrap sub-fields and static
1747         text in DateTimeEditElement children to apply the Unicode Bidi
1748         Algorithm.
1749
1750         Because we can't use display:inline-block for them, we can't specify
1751         min-width CSS property for them. We stop using customStyleForRenderer of
1752         sub-fields to specify each of their widths, and use
1753         customStyleForRenderer of DateTimeEditElement to specify the total
1754         required width. A sub-field width shrink and grow so that the width fits
1755         to the field value, and a DateTimeEditElement doesn't.
1756
1757         No new tests. Coverred by existing tests, especially
1758         fast/forms/datetime/datetime-appearance-l10n.html shows "23:59"
1759         correctly.
1760
1761         * css/html.css:
1762         (input::-webkit-datetime-edit-year-field):
1763         - Make this display:inline to apply the Unicode Bidi Algorithm.
1764         - Use padding instead of margin because of ease of width computation.
1765           Also, the focus apparance gets better by padding.
1766         - Don't allow to specify font property here because of ease of width
1767           computation.
1768         - Remove text-align:center. It doesn't work for display:inline.
1769         (input::-webkit-datetime-edit-text):
1770         - Make this display:inline to apply the Unicode Bidi Algorithm.
1771         - Don't allow to specify font property here because of ease of width
1772           computation.
1773
1774         * html/shadow/DateTimeEditElement.h:
1775         (DateTimeEditElement): Declare customStyleForRenderer.
1776         * html/shadow/DateTimeEditElement.cpp:
1777         (WebCore::DateTimeEditElement::DateTimeEditElement):
1778         Enable customStyleForRenderer.
1779         (WebCore::DateTimeEditElement::customStyleForRenderer):
1780         Compute required width with a font for this element and child maximum
1781         widths, and set it to min-width style.
1782         The resultant width value can be inaccurate if a page author specifies
1783         padding, border, margin, etc. to ::-webkit-datetime-edit-*-field or
1784         ::-webkit-datetime-edit-text. In such case, the page author should specify
1785         wider width to <input>.
1786
1787         * dom/Element.h:
1788         (Element): Add isDateTimeFieldElement to do static_cast<DateTimeFieldElement> safely.
1789         * dom/Element.cpp:
1790         (WebCore::Element::isDateTimeFieldElement): Added.
1791
1792         * html/shadow/DateTimeFieldElement.h:
1793         (DateTimeFieldElement): Declare isDateTimeFieldElement and maximumWidth.
1794         * html/shadow/DateTimeFieldElement.cpp:
1795         (WebCore::DateTimeFieldElement::isDateTimeFieldElement):
1796         Added. Returns true.
1797         (WebCore::DateTimeFieldElement::maximumWidth):
1798         Added. Returns padding width.
1799
1800         * html/shadow/DateTimeSymbolicFieldElement.h:
1801         (DateTimeSymbolicFieldElement):
1802         Remove customStyleForRenderer, and declare maximumWidth.
1803         * html/shadow/DateTimeSymbolicFieldElement.cpp:
1804         (WebCore::DateTimeSymbolicFieldElement::DateTimeSymbolicFieldElement):
1805         Disable customStyleForRenderer.
1806         (WebCore::DateTimeSymbolicFieldElement::maximumWidth):
1807         Added. Returns the expected maximum width with the specified font.
1808
1809         * html/shadow/DateTimeNumericFieldElement.h:
1810         (DateTimeNumericFieldElement):
1811         Remove customStyleForRenderer, declare maximumWidth, and make m_placeholder
1812         non-const because it is updated in the constructor.
1813         * html/shadow/DateTimeNumericFieldElement.cpp:
1814         (WebCore::DateTimeNumericFieldElement::DateTimeNumericFieldElement):
1815         Disable customStyleForRenderer.
1816         If a numeric value for this field is LTR and the whole direction is RTL,
1817         wrap the placeholder string with left-to-right-mark and
1818         right-to-left-mark so that it is handled as LTR. Without this,
1819         sub-fields order would be changed when the content of a field is changed
1820         from a placeholder to a numeric value.
1821         (WebCore::DateTimeNumericFieldElement::maximumWidth):
1822         Added. Returns the expected maximum width with the specified font.
1823
1824 2012-12-05  Kent Tamura  <tkent@chromium.org>
1825
1826         INPUT_MULTIPLE_FIELDS_UI: The hour, am/pm, millisecond fields should support read-only state correctly
1827         https://bugs.webkit.org/show_bug.cgi?id=104210
1828
1829         Reviewed by Kentaro Hara.
1830
1831         1. The hour, am/pm, and millisecond fields should have CSS rules for
1832            [readonly]. They should be gray when they are read-only.
1833         2. The am/pm field should reject to set an empty value like other
1834            numeric fields do.
1835
1836         Tests: Add test cases to fast/forms/time/time-appearance-basic.html.
1837
1838         * css/html.css: merge existing readonly rules, and add ampm, hour, and
1839         millisecond pseudo classes.
1840         * html/shadow/DateTimeSymbolicFieldElement.cpp:
1841         (WebCore::DateTimeSymbolicFieldElement::setEmptyValue):
1842         Reject to set empty value if it is read-only.
1843
1844 2012-12-05  Dan Beam  <dbeam@chromium.org>
1845
1846         HTMLFormElement#requestAutocomplete() should require a user action
1847         https://bugs.webkit.org/show_bug.cgi?id=102320
1848
1849         Reviewed by Kent Tamura.
1850
1851         This patch dispatches an autocompleteerror when HTMLFormElement::requestAutocomplete() is called while not processing
1852         a user gesture.
1853
1854         * fast/forms/form-request-autocomplete.html is updated.
1855
1856         * html/HTMLFormElement.cpp:
1857         (WebCore::HTMLFormElement::requestAutocomplete):
1858
1859         Asynchronously dispatch an autocomplete error when not processing a user action when
1860         HTMLFormElement#requestAutocomplete() is invoked.
1861
1862 2012-12-05  Kentaro Hara  <haraken@chromium.org>
1863
1864         [V8] Optimize v8StringOrNull() and v8StringOrUndefined()
1865         https://bugs.webkit.org/show_bug.cgi?id=104206
1866
1867         Reviewed by Adam Barth.
1868
1869         Currently v8StringOrNull() and v8StringOrUndefined() are checking
1870         a null string twice. It is redundant.
1871
1872         [div.localName]
1873         Before this patch: 20.03 ns
1874         After this patch:  19.34 ns
1875
1876         * bindings/v8/V8Binding.h:
1877         (WebCore::v8StringOrNull):
1878         (WebCore::v8StringOrUndefined):
1879
1880 2012-12-05  Kentaro Hara  <haraken@chromium.org>
1881
1882         [V8] Optimize v8String() for uninitialized DOM attributes
1883         https://bugs.webkit.org/show_bug.cgi?id=104205
1884
1885         Reviewed by Adam Barth.
1886
1887         This patch makes uninitialized div.lang, div.title etc 6.3% faster.
1888
1889         [div.lang]
1890         Before this patch: 12.6 ns
1891         After this patch:  11.8 ns
1892
1893         * bindings/v8/V8Binding.h:
1894         (WebCore::v8String):
1895
1896 2012-12-05  Kentaro Hara  <haraken@chromium.org>
1897
1898         [V8] Remove addImplicitReferencesForNodeWithEventListeners()
1899         https://bugs.webkit.org/show_bug.cgi?id=104203
1900
1901         Reviewed by Adam Barth.
1902
1903         We can use opaqueRootForGC() instead. By this change, we can remove
1904         all AddImplicitReferences() from V8 bindings.
1905
1906         Tests: fast/dom/gc-image-element.html
1907                fast/dom/gc-image-element-2.html
1908                fast/dom/inline-event-attributes-lookup-removed.html
1909
1910         * bindings/v8/V8GCController.cpp:
1911
1912 2012-12-05  Andrei Bucur  <abucur@adobe.com>
1913
1914         [CSS Regions] Blocks don't relayout children if the width of a region changes
1915         https://bugs.webkit.org/show_bug.cgi?id=103993
1916
1917         Reviewed by David Hyatt.
1918
1919         After r135750 lines are no longer invalidating when regions change width. This is happening because the detection for the width change was being done
1920         only at line layout time. This patch moves the line relayout decision to the containing block by setting the relayoutChildren flag if the block
1921         has no region chain attached.
1922
1923         Tests: fast/regions/region-width-change-relayout-1.html
1924                fast/regions/region-width-change-relayout-2.html
1925                fast/regions/region-width-change-relayout-3.html
1926
1927         * rendering/RenderFlowThread.cpp:
1928         (WebCore::RenderFlowThread::logicalWidthChangedInRegions):
1929
1930 2012-12-05  Kihong Kwon  <kihong.kwon@samsung.com>
1931
1932         Parameter event need to covert to RefPtr in the DeviceController::dispatchDeviceEvent
1933         https://bugs.webkit.org/show_bug.cgi?id=104201
1934
1935         Reviewed by Laszlo Gombos.
1936
1937         Parameter 'event' need to covert to RefPtr in the DeviceController::dispatchDeviceEvent.
1938         This can make crash sometimes.
1939
1940         No new tests. Covered by existing layout tests.
1941
1942         * page/DeviceController.cpp:
1943         (WebCore::DeviceController::dispatchDeviceEvent):
1944
1945 2012-12-05  Halton Huo  <halton.huo@intel.com>
1946
1947         [CMake] Unify coding style for CMake files
1948         https://bugs.webkit.org/show_bug.cgi?id=103605
1949
1950         Reviewed by Laszlo Gombos.
1951
1952         Update cmake files(.cmake, CMakeLists.txt) with following style rules:
1953         1. Indentation
1954         1.1 Use spaces, not tabs.
1955         1.2 Four spaces as indent.
1956         2. Spacing
1957         2.1 Place one space between control statements and their parentheses.
1958             For eg, if (), else (), elseif (), endif (), foreach (),
1959             endforeach (), while (), endwhile (), break ().
1960         2.2 Do not place spaces between function and macro statements and
1961             their parentheses. For eg, macro(), endmacro(), function(),
1962             endfunction().
1963         2.3 Do not place spaces between a command or function or macro and its
1964             parentheses, or between a parenthesis and its content. For eg,
1965             message("testing") not message( "testing") or message ("testing" )
1966         2.4 No space at line ending.
1967         3. Lowercase when call commands macros and functions. For eg,
1968            add_executable() not ADD_EXECUTABLE(), set() not SET().
1969
1970         * CMakeLists.txt:
1971         * PlatformBlackBerry.cmake:
1972         * PlatformEfl.cmake:
1973         * PlatformWinCE.cmake:
1974         * UseJSC.cmake:
1975         * UseV8.cmake:
1976
1977 2012-12-05  Kentaro Hara  <haraken@chromium.org>
1978
1979         [V8] Remove unused property names from V8HiddenPropertyName
1980         https://bugs.webkit.org/show_bug.cgi?id=104194
1981
1982         Reviewed by Adam Barth.
1983
1984         We can remove unused property names from V8HiddenPropertyName.
1985
1986         No tests. No change in behavior.
1987
1988         * bindings/v8/V8HiddenPropertyName.h:
1989         (WebCore):
1990
1991 2012-12-05  Greg Billock  <gbillock@google.com>
1992
1993         Add runtime enable for web intents.
1994         https://bugs.webkit.org/show_bug.cgi?id=103669
1995
1996         Reviewed by Adam Barth.
1997
1998         Make web intents Javascript API enabled by a runtime setting.
1999
2000         * Modules/intents/DOMWindowIntents.idl:
2001         * Modules/intents/NavigatorIntents.idl:
2002         * bindings/generic/RuntimeEnabledFeatures.cpp:
2003         (WebCore):
2004         * bindings/generic/RuntimeEnabledFeatures.h:
2005         (RuntimeEnabledFeatures):
2006         (WebCore::RuntimeEnabledFeatures::webkitStartActivityEnabled):
2007         (WebCore::RuntimeEnabledFeatures::webkitIntentEnabled):
2008         (WebCore::RuntimeEnabledFeatures::webKitIntentEnabled):
2009         (WebCore::RuntimeEnabledFeatures::setWebIntentsEnabled):
2010
2011 2012-12-05  Scott Violet  <sky@chromium.org>
2012
2013         [chromium] Remove linux theme related files and switch to default
2014         https://bugs.webkit.org/show_bug.cgi?id=103897
2015
2016         Reviewed by Tony Chang.
2017
2018         Linux related theme files are now named Default.
2019
2020         No new tests, code cleanup.
2021
2022         * WebCore.gyp/WebCore.gyp: Update files
2023         * WebCore.gypi: Update files
2024         * platform/chromium/PlatformThemeChromiumLinux.cpp: Removed.
2025         * platform/chromium/PlatformThemeChromiumLinux.h: Removed.
2026         * platform/chromium/ScrollbarThemeChromiumLinux.cpp: Removed.
2027         * platform/chromium/ScrollbarThemeChromiumLinux.h: Removed.
2028         * rendering/RenderThemeChromiumAndroid.cpp:
2029         (WebCore::RenderThemeChromiumAndroid::extraDefaultStyleSheet): Linux->Default
2030         * rendering/RenderThemeChromiumAndroid.h: Change superclass
2031         * rendering/RenderThemeChromiumLinux.cpp: Removed.
2032         * rendering/RenderThemeChromiumLinux.h: Removed.
2033
2034 2012-12-05  Joshua Bell  <jsbell@chromium.org>
2035
2036         IndexedDB: Allow multiple transactions to interleave request execution
2037         https://bugs.webkit.org/show_bug.cgi?id=97570
2038
2039         Reviewed by Tony Chang.
2040
2041         Implement spec logic for allowing read-only transactions, and read-write transactions
2042         with non-overlapping scopes, to run concurrently. Transactions all still run in the
2043         same thread with tasks triggered via timers, so tasks and the underlying database
2044         operations are interleaved rather than truly parallelized.
2045
2046         Within IDBTransactionCoordinator, rename started->queued, running->started to match
2047         spec terminology and clear up confusion.
2048
2049         Test: storage/indexeddb/transaction-coordination-across-databases.html
2050               storage/indexeddb/transaction-coordination-within-database.html
2051               storage/indexeddb/transaction-readwrite-exclusive.html
2052               storage/indexeddb/transaction-scope-sequencing.html
2053               storage/indexeddb/transaction-starvation.html
2054
2055         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp: Use IDBTransaction::Mode enum
2056         (WebCore::IDBDatabaseBackendImpl::createTransaction):
2057         * Modules/indexeddb/IDBDatabaseBackendImpl.h: Ditto.
2058         (IDBDatabaseBackendImpl):
2059         * Modules/indexeddb/IDBDatabaseBackendInterface.h: Ditto.
2060         (IDBDatabaseBackendInterface):
2061         * Modules/indexeddb/IDBTransactionBackendImpl.cpp: Convert scope as a HashSet for
2062         fast intersecting.
2063         (WebCore::IDBTransactionBackendImpl::create):
2064         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
2065         * Modules/indexeddb/IDBTransactionBackendImpl.h:
2066         (IDBTransactionBackendImpl):
2067         (WebCore::IDBTransactionBackendImpl::mode):
2068         (WebCore::IDBTransactionBackendImpl::scope):
2069         * Modules/indexeddb/IDBTransactionCoordinator.cpp: Spec logic goes here.
2070         (WebCore::IDBTransactionCoordinator::processStartedTransactions): Extend this
2071         method to test all plausibly runnable transactions.
2072         (WebCore):
2073         (WebCore::IDBTransactionCoordinator::canRunTransaction): Test to see if one
2074         particular transaction can be run.
2075         (WebCore::IDBTransactionCoordinator::doScopesOverlap): Do a quick intersection
2076         test between transaction scopes.
2077         * Modules/indexeddb/IDBTransactionCoordinator.h:
2078         (IDBTransactionCoordinator):
2079
2080 2012-12-05  No'am Rosenthal  <noam@webkit.org>
2081
2082         Coordinated Graphics: Enable support for setContentsToBackgroundColor
2083         https://bugs.webkit.org/show_bug.cgi?id=104128
2084
2085         Reviewed by Kenneth Rohde Christiansen.
2086
2087         Enable background color in GraphicsLayerTextureMapper, and paint it using TextureMapper::drawSolidColor.
2088         Once https://bugs.webkit.org/show_bug.cgi?id=103786 is enabled, this would enable Qt/GTK/EFL to directly
2089         composite colors that only have a background color, without having to create a backing store for them.
2090         This would eliminate the memory usage for those layers, reduce the time needed for them to draw into the
2091         backing store and upload the texture, and in the future allow direct compositing of things other than
2092         background colors.
2093
2094         Compositing tests cover this, but are still skipped for ports using coordinated graphics. 
2095         See https://bugs.webkit.org/show_bug.cgi?id=104129.
2096
2097         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
2098         (WebCore::GraphicsLayerTextureMapper::setContentsToBackgroundColor):
2099         (WebCore::GraphicsLayerTextureMapper::backgroundColor):
2100             Maintain a backgroundColor member variable in GraphicsLayerTextureMapper
2101
2102         * platform/graphics/texmap/TextureMapperGL.cpp:
2103         (WebCore::TextureMapperGL::drawSolidColor):
2104             TextureMapperGL::drawSolidColor should allow blending when the solid color has alpha.
2105
2106         * platform/graphics/texmap/TextureMapperLayer.cpp:
2107         (WebCore::TextureMapperLayer::paintSelf):
2108         (WebCore::TextureMapperLayer::flushCompositingStateSelf):
2109         * platform/graphics/texmap/TextureMapperLayer.h:
2110         (State):
2111
2112 2012-12-05  Kentaro Hara  <haraken@chromium.org>
2113
2114         Unreviewed, rolling out r136481.
2115         http://trac.webkit.org/changeset/136481
2116         https://bugs.webkit.org/show_bug.cgi?id=103868
2117
2118         it might have regressed dom_perf/CloneNodes (See bug 104177)
2119
2120         * dom/ContainerNodeAlgorithms.h:
2121         (ChildNodeInsertionNotifier):
2122         (WebCore::ChildNodeInsertionNotifier::notifyNodeInsertedIntoDocument):
2123         (WebCore::ChildNodeInsertionNotifier::notifyNodeInsertedIntoTree):
2124         (WebCore::ChildNodeInsertionNotifier::notify):
2125
2126 2012-12-05  David Grogan  <dgrogan@chromium.org>
2127
2128         IndexedDB: Abort transactions because of leveldb errors part 3
2129         https://bugs.webkit.org/show_bug.cgi?id=103960
2130
2131         Reviewed by Tony Chang.
2132
2133         Transactions are aborted when there are leveldb problems creating
2134         indexes on an object store with existing data or when adding data to an
2135         objectstore that has indexes.
2136
2137         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
2138         (WebCore):
2139         (WebCore::makeIndexWriters):
2140         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
2141         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreStorageOperation::perform):
2142
2143 2012-12-05  Simon Fraser  <simon.fraser@apple.com>
2144
2145         Fix some repaint/paintCounter confusion, and reset it when getting layers out of the layer pool
2146         https://bugs.webkit.org/show_bug.cgi?id=104180
2147
2148         Reviewed by Tim Horton.
2149
2150         Layers retrieved from the LayerPool by TileCache need to have their
2151         repaint counters reset, otherwise the scroll performance logging gets
2152         confused.
2153         
2154         Also, the counter counts paints, not repaints (invalidations), so
2155         rename it accordingly.
2156
2157         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
2158         (WebCore::ScrollingTreeScrollingNodeMac::logExposedUnfilledArea): Whitespace fix.
2159         * platform/graphics/GraphicsLayer.h:
2160         * platform/graphics/ca/mac/TileCache.mm:
2161         (WebCore::TileCache::blankPixelCountForTiles):
2162         (WebCore::TileCache::createTileLayer):
2163         (WebCore::TileCache::drawRepaintCounter):
2164         * platform/graphics/ca/mac/WebTileLayer.h:
2165         * platform/graphics/ca/mac/WebTileLayer.mm:
2166         (-[WebTileLayer resetPaintCount]):
2167         (-[WebTileLayer incrementPaintCount]):
2168         (-[WebTileLayer paintCount]):
2169         (-[WebTileLayer logFilledFreshTile]):
2170
2171 2012-12-05  Oliver Hunt  <oliver@apple.com>
2172
2173         Empty parse cache when receiving a low memory warning
2174         https://bugs.webkit.org/show_bug.cgi?id=104161
2175
2176         Reviewed by Filip Pizlo.
2177
2178         Use new discardAllCode() function on the global data, rather than
2179         directly interacting with the heap.
2180
2181         * bindings/js/GCController.cpp:
2182         (WebCore::GCController::discardAllCompiledCode):
2183
2184 2012-12-05  Dan Bernstein  <mitz@apple.com>
2185
2186         Text decorations are rotated when text-combine takes effect
2187         https://bugs.webkit.org/show_bug.cgi?id=104172
2188
2189         Reviewed by Dave Hyatt.
2190
2191         Test: fast/text/decorations-with-text-combine.html
2192
2193         * rendering/InlineTextBox.cpp:
2194         (WebCore::InlineTextBox::paint): Applied a rotation to the graphics context when painting
2195         the text decorations for combined text.
2196
2197 2012-12-05  Justin Novosad  <junov@google.com>
2198
2199         [skia] Improve performance of GraphicsContext::createCompatibleBuffer by using SkDevice:createCompatibleDevice
2200         https://bugs.webkit.org/show_bug.cgi?id=103896
2201
2202         Reviewed by Stephen White.
2203
2204         Refactored GraphicsContext::createCompatibleBuffer (platform common
2205         code) to use platform-specific implementations provided by ImageBuffer.
2206         There is no change in behavior for non-skia ports. The skia
2207         implementation uses skia'a own createCompatibleDevice implementation,
2208         which offers several performance benefits:
2209         1. For accelerated contexts, the backing store may be allocated from
2210         the scratch texture pool, which minimizes texture allocation and
2211         deallocation overhead.
2212         2. The backing store will not be initially cleared if it is known
2213         in advance that fully opaque contents will be drawn into the buffer.
2214         3. For non-accelerated contexts, if the backing store is flagged as
2215         opaque, faster blitter loop implementations will be used for drawing
2216         the buffer contents into other buffers. (e.g. generated opaque gradient
2217         fills)
2218
2219         No new tests: covered by existing layout tests 
2220
2221         * platform/graphics/Generator.h:
2222         (Generator):
2223         Added hasAlpha method so that it can be used by GeneratorGeneratedImage
2224         * platform/graphics/GeneratorGeneratedImage.cpp:
2225         (WebCore::GeneratorGeneratedImage::drawPattern):
2226         Passing m_generator->hasAlpha() to createCompatibleBuffer in order to
2227         take advantage of optimizations that apply to opaque buffers.
2228         * platform/graphics/Gradient.h:
2229         (Gradient):
2230         Made hasAlpha virtual so that it now overrides Generator::hasAlpha
2231         * platform/graphics/GraphicsContext.cpp:
2232         (WebCore::GraphicsContext::createCompatibleBuffer):
2233         Refactored to use platform-specific implementation
2234         * platform/graphics/GraphicsContext.h:
2235         * platform/graphics/ImageBuffer.cpp:
2236         (WebCore::createCompatibleBuffer):
2237         Non-skia implementation. Mimics old
2238         GraphicsContext::createCompatibleBuffer
2239         * platform/graphics/ImageBuffer.h:
2240         (ImageBuffer):
2241         New skia-specific constructor
2242         * platform/graphics/skia/ImageBufferSkia.cpp:
2243         (WebCore::ImageBuffer::createCompatibleBuffer):
2244         (WebCore::ImageBuffer::ImageBuffer):
2245         * platform/graphics/skia/PlatformContextSkia.cpp:
2246         (WebCore::PlatformContextSkia::createCompatibleDevice):
2247         (WebCore):
2248         * platform/graphics/skia/PlatformContextSkia.h:
2249         (PlatformContextSkia):
2250
2251 2012-12-05  Alexis Menard  <alexis@webkit.org>
2252
2253         REGRESSION (r136683): css3/calc/background-position-parsing.html failing on EFL Linux 64-bit Debug WK2
2254         https://bugs.webkit.org/show_bug.cgi?id=104131
2255
2256         Reviewed by Antti Koivisto.
2257
2258         css3/calc/background-position-parsing.html assert in debug because we
2259         call CSSParser::validUnit multiple times in a row. The problem was with
2260         validUnit which check calc() values and save the result inside
2261         m_parsedCalculation for later usage. validUnit expects you to
2262         use m_parsedCalculation therefore calling validUnit again with
2263         m_parsedCalculation being set asserts. As parseFillBackgroundPosition
2264         just want to check wether the current value is maybe valid for
2265         background-position we can just relax the check to allow either the
2266         valid keywords or any other units (we will anyway filter the incorrect
2267         values later in the parsing). The most important check at this point
2268         for the shorthand is the validity of the keyword.
2269
2270         No new tests : the assert was covered by css3/calc/background-position-parsing.html.
2271
2272         * css/CSSParser.cpp:
2273         (WebCore::CSSParser::isPotentialPositionValue):
2274         (WebCore::CSSParser::parseFillBackgroundPosition):
2275         * css/CSSParser.h:
2276
2277 2012-12-05  Stephen White  <senorblanco@chromium.org>
2278
2279         Unreviewed, rolling out r136735.
2280         http://trac.webkit.org/changeset/136735
2281         https://bugs.webkit.org/show_bug.cgi?id=102699
2282
2283         Broke Chrome/Win build.
2284
2285         * platform/chromium/PlatformSupport.h:
2286         (PlatformSupport):
2287         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
2288         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
2289         (WebCore::ScrollbarThemeChromiumWin::paintButton):
2290         (WebCore::ScrollbarThemeChromiumWin::paintThumb):
2291         * rendering/RenderThemeChromiumWin.cpp:
2292         (WebCore):
2293         (WebCore::RenderThemeChromiumWin::paintButton):
2294         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
2295         (WebCore::RenderThemeChromiumWin::paintSliderThumb):
2296         (WebCore::RenderThemeChromiumWin::paintMenuList):
2297         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
2298         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
2299         (WebCore::RenderThemeChromiumWin::paintProgressBar):
2300
2301 2012-12-05  Jun Jiang  <jun.a.jiang@intel.com>
2302
2303         WebGL: use pointer to the source data for Image directly in texImage2D and texSubImage2D to avoid memory copy if no conversion is needed
2304         https://bugs.webkit.org/show_bug.cgi?id=103885
2305
2306         Reviewed by Kenneth Russell.
2307
2308         In texImage2D() and texSubImage2D(), there is a redundant memory copy from Image data to the intermediate vector when no conversion is needed. If the Image resource can be locked properly, it is better to use the pointer to the image source directly and hence avoid the memory copy and improve the performance. 
2309
2310         Already covered by current tests.
2311
2312         * html/canvas/WebGLRenderingContext.cpp:
2313         (WebCore):
2314         (WebCore::WebGLRenderingContext::texImage2DBase):
2315         (WebCore::WebGLRenderingContext::texImage2DImpl):
2316         (WebCore::WebGLRenderingContext::texSubImage2DBase):
2317         (WebCore::WebGLRenderingContext::texSubImage2DImpl):
2318         * html/canvas/WebGLRenderingContext.h:
2319         (WebGLRenderingContext):
2320         * platform/graphics/GraphicsContext3D.h:
2321         (ImageExtractor):
2322
2323 2012-12-05  Elliott Sprehn  <esprehn@chromium.org>
2324
2325         Add infrastructure for :before and :after in DOM
2326         https://bugs.webkit.org/show_bug.cgi?id=103705
2327
2328         Reviewed by Eric Seidel.
2329
2330         Add all infrastructure for reimplementing generated content :before and
2331         :after as DOM Elements. Now ElementRareData has two pointers to PseudoElements
2332         for the generated content and Node has methods for traversing the tree
2333         including generated content.
2334
2335         This will allow the generated content to be treated as real nodes instead
2336         of anonymous and take part in the usual recalcStyle and attach flow which
2337         fixes many bugs and vastly simplifies the ifecycle of generated content.
2338
2339         Instead of attempting to land both the infrastructure and enable it at
2340         the same time which has proven problematic due to how drastic this change
2341         is, this patch contains only the support code so a much smaller future
2342         patch can be used to switch it on.
2343
2344         No new behavior, this is just the infrastructure.
2345
2346         * CMakeLists.txt:
2347         * GNUmakefile.list.am:
2348         * Target.pri:
2349         * WebCore.gypi:
2350         * WebCore.vcproj/WebCore.vcproj:
2351         * WebCore.xcodeproj/project.pbxproj:
2352         * dom/DOMAllInOne.cpp:
2353         * dom/Element.cpp:
2354         (WebCore::Element::~Element):
2355         (WebCore::Element::detach):
2356         (WebCore::Element::updatePseudoElement):
2357         (WebCore::Element::createPseudoElementIfNeeded):
2358         (WebCore::Element::beforePseudoElement):
2359         (WebCore::Element::afterPseudoElement):
2360         * dom/Element.h:
2361         (Element):
2362         * dom/ElementRareData.h:
2363         (ElementRareData):
2364         (WebCore::ElementRareData::ElementRareData):
2365         (WebCore::ElementRareData::~ElementRareData):
2366         (WebCore::ElementRareData::setPseudoElement):
2367         (WebCore::ElementRareData::pseudoElement):
2368         (WebCore::ElementRareData::releasePseudoElement):
2369         * dom/Node.cpp:
2370         (WebCore::Node::pseudoAwarePreviousSibling):
2371         (WebCore::Node::pseudoAwareNextSibling):
2372         (WebCore::Node::rendererIsEditable):
2373         (WebCore::checkAcceptChild):
2374         * dom/Node.h:
2375         (Node):
2376         (WebCore::Node::isPseudoElement):
2377         (WebCore::Node::isBeforePseudoElement):
2378         (WebCore::Node::isAfterPseudoElement):
2379         (WebCore::Node::pseudoId):
2380         (WebCore::Node::customPseudoId):
2381         * dom/NodeRenderingContext.cpp:
2382         (WebCore::NodeRenderingContext::nextRenderer):
2383         (WebCore::NodeRenderingContext::previousRenderer):
2384         * dom/Position.cpp:
2385         (WebCore::Position::hasRenderedNonAnonymousDescendantsWithHeight):
2386         * dom/PseudoElement.cpp: Added.
2387         (WebCore::pseudoElementTagName):
2388         (WebCore::PseudoElement::PseudoElement):
2389         (WebCore::PseudoElement::customStyleForRenderer):
2390         (WebCore::PseudoElement::attach):
2391         (WebCore::PseudoElement::rendererIsNeeded):
2392         (WebCore::PseudoElement::updateChildStyle):
2393         (WebCore::PseudoElement::didRecalcStyle):
2394         * dom/PseudoElement.h: Added.
2395         (PseudoElement):
2396         (WebCore::PseudoElement::create):
2397         (WebCore::pseudoElementIsNeeded):
2398         * editing/visible_units.cpp:
2399         (WebCore::logicallyPreviousBox):
2400         (WebCore::logicallyNextBox):
2401         (WebCore::startPositionForLine):
2402         (WebCore::endPositionForLine):
2403         * page/animation/AnimationController.cpp:
2404         (WebCore::AnimationController::updateAnimations):
2405         * rendering/HitTestResult.cpp:
2406         (WebCore::HitTestResult::setInnerNode):
2407         (WebCore::HitTestResult::setInnerNonSharedNode):
2408         * rendering/RenderBlock.cpp:
2409         (WebCore::RenderBlock::isSelectionRoot):
2410         (WebCore::RenderBlock::renderName):
2411         * rendering/RenderCounter.cpp:
2412         (WebCore::RenderCounter::originalText):
2413         * rendering/RenderDeprecatedFlexibleBox.cpp:
2414         (WebCore::RenderDeprecatedFlexibleBox::renderName):
2415         * rendering/RenderInline.cpp:
2416         (WebCore::RenderInline::renderName):
2417         * rendering/RenderMultiColumnBlock.cpp:
2418         (WebCore::RenderMultiColumnBlock::renderName):
2419         * rendering/RenderObject.cpp:
2420         (WebCore::RenderObject::createObject):
2421         (WebCore::RenderObject::setPseudoStyle):
2422         (WebCore::RenderObject::createVisiblePosition):
2423         * rendering/RenderObject.h:
2424         (WebCore::RenderObject::isPseudoElement):
2425         (RenderObject):
2426         (WebCore::RenderObject::generatingNode):
2427         * rendering/RenderTableCell.h:
2428         (WebCore::RenderTableCell::renderName):
2429         * rendering/RenderTableRow.h:
2430         (WebCore::RenderTableRow::renderName):
2431         * rendering/RenderTableSection.h:
2432         (WebCore::RenderTableSection::renderName):
2433         * rendering/RenderTreeAsText.cpp:
2434         (WebCore::RenderTreeAsText::writeRenderObject):
2435         * rendering/style/ContentData.cpp:
2436         (WebCore::ImageContentData::createRenderer):
2437         (WebCore::TextContentData::createRenderer):
2438         (WebCore::CounterContentData::createRenderer):
2439         (WebCore::QuoteContentData::createRenderer):
2440
2441 2012-12-05  Justin Novosad  <junov@google.com>
2442
2443         Use of uninitialized variable in WebCore::RenderBox::paintFillLayers
2444         https://bugs.webkit.org/show_bug.cgi?id=104154
2445
2446         Reviewed by Stephen White.
2447
2448         Method FillLayer::clipOccludesNextLayers performs an internal
2449         initialization when called on the first layer of a list of layers.
2450         Without this initialization, calls to clipOccludesNextLayers on
2451         subsequent layers will use uninitialized data.  In some cases, the
2452         call to clipOccludesNextLayers was being short-circuited in
2453         RenderBox::paintFillLayers. 
2454         Fix: Predicate was permuted to ensure that clipOccludesNextLayers
2455         is never short-circuited.
2456         
2457         Test: fast/backgrounds/size/contain-and-cover-zoomed.html
2458         Running with valgrind reveals the error.
2459
2460         * rendering/RenderBox.cpp:
2461         (WebCore::RenderBox::paintFillLayers):
2462
2463 2012-12-05  Elliott Sprehn  <esprehn@gmail.com>
2464
2465         Encapsulate ElementRareData for possible future sharing
2466         https://bugs.webkit.org/show_bug.cgi?id=103948
2467
2468         Reviewed by Eric Seidel.
2469
2470         Encapsulate ElementRareData and make all access go through getters and
2471         setters. This is already true for NodeRareData, but ElementRareData
2472         had many places where people directly access it.
2473
2474         This the first step in possible future sharing of ElementRareData
2475         instances across nodes. All nodes in a shadow tree have rare data to
2476         store the TreeScope, but in most cases all they have is the TreeScope!
2477         Instead of making every node in a shadow subtree have rare data
2478         and use lots of memory we could just share a single instance of rare data
2479         and only allocate a unique one on modification. Encapsulation lets us
2480         assert about mutations on shared instances.
2481
2482         * dom/Element.cpp:
2483         (WebCore::Element::~Element):
2484         (WebCore::Element::attributes):
2485         (WebCore::Element::shadow):
2486         (WebCore::Element::ensureShadow):
2487         (WebCore::Element::minimumSizeForResizing):
2488         (WebCore::Element::setMinimumSizeForResizing):
2489         (WebCore::Element::computedStyle):
2490         (WebCore::Element::classList):
2491         (WebCore::Element::optionalClassList):
2492         (WebCore::Element::dataset):
2493         (WebCore::Element::hasNamedNodeMap):
2494         (WebCore::Element::savedLayerScrollOffset):
2495         (WebCore::Element::setSavedLayerScrollOffset):
2496         * dom/ElementRareData.cpp:
2497         (WebCore::ElementRareData::reportMemoryUsage):
2498         * dom/ElementRareData.h:
2499         (WebCore::ElementRareData::needsFocusAppearanceUpdateSoonAfterAttach):
2500         (WebCore::ElementRareData::setNeedsFocusAppearanceUpdateSoonAfterAttach):
2501         (ElementRareData):
2502         (WebCore::ElementRareData::styleAffectedByEmpty):
2503         (WebCore::ElementRareData::setStyleAffectedByEmpty):
2504         (WebCore::ElementRareData::isInCanvasSubtree):
2505         (WebCore::ElementRareData::setIsInCanvasSubtree):
2506         (WebCore::ElementRareData::containsFullScreenElement):
2507         (WebCore::ElementRareData::setContainsFullScreenElement):
2508         (WebCore::ElementRareData::isInTopLayer):
2509         (WebCore::ElementRareData::setIsInTopLayer):
2510         (WebCore::ElementRareData::childrenAffectedByHover):
2511         (WebCore::ElementRareData::setChildrenAffectedByHover):
2512         (WebCore::ElementRareData::childrenAffectedByActive):
2513         (WebCore::ElementRareData::setChildrenAffectedByActive):
2514         (WebCore::ElementRareData::childrenAffectedByDrag):
2515         (WebCore::ElementRareData::setChildrenAffectedByDrag):
2516         (WebCore::ElementRareData::childrenAffectedByFirstChildRules):
2517         (WebCore::ElementRareData::setChildrenAffectedByFirstChildRules):
2518         (WebCore::ElementRareData::childrenAffectedByLastChildRules):
2519         (WebCore::ElementRareData::setChildrenAffectedByLastChildRules):
2520         (WebCore::ElementRareData::childrenAffectedByDirectAdjacentRules):
2521         (WebCore::ElementRareData::setChildrenAffectedByDirectAdjacentRules):
2522         (WebCore::ElementRareData::childrenAffectedByForwardPositionalRules):
2523         (WebCore::ElementRareData::setChildrenAffectedByForwardPositionalRules):
2524         (WebCore::ElementRareData::childrenAffectedByBackwardPositionalRules):
2525         (WebCore::ElementRareData::setChildrenAffectedByBackwardPositionalRules):
2526         (WebCore::ElementRareData::childIndex):
2527         (WebCore::ElementRareData::setChildIndex):
2528         (WebCore::ElementRareData::shadow):
2529         (WebCore::ElementRareData::setShadow):
2530         (WebCore::ElementRareData::attributeMap):
2531         (WebCore::ElementRareData::setAttributeMap):
2532         (WebCore::ElementRareData::computedStyle):
2533         (WebCore::ElementRareData::setComputedStyle):
2534         (WebCore::ElementRareData::classList):
2535         (WebCore::ElementRareData::setClassList):
2536         (WebCore::ElementRareData::dataset):
2537         (WebCore::ElementRareData::setDataset):
2538         (WebCore::ElementRareData::minimumSizeForResizing):
2539         (WebCore::ElementRareData::setMinimumSizeForResizing):
2540         (WebCore::ElementRareData::savedLayerScrollOffset):
2541         (WebCore::ElementRareData::setSavedLayerScrollOffset):
2542         (WebCore::ElementRareData::resetComputedStyle):
2543         * dom/NodeRareData.h:
2544         (NodeRareData):
2545
2546 2012-12-05  Mark Pilgrim  <pilgrim@chromium.org>
2547
2548         [Chromium][Win] Remove theme-related functions from PlatformSupport
2549         https://bugs.webkit.org/show_bug.cgi?id=102699
2550
2551         Reviewed by Adam Barth.
2552
2553         Call theme engine directly instead of going through
2554         PlatformSupport. Part of a refactoring series. See tracking bug 82948.
2555
2556         * platform/chromium/PlatformSupport.h:
2557         (PlatformSupport):
2558         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
2559         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
2560         (WebCore::ScrollbarThemeChromiumWin::paintButton):
2561         * rendering/RenderThemeChromiumWin.cpp:
2562         (WebCore):
2563         (WebCore::RenderThemeChromiumWin::paintButton):
2564         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
2565         (WebCore::RenderThemeChromiumWin::paintSliderThumb):
2566         (WebCore::RenderThemeChromiumWin::paintMenuList):
2567         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
2568         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
2569         (WebCore::RenderThemeChromiumWin::paintProgressBar):
2570
2571 2012-12-05  Stephen White  <senorblanco@chromium.org>
2572
2573         Unreviewed, rolling out r136609.
2574         http://trac.webkit.org/changeset/136609
2575         https://bugs.webkit.org/show_bug.cgi?id=103793
2576
2577         Breaking Chrome/Mac Debug builds.
2578
2579         * html/canvas/WebGLRenderingContext.cpp:
2580         (WebCore):
2581         (WebCore::WebGLRenderingContext::create):
2582         * platform/chromium/support/GraphicsContext3DChromium.cpp:
2583         (WebCore::GraphicsContext3D::create):
2584         * platform/graphics/GraphicsContext3D.h:
2585         (Attributes):
2586
2587 2012-12-05  Bear Travis  <betravis@adobe.com>
2588
2589         [CSS Exclusions] Enable shape-inside for multiple-segment polygons
2590         https://bugs.webkit.org/show_bug.cgi?id=91878
2591
2592         Reviewed by David Hyatt.
2593
2594         Patch adding support for multiple-segment polygons for shape-insides from
2595         the CSS Exclusions specification. The layout code has been modified to first
2596         support dividing text into multiple segments per line, and then to lay out
2597         multiple segments per line box.
2598
2599         Tests:  fast/exclusions/shape-inside/shape-inside-multiple-segments-001.html
2600                 fast/exclusions/shape-inside/shape-inside-multiple-segments-002.html
2601                 fast/exclusions/shape-inside/shape-inside-multiple-segments-003.html
2602                 fast/exclusions/shape-inside/shape-inside-multiple-segments-004.html
2603
2604         * platform/text/BidiResolver.h:
2605         (WebCore::BidiCharacterRun::BidiCharacterRun):
2606         (BidiCharacterRun): Added a 'startsSegment' bitfield to track whether a
2607         run begins a new segment. The field is here, rather than in BidiRun, in
2608         order to save space. See Bug 100173.
2609         * rendering/BidiRun.h:
2610         (WebCore::BidiRun::BidiRun):
2611         (BidiRun): Set the initial value for 'startsSegment'.
2612         * rendering/ExclusionShapeInsideInfo.cpp:
2613         (WebCore::ExclusionShapeInsideInfo::computeSegmentsForLine): Clear the
2614         segment ranges when computing segments for a new line.
2615         * rendering/ExclusionShapeInsideInfo.h:
2616         (LineSegmentRange): Added a new type to track segment offsets.
2617         (WebCore::ExclusionShapeInsideInfo::segmentRanges): Added a getter for
2618         the line segment ranges vector.
2619         * rendering/InlineFlowBox.cpp:
2620         (WebCore::InlineFlowBox::placeBoxesInInlineDirection): Modified to call
2621         a refactored box placement algorithm that takes a beginning and end position.
2622         (WebCore::InlineFlowBox::placeBoxRangeInInlineDirection): Similar to the
2623         placeBoxes method, but takes an end position that may occur before the end
2624         of the line.
2625         * rendering/RenderBlock.cpp:
2626         (WebCore::RenderBlock::exclusionShapeInsideInfo): Factored out calls
2627         to ExclusionShapeInsideInfo to the .cpp file, as ExclusionShapeInsideInfo
2628         requires InlineIterator.h, which would create a circular dependency in
2629         ExclusionShapeInsideInfo.h.
2630         * rendering/RenderBlock.h:
2631         (WebCore::RenderBlock::exclusionShapeInsideInfo): Modified to call
2632         exclusionShapeInsideInfo to be non-inline.
2633         * rendering/RenderBlockLineLayout.cpp:
2634         (WebCore::LineWidth::LineWidth): LineWidth now uses the number of computed
2635         segmentRanges to determine which LineSegment to use when calculating width.
2636         (WebCore::RenderBlock::createLineBoxes): Now takes a boolean to determine
2637         whether or not it can share the same parentBox as its siblings (segments
2638         must be able to position themselves separately in the RootInlineBox).
2639         (WebCore::RenderBlock::constructLine):
2640         (WebCore::computeExpansionForJustifiedText): Do include runs that start new
2641         segments when calculating justification for the current segment.
2642         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Modified to
2643         use the computeInlineDirectionPositionsForSegment, which can position
2644         multiple segments of text per line.
2645         (WebCore::RenderBlock::computeInlineDirectionPositionsForSegment): Positions
2646         the given segment of text and calculates its layout offsets.
2647         (WebCore::constructBidiRuns): Modified some variables from 'endOfLine' to 'endOfSegment'.
2648         (WebCore::constructBidiRunsForLine): Construct the bidi runs for each segment in
2649         the given line.
2650         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Call constructBidiRunsForLine.
2651         (WebCore::RenderBlock::LineBreaker::nextLineBreak): Moved the line breaking code
2652         to break segments, with nextLineBreak iterating over segment breaks for the entire line.
2653         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak): Calculates how much text a
2654         segment can hold. This code was originally in nextLineBreak.
2655
2656 2012-12-05  Stephen White  <senorblanco@chromium.org>
2657
2658         Unreviewed, rolling out r136630.
2659         http://trac.webkit.org/changeset/136630
2660         https://bugs.webkit.org/show_bug.cgi?id=103555
2661
2662         It's breaking Chrome/Win Debug builds.
2663
2664         * platform/graphics/chromium/LazyDecodingPixelRef.cpp:
2665         (WebCore::LazyDecodingPixelRef::LazyDecodingPixelRef):
2666         * platform/graphics/chromium/LazyDecodingPixelRef.h:
2667         (LazyDecodingPixelRef):
2668
2669 2012-12-05  Andreas Kling  <akling@apple.com>
2670
2671         REGRESSION(r136615): Incorrect style sharing in view-source documents.
2672         <http://webkit.org/b/104089>
2673
2674         Reviewed by Antti Koivisto.
2675
2676         Make sure we collect feature data about the default view-source style sheet before evaluating
2677         style sharing candidates, otherwise it won't know which class selectors to care about.
2678
2679         * css/StyleResolver.cpp:
2680         (WebCore::StyleResolver::collectFeatures):
2681
2682 2012-12-05  Mike West  <mkwst@chromium.org>
2683
2684         Stop generating call stacks inside ContentSecurityPolicy
2685         https://bugs.webkit.org/show_bug.cgi?id=104126
2686
2687         Reviewed by Yury Semikhatsky.
2688
2689         Now that bug 100650 has made it possible for ConsoleMessage to generate
2690         call stacks, we can remove the stack being generated in
2691         ContentSecurityPolicy::logToConsole. We need the ScriptState*, however,
2692         so this patch makes it possible to pipe it through addConsoleMessage
2693         down into the guts of the inspector.
2694
2695         This patch also removes an unused addConsoleMessage variant from
2696         ScriptExecutionContext, which should have been removed from the patch to
2697         100650 before landing it. My bad.
2698
2699         * dom/Document.cpp:
2700         (WebCore::Document::addMessage):
2701         * dom/Document.h:
2702         (Document):
2703             Accept a ScriptState* parameter in Document::addMessage, and pass it
2704             through to Console::addMessage.
2705         * dom/ScriptExecutionContext.cpp:
2706         (WebCore::ScriptExecutionContext::addConsoleMessage):
2707         * dom/ScriptExecutionContext.h:
2708         (ScriptExecutionContext):
2709             Accept a ScriptState* parameter in Document::addMessage, and pass it
2710             through to ScriptExecutionContext::addMessage. Also, remove an unused
2711             variant of ScriptExecutionContext::addConsoleMessage that accepted
2712             only a call stack in addition to the basics.
2713         * inspector/ConsoleMessage.cpp:
2714         (WebCore::ConsoleMessage::ConsoleMessage):
2715         * inspector/ConsoleMessage.h:
2716         (ConsoleMessage):
2717             Accept a ScriptState* and pass it into autogenerateMetadata for
2718             call stack generational goodness.
2719         * inspector/InspectorConsoleAgent.cpp:
2720         (WebCore::InspectorConsoleAgent::addMessageToConsole):
2721             Accept a ScriptState* and pass it into addConsoleMessage.
2722         (WebCore::InspectorConsoleAgent::didFinishXHRLoading):
2723         (WebCore::InspectorConsoleAgent::didReceiveResponse):
2724         (WebCore::InspectorConsoleAgent::didFailLoading):
2725             Add an empty ScriptState parameter to the addConsoleMessage call.
2726         * inspector/InspectorConsoleAgent.h:
2727         (InspectorConsoleAgent):
2728         * inspector/InspectorConsoleInstrumentation.h:
2729         (WebCore::InspectorInstrumentation::addMessageToConsole):
2730         * inspector/InspectorInstrumentation.cpp:
2731         (WebCore):
2732         (WebCore::InspectorInstrumentation::addMessageToConsoleImpl):
2733         * inspector/InspectorInstrumentation.h:
2734         (InspectorInstrumentation):
2735         * page/Console.cpp:
2736         (WebCore::Console::addMessage):
2737         * page/Console.h:
2738         (Console):
2739             Pipe ScriptState through the intermediate classes.
2740         * page/ContentSecurityPolicy.cpp:
2741         (WebCore::ContentSecurityPolicy::logToConsole):
2742             Drop call stack generation, and pass ScriptState* into addConsoleMessage.
2743         * workers/WorkerContext.cpp:
2744         (WebCore::WorkerContext::addConsoleMessage):
2745         (WebCore::WorkerContext::addMessage):
2746         (WebCore::WorkerContext::addMessageToWorkerConsole):
2747         * workers/WorkerContext.h:
2748         (WorkerContext):
2749             Accept ScriptState* and pass it into addMessageToConsole.
2750
2751 2012-12-05  Rafael Weinstein  <rafaelw@chromium.org>
2752
2753         DOMImplementation.createDocument should call appendChild rather than parserAppendChild to add docType and documentElement
2754         https://bugs.webkit.org/show_bug.cgi?id=104040
2755
2756         Reviewed by Ojan Vafai.
2757
2758         createDocument now calls appendChild.
2759
2760         No new tests (no observable changes).
2761
2762         * dom/ContainerNode.cpp:
2763         (WebCore::ContainerNode::parserAppendChild):
2764         * dom/DOMImplementation.cpp:
2765         (WebCore::DOMImplementation::createDocument):
2766
2767 2012-12-05  Alec Flett  <alecflett@chromium.org>
2768
2769         IndexedDB: Stub out transaction-backend methods
2770         https://bugs.webkit.org/show_bug.cgi?id=103921
2771
2772         Reviewed by Dimitri Glazkov.
2773
2774         In preparation for a refactoring. Legacy methods 
2775         will be removed in https://bugs.webkit.org/show_bug.cgi?id=103923.
2776
2777         No new tests, just adding unused methods for refactoring.
2778
2779         * Modules/indexeddb/IDBCallbacks.h:
2780         (WebCore::IDBCallbacks::onUpgradeNeeded):
2781         * Modules/indexeddb/IDBDatabase.cpp:
2782         (WebCore::IDBDatabase::onAbort):
2783         (WebCore):
2784         (WebCore::IDBDatabase::onComplete):
2785         * Modules/indexeddb/IDBDatabase.h:
2786         (IDBDatabase):
2787         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
2788         (WebCore::IDBDatabaseBackendImpl::createTransaction):
2789         (WebCore):
2790         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
2791         (IDBDatabaseBackendImpl):
2792         (WebCore::IDBDatabaseBackendImpl::commit):
2793         (WebCore::IDBDatabaseBackendImpl::abort):
2794         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
2795         (IDBDatabaseBackendInterface):
2796         * Modules/indexeddb/IDBDatabaseCallbacks.h:
2797         (IDBDatabaseCallbacks):
2798         * Modules/indexeddb/IDBDatabaseCallbacksImpl.cpp:
2799         (WebCore::IDBDatabaseCallbacksImpl::onAbort):
2800         (WebCore):
2801         (WebCore::IDBDatabaseCallbacksImpl::onComplete):
2802         * Modules/indexeddb/IDBDatabaseCallbacksImpl.h:
2803         (IDBDatabaseCallbacksImpl):
2804         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
2805         (WebCore::IDBFactoryBackendImpl::open):
2806         * Modules/indexeddb/IDBFactoryBackendImpl.h:
2807         (WebCore::IDBFactoryBackendImpl::open):
2808         (IDBFactoryBackendImpl):
2809         * Modules/indexeddb/IDBFactoryBackendInterface.h:
2810         (IDBFactoryBackendInterface):
2811         * Modules/indexeddb/IDBOpenDBRequest.cpp:
2812         (WebCore::IDBOpenDBRequest::onUpgradeNeeded):
2813         (WebCore):
2814         * Modules/indexeddb/IDBOpenDBRequest.h:
2815         (IDBOpenDBRequest):
2816         * Modules/indexeddb/IDBTransactionBackendInterface.h:
2817         (WebCore):
2818         * Modules/indexeddb/IDBTransactionCoordinator.h:
2819
2820 2012-11-27  Alec Flett  <alecflett@chromium.org>
2821
2822         IndexedDB: remove IDBDatabaseBackendInterface::transaction()
2823         https://bugs.webkit.org/show_bug.cgi?id=102733
2824
2825         Reviewed by Darin Fisher.
2826
2827         Part 3 of a refactor, remove the old transaction() method.
2828
2829         No new tests as this is just post-refactor cleanup.
2830
2831         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
2832         (IDBDatabaseBackendInterface):
2833
2834 2012-12-05  Robert Hogan  <robert@webkit.org>
2835
2836         REGRESSION(r126683): Table cell are getting borders when the style doesn't mention any
2837         https://bugs.webkit.org/show_bug.cgi?id=101677
2838
2839         Reviewed by Julien Chaffraix.
2840
2841         The bordercolor attribute on a cell or row has no effect on FF and Opera, even when the parent
2842         table has a border attribute. IE displays the bordercolor of the cell and row in all cases except when
2843         the parent has no border attribute. WebKit's old behaviour (before r126683) was to display the
2844         bordercolor of the row but not the cells (I don't think this behaviour was particularly deliberate). No
2845         browser displays the bordercolor for a col or tbody element.
2846
2847         Bring WebKit into line with Opera and FF by ignoring the bordercolor attribute on cells, rows, cols, rowgroups, and
2848         colgroups in all cases, regardless of whether the table has a border or not.
2849
2850         Test: fast/table/td-bordercolor-attribute.html
2851
2852         * html/HTMLTablePartElement.cpp:
2853         (WebCore::HTMLTablePartElement::isPresentationAttribute):
2854         (WebCore::HTMLTablePartElement::collectStyleForPresentationAttribute):
2855
2856 2012-12-05  Krzysztof Czech  <k.czech@samsung.com>
2857
2858         [EFL][WK2] Introduce WebKit-EFL to Assistive Technologies
2859         https://bugs.webkit.org/show_bug.cgi?id=104000
2860
2861         Reviewed by Chris Fleizach.
2862
2863         Introduce Webkit-EFL so that Assistive Technologies can distinguish it.
2864
2865         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
2866         (webkitAccessibleGetAttributes):
2867
2868 2012-12-05  Carlos Garcia Campos  <cgarcia@igalia.com>
2869
2870         Remove unneeded WTF prefix from WTF types in RenderFlexibleBox
2871         https://bugs.webkit.org/show_bug.cgi?id=104109
2872
2873         Reviewed by Eric Seidel.
2874
2875         WTF prefix is not needed because WTF headers have a using
2876         statement at the end of the file.
2877
2878         * rendering/RenderFlexibleBox.cpp:
2879         (WebCore::RenderFlexibleBox::layoutBlock):
2880         (WebCore::RenderFlexibleBox::repositionLogicalHeightDependentFlexItems):
2881         (WebCore::RenderFlexibleBox::layoutFlexItems):
2882         (WebCore::RenderFlexibleBox::freezeViolations):
2883         (WebCore::RenderFlexibleBox::resolveFlexibleLengths):
2884         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
2885         (WebCore::RenderFlexibleBox::alignFlexLines):
2886         (WebCore::RenderFlexibleBox::alignChildren):
2887         (WebCore::RenderFlexibleBox::flipForWrapReverse):
2888         * rendering/RenderFlexibleBox.h:
2889
2890 2012-12-05  Andras Becsi  <andras.becsi@digia.com>
2891
2892         Fix compilation for Qt5.0.0 stable branch.
2893         https://bugs.webkit.org/show_bug.cgi?id=103870
2894
2895         Reviewed by Simon Hausmann.
2896
2897         This is a squashed patch consisting of patches by multiple authors.
2898
2899         Fixed use of to-be-removed compatibility functions in QWindow
2900         Patch by Samuel Rødal <samuel.rodal@digia.com>
2901
2902         Build fix. No new tests needed.
2903
2904         * platform/graphics/gstreamer/PlatformVideoWindowQt.cpp:
2905         (FullScreenVideoWindow::FullScreenVideoWindow):
2906         (PlatformVideoWindow::PlatformVideoWindow):
2907
2908 2012-12-05  John J. Barton  <johnjbarton@chromium.org>
2909
2910         Web Inspector: more robust treeoutline.findTreeElement
2911         https://bugs.webkit.org/show_bug.cgi?id=103911
2912
2913         Reviewed by Vsevolod Vlasov.
2914
2915         Non-recursive algorithm to populate the treeoutline given an DOMNode
2916         as representedObject. Walk up the parents from the desired object
2917         until we find one that is currently represented in the treeoutline 
2918         cache. Then walk down, putting children in the cache until we get 
2919         to the desired object again. 
2920         With Pavel Feldeman <pfeldman@chromium.org>
2921
2922         No new tests, refactoring, no new function
2923
2924        * inspector/front-end/treeoutline.js:
2925         (TreeOutline.prototype.findTreeElement):
2926
2927 2012-12-05  Alexander Shalamov  <alexander.shalamov@intel.com>
2928
2929         [EFL][GTK] List value response headers are not handled in RespourceResponse (libsoup specific)
2930         https://bugs.webkit.org/show_bug.cgi?id=95181
2931
2932         Reviewed by Martin Robinson.
2933
2934         When list-value response headers are received, they are handled as single
2935         value headers. This patch fixes incorrect behavior. New test was added to
2936         verify list-value header handling.
2937
2938         Test: http/tests/xmlhttprequest/xmlhttprequest-test-custom-headers.html
2939
2940         * platform/network/soup/ResourceResponseSoup.cpp:
2941         (WebCore::ResourceResponse::updateFromSoupMessage):
2942
2943 2012-12-05  Pavel Feldman  <pfeldman@chromium.org>
2944
2945         Web Inspector: Don't include error message text in the editor buffer.
2946         https://bugs.webkit.org/show_bug.cgi?id=103932
2947
2948         Reviewed by Alexander Pavlov.
2949
2950         Skip entire decoration content when collecting dirty regions.
2951         
2952         * inspector/front-end/DefaultTextEditor.js:
2953         (WebInspector.TextEditorMainPanel.prototype._collectLinesFromDOM):
2954
2955 2012-12-05  Joshua Bell  <jsbell@chromium.org>
2956
2957         IndexedDB: Replace use of ScriptExecutionContext::Task (Part 2)
2958         https://bugs.webkit.org/show_bug.cgi?id=103931
2959
2960         Reviewed by Tony Chang.
2961
2962         Actually drop use of ScriptExecutionContext::Task and remove incorrect usage of
2963         ThreadSafeRefCounted<>. Define a new IDBTransactionBackendImpl::Operation base class
2964         for operations; storage of per-operation data becomes explicit.
2965
2966         No new tests - just a refactor.
2967
2968         * Modules/indexeddb/IDBCallbacks.h: Remove bogus "ThreadSafe"
2969         * Modules/indexeddb/IDBCursorBackendImpl.cpp:
2970         (WebCore::IDBCursorBackendImpl::CursorIterationOperation::create):
2971         (IDBCursorBackendImpl::CursorIterationOperation):
2972         (WebCore::IDBCursorBackendImpl::CursorIterationOperation::CursorIterationOperation):
2973         (WebCore::IDBCursorBackendImpl::CursorAdvanceOperation::create):
2974         (IDBCursorBackendImpl::CursorAdvanceOperation):
2975         (WebCore::IDBCursorBackendImpl::CursorAdvanceOperation::CursorAdvanceOperation):
2976         (WebCore::IDBCursorBackendImpl::CursorPrefetchIterationOperation::create):
2977         (IDBCursorBackendImpl::CursorPrefetchIterationOperation):
2978         (WebCore::IDBCursorBackendImpl::CursorPrefetchIterationOperation::CursorPrefetchIterationOperation):
2979         (WebCore::IDBCursorBackendImpl::CursorAdvanceOperation::perform):
2980         (WebCore::IDBCursorBackendImpl::CursorIterationOperation::perform):
2981         (WebCore::IDBCursorBackendImpl::CursorPrefetchIterationOperation::perform):
2982         * Modules/indexeddb/IDBCursorBackendInterface.h: Remove bogus "ThreadSafe"
2983         * Modules/indexeddb/IDBDatabase.cpp:
2984         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
2985         (WebCore::IDBDatabaseBackendImpl::CreateObjectStoreOperation::create):
2986         (IDBDatabaseBackendImpl::CreateObjectStoreOperation):
2987         (WebCore::IDBDatabaseBackendImpl::CreateObjectStoreOperation::CreateObjectStoreOperation):
2988         (WebCore::IDBDatabaseBackendImpl::DeleteObjectStoreOperation::create):
2989         (IDBDatabaseBackendImpl::DeleteObjectStoreOperation):
2990         (WebCore::IDBDatabaseBackendImpl::DeleteObjectStoreOperation::DeleteObjectStoreOperation):
2991         (WebCore::IDBDatabaseBackendImpl::VersionChangeOperation::create):
2992         (IDBDatabaseBackendImpl::VersionChangeOperation):
2993         (WebCore::IDBDatabaseBackendImpl::VersionChangeOperation::VersionChangeOperation):
2994         (WebCore::IDBDatabaseBackendImpl::CreateObjectStoreAbortOperation::create):
2995         (IDBDatabaseBackendImpl::CreateObjectStoreAbortOperation):
2996         (WebCore::IDBDatabaseBackendImpl::CreateObjectStoreAbortOperation::CreateObjectStoreAbortOperation):
2997         (WebCore::IDBDatabaseBackendImpl::DeleteObjectStoreAbortOperation::create):
2998         (IDBDatabaseBackendImpl::DeleteObjectStoreAbortOperation):
2999         (WebCore::IDBDatabaseBackendImpl::DeleteObjectStoreAbortOperation::DeleteObjectStoreAbortOperation):
3000         (WebCore::IDBDatabaseBackendImpl::VersionChangeAbortOperation::create):
3001         (IDBDatabaseBackendImpl::VersionChangeAbortOperation):
3002         (WebCore::IDBDatabaseBackendImpl::VersionChangeAbortOperation::VersionChangeAbortOperation):
3003         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
3004         (WebCore::IDBDatabaseBackendImpl::CreateObjectStoreOperation::perform):
3005         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
3006         (WebCore::IDBDatabaseBackendImpl::DeleteObjectStoreOperation::perform):
3007         (WebCore::IDBDatabaseBackendImpl::VersionChangeOperation::perform):
3008         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
3009         (WebCore::IDBDatabaseBackendImpl::CreateObjectStoreAbortOperation::perform):
3010         (WebCore::IDBDatabaseBackendImpl::DeleteObjectStoreAbortOperation::perform):
3011         (WebCore::IDBDatabaseBackendImpl::VersionChangeAbortOperation::perform):
3012         * Modules/indexeddb/IDBDatabaseBackendInterface.h: Remove bogus "ThreadSafe"
3013         * Modules/indexeddb/IDBDatabaseCallbacks.h: Remove bogus "ThreadSafe"
3014         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
3015         * Modules/indexeddb/IDBFactoryBackendInterface.h: Remove bogus "ThreadSafe"
3016         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
3017         (WebCore::IDBIndexBackendImpl::OpenIndexCursorOperation::create):
3018         (IDBIndexBackendImpl::OpenIndexCursorOperation):
3019         (WebCore::IDBIndexBackendImpl::OpenIndexCursorOperation::OpenIndexCursorOperation):
3020         (WebCore::IDBIndexBackendImpl::IndexCountOperation::create):
3021         (IDBIndexBackendImpl::IndexCountOperation):
3022         (WebCore::IDBIndexBackendImpl::IndexCountOperation::IndexCountOperation):
3023         (WebCore::IDBIndexBackendImpl::IndexReferencedValueRetrievalOperation::create):
3024         (IDBIndexBackendImpl::IndexReferencedValueRetrievalOperation):
3025         (WebCore::IDBIndexBackendImpl::IndexReferencedValueRetrievalOperation::IndexReferencedValueRetrievalOperation):
3026         (WebCore::IDBIndexBackendImpl::IndexValueRetrievalOperation::create):
3027         (IDBIndexBackendImpl::IndexValueRetrievalOperation):
3028         (WebCore::IDBIndexBackendImpl::IndexValueRetrievalOperation::IndexValueRetrievalOperation):
3029         (WebCore::IDBIndexBackendImpl::OpenIndexCursorOperation::perform):
3030         (WebCore::IDBIndexBackendImpl::openCursor):
3031         (WebCore::IDBIndexBackendImpl::openKeyCursor):
3032         (WebCore::IDBIndexBackendImpl::IndexCountOperation::perform):
3033         (WebCore::IDBIndexBackendImpl::count):
3034         (WebCore::IDBIndexBackendImpl::IndexReferencedValueRetrievalOperation::perform):
3035         (WebCore::IDBIndexBackendImpl::IndexValueRetrievalOperation::perform):
3036         (WebCore::IDBIndexBackendImpl::get):
3037         (WebCore::IDBIndexBackendImpl::getKey):
3038         * Modules/indexeddb/IDBIndexBackendInterface.h: Remove bogus "ThreadSafe"
3039         * Modules/indexeddb/IDBKey.h: Remove bogus "ThreadSafe"
3040         (IDBKey):
3041         * Modules/indexeddb/IDBKeyRange.h: Remove bogus "ThreadSafe"
3042         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
3043         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreRetrievalOperation::create):
3044         (IDBObjectStoreBackendImpl::ObjectStoreRetrievalOperation):
3045         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreRetrievalOperation::ObjectStoreRetrievalOperation):
3046         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreStorageOperation::create):
3047         (IDBObjectStoreBackendImpl::ObjectStoreStorageOperation):
3048         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreStorageOperation::ObjectStoreStorageOperation):
3049         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreIndexesReadyOperation::create):
3050         (IDBObjectStoreBackendImpl::ObjectStoreIndexesReadyOperation):
3051         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreIndexesReadyOperation::ObjectStoreIndexesReadyOperation):
3052         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreDeletionOperation::create):
3053         (IDBObjectStoreBackendImpl::ObjectStoreDeletionOperation):
3054         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreDeletionOperation::ObjectStoreDeletionOperation):
3055         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreClearOperation::create):
3056         (IDBObjectStoreBackendImpl::ObjectStoreClearOperation):
3057         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreClearOperation::ObjectStoreClearOperation):
3058         (WebCore::IDBObjectStoreBackendImpl::CreateIndexOperation::create):
3059         (IDBObjectStoreBackendImpl::CreateIndexOperation):
3060         (WebCore::IDBObjectStoreBackendImpl::CreateIndexOperation::CreateIndexOperation):
3061         (WebCore::IDBObjectStoreBackendImpl::DeleteIndexOperation::create):
3062         (IDBObjectStoreBackendImpl::DeleteIndexOperation):
3063         (WebCore::IDBObjectStoreBackendImpl::DeleteIndexOperation::DeleteIndexOperation):
3064         (WebCore::IDBObjectStoreBackendImpl::OpenObjectStoreCursorOperation::create):
3065         (IDBObjectStoreBackendImpl::OpenObjectStoreCursorOperation):
3066         (WebCore::IDBObjectStoreBackendImpl::OpenObjectStoreCursorOperation::OpenObjectStoreCursorOperation):
3067         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreCountOperation::create):
3068         (IDBObjectStoreBackendImpl::ObjectStoreCountOperation):
3069         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreCountOperation::ObjectStoreCountOperation):
3070         (WebCore::IDBObjectStoreBackendImpl::CreateIndexAbortOperation::create):
3071         (IDBObjectStoreBackendImpl::CreateIndexAbortOperation):
3072         (WebCore::IDBObjectStoreBackendImpl::CreateIndexAbortOperation::CreateIndexAbortOperation):
3073         (WebCore::IDBObjectStoreBackendImpl::DeleteIndexAbortOperation::create):
3074         (IDBObjectStoreBackendImpl::DeleteIndexAbortOperation):
3075         (WebCore::IDBObjectStoreBackendImpl::DeleteIndexAbortOperation::DeleteIndexAbortOperation):
3076         (WebCore::IDBObjectStoreBackendImpl::get):
3077         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreRetrievalOperation::perform):
3078         (WebCore::IDBObjectStoreBackendImpl::put):
3079         (WebCore):
3080         (WebCore::IDBObjectStoreBackendImpl::setIndexesReady):
3081         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreIndexesReadyOperation::perform):
3082         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreStorageOperation::perform):
3083         (WebCore::IDBObjectStoreBackendImpl::deleteFunction):
3084         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreDeletionOperation::perform):
3085         (WebCore::IDBObjectStoreBackendImpl::clear):
3086         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreClearOperation::perform):
3087         (WebCore::IDBObjectStoreBackendImpl::createIndex):
3088         (WebCore::IDBObjectStoreBackendImpl::CreateIndexOperation::perform):
3089         (WebCore::IDBObjectStoreBackendImpl::deleteIndex):
3090         (WebCore::IDBObjectStoreBackendImpl::DeleteIndexOperation::perform):
3091         (WebCore::IDBObjectStoreBackendImpl::openCursor):
3092         (WebCore::IDBObjectStoreBackendImpl::OpenObjectStoreCursorOperation::perform):
3093         (WebCore::IDBObjectStoreBackendImpl::count):
3094         (WebCore::IDBObjectStoreBackendImpl::ObjectStoreCountOperation::perform):
3095         (WebCore::IDBObjectStoreBackendImpl::CreateIndexAbortOperation::perform):
3096         (WebCore::IDBObjectStoreBackendImpl::DeleteIndexAbortOperation::perform):
3097         * Modules/indexeddb/IDBObjectStoreBackendInterface.h: Remove bogus "ThreadSafe"
3098         * Modules/indexeddb/IDBRequest.h: Remove bogus "ThreadSafe"
3099         (IDBRequest):
3100         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
3101         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl): Appease RefPtr<> adoption strictness.
3102         (WebCore::IDBTransactionBackendImpl::scheduleTask):
3103         (WebCore::IDBTransactionBackendImpl::abort):
3104         (WebCore::IDBTransactionBackendImpl::taskTimerFired):
3105         * Modules/indexeddb/IDBTransactionBackendImpl.h:
3106         (Operation):
3107         (WebCore::IDBTransactionBackendImpl::Operation::~Operation):
3108         (IDBTransactionBackendImpl):
3109         (WebCore::IDBTransactionBackendImpl::scheduleTask):
3110         * Modules/indexeddb/IDBTransactionBackendInterface.h: Remove bogus "ThreadSafe"
3111
3112 2012-12-05  Noel Gordon  <noel.gordon@gmail.com>
3113
3114         ENABLE(IMAGE_DECODER_DOWN_SAMPLING): Don't swizzle decode down sampled images
3115         https://bugs.webkit.org/show_bug.cgi?id=103856
3116
3117         Reviewed by Yong Li.
3118
3119         For ports using ENABLE(IMAGE_DECODER_DOWN_SAMPLING), turbo swizzle decodes provide
3120         no speed-up when the decoded image will be down sampled because the data must pass
3121         through the buffer.setRGBA() slow path. That is not the swizzled path. Instead use
3122         JCS_RGB decodes to clarify the output color space handling in outputScanlines().
3123
3124         No new tests. Covered by existing JPEG decoding tests.
3125
3126         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
3127         (WebCore::JPEGImageReader::decode): libjpeg-turbo swizzle decodes provides no real
3128         speed-up if the image will be down sampled. Revert to using JCS_RGA in this case.
3129         (WebCore::setPixel): Remove the libjpeg-turbo JCS_EXT_BGRA and JCS_EXT_RGBA cases.
3130         (WebCore::JPEGImageDecoder::outputScanlines): ditto.
3131         * platform/image-decoders/jpeg/JPEGImageDecoder.h:
3132         (WebCore::JPEGImageDecoder::willDownSample): Return true if image down sampling 
3133         will be applied to the decoded image (m_scaled). Note: the willDownSample() return
3134         value is valid only after setSize() has been called: add an ASSERT for that.
3135
3136 2012-12-05  Michael Pruett  <michael@68k.org>
3137
3138         IndexedDB: Implement IndexedDB bindings for JSC
3139         https://bugs.webkit.org/show_bug.cgi?id=103484
3140
3141         Reviewed by Kentaro Hara.
3142
3143         IndexedDB is currently implemented only for V8. This change adds
3144         the bindings necessary for IndexedDB to work with JSC. With this
3145         patch, IndexedDB for JSC passes 112 out of the 196 layout tests in
3146         storage/indexeddb. IndexedDB is still not enabled for any JSC port.
3147
3148         Tests: storage/indexeddb/*
3149
3150         * CMakeLists.txt:
3151         * GNUmakefile.list.am:
3152         * Modules/indexeddb/IDBOpenDBRequest.idl:
3153         * Modules/indexeddb/IDBVersionChangeRequest.idl:
3154         * UseJSC.cmake:
3155         * WebCore.xcodeproj/project.pbxproj:
3156         * bindings/js/DOMRequestState.h: Added to match bindings/v8/DOMRequestState.h.
3157         (WebCore):
3158         (DOMRequestState):
3159         (WebCore::DOMRequestState::DOMRequestState):
3160         (WebCore::DOMRequestState::clear):
3161         (Scope):
3162         (WebCore::DOMRequestState::Scope::Scope):
3163         (WebCore::DOMRequestState::exec):
3164         * bindings/js/IDBBindingUtilities.cpp: Add utility functions matching those in bindings/v8/IDBBindingUtilities.cpp.
3165         (WebCore::get):
3166         (WebCore):
3167         (WebCore::canSet):
3168         (WebCore::set):
3169         (WebCore::createIDBKeyFromValue):
3170         (WebCore::getNthValueOnKeyPath):
3171         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
3172         (WebCore::ensureNthValueOnKeyPath):
3173         (WebCore::canInjectNthValueOnKeyPath):
3174         (WebCore::injectIDBKeyIntoScriptValue):
3175         (WebCore::canInjectIDBKeyIntoScriptValue):
3176         (WebCore::deserializeIDBValue):
3177         (WebCore::idbKeyToScriptValue):
3178         * bindings/js/IDBBindingUtilities.h: Add utility functions matching those in bindings/v8/IDBBindingUtilities.h.
3179         (WebCore):
3180         * bindings/js/JSIDBAnyCustom.cpp:
3181         (WebCore::toJS):
3182         * bindings/js/JSIDBKeyCustom.cpp:
3183         (WebCore::toJS):
3184         * bindings/js/JSIDBVersionChangeRequestCustom.cpp: Removed.
3185
3186 2012-12-05  Antoine Quint  <graouts@apple.com>
3187
3188         TextTrackCue's .endTime property should fire a TypeError when NaN is assigned
3189         https://bugs.webkit.org/show_bug.cgi?id=103413
3190
3191         Reviewed by Eric Carlson.
3192
3193         Check whether the new time passed to setStartTime() and setEndTime() is none of NaN or Infinity,
3194         otherwise throwing a TypeError.
3195         
3196         Thanks to this fix, we're no longer skipping media/track/opera/interfaces/TextTrackCue/endTime.html and
3197         media/track/opera/interfaces/TextTrackCue/startTime.html.
3198
3199         * html/track/TextTrackCue.cpp:
3200         (WebCore::TextTrackCue::setStartTime):
3201         (WebCore::TextTrackCue::setEndTime):
3202         * html/track/TextTrackCue.h:
3203         (TextTrackCue):
3204         * html/track/TextTrackCue.idl:
3205
3206 2012-12-05  Alexis Menard  <alexis@webkit.org>
3207
3208         [CSS3 Backgrounds and Borders] Allow the CSS3 background position offset for background shorthand.
3209         https://bugs.webkit.org/show_bug.cgi?id=104014
3210
3211         Reviewed by Dirk Schulze.
3212
3213         Add the support of the new <position> type if set from within the
3214         background shorthand. The patch just modify the way we count the values
3215         of the current context by checking wether we encounter a comma (it is
3216         then the next background layer), or if we encounter a '/' (which is in the
3217         background shorthand context the background-size) or any value that is
3218         not a valid background-position keyword or length (which means we are
3219         already parsing the next property of the background shorthand).
3220
3221         Tests: LayoutTests/fast/backgrounds/background-position-parsing-2.html
3222         has been modified to cover this use case.
3223
3224         * css/CSSParser.cpp:
3225         (WebCore::CSSParser::isPositionValue):
3226         (WebCore):
3227         (WebCore::CSSParser::parseFillBackgroundPosition):
3228         (WebCore::CSSParser::parseFillProperty):
3229         * css/CSSParser.h:
3230
3231 2012-12-05  Elliott Sprehn  <esprehn@gmail.com>
3232
3233         ShadowRoot should recalcStyle for itself
3234         https://bugs.webkit.org/show_bug.cgi?id=103933
3235
3236         Reviewed by Hajime Morita.
3237
3238         ShadowRoot should support recalcStyle just like Element instead of
3239         having the code inside ElementShadow. This was once the case and
3240         the dead method prototype for recalcShadowTreeStyle is still in
3241         ShadowRoot.h.
3242
3243         No new tests, just refactoring.
3244
3245         * dom/ElementShadow.cpp:
3246         (WebCore::ElementShadow::recalcStyle):
3247         * dom/ShadowRoot.cpp:
3248         (WebCore::ShadowRoot::recalcStyle):
3249         * dom/ShadowRoot.h:
3250
3251 2012-12-05  Keishi Hattori  <keishi@webkit.org>
3252
3253         Fix text direction in datalist popup for time controls
3254         https://bugs.webkit.org/show_bug.cgi?id=103853
3255
3256         Reviewed by Kent Tamura.
3257
3258         The datalist entry value should be displayed with the same text direction as the date/time format.
3259
3260         Tests: platform/chromium/fast/forms/suggestion-picker/datetime-suggestion-picker-appearance-locale-hebrew.html
3261                platform/chromium/fast/forms/suggestion-picker/datetimelocal-suggestion-picker-appearance-locale-hebrew.html
3262                platform/chromium/fast/forms/suggestion-picker/time-suggestion-picker-appearance-locale-hebrew.html
3263
3264         * Resources/pagepopups/calendarPicker.js: Renamed isCalendarRTL to isLocaleRTL.
3265         (CalendarPicker.prototype._layout):
3266         (CalendarPicker.prototype.fixWindowSize):
3267         (DaysTable.prototype._handleKey):
3268         (MonthPickerDaysTable.prototype._handleKey):
3269         (WeekPickerDaysTable.prototype._handleKey):
3270         * Resources/pagepopups/suggestionPicker.css:
3271         (.suggestion-list-entry .title): Title should have the same text direction as the locale.
3272         (.locale-rtl .suggestion-list-entry .title):
3273         * Resources/pagepopups/suggestionPicker.js:
3274         (SuggestionPicker.prototype._layout): Add locale-rtl class if the isLocaleRTL is true.
3275
3276 2012-12-05  Keishi Hattori  <keishi@webkit.org>
3277
3278         Fix flickering when hiding page popup
3279         https://bugs.webkit.org/show_bug.cgi?id=104100
3280
3281         Reviewed by Kent Tamura.
3282
3283         Moving the page popup while hiding was causing flickering in some environments.
3284
3285         No new tests. Can't reproduce in layout test.
3286
3287         * Resources/pagepopups/pickerCommon.js:
3288         (hideWindow): Don't move and just resize.
3289
3290 2012-12-05  Allan Sandfeld Jensen  <allan.jensen@digia.com>
3291
3292         [Qt] Don't rely on QMimeDatabase for essential MIME types
3293         https://bugs.webkit.org/show_bug.cgi?id=103865
3294
3295         Based on patch by Pierre Rossi.
3296         Reviewed by Jocelyn Turcotte.
3297
3298         Extend the short static list to also include MIME types essential to WebKit,
3299         and detect these first before checking the system mimedatabase.
3300
3301         * platform/qt/MIMETypeRegistryQt.cpp:
3302         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
3303         (WebCore::MIMETypeRegistry::getMIMETypeForPath):
3304
3305 2012-12-05  Zoltan Herczeg  <zherczeg@webkit.org>
3306
3307         Optimize ColorMatrix filter
3308         https://bugs.webkit.org/show_bug.cgi?id=103728
3309
3310         Reviewed by Dirk Schulze.
3311
3312         ColorMatrix filter recalculates several constants for
3313         every pixel. It is enough to do these calculations only
3314         once during the initialization. Style issues also fixed.
3315
3316         Existing tests cover this feature.
3317
3318         * platform/graphics/filters/FEColorMatrix.cpp:
3319         (WebCore::matrix):
3320         (WebCore::saturateAndHueRotate):
3321         (WebCore::effectType):
3322
3323 2012-12-05  Carlos Garcia Campos  <cgarcia@igalia.com>
3324
3325         Flex item auto margins in the cross direction should safe center
3326         https://bugs.webkit.org/show_bug.cgi?id=103919
3327
3328         Reviewed by Ojan Vafai.
3329
3330         Do not apply auto margins for cross axis if there's no alignment
3331         space available.
3332
3333         Test: css3/flexbox/flex-flow-auto-margins-no-available-space.html
3334
3335         * rendering/RenderFlexibleBox.cpp:
3336         (WebCore::RenderFlexibleBox::alignChildren): Make sure we pass a
3337         positive value for availableAlignmentSpace to
3338         updateAutoMarginsInCrossAxis().
3339
3340 2012-12-05  Mike West  <mkwst@chromium.org>
3341
3342         Web Inspector: Autogenerate stack traces and line numbers when possible.
3343         https://bugs.webkit.org/show_bug.cgi?id=100650
3344
3345         Reviewed by Yury Semikhatsky.
3346
3347         Console messages generated in WebCore generally are asked to do a bit of
3348         work in order to provide a developer with a detailed report. We ask the
3349         caller to either generate stack traces, or pass in a url/line number
3350         pair, which can be a bit of work. Predictably, most callers don't pass
3351         in what we'd like to see.
3352
3353         This patch creates a new, simpler console message generation API that we
3354         expect most call sites to use. Source, type, level, and message are
3355         required, and an optional request ID can be passed in. Everything else
3356         will be autogenerated inside ConsoleMessage when appropriate.
3357
3358         In a subsequent patch, we expect to be able to trim down more of the
3359         external call sites (ContentSecurityPolicy springs to mind) in order to
3360         further consolidate the external interface. Simple is good.
3361
3362         * Modules/websockets/WebSocket.cpp:
3363         (WebCore::WebSocket::connect):
3364         * Modules/websockets/WebSocketChannel.cpp:
3365         (WebCore::WebSocketChannel::didFailSocketStream):
3366             Drop the now-redundant URL parameter from various WebSocket errors.
3367         * css/MediaList.cpp:
3368         (WebCore::addResolutionWarningMessageToConsole):
3369             Switch to Document::addConsoleMessage, which means that we can move
3370             line-number generation out of MediaList.
3371         * dom/Document.cpp:
3372         (WebCore::Document::logExceptionToConsole):
3373             Use the long-form 'addMessage()' rather than the public interface.
3374         (WebCore::Document::processHttpEquiv):
3375             Drop the URL parameter, as it's now autogenerated.
3376         (WebCore::Document::addConsoleMessage):
3377         (WebCore):
3378         * dom/Document.h:
3379         (Document):
3380             Override the pure virtual method on ScriptExecutionContext, and pass
3381             the call through to the new Console::addMessage, which accepts a
3382             pointer to the Document in order to do line-number generation.
3383         * dom/ScriptExecutionContext.h:
3384         (ScriptExecutionContext):
3385             Add a pure virtual variant of addConsoleMessage which accepts only
3386             bare minimum data, and expects autogeneration of the rest.
3387             Additionally, ensure that the other variants always have either a
3388             URL/line number, or a stack trace.
3389         * dom/ViewportArguments.cpp:
3390         (WebCore::reportViewportWarning):
3391             Drop line numbers and URLs from Viewport warnings. We can generate
3392             these now.
3393         * html/HTMLFormElement.cpp:
3394         (WebCore::HTMLFormElement::validateInteractively):
3395             Drop the URL from form autofocus warnings
3396         * html/HTMLIFrameElement.cpp:
3397         (WebCore::HTMLIFrameElement::parseAttribute):
3398             Drop the URL and line from sandbox attribute warnings.
3399         * html/canvas/WebGLRenderingContext.cpp:
3400         (WebCore):
3401         (WebCore::WebGLRenderingContext::printWarningToConsole):
3402             Drop the URL from WebGL warnings.
3403         * inspector/ConsoleMessage.cpp:
3404         (WebCore::ConsoleMessage::ConsoleMessage):
3405             Call 'autogenerateMetadata' to ensure that a stack trace is
3406             generated if one isn't provided. Create a new constructor that
3407             accepts a ScriptState/ScriptArguments pair, and use it for console
3408             API calls.
3409         (WebCore):
3410         (WebCore::ConsoleMessage::autogenerateMetadata):
3411             Generate a stack trace given whatever information we've got.
3412         * inspector/ConsoleMessage.h:
3413         (ConsoleMessage):
3414             Create a new constructor that accepts a ScriptState/ScriptArguments
3415             pair, and use it for console API calls.
3416         * inspector/InspectorConsoleAgent.cpp:
3417         (WebCore::InspectorConsoleAgent::enable):
3418             Use the short-form ConsoleMessage constructor.
3419         (WebCore::InspectorConsoleAgent::addMessageToConsole):
3420             Use the stack-only constructor, or the ScriptState
3421             constructor, as appropriate.
3422         (WebCore::InspectorConsoleAgent::count):
3423             We generated a stack, pass it in.
3424         * inspector/InspectorConsoleAgent.cpp:
3425         (WebCore::InspectorConsoleAgent::isWorkerAgent):
3426         * inspector/PageConsoleAgent.h:
3427         (WebCore::PageConsoleAgent::isWorkerAgent):
3428         * inspector/PageConsoleAgent.h:
3429         (WebCore::PageConsoleAgent::isWorkerAgent):
3430             We only want to generate call stacks for non-Workers (because
3431             createScriptCallStack explodes in JSC if we're not on the main
3432             thread). This method will allow us to distinguish between those
3433             messages generated from Workers, and those from Pages.
3434         * loader/FrameLoader.cpp:
3435         (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
3436         * loader/MainResourceLoader.cpp:
3437         (WebCore::MainResourceLoader::didReceiveResponse):
3438             Drop the URL parameter from the console message for X-Frame-Options
3439             parsing errors.
3440         * page/Console.cpp:
3441         (WebCore::Console::addMessage):
3442             When given a Document*, generate a line number if: 1) the document
3443             is still being parsed, 2) the document is not in document.write(),
3444             3) the parser isn't waiting for script, and 4) the parser isn't
3445             executing script. Many callsites didn't check all of these, which
3446             is why the SVG rebaseline (for example) drops lots and lots of line
3447             numbers which point at a closing '</script>' tag.
3448         (WebCore):
3449         * page/Console.h:
3450         (WebCore):
3451         (Console):
3452             Update the public API to accept a Document* and little else.
3453         * page/DOMWindow.cpp:
3454         (WebCore::DOMWindow::printErrorMessage):
3455             Don't generate a stack here. We can do it later.
3456         * svg/SVGDocumentExtensions.cpp:
3457         (WebCore::reportMessage):
3458             Drop the URL and line number. We'll generate them. It'll be sweet.
3459         * workers/WorkerContext.cpp:
3460         (WebCore::WorkerContext::addConsoleMessage):
3461         (WebCore):
3462         * workers/WorkerContext.h:
3463         (WorkerContext):
3464             Implement the new addConsoleMessage variant.
3465
3466 2012-12-04  Carlos Garcia Campos  <cgarcia@igalia.com>
3467
3468         Reduce the children repaints when moved multiple times during the layout
3469         https://bugs.webkit.org/show_bug.cgi?id=103510
3470
3471         Reviewed by Darin Adler.
3472
3473         Cache the children positions before the layout and move to the
3474         final position after the layout.
3475
3476         Test: css3/flexbox/repaint-column-reverse.html
3477
3478         * rendering/RenderFlexibleBox.cpp:
3479         (WebCore::RenderFlexibleBox::OrderIterator::OrderIterator): Do not
3480         call first() on the consructor.
3481         (WebCore::RenderFlexibleBox::layoutBlock): Use a Vector with the
3482         children frame rects before the layout and call
3483         repaintChildrenDuringLayoutIfMoved() to repaint the children that
3484         have been moved.
3485         (WebCore::RenderFlexibleBox::appendChildrenFrameRects): Return a
3486         Vector with children frame rects.
3487         (WebCore::RenderFlexibleBox::repaintChildrenDuringLayoutIfMoved):
3488         Call repaintDuringLayoutIfMoved() for every children using the old
3489         frame rects.
3490         (WebCore::RenderFlexibleBox::setFlowAwareLocationForChild): Do not
3491         call repaintDuringLayoutIfMoved().
3492         (WebCore::RenderFlexibleBox::layoutFlexItems): Make sure the
3493         passed iterator points to the first child.
3494         * rendering/RenderFlexibleBox.h:
3495
3496 2012-12-05  Dan Carney  <dcarney@google.com>
3497
3498         [V8] toV8Fast for all classes with ScriptWrapper Holder objects
3499         https://bugs.webkit.org/show_bug.cgi?id=102686
3500
3501         Reviewed by Adam Barth.
3502
3503         This patch makes most generated bindings use toV8Fast
3504         by adding a fast path to the main world DOMDataStore.
3505         Additionally, toV8Fast is now being called on callbacks
3506         which use v8::Arguments.
3507
3508         No new tests. No change in functionality.
3509
3510         * bindings/scripts/CodeGeneratorV8.pm:
3511         (GenerateHeader):
3512         (GenerateNormalAttrGetter):
3513         (GenerateFunctionCallString):
3514         (NativeToJSValue):
3515         * bindings/v8/DOMDataStore.cpp:
3516         (WebCore::DOMDataStore::mainWorldStore):
3517         (WebCore::DOMDataStore::current):
3518         * bindings/v8/DOMDataStore.h:
3519
3520 2012-12-05  Andrey Adaikin  <aandrey@chromium.org>
3521
3522         Web Inspector: [Canvas] nit: add more typization for js compiler
3523         https://bugs.webkit.org/show_bug.cgi?id=103994
3524
3525         Reviewed by Pavel Feldman.
3526
3527         * inspector/InjectedScriptCanvasModuleSource.js:
3528         (.):
3529
3530 2012-12-05  Hans Muller  <hmuller@adobe.com>
3531
3532         [CSS Exclusions] ExclusionShape inlines should use isFlippedBlocksWritingMode()
3533         https://bugs.webkit.org/show_bug.cgi?id=103939
3534
3535         Reviewed by Dirk Schulze.
3536
3537         Just a minor cleanup: the protected ExclusionShape inlines, like minYForLogicalLine(),
3538         now use isFlippedBlocksWritingMode() instead of testing for RightToLeftWritingMode directly.
3539         This changeimproves consistency with the rest of WebKit and will work correctly
3540         if "horizontal-bt" writing-mode support is ever added.
3541
3542         No new tests were added since the existing tests cover these methods.
3543
3544         * rendering/ExclusionShape.h:
3545         (WebCore::ExclusionShape::minYForLogicalLine):
3546         (WebCore::ExclusionShape::maxYForLogicalLine):
3547         (WebCore::ExclusionShape::internalToLogicalBoundingBox):
3548
3549 2012-12-05  Bear Travis  <betravis@adobe.com>
3550
3551         Absolutely positioned non-replaced elements should resolve vertical margins against
3552         their containing block's logical width
3553         https://bugs.webkit.org/show_bug.cgi?id=103576
3554
3555         Reviewed by Emil A Eklund.
3556
3557         According to the CSS box model specification, all percentage margin & padding values,
3558         including top & bottom, should be resolved based on the containing block's width.
3559         http://www.w3.org/TR/CSS2/box.html#margin-properties
3560         The writing modes specification has refined this definition to use the containing
3561         block's logical width to resolve percentage margin & padding values.
3562         http://dev.w3.org/csswg/css3-writing-modes/#dimension-mapping
3563
3564         Previously, positioned elements measured their container in the element's block
3565         direction (containerLogicalHeight) to resolve margin-before/after, and in the inline
3566         direction (containerLogicalWidth) to resolve margin-start/end. This patch measures the
3567         container's logical width in its own inline direction (containerRelativeLogicalWidth)
3568         to resolve all margin percentage values.
3569
3570         Test: fast/writing-mode/percentage-margins-absolute.html
3571
3572         * rendering/RenderBox.cpp:
3573         (WebCore::RenderBox::computePositionedLogicalWidthUsing): Calculate the logical width
3574         of the container, and use it to calculate margins.
3575         (WebCore::RenderBox::computePositionedLogicalHeightUsing): Ditto.
3576
3577 2012-12-04  Kentaro Hara  <haraken@chromium.org>
3578
3579         [V8] Replace String::New("symbol") with String::NewSymbol("symbol") (part 2)
3580         https://bugs.webkit.org/show_bug.cgi?id=104082
3581
3582         Reviewed by Adam Barth.
3583
3584         V8 can look up symbols faster than strings.
3585
3586         No tests. No change in behavior.
3587
3588         * bindings/v8/custom/V8ArrayBufferViewCustom.cpp:
3589         (WebCore::getHiddenCopyMethod):
3590         (WebCore::installHiddenCopyMethod):
3591         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
3592         (WebCore::constructWebGLArray):
3593         (WebCore::setWebGLArrayHelper):
3594         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
3595         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
3596         * bindings/v8/custom/V8DOMWindowCustom.cpp:
3597         (WebCore::DialogHandler::dialogCreated):
3598         (WebCore::DialogHandler::returnValue):
3599         * bindings/v8/custom/V8GeolocationCustom.cpp:
3600         (WebCore::createPositionOptions):
3601         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
3602         (WebCore::V8HTMLDocument::wrapInShadowObject):
3603         (WebCore::V8HTMLDocument::openCallback):
3604         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
3605         (WebCore::V8HTMLImageElementConstructor::GetTemplate):
3606         * bindings/v8/custom/V8SQLTransactionCustom.cpp:
3607         (WebCore::V8SQLTransaction::executeSqlCallback):
3608
3609 2012-12-04  Elliott Sprehn  <esprehn@chromium.org>
3610
3611         Clicking a scrollbar unfocuses the current activeElement
3612         https://bugs.webkit.org/show_bug.cgi?id=96335
3613
3614         Reviewed by Ojan Vafai.
3615
3616         Previously we only tested for clicks inside frame scrollbars before
3617         moving the focus, this patch expands the check to overflow scrollbars.
3618         Now clicking inside a scrollbar only moves the focus when the scrollbar
3619         has an ancestor that is mouse focusable.
3620
3621         This matches Gecko behavior, and was agreed to be the most sensible for now:
3622         http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2012-October/037759.html
3623
3624         Test: fast/overflow/scrollbar-click-retains-focus.html
3625
3626         * page/EventHandler.cpp:
3627         (WebCore::EventHandler::handleMousePressEvent):
3628           Never start selections inside scrollbars because it would cause asserts. 
3629           This wasn't a problem before because we always moved the focus when clicking a scrollbar.        
3630         (WebCore::EventHandler::dispatchMouseEvent): 
3631           Check that the click is not inside a scrollbar before moving the focus.
3632         (WebCore::EventHandler::isInsideScrollbar): Tests if a point is in a scrollbar.
3633         (WebCore):
3634         (WebCore::EventHandler::sendContextMenuEvent):
3635           Never start selections inside scrollbars because it would cause asserts.
3636         * page/EventHandler.h:
3637         (EventHandler):
3638         * rendering/RenderLayer.cpp:
3639         (WebCore::RenderLayer::hitTestOverflowControls):
3640
3641 2012-12-04  Kentaro Hara  <haraken@chromium.org>
3642
3643         [V8] Replace String::New("symbol") with String::NewSymbol("symbol")
3644         https://bugs.webkit.org/show_bug.cgi?id=104084
3645
3646         Reviewed by Adam Barth.
3647
3648         V8 can look up symbols faster than strings. This is a final patch for the replacement.
3649
3650         No tests. No change in behavior.
3651
3652         * bindings/v8/DateExtension.cpp:
3653         (WebCore::DateExtension::setAllowSleep):
3654         (WebCore::DateExtension::GetNativeFunction):
3655         * bindings/v8/NPV8Object.cpp:
3656         (WebCore::npIdentifierToV8Identifier):
3657         (_NPN_Invoke):
3658         * bindings/v8/PageScriptDebugServer.cpp:
3659         (WebCore::PageScriptDebugServer::addListener):
3660         * bindings/v8/ScriptController.cpp:
3661         (WebCore::ScriptController::setContextDebugId):
3662         * bindings/v8/ScriptDebugServer.cpp:
3663         (WebCore::ScriptDebugServer::callDebuggerMethod):
3664         (WebCore::ScriptDebugServer::setBreakpoint):
3665         (WebCore::ScriptDebugServer::removeBreakpoint):
3666         (WebCore::ScriptDebugServer::clearBreakpoints):
3667         (WebCore::ScriptDebugServer::setBreakpointsActivated):
3668         (WebCore::ScriptDebugServer::handleV8DebugEvent):
3669         (WebCore::ScriptDebugServer::dispatchDidParseSource):
3670         * bindings/v8/ScriptObject.cpp:
3671         (WebCore::ScriptGlobalObject::set):
3672         (WebCore::ScriptGlobalObject::get):
3673         (WebCore::ScriptGlobalObject::remove):
3674         * bindings/v8/V8Binding.h:
3675         (WebCore::toV8Sequence):
3676         * bindings/v8/V8DOMWindowShell.cpp:
3677         (WebCore::setInjectedScriptContextDebugId):
3678         (WebCore::V8DOMWindowShell::updateDocumentProperty):
3679         (WebCore::V8DOMWindowShell::clearDocumentProperty):
3680         * bindings/v8/V8NPObject.cpp:
3681         (WebCore::npObjectPropertyEnumerator):
3682         * bindings/v8/V8NodeFilterCondition.cpp:
3683         (WebCore::V8NodeFilterCondition::acceptNode):
3684         * bindings/v8/V8PerIsolateData.cpp:
3685         (WebCore::V8PerIsolateData::constructorOfToString):
3686         * bindings/v8/WorkerScriptController.cpp:
3687         (WebCore::WorkerScriptController::initializeContextIfNeeded):
3688         * bindings/v8/WorkerScriptDebugServer.cpp:
3689         (WebCore::WorkerScriptDebugServer::addListener):
3690
3691 2012-12-04  Dan Bernstein  <mitz@apple.com>
3692
3693         Support text-orientation: sideways-right (and sideways when it maps to sideways-right)
3694         https://bugs.webkit.org/show_bug.cgi?id=104035
3695
3696         Reviewed by Anders Carlsson.
3697
3698         Test: fast/text/orientation-sideways.html
3699
3700         * GNUmakefile.list.am: Updated for rename of TextOrientation.h.
3701
3702         * WebCore.gypi: Ditto.
3703
3704         * WebCore.xcodeproj/project.pbxproj: Ditto.
3705
3706         * css/CSSComputedStyleDeclaration.cpp:
3707         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Changed to retrieve
3708         text-orientation from RenderStyle rather than from the font description.
3709
3710         * css/CSSParser.cpp:
3711         (WebCore::CSSParser::parseValue): Added sideways and sideways-right as acceptable
3712         text-orientation values.
3713
3714         * css/CSSPrimitiveValueMappings.h:
3715         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Added mappings for sideways and
3716         sideways-right.
3717         (WebCore::CSSPrimitiveValue::operator TextOrientation): Ditto.
3718
3719         * css/CSSValueKeywords.in: Added sideways and sideways-right.
3720
3721         * css/StyleBuilder.cpp:
3722         (WebCore::StyleBuilder::StyleBuilder): Removed text-orientation property handler, as it is
3723         now handled in CSSStyleResolver.
3724
3725         * css/StyleResolver.cpp:
3726         (WebCore::getFontAndGlyphOrientation): Added this helper function that determines the font
3727         orientation and non-CJK glyph orientation based on writing-mode and text-orientation.
3728         (WebCore::StyleResolver::styleForDocument): Added code to set the font orientation and
3729         non-CJK glyph orientation in the document style.
3730         (WebCore::checkForOrientationChange): Added. Sets the font orientation and non-CJK glyph
3731         orientation in the child style if the difference between the parent and child styles requires
3732         doing so.
3733         (WebCore::StyleResolver::updateFont): Added call to checkForOrientationChange().
3734         (WebCore::StyleResolver::applyProperty): Changed the writing-mode case to call the new
3735         setWritingMode helper, which dirties the font as needed, rather than changing the font
3736         here. Moved handling of text-orientation here, by calling setTextOrientation, which also
3737         dirties the font as needed.
3738
3739         * css/StyleResolver.h:
3740         (WebCore::StyleResolver::setWritingMode): Added. Dirties the font if the writing mode changes.
3741         (WebCore::StyleResolver::setTextOrientation): Ditto for text orientation.
3742
3743         * platform/graphics/FontDescription.h:
3744         (WebCore::FontDescription::FontDescription): Updated initializer for rename.
3745         (WebCore::FontDescription::nonCJKGlyphOrientation): Renamed textOrientation to this.
3746         (WebCore::FontDescription::setNonCJKGlyphOrientation): Renamed setTextOrientation to this.
3747         (FontDescription): Renamed member variable m_textOrientation to m_nonCJKGlyphOrientation.
3748         (WebCore::FontDescription::operator==): Updated for rename.
3749
3750         * platform/graphics/FontFastPath.cpp:
3751         (WebCore::glyphDataAndPageForNonCJKCharacterWithGlyphOrientation): Renamed
3752         glyphDataAndPageForCharacterWithTextOrientation to this and changed the parameter type from
3753         TextOrientation to NonCJKGlyphOrientation.
3754         (WebCore::Font::glyphDataAndPageForCharacter): Updated for above rename.
3755
3756         * platform/graphics/mac/FontComplexTextMac.cpp:
3757         (WebCore::Font::fontDataForCombiningCharacterSequence): Updated for rename of
3758         FontDescription::textOrientation().
3759
3760         * platform/text/NonCJKGlyphOrientation.h: Renamed TextOrientation.h to this, and renamed
3761         the enum and its values to better reflect that they describe how glyphs for non-CJK
3762         characters are to be rendered in vertical text.
3763
3764         * rendering/InlineFlowBox.cpp:
3765         (WebCore::InlineFlowBox::requiresIdeographicBaseline): Updated for rename of
3766         FontDescription::textOrientation().
3767
3768         * rendering/style/RenderStyle.cpp:
3769         (WebCore::RenderStyle::diff): Made text-orientation change a layout change.
3770
3771         * rendering/style/RenderStyle.h:
3772         (WebCore::RenderStyle::setTextOrientation): Added.
3773
3774         * rendering/style/RenderStyleConstants.h: Added a new TextOrientation enum here.
3775
3776         * rendering/style/StyleRareInheritedData.cpp:
3777         (WebCore::StyleRareInheritedData::StyleRareInheritedData): Added initialization and copying
3778         of m_textOrientation member variable.
3779         (WebCore::StyleRareInheritedData::operator==): Added comparing of m_textOrientation.
3780
3781         * rendering/style/StyleRareInheritedData.h:
3782         (StyleRareInheritedData): Added m_textOrientation member variable.
3783
3784 2012-12-04  Kentaro Hara  <haraken@chromium.org>
3785
3786         [V8] Use ScopedPersistent for IntegerCache::smallIntegers
3787         https://bugs.webkit.org/show_bug.cgi?id=104066
3788
3789         Reviewed by Adam Barth.
3790
3791         We can use ScopedPersistent for IntegerCache::smallIntegers
3792         instead of manual Persistent::New().
3793
3794         I confirmed no performance regression in Bindings/scroll-top.html
3795
3796         No tests. No change in behavior.
3797
3798         * bindings/v8/V8PerIsolateData.cpp:
3799         (WebCore::V8PerIsolateData::V8PerIsolateData):
3800         * bindings/v8/V8ValueCache.cpp:
3801         (WebCore::IntegerCache::IntegerCache):
3802         * bindings/v8/V8ValueCache.h:
3803         (IntegerCache):
3804         (WebCore::IntegerCache::v8Integer):
3805         (WebCore::IntegerCache::v8UnsignedInteger):
3806
3807 2012-12-04  Eugene Klyuchnikov  <eustas@chromium.org>
3808
3809         Web Inspector: Resources: domain cookies are not shown for sub-sub domain pages.
3810         https://bugs.webkit.org/show_bug.cgi?id=104016
3811
3812         Reviewed by Pavel Feldman.
3813
3814         Fixed regexp to allow zero or more subdomain prefix (was zero or one).
3815
3816         * inspector/front-end/CookieParser.js:
3817         (WebInspector.Cookies.cookieDomainMatchesResourceDomain): Fixed regexp.
3818
3819 2012-12-04  Alpha Lam  <hclam@chromium.org>
3820
3821         Not reviewed. Build fix.
3822
3823         Fix Chromium Windows build.
3824
3825         * platform/graphics/chromium/ImageDecodingStore.h:
3826         (CacheEntry):
3827
3828 2012-12-04  Kentaro Hara  <haraken@chromium.org>
3829
3830         [V8] Remove toV8Object()
3831         https://bugs.webkit.org/show_bug.cgi?id=103987
3832
3833         Reviewed by Adam Barth.
3834
3835         toV8Object() is used only for MessagePort and ArrayBuffer
3836         only by SerializedScriptValue. It is wasteful to generate
3837         toV8Object() for all interfaces.
3838
3839         No tests. No change in behavior.
3840
3841         * bindings/scripts/CodeGeneratorV8.pm:
3842         (GenerateHeader):
3843         * bindings/scripts/test/V8/V8Float64Array.h:
3844         (WebCore):
3845         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
3846         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
3847         * bindings/scripts/test/V8/V8TestEventConstructor.h:
3848         * bindings/scripts/test/V8/V8TestEventTarget.h:
3849         * bindings/scripts/test/V8/V8TestException.h:
3850         * bindings/scripts/test/V8/V8TestInterface.h:
3851         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
3852         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
3853         * bindings/scripts/test/V8/V8TestNode.h:
3854         * bindings/scripts/test/V8/V8TestObj.h:
3855         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
3856         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
3857         * bindings/v8/SerializedScriptValue.cpp:
3858
3859 2012-12-04  Kentaro Hara  <haraken@chromium.org>
3860
3861         [V8] Replace v8::Null(isolate) with v8Null(isolate)
3862         https://bugs.webkit.org/show_bug.cgi?id=104070
3863
3864         Reviewed by Adam Barth.
3865
3866         v8Null(isolate) is a faster version of v8::Null(isolate).
3867
3868         No tests. No change in behavior.
3869
3870         * bindings/v8/V8Binding.h:
3871         (WebCore::v8StringOrNull):
3872         * bindings/v8/custom/V8ClipboardCustom.cpp:
3873         (WebCore::V8Clipboard::typesAccessorGetter):
3874         * bindings/v8/custom/V8CoordinatesCustom.cpp:
3875         (WebCore::V8Coordinates::altitudeAccessorGetter):
3876         (WebCore::V8Coordinates::altitudeAccuracyAccessorGetter):
3877         (WebCore::V8Coordinates::headingAccessorGetter):
3878         (WebCore::V8Coordinates::speedAccessorGetter):
3879         * bindings/v8/custom/V8DeviceMotionEventCustom.cpp:
3880         (WebCore::V8DeviceMotionEvent::accelerationAccessorGetter):
3881         (WebCore::V8DeviceMotionEvent::accelerationIncludingGravityAccessorGetter):
3882         (WebCore::V8DeviceMotionEvent::rotationRateAccessorGetter):
3883         (WebCore::V8DeviceMotionEvent::intervalAccessorGetter):
3884         * bindings/v8/custom/V8DeviceOrientationEventCustom.cpp:
3885         (WebCore::V8DeviceOrientationEvent::alphaAccessorGetter):
3886         (WebCore::V8DeviceOrientationEvent::betaAccessorGetter):
3887         (WebCore::V8DeviceOrientationEvent::gammaAccessorGetter):
3888         (WebCore::V8DeviceOrientationEvent::absoluteAccessorGetter):
3889         * bindings/v8/custom/V8DocumentLocationCustom.cpp:
3890         (WebCore::V8Document::locationAccessorGetter):
3891         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
3892         (WebCore::V8HTMLCanvasElement::getContextCallback):
3893         * bindings/v8/custom/V8HistoryCustom.cpp:
3894         (WebCore::V8History::stateAccessorGetter):
3895         * bindings/v8/custom/V8MessageEventCustom.cpp:
3896         (WebCore::V8MessageEvent::dataAccessorGetter):
3897         * bindings/v8/custom/V8MicroDataItemValueCustom.cpp:
3898         (WebCore::toV8):
3899         * bindings/v8/custom/V8NodeCustom.cpp:
3900         (WebCore::V8Node::insertBeforeCallback):
3901         (WebCore::V8Node::replaceChildCallback):
3902         (WebCore::V8Node::removeChildCallback):
3903         (WebCore::V8Node::appendChildCallback):
3904         * bindings/v8/custom/V8PopStateEventCustom.cpp:
3905         (WebCore::V8PopStateEvent::stateAccessorGetter):
3906         * bindings/v8/custom/V8SQLResultSetRowListCustom.cpp:
3907         (WebCore::V8SQLResultSetRowList::itemCallback):
3908         * bindings/v8/custom/V8TrackEventCustom.cpp:
3909         (WebCore::V8TrackEvent::trackAccessorGetter):
3910         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
3911         (WebCore::toV8Object):
3912         (WebCore::V8WebGLRenderingContext::getAttachedShadersCallback):
3913         (WebCore::V8WebGLRenderingContext::getSupportedExtensionsCallback):
3914
3915 2012-12-04  Min Qin  <qinmin@chromium.org>
3916
3917         Make LazyDecodingPixelRef inherit from skia::LazyPixelRef so that cc thread can access it
3918         https://bugs.webkit.org/show_bug.cgi?id=103555
3919
3920         Reviewed by Stephen White.
3921
3922         Expose LazyDecodingPixelRef to the cc thread by inheriting from skia::LazyPixelRef.
3923         No test added for now as impl side paiting is still WIP.
3924
3925         * platform/graphics/chromium/LazyDecodingPixelRef.cpp:
3926         (WebCore::LazyDecodingPixelRef::LazyDecodingPixelRef):
3927         (WebCore::LazyDecodingPixelRef::PrepareToDecode):
3928         (WebCore):
3929         (WebCore::LazyDecodingPixelRef::Decode):
3930         * platform/graphics/chromium/LazyDecodingPixelRef.h:
3931         (LazyDecodingPixelRef):
3932
3933 2012-12-04  Takashi Sakamoto  <tasak@google.com>
3934
3935         Fix compile error when SVG is disabled.
3936
3937         Unreviewed gardening.
3938
3939         * css/StyleResolver.cpp:
3940         (WebCore::StyleResolver::sharingCandidateHasIdenticalStyleAffectingAttributes):
3941
3942 2012-12-04  Anthony Scian  <ascian@rim.com>
3943
3944         Static code analysis warning fixes
3945         https://bugs.webkit.org/show_bug.cgi?id=103837
3946
3947         Reviewed by Rob Buis.
3948
3949         172,174: disable copy ctor, op= in AutofillBackingStore
3950         504,506: disable copy ctor, op= in CookieManager
3951         1488,1491: disable copy ctor, op= in RSSParserBase
3952         1489,1490: disable copy ctor, op= in RSSItem
3953         514,516: disable copy ctor, op= in CredentialBackingStore
3954         1363: m_state not initialized in ctor
3955
3956         * platform/blackberry/CookieManager.h:
3957         * platform/blackberry/PlatformTouchPointBlackBerry.cpp:
3958         (WebCore::PlatformTouchPoint::PlatformTouchPoint):
3959         * platform/network/blackberry/AutofillBackingStore.h:
3960         (AutofillBackingStore):
3961         * platform/network/blackberry/CredentialBackingStore.h:
3962         (CredentialBackingStore):
3963         * platform/network/blackberry/rss/RSSParserBase.h:
3964         (RSSParserBase):
3965
3966 2012-12-04  Noel Gordon  <noel.gordon@gmail.com>
3967
3968         [v8] Improve worker.postMessage() string performance: avoid utf8 conversion
3969         https://bugs.webkit.org/show_bug.cgi?id=102230
3970
3971         Reviewed by Eric Seidel.
3972
3973         Avoid utf8 conversion when serializing strings with SerializedScriptValue. Provide 
3974         Ascii and UChar writers for v8 string serialization and provide a UChar reader for
3975         deserialization. Define/use serialization StringUCharTag to indicate UChar strings
3976         in the wire format. Increment the SerializedScriptValue wire format version.
3977
3978         In the wire format, StringUCharTag is followed by the string length in bytes, then
3979         the length/2 UChars of the string.
3980
3981         Note the string length is VarInt encoded. During serialization, compute the number
3982         of bytes used to encode the length and prepend a PaddingTag if needed so the UChar
3983         data appears on an even-byte boundary. This prevents unaligned reads of UChar data
3984         during deserialization (the deserialization buffer is even-byte aligned).
3985
3986         Testing transfers of large strings to and from workers indicates a 10X improvement
3987         in transfer rate for strings, and strings within js objects, with this change. For
3988         example, 500 MByte/s on my test machine (50 MByte/s without this change) for flat,
3989         32 MByte string postMessage() transfers.
3990
3991         Covered by platform/chromium/fast/storage/serialized-script-value.html
3992
3993         * bindings/v8/SerializedScriptValue.cpp:
3994
3995 2012-12-04  Kentaro Hara  <haraken@chromium.org>
3996
3997         [V8] V8Binding::v8ExternalString() is redundant
3998         https://bugs.webkit.org/show_bug.cgi?id=103979
3999
4000         Reviewed by Adam Barth.
4001
4002         v8String(), v8StringOrNull() and v8StringOrUndefined() are enough.
4003         We can remove V8Binding::v8ExternalString().
4004
4005         No tests. No change in behavior.
4006
4007         * bindings/scripts/CodeGeneratorV8.pm:
4008         (GenerateNormalAttrGetter):
4009         * bindings/v8/ScriptController.cpp:
4010         (WebCore::ScriptController::compileAndRunScript):
4011         * bindings/v8/ScriptDebugServer.cpp:
4012         (WebCore::ScriptDebugServer::compileScript):
4013         * bindings/v8/V8Binding.h:
4014         (WebCore):
4015         (WebCore::v8String):
4016         (WebCore::v8StringOrNull):
4017         (WebCore::v8StringOrUndefined):
4018         * bindings/v8/V8LazyEventListener.cpp:
4019         (WebCore::V8LazyEventListener::prepareListenerObject):
4020         * bindings/v8/WorkerScriptController.cpp:
4021         (WebCore::WorkerScriptController::evaluate):
4022
4023 2012-12-04  Kentaro Hara  <haraken@chromium.org>
4024
4025         [V8] Remove v8NonStringValueToWebCoreString() and v8NonStringValueToAtomicWebCoreString()
4026         https://bugs.webkit.org/show_bug.cgi?id=103981