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