IndexedDB: IDBTransaction::abort() should throw DOMException
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-07-25  Xingnan Wang  <xingnan.wang@intel.com>
2
3         IndexedDB: IDBTransaction::abort() should throw DOMException
4         https://bugs.webkit.org/show_bug.cgi?id=92069
5
6         Reviewed by Kentaro Hara.
7
8         Keep aligned with the W3C spec.
9         http://dvcs.w3.org/hg/IndexedDB/raw-file/tip/Overview.html#widl-IDBTransaction-abort-void
10
11         Test: storage/indexeddb/transaction-abort.html.
12
13         * Modules/indexeddb/IDBTransaction.cpp:
14         (WebCore::IDBTransaction::abort):
15         (WebCore):
16         * Modules/indexeddb/IDBTransaction.h:
17         (IDBTransaction):
18         * Modules/indexeddb/IDBTransaction.idl:
19
20 2012-07-25  Tony Chang  <tony@chromium.org>
21
22         flexitems can overflow the flexbox due to rounding
23         https://bugs.webkit.org/show_bug.cgi?id=92163
24
25         Reviewed by Levi Weintraub.
26
27         Don't round flex item sizes and use LayoutPoint for the location of flex items.
28
29         Test: css3/flexbox/flex-rounding.html
30
31         * rendering/RenderFlexibleBox.cpp:
32         (WebCore::RenderFlexibleBox::resolveFlexibleLengths):
33         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
34         (WebCore::RenderFlexibleBox::layoutColumnReverse):
35
36 2012-07-25  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
37
38         [BlackBerry] Integrate certmgr with CredentialBackingStore
39         https://bugs.webkit.org/show_bug.cgi?id=92183
40
41         Reviewed by George Staikos.
42
43         Integrated BlackBerry::Platform::CertMgrWrapper with
44         CredentialBackingStore, when certmgr is ready we save
45         the password in certmgr and retrieve it from certmgr.
46
47         RIM PR: 171991
48         Internally reviewed by Joe Mason <jmason@rim.com>.
49
50         No new tests since there's no functional change.
51
52         * platform/network/blackberry/CredentialBackingStore.cpp:
53         (WebCore::hashCredentialInfo):
54         (WebCore):
55         (WebCore::CredentialBackingStore::CredentialBackingStore):
56         (WebCore::CredentialBackingStore::open):
57         (WebCore::CredentialBackingStore::addLogin):
58         (WebCore::CredentialBackingStore::updateLogin):
59         (WebCore::CredentialBackingStore::getLogin):
60         * platform/network/blackberry/CredentialBackingStore.h:
61         (CredentialBackingStore):
62
63 2012-07-25  Kent Tamura  <tkent@chromium.org>
64
65         REGRESSION(r121420): Performance regression of form state saving for pages with multiple forms
66         https://bugs.webkit.org/show_bug.cgi?id=91804
67
68         Reviewed by Hajime Morita.
69
70         The complexity of FormKeyGenerator::formKey() was O(N) where N is the
71         number form elements with an identical action URL, and formKey() is
72         called for every form. So, it's O(N^2). A page in www.reddit.com
73         contains hundreds of form elements with action="#". So FormController::
74         formElementsState() took a few seconds on a slow machine.
75
76         In order to avoid O(N^2) operation, storing a map from form signatures
77         to next index numbers, instead of storing existing formKey strings.
78
79         No new tests. Just a performance improvement.
80
81         Note: This is a re-landing of r123191. We rolled it out because of
82         suspicion of a performance regression. However it was innocent.
83
84         * html/FormController.cpp:
85         (FormKeyGenerator): Remove m_existingKeys. Add a map from a form
86         signature string to the next index number.
87         (WebCore::formSignature): Returns a signature string for a form, without
88         an index number. This is like "actionURL [name1 name2 ]"
89         (WebCore::FormKeyGenerator::formKey):
90         Creates a formKey string by concatenating a formSignature and #n. N is
91         obtained from m_formSignatureToNextIndexMap in O(1).
92         (WebCore::FormKeyGenerator::willDeleteForm):
93         Remove the code for m_existingKeys.
94
95 2012-07-25  Benjamin Poulain  <bpoulain@apple.com>
96
97         Initialize QualifiedName's strings from the read only data segment
98         https://bugs.webkit.org/show_bug.cgi?id=92226
99
100         Reviewed by Anders Carlsson.
101
102         Modify the initialization of static QualifiedName to initialize the AtomicString
103         with the data from the read only memory.
104
105         Overall, HTMLNames::init() gets 10% faster.
106
107         * dom/QualifiedName.cpp:
108         (WebCore::QualifiedName::QualifiedName):
109         * dom/QualifiedName.h:
110         (QualifiedName):
111         Remove the useless constructor taking a char* and get rid of the init() function.
112         The AtomicString representing the name should be constructed by the caller of QualifiedName.
113
114         Because the init() code is relatively large and is only executed once, it is important to
115         keep the AtomicString construction separate. The function createQualifiedName() was added
116         to improve the cache use. The short version let us reduce the code one more instruction per
117         call.
118
119         * dom/make_names.pl:
120         (printQualifiedNameMaker):
121         (printShortQualifiedNameMaker):
122         (printNamesCppFile):
123         (printDefinitions):
124
125 2012-07-25  Yoshifumi Inoue  <yosin@chromium.org>
126
127         [Forms] Move HTMLInputElement::updateInnerTextValue to InputType class
128         https://bugs.webkit.org/show_bug.cgi?id=92230
129
130         Reviewed by Kent Tamura.
131
132         This patch moves implementaion of HTMLInputElement::updateInnerTextValue()
133         into input type classes, removes updateInnerTextValue() from HTMLInputElement,
134         and updates call site of updateInnerTextValue().
135
136         No new tests. This patch doesn't change behavior.
137
138         * html/DateInputType.cpp:
139         (WebCore::DateInputType::handleBlurEvent): Updated call site of updateInnerTextValue().
140         * html/HTMLInputElement.cpp:
141         (WebCore::HTMLInputElement::updateType): Updated call site of updateInnerTextValue().
142         (WebCore::HTMLInputElement::parseAttribute): Updated call site of updateInnerTextValue().
143         (WebCore::HTMLInputElement::copyNonAttributePropertiesFromElement): Updated call site of updateInnerTextValue().
144         (WebCore::HTMLInputElement::setSuggestedValue): Updated call site of updateInnerTextValue().
145         * html/HTMLInputElement.h:
146         (HTMLInputElement): Removed updateInnerTextValue().
147         * html/InputType.cpp:
148         (WebCore::InputType::updateInnerTextValue): Added default implementaion.
149         * html/InputType.h:
150         (InputType): Added declaration of updateInnerTextValue().
151         * html/NumberInputType.cpp:
152         (WebCore::NumberInputType::handleBlurEvent): Updated call site of updateInnerTextValue().
153         * html/TextFieldInputType.cpp:
154         (WebCore::TextFieldInputType::setValue): Updated call site of updateInnerTextValue().
155         (WebCore::TextFieldInputType::updateInnerTextValue): Moved implementaion from HTMLInputElement.
156         * html/TextFieldInputType.h:
157         (TextFieldInputType): Added declaration of updateInnerTextValue().
158
159 2012-07-25  Dana Jansens  <danakj@chromium.org>
160
161         [chromium] Move ephemeral data for a single frame in LayerRendererChromium into a structure with a scoped lifetime equal to the frame
162         https://bugs.webkit.org/show_bug.cgi?id=92294
163
164         Reviewed by Adrienne Walker.
165
166         The LayerRendererChromium class has a number of member variables that are used
167         while drawing a single frame. Because they are member variables, their lifetimes
168         are not clear, and some are even updated between frames, which is not needed.
169
170         This change creates a LRC::DrawingFrame structure that holds the data used
171         while drawing the current frame, and an instance of this structure is held
172         and passed around to functions in LayerRendererChromium, moving all of the
173         data out from being member variables on the class to being function
174         arguments on the relevant methods.
175
176         The projection and window matrices are a part of this frame data, and are not
177         used externally, so they are removed from the CCRenderer interface and included
178         within the DrawingFrame structure.
179
180         Covered by existing tests, no change in behaviour intended.
181
182         * platform/graphics/chromium/LayerRendererChromium.cpp:
183         (WebCore::LayerRendererChromium::LayerRendererChromium):
184         (WebCore::LayerRendererChromium::viewportChanged):
185         (WebCore::LayerRendererChromium::clearFramebuffer):
186         (WebCore::LayerRendererChromium::drawFrame):
187         (WebCore::LayerRendererChromium::drawRenderPass):
188         (WebCore::LayerRendererChromium::drawQuad):
189         (WebCore::LayerRendererChromium::drawCheckerboardQuad):
190         (WebCore::LayerRendererChromium::drawDebugBorderQuad):
191         (WebCore::LayerRendererChromium::drawBackgroundFilters):
192         (WebCore::LayerRendererChromium::drawRenderPassQuad):
193         (WebCore::LayerRendererChromium::drawSolidColorQuad):
194         (WebCore::LayerRendererChromium::drawTileQuad):
195         (WebCore::LayerRendererChromium::drawYUVVideoQuad):
196         (WebCore::LayerRendererChromium::drawStreamVideoQuad):
197         (WebCore::LayerRendererChromium::drawTextureQuad):
198         (WebCore::LayerRendererChromium::drawIOSurfaceQuad):
199         (WebCore::LayerRendererChromium::finishDrawingFrame):
200         (WebCore::LayerRendererChromium::drawTexturedQuad):
201         (WebCore::LayerRendererChromium::copyTextureToFramebuffer):
202         (WebCore::LayerRendererChromium::isCurrentRenderPass):
203         (WebCore::LayerRendererChromium::useRenderPass):
204         (WebCore::LayerRendererChromium::useScopedTexture):
205         (WebCore::LayerRendererChromium::bindFramebufferToTexture):
206         (WebCore::LayerRendererChromium::setScissorToRect):
207         (WebCore::LayerRendererChromium::setDrawFramebufferRect):
208         * platform/graphics/chromium/LayerRendererChromium.h:
209         (DrawingFrame):
210         (WebCore::LayerRendererChromium::DrawingFrame::DrawingFrame):
211         (LayerRendererChromium):
212         * platform/graphics/chromium/cc/CCRenderer.h:
213         (CCRenderer):
214
215 2012-07-19  Adrienne Walker  <enne@google.com>
216
217         [chromium] Make all compositor screen space transforms operate on content rects
218         https://bugs.webkit.org/show_bug.cgi?id=91807
219
220         Reviewed by Kenneth Russell.
221
222         Previously, surface screen space transforms operated on surface
223         content space but layer screen space transforms operated on layer
224         space. For the purpose of consistency, unify these two so that they
225         both operate on content space.
226
227         No tests, because no change in behavior expected. Just a refactoring.
228
229         * platform/graphics/chromium/LayerChromium.h:
230         (LayerChromium):
231         * platform/graphics/chromium/cc/CCDebugRectHistory.cpp:
232         (WebCore::CCDebugRectHistory::savePaintRects):
233         (WebCore::CCDebugRectHistory::savePropertyChangedRects):
234         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
235         (WebCore::calculateDrawTransformsInternal):
236         (WebCore::CCLayerTreeHostCommon::findLayerThatIsHitByPoint):
237         * platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
238         (WebCore::::markOccludedBehindLayer):
239         (WebCore::::occluded):
240         (WebCore::::unoccludedContentRect):
241
242 2012-07-25  Dan Bernstein  <mitz@apple.com>
243
244         Hit testing in one column or in the gap between cloumns along the block axis can return a result from the wrong column
245         https://bugs.webkit.org/show_bug.cgi?id=92311
246
247         Reviewed by Anders Carlsson.
248
249         Tests: fast/multicol/hit-test-end-of-column.html
250                fast/multicol/hit-test-gap-block-axis.html
251
252         * rendering/RenderBlock.cpp:
253         (WebCore::RenderBlock::positionForPointWithInlineChildren): To prevent hits after the last
254         line on a given column from returning the next line in the next column, added a check if
255         the hit occurred within the pagination strut of a line. Covered by the first test.
256         (WebCore::RenderBlock::adjustPointToColumnContents): Added clamp-to-column logic for the
257         block-axis case. This prevents hits near the bottom of the top half of the gap from bleeding
258         into the top of the next column. Covered by the second test.
259
260 2012-07-25  David Grogan  <dgrogan@chromium.org>
261
262         IndexedDB: Make db.version return an integer if appropriate
263         https://bugs.webkit.org/show_bug.cgi?id=92195
264
265         Reviewed by Tony Chang.
266
267         Make use of the existing IDBAny mechanism to return an integer if
268         integer versions have been used.
269
270         No new tests - no change in behavior expected.
271
272         * Modules/indexeddb/IDBDatabase.cpp:
273         (WebCore::IDBDatabase::version):
274         (WebCore):
275         * Modules/indexeddb/IDBDatabase.h:
276         (IDBDatabase):
277         * Modules/indexeddb/IDBDatabase.idl:
278
279 2012-07-25  Michael Saboff  <msaboff@apple.com>
280
281         Convert HTML parser to handle 8-bit resources without converting to UChar*
282         https://bugs.webkit.org/show_bug.cgi?id=90321
283
284         Reviewed by Geoffrey Garen.
285
286         No new tests, no new functionality therefore covered by existing tests.
287
288         Changed the parsing of HTML to handle 8-bit strings without converting the 
289         whole string to 16-bits.  Primary change was to use the appropriate 
290         character pointer type (LChar* or UChar*) depending on the source string.
291         This access is abstracted in SegmentedSubstring by getCurrentChar{8,16} and
292         incrementAndGetCurrentChar{8,16} methods.  In SegmentedString, the advance()
293         and advanceAndUpdateLineNumber() methods have been refactored into a
294         state machine managed pair of function pointers.  The possible functions
295         have not only the 8 and 16 bitness factored out, they also have the 
296         "exclude line numbers" logic factored out for advanceAndUpdateLineNumber().
297         This provides a net speed-up even with the 8/16 bit testing.
298         Other changes involve using String methods to access and compare with the
299         source data.
300
301         * html/FTPDirectoryDocument.cpp:
302         (WebCore::FTPDirectoryDocumentParser::append): Changed to use currentChar()
303         instead of SegmentedString '*' operator.
304         * html/parser/HTMLEntityParser.cpp: Changed to use currentChar() instead of
305         SegmentedString '*' operator.
306         * html/parser/HTMLParserIdioms.cpp:
307         (WebCore::stripLeadingAndTrailingHTMLSpaces): Added 8-bit fast path.
308         * html/parser/HTMLSourceTracker.cpp:
309         (WebCore::HTMLSourceTracker::sourceForToken): Changed to use currentChar() instead of
310         SegmentedString '*' operator.
311         * loader/cache/CachedScript.cpp:
312         (WebCore::CachedScript::script): Updated to use new String::dataSize() method.
313         * platform/text/SegmentedString.cpp:
314         (WebCore::SegmentedString::SegmentedString):
315         (WebCore::SegmentedString::operator=):
316         (WebCore::SegmentedString::clear):
317         (WebCore::SegmentedString::append):
318         (WebCore::SegmentedString::prepend):
319         (WebCore::SegmentedString::advanceSubstring):
320         (WebCore::SegmentedString::advance): Changed to be a wrapper that invokes current 
321         advance function.
322         (WebCore::SegmentedString::advance8): Fast path advance function for 8 bit data.
323         (WebCore::SegmentedString::advance16): Fast path advance function for 16 bit data.
324         (WebCore::SegmentedString::advanceAndUpdateLineNumber8IncludeLineNumbers): Fast
325         path advanceAndUpdateLineNumber for 8 bit data when we need to update the line number.
326         (WebCore::SegmentedString::advanceAndUpdateLineNumber16IncludeLineNumbers): Fast
327         path advanceAndUpdateLineNumber for 16 bit data when we need to update the line number.
328         (WebCore::SegmentedString::advanceSlowCase): Slow case advance function for both
329         8 and 16 bit advance.
330         (WebCore::SegmentedString::advanceAndUpdateLineNumberSlowCase): Slow case
331         advanceAndUpdateLineNumber function for both 8 and 16 bit data.
332         (WebCore::SegmentedString::advanceEmpty): Advance function when input has been exhausted.
333         * platform/text/SegmentedString.h:
334         (WebCore::SegmentedSubstring::SegmentedSubstring):
335         (WebCore::SegmentedSubstring::clear):
336         (SegmentedSubstring):
337         (WebCore::SegmentedSubstring::is8Bit): New getter.
338         (WebCore::SegmentedSubstring::appendTo):
339         (WebCore::SegmentedSubstring::getCurrentChar8): New getter for the 8 bit case.
340         (WebCore::SegmentedSubstring::getCurrentChar16): New getter for the 16 bit case.
341         (WebCore::SegmentedSubstring::incrementAndGetCurrentChar8): New wrapper functions
342         that pre-increments the 8 bit pointer and returns the next character.
343         (WebCore::SegmentedSubstring::incrementAndGetCurrentChar16): New wrapper functions
344         that pre-increments the 16 bit pointer and returns the next character.
345         (WebCore::SegmentedSubstring::currentSubString):
346         (WebCore::SegmentedSubstring::getCurrentChar):
347         (WebCore::SegmentedSubstring::incrementAndGetCurrentChar):
348         (WebCore::SegmentedString::SegmentedString):
349         (WebCore::SegmentedString::push):
350         (WebCore::SegmentedString::isEmpty):
351         (WebCore::SegmentedString::lookAhead):
352         (WebCore::SegmentedString::lookAheadIgnoringCase):
353         (WebCore::SegmentedString::advance):
354         (WebCore::SegmentedString::advanceAndUpdateLineNumber):
355         (WebCore::SegmentedString::advanceAndASSERT):
356         (WebCore::SegmentedString::advanceAndASSERTIgnoringCase):
357         (WebCore::SegmentedString::advancePastNonNewline):
358         (WebCore::SegmentedString::advancePastNewlineAndUpdateLineNumber):
359         (WebCore::SegmentedString::currentChar):
360         (WebCore::SegmentedString::setSlowCase): Set advance function pointers to slow case
361         functions.
362         (WebCore::SegmentedString::decrementAndCheckLength): Decrement substring length and
363         change to slow case functions when only one character left.
364         (WebCore::SegmentedString::setAdvanceFunctionPointers): Select appropriate advance
365         functions based on current substring.
366         (WebCore::SegmentedString::lookAheadInline): Changed to use String::startsWith().
367         (WebCore::SegmentedString::lookAheadSlowCase):
368         * xml/parser/CharacterReferenceParserInlineMethods.h:
369         (WebCore::consumeCharacterReference): Changed to use currentChar() instead of
370         SegmentedString '*' operator.
371         * xml/parser/MarkupTokenizerBase.h:
372         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::nextInputCharacter):
373         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::peek): Changed to use
374         currentChar() instead of SegmentedString '*' operator.
375         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::advance):
376
377 2012-07-25  Sheriff Bot  <webkit.review.bot@gmail.com>
378
379         Unreviewed, rolling out r123625 and r123672.
380         http://trac.webkit.org/changeset/123625
381         http://trac.webkit.org/changeset/123672
382         https://bugs.webkit.org/show_bug.cgi?id=92315
383
384         Broke Windows and gcc builds (Requested by rniwa on #webkit).
385
386         * platform/AutodrainedPool.h:
387         (AutodrainedPool):
388         * platform/ContentType.h:
389         (ContentType):
390         * platform/ContextMenu.h:
391         (ContextMenu):
392         * platform/ContextMenuItem.h:
393         (ContextMenuItem):
394         * platform/Cursor.h:
395         (WebCore::SharedCursor::SharedCursor):
396         (Cursor):
397         * platform/KURL.h:
398         (WebCore::KURL::KURL):
399         (KURL):
400         * platform/KURLGooglePrivate.h:
401         (KURLGooglePrivate):
402         * platform/PODRedBlackTree.h:
403         (WebCore::PODRedBlackTree::PODRedBlackTree):
404         * platform/Pasteboard.h:
405         (Pasteboard):
406         * platform/PlatformEvent.h:
407         (WebCore::PlatformEvent::PlatformEvent):
408         * platform/PlatformKeyboardEvent.h:
409         (PlatformKeyboardEvent):
410         * platform/PlatformMouseEvent.h:
411         (PlatformMouseEvent):
412         * platform/PlatformPasteboard.h:
413         (PlatformPasteboard):
414         * platform/PlatformTouchEvent.h:
415         (PlatformTouchEvent):
416         * platform/PlatformWheelEvent.h:
417         (PlatformWheelEvent):
418         * platform/RunLoop.h:
419         (TimerBase):
420         * platform/ScrollAnimator.h:
421         (ScrollAnimator):
422         * platform/ScrollAnimatorNone.h:
423         (ScrollAnimatorNone):
424         * platform/SharedBuffer.h:
425         (SharedBuffer):
426         * platform/WheelFlingPlatformGestureCurve.h:
427         (WheelFlingPlatformGestureCurve):
428         * platform/Widget.h:
429         (Widget):
430         * platform/network/cf/ResourceRequestCFNet.cpp:
431         (WebCore::ResourceRequest::doUpdateResourceRequest):
432
433 2012-07-25  Ryosuke Niwa  <rniwa@webkit.org>
434
435         Windows build fix attempt after r123625.
436
437         * platform/network/cf/ResourceRequestCFNet.cpp:
438         (WebCore::ResourceRequest::doUpdateResourceRequest):
439
440 2012-07-25  Kwang Yul Seo  <skyul@company100.net>
441
442         Read tag names and attributes from the saved tokens in HTMLTreeBuilder::resetInsertionModeAppropriately.
443         https://bugs.webkit.org/show_bug.cgi?id=92240
444
445         Reviewed by Adam Barth.
446
447         This is a follow-up patch for r123577. Added ItemType enum to HTMLStackItem to handle
448         the context element case.
449
450         No new tests, covered by existing tests.
451
452         * html/parser/HTMLStackItem.h:
453         (WebCore::HTMLStackItem::create):
454         (WebCore::HTMLStackItem::HTMLStackItem):
455         * html/parser/HTMLTreeBuilder.cpp:
456         (WebCore::HTMLTreeBuilder::HTMLTreeBuilder):
457         (WebCore::HTMLTreeBuilder::resetInsertionModeAppropriately):
458
459 2012-07-25  Nico Weber  <thakis@chromium.org>
460
461         [chromium/mac] Remove mac_bundle_resources section from WebCore.gyp
462         https://bugs.webkit.org/show_bug.cgi?id=92207
463
464         Reviewed by Tony Chang.
465
466         It's no longer needed after http://crrev.com/148290 and
467         http://crrev.com/148187.
468
469         * WebCore.gyp/WebCore.gyp:
470
471 2012-07-25  Dana Jansens  <danakj@chromium.org>
472
473         [chromium] Move WebFilterOperations from RenderPassDrawQuad to RenderPass
474         https://bugs.webkit.org/show_bug.cgi?id=91885
475
476         Reviewed by Adrienne Walker.
477
478         We move the filter operations to CCRenderPass to avoid having
479         variable-length data in a WebCompositorQuad in order to serialize,
480         and also to avoid requiring a virtual destructor for the quad
481         classes.
482
483         The drawFrame method now takes a CCRenderPassIdHashMap in order
484         to connect RenderPass quads to their source RenderPass.
485
486         Covered by existing tests.
487
488         * platform/graphics/chromium/LayerRendererChromium.cpp:
489         (WebCore::LayerRendererChromium::decideRenderPassAllocationsForFrame):
490         (WebCore::LayerRendererChromium::drawFrame):
491         (WebCore::LayerRendererChromium::beginDrawingFrame):
492         (WebCore::LayerRendererChromium::drawBackgroundFilters):
493         (WebCore::LayerRendererChromium::drawRenderPassQuad):
494         * platform/graphics/chromium/LayerRendererChromium.h:
495         (LayerRendererChromium):
496         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
497         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
498         (WebCore::CCLayerTreeHostImpl::drawLayers):
499         * platform/graphics/chromium/cc/CCRenderPass.h:
500         (WebCore::CCRenderPass::filters):
501         (WebCore::CCRenderPass::setFilters):
502         (CCRenderPass):
503         (WebCore::CCRenderPass::backgroundFilters):
504         (WebCore::CCRenderPass::setBackgroundFilters):
505         * platform/graphics/chromium/cc/CCRenderPassDrawQuad.cpp:
506         (WebCore::CCRenderPassDrawQuad::create):
507         (WebCore::CCRenderPassDrawQuad::CCRenderPassDrawQuad):
508         * platform/graphics/chromium/cc/CCRenderPassDrawQuad.h:
509         (CCRenderPassDrawQuad):
510         * platform/graphics/chromium/cc/CCRenderSurface.cpp:
511         (WebCore::CCRenderSurface::appendQuads):
512         * platform/graphics/chromium/cc/CCRenderer.h:
513         (CCRenderer):
514
515 2012-07-25  Mike Reed  <reed@google.com>
516
517         fix test in beginLayerClippedToImage to check for immutability if we're going to do a shallow-copy
518         https://bugs.webkit.org/show_bug.cgi?id=92276
519
520         Reviewed by Stephen White.
521
522         PlatformContextSkia::beginLayerClippedToImage
523
524         This function wants to apply the provided ImageBuffer as a clip. Skia does not support this natively yet,
525         so the code makes a "copy" of that imageBuffer, to be applied later. The old code, wanting to avoid a
526         deep copy if possible, checked for the presence of a SkPixelRef. If it found one, it made a shallow copy.
527         This is flawed, since the contents of a pixelref are not guaranteed to be immutable. The new code checks
528         against this attribute: if the bitmap is "immutable" then we can make a shallow-copy, else we make a
529         deep copy.
530
531         No new tests. Existing svg layouttests work w/ or w/out this change, but at the next Skia deps roll, we see
532         failures w/o this change. The change is more "correct", though the problem case does not exhibit itself until
533         Skia rev. 4722 or later lands.
534
535         * platform/graphics/skia/PlatformContextSkia.cpp:
536         (WebCore::PlatformContextSkia::beginLayerClippedToImage):
537
538 2012-07-25  Li Yin  <li.yin@intel.com>
539
540         It is invalid when both numberOfInputChannels and numberOfOutputChannels to be zero in JavaScriptAudioNode.
541         https://bugs.webkit.org/show_bug.cgi?id=91364
542
543         Reviewed by Kenneth Russell.
544
545         Spec: http://www.w3.org/TR/webaudio/#JavaScriptAudioNode-section
546         It is invalid for both numberOfInputChannels and numberOfOutputChannels to be zero.
547
548         Test: webaudio/javascriptaudionode.html
549
550         * Modules/webaudio/JavaScriptAudioNode.cpp:
551         (WebCore::JavaScriptAudioNode::create):
552
553 2012-07-24  Shawn Singh  <shawnsingh@chromium.org>
554
555         [chromium] Refactor CCLayerTreeHostCommon: move root layer special case initialization into internal code.
556         https://bugs.webkit.org/show_bug.cgi?id=88953
557
558         Reviewed by Adrienne Walker.
559
560         This is part 1 of trying to reduce the root layer special
561         case. This tries to reduce the special-ness of the root layer from
562         the perspective of outside code.
563
564         After this patch, code that uses calcDrawTransforms() no longer
565         needs to initialize the root layer's surface, and no longer needs
566         to manually append the root layer to the renderSurfaceLayerList.
567
568         Unit tests were also updated (much cleaner!) to account for this change.
569
570         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
571         (WebCore::CCLayerTreeHost::updateLayers):
572         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
573         (WebCore):
574         (WebCore::setupRootLayerAndSurfaceForRecursion):
575         (WebCore::CCLayerTreeHostCommon::calculateDrawTransforms):
576         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.h:
577         (CCLayerTreeHostCommon):
578         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
579         (WebCore::CCLayerTreeHostImpl::calculateRenderSurfaceLayerList):
580
581 2012-07-25  Taiju Tsuiki  <tzik@chromium.org>
582
583         FileSystem should provide a way to delete filesystem.
584         https://bugs.webkit.org/show_bug.cgi?id=91861
585
586         Reviewed by Adam Barth.
587
588         We will add a test when we wire-up the feature to Inspector.
589
590         * Modules/filesystem/LocalFileSystem.cpp: Add deleteFileSystem
591         (WebCore::deleteFileSystem):
592         (WebCore):
593         (WebCore::LocalFileSystem::deleteFileSystem):
594         * Modules/filesystem/LocalFileSystem.h:
595         (LocalFileSystem):
596         * platform/AsyncFileSystem.cpp: Add deleteFileSystem
597         (WebCore):
598         (WebCore::AsyncFileSystem::deleteFileSystem):
599         * platform/AsyncFileSystem.h:
600         (AsyncFileSystem):
601         * platform/blackberry/AsyncFileSystemBlackBerry.cpp: Add deleteFileSystem
602         (WebCore::AsyncFileSystem::deleteFileSystem):
603         (WebCore):
604         * platform/gtk/AsyncFileSystemGtk.cpp: Add deleteFileSystem
605         (WebCore::AsyncFileSystem::deleteFileSystem):
606         (WebCore):
607
608 2012-07-25  Andrey Adaikin  <aandrey@chromium.org>
609
610         Web Inspector: Add more jsdocs to InjectedScriptSource.js
611         https://bugs.webkit.org/show_bug.cgi?id=92255
612
613         Reviewed by Pavel Feldman.
614
615         * inspector/InjectedScriptSource.js:
616
617 2012-07-24  Dana Jansens  <danakj@chromium.org>
618
619         [chromium] Turn the debug HUD into a layer so that it can be drawn as a WebCompositorQuad
620         https://bugs.webkit.org/show_bug.cgi?id=92182
621
622         Reviewed by Adrienne Walker.
623
624         By changing the HUD into a quad, we are able to create a HUD and pass
625         it to the host compositor, allowing the HUD to be used for renderers
626         under Ubercompositor.
627
628         This also removes the special drawing code for the HUD from
629         LayerRendererChromium, allowing us to move finishDrawingFrame
630         into LayerRendererChromium as a private method and remove it
631         from the CCRenderer interface.
632
633         Finally, we can remove the CCFontAtlas transport code from CCProxy
634         and its implementations as the atlas can be synced to impl thread
635         through the usual layer commit mechanism.
636
637         The debug HUD is not covered by tests.
638
639         * WebCore.gypi:
640         * platform/graphics/chromium/HeadsUpDisplayLayerChromium.cpp: Added.
641         (WebCore):
642         (WebCore::HeadsUpDisplayLayerChromium::create):
643         (WebCore::HeadsUpDisplayLayerChromium::HeadsUpDisplayLayerChromium):
644         (WebCore::HeadsUpDisplayLayerChromium::~HeadsUpDisplayLayerChromium):
645         (WebCore::HeadsUpDisplayLayerChromium::createCCLayerImpl):
646         * platform/graphics/chromium/HeadsUpDisplayLayerChromium.h: Added.
647         (WebCore):
648         (HeadsUpDisplayLayerChromium):
649         * platform/graphics/chromium/LayerRendererChromium.cpp:
650         (WebCore::LayerRendererChromium::drawFrame):
651         (WebCore::LayerRendererChromium::cleanupSharedObjects):
652         * platform/graphics/chromium/LayerRendererChromium.h:
653         (LayerRendererChromium):
654         * platform/graphics/chromium/cc/CCDebugRectHistory.cpp:
655         (WebCore::CCDebugRectHistory::savePropertyChangedRects):
656         * platform/graphics/chromium/cc/CCDebugRectHistory.h:
657         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.cpp: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp.
658         (WebCore):
659         (WebCore::CCHeadsUpDisplayLayerImpl::CCHeadsUpDisplayLayerImpl):
660         (WebCore::CCHeadsUpDisplayLayerImpl::~CCHeadsUpDisplayLayerImpl):
661         (WebCore::CCHeadsUpDisplayLayerImpl::willDraw):
662         (WebCore::CCHeadsUpDisplayLayerImpl::appendQuads):
663         (WebCore::CCHeadsUpDisplayLayerImpl::didDraw):
664         (WebCore::CCHeadsUpDisplayLayerImpl::didLoseContext):
665         (WebCore::CCHeadsUpDisplayLayerImpl::drawHudContents):
666         (WebCore::CCHeadsUpDisplayLayerImpl::drawFPSCounter):
667         (WebCore::CCHeadsUpDisplayLayerImpl::drawFPSCounterText):
668         (WebCore::CCHeadsUpDisplayLayerImpl::drawDebugRects):
669         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.h: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCHeadsUpDisplay.h.
670         (WebCore):
671         (CCHeadsUpDisplayLayerImpl):
672         (WebCore::CCHeadsUpDisplayLayerImpl::create):
673         * platform/graphics/chromium/cc/CCLayerImpl.h:
674         (WebCore::CCLayerImpl::layerIsAlwaysDamaged):
675         This flag is used to mark the HUD as always damaged, so that it is
676         continually drawn on the impl thread. It is also used as a hint by
677         the CCDebugRectHistory class to not include the layer in the display
678         of damage, since always damaged is not interesting damage.
679         (CCLayerImpl):
680         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
681         (WebCore::CCLayerTreeHost::create):
682         (WebCore::CCLayerTreeHost::CCLayerTreeHost):
683         (WebCore::CCLayerTreeHost::initialize):
684         (WebCore::CCLayerTreeHost::willCommit):
685         (WebCore::CCLayerTreeHost::didCommit):
686         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
687         (CCLayerTreeSettings):
688         (WebCore::CCLayerTreeSettings::showDebugInfo):
689         (WebCore::CCLayerTreeSettings::showDebugRects):
690         (CCLayerTreeHost):
691         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
692         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
693         (WebCore::CCLayerTreeHostImpl::drawLayers):
694         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
695         (WebCore):
696         (CCLayerTreeHostImpl):
697         * platform/graphics/chromium/cc/CCProxy.h:
698         (CCProxy):
699         * platform/graphics/chromium/cc/CCRenderer.h:
700         (CCRenderer):
701         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
702         * platform/graphics/chromium/cc/CCSingleThreadProxy.h:
703         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
704         * platform/graphics/chromium/cc/CCThreadProxy.h:
705         (CCThreadProxy):
706
707 2012-07-25  'Pavel Feldman'  <pfeldman@chromium.org>
708
709         Web Inspector: follow up to r123612, fixing CSS value suggest.
710
711         Not reviewed, minor JS fix.
712
713         * inspector/front-end/CSSCompletions.js:
714         (WebInspector.CSSCompletions):
715         * inspector/front-end/StylesSidebarPane.js:
716         (WebInspector.StylePropertyTreeElement.prototype):
717
718 2012-07-25  Michael Saboff  <msaboff@apple.com>
719
720         Unreviewed build fix after r123624.
721
722         * inspector/InspectorPageAgent.cpp:
723         (WebCore::InspectorPageAgent::clearGeolocationOverride):
724         Changed ASSERT_UNUSED() to UNUSED_PARAM().
725
726 2012-07-25  Pavel Feldman  <pfeldman@chromium.org>
727
728         Web inspector auto-completes "optimizequality" but then complains
729         https://bugs.webkit.org/show_bug.cgi?id=92262
730
731         Reviewed by Timothy Hatcher.
732
733         Fixed optimizeSpeed, optimizeLegibility, geometricPrecision.
734
735         * inspector/front-end/CSSKeywordCompletions.js:
736
737 2012-07-25  Beth Dakin  <bdakin@apple.com>
738
739         https://bugs.webkit.org/show_bug.cgi?id=89114
740         REGRESSION (r112919): Setting scrollTop after setting display from none to block 
741         fails
742         -and corresponding-
743         <rdar://problem/11656050>
744
745         Reviewed by Simon Fraser.
746
747         ScrollAnimatorMac::immediateScrollTo() and ScrollAnimatorMac::immediateScrollBy() 
748         both have an optimization in place so that they do not call 
749         notifyPositionChanged() if the new scroll offset matches the ScrollAnimator's 
750         cached m_currentPosX and m_currentPosY. So revision 112919 caused troubled with 
751         this optimization because it allowed RenderLayers to restore a scrollOffset from 
752         the Element if there is one cached there. This caused the RenderLayer to have a 
753         scrollOffset that is improperly out-of-synch with the ScrollAnimator's 
754         currentPosition (which will just be 0,0 since it is being re-created like the 
755         RenderLayer). This fix makes sure they are in synch by calling 
756         setCurrentPosition() on the ScrollAnimator when the cached position is non-zero.
757         * rendering/RenderLayer.cpp:
758         (WebCore::RenderLayer::RenderLayer):
759
760 2012-07-25  Andreas Kling  <kling@webkit.org>
761
762         Make ElementAttributeData a variable-sized object to reduce memory use.
763         <http://webkit.org/b/88240>
764
765         Reviewed by Ryosuke Niwa.
766
767         Take advantage of the fact that we know at ElementAttributeData construction time how many attributes
768         it needs to accomodate and allocate exactly as much space as needed instead of using a Vector.
769         For elements that never have their attribute list mutated (the vast majority), this saves a lot of
770         memory and removes the indirection to Vector<Attribute>'s heap-allocated storage.
771
772         Introduced a mutability flag to ElementAttributeData and sprinkled assertions all over to make sure
773         that nothing tries to mutate an element with a raw attribute array.
774
775         When an Element's attribute(s) are mutated, we reconstruct the ElementAttributeData, this time using
776         a Vector as backing instead. This is triggered when calling Element::mutableAttributeData().
777
778         This reduces memory consumption by 3.2MB when viewing the full HTML5 spec at <http://whatwg.org/c/>.
779         That is a ~35% reduction in DOM attribute memory use.
780
781         Furthermore, that page ends up promoting 27% of the elements to mutable attribute storage due to dynamic
782         adding of "class" attributes. For more static pages, savings are even greater.
783
784         Also did away with ElementAttributeData::removeAttribute(name) and do separate index lookup where
785         needed. Not a big deal but avoids double lookup of attributes when removing them.
786
787         * dom/Element.cpp:
788         (WebCore::Element::detachAttribute):
789         (WebCore::Element::removeAttribute):
790         (WebCore::Element::attributes):
791         (WebCore::Element::setAttributeInternal):
792         (WebCore::Element::parserSetAttributes):
793         (WebCore::Element::hasEquivalentAttributes):
794         (WebCore::Element::setAttributeNode):
795         (WebCore::Element::removeAttributeNode):
796         (WebCore::Element::getAttributeNode):
797         (WebCore::Element::getAttributeNodeNS):
798         (WebCore::Element::hasAttribute):
799         (WebCore::Element::hasAttributeNS):
800         (WebCore::Element::cloneAttributesFromElement):
801
802             Sprinkle const on ElementAttributeData* pointers.
803             Switch to using mutableAttributeData() in code paths that modify attributes.
804
805         (WebCore::Element::normalizeAttributes):
806
807             Cleaner iteration over attributes, I removed ElementAttributeData::attributeVector() since that
808             was just incurring a bunch of extra Vector copying. Since ElementAttributeData already exposes
809             length() and attributeItem(index), use those to iterate directly over the attributes.
810
811         (WebCore::Element::createMutableAttributeData):
812
813             Added, converts existing ElementAttributeData to a mutable object. Otherwise creates a new
814             ElementAttributeData (mutable and empty.)
815
816         * dom/Element.h:
817         (WebCore::Element::attributeData):
818         (WebCore::Element::updatedAttributeData):
819         (WebCore::Element::ensureAttributeData):
820         (WebCore::Element::ensureUpdatedAttributeData):
821
822             Made all of these return "const ElementAttributeData*" to ensure at compile-time that nothing
823             attempts to modify an ElementAttributeData that may be immutable.
824
825             ensureUpdatedAttributeData() is still const, despite possibly calling mutableAttributeData().
826             The goal of having methods be const is to prevent conversion from one ElementAttributeData
827             object to another, so that pointers remain intact and no unnecessary work gets done.
828
829         (WebCore::Element::mutableAttributeData):
830
831             Added, returns a guaranteed mutable ElementAttributeData* pointer.
832
833         * dom/ElementAttributeData.cpp:
834         (WebCore::ElementAttributeData::createImmutable):
835
836             Creates a new ElementAttributeData tailored to fit the provided Vector<Attribute>.
837
838         (WebCore::ElementAttributeData::ElementAttributeData):
839
840             Moved constructors out-of-line, getting too complex for header files.
841
842             ElementAttributeData(const Vector<Attribute>&) creates an immutable ElementAttributeData
843             containing the provided attributes in an array tacked onto the end of the object.
844
845         (WebCore::ElementAttributeData::~ElementAttributeData):
846
847             Free the attribute vector if mutable.
848             For immutable objects, manually invoke destructor on each Attribute object,
849             since these won't be destroyed automatically by ~ElementAttributeData.
850
851         (WebCore::ElementAttributeData::attrIfExists):
852
853         (WebCore::ElementAttributeData::ensureAttr):
854         (WebCore::ElementAttributeData::setAttr):
855         (WebCore::ElementAttributeData::removeAttr):
856
857             Make these const, as they should always have been- they don't affect the ElementAttributeData,
858             only the global DOM Attr <-> ElementAttributeData mappings.
859
860         (WebCore::ElementAttributeData::ensureInlineStyle):
861         (WebCore::ElementAttributeData::ensureMutableInlineStyle):
862
863             Sprinkle ASSERT(isMutable()). This doesn't mean that all Elements with inline styles automatically
864             have mutable attribute data. There's still inlineStyle() for that, which may return null.
865             These are only for use where you need a valid StylePropertySet*, even if there is no inline style
866             attribute, e.g in editing code that wants to add style.
867
868         (WebCore::ElementAttributeData::updateInlineStyleAvoidingMutation):
869         (WebCore::ElementAttributeData::destroyInlineStyle):
870
871             Make these const. While destroyInlineStyle() doesn't sound very const-y, immutable objects that
872             contain a style attribute will have a valid inlineStyle() with that style data. This is just
873             an interface for ~StyledElement to destroy the style object.
874             It'd be nice to do that in ~ElementAttributeData(), but we need a StyledElement* pointer to
875             clean up properly and we don't store one in this class.
876
877         (WebCore::ElementAttributeData::addAttribute):
878         (WebCore::ElementAttributeData::removeAttribute):
879         (WebCore::ElementAttributeData::clearAttributes):
880         (WebCore::ElementAttributeData::replaceAttribute):
881
882             Sprinkle ASSERT(isMutable()).
883             Always go straight for m_mutableAttributeVector since we know that's the storage being used.
884
885         (WebCore::ElementAttributeData::isEquivalent):
886         (WebCore::ElementAttributeData::detachAttrObjectsFromElement):
887         (WebCore::ElementAttributeData::getAttributeItemIndexSlowCase):
888         (WebCore::ElementAttributeData::removeAttribute):
889         (WebCore::ElementAttributeData::getAttributeItem):
890         (WebCore::ElementAttributeData::getAttributeItemIndex):
891
892             Use length() and attributeItem(index) to iterate over the attributes.
893
894         (WebCore::ElementAttributeData::cloneDataFrom):
895
896             Sprinkle ASSERT(isMutable()). Added a FIXME that cloning elements could create immutable
897             attribute data. I'm not sure this optimization is worthwhile, as cloning elements is already
898             a semi-rare occurrence.
899
900             Updated code to handle both immutable and mutable source objects. This could 
901
902         (WebCore::ElementAttributeData::getAttributeNode):
903
904             Const correctness.
905
906         * dom/ElementAttributeData.h:
907         (ElementAttributeData):
908
909             Turn attribute storage into what's effectively union { OwnPtr<Vector<Attribute>>; Attribute[]; }
910             The new m_isMutable bit determines which union member should be used for access.
911
912         (WebCore::ElementAttributeData::create):
913         (WebCore::ElementAttributeData::createImmutable):
914
915             Added createImmutable(const Vector<Attribute>&) as a complement to create().
916
917         (WebCore::ElementAttributeData::setClass):
918         (WebCore::ElementAttributeData::setIdForStyleResolution):
919         (WebCore::ElementAttributeData::inlineStyle):
920         (WebCore::ElementAttributeData::setAttributeStyle):
921
922             Make these const, and their data member counterparts 'mutable'.
923             An immutable ElementAttributeData object still has m_classNames, m_idForStyleResolution,
924             m_inlineStyleDecl and m_attributeStyle.
925
926         (WebCore::ElementAttributeData::reportMemoryUsage):
927
928             Updated for isMutable().
929
930         (WebCore::ElementAttributeData::makeMutable):
931
932             Returns a mutable clone of itself.
933
934         (WebCore::ElementAttributeData::isEmpty):
935         (WebCore::ElementAttributeData::length):
936         (WebCore::ElementAttributeData::attributeItem):
937
938             Check isMutable() to know how to access attribute storage.
939
940         * dom/StyledElement.cpp:
941         (WebCore::StyledElement::style):
942         (WebCore::StyledElement::setInlineStyleProperty):
943
944             Simplify by using StyledElement::ensureInlineStyle().
945
946         (WebCore::StyledElement::classAttributeChanged):
947
948             Use mutableAttributeData() if the attribute is being removed completely.
949             In other cases, tiptoe around without causing the attribute data to go mutable.
950
951         (WebCore::StyledElement::removeInlineStyleProperty):
952
953             Use mutableAttributeData() if/when actually removing something.
954
955         (WebCore::StyledElement::addSubresourceAttributeURLs):
956
957             Const correctness.
958
959         * dom/StyledElement.h:
960         (WebCore::StyledElement::ensureInlineStyle):
961
962             This now implies conversion to mutable attribute data. Used by codepaths that add/remove
963             properties, so conversion is inevitable.
964
965         * html/parser/HTMLConstructionSite.cpp:
966         (WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement):
967         (WebCore::HTMLConstructionSite::createHTMLElementFromSavedElement):
968         * svg/properties/SVGAnimatedPropertyMacros.h:
969         (WebCore::SVGSynchronizableAnimatedProperty::synchronize):
970
971             Use mutableAttributeData() as appropriate.
972
973         * xml/parser/XMLDocumentParserQt.cpp:
974         (WebCore::XMLDocumentParser::XMLDocumentParser):
975
976             Const correctness.
977
978 2012-07-25  Andrew Wilson  <atwilson@chromium.org>
979
980         Unreviewed, rolling out r123560.
981         http://trac.webkit.org/changeset/123560
982         https://bugs.webkit.org/show_bug.cgi?id=90321
983
984         Breaks chromium valgrind tests.
985
986         * html/FTPDirectoryDocument.cpp:
987         (WebCore::FTPDirectoryDocumentParser::append):
988         * html/parser/HTMLEntityParser.cpp:
989         (WebCore::HTMLEntityParser::consumeNamedEntity):
990         * html/parser/HTMLParserIdioms.cpp:
991         (WebCore::stripLeadingAndTrailingHTMLSpaces):
992         * html/parser/HTMLSourceTracker.cpp:
993         (WebCore::HTMLSourceTracker::sourceForToken):
994         * loader/cache/CachedScript.cpp:
995         (WebCore::CachedScript::script):
996         * platform/text/SegmentedString.cpp:
997         (WebCore::SegmentedString::SegmentedString):
998         (WebCore::SegmentedString::operator=):
999         (WebCore::SegmentedString::clear):
1000         (WebCore::SegmentedString::append):
1001         (WebCore::SegmentedString::prepend):
1002         (WebCore::SegmentedString::advanceSubstring):
1003         (WebCore::SegmentedString::advance):
1004         (WebCore::SegmentedString::advanceSlowCase):
1005         (WebCore::SegmentedString::advanceAndUpdateLineNumberSlowCase):
1006         * platform/text/SegmentedString.h:
1007         (WebCore::SegmentedSubstring::SegmentedSubstring):
1008         (WebCore::SegmentedSubstring::clear):
1009         (WebCore::SegmentedSubstring::appendTo):
1010         (SegmentedSubstring):
1011         (WebCore::SegmentedString::SegmentedString):
1012         (WebCore::SegmentedString::push):
1013         (WebCore::SegmentedString::isEmpty):
1014         (WebCore::SegmentedString::lookAhead):
1015         (WebCore::SegmentedString::lookAheadIgnoringCase):
1016         (WebCore::SegmentedString::advance):
1017         (WebCore::SegmentedString::advanceAndASSERT):
1018         (WebCore::SegmentedString::advanceAndASSERTIgnoringCase):
1019         (WebCore::SegmentedString::advancePastNewlineAndUpdateLineNumber):
1020         (SegmentedString):
1021         (WebCore::SegmentedString::advancePastNonNewline):
1022         (WebCore::SegmentedString::advanceAndUpdateLineNumber):
1023         (WebCore::SegmentedString::operator*):
1024         (WebCore::SegmentedString::operator->):
1025         (WebCore::SegmentedString::current):
1026         (WebCore::SegmentedString::equalsLiterally):
1027         (WebCore::SegmentedString::equalsIgnoringCase):
1028         (WebCore::SegmentedString::lookAheadInline):
1029         (WebCore::SegmentedString::lookAheadSlowCase):
1030         * xml/parser/CharacterReferenceParserInlineMethods.h:
1031         (WebCore::consumeCharacterReference):
1032         * xml/parser/MarkupTokenizerBase.h:
1033         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::nextInputCharacter):
1034         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::peek):
1035         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::advance):
1036
1037 2012-07-25  Konrad Piascik  <kpiascik@rim.com>
1038
1039         Web Inspector: Geolocation override
1040         https://bugs.webkit.org/show_bug.cgi?id=89365
1041
1042         Reviewed by Pavel Feldman.
1043
1044         Re-added the m_page member variable for GeolocationController since
1045         it's now being used by InspectorInstrumentaiton.
1046
1047         Added a way to override the GeolocationPosition and GeolocationError
1048         using Web Inspector. Curretnly only PositionError can be set.
1049
1050         This will be hidden behind the experiments flag for now.
1051
1052         Tests: inspector/geolocation-error.html
1053                inspector/geolocation-success.html
1054                inspector/geolocation-watchPosition.html
1055
1056         * English.lproj/localizedStrings.js:
1057         * Modules/geolocation/GeolocationController.cpp:
1058         (WebCore::GeolocationController::GeolocationController):
1059         (WebCore::GeolocationController::positionChanged):
1060         * Modules/geolocation/GeolocationController.h:
1061         (GeolocationController):
1062         * inspector/Inspector.json:
1063         * inspector/InspectorInstrumentation.cpp:
1064         (WebCore):
1065         (WebCore::InspectorInstrumentation::overrideGeolocationPositionImpl):
1066         * inspector/InspectorInstrumentation.h:
1067         (WebCore):
1068         (InspectorInstrumentation):
1069         (WebCore::InspectorInstrumentation::overrideGeolocationPosition):
1070         * inspector/InspectorPageAgent.cpp:
1071         (WebCore::InspectorPageAgent::InspectorPageAgent):
1072         (WebCore::InspectorPageAgent::setGeolocationOverride):
1073         (WebCore):
1074         (WebCore::InspectorPageAgent::clearGeolocationOverride):
1075         (WebCore::InspectorPageAgent::canOverrideGeolocation):
1076         (WebCore::InspectorPageAgent::overrideGeolocationPosition):
1077         * inspector/InspectorPageAgent.h:
1078         * inspector/front-end/Settings.js:
1079         * inspector/front-end/SettingsScreen.js:
1080         (WebInspector.UserAgentSettingsTab):
1081         (WebInspector.UserAgentSettingsTab.prototype._createDeviceMetricsElement):
1082         (WebInspector.UserAgentSettingsTab.prototype._onGeolocationOverrideCheckboxClicked):
1083         (WebInspector.UserAgentSettingsTab.prototype._applyGeolocationUserInput):
1084         (WebInspector.UserAgentSettingsTab.prototype._setGeolocationPosition.set if):
1085         (WebInspector.UserAgentSettingsTab.prototype._setGeolocationPosition):
1086         (WebInspector.UserAgentSettingsTab.prototype._createGeolocationOverrideElement.createInput):
1087         (WebInspector.UserAgentSettingsTab.prototype._createGeolocationOverrideElement):
1088         * inspector/front-end/UserAgentSupport.js:
1089         (WebInspector.UserAgentSupport.GeolocationPosition):
1090         (WebInspector.UserAgentSupport.GeolocationPosition.prototype.toSetting):
1091         (WebInspector.UserAgentSupport.GeolocationPosition.parseSetting):
1092         (WebInspector.UserAgentSupport.GeolocationPosition.parseUserInput):
1093         (WebInspector.UserAgentSupport.GeolocationPosition.clearGeolocationOverride):
1094         * inspector/front-end/inspector.js:
1095         (WebInspector.doLoadedDone):
1096
1097 2012-07-25  Shawn Singh  <shawnsingh@chromium.org>
1098
1099         [chromium] Build fix for clang builds after r123628
1100         https://bugs.webkit.org/show_bug.cgi?id=92266
1101
1102         Reviewed by Adrienne Walker.
1103
1104         An un-used variable was causing build failures for clang builds
1105         after the refactoring in r123628.  It is correct to simply remove
1106         this value.
1107
1108         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
1109         (WebCore::calculateDrawTransformsInternal):
1110
1111 2012-07-25  Hans Wennborg  <hans@chromium.org>
1112
1113         Speech JavaScript API: extract function from SpeechRecognitionResult::emma()
1114         https://bugs.webkit.org/show_bug.cgi?id=92232
1115
1116         Reviewed by Adam Barth.
1117
1118         Extract code for creating emma-qualified names to a helper function.
1119
1120         Just a refactoring; covered by the existing test.
1121
1122         * Modules/speech/SpeechRecognitionResult.cpp:
1123         (WebCore::emmaQualifiedName):
1124         (WebCore):
1125         (WebCore::SpeechRecognitionResult::emma):
1126
1127 2012-07-25  Adrienne Walker  <enne@google.com>
1128
1129         [chromium] Unify compositor quadTransform/drawTransform/originTransform
1130         https://bugs.webkit.org/show_bug.cgi?id=91417
1131
1132         Reviewed by Kenneth Russell.
1133
1134         drawTransform used to operate on centered layer rects. To unify quad
1135         transforms, draw transforms, and origin transforms, make draw
1136         transforms operate on content rects with the origin in the top left.
1137
1138         This essentially eliminates the need for surface origin transforms,
1139         which will be eliminated in a future patch.
1140
1141         Also, remove the unused CCLayerImpl::getDrawRect function.
1142
1143         No-op refactoring. Tested by existing tests.
1144
1145         * platform/graphics/chromium/LayerRendererChromium.cpp:
1146         (WebCore::LayerRendererChromium::drawRenderPassQuad):
1147         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
1148         (WebCore::RenderSurfaceChromium::drawableContentRect):
1149         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
1150         (WebCore::CCDamageTracker::extendDamageForLayer):
1151         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
1152         (WebCore::CCLayerImpl::createSharedQuadState):
1153         * platform/graphics/chromium/cc/CCLayerImpl.h:
1154         (CCLayerImpl):
1155         * platform/graphics/chromium/cc/CCLayerSorter.cpp:
1156         (WebCore::CCLayerSorter::LayerShape::LayerShape):
1157         (WebCore::CCLayerSorter::createGraphNodes):
1158         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
1159         (WebCore::calculateVisibleContentRect):
1160         (WebCore::calculateDrawTransformsInternal):
1161         * platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
1162         (WebCore::::markOccludedBehindLayer):
1163         (WebCore::::occluded):
1164         (WebCore::::unoccludedContentRect):
1165         * platform/graphics/chromium/cc/CCRenderPass.cpp:
1166         (WebCore::CCRenderPass::appendQuadsToFillScreen):
1167         * platform/graphics/chromium/cc/CCRenderSurface.cpp:
1168         (WebCore::CCRenderSurface::drawableContentRect):
1169
1170 2012-07-25  Tommy Widenflycht  <tommyw@google.com>
1171
1172         MediaStream API: Update MediaStreamTrack to match the specification
1173         https://bugs.webkit.org/show_bug.cgi?id=90180
1174
1175         Reviewed by Adam Barth.
1176
1177         MediaStreamTracks are now required to show the status of the underlying source,
1178         and trigger events when that status changes.
1179
1180         Test: fast/mediastream/MediaStreamTrack.html
1181
1182         * GNUmakefile.list.am:
1183         * Modules/mediastream/MediaStream.cpp:
1184         (WebCore::MediaStream::MediaStream):
1185         (WebCore::MediaStream::addTrack):
1186         * Modules/mediastream/MediaStreamTrack.cpp:
1187         (WebCore::MediaStreamTrack::create):
1188         (WebCore::MediaStreamTrack::MediaStreamTrack):
1189         (WebCore::MediaStreamTrack::~MediaStreamTrack):
1190         (WebCore::MediaStreamTrack::setEnabled):
1191         (WebCore::MediaStreamTrack::readyState):
1192         (WebCore):
1193         (WebCore::MediaStreamTrack::sourceChangedState):
1194         (WebCore::MediaStreamTrack::stop):
1195         (WebCore::MediaStreamTrack::interfaceName):
1196         (WebCore::MediaStreamTrack::scriptExecutionContext):
1197         (WebCore::MediaStreamTrack::eventTargetData):
1198         (WebCore::MediaStreamTrack::ensureEventTargetData):
1199         * Modules/mediastream/MediaStreamTrack.h:
1200         * Modules/mediastream/MediaStreamTrack.idl:
1201         * WebCore.gypi:
1202         * dom/EventNames.h:
1203         (WebCore):
1204         * dom/EventTargetFactory.in:
1205         * platform/chromium/support/WebMediaStreamDescriptor.cpp:
1206         * platform/chromium/support/WebMediaStreamSource.cpp:
1207         (WebKit::WebMediaStreamSource::setReadyState):
1208         (WebKit):
1209         (WebKit::WebMediaStreamSource::readyState):
1210         * platform/mediastream/MediaStreamSource.cpp: Copied from Source/WebCore/platform/mediastream/MediaStreamSource.h.
1211         (WebCore):
1212         (WebCore::MediaStreamSource::create):
1213         (WebCore::MediaStreamSource::MediaStreamSource):
1214         (WebCore::MediaStreamSource::setReadyState):
1215         (WebCore::MediaStreamSource::addObserver):
1216         (WebCore::MediaStreamSource::removeObserver):
1217         * platform/mediastream/MediaStreamSource.h:
1218         (Observer):
1219         (WebCore::MediaStreamSource::Observer::~Observer):
1220         (MediaStreamSource):
1221         (WebCore::MediaStreamSource::readyState):
1222         * platform/mediastream/chromium/MediaStreamCenterChromium.cpp:
1223         (WebCore::MediaStreamCenterChromium::queryMediaStreamSources):
1224         (WebCore::MediaStreamCenterChromium::didCreateMediaStream):
1225
1226 2012-07-25  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1227
1228         Incorrect rounding in ceiledLayoutUnit and roundedLayoutUnit.
1229         https://bugs.webkit.org/show_bug.cgi?id=91061
1230
1231         Reviewed by Adam Barth.
1232
1233         The two functions are currently both returning the flooredLayoutUnit when subpixel
1234         layout is enabled. This patch changes them to return the correct fractional rounded
1235         value.
1236
1237         * platform/FractionalLayoutUnit.h:
1238         (WebCore::FractionalLayoutUnit::fromFloatCeil):
1239         (FractionalLayoutUnit):
1240         (WebCore::FractionalLayoutUnit::fromFloatRound):
1241         * rendering/LayoutTypes.h:
1242         (WebCore::roundedLayoutUnit):
1243         (WebCore::ceiledLayoutUnit):
1244         * rendering/RenderBlock.cpp:
1245         (WebCore::updatePreferredWidth):
1246
1247 2012-07-25  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1248
1249         Add *explicit* keyword to constructors in WebCore/platform
1250         https://bugs.webkit.org/show_bug.cgi?id=92238
1251
1252         Reviewed by Kentaro Hara.
1253
1254         As a step to let *explicit* keyword add to constructors which have a parameter,
1255         *explicit* keyword is added to Source/WebCore/platform in order to avoid implicit
1256         type conversion.
1257
1258         Some files in platform directory can't use explicit keyword because of build breaks.
1259
1260         No new tests. Covered by existing tests.
1261
1262         * platform/AutodrainedPool.h:
1263         (AutodrainedPool):
1264         * platform/ContentType.h:
1265         (ContentType):
1266         * platform/ContextMenu.h:
1267         (ContextMenu):
1268         * platform/ContextMenuItem.h:
1269         (ContextMenuItem):
1270         * platform/Cursor.h:
1271         (WebCore::SharedCursor::SharedCursor):
1272         (Cursor):
1273         * platform/KURL.h:
1274         (WebCore::KURL::KURL):
1275         (KURL):
1276         * platform/KURLGooglePrivate.h:
1277         (KURLGooglePrivate):
1278         * platform/PODRedBlackTree.h:
1279         (WebCore::PODRedBlackTree::PODRedBlackTree):
1280         * platform/Pasteboard.h:
1281         (Pasteboard):
1282         * platform/PlatformEvent.h:
1283         (WebCore::PlatformEvent::PlatformEvent):
1284         * platform/PlatformKeyboardEvent.h:
1285         (PlatformKeyboardEvent):
1286         * platform/PlatformMouseEvent.h:
1287         (PlatformMouseEvent):
1288         * platform/PlatformPasteboard.h:
1289         (PlatformPasteboard):
1290         * platform/PlatformTouchEvent.h:
1291         (PlatformTouchEvent):
1292         * platform/PlatformWheelEvent.h:
1293         (PlatformWheelEvent):
1294         * platform/RunLoop.h:
1295         (TimerBase):
1296         * platform/ScrollAnimator.h:
1297         (ScrollAnimator):
1298         * platform/ScrollAnimatorNone.h:
1299         (ScrollAnimatorNone):
1300         * platform/SharedBuffer.h:
1301         (SharedBuffer):
1302         * platform/WheelFlingPlatformGestureCurve.h:
1303         (WheelFlingPlatformGestureCurve):
1304         * platform/Widget.h:
1305         (Widget):
1306
1307 2012-07-25  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1308
1309         NodesFromRect and area-based hit-testing can not handle CSS transforms.
1310         https://bugs.webkit.org/show_bug.cgi?id=85792
1311
1312         Reviewed by Eric Seidel.
1313
1314         To support the combination of CSS transforms and rect based hit testing,
1315         we need to test against the transformed rect, instead of the original rect.
1316
1317         This patch makes HitTestPoint store the exact transformed FloatPoint and 
1318         FloatQuad, and modifies the intersection methods so that they will use a 
1319         new FloatQuad based intersection when transforms requires it.
1320
1321         Tests: fast/dom/nodesFromRect/nodesFromRect-rotate.html
1322                fast/dom/nodesFromRect/nodesFromRect-scale.html
1323
1324         * platform/graphics/FloatQuad.cpp:
1325         (WebCore::determinant):
1326         (WebCore::rightMostCornerToVector):
1327         (WebCore::FloatQuad::intersectsRect):
1328         (WebCore::FloatQuad::isCounterclockwise):
1329         * platform/graphics/FloatQuad.h:
1330         (FloatQuad):
1331         * rendering/HitTestResult.cpp:
1332         (WebCore::HitTestPoint::HitTestPoint):
1333         (WebCore::HitTestPoint::operator=):
1334         (WebCore::HitTestPoint::move):
1335         (WebCore::HitTestPoint::intersectsRect):
1336         (WebCore::HitTestPoint::intersects):
1337         * rendering/HitTestResult.h:
1338         (HitTestPoint):
1339         (WebCore::HitTestPoint::isRectilinear):
1340         (WebCore::HitTestPoint::transformedPoint):
1341         (WebCore::HitTestPoint::transformedRect):
1342         * rendering/HitTestingTransformState.cpp:
1343         (WebCore::HitTestingTransformState::flattenWithTransform):
1344         (WebCore::HitTestingTransformState::mappedArea):
1345         (WebCore::HitTestingTransformState::boundsOfMappedArea):
1346         * rendering/HitTestingTransformState.h:
1347         (WebCore::HitTestingTransformState::create):
1348         (WebCore::HitTestingTransformState::HitTestingTransformState):
1349         * rendering/RenderFlowThread.cpp:
1350         (WebCore::RenderFlowThread::hitTestRegion):
1351         * rendering/RenderLayer.cpp:
1352         (WebCore::RenderLayer::hitTest):
1353         (WebCore::RenderLayer::createLocalTransformState):
1354         (WebCore::RenderLayer::hitTestLayer):
1355         (WebCore::RenderLayer::hitTestChildLayerColumns):
1356         * rendering/RenderLayer.h:
1357         * rendering/svg/RenderSVGText.cpp:
1358         (WebCore::RenderSVGText::nodeAtFloatPoint):
1359
1360 2012-07-25  Kwang Yul Seo  <skyul@company100.net>
1361
1362         Add HTMLStackItem.h to project files
1363         https://bugs.webkit.org/show_bug.cgi?id=92221
1364
1365         Reviewed by Adam Barth.
1366
1367         Added HTMLStackItem.h introduced in r123399 to project files.
1368
1369         Project file changes only, no change in behavior thus no new tests.
1370
1371         * GNUmakefile.list.am:
1372         * WebCore.gypi:
1373         * WebCore.vcproj/WebCore.vcproj:
1374         * WebCore.xcodeproj/project.pbxproj:
1375
1376 2012-07-25  Sheriff Bot  <webkit.review.bot@gmail.com>
1377
1378         Unreviewed, rolling out r123606.
1379         http://trac.webkit.org/changeset/123606
1380         https://bugs.webkit.org/show_bug.cgi?id=92247
1381
1382         broke Windows build of Chromium (Requested by tomhudson on
1383         #webkit).
1384
1385         * Resources/colorSuggestionPicker.css: Removed.
1386         * Resources/colorSuggestionPicker.js: Removed.
1387         * WebCore.gyp/WebCore.gyp:
1388
1389 2012-07-25  Pavel Feldman  <pfeldman@chromium.org>
1390
1391         Web Inspector: disabling property should remove "overriden" decoration from overriden UA shorthand.
1392         https://bugs.webkit.org/show_bug.cgi?id=92253
1393
1394         Reviewed by Vsevolod Vlasov.
1395
1396         Bug fix with a test and more compilation markup.
1397
1398         Test: inspector/styles/styles-disable-then-enable-overriden-ua.html
1399
1400         * inspector/front-end/StylesSidebarPane.js:
1401         (WebInspector.StylePropertiesSection.prototype.update):
1402         (WebInspector.StylePropertyTreeElement):
1403         (WebInspector.StylePropertyTreeElement.prototype):
1404
1405 2012-07-25  Vsevolod Vlasov  <vsevik@chromium.org>
1406
1407         Web Inspector: Improve ObjectPropertiesSection UI by adding a tooltip for the value.
1408         https://bugs.webkit.org/show_bug.cgi?id=92225
1409
1410         Reviewed by Pavel Feldman.
1411
1412         Added tooltip with property value description on the property's valueElement.
1413
1414         * inspector/front-end/ObjectPropertiesSection.js:
1415         (WebInspector.ObjectPropertyTreeElement.prototype.update):
1416
1417 2012-07-25  Pavel Feldman  <pfeldman@chromium.org>
1418
1419         https://bugs.webkit.org/show_bug.cgi?id=91931
1420
1421         Reviewed by Vsevolod Vlasov.
1422
1423         - Synthetic shorthand values are now only returned for source-less styles
1424         - CSSAgents reports longhands along with the property names in getSupportedCSSProperties
1425         - StylesSidebarPane now has two paths: for source-enabled styles and for CSSOM-based ones (UA styles)
1426         - CSSStyleModel uses style metainfo as a source of shorthand / longhand relationship now
1427
1428         Test: inspector/styles/styles-overriden-properties.html
1429
1430         * inspector/Inspector.json:
1431         * inspector/InspectorCSSAgent.cpp:
1432         (WebCore::InspectorCSSAgent::getSupportedCSSProperties):
1433         * inspector/InspectorCSSAgent.h:
1434         (InspectorCSSAgent):
1435         * inspector/InspectorStyleSheet.cpp:
1436         (WebCore::InspectorStyle::styleWithProperties):
1437         * inspector/front-end/CSSCompletions.js:
1438         (WebInspector.CSSCompletions):
1439         (WebInspector.CSSCompletions.requestCSSNameCompletions):
1440         (WebInspector.CSSCompletions.prototype._closest):
1441         (WebInspector.CSSCompletions.prototype.longhands):
1442         (WebInspector.CSSCompletions.prototype.shorthands):
1443         * inspector/front-end/CSSStyleModel.js:
1444         (WebInspector.CSSStyleDeclaration):
1445         (WebInspector.CSSStyleDeclaration.prototype.longhandProperties):
1446         (WebInspector.CSSStyleDeclaration.prototype.shorthandValue):
1447         (WebInspector.CSSStyleDeclaration.prototype.newBlankProperty):
1448         (WebInspector.CSSProperty):
1449         (WebInspector.CSSProperty.parsePayload):
1450         * inspector/front-end/SourceCSSTokenizer.js:
1451         (WebInspector.SourceCSSTokenizer):
1452         * inspector/front-end/SourceCSSTokenizer.re2js:
1453         * inspector/front-end/StylesSidebarPane.js:
1454         (WebInspector.StylePropertiesSection.prototype.isPropertyOverloaded):
1455         (WebInspector.StylePropertiesSection.prototype.update):
1456         (WebInspector.StylePropertiesSection.prototype.onpopulate):
1457         (WebInspector.StylePropertyTreeElement.prototype):
1458
1459 2012-07-25  Keishi Hattori  <keishi@webkit.org>
1460
1461         Implement ColorSuggestionPicker page popup
1462         https://bugs.webkit.org/show_bug.cgi?id=92109
1463
1464         Reviewed by Kent Tamura.
1465
1466         Implements ColorSuggestionPicker page popup. This will be used in
1467         certain ports as the datalist UI for <input type=color>.
1468
1469         No new tests because there is no way to open the popup yet.
1470
1471         * Resources/colorSuggestionPicker.css: Added.
1472         (body):
1473         (#main):
1474         (.color-swatch):
1475         (.color-swatch:hover):
1476         (.color-swatch-container):
1477         (.other-color):
1478         * Resources/colorSuggestionPicker.js: Added.
1479         (getScrollbarWidth):When there are more than 20 colors we need to
1480         increase the window width to accommodate the scroll bar.
1481         (createElement):
1482         (handleMessage):
1483         (initialize):
1484         (handleArgumentsTimeout):
1485         (validateArguments):
1486         (submitValue): Calls setValueAndClosePopup with a numValue of 0.
1487         (handleCancel): Calls setValueAndClosePopup with a numValue of -1.
1488         (chooseOtherColor): Calls setValueAndClosePopup with a numValue of -2.
1489         (ColorPicker):
1490         (ColorPicker.prototype._layout): Lays out the color swatches in a 5x4
1491         grid.
1492         (ColorPicker.prototype._handleSwatchClick):
1493         * WebCore.gyp/WebCore.gyp:
1494
1495 2012-07-25  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1496
1497         Fix arithmetic composite filter for auto-vectorization
1498         https://bugs.webkit.org/show_bug.cgi?id=92123
1499
1500         Reviewed by Nikolas Zimmermann.
1501
1502         Since only clamping of the result prevents GCC from auto-vectorizing the inner loop, this patch 
1503         adds a faster version of the inner loop to handle cases where clamping is unnecessary, 
1504
1505         * platform/graphics/filters/FEComposite.cpp:
1506         (WebCore::computeArithmeticPixelsUnclamped):
1507         (WebCore::arithmeticSoftware):
1508
1509 2012-07-25  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1510
1511         Fix blend filter for autovectorizing
1512         https://bugs.webkit.org/show_bug.cgi?id=91398
1513
1514         Reviewed by Nikolas Zimmermann.
1515
1516         Get rid of wrapper classes, and use functions directly as template argument.
1517
1518         * platform/graphics/filters/FEBlend.cpp:
1519         (WebCore::feBlendNormal):
1520         (WebCore::feBlendMultiply):
1521         (WebCore::feBlendScreen):
1522         (WebCore::feBlendDarken):
1523         (WebCore::feBlendLighten):
1524         (WebCore::feBlendUnknown):
1525         (WebCore::platformApply):
1526         (WebCore::FEBlend::platformApplyGeneric):
1527
1528 2012-07-25  Keishi Hattori  <keishi@webkit.org>
1529
1530         Add methods to ColorChooserClient so the color chooser can show suggestions
1531         https://bugs.webkit.org/show_bug.cgi?id=92114
1532
1533         Reviewed by Kent Tamura.
1534
1535         Added methods to ColorChooserClient so the color chooser can ask the
1536         client for suggestions and current color.
1537
1538         No new tests. The methods are not used yet.
1539
1540         * html/ColorInputType.cpp:
1541         (WebCore::ColorInputType::currentColor): Returns what color the color
1542         chooser should display.
1543         (WebCore):
1544         (WebCore::ColorInputType::shouldShowSuggestions): Returns if the UI for
1545         suggestions should be shown.
1546         (WebCore::ColorInputType::suggestions): Returns a list of colors to be
1547         suggested to the user.
1548         * html/ColorInputType.h:
1549         (ColorInputType):
1550         * html/HTMLInputElement.h:
1551         (HTMLInputElement): Made dataList() public.
1552         * platform/ColorChooserClient.h:
1553         (ColorChooserClient):
1554
1555 2012-07-25  Kentaro Hara  <haraken@chromium.org>
1556
1557         Replace int with long in test IDL files
1558         https://bugs.webkit.org/show_bug.cgi?id=92181
1559
1560         Reviewed by Adam Barth.
1561
1562         int is not a valid type in WebIDL. It should be long.
1563         We should replace int with long in bindings/scripts/test/*.idl.
1564         This is a follow-up patch for r123550.
1565
1566         Test: bindings/scripts/test/TestObj.idl
1567
1568         * bindings/scripts/test/CPP/WebDOMTestObj.cpp:
1569         (WebDOMTestObj::readOnlyLongAttr):
1570         (WebDOMTestObj::Attr):
1571         (WebDOMTestObj::setAttr):
1572         (WebDOMTestObj::voidMethodWithArgs):
1573         (WebDOMTestObj::Method):
1574         (WebDOMTestObj::MethodWithArgs):
1575         (WebDOMTestObj::objMethodWithArgs):
1576         * bindings/scripts/test/CPP/WebDOMTestObj.h:
1577         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
1578         (webkit_dom_test_obj_set_property):
1579         (webkit_dom_test_obj_get_property):
1580         (webkit_dom_test_obj_class_init):
1581         (webkit_dom_test_obj_void_method_with_args):
1582         (webkit_dom_test_obj_method):
1583         (webkit_dom_test_obj_method_with_args):
1584         (webkit_dom_test_obj_obj_method_with_args):
1585         (webkit_dom_test_obj_get_read_only_long_attr):
1586         (webkit_dom_test_obj_get_attr):
1587         (webkit_dom_test_obj_set_attr):
1588         (webkit_dom_test_obj_get_strawberry):
1589         (webkit_dom_test_obj_set_strawberry):
1590         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
1591         * bindings/scripts/test/JS/JSTestObj.cpp:
1592         (WebCore):
1593         (WebCore::jsTestObjReadOnlyLongAttr):
1594         (WebCore::jsTestObjConstructorStaticReadOnlyLongAttr):
1595         (WebCore::jsTestObjAttr):
1596         (WebCore::setJSTestObjAttr):
1597         (WebCore::setJSTestObjStrawberry):
1598         (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
1599         (WebCore::jsTestObjPrototypeFunctionMethod):
1600         (WebCore::jsTestObjPrototypeFunctionMethodWithArgs):
1601         (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
1602         (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
1603         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
1604         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
1605         * bindings/scripts/test/JS/JSTestObj.h:
1606         (WebCore):
1607         * bindings/scripts/test/ObjC/DOMTestObj.h:
1608         * bindings/scripts/test/ObjC/DOMTestObj.mm:
1609         (-[DOMTestObj readOnlyLongAttr]):
1610         (-[DOMTestObj Attr]):
1611         (-[DOMTestObj setAttr:]):
1612         (-[DOMTestObj voidMethodWithArgs:strArg:objArg:]):
1613         (-[DOMTestObj Method]):
1614         (-[DOMTestObj MethodWithArgs:strArg:objArg:]):
1615         (-[DOMTestObj objMethodWithArgs:strArg:objArg:]):
1616         (-[DOMTestObj customMethodWithArgs:strArg:objArg:]):
1617         * bindings/scripts/test/TestObj.idl:
1618         * bindings/scripts/test/V8/V8TestObj.cpp:
1619         (WebCore::TestObjV8Internal::readOnlyLongAttrAttrGetter):
1620         (WebCore::TestObjV8Internal::staticReadOnlyLongAttrAttrGetter):
1621         (WebCore::TestObjV8Internal::AttrAttrGetter):
1622         (WebCore::TestObjV8Internal::AttrAttrSetter):
1623         (WebCore::TestObjV8Internal::strawberryAttrSetter):
1624         (WebCore::TestObjV8Internal::voidMethodWithArgsCallback):
1625         (WebCore::TestObjV8Internal::MethodCallback):
1626         (WebCore::TestObjV8Internal::MethodWithArgsCallback):
1627         (WebCore::TestObjV8Internal::objMethodWithArgsCallback):
1628         (WebCore::TestObjV8Internal::methodReturningSequenceCallback):
1629         (WebCore::TestObjV8Internal::overloadedMethod2Callback):
1630         (WebCore::TestObjV8Internal::overloadedMethod4Callback):
1631         (WebCore):
1632         (WebCore::ConfigureV8TestObjTemplate):
1633
1634 2012-07-25  Shinya Kawanaka  <shinyak@chromium.org>
1635
1636         A validation bubble should not be modifiable.
1637         https://bugs.webkit.org/show_bug.cgi?id=92217
1638
1639         Reviewed by Kent Tamura.
1640
1641         A user can set -webkit-user-modify: read-write to validation message elements.
1642         This might cause a undesired crash like Bug 65738. They should be unmodifiable.
1643
1644         Test: fast/forms/validation-user-modify.html
1645
1646         * css/html.css:
1647         Added -webkit-user-modify: read-only !important; for these elements so that they won't be
1648         changed by a user.
1649         (::-webkit-validation-bubble):
1650         (::-webkit-validation-bubble-message):
1651         (::-webkit-validation-bubble-text-block):
1652         (::-webkit-validation-bubble-heading):
1653         (::-webkit-validation-bubble-arrow):
1654         (::-webkit-validation-bubble-arrow-clipper):
1655
1656 2012-07-25  Zeno Albisser  <zeno@webkit.org>
1657
1658         [Qt][WK2] Disable CopyToTexture for GraphicsSurfaceMac.
1659         https://bugs.webkit.org/show_bug.cgi?id=92159
1660
1661         Disable CopyToTexture feature for GraphicsSurface on Mac.
1662         While this is actually working, it is currently used for Tiles
1663         that are single buffered, and therefore requires a call to glFlush.
1664         This call blocks the GPU for about 40ms which would make smooth animations impossible.
1665
1666         Reviewed by Noam Rosenthal.
1667
1668         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
1669         (WebCore::GraphicsSurface::platformCreate):
1670         (WebCore::GraphicsSurface::platformImport):
1671
1672 2012-07-25  Kenichi Ishibashi  <bashi@chromium.org>
1673
1674         [Chromium] Fix up includes in HarfBuzzNGFace.h
1675         https://bugs.webkit.org/show_bug.cgi?id=92127
1676
1677         Reviewed by Hajime Morita.
1678
1679         Move constructors of FontPlatformData from headers to corresponding cpp files
1680         so that we can use forward declaration for HarfBuzzNGFace instead of including HarfBuzzNGFace.h.
1681         This way we can include hb.h in HarfBuzzNGFace.h.
1682
1683         No new tests. No changes in behavior.
1684
1685         * platform/graphics/FontPlatformData.cpp:
1686         (WebCore::FontPlatformData::FontPlatformData): Moved from header file.
1687         (WebCore):
1688         * platform/graphics/FontPlatformData.h:
1689         (WebCore):
1690         (FontPlatformData): Moved to cpp file.
1691         * platform/graphics/cocoa/FontPlatformDataCocoa.mm: Include HarfBuzzNGFace.h
1692         * platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.cpp:
1693         (WebCore::FontPlatformData::FontPlatformData): Moved from header file.
1694         (WebCore):
1695         * platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.h:
1696         (WebCore):
1697         (FontPlatformData): Moved to cpp file.
1698         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.h: Include hb.h.
1699
1700 2012-07-24  Benjamin Poulain  <bpoulain@apple.com> && Joseph Pecoraro  <pecoraro@apple.com>
1701
1702         QualifiedName's HashSet should be big enough to hold at least all the static names
1703         https://bugs.webkit.org/show_bug.cgi?id=91891
1704
1705         Reviewed by Darin Adler.
1706
1707         QualifiedName's table has a standard size of 64 buckets. When initializing WebKit,
1708         we create 850 static QualifiedName for the standard names (HTMLNames, SVGNames etc).
1709
1710         The small base size forces us to grow and rehash the table several time on startup.
1711
1712         This patch solves the issue by defining the initial table size to the minimum size that
1713         can hold all the static QualifiedName.
1714
1715         * dom/QualifiedName.cpp:
1716         (QualifiedNameHashTraits):
1717         * dom/make_names.pl:
1718         (printNamesHeaderFile):
1719
1720 2012-07-24  Kwang Yul Seo  <skyul@company100.net>
1721
1722         Remove anonymous namespace and make functions static.
1723         https://bugs.webkit.org/show_bug.cgi?id=92214
1724
1725         Reviewed by Adam Barth.
1726
1727         Mark functions as static instead of enclosing them in anonymous namespaces.
1728         One exception to this rule is when a function is passed as a template argument.
1729         In this case, the function must have an external linkage.
1730
1731         No functional change. Covered by existing tests.
1732
1733         * html/parser/HTMLConstructionSite.cpp:
1734         (WebCore::hasImpliedEndTag):
1735         (WebCore::causesFosterParenting):
1736         (WebCore::isAllWhitespace):
1737         * html/parser/HTMLDocumentParser.cpp:
1738         (WebCore):
1739         (WebCore::tokenizerStateForContextElement):
1740         * html/parser/HTMLElementStack.cpp:
1741         (WebCore::isNumberedHeaderElement):
1742         (WebCore::isRootNode):
1743         (WebCore):
1744         * html/parser/HTMLEntityParser.cpp:
1745         (WebCore::isAlphaNumeric):
1746         * html/parser/HTMLEntitySearch.cpp:
1747         (WebCore::halfway):
1748         * html/parser/HTMLPreloadScanner.cpp:
1749         (WebCore):
1750         * html/parser/HTMLTokenizer.cpp:
1751         (WebCore::toLowerCase):
1752         (WebCore::vectorEqualsString):
1753         (WebCore::isEndTagBufferingState):
1754         * html/parser/HTMLTreeBuilder.cpp:
1755         (WebCore):
1756         (WebCore::uninitializedPositionValue1):
1757         (WebCore::isAllWhitespace):
1758         (WebCore::isAllWhitespaceOrReplacementCharacters):
1759         (WebCore::isNumberedHeaderTag):
1760         (WebCore::isCaptionColOrColgroupTag):
1761         (WebCore::isTableCellContextTag):
1762         (WebCore::isTableBodyContextTag):
1763         (WebCore::isSpecialNode):
1764         (WebCore::isNonAnchorNonNobrFormattingTag):
1765         (WebCore::isNonAnchorFormattingTag):
1766         (WebCore::isFormattingTag):
1767         (WebCore::closestFormAncestor):
1768         (WebCore::mapLoweredLocalNameToName):
1769         (WebCore::adjustSVGTagNameCase):
1770         (WebCore::adjustAttributes):
1771         (WebCore::adjustSVGAttributes):
1772         (WebCore::adjustMathMLAttributes):
1773         (WebCore::addNamesWithPrefix):
1774         (WebCore::adjustForeignAttributes):
1775
1776 2012-07-24  Vsevolod Vlasov  <vsevik@chromium.org>
1777
1778         Unreviewed r123494 follow-up: fixed inspector undock icon.
1779
1780         * inspector/front-end/Images/statusbarButtonGlyphs.png:
1781
1782 2012-07-24  Kwang Yul Seo  <skyul@company100.net>
1783
1784         Read tag names and attributes from the saved tokens where possible.
1785         https://bugs.webkit.org/show_bug.cgi?id=92079
1786
1787         Reviewed by Adam Barth.
1788
1789         Read tag names and attributes from the saved tokens, not from the DOM.
1790         Also added convenient methods such as hasLocalName, hasTagName, localName,
1791         isElementNode and isDocumentFragmentNode to HTMLStackItem class.
1792
1793         No new tests, covered by existing tests.
1794
1795         * html/parser/HTMLConstructionSite.cpp:
1796         (WebCore::HTMLNames::hasImpliedEndTag):
1797         (WebCore::HTMLNames::causesFosterParenting):
1798         (WebCore::HTMLConstructionSite::generateImpliedEndTagsWithExclusion):
1799         (WebCore::HTMLConstructionSite::generateImpliedEndTags):
1800         (WebCore::HTMLConstructionSite::shouldFosterParent):
1801         * html/parser/HTMLConstructionSite.h:
1802         (WebCore::HTMLConstructionSite::currentStackItem):
1803         * html/parser/HTMLElementStack.cpp:
1804         (WebCore::HTMLNames::isNumberedHeaderElement):
1805         (WebCore::HTMLNames::isRootNode):
1806         (WebCore::HTMLNames::isScopeMarker):
1807         (WebCore::HTMLNames::isListItemScopeMarker):
1808         (WebCore::HTMLNames::isTableScopeMarker):
1809         (WebCore::HTMLNames::isTableBodyScopeMarker):
1810         (WebCore::HTMLNames::isTableRowScopeMarker):
1811         (WebCore::HTMLNames::isForeignContentScopeMarker):
1812         (WebCore::HTMLNames::isButtonScopeMarker):
1813         (WebCore::HTMLNames::isSelectScopeMarker):
1814         (WebCore::HTMLElementStack::ElementRecord::replaceElement):
1815         (WebCore::HTMLElementStack::popUntilNumberedHeaderElementPopped):
1816         (WebCore::HTMLElementStack::popUntilTableScopeMarker):
1817         (WebCore::HTMLElementStack::popUntilTableBodyScopeMarker):
1818         (WebCore::HTMLElementStack::popUntilTableRowScopeMarker):
1819         (WebCore::HTMLElementStack::isMathMLTextIntegrationPoint):
1820         (WebCore::HTMLElementStack::isHTMLIntegrationPoint):
1821         (WebCore::HTMLElementStack::popUntilForeignContentScopeMarker):
1822         (WebCore::HTMLElementStack::pushRootNode):
1823         (WebCore::HTMLElementStack::oneBelowTop):
1824         (WebCore::HTMLElementStack::topmost):
1825         (WebCore):
1826         (WebCore::inScopeCommon):
1827         (WebCore::HTMLElementStack::hasNumberedHeaderElementInScope):
1828         (WebCore::HTMLElementStack::inScope):
1829         * html/parser/HTMLElementStack.h:
1830         (WebCore::HTMLElementStack::topStackItem):
1831         (HTMLElementStack):
1832         (WebCore::isInHTMLNamespace):
1833         * html/parser/HTMLStackItem.h:
1834         (WebCore::HTMLStackItem::isDocumentFragmentNode):
1835         (WebCore::HTMLStackItem::isElementNode):
1836         (HTMLStackItem):
1837         (WebCore::HTMLStackItem::hasLocalName):
1838         (WebCore::HTMLStackItem::hasTagName):
1839         (WebCore::HTMLStackItem::HTMLStackItem):
1840         * html/parser/HTMLTreeBuilder.cpp:
1841         (WebCore):
1842         (WebCore::HTMLTreeBuilder::constructTreeFromAtomicToken):
1843         (WebCore::HTMLTreeBuilder::processFakeEndTag):
1844         (WebCore::HTMLTreeBuilder::processCloseWhenNestedTag):
1845         (WebCore::HTMLTreeBuilder::processStartTagForInBody):
1846         (WebCore::HTMLTreeBuilder::processStartTag):
1847         (WebCore::HTMLTreeBuilder::processAnyOtherEndTagForInBody):
1848         (WebCore::HTMLTreeBuilder::furthestBlockForFormattingElement):
1849         (WebCore::HTMLTreeBuilder::callTheAdoptionAgency):
1850         (WebCore::HTMLTreeBuilder::processEndTagForInTableBody):
1851         (WebCore::HTMLTreeBuilder::processEndTagForInCell):
1852         (WebCore::HTMLTreeBuilder::processEndTagForInBody):
1853         (WebCore::HTMLTreeBuilder::processCaptionEndTagForInCaption):
1854         (WebCore::HTMLTreeBuilder::processTrEndTagForInRow):
1855         (WebCore::HTMLTreeBuilder::processEndTag):
1856         (WebCore::HTMLTreeBuilder::processCharacterBuffer):
1857         (WebCore::HTMLTreeBuilder::processEndOfFile):
1858         (WebCore::HTMLTreeBuilder::shouldProcessTokenInForeignContent):
1859         (WebCore::HTMLTreeBuilder::processTokenInForeignContent):
1860         * html/parser/HTMLTreeBuilder.h:
1861
1862 2012-07-24  Hironori Bono  <hbono@chromium.org>
1863
1864         Avoid moving child objects multiple times when vertical scrollbar are shown at the left side.
1865         https://bugs.webkit.org/show_bug.cgi?id=91756
1866
1867         Reviewed by Tony Chang.
1868
1869         My r123067 moves the top-left origin of an RTL element right when its vertical
1870         scrollbar is shown at its left side. (That is, r123067 moves all child objects
1871         in the RTL element right.) This change also increases RenderBox::clientLeft()
1872         at the same time, i.e. it also moves child objects right. Furthermore, my r109512
1873         moves positioned objects in an RTL element right at the same time. This makes
1874         WebKit move objects in an RTL element up to three times by the scrollbar width.
1875         (Moving an absolute object right increases the scrollWidth value and it causes
1876         this bug.) This change removes unnecessary code that moves objects right in my
1877         r109512 and RenderBox::clientLeft().
1878
1879         Test: scrollbars/rtl/div-absolute.html
1880               fast/block/float/026.html
1881               fast/block/float/028.html
1882               fast/overflow/unreachable-overflow-rtl-bug.html
1883
1884         * dom/Element.cpp:
1885         (WebCore::Element::clientLeft): Increase clientLeft value by the width of a vertical scrollbar as written in the CSSOM specification.
1886         * rendering/RenderBlock.cpp:
1887         (WebCore::RenderBlock::addOverflowFromPositionedObjects): Removed unnecessary code.
1888         (WebCore::RenderBlock::determineLogicalLeftPositionForChild): Removed unnecessary code.
1889         * rendering/RenderBox.h:
1890         (WebCore::RenderBox::clientLeft): Removed unnecessary code.
1891
1892 2012-07-24  Dan Bernstein  <mitz@apple.com>
1893
1894         RenderBlock::positionForPoint can fail when the block or its children have a vertical writing mode
1895         https://bugs.webkit.org/show_bug.cgi?id=92202
1896
1897         Reviewed by Beth Dakin.
1898
1899         Test: fast/writing-mode/positionForPoint.html
1900
1901         * rendering/RenderBlock.cpp:
1902         (WebCore::RenderBlock::positionForPoint): Fixed two issues, each of which are covered by
1903         one of the sub-tests in the new regression test: (1) changed to compare children’s logical
1904         bounds against pointInLogicalContents, i.e. compare childern’s horizontal bounds to the
1905         point’s horizontal component; and (2) changed to use logicalTopForChild and
1906         logicalHeightForChild, which account for this block’s writing mode, instead of logicalTop
1907         and logicalBottom, which are based on the child’s writing mode.
1908
1909 2012-07-24  MORITA Hajime  <morrita@google.com>
1910
1911         https://bugs.webkit.org/show_bug.cgi?id=89179
1912         Rendering LI having Shadow DOM seems weird
1913
1914         Reviewed by Dimitri Glazkov.
1915
1916         This incorrect rendering happend because HTMLLIElement::attach()
1917         wasn't aware of composed shadow subtree. This change makes it
1918         aware of that using ComposedShadowTreeParentWalker.
1919
1920         Test: fast/dom/shadow/shadow-and-list-elements.html
1921
1922         * html/HTMLLIElement.cpp:
1923         (WebCore::HTMLLIElement::attach):
1924
1925 2012-07-24  Alec Flett  <alecflett@chromium.org>
1926
1927         IndexedDB: fix #include dependencies so IDBRequest isn't an include root
1928         https://bugs.webkit.org/show_bug.cgi?id=92167
1929
1930         Reviewed by Tony Chang.
1931
1932         Remove implicit dependencies due to using IDBRequest.h, and fix all
1933         places that break as a result.
1934
1935         * Modules/indexeddb/IDBCallbacks.h:
1936         (WebCore):
1937         * Modules/indexeddb/IDBObjectStore.cpp:
1938         * Modules/indexeddb/IDBRequest.h:
1939         * inspector/InspectorIndexedDBAgent.cpp:
1940
1941 2012-07-24  Keishi Hattori  <keishi@webkit.org>
1942
1943         Move PagePopupClient helper functions so they can be shared
1944         https://bugs.webkit.org/show_bug.cgi?id=92096
1945
1946         Reviewed by Kent Tamura.
1947
1948         Move PagePopupClient helper functions to a separate file,
1949         so they can be shared with new PagePopupClients.
1950
1951         No new tests. Covered by fast/forms/date/calendar-picker-appearance.html
1952
1953         * WebCore.gypi: Added PagePopupClient.cpp
1954         * html/shadow/CalendarPickerElement.cpp:
1955         (WebCore::CalendarPickerElement::writeDocument): Modified to use PagePopupClient.
1956         * page/PagePopupClient.cpp: Added.
1957         (WebCore):
1958         (WebCore::PagePopupClient::addJavaScriptString):
1959         (WebCore::PagePopupClient::addProperty):
1960         * page/PagePopupClient.h:
1961         (WebCore::PagePopupClient::addString):
1962
1963 2012-07-24  Jer Noble  <jer.noble@apple.com>
1964
1965         setting playbackRate on a MediaController doesn't change the playbackRate for slaved media
1966         https://bugs.webkit.org/show_bug.cgi?id=92035
1967
1968         Reviewed by Darin Adler.
1969
1970         Allow updatePlaybackRate() to change the MediaPlayer rate when the media element has a 
1971         current media controller.
1972
1973         Test: media/media-controller-playbackrate.html
1974
1975         * html/HTMLMediaElement.cpp:
1976         (WebCore::HTMLMediaElement::updatePlaybackRate):
1977
1978 2012-07-24  Hayato Ito  <hayato@chromium.org>
1979
1980         Rename FocusScope to FocusNavigationScope.
1981         https://bugs.webkit.org/show_bug.cgi?id=92062
1982
1983         Reviewed by Dimitri Glazkov.
1984
1985         FocusNavagationScope is better name than FocusScope since the
1986         class is only used for controlling focus navigation.
1987
1988         No new tests - no functional changes.
1989
1990         * page/FocusController.cpp:
1991         (WebCore::FocusNavigationScope::FocusNavigationScope):
1992         (WebCore::FocusNavigationScope::rootNode):
1993         (WebCore::FocusNavigationScope::owner):
1994         (WebCore::FocusNavigationScope::focusNavigationScopeOf):
1995         (WebCore::FocusNavigationScope::focusNavigationScopeOwnedByShadowHost):
1996         (WebCore::FocusNavigationScope::focusNavigationScopeOwnedByIFrame):
1997         (WebCore::FocusController::findFocusableNodeDecendingDownIntoFrameDocument):
1998         (WebCore::FocusController::advanceFocusInDocumentOrder):
1999         (WebCore::FocusController::findFocusableNodeAcrossFocusScope):
2000         (WebCore::FocusController::findFocusableNodeRecursively):
2001         (WebCore::FocusController::findFocusableNode):
2002         (WebCore::FocusController::nextFocusableNode):
2003         (WebCore::FocusController::previousFocusableNode):
2004         * page/FocusController.h:
2005         (FocusNavigationScope):
2006         (FocusController):
2007
2008 2012-07-24  Michael Saboff  <msaboff@apple.com>
2009
2010         Convert HTML parser to handle 8-bit resources without converting to UChar*
2011         https://bugs.webkit.org/show_bug.cgi?id=90321
2012
2013         Reviewed by Geoffrey Garen.
2014
2015         No new tests, no new functionality therefore covered by existing tests.
2016
2017         Changed the parsing of HTML to handle 8-bit strings without converting the 
2018         whole string to 16-bits.  Primary change was to use the appropriate 
2019         character pointer type (LChar* or UChar*) depending on the source string.
2020         This access is abstracted in SegmentedSubstring by getCurrentChar{8,16} and
2021         incrementAndGetCurrentChar{8,16} methods.  In SegmentedString, the advance()
2022         and advanceAndUpdateLineNumber() methods have been refactored into a
2023         state machine managed pair of function pointers.  The possible functions
2024         have not only the 8 and 16 bitness factored out, they also have the 
2025         "exclude line numbers" logic factored out for advanceAndUpdateLineNumber().
2026         This provides a net speed-up even with the 8/16 bit testing.
2027         Other changes involve using String methods to access and compare with the
2028         source data.
2029
2030         * html/FTPDirectoryDocument.cpp:
2031         (WebCore::FTPDirectoryDocumentParser::append): Changed to use currentChar()
2032         instead of SegmentedString '*' operator.
2033         * html/parser/HTMLEntityParser.cpp: Changed to use currentChar() instead of
2034         SegmentedString '*' operator.
2035         * html/parser/HTMLParserIdioms.cpp:
2036         (WebCore::stripLeadingAndTrailingHTMLSpaces): Added 8-bit fast path.
2037         * html/parser/HTMLSourceTracker.cpp:
2038         (WebCore::HTMLSourceTracker::sourceForToken): Changed to use currentChar() instead of
2039         SegmentedString '*' operator.
2040         * loader/cache/CachedScript.cpp:
2041         (WebCore::CachedScript::script): Updated to use new String::dataSize() method.
2042         * platform/text/SegmentedString.cpp:
2043         (WebCore::SegmentedString::SegmentedString):
2044         (WebCore::SegmentedString::operator=):
2045         (WebCore::SegmentedString::clear):
2046         (WebCore::SegmentedString::append):
2047         (WebCore::SegmentedString::prepend):
2048         (WebCore::SegmentedString::advanceSubstring):
2049         (WebCore::SegmentedString::advance): Changed to be a wrapper that invokes current 
2050         advance function.
2051         (WebCore::SegmentedString::advance8): Fast path advance function for 8 bit data.
2052         (WebCore::SegmentedString::advance16): Fast path advance function for 16 bit data.
2053         (WebCore::SegmentedString::advanceAndUpdateLineNumber8IncludeLineNumbers): Fast
2054         path advanceAndUpdateLineNumber for 8 bit data when we need to update the line number.
2055         (WebCore::SegmentedString::advanceAndUpdateLineNumber16IncludeLineNumbers): Fast
2056         path advanceAndUpdateLineNumber for 16 bit data when we need to update the line number.
2057         (WebCore::SegmentedString::advanceSlowCase): Slow case advance function for both
2058         8 and 16 bit advance.
2059         (WebCore::SegmentedString::advanceAndUpdateLineNumberSlowCase): Slow case
2060         advanceAndUpdateLineNumber function for both 8 and 16 bit data.
2061         (WebCore::SegmentedString::advanceEmpty): Advance function when input has been exhausted.
2062         * platform/text/SegmentedString.h:
2063         (WebCore::SegmentedSubstring::SegmentedSubstring):
2064         (WebCore::SegmentedSubstring::clear):
2065         (SegmentedSubstring):
2066         (WebCore::SegmentedSubstring::is8Bit): New getter.
2067         (WebCore::SegmentedSubstring::appendTo):
2068         (WebCore::SegmentedSubstring::getCurrentChar8): New getter for the 8 bit case.
2069         (WebCore::SegmentedSubstring::getCurrentChar16): New getter for the 16 bit case.
2070         (WebCore::SegmentedSubstring::incrementAndGetCurrentChar8): New wrapper functions
2071         that pre-increments the 8 bit pointer and returns the next character.
2072         (WebCore::SegmentedSubstring::incrementAndGetCurrentChar16): New wrapper functions
2073         that pre-increments the 16 bit pointer and returns the next character.
2074         (WebCore::SegmentedSubstring::currentSubString):
2075         (WebCore::SegmentedSubstring::getCurrentChar):
2076         (WebCore::SegmentedSubstring::incrementAndGetCurrentChar):
2077         (WebCore::SegmentedString::SegmentedString):
2078         (WebCore::SegmentedString::push):
2079         (WebCore::SegmentedString::isEmpty):
2080         (WebCore::SegmentedString::lookAhead):
2081         (WebCore::SegmentedString::lookAheadIgnoringCase):
2082         (WebCore::SegmentedString::advance):
2083         (WebCore::SegmentedString::advanceAndUpdateLineNumber):
2084         (WebCore::SegmentedString::advanceAndASSERT):
2085         (WebCore::SegmentedString::advanceAndASSERTIgnoringCase):
2086         (WebCore::SegmentedString::advancePastNonNewline):
2087         (WebCore::SegmentedString::advancePastNewlineAndUpdateLineNumber):
2088         (WebCore::SegmentedString::currentChar):
2089         (WebCore::SegmentedString::setSlowCase): Set advance function pointers to slow case
2090         functions.
2091         (WebCore::SegmentedString::decrementAndCheckLength): Decrement substring length and
2092         change to slow case functions when only one character left.
2093         (WebCore::SegmentedString::setAdvanceFunctionPointers): Select appropriate advance
2094         functions based on current substring.
2095         (WebCore::SegmentedString::lookAheadInline): Changed to use String::startsWith().
2096         (WebCore::SegmentedString::lookAheadSlowCase):
2097         * xml/parser/CharacterReferenceParserInlineMethods.h:
2098         (WebCore::consumeCharacterReference): Changed to use currentChar() instead of
2099         SegmentedString '*' operator.
2100         * xml/parser/MarkupTokenizerBase.h:
2101         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::nextInputCharacter):
2102         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::peek): Changed to use
2103         currentChar() instead of SegmentedString '*' operator.
2104         (WebCore::MarkupTokenizerBase::InputStreamPreprocessor::advance):
2105
2106 2012-07-24  Kenneth Russell  <kbr@google.com>
2107
2108         [chromium] Hint garbage collector to run if page uses Canvas contexts
2109         https://bugs.webkit.org/show_bug.cgi?id=76225
2110
2111         Reviewed by Kentaro Hara.
2112
2113         Upon creating a canvas context, set a hint in the current isolate
2114         indicating that a full GC should be done upon the next page
2115         navigation.
2116
2117         This improves Chrome's robustness on some WebGL stress tests which
2118         simulate real-world behavior by repeatedly navigating among
2119         several samples. More general measures are being investigated, but
2120         this change makes V8 behave the same as JSC on these stress tests.
2121         JSC doesn't currently use generational garbage collection, so it
2122         has more opportunities to discover unreferenced canvas contexts.
2123
2124         Test: fast/canvas/webgl/context-creation-and-destruction.html
2125
2126         * bindings/v8/V8Binding.cpp:
2127         (WebCore::V8BindingPerIsolateData::V8BindingPerIsolateData):
2128             Initialize per-isolate low memory hint.
2129         * bindings/v8/V8Binding.h:
2130         (V8BindingPerIsolateData):
2131         (WebCore::V8BindingPerIsolateData::setLowMemoryNotificationHint):
2132             Set a per-isolate hint to signal a low memory condition upon the next page navigation.
2133         (WebCore::V8BindingPerIsolateData::clearLowMemoryNotificationHint):
2134             Clear the previously set hint.
2135         (WebCore::V8BindingPerIsolateData::isLowMemoryNotificationHint):
2136             Get the previously set hint.
2137         * bindings/v8/V8Proxy.cpp:
2138         (WebCore::V8Proxy::hintForGCIfNecessary):
2139             If necessary, send V8 a hint that it should GC.
2140         (WebCore):
2141         (WebCore::V8Proxy::clearForClose):
2142         (WebCore::V8Proxy::clearForNavigation):
2143             Call hintForGCIfNecessary.
2144         * bindings/v8/V8Proxy.h:
2145         (V8Proxy):
2146         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
2147         (WebCore::V8HTMLCanvasElement::getContextCallback):
2148             Set a hint that we should GC upon the next page navigation.
2149
2150 2012-07-24  Dave Tu  <dtu@chromium.org>
2151
2152         [chromium] Add time spent painting to GPU benchmarking renderingStats() API.
2153         https://bugs.webkit.org/show_bug.cgi?id=90019
2154
2155         Reviewed by Adrienne Walker.
2156
2157         * platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.cpp:
2158         (WebCore::BitmapCanvasLayerTextureUpdater::prepareToUpdate):
2159         * platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.h:
2160         (BitmapCanvasLayerTextureUpdater):
2161         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.cpp:
2162         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::prepareRect):
2163         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::prepareToUpdate):
2164         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::paintContentsRect):
2165         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h:
2166         (Texture):
2167         (BitmapSkPictureCanvasLayerTextureUpdater):
2168         * platform/graphics/chromium/CanvasLayerTextureUpdater.cpp:
2169         (WebCore::CanvasLayerTextureUpdater::paintContents):
2170         * platform/graphics/chromium/CanvasLayerTextureUpdater.h:
2171         (CanvasLayerTextureUpdater):
2172         * platform/graphics/chromium/ContentLayerChromium.cpp:
2173         (WebCore::ContentLayerChromium::update):
2174         * platform/graphics/chromium/ContentLayerChromium.h:
2175         (ContentLayerChromium):
2176         * platform/graphics/chromium/ImageLayerChromium.cpp:
2177         (WebCore::ImageLayerChromium::update):
2178         * platform/graphics/chromium/ImageLayerChromium.h:
2179         (ImageLayerChromium):
2180         * platform/graphics/chromium/LayerChromium.h:
2181         (WebCore):
2182         (WebCore::LayerChromium::update):
2183         * platform/graphics/chromium/LayerTextureUpdater.h:
2184         (WebCore):
2185         (WebCore::LayerTextureUpdater::Texture::prepareRect):
2186         (WebCore::LayerTextureUpdater::prepareToUpdate):
2187         * platform/graphics/chromium/ScrollbarLayerChromium.cpp:
2188         (WebCore::ScrollbarLayerChromium::updatePart):
2189         (WebCore::ScrollbarLayerChromium::update):
2190         * platform/graphics/chromium/ScrollbarLayerChromium.h:
2191         (ScrollbarLayerChromium):
2192         * platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.cpp:
2193         (WebCore::SkPictureCanvasLayerTextureUpdater::prepareToUpdate):
2194         * platform/graphics/chromium/SkPictureCanvasLayerTextureUpdater.h:
2195         (SkPictureCanvasLayerTextureUpdater):
2196         * platform/graphics/chromium/TiledLayerChromium.cpp:
2197         (WebCore::TiledLayerChromium::updateTiles):
2198         (WebCore::TiledLayerChromium::updateContentRect):
2199         * platform/graphics/chromium/TiledLayerChromium.h:
2200         (TiledLayerChromium):
2201         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2202         (WebCore::CCLayerTreeHost::CCLayerTreeHost):
2203         (WebCore::CCLayerTreeHost::updateAnimations):
2204         (WebCore::CCLayerTreeHost::renderingStats):
2205         (WebCore::CCLayerTreeHost::paintMasksForRenderSurface):
2206         (WebCore::CCLayerTreeHost::paintLayerContents):
2207         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2208         (WebCore):
2209         (CCLayerTreeHost):
2210         * platform/graphics/chromium/cc/CCRenderingStats.h:
2211         (CCRenderingStats):
2212         (WebCore::CCRenderingStats::CCRenderingStats):
2213
2214 2012-07-24  Jian Li  <jianli@chromium.org>
2215
2216         [V8] Correct WebIDL type should be used in the testing IDL file 
2217         https://bugs.webkit.org/show_bug.cgi?id=92168
2218
2219         Reviewed by Kentaro Hara.
2220
2221         Updated bindings test.
2222
2223         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
2224         (webkit_dom_test_obj_strict_function):
2225         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
2226         * bindings/scripts/test/JS/JSTestObj.cpp:
2227         (WebCore::jsTestObjPrototypeFunctionStrictFunction):
2228         * bindings/scripts/test/TestObj.idl:
2229         * bindings/scripts/test/V8/V8TestObj.cpp:
2230         (WebCore::TestObjV8Internal::enabledAtRuntimeMethod1Callback):
2231         (WebCore::TestObjV8Internal::enabledAtRuntimeMethod2Callback):
2232         (WebCore::TestObjV8Internal::enabledPerContextMethod1Callback):
2233         (WebCore::TestObjV8Internal::enabledPerContextMethod2Callback):
2234         (WebCore::TestObjV8Internal::strictFunctionCallback):
2235
2236 2012-07-24  Kent Tamura  <tkent@chromium.org>
2237
2238         Unreviewed, rolling out r123191.
2239         http://trac.webkit.org/changeset/123191
2240         https://bugs.webkit.org/show_bug.cgi?id=91804
2241
2242         It might cause another performance regression.
2243         http://code.google.com/p/chromium/issues/detail?id=138410
2244
2245         * html/FormController.cpp:
2246         (FormKeyGenerator):
2247         (WebCore::createKey):
2248         (WebCore::FormKeyGenerator::formKey):
2249         (WebCore::FormKeyGenerator::willDeleteForm):
2250
2251 2012-07-24  Vineet Chaudhary  <rgf748@motorola.com>
2252
2253         [JSBinding] Merging jsUnsignedLongArrayToVector() to toNativeArray() using traits.
2254         https://bugs.webkit.org/show_bug.cgi?id=90381
2255
2256         Reviewed by Kentaro Hara.
2257
2258         We can remove jsUnsignedLongArrayToVector() implementaion
2259         merging it to current and toNativeArray() traits.
2260
2261         Tests: TestObj.idl
2262         There should be no behavoiral changes as just refactoring.
2263
2264         * Modules/vibration/NavigatorVibration.idl: Use sequence<T> as method param than T[]
2265         * bindings/js/JSDOMBinding.cpp: Moved toJSSequence() to header file.
2266         * bindings/js/JSDOMBinding.h:
2267         (WebCore::toJSSequence): Moved toJSSequence() to header file.
2268         (WebCore::jsArray): Renamed Traits to JSValueTraits
2269         (WebCore::toNativeArray): Using traits.
2270         * bindings/js/JSDictionary.cpp:
2271         (WebCore::JSDictionary::convertValue):
2272         * bindings/js/JSMessagePortCustom.cpp:
2273         (WebCore::fillMessagePortArray):
2274         * bindings/scripts/CodeGeneratorJS.pm: Removed unsigned long[] specific binding code.
2275         (AddIncludesForType):
2276         (GenerateParametersCheckExpression):
2277         (JSValueToNative):
2278         (NativeToJSValue):
2279         * bindings/scripts/CodeGeneratorV8.pm:
2280         (GenerateParametersCheckExpression): Added check sequence<T> check for overloaded methods.
2281         * bindings/scripts/test/JS/JSTestObj.cpp: Rebased binding test.
2282         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
2283         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
2284         (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
2285         * bindings/scripts/test/JS/JSTestObj.h: Rebased binding test.
2286         * bindings/scripts/test/TestObj.idl: Added test for sequence<T> as method parameter.
2287         * bindings/scripts/test/V8/V8TestObj.cpp: Rebased binding test.
2288         (WebCore::TestObjV8Internal::overloadedMethod10Callback):
2289         (TestObjV8Internal):
2290         (WebCore::TestObjV8Internal::overloadedMethodCallback):
2291
2292 2012-07-24  Kwang Yul Seo  <skyul@company100.net>
2293
2294         Remove an invalid assertion introduced in r123536. Unreviewed.
2295
2296         * xml/parser/MarkupTokenBase.h:
2297         (WebCore::AtomicMarkupTokenBase::clearExternalCharacters):
2298
2299 2012-07-24  Sheriff Bot  <webkit.review.bot@gmail.com>
2300
2301         Unreviewed, rolling out r123504.
2302         http://trac.webkit.org/changeset/123504
2303         https://bugs.webkit.org/show_bug.cgi?id=92169
2304
2305         broke a bunch of text-related tests in chromium mac debug
2306         (Requested by zhenyao on #webkit).
2307
2308         * platform/text/cf/StringCF.cpp:
2309         (WTF::String::createCFString):
2310         * platform/text/cf/StringImplCF.cpp:
2311         (WTF::StringImpl::createCFString):
2312
2313 2012-07-24  Kwang Yul Seo  <skyul@company100.net>
2314
2315         Ensure Noah's ark without reading the DOM tree.
2316         https://bugs.webkit.org/show_bug.cgi?id=92065
2317
2318         Reviewed by Adam Barth.
2319
2320         Technically we shouldn't read attributes back from the DOM. If JavaScript changes
2321         the attributes values, we could get a slightly wrong output here.
2322
2323         Read attributes from tokens saved in the active formatting element list.
2324
2325         No new tests, covered by existing tests.
2326
2327         * html/parser/HTMLFormattingElementList.cpp:
2328         (WebCore::attributeCount):
2329         (WebCore::HTMLFormattingElementList::append):
2330         (WebCore::HTMLFormattingElementList::tryToEnsureNoahsArkConditionQuickly):
2331         (WebCore::HTMLFormattingElementList::ensureNoahsArkCondition):
2332         * html/parser/HTMLFormattingElementList.h:
2333         (HTMLFormattingElementList):
2334         * html/parser/HTMLStackItem.h:
2335         (WebCore::HTMLStackItem::localName):
2336         (HTMLStackItem):
2337
2338 2012-07-23  Kwang Yul Seo  <skyul@company100.net>
2339
2340         Clear the external characters pointer of an AtomicHTMLToken before the raw token is cleared.
2341         https://bugs.webkit.org/show_bug.cgi?id=92056
2342
2343         Reviewed by Adam Barth.
2344
2345         AtomicHTMLToken keeps a pointer to the HTMLToken's buffer instead of copying the
2346         characters for performance. Clear the external characters pointer before the raw token
2347         is cleared to make sure that we won't have a dangling pointer.
2348
2349         No new tests - no functional changes.
2350
2351         * html/parser/HTMLTreeBuilder.cpp:
2352         (WebCore::HTMLTreeBuilder::constructTreeFromToken):
2353         * xml/parser/MarkupTokenBase.h:
2354         (WebCore::AtomicMarkupTokenBase::clearExternalCharacters):
2355         (AtomicMarkupTokenBase):
2356
2357 2012-07-24  Jian Li  <jianli@chromium.org>
2358
2359         Add per-context setting for html notifications
2360         https://bugs.webkit.org/show_bug.cgi?id=91295
2361
2362         Reviewed by Adam Barth.
2363
2364         Added a new per-context setting to control the enabling of html notifications.
2365         For chromium port, we're going to disable html notifications for web
2366         pages, but still keep it enabled for extensions.
2367
2368         Also enhance V8 code generator to support V8EnabledPerContext attribute
2369         for methods.
2370
2371         Updated the binding tests.
2372
2373         * Modules/notifications/NotificationCenter.cpp:
2374         (WebCore::NotificationCenter::document): Expose document for being used by installPerContextProperties.
2375         (WebCore):
2376         * Modules/notifications/NotificationCenter.h:
2377         (NotificationCenter):
2378         * Modules/notifications/NotificationCenter.idl: Add V8EnabledPerContext attribute.
2379         * bindings/scripts/CodeGeneratorV8.pm: V8EnabledPerContext now supports methods.
2380         (GenerateHeader):
2381         (IsStandardFunction):
2382         (GenerateNonStandardFunction):
2383         (GenerateImplementation):
2384         (GenerateToV8Converters):
2385         (GetContextEnableFunction):
2386         * bindings/scripts/test/TestObj.idl: Add test case for V8EnabledPerContext methods.
2387         * bindings/scripts/test/V8/V8TestObj.cpp: Update test result.
2388         (WebCore::TestObjV8Internal::enabledAtContextMethod1Callback):
2389         (TestObjV8Internal):
2390         (WebCore::TestObjV8Internal::enabledAtContextMethod2Callback):
2391         (WebCore::V8TestObj::installPerContextProperties):
2392         (WebCore::V8TestObj::wrapSlow):
2393         * dom/ContextFeatures.cpp: Add a new per-context feature.
2394         (WebCore::ContextFeatures::htmlNotificationsEnabled):
2395         (WebCore):
2396         * dom/ContextFeatures.h: Add a new per-context feature.
2397
2398 2012-07-24  Sheriff Bot  <webkit.review.bot@gmail.com>
2399
2400         Unreviewed, rolling out r123499.
2401         http://trac.webkit.org/changeset/123499
2402         https://bugs.webkit.org/show_bug.cgi?id=92161
2403
2404         Android fails to compile (Requested by zhenyao on #webkit).
2405
2406         * GNUmakefile.list.am:
2407         * Modules/mediastream/MediaStream.cpp:
2408         (WebCore::MediaStream::MediaStream):
2409         (WebCore::MediaStream::addTrack):
2410         * Modules/mediastream/MediaStreamTrack.cpp:
2411         (WebCore::MediaStreamTrack::create):
2412         (WebCore::MediaStreamTrack::MediaStreamTrack):
2413         (WebCore::MediaStreamTrack::~MediaStreamTrack):
2414         (WebCore::MediaStreamTrack::setEnabled):
2415         * Modules/mediastream/MediaStreamTrack.h:
2416         (MediaStreamTrack):
2417         * Modules/mediastream/MediaStreamTrack.idl:
2418         * WebCore.gypi:
2419         * dom/EventNames.h:
2420         (WebCore):
2421         * dom/EventTargetFactory.in:
2422         * platform/chromium/support/WebMediaStreamDescriptor.cpp:
2423         (WebKit):
2424         (WebKit::WebMediaStreamDescriptor::sources):
2425         * platform/chromium/support/WebMediaStreamSource.cpp:
2426         * platform/mediastream/MediaStreamSource.cpp: Removed.
2427         * platform/mediastream/MediaStreamSource.h:
2428         (WebCore::MediaStreamSource::create):
2429         (WebCore::MediaStreamSource::muted):
2430         (WebCore::MediaStreamSource::setMuted):
2431         (WebCore::MediaStreamSource::MediaStreamSource):
2432         (MediaStreamSource):
2433         * platform/mediastream/chromium/MediaStreamCenterChromium.cpp:
2434         (WebCore::MediaStreamCenterChromium::queryMediaStreamSources):
2435         (WebCore::MediaStreamCenterChromium::didCreateMediaStream):
2436
2437 2012-07-24  Julien Chaffraix  <jchaffraix@webkit.org>
2438
2439         Crash in RenderTableSection::layoutRows
2440         https://bugs.webkit.org/show_bug.cgi?id=92145
2441
2442         Reviewed by Abhishek Arya.
2443
2444         The crash came from the insertChildNode logic being confused and choosing the wrong
2445         renderer for insertion. This is because after r123159, table anonymous wrappers can
2446         be created as 'inline-table' and wouldn't pass the isAnonymousBlock() check.
2447
2448         This change also aligns the ancestor iteration with RenderBlock::addChildToAnonymousColumnBlocks.
2449
2450         Test: fast/table/crash-table-section-layoutRows.html
2451
2452         * rendering/RenderObjectChildList.cpp:
2453         (WebCore::RenderObjectChildList::insertChildNode):
2454         Changed the code to always get the right child. There is no justification to not
2455         walking up to the |owner|'s direct child in all cases.
2456
2457 2012-07-24  Tony Chang  <tony@chromium.org>
2458
2459         Make RenderBlock::paintChildren virtual so sub classes can change the paint order
2460         https://bugs.webkit.org/show_bug.cgi?id=92042
2461
2462         Reviewed by Ojan Vafai.
2463
2464         The flexbox spec says that the order property should change the paint order of flex children.
2465         To make that possible, make paintChildren virtual so RenderFlexibleBox can override it.
2466
2467         No new tests, this is just a refactoring.
2468
2469         * rendering/RenderBlock.cpp:
2470         (WebCore::RenderBlock::paintContents): Move some code out of paintChildren into paintContents.
2471         (WebCore::RenderBlock::paintChildren): Make virtual and just have it be a simple for loop.
2472         (WebCore::RenderBlock::paintChild): Move code out of paintChildren so subclasses can reuse.
2473         * rendering/RenderBlock.h:
2474         (RenderBlock): Make paintChildren virtual and protected so sub classes can call paintChild.
2475
2476 2012-07-24  Anna Cavender  <annacc@chromium.org>
2477
2478         Create SourceBuffer and SourceBufferList objects
2479         https://bugs.webkit.org/show_bug.cgi?id=91771
2480
2481         Reviewed by Eric Carlson.
2482
2483         SourceBuffer and SourceBufferList objects are needed in order to
2484         implement the new object-oriented MediaSource API:
2485         http://dvcs.w3.org/hg/html-media/raw-file/tip/media-source/media-source.html
2486
2487         No new tests - will be able to test after landing BUGWK91775
2488
2489         Adding new files to build files:
2490         * CMakeLists.txt:
2491         * DerivedSources.cpp:
2492         * DerivedSources.make:
2493         * DerivedSources.pri:
2494         * GNUmakefile.am:
2495         * GNUmakefile.list.am:
2496         * Target.pri:
2497         * WebCore.gyp/WebCore.gyp:
2498         * WebCore.gypi:
2499         * WebCore.vcproj/WebCore.vcproj:
2500         * WebCore.vcproj/WebCoreCommon.vsprops:
2501         * WebCore.vcproj/copyForwardingHeaders.cmd:
2502         * WebCore.xcodeproj/project.pbxproj:
2503
2504         New objects:
2505         * Modules/mediasource/SourceBuffer.cpp: Added.
2506         * Modules/mediasource/SourceBuffer.h: Added.
2507         * Modules/mediasource/SourceBuffer.idl: Added.
2508         * Modules/mediasource/SourceBufferList.cpp: Added.
2509         * Modules/mediasource/SourceBufferList.h: Added.
2510         * Modules/mediasource/SourceBufferList.idl: Added.
2511
2512         New events:
2513         * dom/EventNames.h:
2514         (WebCore):
2515         * dom/EventTarget.h:
2516         (WebCore):
2517         * dom/EventTargetFactory.in:
2518
2519         Object constructors:
2520         * page/DOMWindow.idl:
2521
2522 2012-07-24  Patrick Gansterer  <paroga@webkit.org>
2523
2524         Store the full year in GregorianDateTime
2525         https://bugs.webkit.org/show_bug.cgi?id=92067
2526
2527         Reviewed by Geoffrey Garen.
2528
2529         Use the full year instead of the offset from year 1900 
2530         for the year member variable of GregorianDateTime.
2531
2532         * bridge/qt/qt_runtime.cpp:
2533         (JSC::Bindings::convertValueToQVariant):
2534         (JSC::Bindings::convertQVariantToValue):
2535         * bridge/qt/qt_runtime_qt4.cpp:
2536         (JSC::Bindings::convertValueToQVariant):
2537         (JSC::Bindings::convertQVariantToValue):
2538
2539 2012-07-24  Benjamin Poulain  <bpoulain@apple.com>
2540
2541         Do not perform 8 to 16bits characters conversion when converting a WTFString to NSString/CFString
2542         https://bugs.webkit.org/show_bug.cgi?id=90720
2543
2544         Reviewed by Geoffrey Garen.
2545
2546         In most String to CFString conversion, we should be able to use the "NoCopy" constructor and have
2547         a relatively cheap conversion from WTF::String to CFString.
2548
2549         When the String is 8 bits, it was converted to 16 bits by getData16SlowCase() because of the call
2550         to String::characters().
2551
2552         This patch adds a path for creating a CFString from a 8bits string using CFStringCreateWithBytes.
2553
2554         This is covered by existing tests.
2555
2556         * platform/text/cf/StringCF.cpp:
2557         (WTF::String::createCFString): CFSTR() create static CFString, it is unecessary to retain it.
2558         * platform/text/cf/StringImplCF.cpp:
2559         (WTF::StringImpl::createCFString): The logic to avoid the StringWrapperCFAllocator has also been simplified.
2560         The allocator creation is now closer to where it is useful.
2561
2562 2012-07-24  Kentaro Hara  <haraken@chromium.org>
2563
2564         [V8] String wrappers should be marked Independent
2565         https://bugs.webkit.org/show_bug.cgi?id=91251
2566
2567         Reviewed by Adam Barth.
2568
2569         Currently V8 String wrappers are not marked Independent.
2570         By marking them Independent, they can be reclaimed by the scavenger GC.
2571         Although I couldn't find a case where this change reduces memory usage,
2572         this change would be important for upcoming changes in string conversion
2573         between V8 and WebKit (https://bugs.webkit.org/show_bug.cgi?id=91850).
2574
2575         'm_lastStringImpl = 0' in StringCache::remove() is important.
2576         Look at the following code:
2577
2578             static void cachedStringCallback(v8::Persistent<v8::Value> wrapper, void* parameter)
2579             {
2580                 ...;
2581                 stringCache()->remove(stringImpl);
2582                 wrapper.Dispose();
2583             }
2584
2585             void StringCache::remove(StringImpl* stringImpl)
2586             {
2587                 ...
2588                 if (m_lastStringImpl.get() == stringImpl)
2589                     m_lastStringImpl = 0;
2590             }
2591
2592             v8::Local<v8::String> v8ExternalString(StringImpl* stringImpl, v8::Isolate* isolate)
2593             {
2594                 if (m_lastStringImpl.get() == stringImpl) {
2595                     return v8::Local<v8::String>::New(m_lastV8String); // m_lastV8String points to a wrapper object that was accessed most recently.
2596                 }
2597                 return v8ExternalStringSlow(stringImpl, isolate);
2598             }
2599
2600         Without 'm_lastStringImpl = 0', already disposed m_lastV8String can be used
2601         in v8ExternalString(). This was a cause of the crashes of r122614.
2602
2603         Tests: At the initial commit of this patch (r122614),
2604                the following tests had been broken due to missing 'm_lastStringImpl = 0'.
2605                fast/workers/worker-location.html
2606                Dromaeo/cssquery-jquery.html
2607                Dromaeo/jslib-event-jquery.html
2608                Dromaeo/jslib-style-jquery.html
2609                Dromaeo/jslib-style-prototype.html
2610
2611         * bindings/v8/V8Binding.cpp:
2612         (WebCore::StringCache::remove):
2613         (WebCore::StringCache::v8ExternalStringSlow):
2614
2615 2012-07-24  Tommy Widenflycht  <tommyw@google.com>
2616
2617         MediaStream API: Update MediaStreamTrack to match the specification
2618         https://bugs.webkit.org/show_bug.cgi?id=90180
2619
2620         Reviewed by Adam Barth.
2621
2622         MediaStreamTracks are now required to show the status of the underlying source,
2623         and trigger events when that status changes.
2624
2625         Test: fast/mediastream/MediaStreamTrack.html
2626
2627         * GNUmakefile.list.am:
2628         * Modules/mediastream/MediaStream.cpp:
2629         (WebCore::MediaStream::MediaStream):
2630         (WebCore::MediaStream::addTrack):
2631         * Modules/mediastream/MediaStreamTrack.cpp:
2632         (WebCore::MediaStreamTrack::create):
2633         (WebCore::MediaStreamTrack::MediaStreamTrack):
2634         (WebCore::MediaStreamTrack::~MediaStreamTrack):
2635         (WebCore::MediaStreamTrack::setEnabled):
2636         (WebCore::MediaStreamTrack::readyState):
2637         (WebCore):
2638         (WebCore::MediaStreamTrack::sourceChangedState):
2639         (WebCore::MediaStreamTrack::stop):
2640         (WebCore::MediaStreamTrack::interfaceName):
2641         (WebCore::MediaStreamTrack::scriptExecutionContext):
2642         (WebCore::MediaStreamTrack::eventTargetData):
2643         (WebCore::MediaStreamTrack::ensureEventTargetData):
2644         * Modules/mediastream/MediaStreamTrack.h:
2645         * Modules/mediastream/MediaStreamTrack.idl:
2646         * WebCore.gypi:
2647         * dom/EventNames.h:
2648         (WebCore):
2649         * dom/EventTargetFactory.in:
2650         * platform/chromium/support/WebMediaStreamDescriptor.cpp:
2651         * platform/chromium/support/WebMediaStreamSource.cpp:
2652         (WebKit::WebMediaStreamSource::setReadyState):
2653         (WebKit):
2654         (WebKit::WebMediaStreamSource::readyState):
2655         * platform/mediastream/MediaStreamSource.cpp: Copied from Source/WebCore/platform/mediastream/MediaStreamSource.h.
2656         (WebCore):
2657         (WebCore::MediaStreamSource::create):
2658         (WebCore::MediaStreamSource::MediaStreamSource):
2659         (WebCore::MediaStreamSource::setReadyState):
2660         (WebCore::MediaStreamSource::addObserver):
2661         (WebCore::MediaStreamSource::removeObserver):
2662         * platform/mediastream/MediaStreamSource.h:
2663         (Observer):
2664         (WebCore::MediaStreamSource::Observer::~Observer):
2665         (MediaStreamSource):
2666         (WebCore::MediaStreamSource::readyState):
2667         * platform/mediastream/chromium/MediaStreamCenterChromium.cpp:
2668         (WebCore::MediaStreamCenterChromium::queryMediaStreamSources):
2669         (WebCore::MediaStreamCenterChromium::didCreateMediaStream):
2670
2671 2012-07-24  Scott Graham  <scottmg@chromium.org>
2672
2673         Use native (non-cygwin) binaries for perl, gperf, and bison in Chromium
2674         https://bugs.webkit.org/show_bug.cgi?id=91667
2675
2676         Reviewed by Tony Chang.
2677
2678         Using native tools instead of cygwin version improves build time
2679         performance by roughly 50% (on top of previous cl-instead-of-gcc
2680         change).
2681
2682         Also, use - instead of / for cl flags, otherwise preprocessing fails
2683         very slowly (due to retry loop). And, replace \ with / in gperf
2684         command line. Without this, gperf emits the filename literally in
2685         #line directives which causes VS to error with "unescaped \ in
2686         string". Bizarrely, building ColorData.cpp with those \ in place
2687         causes the IDE to exit with no error message, which was the cause of
2688         the previous canary failures.
2689
2690         No new tests.
2691
2692         * WebCore.gyp/WebCore.gyp:
2693         * WebCore.gyp/scripts/rule_bison.py:
2694         * bindings/scripts/preprocessor.pm:
2695         (applyPreprocessor):
2696         * make-hash-tools.pl:
2697
2698 2012-07-24  Daniel Cheng  <dcheng@chromium.org>
2699
2700         Files from drag and file <input> should use getMIMETypeForExtension to determine content type.
2701         https://bugs.webkit.org/show_bug.cgi?id=91702
2702
2703         Reviewed by Jian Li.
2704
2705         Awhile back, we changed File to only use getWellKnownMIMETypeForExtension to prevent web
2706         pages from being able to detect what applications a user has installed indirectly through
2707         the MIME types. However, some sites like YouTube's drag and drop uploader use MIME types
2708         that aren't in WebKit's internal list, so we relax the restriction for Files that originate
2709         from an user action.
2710
2711         * fileapi/File.cpp:
2712         (WebCore::getContentTypeFromFileName):
2713         (WebCore::createBlobDataForFile):
2714         (WebCore::createBlobDataForFileWithName):
2715         (WebCore::createBlobDataForFileWithMetadata):
2716         (WebCore::File::createWithRelativePath):
2717         (WebCore::File::File):
2718         * fileapi/File.h:
2719         (File):
2720         (WebCore::File::create):
2721         (WebCore::File::createWithName):
2722         * html/FileInputType.cpp:
2723         (WebCore::FileInputType::createFileList):
2724         * platform/chromium/ChromiumDataObject.cpp:
2725         (WebCore::ChromiumDataObject::addFilename):
2726         * platform/gtk/ClipboardGtk.cpp:
2727         (WebCore::ClipboardGtk::files):
2728         * platform/mac/ClipboardMac.mm:
2729         (WebCore::ClipboardMac::files):
2730         * platform/qt/ClipboardQt.cpp:
2731         (WebCore::ClipboardQt::files):
2732         * platform/win/ClipboardWin.cpp:
2733         (WebCore::ClipboardWin::files):
2734
2735 2012-07-24  Vsevolod Vlasov  <vsevik@chromium.org>
2736
2737         Web Inspector: Snippets UI polish
2738         https://bugs.webkit.org/show_bug.cgi?id=92142
2739
2740         Reviewed by Pavel Feldman.
2741
2742         Changed snippets context menu items.
2743         Added run snippet status bar button.
2744         Removed unused edit source button.
2745
2746         * English.lproj/localizedStrings.js:
2747         * inspector/front-end/Images/statusbarButtonGlyphs.png:
2748         * inspector/front-end/ScriptSnippetModel.js:
2749         (WebInspector.SnippetJavaScriptSourceFrame):
2750         (WebInspector.SnippetJavaScriptSourceFrame.prototype.statusBarItems):
2751         (WebInspector.SnippetJavaScriptSourceFrame.prototype._runButtonClicked):
2752         * inspector/front-end/ScriptsNavigator.js:
2753         (WebInspector.SnippetsNavigatorView.prototype.getOrCreateFolderTreeElement):
2754         (WebInspector.SnippetsNavigatorView.prototype.handleContextMenu):
2755         * inspector/front-end/ScriptsPanel.js:
2756         (WebInspector.ScriptsPanel.prototype._updateScriptViewStatusBarItems):
2757         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
2758         * inspector/front-end/SourceFrame.js:
2759         (WebInspector.SourceFrame.prototype.statusBarItems):
2760         * inspector/front-end/inspector.css:
2761         * inspector/front-end/scriptsPanel.css:
2762         (.evaluate-snippet-status-bar-item .glyph):
2763         (.evaluate-snippet-status-bar-item.toggled .glyph):
2764
2765 2012-07-24  Nico Weber  <thakis@chromium.org>
2766
2767         [chromium/mac] Remove webcore_resource_files from WebCore.gypi
2768         https://bugs.webkit.org/show_bug.cgi?id=92129
2769
2770         Reviewed by Adam Barth.
2771
2772         It was added in http://trac.webkit.org/changeset/81706/trunk/Source/WebCore/WebCore.gypi .
2773         The changes in that revision were mostly reverted in http://trac.webkit.org/changeset/119921 ,
2774         but this block was forgotten. Since it just confused me for a bit, remove it.
2775
2776         * WebCore.gyp/WebCore.gyp:
2777
2778 2012-07-24  Julien Chaffraix  <jchaffraix@webkit.org>
2779
2780         inline-table wrapper should be generated for display: inline element only
2781         https://bugs.webkit.org/show_bug.cgi?id=92054
2782
2783         Reviewed by Abhishek Arya.
2784
2785         CSS 2.1 only takes into account the display when determining if we should generate
2786         an inline-table. My misreading of the spec would make us generate an inline-table
2787         wrapper for any inline formatting context.
2788
2789         Test: fast/table/inline-block-generates-table-wrapper.html
2790
2791         * rendering/RenderTable.cpp:
2792         (WebCore::RenderTable::createAnonymousWithParentRenderer):
2793         Changed to use display instead of isInline to properly match the spec.
2794
2795 2012-07-24  Alec Flett  <alecflett@chromium.org>
2796
2797         IndexedDB: Temporarily continue generating backend keys for empty key lists
2798         https://bugs.webkit.org/show_bug.cgi?id=92012
2799
2800         Reviewed by Tony Chang.
2801
2802         Temporarily change key behavior to allow chromium in_process_webkit
2803         to call putWithIndexKeys without inadvertently preventing index
2804         key generation. Note this is temporary until frontend key generation
2805         patch lands.
2806
2807         No new tests, this is part of a refactor that doesn't change behavior.
2808
2809         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
2810         (WebCore::IDBObjectStoreBackendImpl::putInternal):
2811
2812 2012-07-24  Pavel Feldman  <pfeldman@chromium.org>
2813
2814         Web Inspector: introduce UISourceCodeFrame.
2815         https://bugs.webkit.org/show_bug.cgi?id=92124
2816
2817         Reviewed by Vsevolod Vlasov.
2818
2819         Generic implementation of SourceFrame over UISourceCode added.
2820
2821         * WebCore.gypi:
2822         * WebCore.vcproj/WebCore.vcproj:
2823         * inspector/compile-front-end.py:
2824         * inspector/front-end/ScriptsPanel.js:
2825         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
2826         * inspector/front-end/StylesPanel.js:
2827         * inspector/front-end/UISourceCodeFrame.js: Added.
2828         (WebInspector.UISourceCodeFrame):
2829         (WebInspector.UISourceCodeFrame.prototype.canEditSource):
2830         (WebInspector.UISourceCodeFrame.prototype.commitEditing):
2831         (WebInspector.UISourceCodeFrame.prototype.afterTextChanged):
2832         (WebInspector.UISourceCodeFrame.prototype._didEditContent):
2833         (WebInspector.UISourceCodeFrame.prototype._onContentChanged):
2834         (WebInspector.UISourceCodeFrame.prototype.populateTextAreaContextMenu):
2835         * inspector/front-end/WebKit.qrc:
2836         * inspector/front-end/inspector.html:
2837
2838 2012-07-24  Dan Bernstein  <mitz@apple.com>
2839
2840         <rdar://problem/11945102> REGRESSION (r109451): Overlay scrollbars always use the default style, regardless of background color
2841         https://bugs.webkit.org/show_bug.cgi?id=92115
2842
2843         Reviewed by Mark Rowe.
2844
2845         * platform/Scrollbar.cpp:
2846         (WebCore::Scrollbar::scrollbarOverlayStyle): Reversed an incorrect null check.
2847
2848 2012-07-24  Andrew Wilson  <atwilson@chromium.org>
2849
2850         Another prospective build fix for Chromium. Unreviewed.
2851
2852         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.h:
2853
2854 2012-07-24  Andrew Wilson  <atwilson@chromium.org>
2855
2856         Unreviewed prospective build fix for Chromium. Changed include of hb.h in HarfBuzzNGFace.h
2857
2858         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.h:
2859
2860 2012-07-24  Dominik Röttsches  <dominik.rottsches@intel.com>
2861
2862         HarfBuzzFaceNG.h forward declarations conflict with newer versions of Harfbuzz
2863         https://bugs.webkit.org/show_bug.cgi?id=92103
2864
2865         Reviewed by Philippe Normand.
2866
2867         As preparation for enabling harfbuzz-ng for EFL, I would like to include the header
2868         here since the forward declarations are conflicting with the harfbuzz version
2869         we will use for EFL.
2870
2871         No new tests, no change in behavior.
2872
2873         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.h:
2874
2875 2012-07-24  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2876
2877         Fix blend filter for autovectorizing
2878         https://bugs.webkit.org/show_bug.cgi?id=91398
2879
2880         Reviewed by Nikolas Zimmermann.
2881
2882         To support auto-vectorizing, the loop had to be unswitched, and regular arrays used that 
2883         did not do boundary-checks in the inner loop. Finally the integer division by 255
2884         was optimized not use integer division intrinsics.
2885
2886         On a X86-64 architechture using GCC -O3 on the file, this gives a speed-up of 2.9x.
2887
2888         * platform/graphics/filters/FEBlend.cpp:
2889         (WebCore::fastDivideBy255):
2890         (BlendNormal):
2891         (WebCore::BlendNormal::apply):
2892         (BlendMultiply):
2893         (WebCore::BlendMultiply::apply):
2894         (BlendScreen):
2895         (WebCore::BlendScreen::apply):
2896         (BlendDarken):
2897         (WebCore::BlendDarken::apply):
2898         (BlendLighten):
2899         (WebCore::BlendLighten::apply):
2900         (BlendUnknown):
2901         (WebCore::BlendUnknown::apply):
2902         (WebCore::platformApply):
2903         (WebCore::FEBlend::platformApplyGeneric):
2904         (WebCore::FEBlend::platformApplySoftware):
2905         * platform/graphics/filters/FEBlend.h:
2906         (FEBlend):
2907
2908 2012-07-23  Hans Wennborg  <hans@chromium.org>
2909
2910         Speech JavaScript API: Add the SpeechRecognitionResult.emma attribute
2911         https://bugs.webkit.org/show_bug.cgi?id=91743
2912
2913         Reviewed by Adam Barth.
2914
2915         Implement the 'emma' attribute as described in the spec draft at
2916         http://dvcs.w3.org/hg/speech-api/raw-file/tip/speechapi.html
2917
2918         Test: fast/speech/scripted/emma.html
2919
2920         * Modules/speech/SpeechRecognitionResult.cpp:
2921         (WebCore::SpeechRecognitionResult::~SpeechRecognitionResult):
2922         (WebCore):
2923         (WebCore::SpeechRecognitionResult::emma):
2924         * Modules/speech/SpeechRecognitionResult.h:
2925         (WebCore):
2926         (SpeechRecognitionResult):
2927         * Modules/speech/SpeechRecognitionResult.idl:
2928         * WebCore.gypi:
2929         * bindings/v8/custom/V8SpeechRecognitionResultCustom.cpp:
2930         (WebCore):
2931         (WebCore::V8SpeechRecognitionResult::visitDOMWrapper):
2932           We need to add an implicit reference from the result object to the
2933           emma object to keep the latters DOM tree alive across
2934           garbage-collection.
2935
2936 2012-07-24  Andrei Poenaru  <poenaru@adobe.com>
2937
2938         Web Inspector: Protocol Extension: add getFlowByName command
2939         https://bugs.webkit.org/show_bug.cgi?id=91855
2940
2941         Reviewed by Pavel Feldman.
2942
2943         The "getFlowByName" command should return a NamedFlow for a given document and name.
2944
2945         Test: inspector/styles/protocol-css-regions-commands.html
2946
2947         * inspector/Inspector.json:
2948         * inspector/InspectorCSSAgent.cpp:
2949         (WebCore::InspectorCSSAgent::getFlowByName):
2950         (WebCore):
2951         * inspector/InspectorCSSAgent.h:
2952         (InspectorCSSAgent):
2953         * inspector/front-end/CSSStyleModel.js:
2954         (WebInspector.CSSStyleModel.prototype.getNamedFlowCollectionAsync):
2955         (WebInspector.CSSStyleModel.prototype.getFlowByNameAsync):
2956         (WebInspector.NamedFlow):
2957         (WebInspector.NamedFlow.parsePayload):
2958
2959 2012-07-23  Oswald Buddenhagen  <oswald.buddenhagen@nokia.com>
2960
2961         [Qt] Fix compilation against namespaced Qt
2962
2963         Reviewed by Simon Hausmann.
2964
2965         * platform/graphics/Font.h:
2966         * platform/network/ResourceHandleInternal.h:
2967         * platform/qt/ThirdPartyCookiesQt.h:
2968
2969 2012-07-24  Anthony Scian  <ascian@rim.com>
2970
2971         Web Inspector [JSC]: Enable initiator column in network panel.
2972         https://bugs.webkit.org/show_bug.cgi?id=65533
2973
2974         Reviewed by Vsevolod Vlasov.
2975
2976         With 40118 fixed for webkit, Preferences.displayInitiator should be set to true.
2977         Removed references to it since the optionality is no longer required.
2978
2979         Test: http/tests/inspector/network/network-initiator.html
2980
2981         * inspector/front-end/NetworkPanel.js:
2982         (WebInspector.NetworkLogView.prototype._createTable):
2983         (WebInspector.NetworkLogView.prototype.switchToDetailedView):
2984         (WebInspector.NetworkLogView.prototype.switchToBriefView):
2985         (WebInspector.NetworkDataGridNode.prototype.createCells):
2986         (WebInspector.NetworkDataGridNode.prototype.refreshRequest):
2987         * inspector/front-end/Settings.js:
2988
2989 2012-07-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2990
2991         Missing *explicit* keyword in dom and page.
2992         https://bugs.webkit.org/show_bug.cgi?id=92074
2993
2994         Reviewed by Kentaro Hara.
2995
2996         Some constructors missed to use *explicit* keyword. They need to be added
2997         *explicit* keyword to contructor which has a parameter in order to avoid
2998         implicit type conversion.
2999
3000         Some files in dom directory can't use explicit keyword because of build breaks.
3001
3002         No new tests. Covered by existing tests.
3003
3004         * dom/BeforeLoadEvent.h:
3005         (WebCore::BeforeLoadEvent::BeforeLoadEvent):
3006         * dom/BeforeTextInsertedEvent.h:
3007         (BeforeTextInsertedEvent):
3008         * dom/ChildListMutationScope.h:
3009         (WebCore::ChildListMutationScope::ChildListMutationScope):
3010         * dom/ChildNodeList.h:
3011         (ChildNodeList):
3012         * dom/ClientRect.h:
3013         (ClientRect):
3014         * dom/ClientRectList.h:
3015         (ClientRectList):
3016         * dom/ComposedShadowTreeWalker.h:
3017         (ComposedShadowTreeParentWalker):
3018         * dom/DOMCoreException.h:
3019         (WebCore::DOMCoreException::DOMCoreException):
3020         * dom/DOMImplementation.h:
3021         (DOMImplementation):
3022         * dom/DatasetDOMStringMap.h:
3023         (WebCore::DatasetDOMStringMap::DatasetDOMStringMap):
3024         * dom/DeviceMotionController.h:
3025         (DeviceMotionController):
3026         * dom/DeviceOrientationController.h:
3027         (DeviceOrientationController):
3028         * dom/DocumentParser.h:
3029         (DocumentParser):
3030         * dom/EventException.h:
3031         (WebCore::EventException::EventException):
3032         * dom/EventListener.h:
3033         (WebCore::EventListener::EventListener):
3034         * dom/ExceptionBase.h:
3035         (ExceptionBase):
3036         * dom/GenericEventQueue.h:
3037         (GenericEventQueue):
3038         * dom/KeyboardEvent.h:
3039         (WebCore::KeypressCommand::KeypressCommand):
3040         * dom/MemoryInstrumentation.h:
3041         (WebCore::MemoryObjectInfo::MemoryObjectInfo):
3042         * dom/MessageChannel.h:
3043         (MessageChannel):
3044         * dom/MessagePort.h:
3045         (MessagePort):
3046         * dom/MessagePortChannel.h:
3047         (MessagePortChannel):
3048         * dom/MutationObserver.h:
3049         * dom/NamedNodeMap.h:
3050         (WebCore::NamedNodeMap::NamedNodeMap):
3051         * dom/NodeFilter.h:
3052         (WebCore::NodeFilter::NodeFilter):
3053         * dom/NodeWithIndex.h:
3054         (WebCore::NodeWithIndex::NodeWithIndex):
3055         * dom/Range.h:
3056         * dom/RangeException.h:
3057         (WebCore::RangeException::RangeException):
3058         * dom/RawDataDocumentParser.h:
3059         (WebCore::RawDataDocumentParser::RawDataDocumentParser):
3060         * dom/ScriptRunner.h:
3061         (ScriptRunner):
3062         * dom/SelectorQuery.h:
3063         (SelectorQuery):
3064         * dom/ShadowRoot.h:
3065         (ShadowRoot):
3066         * dom/SpaceSplitString.h:
3067         (SpaceSplitStringData):
3068         * dom/StaticHashSetNodeList.h:
3069         (StaticHashSetNodeList):
3070         * dom/StaticNodeList.h:
3071         (WebCore::StaticNodeList::StaticNodeList):
3072         * dom/TransformSource.h:
3073         (TransformSource):
3074         * dom/TreeScope.h:
3075         (TreeScope):
3076         * dom/WebKitNamedFlowCollection.h:
3077         (WebKitNamedFlowCollection):
3078         * page/EventHandler.h:
3079         (EventHandler):
3080         * page/FocusController.h:
3081         (FocusController):
3082         * page/FrameView.h:
3083         (FrameView):
3084         * page/MemoryInfo.h:
3085         (MemoryInfo):
3086         * page/Page.h:
3087         (Page):
3088         * page/PageGroup.h:
3089         (PageGroup):
3090         * page/PrintContext.h:
3091         (PrintContext):
3092         * page/Settings.h:
3093         (Settings):
3094         * page/SpeechInput.h:
3095         (SpeechInput):
3096         * page/SpeechInputResultList.h:
3097         (SpeechInputResultList):
3098         * page/WebKitAnimation.h:
3099         * page/WindowFeatures.h:
3100         (WindowFeatures):
3101         * page/WorkerNavigator.h:
3102         (WorkerNavigator):
3103
3104 2012-07-24  Kent Tamura  <tkent@chromium.org>
3105
3106         Replace some callsites of shadowAncestorNode() with shadowHost()
3107         https://bugs.webkit.org/show_bug.cgi?id=92060
3108
3109         Reviewed by Hajime Morita.
3110
3111         shadowAncestorNode() is deprecated.
3112
3113         No new tests. This shouldn't change behaviors.
3114
3115         * html/shadow/MediaControlElements.cpp:
3116         (WebCore::toParentMediaElement):
3117         * html/shadow/TextControlInnerElements.h:
3118         (WebCore::SpinButtonElement::isEnabledFormControl):
3119         (WebCore::SpinButtonElement::isReadOnlyFormControl):
3120         * platform/efl/RenderThemeEfl.cpp:
3121         (WebCore::RenderThemeEfl::paintMediaFullscreenButton):
3122         (WebCore::RenderThemeEfl::paintMediaMuteButton):
3123         * platform/gtk/RenderThemeGtk.cpp:
3124         (WebCore::getMediaElementFromRenderObject):
3125         (WebCore::centerRectVerticallyInParentInputElement):
3126         * platform/qt/RenderThemeQt.cpp:
3127         (WebCore::RenderThemeQt::paintSearchFieldCancelButton):
3128         (WebCore::RenderThemeQt::paintMediaSliderThumb):
3129         Removed an ASSERT() because nullness of o->node() is already asserted.
3130         * rendering/RenderInputSpeech.cpp:
3131         (WebCore::RenderInputSpeech::paintInputFieldSpeechButton):
3132         * rendering/RenderMediaControlsChromium.cpp:
3133         (WebCore::paintMediaSliderThumb):
3134         Passing shadowHost() to toParentMediaElement(), which accepts 0 and will return 0.
3135         (WebCore::paintMediaVolumeSliderThumb): ditto.
3136         * rendering/RenderThemeChromiumSkia.cpp:
3137         (WebCore::RenderThemeChromiumSkia::paintSearchFieldCancelButton):
3138         (WebCore::RenderThemeChromiumSkia::paintSearchFieldResultsDecoration):
3139         (WebCore::RenderThemeChromiumSkia::paintSearchFieldResultsButton):
3140         * rendering/RenderThemeMac.mm:
3141         (WebCore::RenderThemeMac::paintSearchFieldCancelButton):
3142         Remove an ASSERT(input) because input never be null unless o->node() is
3143         null. If o->node() is null, this function crashes.
3144         (WebCore::RenderThemeMac::paintSearchFieldResultsDecoration):
3145         (WebCore::RenderThemeMac::paintSearchFieldResultsButton):
3146         (WebCore::RenderThemeMac::paintMediaMuteButton):
3147         It's ok to ignore "node is a media element" case because this function
3148         works only if node->isMediaControlElement().
3149         (WebCore::RenderThemeMac::paintMediaPlayButton): ditto.
3150         (WebCore::RenderThemeMac::paintMediaSliderTrack): ditto.
3151         * rendering/RenderThemeSafari.cpp:
3152         (WebCore::RenderThemeSafari::paintSearchFieldCancelButton):
3153         Remove an ASSERT(input) because input never be null unless o->node() is
3154         null. If o->node() is null, this function crashes.
3155         (WebCore::RenderThemeSafari::paintSearchFieldResultsDecoration): ditto.
3156         (WebCore::RenderThemeSafari::paintSearchFieldResultsButton): ditto.
3157         * rendering/RenderThemeWinCE.cpp:
3158         (WebCore::mediaElementParent):
3159
3160 2012-07-24  Peter Beverloo  <peter@chromium.org>
3161
3162         [Chromium] Build fix for Android after r123424
3163         https://bugs.webkit.org/show_bug.cgi?id=92082
3164
3165         Unreviewed build fix.
3166
3167         Mark removed the PlatformSupport.h header from ScrollbarThemeChromiumAndroid.cpp
3168         in r123424, while there still are two references left to another method and a
3169         constant. Re-add the include directive.
3170
3171         * platform/chromium/ScrollbarThemeChromiumAndroid.cpp:
3172
3173 2012-07-24  Kentaro Hara  <haraken@chromium.org>
3174
3175         [JSC] REGRESSION(r122912): CodeGeneratorJS.pm generates wrong code
3176         for static attributes in supplemental IDL files
3177         https://bugs.webkit.org/show_bug.cgi?id=91925
3178
3179         Reviewed by Adam Barth.
3180
3181         r122912 implemented static attributes in CodeGeneratorJS.pm.
3182         However, it generates wrong code for static attributes in supplemental
3183         IDL files. This patch fixes it as shown in JSTestInterface.cpp.
3184         This fix aligns with the fix in CodeGeneratorV8.pm (r123308).
3185
3186         Test: bindings/scripts/test/TestSupplemental.idl
3187
3188         * bindings/scripts/CodeGeneratorJS.pm:
3189         (GenerateImplementation):
3190         * bindings/scripts/test/JS/JSTestInterface.cpp:
3191         (WebCore::jsTestInterfaceConstructorSupplementalStaticReadOnlyAttr):
3192         (WebCore::jsTestInterfaceConstructorSupplementalStaticAttr):
3193         (WebCore::setJSTestInterfaceConstructorSupplementalStaticAttr):
3194
3195 2012-07-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3196
3197         Add *explicit* keyword to constructor which has a parameter in bridge, history, loader and plugins.
3198         https://bugs.webkit.org/show_bug.cgi?id=92064
3199
3200         Reviewed by Kentaro Hara.
3201
3202         Some constructors missed to use *explicit* keyword. They need to be added
3203         *explicit* keyword to contructor which has a parameter in order to avoid
3204         implicit type conversion.
3205
3206         No new tests. Covered by existing tests.
3207
3208         * bridge/IdentifierRep.h:
3209         (WebCore::IdentifierRep::IdentifierRep):
3210         * history/BackForwardListImpl.h:
3211         (BackForwardListImpl):
3212         * history/CachedFrame.h:
3213         (CachedFrame):
3214         * history/HistoryItem.h:
3215         (HistoryItem):
3216         * loader/DocumentWriter.h:
3217         (DocumentWriter):
3218         * loader/FrameNetworkingContext.h:
3219         (WebCore::FrameNetworkingContext::FrameNetworkingContext):
3220         * loader/HistoryController.h:
3221         * loader/ImageLoader.h:
3222         (ImageLoader):
3223         * loader/LinkLoader.h:
3224         (LinkLoader):
3225         * loader/MainResourceLoader.h:
3226         (MainResourceLoader):
3227         * loader/NavigationAction.h:
3228         (NavigationAction):
3229         * loader/NavigationScheduler.h:
3230         (NavigationScheduler):
3231         * loader/PolicyChecker.h:
3232         (PolicyChecker):
3233         * loader/SubframeLoader.h:
3234         (SubframeLoader):
3235         * loader/ThreadableLoaderClientWrapper.h:
3236         (WebCore::ThreadableLoaderClientWrapper::ThreadableLoaderClientWrapper):
3237         * plugins/PluginData.h:
3238         (PluginData):
3239         * plugins/PluginViewBase.h:
3240         (WebCore::PluginViewBase::PluginViewBase):
3241
3242 2012-07-24  Patrick Gansterer  <paroga@webkit.org>
3243
3244         [Qt] Fix conversion from GregorianDateTime to QTime
3245         https://bugs.webkit.org/show_bug.cgi?id=92068
3246
3247         Reviewed by Simon Hausmann.
3248
3249         * bridge/qt/qt_runtime.cpp:
3250         (JSC::Bindings::convertValueToQVariant):
3251         * bridge/qt/qt_runtime_qt4.cpp:
3252         (JSC::Bindings::convertValueToQVariant):
3253
3254 2012-07-24  Arko Saha  <arko@motorola.com>
3255
3256         Microdata: Implement PropertyNodeList interface.
3257         https://bugs.webkit.org/show_bug.cgi?id=80269
3258
3259         Reviewed by Ryosuke Niwa.
3260
3261         Added support for PropertyNodeList interface. Currently HTMLPropertiesCollection.namedItem(name)
3262         returns NodeList object. Made changes so that it will return PropertyNodeList object.
3263
3264         Implemented propertyNodeList.getValues() method. It returns an array of various values. Its
3265         values are obtained from the "itemValue" DOM property of each of the elements represented by
3266         the object, in tree order.
3267
3268         Spec: http://www.whatwg.org/specs/web-apps/current-work/multipage/common-dom-interfaces.html#propertynodelist
3269
3270         Tests: fast/dom/MicroData/nameditem-returns-propertynodelist.html
3271                fast/dom/MicroData/propertynodelist-getvalues-array-values-obtained-from-itemvalue-of-each-element.html
3272                fast/dom/MicroData/propertynodelist-getvalues-test.html
3273                fast/dom/MicroData/propertynodelist-test-add-remove-element.html
3274
3275         * CMakeLists.txt:
3276         * DerivedSources.cpp:
3277         * DerivedSources.make:
3278         * DerivedSources.pri:
3279         * GNUmakefile.list.am:
3280         * Target.pri:
3281         * UseJSC.cmake:
3282         * UseV8.cmake:
3283         * WebCore.gypi:
3284         * WebCore.vcproj/WebCore.vcproj:
3285         * WebCore.xcodeproj/project.pbxproj:
3286         * bindings/gobject/GNUmakefile.am:
3287         * bindings/js/JSBindingsAllInOne.cpp:
3288         * bindings/js/JSMicroDataItemValueCustom.cpp: Added.
3289         (WebCore):
3290         (WebCore::toJS): Added toJS() custom method. Returns Node if itemValue is node else returns String.
3291         * bindings/v8/custom/V8MicroDataItemValueCustom.cpp: Added.
3292         (WebCore):
3293         (WebCore::toV8): Added toV8 custom code.
3294         * dom/DynamicNodeList.cpp:
3295         (WebCore::DynamicNodeListCacheBase::rootNode): Return document if owner node has itemref attribute specified.
3296         (WebCore):
3297         (WebCore::DynamicNodeListCacheBase::ownerNodeHasItemRefAttribute): Returns true if owner node has itemref attribute
3298         specified with root type NodeListRootedAtDocumentIfOwnerHasItemrefAttr.
3299         (WebCore::DynamicNodeListCacheBase::invalidateCache):
3300         (WebCore::DynamicNodeList::itemWithName): Update itemrefElements cache if root type is
3301         NodeListIsRootedAtDocumentIfOwnerHasItemrefAttr.
3302         * dom/DynamicNodeList.h: Added m_hasItemRefElements in DynamicNodeListCacheBase to check if itemRefElmenets cache
3303         is valid.
3304         (WebCore::DynamicNodeListCacheBase::DynamicNodeListCacheBase):
3305         (WebCore::DynamicNodeListCacheBase::isRootedAtDocument):
3306         (DynamicNodeListCacheBase):
3307         (WebCore::DynamicNodeListCacheBase::isItemRefElementsCacheValid):
3308         (WebCore::DynamicNodeListCacheBase::setItemRefElementsCacheValid):
3309         (WebCore::DynamicNodeListCacheBase::rootType): Returns cached root type.
3310         (WebCore::DynamicNodeListCacheBase::shouldInvalidateTypeOnAttributeChange): Invalidate NodeListCache on itemref
3311         attribute change.
3312         * dom/Node.cpp:
3313         (WebCore::Node::propertyNodeList):
3314         * dom/Node.h:
3315         (WebCore):
3316         (Node):
3317         * dom/PropertyNodeList.cpp: Added.
3318         (WebCore):
3319         (WebCore::PropertyNodeList::PropertyNodeList):
3320         (WebCore::PropertyNodeList::~PropertyNodeList):
3321         (WebCore::PropertyNodeList::elementIsPropertyOfRefElement): Checks if the testElement is a property of Microdata
3322         item.
3323         (WebCore::PropertyNodeList::updateRefElements):
3324         (WebCore::PropertyNodeList::nodeMatches):
3325         (WebCore::PropertyNodeList::getValues): Returns PropertyValueArray whose values are obtained from the
3326         itemValue DOM property of each of the elements represented by the object, in tree order.
3327         * dom/PropertyNodeList.h: Added.
3328         (WebCore):
3329         (PropertyNodeList):
3330         (WebCore::PropertyNodeList::create):
3331         * dom/PropertyNodeList.idl: Added.
3332         * html/HTMLCollection.cpp:
3333         (WebCore::DynamicNodeListCacheBase::itemCommon): Update itemrefElements cache if its a NodeListCollectionType with
3334         root type NodeListIsRootedAtDocumentIfOwnerHasItemrefAttr.
3335         * html/HTMLElement.cpp:
3336         (WebCore::HTMLElement::properties):
3337         (WebCore):
3338         (WebCore::HTMLElement::getItemRefElements): Returns the ItemRefElements list of given element. Added this
3339         method to share the code between HTMLPropertiesCollection and PropertyNodeList to update itemRefElements.
3340         * html/HTMLElement.h:
3341         (HTMLElement):
3342         * html/HTMLPropertiesCollection.cpp:
3343         (WebCore::HTMLPropertiesCollection::HTMLPropertiesCollection):
3344         (WebCore::HTMLPropertiesCollection::updateRefElements):
3345         (WebCore::HTMLPropertiesCollection::updateNameCache):
3346         (WebCore::HTMLPropertiesCollection::namedItem): Return PropertyNodeList object instead of NodeList.
3347         (WebCore::HTMLPropertiesCollection::hasNamedItem): Return true if it finds an item with given
3348         name in the properties collection.
3349         * html/HTMLPropertiesCollection.h: Removed m_hasItemRefElements member variable, now DynamicNodeListCacheBase
3350         has isItemRefElementsCacheValid. Also removed m_hasPropertyNameCache, as DynamicNodeListCacheBase already has
3351         hasNameCache() and setHasNameCache().
3352         (WebCore):
3353         (HTMLPropertiesCollection):
3354         (WebCore::HTMLPropertiesCollection::invalidateCache):
3355         (WebCore::HTMLPropertiesCollection::updatePropertyCache):
3356         * html/HTMLPropertiesCollection.idl:
3357         * html/MicroDataItemValue.idl: Added.
3358         * page/DOMWindow.idl:
3359
3360 2012-07-24  Kentaro Hara  <haraken@chromium.org>
3361
3362         [JSC] REGRESSION(r122912): CodeGeneratorJS.pm should not
3363         implicitly assume ScriptExecutionContext for static attributes
3364         https://bugs.webkit.org/show_bug.cgi?id=91924
3365
3366         Reviewed by Adam Barth.
3367
3368         r122912 implemented static attributes in CodeGeneratorJS.pm.
3369         However, the generated code assumes that static attributes
3370         always require ScriptExecutionContext, which is wrong.
3371         If we need a ScriptExecutionContext, we should specify
3372         [CallWith=ScriptExecutionContext].
3373
3374         This patch fixes CodeGeneratorJS.pm so that static attributes
3375         do not assume ScriptExecutionContext. This fix aligns with
3376         the fix in CodeGeneratorV8.pm in r123308.
3377
3378         Test: bindings/scripts/test/TestObj.idl
3379
3380         * bindings/scripts/CodeGeneratorJS.pm:
3381         (GenerateImplementation):
3382         * bindings/scripts/test/JS/JSTestInterface.cpp:
3383         (WebCore::jsTestInterfaceConstructorSupplementalStaticReadOnlyAttr):
3384         (WebCore::jsTestInterfaceConstructorSupplementalStaticAttr):
3385         (WebCore::setJSTestInterfaceConstructorSupplementalStaticAttr):
3386         * bindings/scripts/test/JS/JSTestObj.cpp:
3387         (WebCore::jsTestObjConstructorStaticReadOnlyIntAttr):
3388         (WebCore::jsTestObjConstructorStaticStringAttr):
3389         (WebCore::setJSTestObjConstructorStaticStringAttr):
3390
3391 2012-07-23  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3392
3393         Missing *explicit* keyword in editing.
3394         https://bugs.webkit.org/show_bug.cgi?id=92055
3395
3396         Reviewed by Ryosuke Niwa.
3397
3398         Some constructors missed to use *explicit* keyword. They need to be added
3399         *explicit* keyword to contructor which has a parameter in order to avoid
3400         implicit type conversion.
3401
3402         No new tests. Covered by existing tests.
3403
3404         * editing/AlternativeTextController.h:
3405         (WebCore::AlternativeTextController::UNLESS_ENABLED):
3406         * editing/BreakBlockquoteCommand.h:
3407         (BreakBlockquoteCommand):
3408         * editing/DeleteButton.h:
3409         (DeleteButton):
3410         * editing/DeleteButtonController.h:
3411         (DeleteButtonController):
3412         * editing/EditCommand.h:
3413         (EditCommand):
3414         (WebCore::SimpleEditCommand::SimpleEditCommand):
3415         * editing/EditingBehavior.h:
3416         (WebCore::EditingBehavior::EditingBehavior):
3417         * editing/EditingStyle.h:
3418         (EditingStyle):
3419         * editing/Editor.h:
3420         (Editor):
3421         * editing/FrameSelection.h:
3422         (FrameSelection):
3423         * editing/InsertLineBreakCommand.h:
3424         (InsertLineBreakCommand):
3425         * editing/ModifySelectionListLevel.h:
3426         (ModifySelectionListLevelCommand):
3427         (DecreaseSelectionListLevelCommand):
3428         * editing/RemoveFormatCommand.h:
3429         (RemoveFormatCommand):
3430         * editing/RemoveNodeCommand.h:
3431         (RemoveNodeCommand):
3432         * editing/RemoveNodePreservingChildrenCommand.h:
3433         (RemoveNodePreservingChildrenCommand):
3434         * editing/ReplaceNodeWithSpanCommand.h:
3435         (ReplaceNodeWithSpanCommand):
3436         * editing/TextInsertionBaseCommand.h:
3437         (TextInsertionBaseCommand):
3438         * editing/UndoManager.h:
3439         (UndoManager):
3440         * editing/UnlinkCommand.h:
3441         (UnlinkCommand):
3442         * editing/WrapContentsInDummySpanCommand.h:
3443         (WrapContentsInDummySpanCommand):
3444
3445 2012-07-23  Dominic Mazzoni  <dmazzoni@google.com>
3446
3447         AX: Need AccessibilityObjects for nodes without renderers in canvas subtree
3448         https://bugs.webkit.org/show_bug.cgi?id=87899
3449
3450         Reviewed by Chris Fleizach.
3451
3452         Refactors AccessibilityRenderObject so that it inherits from a new class,
3453         AccessibilityNodeObject, that can be constructed from a Node without a
3454         renderer. Modifies AXObjectCache so that it automatically creates an
3455         AccessibilityNodeObject for elements in a canvas subtree but not otherwise.
3456         A new layout test verifies that this correctly exposes an accessibility
3457         tree with appropriate roles for elements in a canvas subtree.
3458
3459         This patch does not try to complete the implementation of
3460         AccessibilityNodeObject. Most AX methods are still unimplemented and need
3461         to be migrated from AccessibilityRenderObject to AccessibilityNodeObject
3462         in a future patch.
3463         
3464         This patch also doesn't change anything outside of WebCore/accessibility, so
3465         the rest of WebCore only calls AXObjectCache when there are changes to a
3466         RenderObject, not to a Node. Accessible notifications on nodes without
3467         renderers need to be implemented in a future patch.
3468
3469         Test: accessibility/canvas-accessibilitynodeobject.html
3470
3471         * CMakeLists.txt:
3472         * GNUmakefile.list.am:
3473         * Target.pri:
3474         * WebCore.gypi:
3475         * accessibility/AXObjectCache.cpp:
3476         (WebCore::AXObjectCache::get):
3477         (WebCore):
3478         (WebCore::createFromNode):
3479         (WebCore::AXObjectCache::getOrCreate):
3480         (WebCore::AXObjectCache::remove):
3481         * accessibility/AXObjectCache.h:
3482         (AXObjectCache):
3483         (WebCore::AXObjectCache::get):
3484         (WebCore::AXObjectCache::getOrCreate):
3485         (WebCore::AXObjectCache::remove):
3486         * accessibility/AccessibilityARIAGrid.cpp:
3487         (WebCore::AccessibilityARIAGrid::AccessibilityARIAGrid):
3488         (WebCore):
3489         (WebCore::AccessibilityARIAGrid::~AccessibilityARIAGrid):
3490         (WebCore::AccessibilityARIAGrid::init):
3491         (WebCore::AccessibilityARIAGrid::create):
3492         * accessibility/AccessibilityARIAGrid.h:
3493         (AccessibilityARIAGrid):
3494         * accessibility/AccessibilityARIAGridCell.cpp:
3495         (WebCore::AccessibilityARIAGridCell::create):
3496         * accessibility/AccessibilityARIAGridRow.cpp:
3497         (WebCore::AccessibilityARIAGridRow::create):
3498         * accessibility/AccessibilityAllInOne.cpp:
3499         * accessibility/AccessibilityList.cpp:
3500         (WebCore::AccessibilityList::create):
3501         * accessibility/AccessibilityListBox.cpp:
3502         (WebCore::AccessibilityListBox::create):
3503         * accessibility/AccessibilityMediaControls.cpp:
3504         (WebCore::AccessibilityMediaControl::create):
3505         (WebCore::AccessibilityMediaControlsContainer::create):
3506         (WebCore::AccessibilityMediaTimeline::create):
3507         (WebCore::AccessibilityMediaTimeDisplay::create):
3508         * accessibility/AccessibilityMenuList.cpp:
3509         (WebCore::AccessibilityMenuList::create):
3510         (WebCore):
3511         * accessibility/AccessibilityMenuList.h:
3512         (AccessibilityMenuList):
3513         * accessibility/AccessibilityNodeObject.cpp: Added.
3514         (WebCore):
3515         (WebCore::AccessibilityNodeObject::AccessibilityNodeObject):
3516         (WebCore::AccessibilityNodeObject::~AccessibilityNodeObject):
3517         (WebCore::AccessibilityNodeObject::init):
3518         (WebCore::AccessibilityNodeObject::create):
3519         (WebCore::AccessibilityNodeObject::detach):
3520         (WebCore::AccessibilityNodeObject::childrenChanged):
3521         (WebCore::AccessibilityNodeObject::updateAccessibilityRole):
3522         (WebCore::AccessibilityNodeObject::firstChild):
3523         (WebCore::AccessibilityNodeObject::lastChild):
3524         (WebCore::AccessibilityNodeObject::previousSibling):
3525         (WebCore::AccessibilityNodeObject::nextSibling):
3526         (WebCore::AccessibilityNodeObject::parentObjectIfExists):
3527         (WebCore::AccessibilityNodeObject::parentObject):
3528         (WebCore::AccessibilityNodeObject::elementRect):
3529         (WebCore::AccessibilityNodeObject::setNode):
3530         (WebCore::AccessibilityNodeObject::document):
3531         (WebCore::AccessibilityNodeObject::determineAccessibilityRole):
3532         (WebCore::AccessibilityNodeObject::addChildren):
3533         (WebCore::AccessibilityNodeObject::accessibilityIsIgnored):
3534         (WebCore::AccessibilityNodeObject::canSetFocusAttribute):
3535         (WebCore::AccessibilityNodeObject::determineAriaRoleAttribute):
3536         (WebCore::AccessibilityNodeObject::ariaRoleAttribute):
3537         (WebCore::AccessibilityNodeObject::remapAriaRoleDueToParent):
3538         * accessibility/AccessibilityNodeObject.h: Added.
3539         (WebCore):
3540         (AccessibilityNodeObject):
3541         (WebCore::AccessibilityNodeObject::isAccessibilityNodeObject):
3542         (WebCore::AccessibilityNodeObject::node):
3543         (WebCore::AccessibilityNodeObject::isDetached):
3544         (WebCore::toAccessibilityNodeObject):
3545         * accessibility/AccessibilityObject.h:
3546         (WebCore::AccessibilityObject::isAccessibilityNodeObject):
3547         * accessibility/AccessibilityProgressIndicator.cpp:
3548         (WebCore::AccessibilityProgressIndicator::create):
3549         * accessibility/AccessibilityRenderObject.cpp:
3550         (WebCore::AccessibilityRenderObject::AccessibilityRenderObject):
3551         (WebCore::AccessibilityRenderObject::init):
3552         (WebCore):
3553         (WebCore::AccessibilityRenderObject::create):
3554         (WebCore::AccessibilityRenderObject::detach):
3555         (WebCore::AccessibilityRenderObject::setRenderer):
3556         (WebCore::AccessibilityRenderObject::canHaveChildren):
3557         (WebCore::AccessibilityRenderObject::addCanvasChildren):
3558         (WebCore::AccessibilityRenderObject::addChildren):
3559         * accessibility/AccessibilityRenderObject.h:
3560         (AccessibilityRenderObject):
3561         * accessibility/AccessibilitySlider.cpp:
3562         (WebCore::AccessibilitySlider::create):
3563         * accessibility/AccessibilityTable.cpp:
3564         (WebCore::AccessibilityTable::AccessibilityTable):
3565         (WebCore):
3566         (WebCore::AccessibilityTable::~AccessibilityTable):
3567         (WebCore::AccessibilityTable::init):
3568         (WebCore::AccessibilityTable::create):
3569         * accessibility/AccessibilityTable.h:
3570         (AccessibilityTable):
3571         * accessibility/AccessibilityTableCell.cpp:
3572         (WebCore::AccessibilityTableCell::create):
3573         * accessibility/AccessibilityTableRow.cpp:
3574         (WebCore::AccessibilityTableRow::create):
3575
3576 2012-07-23  David Barr  <davidbarr@chromium.org>
3577
3578         Fix ENABLE_CSS_IMAGE_ORIENTATION compile flag
3579         https://bugs.webkit.org/show_bug.cgi?id=91961
3580
3581         Reviewed by Tony Chang.
3582
3583         https://bugs.webkit.org/show_bug.cgi?id=89055
3584         A rule was missed implementing the ENABLE_CSS_IMAGE_ORIENTATION compile flag.
3585
3586         https://bugs.webkit.org/show_bug.cgi?id=90046
3587         Half of the missing rule was inadvertently added together with ENABLE_CSS_STICKY_POSITION.
3588
3589         No new tests; build configuration fix.
3590
3591         * Configurations/FeatureDefines.xcconfig:
3592
3593 2012-07-23  Douglas Stockwell  <dstockwell@chromium.org>
3594
3595         Null-pointer crash when a derived color like -webkit-activelink is set in a gradient stop
3596         https://bugs.webkit.org/show_bug.cgi?id=89148
3597
3598         Reviewed by Simon Fraser.
3599
3600         CSSGradientValue attempted to resolve colors during paint, this crashed
3601         when a derived color like -webkit-activelink was encountered because the
3602         corresponding element was no longer available in the StyleResolver.
3603         Instead, by adding a field to CSSGradientColorStop we can resolve and
3604         then cache the resolved colors at the correct time. To avoid sharing
3605         cached derived colors between elements we clone the gradient values when
3606         needed.
3607
3608         Test: fast/css/crash-on-gradient-with-derived-color.html
3609
3610         * css/CSSGradientValue.cpp:
3611         (WebCore::CSSGradientValue::gradientWithStylesResolved): Added. Resolve and cache
3612         resolved colors, clone if colors are derived from the element.
3613         (WebCore):
3614         (WebCore::CSSGradientValue::addStops):
3615         (WebCore::CSSGradientValue::isCacheable): Defer to new logic in
3616         StyleResolver.
3617         * css/CSSGradientValue.h:
3618         (CSSGradientColorStop): Added cache of resolved color.
3619         (CSSGradientValue):
3620         (CSSLinearGradientValue):
3621         (CSSRadialGradientValue):
3622         * css/CSSImageGeneratorValue.h:
3623         (WebCore):
3624         * css/CSSValue.h:
3625         (WebCore::CSSValue::isGradientValue):
3626         * css/StyleResolver.cpp:
3627         (WebCore::StyleResolver::collectMatchingRulesForList):
3628         * css/StyleResolver.h:
3629         (StyleResolver):
3630         * rendering/style/StyleGeneratedImage.cpp:
3631         (WebCore::StyleGeneratedImage::image): Revert change from r96449. This
3632         is no longer necessary as the gradient colors are now resolved at a
3633         time when the style is set on StyleResolver.
3634
3635 2012-07-23  Patrick Gansterer  <paroga@webkit.org>
3636
3637         Move GregorianDateTime from JSC to WTF namespace
3638         https://bugs.webkit.org/show_bug.cgi?id=91948
3639
3640         Reviewed by Geoffrey Garen.
3641
3642         Moving GregorianDateTime into the WTF namespace allows us to us to
3643         use it in WebCore too. The new class has the same behaviour as the
3644         old struct. Only the unused timeZone member has been removed.
3645
3646         * bridge/qt/qt_runtime.cpp:
3647         (JSC::Bindings::convertValueToQVariant):
3648         (JSC::Bindings::convertQVariantToValue):
3649         * bridge/qt/qt_runtime_qt4.cpp:
3650         (JSC::Bindings::convertValueToQVariant):
3651         (JSC::Bindings::convertQVariantToValue):
3652
3653 2012-07-23  Mark Pilgrim  <pilgrim@chromium.org>
3654
3655         [Chromium] Move layoutTestMode to WebCore
3656         https://bugs.webkit.org/show_bug.cgi?id=92010
3657
3658         Reviewed by Adam Barth.
3659
3660         Part of a refactoring series. See tracking bug 82948.
3661
3662         * CMakeLists.txt:
3663         * GNUmakefile.list.am:
3664         * Target.pri:
3665         * WebCore.gypi:
3666         * WebCore.vcproj/WebCore.vcproj:
3667         * WebCore.xcodeproj/project.pbxproj:
3668         * bindings/generic/RuntimeEnabledFeatures.h:
3669         (RuntimeEnabledFeatures):
3670         * platform/LayoutTestSupport.cpp: Added.
3671         (WebCore):
3672         (WebCore::isRunningLayoutTest):
3673         (WebCore::setIsRunningLayoutTest):
3674         * platform/LayoutTestSupport.h: Added.
3675         (WebCore):
3676         * platform/chromium/PlatformSupport.h:
3677         (PlatformSupport):
3678         * platform/chromium/ScrollbarThemeChromiumAndroid.cpp:
3679         (WebCore::ScrollbarThemeChromiumAndroid::scrollbarThickness):
3680         (WebCore::ScrollbarThemeChromiumAndroid::paintScrollbarBackground):
3681         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
3682         (WebCore::ScrollbarThemeChromiumWin::scrollbarThickness):
3683         (WebCore::ScrollbarThemeChromiumWin::buttonSize):
3684         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
3685         (WebCore):
3686         (WebCore::LookupAltName):
3687         (WebCore::fontContainsCharacter):
3688         (WebCore::FillLogFont):
3689         (WebCore::FontCache::getFontDataForCharacters):
3690         (WebCore::FontCache::createFontPlatformData):
3691         * platform/graphics/skia/FontCustomPlatformData.cpp:
3692         (WebCore::FontCustomPlatformData::fontPlatformData):
3693         * platform/graphics/skia/FontSkia.cpp:
3694         (WebCore::Font::drawGlyphs):
3695         * rendering/RenderThemeChromiumAndroid.cpp:
3696         (WebCore::RenderThemeChromiumAndroid::systemColor):
3697         (WebCore::RenderThemeChromiumAndroid::adjustInnerSpinButtonStyle):
3698         * rendering/RenderThemeChromiumMac.mm:
3699         (WebCore::RenderThemeChromiumMac::usesTestModeFocusRingColor):
3700         * rendering/RenderThemeChromiumSkia.cpp:
3701         (WebCore::RenderThemeChromiumSkia::caretBlinkInterval):
3702         * rendering/RenderThemeChromiumWin.cpp:
3703         (WebCore):
3704         (WebCore::RenderThemeChromiumWin::platformActiveSelectionBackgroundColor):
3705         (WebCore::RenderThemeChromiumWin::platformInactiveSelectionBackgroundColor):
3706         (WebCore::RenderThemeChromiumWin::platformActiveSelectionForegroundColor):
3707         (WebCore::RenderThemeChromiumWin::systemColor):
3708         (WebCore::menuListButtonWidth):
3709         (WebCore::RenderThemeChromiumWin::determineClassicState):
3710
3711 2012-07-23  Dave Tu  <dtu@chromium.org>
3712
3713         [chromium] Add droppedFrameCount to renderingStats.
3714         https://bugs.webkit.org/show_bug.cgi?id=91694
3715
3716         Reviewed by Adrienne Walker.
3717
3718         * platform/graphics/chromium/cc/CCFrameRateCounter.cpp:
3719         (WebCore):
3720         (WebCore::CCFrameRateCounter::frameInterval):
3721         (WebCore::CCFrameRateCounter::frameIndex):
3722         (WebCore::CCFrameRateCounter::CCFrameRateCounter):
3723         (WebCore::CCFrameRateCounter::markBeginningOfFrame):
3724         (WebCore::CCFrameRateCounter::isBadFrame):
3725         * platform/graphics/chromium/cc/CCFrameRateCounter.h:
3726         (WebCore::CCFrameRateCounter::droppedFrameCount):
3727         (CCFrameRateCounter):
3728         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3729         (WebCore::CCLayerTreeHost::renderingStats):
3730         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3731         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
3732         (WebCore::CCLayerTreeHostImpl::drawLayers):
3733         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3734         (CCLayerTreeHostImpl):
3735         * platform/graphics/chromium/cc/CCRenderingStats.h:
3736         (CCRenderingStats):
3737         (WebCore::CCRenderingStats::CCRenderingStats):
3738         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
3739         (WebCore::CCSingleThreadProxy::implSideRenderingStats):
3740         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
3741         (WebCore::CCThreadProxy::implSideRenderingStatsOnImplThread):
3742
3743 2012-07-23  Dan Bernstein  <mitz@apple.com>
3744
3745         Fixed the build after r123418.
3746
3747         * WebCore.exp.in: Added DocumentMarkerController::addTextMatchMarker.
3748
3749 2012-07-23  Mike Lawther  <mikelawther@chromium.org>
3750
3751         CSS3 calc: optimise blending expression
3752         https://bugs.webkit.org/show_bug.cgi?id=90037
3753
3754         Reviewed by Tony Chang.
3755
3756         Introduce a new calc expression node - a BlendLength node. Given two Lengths and a progress
3757         this blends them together when evaluated.
3758
3759         An alternative and more general approach of being able to blend two CalcExpressionNodes was
3760         tested, but involves more memory allocations, was measurably slower, and nothing currently
3761         would make use of the generality. 
3762
3763         No functional change. Covered by existing tests.
3764
3765         * platform/CalculationValue.h:
3766         (CalcExpressionBlendLength):
3767         (WebCore::CalcExpressionBlendLength::CalcExpressionBlendLength):
3768         (WebCore::CalcExpressionBlendLength::operator==):
3769         (WebCore::CalcExpressionBlendLength::evaluate):
3770         (WebCore):
3771         * platform/Length.cpp:
3772         (WebCore::Length::blendCalculation):
3773
3774 2012-07-23  Nico Weber  <thakis@chromium.org>
3775
3776         [chromium] Show search tickmarks on css-styled scrollbars
3777         https://bugs.webkit.org/show_bug.cgi?id=91949
3778
3779         Reviewed by Adrienne Walker.
3780
3781         This is done by letting RenderScrollbarTheme::paintTickmarks()
3782         delegate to the native ScrollbarTheme. To make this possible,
3783         move paintTickmarks() from ScrollbarThemeComposite to the
3784         superclass ScrollbarTheme.
3785
3786         For testing, add internals.addTextMatchMarker() and add a pixel test.
3787
3788         * platform/ScrollbarTheme.h:
3789         (WebCore::ScrollbarTheme::paintTickmarks):
3790         Moved paintTickmarks() from ScrollbarThemeComposite to here.
3791         * platform/ScrollbarThemeComposite.h:
3792         Remove paintTickmarks().
3793         * platform/chromium/ScrollbarThemeChromium.cpp:
3794         (WebCore::ScrollbarThemeChromium::paintTickmarks):
3795         Switch to drawing tickmarks as vectors, so they can be arbitrarily wide.
3796         * platform/chromium/ScrollbarThemeChromiumMac.h:
3797         (ScrollbarThemeChromiumMac):
3798         Implement paintTickmarks(), so that css-styled scrollbars get tickmarks on mac.
3799         * platform/chromium/ScrollbarThemeChromiumMac.mm:
3800         (WebCore::ScrollbarThemeChromiumMac::paint):
3801         (WebCore::ScrollbarThemeChromiumMac::paintTickmarks):
3802         Implement paintTickmarks(), so that css-styled scrollbars get tickmarks on mac.
3803         * rendering/RenderScrollbarTheme.cpp:
3804         (WebCore::RenderScrollbarTheme::paintTickmarks):
3805         Delegate to the native ScrollbarTheme for tickmark drawing.
3806         (WebCore):
3807         * rendering/RenderScrollbarTheme.h:
3808         (RenderScrollbarTheme):
3809         Override paintTickmarks().
3810
3811 2012-07-23  Brian Anderson  <brianderson@chromium.org>
3812
3813         [chromium] Use shallow flushes that don't glFlush
3814         https://bugs.webkit.org/show_bug.cgi?id=90325
3815
3816         Reviewed by Kenneth Russell.
3817
3818         Adds plumbing for the shallowFlushCHROMIUM extension and uses
3819         shallow flushes instead of normal flushes when uploading textures.
3820         Shallow flushes allow us to initiate command buffer flushes to
3821         the GPU thread/process without the overhead of a true glFlush.
3822
3823         CCTextureUpdaterTest updated to recognize shallow flushes.
3824
3825         * platform/chromium/support/Extensions3DChromium.cpp:
3826         (WebCore::Extensions3DChromium::shallowFlushCHROMIUM):
3827         (WebCore):
3828         * platform/graphics/chromium/Extensions3DChromium.h:
3829         (Extensions3DChromium):
3830         * platform/graphics/chromium/cc/CCGraphicsContext.h:
3831         * platform/graphics/chromium/cc/CCResourceProvider.cpp:
3832         (WebCore::CCResourceProvider::shallowFlushIfSupported):
3833         (WebCore):
3834         (WebCore::CCResourceProvider::CCResourceProvider):
3835         (WebCore::CCResourceProvider::initialize):
3836         * platform/graphics/chromium/cc/CCResourceProvider.h:
3837         (CCResourceProvider):
3838         * platform/graphics/chromium/cc/CCTextureUpdater.cpp:
3839         (WebCore::CCTextureUpdater::update):
3840
3841 2012-07-23  Hanyee Kim  <choco@company100.net>
3842
3843         When using TextureMapper, WebKit does not retain final value of opacity in animations, unless it is specified on the last key frame.
3844         https://bugs.webkit.org/show_bug.cgi?id=91322
3845
3846         Reviewed by Noam Rosenthal.
3847
3848         When -webkit-fill-mode is forwards, GraphicsLayerAnimation::apply does not apply
3849         the property values defined in the last executing keyframe after the final iteration of animation.
3850
3851         This patch does not return right after the end of animation, but it keeps applying
3852         the property values defined in the last executing keyframe.
3853         Add normalizedAnimationValueForFillsForwards function that returns a normalized value of the
3854         last executing keyframe.
3855
3856         Link to CSS Animations spec: http://www.w3.org/TR/css3-animations/#animation-fill-mode-property
3857
3858         Test: animations/fill-mode-forwards2.html
3859
3860         * platform/graphics/GraphicsLayerAnimation.cpp:
3861         (WebCore::normalizedAnimationValueForFillsForwards):
3862         (WebCore):
3863         (WebCore::GraphicsLayerAnimation::apply):
3864
3865 2012-07-23  Sheriff Bot  <webkit.review.bot@gmail.com>
3866
3867         Unreviewed, rolling out r123184, r123195, and r123197.
3868         http://trac.webkit.org/changeset/123184
3869         http://trac.webkit.org/changeset/123195
3870         http://trac.webkit.org/changeset/123197
3871         https://bugs.webkit.org/show_bug.cgi?id=92049
3872
3873         pagecycler regression (Requested by morrita on #webkit).
3874
3875         * WebCore.exp.in:
3876         * dom/Document.cpp:
3877         (WebCore::Document::Document):
3878         (WebCore::Document::~Document):
3879         (WebCore::Document::suggestedMIMEType):
3880         * dom/Document.h:
3881         (WebCore):
3882         (WebCore::Node::isDocumentNode):
3883         (WebCore::Node::Node):
3884         * dom/Node.cpp:
3885         (WebCore::Node::~Node):
3886         (WebCore::Node::setDocument):
3887         (WebCore):
3888         (WebCore::Node::setTreeScope):
3889         (WebCore::Node::treeScope):
3890         (WebCore::Node::isInShadowTree):
3891         (WebCore::Node::reportMemoryUsage):
3892         * dom/Node.h:
3893         (Node):
3894         (WebCore::Node::document):
3895         (WebCore::Node::inDocument):
3896         * dom/NodeRareData.h:
3897         (WebCore::NodeRareData::NodeRareData):
3898         (WebCore::NodeRareData::treeScope):
3899         (WebCore::NodeRareData::setTreeScope):
3900         (NodeRareData):
3901         * dom/ShadowRoot.cpp:
3902         (WebCore::ShadowRoot::ShadowRoot):
3903         * dom/TreeScope.cpp:
3904         (WebCore::TreeScope::TreeScope):
3905         (WebCore::TreeScope::setParentTreeScope):
3906         * dom/TreeScope.h:
3907         (WebCore):
3908         (WebCore::TreeScope::idTargetObserverRegistry):
3909         (TreeScope):
3910         * dom/TreeScopeAdopter.cpp:
3911         (WebCore::TreeScopeAdopter::moveTreeToNewScope):
3912         (WebCore::TreeScopeAdopter::moveNodeToNewDocument):
3913         * editing/MoveSelectionCommand.cpp:
3914         * editing/RemoveNodeCommand.cpp:
3915         * editing/RemoveNodePreservingChildrenCommand.cpp:
3916         * inspector/PageConsoleAgent.cpp:
3917
3918 2012-07-23  Roger Fong  <roger_fong@apple.com>
3919
3920         On Windows, if select element is off screen horizontally, 
3921         menu is either inappropriately resized or positioned offscreen.
3922         https://bugs.webkit.org/show_bug.cgi?id=91913
3923         <rdar://problem/7611229>
3924
3925         Reviewed by Tim Horton.
3926
3927         If the select element is positioned off the edge of the screen to the left, 
3928         the menu is resized. It should not be resized, just shifted to remain on the screen.
3929         If the select element is positioned off the edge of the screen to the right, 
3930         the menu goes off screen instead of being shifted over to appear on screen.
3931         This problem only occurs on Windows.
3932         
3933         Test: ManualTests/win/select-menu-off-screen.html
3934
3935         * platform/win/PopupMenuWin.cpp:
3936         (WebCore::PopupMenuWin::calculatePositionAndSize):
3937         Modified final horizontal position calculation code to position
3938         popup menu on screen if it would otherwise go off.
3939         
3940 2012-07-23  David Dorwin  <ddorwin@chromium.org>
3941
3942         Fixed crash in webkitAddKey() when key parameter is null.
3943         https://bugs.webkit.org/show_bug.cgi?id=85444
3944
3945         Reviewed by Kentaro Hara.
3946
3947         Reference: Step 1 of http://dvcs.w3.org/hg/html-media/raw-file/5f76a0b43836/encrypted-media/encrypted-media.html#dom-addkey
3948
3949         Tests: media/encrypted-media/encrypted-media-syntax.html 
3950
3951         * html/HTMLMediaElement.cpp:
3952         (WebCore::HTMLMediaElement::webkitAddKey):
3953
3954 2012-07-23  Hayato Ito  <hayato@chromium.org>
3955
3956         A FocusScope for a distributed node should not be its TreeScope.
3957         https://bugs.webkit.org/show_bug.cgi?id=91829
3958
3959         Reviewed by Dimitri Glazkov.
3960
3961         Current implementation of FocusScope::focusScopeOf(Node*) returns
3962         the given node's treeScope().  That does not apply if the node is
3963         a distributed node.  We should calculate a FocusScope for a
3964         distributed node by traversing ancestor nodes in Composed Shadow
3965         Tree.
3966
3967         Test: fast/dom/shadow/focus-navigation-with-distributed-nodes.html
3968
3969         * page/FocusController.cpp:
3970         (WebCore::FocusScope::focusScopeOf):
3971
3972 2012-07-23  Douglas Stockwell  <dstockwell@google.com>
3973
3974         Null-pointer crash when parsing border-image
3975         https://bugs.webkit.org/show_bug.cgi?id=91963
3976
3977         Reviewed by Darin Adler.
3978
3979         Test: fast/css/border-image-fill-crash.html
3980
3981         * css/CSSParser.cpp:
3982         (WebCore::CSSParser::parseBorderImageRepeat): Handle the case where
3983         parseBorderImageRepeat is called when the value list is empty.
3984
3985 2012-07-23  Bem Jones-Bey  <bjonesbe@adobe.com>
3986
3987         [CSS Exclusions] SVG shape errors should invalidate exclusion shapes
3988         https://bugs.webkit.org/show_bug.cgi?id=91761
3989
3990         Reviewed by Andreas Kling.
3991
3992         CSS exclusion shapes that are specified with negative radiuses or
3993         height/width are now considered invalid and ignored.
3994
3995         Tests added to
3996         LayoutTests/fast/exclusions/parsing-wrap-shape-lengths.html
3997
3998         * css/CSSParser.cpp:
3999         (WebCore::CSSParser::parseExclusionShapeRectangle):
4000         (WebCore::CSSParser::parseExclusionShapeCircle):
4001         (WebCore::CSSParser::parseExclusionShapeEllipse):
4002
4003 2012-07-23  Tien-Ren Chen  <trchen@chromium.org>
4004
4005         [chromium] Implement scrollbar theme for Android
4006         https://bugs.webkit.org/show_bug.cgi?id=91674
4007
4008         Reviewed by Adam Barth.
4009
4010         Previously the scrollbar for Android was implemented as an extra
4011         drawing pass in the compositor. Now we switch to use the standard
4012         ScrollbarTheme mechanism.
4013
4014         No new tests. We use mock scrollbars during layout test to share
4015         pixel results with Linux.
4016
4017         * platform/chromium/ScrollbarThemeChromiumAndroid.cpp:
4018         (WebCore::ScrollbarThemeChromiumAndroid::scrollbarThickness):
4019         (WebCore::ScrollbarThemeChromiumAndroid::thumbPosition):
4020         (WebCore::ScrollbarThemeChromiumAndroid::thumbLength):
4021         (WebCore::ScrollbarThemeChromiumAndroid::backButtonRect):
4022         (WebCore::ScrollbarThemeChromiumAndroid::forwardButtonRect):
4023         (WebCore::ScrollbarThemeChromiumAndroid::trackRect):
4024         (WebCore):
4025         (WebCore::ScrollbarThemeChromiumAndroid::paintThumb):
4026         (WebCore::ScrollbarThemeChromiumAndroid::paintScrollbarBackground):