e3e6f1b7e35064fc5d354f524b8e1359ffa271da
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-03-26  Anton Muhin  <antonm@chromium.org>
2
3         Fix a typo in IDL
4         https://bugs.webkit.org/show_bug.cgi?id=82215
5
6         Reviewed by Adam Barth.
7
8         No new tests, just a typo fix.
9
10         * notifications/WorkerContextNotifications.idl:
11
12 2012-03-26  W. James MacLean  <wjmaclean@chromium.org>
13
14         [chromium] Change handleGestureFling() to use CCInputHandlerClient::Wheel.
15         https://bugs.webkit.org/show_bug.cgi?id=82133
16
17         Reviewed by James Robinson.
18
19         Covered by existing unit tests.
20
21         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
22         (WebCore::CCLayerTreeHostImpl::scrollBegin):
23
24 2012-03-26  Mike Lawther  <mikelawther@chromium.org>
25
26         CSS3 calc: mixed percent/absolute for box-reflect
27         https://bugs.webkit.org/show_bug.cgi?id=82161
28
29         Reviewed by Ojan Vafai.
30
31         Tests: css3/calc/box-reflect-expected.html
32                css3/calc/box-reflect.html
33
34         * css/CSSStyleSelector.cpp:
35         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
36
37 2012-03-26  Mike Lawther  <mikelawther@chromium.org>
38
39         CSS3 calc: mixed percent/absolute support for vertical-align
40         https://bugs.webkit.org/show_bug.cgi?id=82152
41
42         Reviewed by Ojan Vafai.
43
44         Tests: css3/calc/vertical-align-expected.html
45                css3/calc/vertical-align.html
46
47         * css/CSSStyleApplyProperty.cpp:
48         (WebCore::ApplyPropertyVerticalAlign::applyValue):
49
50 2012-03-26  Filip Spacek  <fspacek@rim.com>
51
52         [BlackBerry] Accelerated compositing updates
53         https://bugs.webkit.org/show_bug.cgi?id=82058
54
55         Reviewed by Rob Buis.
56
57         * platform/graphics/blackberry/CanvasLayerWebKitThread.cpp:
58         (WebCore::CanvasLayerWebKitThread::CanvasLayerWebKitThread):
59         (WebCore::CanvasLayerWebKitThread::~CanvasLayerWebKitThread):
60         (WebCore::CanvasLayerWebKitThread::setDevice):
61         (WebCore::CanvasLayerWebKitThread::updateTextureContentsIfNeeded):
62         * platform/graphics/blackberry/CanvasLayerWebKitThread.h:
63         (WebCore::CanvasLayerWebKitThread::create):
64         (CanvasLayerWebKitThread):
65         * platform/graphics/blackberry/InstrumentedPlatformCanvas.h:
66         (WebCore::InstrumentedPlatformCanvas::InstrumentedPlatformCanvas):
67         (WebCore::InstrumentedPlatformCanvas::save):
68         (WebCore::InstrumentedPlatformCanvas::saveLayer):
69         (WebCore::InstrumentedPlatformCanvas::restore):
70         (WebCore::InstrumentedPlatformCanvas::translate):
71         (WebCore::InstrumentedPlatformCanvas::scale):
72         (WebCore::InstrumentedPlatformCanvas::rotate):
73         (WebCore::InstrumentedPlatformCanvas::skew):
74         (WebCore::InstrumentedPlatformCanvas::concat):
75         (WebCore::InstrumentedPlatformCanvas::setMatrix):
76         (WebCore::InstrumentedPlatformCanvas::clipRect):
77         (WebCore::InstrumentedPlatformCanvas::clipPath):
78         (WebCore::InstrumentedPlatformCanvas::clipRegion):
79         (WebCore::InstrumentedPlatformCanvas::clear):
80         (WebCore::InstrumentedPlatformCanvas::drawPaint):
81         (WebCore::InstrumentedPlatformCanvas::drawPoints):
82         (WebCore::InstrumentedPlatformCanvas::drawRect):
83         (WebCore::InstrumentedPlatformCanvas::drawPath):
84         (WebCore::InstrumentedPlatformCanvas::drawBitmap):
85         (WebCore::InstrumentedPlatformCanvas::drawBitmapRect):
86         (WebCore::InstrumentedPlatformCanvas::drawBitmapMatrix):
87         (WebCore::InstrumentedPlatformCanvas::drawSprite):
88         (WebCore::InstrumentedPlatformCanvas::drawText):
89         (WebCore::InstrumentedPlatformCanvas::drawPosText):
90         (WebCore::InstrumentedPlatformCanvas::drawPosTextH):
91         (WebCore::InstrumentedPlatformCanvas::drawTextOnPath):
92         (WebCore::InstrumentedPlatformCanvas::drawPicture):
93         (WebCore::InstrumentedPlatformCanvas::drawVertices):
94         (WebCore::InstrumentedPlatformCanvas::drawData):
95         * platform/graphics/blackberry/LayerData.h:
96         (WebCore::LayerData::LayerData):
97         (WebCore::LayerData::needsTexture):
98         (LayerData):
99         * platform/graphics/blackberry/LayerTiler.cpp:
100         (WebCore::LayerTiler::updateTextureContentsIfNeeded):
101         * platform/graphics/blackberry/LayerWebKitThread.cpp:
102         (WebCore::LayerWebKitThread::paintContents):
103         (WebCore::LayerWebKitThread::setDrawable):
104         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
105         (WebCore::loadBufferingImageData):
106         * platform/graphics/blackberry/skia/ImageBufferDataSkia.h: Renamed from Source/WebCore/platform/graphics/blackberry/skia/ImageBufferData.h.
107         (WebCore):
108         (ImageBufferData):
109
110 2012-03-26  Stephen Chenney  <schenney@chromium.org>
111
112         Failure to invalidate text position attributes when DOM changes
113         https://bugs.webkit.org/show_bug.cgi?id=81464
114
115         Reviewed by Nikolas Zimmermann.
116
117         The text positioning elements data structure in RenderSVGText must be
118         updated when either the children of the corresponding element are
119         modified, or the length of the text inside the elements changes.
120         Previously, the call to clear the text positioning elements (to force
121         recomputation) was guarded by a flag. If code tried to invalidate when
122         the flag was not set, then something set the flag, the elements would
123         be invalid at use time.
124
125         This patch modifies the method that invalidates the positining
126         attributes so that the action always happens. It also renames the
127         method to more accurately reflect its function.
128
129         Test: svg/custom/delete-modified-text-in-defs-crash.svg
130
131         * rendering/svg/RenderSVGInlineText.cpp:
132         (WebCore::RenderSVGInlineText::setTextInternal): Rename textDOMChanged to invalidateTextPositioningElements
133         * rendering/svg/RenderSVGText.cpp:
134         (WebCore::RenderSVGText::invalidateTextPositioningElements): Rename
135         textDOMChanged to invalidateTextPositioningElements and remove the check against the needsPosition... flag.
136         * rendering/svg/RenderSVGText.h:
137         (RenderSVGText): Rename textDOMChanged to invalidateTextPositioningElements
138         * svg/SVGAElement.cpp:
139         (WebCore::SVGAElement::childrenChanged): Rename textDOMChanged to invalidateTextPositioningElements
140         * svg/SVGTextContentElement.cpp:
141         (WebCore::SVGTextContentElement::childrenChanged): Rename textDOMChanged to invalidateTextPositioningElements
142
143 2012-03-26  Julien Chaffraix  <jchaffraix@webkit.org>
144
145         REGRESSION (r110065-r110080): fast/forms/placeholder-set-attribute.html is failing intermittently because WebKit fails to repaint after setting the placeholder attribute
146         https://bugs.webkit.org/show_bug.cgi?id=81802
147
148         Reviewed by Dan Bernstein.
149
150         Covered by fast/forms/placeholder-set-attribute.html which should be less flaky.
151
152         Unfortunately no new test case as this bug requires a very specific set of conditions that I couldn't reproduce deterministically.
153
154         This is a regression from r110072: RenderTextControlSingleLine would rely on the placeholder's RenderLayer to properly repaint during
155         the first layout as the placeholder has overflow: hidden set. r110072 removed the layer in this case and thus we miss a repaint.
156
157         * rendering/RenderTextControlSingleLine.cpp:
158         (WebCore::RenderTextControlSingleLine::layout):
159         For our first layout, we need to make sure our placeholder is painted. layoutBlockChild has a very similar logic to force repaint
160         on a first layout. We don't hit this logic as the placeholder is explicitly skipped in RenderTextControl::layoutSpecialExcludedChild.
161
162 2012-03-26  Julien Chaffraix  <jchaffraix@webkit.org>
163
164         REGRESSION(r110072): fast/forms/textfield-overflow.html is failing
165         https://bugs.webkit.org/show_bug.cgi?id=80531
166
167         Reviewed by Ojan Vafai.
168
169         Tested by fast/forms/textfield-overflow.html (re-enabled after this change).
170
171         The existing code would happily query layout information before calling layout (FTW!).
172         The solution is to properly layout our object, then modify some dimensions as needed while
173         marking ourself as needing layout and then layouting again.
174
175         * rendering/RenderTextControlSingleLine.cpp:
176         (WebCore::RenderTextControlSingleLine::layout):
177         Implemented a proper 2 pass layout algorithm. Removed the |relayoutChildren| logic as:
178         - layoutBlock handles automatically logical height changes.
179         - we were not modifying the logical width between layouts so we don't need to force a
180         child relayout in this case.
181
182 2012-03-26  Robin Cao  <robin.cao@torchmobile.com.cn>
183
184         [BlackBerry] Upstream LayerCompositingThread.{h, cpp}
185         https://bugs.webkit.org/show_bug.cgi?id=79873
186
187         Reviewed by Rob Buis.
188
189         Initial upstream, no new tests.
190
191         * platform/graphics/blackberry/LayerCompositingThread.cpp: Added.
192         (WebCore):
193         (WebCore::LayerCompositingThread::create):
194         (WebCore::LayerCompositingThread::LayerCompositingThread):
195         (WebCore::LayerCompositingThread::~LayerCompositingThread):
196         (WebCore::LayerCompositingThread::destroyOnCompositingThread):
197         (WebCore::LayerCompositingThread::setLayerRenderer):
198         (WebCore::LayerCompositingThread::deleteTextures):
199         (WebCore::LayerCompositingThread::setDrawTransform):
200         (WebCore::getTransformedRect):
201         (WebCore::LayerCompositingThread::getTransformedHolePunchRect):
202         (WebCore::LayerCompositingThread::drawTextures):
203         (WebCore::LayerCompositingThread::drawSurface):
204         (WebCore::LayerCompositingThread::drawMissingTextures):
205         (WebCore::LayerCompositingThread::releaseTextureResources):
206         (WebCore::LayerCompositingThread::setPluginView):
207         (WebCore::LayerCompositingThread::setMediaPlayer):
208         (WebCore::LayerCompositingThread::clearAnimations):
209         (WebCore::LayerCompositingThread::removeSublayer):
210         (WebCore::LayerCompositingThread::indexOfSublayer):
211         (WebCore::LayerCompositingThread::rootLayer):
212         (WebCore::LayerCompositingThread::removeFromSuperlayer):
213         (WebCore::LayerCompositingThread::setSublayers):
214         (WebCore::LayerCompositingThread::updateTextureContentsIfNeeded):
215         (WebCore::LayerCompositingThread::setVisible):
216         (WebCore::LayerCompositingThread::setNeedsCommit):
217         (WebCore::LayerCompositingThread::scheduleCommit):
218         (WebCore::LayerCompositingThread::updateAnimations):
219         (WebCore::LayerCompositingThread::hasVisibleHolePunchRect):
220         (WebCore::LayerCompositingThread::createLayerRendererSurface):
221         * platform/graphics/blackberry/LayerCompositingThread.h: Added.
222         (Graphics):
223         (WebCore):
224         (LayerCompositingThread):
225         (WebCore::LayerCompositingThread::bindContentsTexture):
226         (WebCore::LayerCompositingThread::getSublayers):
227         (WebCore::LayerCompositingThread::setSuperlayer):
228         (WebCore::LayerCompositingThread::superlayer):
229         (WebCore::LayerCompositingThread::drawTransform):
230         (WebCore::LayerCompositingThread::setDrawOpacity):
231         (WebCore::LayerCompositingThread::drawOpacity):
232         (WebCore::LayerCompositingThread::layerRendererSurface):
233         (WebCore::LayerCompositingThread::clearLayerRendererSurface):
234         (WebCore::LayerCompositingThread::setMaskLayer):
235         (WebCore::LayerCompositingThread::maskLayer):
236         (WebCore::LayerCompositingThread::setReplicaLayer):
237         (WebCore::LayerCompositingThread::replicaLayer):
238         (WebCore::LayerCompositingThread::getDrawRect):
239         (WebCore::LayerCompositingThread::getTransformedBounds):
240         (WebCore::LayerCompositingThread::hasMissingTextures):
241         (WebCore::LayerCompositingThread::isDirty):
242         (WebCore::LayerCompositingThread::isVisible):
243         (WebCore::LayerCompositingThread::setOpacity):
244         (WebCore::LayerCompositingThread::setTransform):
245         (WebCore::LayerCompositingThread::hasRunningAnimations):
246         (WebCore::LayerCompositingThread::numSublayers):
247
248 2012-03-26  Kent Tamura  <tkent@chromium.org>
249
250         Add a notification function for detaching to TextFieldDecorator
251         https://bugs.webkit.org/show_bug.cgi?id=82142
252
253         Reviewed by Dimitri Glazkov.
254
255         Add willDetach() functio to TextFieldDecorator. This will be
256         needed if a decorator opens a popup UI on handleClick(), and the
257         popup UI should be closed when the attaching text field is
258         detached.
259
260         No new tests because of no behavior changes in any platforms.
261
262         * html/shadow/TextFieldDecorationElement.cpp:
263         (WebCore::TextFieldDecorationElement::hostInput):
264         Added. A utilify function to get an HTMLInputElement*.
265         (WebCore::TextFieldDecorationElement::updateImage): Use hostInput().
266         (WebCore::TextFieldDecorationElement::customStyleForRenderer): ditto.
267         (WebCore::TextFieldDecorationElement::detach): Added. Calls TextFieldDecorator::willDetach().
268         (WebCore::TextFieldDecorationElement::defaultEventHandler): Use hostInput().
269         * html/shadow/TextFieldDecorationElement.h:
270         (TextFieldDecorator):
271         (TextFieldDecorationElement):
272
273 2012-03-26  Dan Bernstein  <mitz@apple.com>
274
275         Tried to fix the 32-bit build after r112021.
276
277         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
278         (-[WebAccessibilityObjectWrapper _convertToNSRange:]):
279
280 2012-03-26  Leo Yang  <leo.yang@torchmobile.com.cn>
281
282         [BlackBerry] Skeleton code of AsyncFileSystemBlackBerry.cpp
283         https://bugs.webkit.org/show_bug.cgi?id=82157
284
285         Reviewed by Rob Buis.
286
287         AsyncFileSystemBlackBerry is responsible for asynchronous operating
288         on file system for the blackberry porting. It's just skeleton code
289         containing no implementation yet.
290
291         No new tests because of skeleton code.
292
293         * PlatformBlackBerry.cmake: Add AsyncFileSystemBlackBerry.cpp if ENABLE_FILE_SYSTEM is on.
294         * platform/AsyncFileSystem.cpp:
295         (WebCore):
296         * platform/blackberry/AsyncFileSystemBlackBerry.cpp: Added.
297         (WebCore):
298         (WebCore::AsyncFileSystem::isAvailable):
299         (WebCore::AsyncFileSystem::isValidType):
300         (WebCore::AsyncFileSystem::create):
301         (WebCore::AsyncFileSystem::openFileSystem):
302         (WebCore::AsyncFileSystem::crackFileSystemURL):
303         (WebCore::AsyncFileSystemBlackBerry::AsyncFileSystemBlackBerry):
304         (WebCore::AsyncFileSystemBlackBerry::~AsyncFileSystemBlackBerry):
305         (WebCore::AsyncFileSystemBlackBerry::toURL):
306         (WebCore::AsyncFileSystemBlackBerry::move):
307         (WebCore::AsyncFileSystemBlackBerry::copy):
308         (WebCore::AsyncFileSystemBlackBerry::remove):
309         (WebCore::AsyncFileSystemBlackBerry::removeRecursively):
310         (WebCore::AsyncFileSystemBlackBerry::readMetadata):
311         (WebCore::AsyncFileSystemBlackBerry::createFile):
312         (WebCore::AsyncFileSystemBlackBerry::createDirectory):
313         (WebCore::AsyncFileSystemBlackBerry::fileExists):
314         (WebCore::AsyncFileSystemBlackBerry::directoryExists):
315         (WebCore::AsyncFileSystemBlackBerry::readDirectory):
316         (WebCore::AsyncFileSystemBlackBerry::createWriter):
317         (WebCore::AsyncFileSystemBlackBerry::createSnapshotFileAndReadMetadata):
318         * platform/blackberry/AsyncFileSystemBlackBerry.h: Added.
319         (WebCore):
320         (AsyncFileSystemBlackBerry):
321
322 2012-03-26  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
323
324         [BlackBerry] CredentialBackingStore implement encryptString() and decryptString()
325         https://bugs.webkit.org/show_bug.cgi?id=82204
326
327         Reviewed by Rob Buis.
328
329         Implemented encryptedString() and decryptedString() in class CredentialBackingStore
330         by calling BlackBerry::Platform::Encryptor::encryptString() and
331         BlackBerry::Platform::Encryptor::encryptString() respectively.
332
333         No new tests.
334
335         * platform/network/blackberry/CredentialBackingStore.cpp:
336         (WebCore::CredentialBackingStore::encryptedString):
337         (WebCore::CredentialBackingStore::decryptedString):
338
339 2012-03-26  Pavel Feldman  <pfeldman@chromium.org>
340
341         Web Inspector: 'use strict' exceptions stop in inspector code
342         https://bugs.webkit.org/show_bug.cgi?id=82199
343
344         Reviewed by Yury Semikhatsky.
345
346         Accessing callee from within InjectedScript made inspector stop on handled exceptions.
347         I replaced it with Object.prototype.toString.call(obj) === "[object Arguments]".
348
349         * inspector/InjectedScriptSource.js:
350
351 2012-03-26  Mihai Balan  <mibalan@adobe.com>
352
353         [CSS Regions] In region styling (@-webkit-region) the position for CSS rules is incorrectly computed
354         https://bugs.webkit.org/show_bug.cgi?id=81901
355
356         Reviewed by Antti Koivisto.
357
358         Right now CSS rules position does not take into account rules that are inside a @-webkit-region
359         declaration, leading to buggy behavior where rules that appear later in the document are superseded
360         by rules that appear earlier in the document (opposite as how things should be). The fix updates
361         the "global" rules counter once the rules in a @-webkit-region declaration have been added.
362
363         Tests: fast/regions/region-style-rule-position-expected.html
364                fast/regions/region-style-rule-position.html
365
366         * css/CSSStyleSelector.cpp:
367         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
368
369 2012-03-26  Pierre Rossi  <pierre.rossi@nokia.com>
370
371         [Qt] Disable focus ring in the mobile theme.
372         https://bugs.webkit.org/show_bug.cgi?id=81934
373
374         For mobile devices intended to be used only through
375         touch, the focus rings makes little sense and feels
376         awkward.
377
378         Reviewed by Kenneth Rohde Christiansen.
379
380         No new tests. This is merely a cosmetic touch.
381
382         * platform/qt/RenderThemeQtMobile.h:
383         (RenderThemeQtMobile):
384         (WebCore::RenderThemeQtMobile::platformFocusRingColor):
385
386 2012-03-26  Charles Wei  <charles.wei@torchmobile.com.cn>
387
388         [BlackBerry] Clean up networking code and remove WML support.
389         https://bugs.webkit.org/show_bug.cgi?id=82170
390
391         Reviewed by Rob Buis.
392
393         This just removes the WML support of BlackBerry porting, which is already 
394         removed from WebCore. No new tests needed.
395
396         * platform/blackberry/MIMETypeRegistryBlackBerry.cpp:
397         (WebCore):
398         * platform/network/blackberry/DeferredData.cpp:
399         (WebCore::DeferredData::DeferredData):
400         (WebCore::DeferredData::processDeferredData):
401         * platform/network/blackberry/DeferredData.h:
402         (DeferredData):
403         (WebCore::DeferredData::hasDeferredData):
404         * platform/network/blackberry/NetworkJob.cpp:
405         * platform/network/blackberry/NetworkJob.h:
406         (NetworkJob):
407         * platform/network/blackberry/ResourceResponse.h:
408         (WebCore::ResourceResponse::ResourceResponse):
409         (ResourceResponse):
410         * platform/network/blackberry/ResourceResponseBlackBerry.cpp:
411         (WebCore::ResourceResponse::doPlatformCopyData):
412         (WebCore::ResourceResponse::doPlatformAdopt):
413
414 2012-03-26  Philip Rogers  <pdr@google.com>
415
416         Add invalid bounding box concept to SVG containers
417         https://bugs.webkit.org/show_bug.cgi?id=81104
418
419         Reviewed by Nikolas Zimmermann.
420
421         An empty <g> element needs to use an invalid bounding box because
422         an empty bounding box isn't the default state. This change
423         introduces the concept of an invalid object bounding box for
424         both RenderSVGContainer and RenderSVGRoot. Code that
425         does not explicitly check that the bounding box is valid
426         should be unaffected by this change. We use this new invalid
427         flag in computeContainerBoundingBoxes so that we do not
428         include invalid bounding boxes.
429
430         This change also contains a small fix in
431         RenderSVGContainer::toRenderSVGContainer which depended on
432         RenderSVGViewportContainer not inheriting from RenderSVGContainer,
433         which it now does.
434
435         Test: svg/custom/getBBox-empty-container.html
436
437         * rendering/svg/RenderSVGContainer.cpp:
438         (WebCore::RenderSVGContainer::RenderSVGContainer):
439         (WebCore::RenderSVGContainer::updateCachedBoundaries):
440         * rendering/svg/RenderSVGContainer.h:
441         (WebCore::RenderSVGContainer::isObjectBoundingBoxValid):
442         (RenderSVGContainer):
443         (WebCore::toRenderSVGContainer):
444         * rendering/svg/RenderSVGRoot.cpp:
445         (WebCore::RenderSVGRoot::RenderSVGRoot):
446         (WebCore::RenderSVGRoot::updateCachedBoundaries):
447         * rendering/svg/RenderSVGRoot.h:
448         (RenderSVGRoot):
449         * rendering/svg/SVGRenderSupport.cpp:
450         (WebCore):
451         (WebCore::updateObjectBoundingBox):
452         (WebCore::SVGRenderSupport::computeContainerBoundingBoxes):
453         * rendering/svg/SVGRenderSupport.h:
454         (SVGRenderSupport):
455
456 2012-03-26  Alexei Filippov  <alexeif@chromium.org>
457
458         Web Inspector: Speed up the retainers build phase.
459         https://bugs.webkit.org/show_bug.cgi?id=81763
460
461         Replacing the edge iterator in retainers building phase
462         makes it run 10 times faster (400 ms vs. 4 sec).
463
464         Reviewed by Yury Semikhatsky.
465
466         * inspector/front-end/HeapSnapshot.js:
467         (WebInspector.HeapSnapshot.prototype._buildRetainers):
468
469 2012-03-22  Alexander Pavlov  <apavlov@chromium.org>
470
471         Web Inspector: Migrate InspectorCSSAgent to strict protocol types
472         https://bugs.webkit.org/show_bug.cgi?id=81923
473
474         Reviewed by Pavel Feldman.
475
476         No new tests, as this is a refactoring.
477
478         * inspector/CodeGeneratorInspector.py:
479         * inspector/InspectorCSSAgent.cpp:
480         (SelectorProfile):
481         (WebCore::SelectorProfile::toInspectorObject):
482         (WebCore::InspectorCSSAgent::clearFrontend):
483         (WebCore::InspectorCSSAgent::getMatchedStylesForNode):
484         (WebCore::InspectorCSSAgent::getInlineStylesForNode):
485         (WebCore::InspectorCSSAgent::getComputedStyleForNode):
486         (WebCore::InspectorCSSAgent::getAllStyleSheets):
487         (WebCore::InspectorCSSAgent::getStyleSheet):
488         (WebCore::InspectorCSSAgent::setPropertyText):
489         (WebCore::InspectorCSSAgent::toggleProperty):
490         (WebCore::InspectorCSSAgent::setRuleSelector):
491         (WebCore::InspectorCSSAgent::addRule):
492         (WebCore::InspectorCSSAgent::getSupportedCSSProperties):
493         (WebCore::InspectorCSSAgent::stopSelectorProfiler):
494         (WebCore::InspectorCSSAgent::stopSelectorProfilerImpl):
495         (WebCore::InspectorCSSAgent::collectStyleSheets):
496         (WebCore::InspectorCSSAgent::buildArrayForRuleList):
497         (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle):
498         * inspector/InspectorCSSAgent.h:
499         (InspectorCSSAgent):
500         * inspector/InspectorStyleSheet.cpp:
501         (WebCore::buildSourceRangeObject):
502         (WebCore::buildMediaObject):
503         (WebCore::fillMediaListChain):
504         (WebCore::InspectorStyle::buildObjectForStyle):
505         (WebCore::InspectorStyle::buildArrayForComputedStyle):
506         (WebCore::InspectorStyle::styleWithProperties):
507         (WebCore::InspectorStyleSheet::buildObjectForStyleSheet):
508         (WebCore::InspectorStyleSheet::buildObjectForStyleSheetInfo):
509         (WebCore::InspectorStyleSheet::buildObjectForRule):
510         (WebCore::InspectorStyleSheet::buildObjectForStyle):
511         * inspector/InspectorStyleSheet.h:
512         (WebCore::InspectorCSSId::asProtocolValue):
513         (InspectorStyle):
514         (InspectorStyleSheet):
515
516 2012-03-26  Alexander Pavlov  <apavlov@chromium.org>
517
518         Web Inspector: [REGRESSION] Workarounds for security checks when retrieving stylesheet rule lists are broken
519         https://bugs.webkit.org/show_bug.cgi?id=82191
520
521         Reviewed by Vsevolod Vlasov.
522
523         Test: http/tests/inspector/modify-cross-domain-rule.html
524
525         * inspector/InspectorStyleSheet.cpp:
526         (WebCore::asCSSRuleList):
527         (WebCore::InspectorStyleSheet::buildObjectForStyleSheet):
528
529 2012-03-26  Carlos Garcia Campos  <cgarcia@igalia.com>
530
531         Unreviewed. Fix make distcheck.
532
533         * GNUmakefile.list.am: Add missing files.
534
535 2012-03-26  Jason Liu  <jason.liu@torchmobile.com.cn>
536
537         [BlackBerry] Cookies mismatch when login to gmail.
538         https://bugs.webkit.org/show_bug.cgi?id=82165
539
540         Redirection's response can add or update cookies. The cookies of ResourceRequest is dirty
541         in this case. We shouldn't copy the dirty cookie header from ResourceRequest to PlatformRequest
542         for redirection loading.
543
544         This issue didn't happen before because we used m_cookieData not the cookie header.
545         Now we use the cookie header to avoid storing double cookie's data, and m_cookieData is removed.
546
547         Reviewed by George Staikos.
548
549         No new tests. It is a refactoring issue.
550
551         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
552         (WebCore::ResourceRequest::initializePlatformRequest):
553
554 2012-03-26  Alexis Menard  <alexis.menard@openbossa.org>
555
556         Increase code sharing between StylePropertySet and CSSPropertyLonghand.
557         https://bugs.webkit.org/show_bug.cgi?id=81960
558
559         Reviewed by Antti Koivisto.
560
561         Use longhands declaration from CSSPropertyLonghand in StylePropertySet in order
562         to avoid code duplication.
563
564         No new tests : refactoring only, we shouldn't have any behavior difference.
565
566         * css/CSSPropertyLonghand.cpp:
567         (WebCore::backgroundLonghand):
568         Re-order the array to match the spec default order.
569         (WebCore::webkitMaskLonghand):
570         Re-order to match the original order.
571         (WebCore::webkitTransformOriginLonghand):
572         A LayoutTest shows that a property was missing.
573         * css/StylePropertySet.cpp:
574         (WebCore::StylePropertySet::getPropertyValue):
575         (WebCore::StylePropertySet::borderSpacingValue):
576         (WebCore::StylePropertySet::get4Values):
577         (WebCore::StylePropertySet::getLayeredShorthandValue):
578         (WebCore::StylePropertySet::getShorthandValue):
579         (WebCore::StylePropertySet::getCommonValue):
580         (WebCore::StylePropertySet::asText):
581         * css/StylePropertySet.h:
582         (WebCore):
583         (StylePropertySet):
584
585 2012-03-26  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
586
587         [Qt] Assert in GestureTapHighlighter.
588         https://bugs.webkit.org/show_bug.cgi?id=82187
589
590         Reviewed by Kenneth Rohde Christiansen.
591
592         Adjust the boundaries of the center-rect before performing the intersection test,
593         since adjusting the boundary may cause a new intersection.
594
595         * page/GestureTapHighlighter.cpp:
596
597 2012-03-26  Antti Koivisto  <antti@apple.com>
598
599         Split MediaList into internal and CSSOM types
600         https://bugs.webkit.org/show_bug.cgi?id=82149
601
602         Reviewed by Andread Kling.
603
604         MediaList is a CSSOM type and should not be used internally.
605         
606         - Use new type MediaQuerySet internally to represent a collection of media queries.
607         - Create MediaList wrapper on-demand for CSSOM purposes only.
608         
609         This moves us forward in separating CSSOM from the internal stylesheet implementation.
610         
611         MediaQuerySet really belongs to a file of its own but that is not part of this patch.
612         
613         * css/CSSGrammar.y:
614         * css/CSSImportRule.cpp:
615         (WebCore::CSSImportRule::create):
616         (WebCore):
617         (WebCore::CSSImportRule::CSSImportRule):
618         (WebCore::CSSImportRule::~CSSImportRule):
619         (WebCore::CSSImportRule::media):
620         (WebCore::CSSImportRule::cssText):
621         * css/CSSImportRule.h:
622         (WebCore):
623         (CSSImportRule):
624         (WebCore::CSSImportRule::mediaQueries):
625         * css/CSSMediaRule.cpp:
626         (WebCore::CSSMediaRule::CSSMediaRule):
627         (WebCore::CSSMediaRule::~CSSMediaRule):
628         (WebCore::CSSMediaRule::cssText):
629         * css/CSSMediaRule.h:
630         (WebCore::CSSMediaRule::create):
631         (WebCore::CSSMediaRule::media):
632         (WebCore::CSSMediaRule::mediaQueries):
633         (CSSMediaRule):
634         * css/CSSParser.cpp:
635         (WebCore::CSSParser::parseMediaQuery):
636         (WebCore::CSSParser::createMediaQuerySet):
637         (WebCore::CSSParser::createImportRule):
638         (WebCore::CSSParser::createMediaRule):
639         (WebCore::CSSParser::updateLastMediaLine):
640         * css/CSSParser.h:
641         (WebCore):
642         (CSSParser):
643         * css/CSSStyleSelector.cpp:
644         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
645         * css/CSSStyleSheet.cpp:
646         (WebCore):
647         (WebCore::CSSStyleSheet::media):
648         (WebCore::CSSStyleSheet::setMediaQueries):
649         * css/CSSStyleSheet.h:
650         (WebCore):
651         (CSSStyleSheet):
652         (WebCore::CSSStyleSheet::mediaQueries):
653         * css/MediaList.cpp:
654         (WebCore):
655         (WebCore::MediaQuerySet::MediaQuerySet):
656         (WebCore::MediaQuerySet::~MediaQuerySet):
657         (WebCore::parseMediaDescriptor):
658         (WebCore::MediaQuerySet::parse):
659         (WebCore::MediaQuerySet::add):
660         (WebCore::MediaQuerySet::remove):
661         (WebCore::MediaQuerySet::addMediaQuery):
662         (WebCore::MediaQuerySet::mediaText):
663         (WebCore::MediaQuerySet::ensureMediaList):
664         
665             - Use OwnPtr<> for MediaQuery ownership.
666             - Move the appropriate functions to MediaQuerySet.
667             - Clean up a bit to make this more readable and better aligned to WebKit style.
668         
669         (WebCore::MediaList::MediaList):
670         (WebCore::MediaList::~MediaList):
671         (WebCore::MediaList::setMediaText):
672         (WebCore::MediaList::item):
673         (WebCore::MediaList::deleteMedium):
674         (WebCore::MediaList::appendMedium):
675         * css/MediaList.h:
676         (WebCore):
677         (WebCore::MediaQuerySet::create):
678         (WebCore::MediaQuerySet::createAllowingDescriptionSyntax):
679         (MediaQuerySet):
680         (WebCore::MediaQuerySet::queryVector):
681         (WebCore::MediaQuerySet::lastLine):
682         (WebCore::MediaQuerySet::setLastLine):
683         (MediaList):
684         (WebCore::MediaList::ref):
685         (WebCore::MediaList::deref):
686         (WebCore::MediaList::length):
687         (WebCore::MediaList::mediaText):
688         (WebCore::MediaList::queries):
689         * css/MediaQueryEvaluator.cpp:
690         (WebCore::MediaQueryEvaluator::eval):
691         * css/MediaQueryEvaluator.h:
692         (WebCore):
693         (MediaQueryEvaluator):
694         * css/MediaQueryList.cpp:
695         (WebCore::MediaQueryList::create):
696         (WebCore::MediaQueryList::MediaQueryList):
697         * css/MediaQueryList.h:
698         (WebCore):
699         (MediaQueryList):
700         * css/MediaQueryMatcher.cpp:
701         (WebCore::MediaQueryMatcher::evaluate):
702         (WebCore::MediaQueryMatcher::matchMedia):
703         * css/MediaQueryMatcher.h:
704         (WebCore):
705         (MediaQueryMatcher):
706         * css/StyleMedia.cpp:
707         (WebCore::StyleMedia::matchMedium):
708         * css/StyleSheet.cpp:
709         (WebCore::StyleSheet::~StyleSheet):
710         
711             Move the media query ownership to CSSStyleSheet where it belongs.
712         
713         (WebCore):
714         * css/StyleSheet.h:
715         (WebCore::StyleSheet::media):
716         (StyleSheet):
717         * dom/DOMImplementation.cpp:
718         (WebCore::DOMImplementation::createCSSStyleSheet):
719         * dom/ProcessingInstruction.cpp:
720         (WebCore::ProcessingInstruction::setCSSStyleSheet):
721         * dom/StyleElement.cpp:
722         (WebCore::StyleElement::createSheet):
723         * html/HTMLLinkElement.cpp:
724         (WebCore::HTMLLinkElement::process):
725         (WebCore::HTMLLinkElement::setCSSStyleSheet):
726         * html/HTMLMediaElement.cpp:
727         (WebCore::HTMLMediaElement::selectNextSourceChild):
728         * html/parser/HTMLPreloadScanner.cpp:
729         (WebCore::HTMLNames::PreloadTask::linkMediaAttributeIsScreen):
730         * inspector/InspectorStyleSheet.cpp:
731         (WebCore::buildMediaObject):
732
733 2012-03-26  Zeno Albisser  <zeno@webkit.org>
734
735         [Qt]WK2] TextureMapperShaderManager should query the program map before creating new shader program instances.
736         https://bugs.webkit.org/show_bug.cgi?id=82178
737
738         If TextureMapperShaderManager already has a reference to an instance of the
739         requested shader program type, this instance should be reused instead of
740         creating a new one.
741
742         Reviewed by Noam Rosenthal.
743
744         * platform/graphics/texmap/TextureMapperShaderManager.h:
745         (WebCore::TextureMapperShaderManager::getShaderProgram):
746
747 2012-03-26  Yury Semikhatsky  <yurys@chromium.org>
748
749         [Chromium] Web Inspector: dedicated worker inspector is empty
750         https://bugs.webkit.org/show_bug.cgi?id=82181
751
752         "beforeunload" event for worker inspector front-end is ingnored if the
753         window url is "about:blank" as it is just unload of the default content
754         before the front-end page load.
755
756         Reviewed by Pavel Feldman.
757
758         * inspector/front-end/WorkerManager.js:
759         (WebInspector.WorkerManager.prototype._workerInspectorClosing):
760
761 2012-03-22  Yury Semikhatsky  <yurys@chromium.org>
762
763         Web Inspector: split nodes and containment edges into two different arrays
764         https://bugs.webkit.org/show_bug.cgi?id=81930
765
766         Extract heap profile nodes and edges into two separate arrays. This
767         way we will have a continuous array of the heap graph nodes and can
768         aviod additional mapping between node index and its position in the
769         heap snapshot.
770
771         Reviewed by Pavel Feldman.
772
773         * inspector/front-end/HeapSnapshot.js:
774         (WebInspector.HeapSnapshot.prototype._init):
775         (WebInspector.HeapSnapshot.prototype._buildContinuousNodeArray):
776         (WebInspector.HeapSnapshot.prototype._createOnlyNodesArray):
777         (WebInspector.HeapSnapshot.prototype._restoreNodeTypes):
778         (WebInspector.HeapSnapshot.prototype._createRetainmentEdgesArray):
779         (WebInspector.HeapSnapshot.prototype._createContainmentEdgesArray):
780         * inspector/front-end/HeapSnapshotProxy.js:
781         (WebInspector.HeapSnapshotWorker):
782
783 2012-03-22  Pavel Podivilov  <podivilov@chromium.org>
784
785         Web Inspector: move resource loading logic from SourceMapParser to CompilerScriptMapping.
786         https://bugs.webkit.org/show_bug.cgi?id=81897
787
788         Reviewed by Vsevolod Vlasov.
789
790         SourceMapParser should only deal with payload parsing.
791
792         * inspector/front-end/CompilerScriptMapping.js:
793         (WebInspector.CompilerScriptMapping.prototype.rawLocationToUILocation):
794         (WebInspector.CompilerScriptMapping.prototype.addScript):
795         (WebInspector.CompilerScriptMapping.prototype.loadSourceMapForScript):
796         (WebInspector.SourceMapPayload):
797         (WebInspector.SourceMapParser):
798         (WebInspector.SourceMapParser.prototype.sourceContent):
799         (WebInspector.SourceMapParser.prototype.findEntry):
800         (WebInspector.SourceMapParser.prototype.findEntryReversed):
801         * inspector/front-end/ContentProviders.js:
802         (WebInspector.CompilerSourceMappingContentProvider):
803         (WebInspector.CompilerSourceMappingContentProvider.prototype.requestContent):
804
805 2012-03-26  Ilya Tikhonovsky  <loislo@chromium.org>
806
807         Web Inspector: replace indexOf('a text') === 0 with RegExp because it is much faster.
808         https://bugs.webkit.org/show_bug.cgi?id=82175
809
810         We were using aString.indexOf("Window") but it is not effective from performance point of view.
811         I'm replaced it with RegExp.
812
813         Reviewed by Yury Semikhatsky.
814
815         * inspector/front-end/HeapSnapshot.js:
816         (WebInspector.HeapSnapshotNode.prototype.get isWindow):
817         (WebInspector.HeapSnapshotNode.prototype.get isDetachedDOMTree):
818
819 2012-03-26  Pavel Feldman  <pfeldman@chromium.org>
820
821         Web Inspector: breakpoints should be disabled while live editing JavaScript.
822         https://bugs.webkit.org/show_bug.cgi?id=81947
823
824         Reviewed by Yury Semikhatsky.
825
826         This change disables (removes from the backend) the breakpoints while editing script.
827         Undoing or committing the change restores the breakpoints. Main logic is implemented within
828         JavaScriptSourceFrame, but it required minor tweaking of the text editor: more correct
829         undo/redo wrapper and better detection of the noop opterations.
830
831         * inspector/front-end/JavaScriptSourceFrame.js:
832         (WebInspector.JavaScriptSourceFrame):
833         (WebInspector.JavaScriptSourceFrame.prototype.afterTextChanged):
834         (WebInspector.JavaScriptSourceFrame.prototype.beforeTextChanged):
835         (WebInspector.JavaScriptSourceFrame.prototype.didEditContent):
836         (WebInspector.JavaScriptSourceFrame.prototype.addBreakpoint):
837         (WebInspector.JavaScriptSourceFrame.prototype.removeBreakpoint):
838         (WebInspector.JavaScriptSourceFrame.prototype._onMouseDown):
839         * inspector/front-end/TextEditorModel.js:
840         (WebInspector.TextEditorModel.endsWithBracketRegex.):
841         * inspector/front-end/TextViewer.js:
842         (WebInspector.TextEditorMainPanel.prototype.handleUndoRedo.before):
843         (WebInspector.TextEditorMainPanel.prototype.handleUndoRedo.after):
844         (WebInspector.TextEditorMainPanel.prototype.handleUndoRedo):
845         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
846
847 2012-03-25  Nat Duca  <nduca@chromium.org>
848
849         [chromium] Route willBeginFrame from compositor to WebWidget
850         https://bugs.webkit.org/show_bug.cgi?id=82171
851
852         Reviewed by Darin Fisher.
853
854         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
855         (CCLayerTreeHostClient):
856         (WebCore::CCLayerTreeHost::willBeginFrame):
857         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
858         (WebCore::CCThreadProxy::beginFrame):
859
860 2012-03-25  Hayato Ito  <hayato@chromium.org>
861
862         [Shadow DOM] Add Reified DOM Tree traversal internal APIs.
863         https://bugs.webkit.org/show_bug.cgi?id=79197
864
865         Reviewed by Dimitri Glazkov.
866
867         Add internal APIs which can be used to traverse Reified DOM tree, which is
868         a result of node distribution algorithm explained in Shadow DOM spec.
869         https://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html
870
871         Every public functions defined in ReifiedTreeTraversal are static
872         functions and are named in a similar way to ones defined in WebCore::Node class.
873         The only difference is that ReifiedTreeTraversal APIs consider shadow
874         hosts and also traverse nodes is Shadow DOM subtrees, crossing shadow's upper and lower boundary
875         transparently.
876
877         There is no actual client which uses these APIs. Follow-up patches for FocusNavigation
878         and EventDispatcher will use the APIs so that they can traverse node in reified tree order.
879
880         Test: fast/dom/shadow/reified-tree-traversal.html
881
882         * CMakeLists.txt:
883         * GNUmakefile.list.am:
884         * Target.pri:
885         * WebCore.exp.in:
886         * WebCore.gypi:
887         * WebCore.vcproj/WebCore.vcproj:
888         * WebCore.xcodeproj/project.pbxproj:
889         * dom/ReifiedTreeTraversal.cpp: Added.
890         (WebCore):
891         (WebCore::isShadowHost):
892         (WebCore::shadowTreeFor):
893         (WebCore::shadowTreeOfParent):
894         (WebCore::ReifiedTreeTraversal::firstChild):
895         (WebCore::ReifiedTreeTraversal::lastChild):
896         (WebCore::ReifiedTreeTraversal::lastChildWithoutCrossingUpperBoundary):
897         (WebCore::ReifiedTreeTraversal::traverseChild):
898         (WebCore::ReifiedTreeTraversal::traverseLightChildren):
899         (WebCore::ReifiedTreeTraversal::traverseNode):
900         (WebCore::ReifiedTreeTraversal::nextSibling):
901         (WebCore::ReifiedTreeTraversal::previousSibling):
902         (WebCore::ReifiedTreeTraversal::traverseSiblingOrBackToInsertionPoint):
903         (WebCore::ReifiedTreeTraversal::traverseSiblingInCurrentTree):
904         (WebCore::ReifiedTreeTraversal::traverseSiblingOrBackToYoungerShadowRoot):
905         (WebCore::ReifiedTreeTraversal::escapeFallbackContentElement):
906         (WebCore::ReifiedTreeTraversal::traverseNodeEscapingFallbackContents):
907         (WebCore::ReifiedTreeTraversal::parentNode):
908         (WebCore::ReifiedTreeTraversal::parentNodeWithoutCrossingUpperBoundary):
909         (WebCore::ReifiedTreeTraversal::parentNodeOrBackToInsertionPoint):
910         (WebCore::ReifiedTreeTraversal::parentNodeInCurrentTree):
911         (WebCore::ReifiedTreeTraversal::parentNodeBackToYoungerShadowRootOrHost):
912         (WebCore::ReifiedTreeTraversal::adjustedParentNode):
913         (WebCore::ReifiedTreeTraversal::traverseNextNode):
914         (WebCore::ReifiedTreeTraversal::traverseNextNodeWithoutCrossingUpperBoundary):
915         (WebCore::ReifiedTreeTraversal::traversePreviousNode):
916         (WebCore::ReifiedTreeTraversal::traversePreviousNodeWithoutCrossingUpperBoundary):
917         * dom/ReifiedTreeTraversal.h: Added.
918         (WebCore):
919         (ReifiedTreeTraversal):
920         * dom/ShadowTree.cpp:
921         (WebCore::ShadowTree::insertionPointFor):
922         (WebCore::ShadowTree::selectionFor):
923         (WebCore):
924         * dom/ShadowTree.h:
925         (WebCore):
926         (ShadowTree):
927         * html/shadow/HTMLContentSelector.cpp:
928         (WebCore::HTMLContentSelector::findFor):
929         * html/shadow/HTMLContentSelector.h:
930         (HTMLContentSelectionSet):
931         (WebCore::HTMLContentSelectionSet::find):
932         (HTMLContentSelector):
933         * html/shadow/InsertionPoint.h:
934         (WebCore::isInsertionPoint):
935         (WebCore::toInsertionPoint):
936         (WebCore):
937         * testing/Internals.cpp:
938         (WebCore::Internals::nextSiblingInReifiedTree):
939         (WebCore):
940         (WebCore::Internals::firstChildInReifiedTree):
941         (WebCore::Internals::lastChildInReifiedTree):
942         (WebCore::Internals::traverseNextNodeInReifiedTree):
943         (WebCore::Internals::traversePreviousNodeInReifiedTree):
944         * testing/Internals.h:
945         (Internals):
946         * testing/Internals.idl:
947
948 2012-03-25  Nikita Vasilyev  <me@elv1s.ru>
949
950         Web Inspector: Indenting fully selected line should not indent the line next to it
951         https://bugs.webkit.org/show_bug.cgi?id=81758
952
953         In the editor, you can select a whole line by moving caret at 0 column
954         position and pressing Shift + Arrow Down/Up. After that, pressing Tab
955         indents 2 lines: fully selected one and the line next to it. The patch
956         changes this behaviour to indent only fully selected line since that is
957         what pretty-match all the other code editors do.
958
959         Reviewed by Pavel Feldman.
960
961         Test: inspector/editor/indentation.html
962
963         * inspector/front-end/TextViewer.js:
964         (WebInspector.TextEditorMainPanel.prototype._indentLines):
965             Do not insert indent at the begging of the last line if a selection
966             ends on its 0 column.
967         (WebInspector.TextEditorMainPanel.prototype._unindentLines):
968             Do not remove indent at the begging of the last line if a selection
969             ends on its 0 column.
970
971 2012-03-25  Abhishek Arya  <inferno@chromium.org>
972
973         Crash in ContainerNode::resumePostAttachCallbacks.
974         https://bugs.webkit.org/show_bug.cgi?id=82159
975
976         Reviewed by Hajime Morita.
977
978         Test: plugins/object-onfocus-mutation-crash.html
979
980         * dom/ContainerNode.cpp:
981         (WebCore::ContainerNode::resumePostAttachCallbacks): dispatching post attach
982         callbacks when our attach depth is 1 can fire mutation events such as onfocus
983         which can blow away |this|. Need to protect it with a RefPtr.
984         * html/HTMLPlugInImageElement.cpp:
985         (WebCore::HTMLPlugInImageElement::attach): add calls to suspend attach callbacks
986         until the function completes.
987
988 2012-03-25  Dana Jansens  <danakj@chromium.org>
989
990         [chromium] Layers with animating transforms should prepaint even if they are not visible yet
991         https://bugs.webkit.org/show_bug.cgi?id=82117
992
993         Reviewed by Adrienne Walker.
994
995         For animating transforms, instead of early-outing when the layer's
996         visible rect is empty, let it prepaint regardless.
997
998         For now, we just only paint the outermost tiles, and only for small
999         layers, with at most 9 tiles.
1000
1001         This changes the behaviour of ContentLayerChromium's
1002         idlePaintContentsIfDirty() so I've guarded the behaviour of the two
1003         prepainting functions that it calls to ensure the old behaviour holds
1004         without animations, and the new behaviour works with them.
1005
1006         Unit test: TiledLayerChromiumTest.idlePaintZeroSizedLayer
1007                    TiledLayerChromiumTest.idlePaintZeroSizedAnimatingLayer
1008                    TiledLayerChromiumTest.idlePaintNonVisibleLayers
1009                    TiledLayerChromiumTest.idlePaintNonVisibleAnimatingLayers
1010
1011         * platform/graphics/chromium/ContentLayerChromium.cpp:
1012         (WebCore::ContentLayerChromium::idlePaintContentsIfDirty):
1013         * platform/graphics/chromium/TiledLayerChromium.cpp:
1014         (WebCore::TiledLayerChromium::prepareToUpdateIdle):
1015         (WebCore::TiledLayerChromium::needsIdlePaint):
1016         (WebCore::TiledLayerChromium::idlePaintRect):
1017         * platform/graphics/chromium/TiledLayerChromium.h:
1018         (WebCore::TiledLayerChromium::numPaintedTiles):
1019         (TiledLayerChromium):
1020
1021 2012-03-25  Antti Koivisto  <antti@apple.com>
1022
1023         Don't use CSSRuleList for child rule ownership
1024         https://bugs.webkit.org/show_bug.cgi?id=82127
1025
1026         Reviewed by Andreas Kling.
1027
1028         CSSMediaRule, WebKitCSSKeyframesRule and WebKitRegionRule use CSSRuleList for storing children. 
1029         They should use a simple rule vector instead. CSSRuleList is a CSSOM type that should be 
1030         instantiated on-demand for API purposes only.
1031         
1032         - Use Vector<RefPtr<CSSRule>> for storing the rule children of CSSMediaRule, WebKitCSSKeyframesRule 
1033           and WebKitRegionRule.
1034         - Add direct accessors, use internally instead of CSSRuleList.
1035         - Make CSSRuleList an abstract base. Add concrete subclasses for dealing with the underlying storage.
1036         - Instantiate CSSRuleLists on-demand.
1037         - Make CSSStyleSheet.cssRules always return the same object instance. This matches Firefox and the rest
1038           of our CSSOM implementation. Tested by fast/dom/gc-9.html.
1039           
1040         The patch decouples internals from the external API. It simplifies the child rule ownership and reduces 
1041         indirection. Memory use of css rules with children is reduced (by a ptr, refcount and heap allocation overhead).
1042
1043         * css/CSSGrammar.y:
1044         * css/CSSMediaRule.cpp:
1045         (WebCore::CSSMediaRule::CSSMediaRule):
1046         (WebCore::CSSMediaRule::~CSSMediaRule):
1047         (WebCore::CSSMediaRule::append):
1048         (WebCore::CSSMediaRule::insertRule):
1049         (WebCore::CSSMediaRule::deleteRule):
1050         (WebCore::CSSMediaRule::cssText):
1051         (WebCore::CSSMediaRule::cssRules):
1052         * css/CSSMediaRule.h:
1053         (WebCore::CSSMediaRule::create):
1054         (CSSMediaRule):
1055         (WebCore::CSSMediaRule::ruleCount):
1056         (WebCore::CSSMediaRule::ruleAt):
1057         * css/CSSParser.cpp:
1058         (WebCore::CSSParser::createMediaRule):
1059         (WebCore::CSSParser::createRuleList):
1060         (WebCore::CSSParser::createRegionRule):
1061         * css/CSSParser.h:
1062         (WebCore):
1063         * css/CSSRuleList.cpp:
1064         (WebCore):
1065         (WebCore::StaticCSSRuleList::StaticCSSRuleList):
1066         (WebCore::StaticCSSRuleList::~StaticCSSRuleList):
1067         (WebCore::StaticCSSRuleList::deref):
1068         (WebCore::StaticCSSRuleList::item):        
1069         * css/CSSRuleList.h:
1070         (CSSRuleList):
1071
1072             Turn CSSRuleList into abstract interface.
1073                     
1074         (StaticCSSRuleList):
1075         (WebCore::StaticCSSRuleList::create):
1076         (WebCore::StaticCSSRuleList::ref):
1077         (WebCore::StaticCSSRuleList::rules):
1078         (WebCore::StaticCSSRuleList::styleSheet):
1079         (WebCore::StaticCSSRuleList::length):
1080         
1081             Concrete implementation for fixed list of rules.
1082     
1083         (WebCore):
1084         (LiveCSSRuleList):
1085         (WebCore::LiveCSSRuleList::LiveCSSRuleList):
1086         (WebCore::LiveCSSRuleList::ref):
1087         (WebCore::LiveCSSRuleList::deref):
1088         (WebCore::LiveCSSRuleList::length):
1089         (WebCore::LiveCSSRuleList::item):
1090         (WebCore::LiveCSSRuleList::styleSheet):
1091         
1092             Concrete implemenation for live list backed by the underlying container rule.
1093             LiveCSSRuleList is owned by the underlying rule. Refcount is forwarded. 
1094         
1095         * css/CSSStyleSelector.cpp:
1096         (WebCore::CSSStyleSelector::sortAndTransferMatchedRules):
1097         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
1098         * css/CSSStyleSelector.h:
1099         (CSSStyleSelector):
1100         * css/CSSStyleSheet.cpp:
1101         
1102             The same scheme for CSSStyleSheet.cssRule as with container rules.
1103         
1104         (StyleSheetCSSRuleList):
1105         (WebCore::StyleSheetCSSRuleList::StyleSheetCSSRuleList):
1106         (WebCore::StyleSheetCSSRuleList::ref):
1107         (WebCore::StyleSheetCSSRuleList::deref):
1108         (WebCore::StyleSheetCSSRuleList::length):
1109         (WebCore::StyleSheetCSSRuleList::item):
1110         (WebCore::StyleSheetCSSRuleList::styleSheet):
1111         (WebCore):
1112         (WebCore::CSSStyleSheet::rules):
1113         (WebCore::CSSStyleSheet::cssRules):
1114         * css/CSSStyleSheet.h:
1115         (CSSStyleSheet):
1116         * css/WebKitCSSKeyframesRule.cpp:
1117         (WebCore::WebKitCSSKeyframesRule::WebKitCSSKeyframesRule):
1118         (WebCore::WebKitCSSKeyframesRule::~WebKitCSSKeyframesRule):
1119         (WebCore):
1120         (WebCore::WebKitCSSKeyframesRule::append):
1121         (WebCore::WebKitCSSKeyframesRule::deleteRule):
1122         (WebCore::WebKitCSSKeyframesRule::findRule):
1123         (WebCore::WebKitCSSKeyframesRule::findRuleIndex):
1124         (WebCore::WebKitCSSKeyframesRule::cssText):
1125         (WebCore::WebKitCSSKeyframesRule::cssRules):
1126         * css/WebKitCSSKeyframesRule.h:
1127         (WebKitCSSKeyframesRule):
1128         (WebCore::WebKitCSSKeyframesRule::ruleCount):
1129         (WebCore::WebKitCSSKeyframesRule::ruleAt):
1130         (WebCore::WebKitCSSKeyframesRule::length):
1131         (WebCore::WebKitCSSKeyframesRule::item):
1132         * css/WebKitCSSRegionRule.cpp:
1133         (WebCore::WebKitCSSRegionRule::WebKitCSSRegionRule):
1134         (WebCore::WebKitCSSRegionRule::~WebKitCSSRegionRule):
1135         (WebCore::WebKitCSSRegionRule::cssText):
1136         (WebCore::WebKitCSSRegionRule::cssRules):
1137         * css/WebKitCSSRegionRule.h:
1138         * inspector/InspectorStyleSheet.cpp:
1139         (WebCore::asCSSRuleList):
1140         (WebCore::InspectorStyleSheet::addRule):
1141         (WebCore::InspectorStyleSheet::buildObjectForStyleSheet):
1142
1143 2012-03-25  Kentaro Hara  <haraken@chromium.org>
1144
1145         Remove duplicated GenerateConditionalString() from code generators
1146         https://bugs.webkit.org/show_bug.cgi?id=82148
1147
1148         Reviewed by Adam Barth.
1149
1150         Previously GenerateConditionalString()s were defined in each code generator,
1151         and they were doing the same thing. This patch puts GenerateConditionalString()
1152         in CodeGenerator.pm and removes duplicated GenerateConditionalString()s.
1153
1154         No tests. No change in the generated code.
1155
1156         * bindings/scripts/CodeGenerator.pm:
1157         (GenerateConditionalString):
1158         * bindings/scripts/CodeGeneratorCPP.pm:
1159         (GenerateHeader):
1160         (GenerateImplementation):
1161         * bindings/scripts/CodeGeneratorGObject.pm:
1162         (GenerateProperty):
1163         (GenerateProperties):
1164         (GenerateFunction):
1165         (WriteData):
1166         * bindings/scripts/CodeGeneratorJS.pm:
1167         (GenerateHeaderContentHeader):
1168         (GenerateImplementationContentHeader):
1169         (GenerateHeader):
1170         (GenerateImplementation):
1171         (GenerateCallbackHeader):
1172         (GenerateCallbackImplementation):
1173         * bindings/scripts/CodeGeneratorObjC.pm:
1174         (GenerateHeader):
1175         (GenerateImplementation):
1176         * bindings/scripts/CodeGeneratorV8.pm:
1177         (GenerateHeader):
1178         (GenerateNormalAttrGetter):
1179         (GenerateNormalAttrSetter):
1180         (GenerateOverloadedFunctionCallback):
1181         (GenerateFunctionCallback):
1182         (GenerateBatchedAttributeData):
1183         (GenerateImplementation):
1184         (GenerateHeaderContentHeader):
1185         (GenerateImplementationContentHeader):
1186         (GenerateCallbackHeader):
1187         (GenerateCallbackImplementation):
1188
1189 2012-03-25  Kentaro Hara  <haraken@chromium.org>
1190
1191         Move DOMWindowSQLDatabase.* to DOMWindowWebDatabase.*, and move WorkerContextSQLDatabase.* to WorkerContextWebDatabase.*
1192         https://bugs.webkit.org/show_bug.cgi?id=82146
1193
1194         Reviewed by Adam Barth.
1195
1196         Now SQLDatabase is renamed to WebDatabase (See Modules/webdatabase/).
1197         We should move DOMWindowSQLDatabase.* to DOMWindowWebDatabase.*,
1198         and move WorkerContextSQLDatabase.* to WorkerContextWebDatabase.*.
1199         We'll rename the SQL_DATABASE flag to the WEB_DATABASE flag in a follow-up patch.
1200
1201         No tests. No change in behavior.
1202
1203         * Modules/webdatabase/DOMWindowWebDatabase.cpp: Renamed from Source/WebCore/Modules/webdatabase/DOMWindowSQLDatabase.cpp.
1204         (WebCore):
1205         (WebCore::DOMWindowWebDatabase::openDatabase):
1206         * Modules/webdatabase/DOMWindowWebDatabase.h: Renamed from Source/WebCore/Modules/webdatabase/DOMWindowSQLDatabase.h.
1207         (WebCore):
1208         (DOMWindowWebDatabase):
1209         (WebCore::DOMWindowWebDatabase::DOMWindowWebDatabase):
1210         (WebCore::DOMWindowWebDatabase::~DOMWindowWebDatabase):
1211         * Modules/webdatabase/DOMWindowWebDatabase.idl: Renamed from Source/WebCore/Modules/webdatabase/DOMWindowSQLDatabase.idl.
1212         * Modules/webdatabase/WorkerContextWebDatabase.cpp: Renamed from Source/WebCore/Modules/webdatabase/WorkerContextSQLDatabase.cpp.
1213         (WebCore):
1214         (WebCore::WorkerContextWebDatabase::openDatabase):
1215         (WebCore::WorkerContextWebDatabase::openDatabaseSync):
1216         * Modules/webdatabase/WorkerContextWebDatabase.h: Renamed from Source/WebCore/Modules/webdatabase/WorkerContextSQLDatabase.h.
1217         (WebCore):
1218         (WorkerContextWebDatabase):
1219         (WebCore::WorkerContextWebDatabase::WorkerContextWebDatabase):
1220         (WebCore::WorkerContextWebDatabase::~WorkerContextWebDatabase):
1221         * Modules/webdatabase/WorkerContextWebDatabase.idl: Renamed from Source/WebCore/Modules/webdatabase/WorkerContextSQLDatabase.idl.
1222
1223         * DerivedSources.make:
1224         * DerivedSources.pri:
1225         * GNUmakefile.list.am:
1226         * Target.pri:
1227         * WebCore.gypi:
1228         * WebCore.vcproj/WebCore.vcproj:
1229         * WebCore.xcodeproj/project.pbxproj:
1230
1231 2012-03-25  Philip Rogers  <pdr@google.com>
1232
1233         Avoid race condition when iterating over pending resources
1234         https://bugs.webkit.org/show_bug.cgi?id=82115
1235
1236         Reviewed by Nikolas Zimmermann.
1237
1238         We can hit a race condition in SVGStyledElement::buildPendingResourcesIfNeeded
1239         where pending elements can become non-pending while we iterate over them.
1240
1241         This patch cleans up buildPendingResourcesIfNeeded and re-works how pending
1242         resources are removed. Because pending resources can be modified while
1243         iterating over them, we introduce m_pendingResourcesForRemoval that
1244         holds pending resources that are marked for removal. Instead of iterating
1245         over this list we simply remove each pending resource from
1246         m_pendingResourcesForRemoval; if a pending resource is modified or removed
1247         during the processing of another pending resource this list is updated before
1248         the next element can be accessed.
1249
1250         This change also removes removePendingResourceForElement which is no longer
1251         referenced.
1252
1253         Test: http/tests/svg/change-id-with-pending-resources.html
1254
1255         * svg/SVGDocumentExtensions.cpp:
1256         (WebCore::SVGDocumentExtensions::~SVGDocumentExtensions):
1257         (WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
1258         (WebCore::SVGDocumentExtensions::removePendingResourceForRemoval):
1259         (WebCore):
1260         (WebCore::SVGDocumentExtensions::markPendingResourcesForRemoval):
1261         (WebCore::SVGDocumentExtensions::removeElementFromPendingResourcesForRemoval):
1262         * svg/SVGDocumentExtensions.h:
1263         (SVGDocumentExtensions):
1264         * svg/SVGStyledElement.cpp:
1265         (WebCore::SVGStyledElement::buildPendingResourcesIfNeeded):
1266
1267 2012-03-25  Arvid Nilsson  <anilsson@rim.com>
1268
1269         [BlackBerry] Accelerated compositing layers fail to render when using WebPageCompositor
1270         https://bugs.webkit.org/show_bug.cgi?id=82104
1271         RIM PR: 145963
1272
1273         Reviewed by Rob Buis.
1274
1275         The embedder may use vertex buffers, which affected the interpretation
1276         our vertex array pointers from memory pointers to offsets into a vertex
1277         buffer. The resulting geometry often resulted in no visible layers on
1278         screen.
1279
1280         Fixed by getting rid of any bound buffer when we enter
1281         LayerRenderer::drawLayers().
1282
1283         * platform/graphics/blackberry/LayerRenderer.cpp:
1284         (WebCore::LayerRenderer::drawLayers):
1285
1286 2012-03-24  Nat Duca  <nduca@chromium.org>
1287
1288         [chromium] Instrument gesture animations with async traces
1289         https://bugs.webkit.org/show_bug.cgi?id=82076
1290
1291         Reviewed by Adrienne Walker.
1292
1293         * platform/ActivePlatformGestureAnimation.cpp:
1294         (WebCore::ActivePlatformGestureAnimation::~ActivePlatformGestureAnimation):
1295         (WebCore::ActivePlatformGestureAnimation::ActivePlatformGestureAnimation):
1296         * platform/PlatformGestureCurve.h:
1297         (PlatformGestureCurve):
1298         * platform/TouchpadFlingPlatformGestureCurve.h:
1299         (WebCore::TouchpadFlingPlatformGestureCurve::debugName):
1300         * platform/WheelFlingPlatformGestureCurve.h:
1301         (WebCore::WheelFlingPlatformGestureCurve::debugName):
1302         * platform/graphics/chromium/cc/CCActiveGestureAnimation.cpp:
1303         (WebCore::CCActiveGestureAnimation::CCActiveGestureAnimation):
1304         (WebCore::CCActiveGestureAnimation::~CCActiveGestureAnimation):
1305         * platform/graphics/chromium/cc/CCGestureCurve.h:
1306         (CCGestureCurve):
1307
1308 2012-03-24  Jeffrey Pfau  <jpfau@apple.com>
1309
1310         XML error document creation should not fire mutation events
1311         https://bugs.webkit.org/show_bug.cgi?id=80765
1312
1313         Reviewed by Adam Barth.
1314
1315         Broke two tests that expected the old behavior, which have now been updated.
1316
1317         * xml/XMLErrors.cpp:
1318         (WebCore::createXHTMLParserErrorHeader):
1319         (WebCore::XMLErrors::insertErrorMessageBlock):
1320
1321 2012-03-24  Florin Malita  <fmalita@google.com>
1322
1323         ForeignObject content is zoomed two times
1324         https://bugs.webkit.org/show_bug.cgi?id=76282
1325
1326         Reviewed by Nikolas Zimmermann.
1327
1328         Test: svg/zoom/page/zoom-foreign-content.svg
1329
1330         Reset the effective zoom property for FO-nested content to avoid
1331         having the zoom factor applied multiple times (zooming is handled by
1332         the top level SVG root element).
1333
1334         * css/CSSStyleSelector.cpp:
1335         (WebCore::CSSStyleSelector::adjustRenderStyle):
1336
1337 2012-03-24  Chris Fleizach  <cfleizach@apple.com>
1338
1339         AX: Support solution to handle invalid ax text marker
1340         https://bugs.webkit.org/show_bug.cgi?id=82023
1341
1342         Reviewed by Oliver Hunt.
1343
1344         This provides methods to better use text markers so that assistive technologies
1345         can know when they are valid, and can convert them to and from absolute positions.
1346
1347         Test: platform/mac/accessibility/textmarker-routines.html
1348
1349         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
1350         (-[WebAccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
1351         (-[WebAccessibilityObjectWrapper _convertToNSRange:]):
1352         (-[WebAccessibilityObjectWrapper _indexForTextMarker:]):
1353         (-[WebAccessibilityObjectWrapper _textMarkerForIndex:]):
1354         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
1355
1356 2012-03-24  Victor Carbune  <vcarbune@adobe.com>
1357
1358         Quick fix for rendering controls regression.
1359         https://bugs.webkit.org/show_bug.cgi?id=82125
1360
1361         Reviewed by Eric Carlson.
1362
1363         Only temporary fix. Tests to cover the problem should be added
1364
1365         * html/shadow/MediaControlElements.cpp:
1366         (WebCore::MediaControlPanelElement::makeOpaque): The display:none
1367         property should be toggled only by the media element now.
1368         (WebCore::MediaControlPanelElement::makeTransparent): The timer
1369         that toggles the dispalay:none shouldn't be used now.
1370
1371 2012-03-24  Kevin Ollivier  <kevino@theolliviers.com>
1372
1373         [wx] Unreviewed. Add header needed for compilation.
1374
1375         * html/shadow/TextFieldDecorationElement.cpp:
1376
1377 2012-03-24  Abhishek Arya  <inferno@chromium.org>
1378
1379         Crash in ApplyStyleCommand::applyInlineStyleToNodeRange.
1380         https://bugs.webkit.org/show_bug.cgi?id=81959
1381
1382         Reviewed by Ryosuke Niwa.
1383
1384         Test: editing/execCommand/apply-style-command-crash.html
1385
1386         * editing/ApplyStyleCommand.cpp:
1387         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange): RefPtr the weak
1388         node iterator |node|.
1389         * editing/ApplyStyleCommand.h:
1390         (ApplyStyleCommand): convert |startNode| and |pastEndNode| into PassRefPtr.
1391
1392 2012-03-24  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
1393
1394         Unreviewed, build fix since we use "-Werror=unused-but-set-variable".
1395
1396         The variable 'it' was set at TextureMapperShaderManager.h:110 but never used.
1397
1398         * platform/graphics/texmap/TextureMapperShaderManager.h:
1399         (WebCore::TextureMapperShaderManager::getShaderProgram):
1400
1401 2012-03-24  Zeno Albisser  <zeno@webkit.org>
1402
1403         [Qt][WK2] Make TextureMapperShaderManager::getShaderProgram() not be a template.
1404         https://bugs.webkit.org/show_bug.cgi?id=82049
1405
1406         Change the getShaderProgram() function to not be a template.
1407         This is a workaround for a compiler bug that leads to an assert
1408         when compiling in debug mode on mac.
1409
1410         Reviewed by Noam Rosenthal.
1411
1412         * platform/graphics/texmap/TextureMapperGL.cpp:
1413         (WebCore::TextureMapperGL::drawTexture):
1414         (WebCore::TextureMapperGL::beginClip):
1415         * platform/graphics/texmap/TextureMapperShaderManager.h:
1416         (TextureMapperShaderProgram):
1417         (WebCore::TextureMapperShaderManager::getShaderProgram):
1418         (TextureMapperShaderManager):
1419
1420 2012-03-23  Shawn Singh  <shawnsingh@chromium.org>
1421
1422         [chromium] Incorrect replica originTransform used in CCDamageTracker
1423         https://bugs.webkit.org/show_bug.cgi?id=82118
1424
1425         Reviewed by Adrienne Walker.
1426
1427         Unit test added to CCDamageTrackerTest.cpp
1428
1429         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
1430         (WebCore::CCDamageTracker::extendDamageForRenderSurface):
1431
1432 2012-03-23  Dana Jansens  <danakj@chromium.org>
1433
1434         [chromium] When prepainting fails, tiles dirty rects may be cleared
1435         https://bugs.webkit.org/show_bug.cgi?id=82107
1436
1437         Reviewed by Adrienne Walker.
1438
1439         When prepainting, if a tile is unable to be reserved due to memory
1440         limits, we bail out of prepareToUpdateTiles. But we would have
1441         cleared the dirty rect of any previous tiles. This leaves them
1442         in a bad state where their textures are reserved, but their textureIds
1443         are set to 0, and they are not marked dirty. This means that they will
1444         not be updated and displayed if they become visible, since it is
1445         assumed that valid textures with zero textureId must have a dirty
1446         region.
1447
1448         We fix this by not clearing the dirty rects until we know we are
1449         going to update the layer.
1450
1451         Unit test: TiledLayerChromiumTest.pushTilesAfterIdlePaintFailed
1452
1453         * platform/graphics/chromium/TiledLayerChromium.cpp:
1454         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
1455         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
1456         (WebCore::CCTiledLayerImpl::hasTextureIdForTileAt):
1457         (WebCore):
1458         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
1459         (CCTiledLayerImpl):
1460
1461 2012-03-23  Stephanie Lewis  <slewis@apple.com>
1462
1463         https://bugs.webkit.org/show_bug.cgi?id=81963 WebProcess can get stuck in GC during many low memory signals.
1464         <rdar://problem/11094830> WebProcess appears to get stuck in its GC handler (81963).
1465         Remove the call to garbage collect  in low memory signal handler.  Did some testing with hitting the low memory handler
1466         during Membuster and we would get back at most 100k - 200k.  That isn't enough to help the system, and in 
1467         that state the GC collection can take a substantial amount of time.
1468
1469         Reviewed by Geoff Garen.
1470
1471         Performance Change, no change in behavior.
1472
1473         * platform/mac/MemoryPressureHandlerMac.mm:
1474         (WebCore::MemoryPressureHandler::releaseMemory):
1475
1476 2012-03-23  W. James MacLean  <wjmaclean@chromium.org>
1477
1478         [chromium] CCLayerTreeHostImpl::scrollBegin() should return ScrollFailed for CCInputHandlerClient::Gesture type when wheel handlers found.
1479         https://bugs.webkit.org/show_bug.cgi?id=82106
1480
1481         Reviewed by Adrienne Walker.
1482
1483         Existing unit tests updated.
1484
1485         With gesture scroll events now being handled as mouse wheel events, we should not start a gesture scroll when
1486         wheel handlers are present.
1487
1488         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1489         (WebCore::CCLayerTreeHostImpl::scrollBegin):
1490
1491 2012-03-23  Adam Barth  <abarth@webkit.org>
1492
1493         Move Notifications APIs from WorkerContext.idl to WorkerContextNotifications.idl
1494         https://bugs.webkit.org/show_bug.cgi?id=79635
1495
1496         Reviewed by Kentaro Hara.
1497
1498         This patch moves the NotificationCenter from WorkerContext to
1499         WorkerContextNotificiations, reducing clutter in WorkerContext.  After
1500         this patch, Notifications are almost entirely contained in the
1501         notifications directory.
1502
1503         * CMakeLists.txt:
1504         * DerivedSources.make:
1505         * DerivedSources.pri:
1506         * GNUmakefile.list.am:
1507         * Target.pri:
1508         * WebCore.gypi:
1509         * WebCore.vcproj/WebCore.vcproj:
1510         * WebCore.xcodeproj/project.pbxproj:
1511         * workers/WorkerContext.cpp:
1512         (WebCore::WorkerContext::~WorkerContext):
1513         * workers/WorkerContext.h:
1514         (WebCore):
1515         (WorkerContext):
1516         * workers/WorkerContext.idl:
1517
1518 2012-03-23  Michal Mocny  <mmocny@google.com>
1519
1520         [chromium] RootLayer was not being checked for null causing segfaults very rarely.
1521         https://bugs.webkit.org/show_bug.cgi?id=82111
1522
1523         Reviewed by Adrienne Walker.
1524
1525         * platform/graphics/chromium/LayerRendererChromium.cpp:
1526         (WebCore::LayerRendererChromium::beginDrawingFrame):
1527         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
1528         (WebCore::CCLayerTreeHostImpl::drawLayers):
1529
1530 2012-03-23  Shawn Singh  <shawnsingh@chromium.org>
1531
1532         [chromium] Fix race bug that clobbers CCLayerImpl updateRect
1533         https://bugs.webkit.org/show_bug.cgi?id=82109
1534
1535         Reviewed by Dirk Pranke.
1536
1537         If the main thread commits twice before the impl thread actually
1538         draws, then the updateRect of the first frame gets lost forever,
1539         and not propagated to the damage tracker.
1540
1541         The solution is to accumulate the updateRect. The CCLayerImpl
1542         updateRect is already being correctly cleared at the appropriate
1543         time after drawing.
1544
1545         Unit test added to LayerChromiumTest.cpp.
1546
1547         * platform/graphics/chromium/LayerChromium.cpp:
1548         (WebCore::LayerChromium::pushPropertiesTo):
1549
1550 2012-03-23  Rafael Weinstein  <rafaelw@chromium.org>
1551
1552         [MutationObservers] attributeFilter should be case sensitive at all times
1553         https://bugs.webkit.org/show_bug.cgi?id=81822
1554
1555         Reviewed by Ryosuke Niwa.
1556
1557         This removes the behavior in MutationObserverRegistration which treats
1558         attributeFilter as case insensitive for HTML elements in HTML documents.
1559
1560         Relevant tests have been updated.
1561
1562         * dom/MutationObserverRegistration.cpp:
1563         (WebCore::MutationObserverRegistration::resetObservation):
1564         (WebCore::MutationObserverRegistration::shouldReceiveMutationFrom):
1565         * dom/MutationObserverRegistration.h:
1566         (MutationObserverRegistration):
1567
1568 2012-03-23  Kentaro Hara  <haraken@chromium.org>
1569
1570         Move WebSocket APIs from WorkerContext.idl to WorkerContextWebSocket.idl
1571         https://bugs.webkit.org/show_bug.cgi?id=79663
1572
1573         Reviewed by Adam Barth.
1574
1575         For WebKit modularization, this patch moves WebSocket APIs from WorkerContext.idl
1576         to WorkerContextWebSocket.idl.
1577
1578         Tests: http/tests/websocket/tests/hybi/workers/* (No change in test results)
1579
1580         * CMakeLists.txt:
1581         * DerivedSources.make:
1582         * DerivedSources.pri:
1583         * GNUmakefile.list.am:
1584         * Modules/websockets/WorkerContextWebSocket.idl: Added.
1585         * WebCore.gypi:
1586         * WebCore.xcodeproj/project.xcodeproj:
1587         * workers/WorkerContext.idl:
1588
1589 2012-03-23  Parag Radke  <parag@motorola.com>
1590
1591         REGRESSION: can select text of an input button
1592         https://bugs.webkit.org/show_bug.cgi?id=13624
1593
1594         Reviewed by Ryosuke Niwa.
1595
1596         Text in a button should never have a selection background of its own painted
1597         but if the button is inside an editable area, then the whole button should
1598         have it's selection background painted.
1599
1600         Test: editing/selection/selection-button-text.html
1601
1602         * rendering/RenderButton.h:
1603         Added implementation for the virtual function canBeSelectionLeaf()
1604         which returns true if the button renderer is editable, false other wise.
1605         * rendering/RenderTextFragment.h:
1606         Added implementation for the virtual function canBeSelectionLeaf()
1607         which returns true if the text fragment renderer is editable, false other wise.
1608
1609 2012-03-23  Eric Carlson  <eric.carlson@apple.com>
1610
1611         Remove unnecessary ASSERT from LoadableTextTrack::trackElementIndex
1612         https://bugs.webkit.org/show_bug.cgi?id=82095
1613
1614         Reviewed by Dan Bernstein.
1615
1616         No new tests, removed a bogus ASSERT that was sometimes triggered by tests.
1617
1618         * html/track/LoadableTextTrack.cpp:
1619         (WebCore::LoadableTextTrack::trackElementIndex): Remove ASSERT.
1620
1621 2012-03-23  Eric Carlson  <eric.carlson@apple.com>
1622
1623         Layout Test media/video-source-load.html is failing
1624         https://bugs.webkit.org/show_bug.cgi?id=82094
1625
1626         Reviewed by Alexey Proskuryakov.
1627
1628         No new tests, tested by media/video-source-load.html.
1629
1630         * html/HTMLMediaElement.cpp:
1631         (WebCore::HTMLMediaElement::sourceWasAdded): Set m_nextChildNodeToConsider when called 
1632             with networkState == NETWORK_EMPTY because the resource selection algorithm has
1633             not started yet.
1634
1635 2012-03-23  Alexey Proskuryakov  <ap@apple.com>
1636
1637         [Mac] No need for platform-specific ENABLE_BLOB values
1638         https://bugs.webkit.org/show_bug.cgi?id=82102
1639
1640         Reviewed by David Kilzer.
1641
1642         * Configurations/FeatureDefines.xcconfig:
1643
1644 2012-03-23  Kent Tamura  <tkent@chromium.org>
1645
1646         Add TextFieldDecorator and TextFieldDecorationElement
1647         https://bugs.webkit.org/show_bug.cgi?id=80580
1648
1649         Reviewed by Dimitri Glazkov.
1650
1651         These classes will be used to add a decoration icon to a text field
1652         <input> from outside of WebCore. We have a plan to use them in Chromium
1653         port. So this patch doesn't add TextFieldDecorationElement.{cpp,h} to
1654         non-Chromium build files.
1655
1656         How it works:
1657         When a shadow subtree for a text field is created, we ask ChromeClient
1658         to decorate it. ChromeClient appends a TextFieldDecorationElement to the
1659         existing shadow subtree or another shadow tree. A TextFieldDecorator is
1660         associated to a TextFieldDecorationElement, and it provides decoration
1661         icon images and a click handler.
1662
1663         No new tests. This patch won't make any behavior change for now.
1664
1665         * WebCore.gypi: Add TextFieldDecorationElement.cpp and TextFieldDecorationElement.h
1666         * dom/Element.h:
1667         (WebCore::Element::isTextFieldDecoration):
1668         * html/TextFieldInputType.cpp:
1669         (WebCore::TextFieldInputType::createShadowSubtree):
1670         Calls ChromeClient::willAddTextFieldDecorationsTo() and addTextFieldDecorationsTo().
1671         * html/shadow/TextFieldDecorationElement.cpp: Added.
1672         (WebCore::TextFieldDecorator::~TextFieldDecorator):
1673         (WebCore::TextFieldDecorationElement::TextFieldDecorationElement):
1674         (WebCore::TextFieldDecorationElement::create):
1675         (WebCore::TextFieldDecorationElement::isTextFieldDecoration):
1676         (WebCore::TextFieldDecorationElement::updateImage):
1677         (WebCore::TextFieldDecorationElement::customStyleForRenderer):
1678         Sets the size to a square of the font-size.
1679         (WebCore::TextFieldDecorationElement::createRenderer):
1680         Always creates a RenderImage.
1681         (WebCore::TextFieldDecorationElement::attach):
1682         Sets an image for appropriate state.
1683         (WebCore::TextFieldDecorationElement::isMouseFocusable):
1684         (WebCore::TextFieldDecorationElement::defaultEventHandler):
1685         Delegate a click event to the corresponding function of TextFieldDecorator.
1686         * html/shadow/TextFieldDecorationElement.h: Added.
1687         (TextFieldDecorator): Added.
1688         (TextFieldDecorationElement): Added.
1689         (WebCore::toTextFieldDecorationElement): Added.
1690         * page/ChromeClient.h:
1691         (WebCore::ChromeClient::willAddTextFieldDecorationsTo): Add an empty implementation.
1692         (WebCore::ChromeClient::addTextFieldDecorationsTo): ditto.
1693
1694 2012-03-23  Adam Klein  <adamk@chromium.org>
1695
1696         Match DOM4 spec with respect to DocumentFragment insertion
1697         https://bugs.webkit.org/show_bug.cgi?id=82089
1698
1699         Reviewed by Ryosuke Niwa.
1700
1701         DOM4 specifies the behavior of appendChild, insertBefore, and replaceChild
1702         in terms of "mutation algorithms":
1703
1704         http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#mutation-algorithms
1705
1706         This change updates WebKit to match, in particular with regard to DocumentFragments.
1707         Previously, ContainerNode would remove nodes one at a time, then add them to the new parent.
1708         When combined with MutationObservers, this results in overly-verbose mutation records.
1709         Now we create as few records as possible, matching the spec as well as Gecko's implementation
1710         of MutationObservers.
1711
1712         Note that we still need to check validity each time through the loop,
1713         since inserting a node may dispatch events. In a future change, I hope
1714         to move these events so that they fire only after all nodes are inserted,
1715         but that's too much to tackle all in one.
1716
1717         Tests: fast/mutation/document-fragment-insertion.html
1718
1719         * dom/ContainerNode.cpp:
1720         (WebCore::collectChildrenAndRemoveFromOldParent): New helper method
1721         combining collectTargetNodes() with the removal of the collected nodes from
1722         their old parent, if any.
1723         (WebCore::ContainerNode::insertBefore): Use new helper method instead
1724         of removing nodes one at a time from the fragment.
1725         (WebCore::ContainerNode::replaceChild): ditto. Also removed some redundant asserts
1726         and moved the "do nothing" check out of the loop.
1727         (WebCore::ContainerNode::appendChild): Use new helper method.
1728
1729 2012-03-23  Stephen White  <senorblanco@chromium.org>
1730
1731         [skia] Switch to Skia's implementation of the feMorphology filter.
1732         https://bugs.webkit.org/show_bug.cgi?id=82085
1733
1734         Reviewed by Dirk Schulze.
1735
1736         Covered by existing tests in svg/filters/.
1737
1738         * WebCore.gypi:
1739         * platform/graphics/filters/FEMorphology.h:
1740         (FEMorphology):
1741         * platform/graphics/filters/skia/FEMorphologySkia.cpp: Added.
1742         (WebCore):
1743         (WebCore::FEMorphology::platformApplySkia):
1744
1745 2012-03-23  Adam Barth  <abarth@webkit.org>
1746
1747         Move Notifications APIs from DOMWindow.idl to DOMWindowNotifications.idl (Part 3)
1748         https://bugs.webkit.org/show_bug.cgi?id=82027
1749
1750         Reviewed by Kentaro Hara.
1751
1752         Rather than watching for willDetachPage, NotificationCenter can just
1753         override ActiveDOMObject::stop directly to be notified when it needs to
1754         stop.
1755
1756         Switching NotificationCenter over to using ActiveDOMObject callbacks
1757         frees DOMWindowNotification to implement reconnectFrame.  However, this
1758         is only really a victory in princple because NotificationCenter always
1759         returns false for canSuspend(), which means we'll never actually use
1760         the reconnectFrame functionality.  However, this patch does move us
1761         closer to the time when NotificationCenter can implement
1762         ActiveDOMObject::suspend/resume to play nice with the PageCache.
1763
1764         * notifications/DOMWindowNotifications.cpp:
1765         (WebCore::DOMWindowNotifications::disconnectFrame):
1766         (WebCore::DOMWindowNotifications::reconnectFrame):
1767         * notifications/DOMWindowNotifications.h:
1768         (DOMWindowNotifications):
1769         * notifications/NotificationCenter.cpp:
1770         (WebCore::NotificationCenter::NotificationCenter):
1771         (WebCore::NotificationCenter::stop):
1772         * notifications/NotificationCenter.h:
1773         (NotificationCenter):
1774
1775 2012-03-23  Daniel Cheng  <dcheng@chromium.org>
1776
1777         [chromium] Support file drag out using DataTransferItemList::add(File)
1778         https://bugs.webkit.org/show_bug.cgi?id=81261
1779
1780         Reviewed by Tony Chang.
1781
1782         Original patch by Varun Jain <varunjain@chromium.org>.
1783         I've updated the original patch to remove 'downloadurl' handling since it's not tested, nor
1784         is it necessary for File objects, since File objects correspond to a native filesystem path.
1785
1786         Test: fast/events/drag-dataTransferItemList-file-handling.html
1787
1788         * platform/chromium/DataTransferItemListChromium.cpp:
1789         (WebCore::DataTransferItemListChromium::add):
1790
1791 2012-03-23  Zan Dobersek  <zandobersek@gmail.com>
1792
1793         [GObject bindings] Supplemental interfaces are not disabled with the "Conditional" attribute
1794         https://bugs.webkit.org/show_bug.cgi?id=80030
1795
1796         Reviewed by Martin Robinson.
1797
1798         Changes in CodeGeneratorGObject.pm:
1799         - group implementation of private helpers and guard them inside
1800         an ifdef if a root conditional attribute is present.
1801         - always define the type of a GObject binding, even if the root
1802         conditional feature is not enabled
1803         - the methods are generated as well, but are simply stubs if the
1804         feature is not enabled, throwing a warning upon interaction.
1805         - if the method itself is guarded by a conditional attribute,
1806         the stub implementation gains one more level of depth, throwing
1807         a warning if the method's conditional feature is not enabled
1808         but the root conditional feature is.
1809         - small style fixes in random places.
1810
1811         Also changed are GObject baselines for binding tests.
1812
1813         No new tests - no new testable functionality.
1814
1815         * bindings/gobject/GNUmakefile.am:
1816         * bindings/scripts/CodeGeneratorGObject.pm:
1817         (HumanReadableConditional):
1818         (GenerateConditionalWarn):
1819         (GenerateProperty):
1820         (GenerateProperties):
1821         (GenerateFunction):
1822         (GenerateFunctions):
1823         (GenerateCFile):
1824         (GenerateEventTargetIface):
1825         (Generate):
1826         (WriteData):
1827         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
1828         (WebKit):
1829         (WebKit::kit):
1830         (WebKit::wrapFloat64Array):
1831         (webkit_dom_float64array_finalize):
1832         (webkit_dom_float64array_foo):
1833         * bindings/scripts/test/GObject/WebKitDOMFloat64ArrayPrivate.h:
1834         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
1835         (WebKit):
1836         (WebKit::kit):
1837         (WebKit::wrapTestActiveDOMObject):
1838         (webkit_dom_test_active_dom_object_finalize):
1839         (webkit_dom_test_active_dom_object_exciting_function):
1840         (webkit_dom_test_active_dom_object_post_message):
1841         (webkit_dom_test_active_dom_object_get_exciting_attr):
1842         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObjectPrivate.h:
1843         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
1844         (WebKit):
1845         (WebKit::kit):
1846         (WebKit::core):
1847         (WebKit::wrapTestCallback):
1848         (webkit_dom_test_callback_finalize):
1849         (webkit_dom_test_callback_callback_with_no_param):
1850         (webkit_dom_test_callback_callback_with_class1param):
1851         (webkit_dom_test_callback_callback_with_class2param):
1852         (webkit_dom_test_callback_callback_with_non_bool_return_type):
1853         (webkit_dom_test_callback_callback_with_string_list):
1854         * bindings/scripts/test/GObject/WebKitDOMTestCallbackPrivate.h:
1855         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
1856         (WebKit):
1857         (WebKit::kit):
1858         (WebKit::wrapTestCustomNamedGetter):
1859         (webkit_dom_test_custom_named_getter_finalize):
1860         (webkit_dom_test_custom_named_getter_another_function):
1861         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetterPrivate.h:
1862         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
1863         (WebKit):
1864         (WebKit::kit):
1865         (WebKit::wrapTestEventConstructor):
1866         (webkit_dom_test_event_constructor_finalize):
1867         (webkit_dom_test_event_constructor_get_attr1):
1868         (webkit_dom_test_event_constructor_get_attr2):
1869         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructorPrivate.h:
1870         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
1871         (WebKit):
1872         (WebKit::core):
1873         (WebKit::wrapTestEventTarget):
1874         (webkit_dom_test_event_target_finalize):
1875         (webkit_dom_test_event_target_item):
1876         (webkit_dom_test_event_target_dispatch_event):
1877         * bindings/scripts/test/GObject/WebKitDOMTestEventTargetPrivate.h:
1878         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
1879         (WebKit):
1880         (WebKit::kit):
1881         (WebKit::core):
1882         (WebKit::wrapTestInterface):
1883         (webkit_dom_test_interface_finalize):
1884         (webkit_dom_test_interface_supplemental_method1):
1885         (webkit_dom_test_interface_supplemental_method2):
1886         (webkit_dom_test_interface_supplemental_method4):
1887         (webkit_dom_test_interface_get_supplemental_str1):
1888         (webkit_dom_test_interface_get_supplemental_str2):
1889         (webkit_dom_test_interface_set_supplemental_str2):
1890         (webkit_dom_test_interface_get_supplemental_node):
1891         (webkit_dom_test_interface_set_supplemental_node):
1892         * bindings/scripts/test/GObject/WebKitDOMTestInterfacePrivate.h:
1893         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
1894         (WebKit):
1895         (WebKit::kit):
1896         (WebKit::wrapTestMediaQueryListListener):
1897         (webkit_dom_test_media_query_list_listener_finalize):
1898         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListenerPrivate.h:
1899         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
1900         (WebKit):
1901         (WebKit::kit):
1902         (WebKit::wrapTestNamedConstructor):
1903         (webkit_dom_test_named_constructor_finalize):
1904         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructorPrivate.h:
1905         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
1906         (WebKit):
1907         (WebKit::kit):
1908         (WebKit::core):
1909         (WebKit::wrapTestObj):
1910         (webkit_dom_test_obj_finalize):
1911         (webkit_dom_test_obj_set_property):
1912         (webkit_dom_test_obj_get_property):
1913         (webkit_dom_test_obj_constructed):
1914         (webkit_dom_test_obj_class_init):
1915         (webkit_dom_test_obj_init):
1916         (webkit_dom_test_obj_void_method):
1917         (webkit_dom_test_obj_void_method_with_args):
1918         (webkit_dom_test_obj_int_method):
1919         (webkit_dom_test_obj_int_method_with_args):
1920         (webkit_dom_test_obj_obj_method):
1921         (webkit_dom_test_obj_obj_method_with_args):
1922         (webkit_dom_test_obj_method_with_sequence_arg):
1923         (webkit_dom_test_obj_method_that_requires_all_args_and_throws):
1924         (webkit_dom_test_obj_serialized_value):
1925         (webkit_dom_test_obj_idb_key):
1926         (webkit_dom_test_obj_options_object):
1927         (webkit_dom_test_obj_method_with_exception):
1928         (webkit_dom_test_obj_with_script_state_void):
1929         (webkit_dom_test_obj_with_script_state_obj):
1930         (webkit_dom_test_obj_with_script_state_void_exception):
1931         (webkit_dom_test_obj_with_script_state_obj_exception):
1932         (webkit_dom_test_obj_with_script_execution_context):
1933         (webkit_dom_test_obj_with_script_execution_context_and_script_state):
1934         (webkit_dom_test_obj_with_script_execution_context_and_script_state_obj_exception):
1935         (webkit_dom_test_obj_with_script_execution_context_and_script_state_with_spaces):
1936         (webkit_dom_test_obj_method_with_optional_arg):
1937         (webkit_dom_test_obj_method_with_non_optional_arg_and_optional_arg):
1938         (webkit_dom_test_obj_method_with_non_optional_arg_and_two_optional_args):
1939         (webkit_dom_test_obj_method_with_optional_string):
1940         (webkit_dom_test_obj_method_with_optional_string_is_undefined):
1941         (webkit_dom_test_obj_method_with_optional_string_is_null_string):
1942         (webkit_dom_test_obj_conditional_method1):
1943         (webkit_dom_test_obj_conditional_method2):
1944         (webkit_dom_test_obj_conditional_method3):
1945         (webkit_dom_test_obj_class_method):
1946         (webkit_dom_test_obj_class_method_with_optional):
1947         (webkit_dom_test_obj_overloaded_method1):
1948         (webkit_dom_test_obj_convert1):
1949         (webkit_dom_test_obj_convert2):
1950         (webkit_dom_test_obj_convert3):
1951         (webkit_dom_test_obj_convert4):
1952         (webkit_dom_test_obj_convert5):
1953         (webkit_dom_test_obj_mutable_point_function):
1954         (webkit_dom_test_obj_immutable_point_function):
1955         (webkit_dom_test_obj_orange):
1956         (webkit_dom_test_obj_strict_function):
1957         (webkit_dom_test_obj_get_read_only_int_attr):
1958         (webkit_dom_test_obj_get_read_only_string_attr):
1959         (webkit_dom_test_obj_get_read_only_test_obj_attr):
1960         (webkit_dom_test_obj_get_short_attr):
1961         (webkit_dom_test_obj_set_short_attr):
1962         (webkit_dom_test_obj_get_unsigned_short_attr):
1963         (webkit_dom_test_obj_set_unsigned_short_attr):
1964         (webkit_dom_test_obj_get_int_attr):
1965         (webkit_dom_test_obj_set_int_attr):
1966         (webkit_dom_test_obj_get_long_long_attr):
1967         (webkit_dom_test_obj_set_long_long_attr):
1968         (webkit_dom_test_obj_get_unsigned_long_long_attr):
1969         (webkit_dom_test_obj_set_unsigned_long_long_attr):
1970         (webkit_dom_test_obj_get_string_attr):
1971         (webkit_dom_test_obj_set_string_attr):
1972         (webkit_dom_test_obj_get_test_obj_attr):
1973         (webkit_dom_test_obj_set_test_obj_attr):
1974         (webkit_dom_test_obj_get_xml_obj_attr):
1975         (webkit_dom_test_obj_set_xml_obj_attr):
1976         (webkit_dom_test_obj_get_create):
1977         (webkit_dom_test_obj_set_create):
1978         (webkit_dom_test_obj_get_reflected_string_attr):
1979         (webkit_dom_test_obj_set_reflected_string_attr):
1980         (webkit_dom_test_obj_get_reflected_integral_attr):
1981         (webkit_dom_test_obj_set_reflected_integral_attr):
1982         (webkit_dom_test_obj_get_reflected_unsigned_integral_attr):
1983         (webkit_dom_test_obj_set_reflected_unsigned_integral_attr):
1984         (webkit_dom_test_obj_get_reflected_boolean_attr):
1985         (webkit_dom_test_obj_set_reflected_boolean_attr):
1986         (webkit_dom_test_obj_get_reflected_url_attr):
1987         (webkit_dom_test_obj_set_reflected_url_attr):
1988         (webkit_dom_test_obj_get_reflected_custom_integral_attr):
1989         (webkit_dom_test_obj_set_reflected_custom_integral_attr):
1990         (webkit_dom_test_obj_get_reflected_custom_boolean_attr):
1991         (webkit_dom_test_obj_set_reflected_custom_boolean_attr):
1992         (webkit_dom_test_obj_get_reflected_custom_url_attr):
1993         (webkit_dom_test_obj_set_reflected_custom_url_attr):
1994         (webkit_dom_test_obj_get_attr_with_getter_exception):
1995         (webkit_dom_test_obj_set_attr_with_getter_exception):
1996         (webkit_dom_test_obj_get_attr_with_setter_exception):
1997         (webkit_dom_test_obj_set_attr_with_setter_exception):
1998         (webkit_dom_test_obj_get_string_attr_with_getter_exception):
1999         (webkit_dom_test_obj_set_string_attr_with_getter_exception):
2000         (webkit_dom_test_obj_get_string_attr_with_setter_exception):
2001         (webkit_dom_test_obj_set_string_attr_with_setter_exception):
2002         (webkit_dom_test_obj_get_with_script_state_attribute):
2003         (webkit_dom_test_obj_set_with_script_state_attribute):
2004         (webkit_dom_test_obj_get_with_script_execution_context_attribute):
2005         (webkit_dom_test_obj_set_with_script_execution_context_attribute):
2006         (webkit_dom_test_obj_get_with_script_state_attribute_raises):
2007         (webkit_dom_test_obj_set_with_script_state_attribute_raises):
2008         (webkit_dom_test_obj_get_with_script_execution_context_attribute_raises):
2009         (webkit_dom_test_obj_set_with_script_execution_context_attribute_raises):
2010         (webkit_dom_test_obj_get_with_script_execution_context_and_script_state_attribute):
2011         (webkit_dom_test_obj_set_with_script_execution_context_and_script_state_attribute):
2012         (webkit_dom_test_obj_get_with_script_execution_context_and_script_state_attribute_raises):
2013         (webkit_dom_test_obj_set_with_script_execution_context_and_script_state_attribute_raises):
2014         (webkit_dom_test_obj_get_with_script_execution_context_and_script_state_with_spaces_attribute):
2015         (webkit_dom_test_obj_set_with_script_execution_context_and_script_state_with_spaces_attribute):
2016         (webkit_dom_test_obj_get_conditional_attr1):
2017         (webkit_dom_test_obj_set_conditional_attr1):
2018         (webkit_dom_test_obj_get_conditional_attr2):
2019         (webkit_dom_test_obj_set_conditional_attr2):
2020         (webkit_dom_test_obj_get_conditional_attr3):
2021         (webkit_dom_test_obj_set_conditional_attr3):
2022         (webkit_dom_test_obj_get_content_document):
2023         (webkit_dom_test_obj_get_mutable_point):
2024         (webkit_dom_test_obj_set_mutable_point):
2025         (webkit_dom_test_obj_get_immutable_point):
2026         (webkit_dom_test_obj_set_immutable_point):
2027         (webkit_dom_test_obj_get_strict_float):
2028         (webkit_dom_test_obj_set_strict_float):
2029         (webkit_dom_test_obj_get_description):
2030         (webkit_dom_test_obj_get_id):
2031         (webkit_dom_test_obj_set_id):
2032         (webkit_dom_test_obj_get_hash):
2033         * bindings/scripts/test/GObject/WebKitDOMTestObjPrivate.h:
2034         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
2035         (WebKit):
2036         (WebKit::kit):
2037         (WebKit::core):
2038         (WebKit::wrapTestSerializedScriptValueInterface):
2039         (webkit_dom_test_serialized_script_value_interface_finalize):
2040         (webkit_dom_test_serialized_script_value_interface_accept_transfer_list):
2041         (webkit_dom_test_serialized_script_value_interface_multi_transfer_list):
2042         (webkit_dom_test_serialized_script_value_interface_get_value):
2043         (webkit_dom_test_serialized_script_value_interface_set_value):
2044         (webkit_dom_test_serialized_script_value_interface_get_readonly_value):
2045         (webkit_dom_test_serialized_script_value_interface_get_cached_value):
2046         (webkit_dom_test_serialized_script_value_interface_set_cached_value):
2047         (webkit_dom_test_serialized_script_value_interface_get_cached_readonly_value):
2048         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterfacePrivate.h:
2049
2050 2012-03-23  Dana Jansens  <danakj@chromium.org>
2051
2052         [chromium] Record painted pixel counts for measuring effectiveness of per-tile painting
2053         https://bugs.webkit.org/show_bug.cgi?id=82057
2054
2055         Reviewed by Adrienne Walker.
2056
2057         Adds painted pixel metrics to CCOverdrawMetrics class, and calls in
2058         to report painted areas when updating tiles in the TiledLayerChromium
2059         class.
2060
2061         Unit test: TiledLayerChromiumTest.opaqueContentsRegion
2062                    TiledLayerChromiumTest.pixelsPaintedMetrics
2063
2064         * platform/graphics/chromium/TiledLayerChromium.cpp:
2065         (WebCore::TiledLayerChromium::prepareToUpdateTiles):
2066         * platform/graphics/chromium/cc/CCOverdrawMetrics.cpp:
2067         (WebCore::CCOverdrawMetrics::CCOverdrawMetrics):
2068         (WebCore::CCOverdrawMetrics::didPaint):
2069         (WebCore):
2070         (WebCore::CCOverdrawMetrics::recordMetricsInternal):
2071         * platform/graphics/chromium/cc/CCOverdrawMetrics.h:
2072         (CCOverdrawMetrics):
2073         (WebCore::CCOverdrawMetrics::pixelsPainted):
2074
2075 2012-03-23  Abhishek Arya  <inferno@chromium.org>
2076
2077         Crash in RenderBlock::splitBlocks.
2078         https://bugs.webkit.org/show_bug.cgi?id=81926
2079
2080         Reviewed by Julien Chaffraix.
2081
2082         We are updating the :after content before calling splitFlow. The :after content
2083         gets blown away since it will go to the continuation. beforeChild was earlier
2084         set to the first child. Being the last anonymous block, its children gets pulled
2085         up in collapseAnonymousBoxChild and it gets destroyed. So, we need to update
2086         beforeChild value. 
2087
2088         Test: fast/multicol/span/update-after-content-before-child-crash.html
2089
2090         * rendering/RenderBlock.cpp:
2091         (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
2092
2093 2012-03-23  Dana Jansens  <danakj@chromium.org>
2094
2095         [chromium] Improved composited debug borders
2096         https://bugs.webkit.org/show_bug.cgi?id=82071
2097
2098         Reviewed by Adrienne Walker.
2099
2100         Fix the problem with missing debug borders. Since we append quads
2101         to the list front to back now, we draw the quads in the list from
2102         back to front of the list. Which means if the debug quad is added
2103         after the layer it is drawing around, the layer can draw over top
2104         of its debug quad. Reverse the ordering when appending to fix it.
2105
2106         Make the border red around tiles that are checkerboarded. Missing
2107         tiles in non-root layers are drawn clear, so this makes them more
2108         visible.
2109
2110         Put a blue border around each render surface, and a purple border
2111         on their replicas.
2112
2113         No new tests.
2114
2115         * platform/graphics/chromium/cc/CCRenderPass.cpp:
2116         (WebCore):
2117         (WebCore::CCRenderPass::appendQuadsForLayer):
2118         (WebCore::CCRenderPass::appendQuadsForRenderSurfaceLayer):
2119         * platform/graphics/chromium/cc/CCRenderSurface.cpp:
2120         (WebCore::CCRenderSurface::hasReplica):
2121         (WebCore):
2122         (WebCore::CCRenderSurface::createReplicaSharedQuadState):
2123         * platform/graphics/chromium/cc/CCRenderSurface.h:
2124         (CCRenderSurface):
2125         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
2126         (WebCore):
2127         (WebCore::CCTiledLayerImpl::appendQuads):
2128
2129 2012-03-23  Simon Fraser  <simon.fraser@apple.com>
2130
2131         Move code that calls setAcceleratesDrawing() on GraphicsLayers into RenderLayerBacking
2132         https://bugs.webkit.org/show_bug.cgi?id=82092
2133
2134         Reviewed by Dean Jackson.
2135
2136         A RenderLayerBacking manages several GraphicsLayers, but RenderLayerCompositor
2137         was only calling setAcceleratesDrawing() on the one it knows about. Fix by moving
2138         this setting code down into RenderLayerBacking.
2139         
2140         RenderLayerCompositor now caches the setAcceleratesDrawing setting, as it does
2141         for other compositing-related settings, so that RenderLayerBacking doesn't have
2142         to grovel for Settings every time.
2143
2144         * rendering/RenderLayerBacking.cpp:
2145         (WebCore::RenderLayerBacking::createGraphicsLayer):
2146         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
2147         * rendering/RenderLayerCompositor.cpp:
2148         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
2149         (WebCore::RenderLayerCompositor::cacheAcceleratedCompositingFlags):
2150         (WebCore::RenderLayerCompositor::updateBacking):
2151         * rendering/RenderLayerCompositor.h:
2152         (WebCore::RenderLayerCompositor::acceleratedDrawingEnabled):
2153         (RenderLayerCompositor):
2154
2155 2012-03-23  Beth Dakin  <bdakin@apple.com>
2156
2157         https://bugs.webkit.org/show_bug.cgi?id=82083
2158
2159         Rubber-stamped by Simon Fraser.
2160
2161         This patch is just a name change. getExistingScrollAnimator() (which was 
2162         added earlier today) is now existingScrollAnimator().
2163         * loader/FrameLoader.cpp:
2164         (WebCore::FrameLoader::transitionToCommitted):
2165         * page/EventHandler.cpp:
2166         (WebCore::EventHandler::handleGestureTapDown):
2167         * page/FrameView.cpp:
2168         (WebCore::FrameView::setAnimatorsAreActive):
2169         * platform/ScrollView.cpp:
2170         (WebCore::ScrollView::updateScrollbars):
2171         * platform/ScrollableArea.cpp:
2172         (WebCore::ScrollableArea::willStartLiveResize):
2173         (WebCore::ScrollableArea::willEndLiveResize):
2174         (WebCore::ScrollableArea::contentAreaWillPaint):
2175         (WebCore::ScrollableArea::mouseEnteredContentArea):
2176         (WebCore::ScrollableArea::mouseExitedContentArea):
2177         (WebCore::ScrollableArea::mouseMovedInContentArea):
2178         (WebCore::ScrollableArea::contentAreaDidShow):
2179         (WebCore::ScrollableArea::contentAreaDidHide):
2180         (WebCore::ScrollableArea::contentsResized):
2181         (WebCore::ScrollableArea::serviceScrollAnimations):
2182         * platform/ScrollableArea.h:
2183         (WebCore::ScrollableArea::existingScrollAnimator):
2184
2185 2012-03-23  Abhishek Arya  <inferno@chromium.org>
2186
2187         Crash due to accessing removed parent lineboxes when clearing selection.
2188         https://bugs.webkit.org/show_bug.cgi?id=81359
2189
2190         Reviewed by Eric Seidel.
2191
2192         Similar to r110323, adds the canUpdateSelectionOnRootLineBoxes
2193         check to more places.
2194
2195         Test: editing/selection/clear-selection-crash.html
2196
2197         * rendering/RenderObject.cpp:
2198         (WebCore::RenderObject::canUpdateSelectionOnRootLineBoxes):
2199         * rendering/RenderSelectionInfo.h:
2200         (WebCore::RenderSelectionInfo::RenderSelectionInfo):
2201         (WebCore::RenderBlockSelectionInfo::RenderBlockSelectionInfo):
2202
2203 2012-03-23  Beth Dakin  <bdakin@apple.com>
2204
2205         https://bugs.webkit.org/show_bug.cgi?id=82083
2206         Too many ScrollAnimators are allocated on pages with frames
2207
2208         Reviewed by Geoffrey Garen.
2209
2210         This patch adds a new getter to ScrollableArea called 
2211         getExistingScrollAnimator() unlike scrollAnimator() this new function will 
2212         just return null if there is not already a ScrollAnimator. Callers should use 
2213         this new function when they have business with ScrollAnimator that does not 
2214         need to do anything when there are no scrollbars.
2215         * loader/FrameLoader.cpp:
2216         (WebCore::FrameLoader::transitionToCommitted):
2217         * page/EventHandler.cpp:
2218         (WebCore::EventHandler::handleGestureTapDown):
2219         * page/FrameView.cpp:
2220         (WebCore::FrameView::setAnimatorsAreActive):
2221         * platform/ScrollView.cpp:
2222         (WebCore::ScrollView::updateScrollbars):
2223         * platform/ScrollableArea.cpp:
2224         (WebCore::ScrollableArea::willStartLiveResize):
2225         (WebCore::ScrollableArea::willEndLiveResize):
2226         (WebCore::ScrollableArea::contentAreaWillPaint):
2227         (WebCore::ScrollableArea::mouseEnteredContentArea):
2228         (WebCore::ScrollableArea::mouseExitedContentArea):
2229         (WebCore::ScrollableArea::mouseMovedInContentArea):
2230         (WebCore::ScrollableArea::contentAreaDidShow):
2231         (WebCore::ScrollableArea::contentAreaDidHide):
2232         (WebCore::ScrollableArea::willRemoveHorizontalScrollbar):
2233         (WebCore::ScrollableArea::contentsResized):
2234         (WebCore::ScrollableArea::serviceScrollAnimations):
2235         * platform/ScrollableArea.h:
2236         (ScrollableArea):
2237         (WebCore::ScrollableArea::getExistingScrollAnimator):
2238
2239 2012-03-23  Eric Carlson  <eric.carlson@apple.com>
2240
2241         Deal with DOM modifications when evaluating source elements.
2242         https://bugs.webkit.org/show_bug.cgi?id=81163
2243
2244         Reviewed by Alexey Proskuryakov.
2245
2246         Test: media/video-beforeload-remove-source.html
2247
2248         * dom/ContainerNode.cpp: Make NodeVector and collectNodes public, renamed as getChildNodes.
2249         (WebCore::ContainerNode::takeAllChildrenFrom): collectNodes -> getChildNodes.
2250         (WebCore::ContainerNode::willRemove): collectNodes -> getChildNodes.
2251         (WebCore::ContainerNode::willRemoveChildren): collectNodes -> getChildNodes.
2252         (WebCore::ContainerNode::insertedIntoDocument): collectNodes -> getChildNodes.
2253         (WebCore::ContainerNode::removedFromDocument): collectNodes -> getChildNodes.
2254         * dom/ContainerNode.h:
2255         (WebCore::getChildNodes):
2256
2257         * editing/ReplaceSelectionCommand.cpp: Remove unused NodeVector declaration.
2258
2259         * html/HTMLMediaElement.cpp:
2260         (WebCore::HTMLMediaElement::HTMLMediaElement): m_nextChildNodeToConsider and m_currentSourceNode
2261             are now RefPtrs.
2262         (WebCore::HTMLMediaElement::loadTimerFired): Protect HTMLMediaElement from being deleted during
2263             a DOM modification during an event callback.
2264         (WebCore::HTMLMediaElement::load): Ditto.
2265         (WebCore::HTMLMediaElement::selectMediaResource): Set m_nextChildNodeToConsider to the first
2266             child node, it will be the first node considered.
2267         (WebCore::HTMLMediaElement::havePotentialSourceChild): m_nextChildNodeToConsider and m_currentSourceNode
2268             are now RefPtrs.
2269         (WebCore::HTMLMediaElement::selectNextSourceChild): Collect all child nodes in a vector before
2270             looking for <source> nodes because 'beforeload' event handlers can mutate the DOM. Don't
2271             use a <source> that is no longer a child node after 'beforeload'. Use 0 to represent the end
2272             of the child node list because m_nextChildNodeToConsider is now a RefPtr so using the previous 
2273             sentinel, "this", would cause a retain cycle.
2274         (WebCore::HTMLMediaElement::sourceWasAdded):  m_nextChildNodeToConsider and m_currentSourceNode
2275             are now RefPtrs.
2276         (WebCore::HTMLMediaElement::sourceWillBeRemoved): Ditto.
2277         (WebCore::HTMLMediaElement::getPluginProxyParams): Protect HTMLMediaElement from being deleted during
2278             a DOM modification during an event callback.
2279         * html/HTMLMediaElement.h:
2280
2281 2012-03-23  Dean Jackson  <dino@apple.com>
2282
2283         Disable CSS_SHADERS in Apple builds
2284         https://bugs.webkit.org/show_bug.cgi?id=81996
2285
2286         Reviewed by Simon Fraser.
2287
2288         Remove ENABLE_CSS_SHADERS from FeatureDefines. It's now in Platform.h.
2289
2290         * Configurations/FeatureDefines.xcconfig:
2291
2292 2012-03-23  Dave Michael  <dmichael@chromium.org>
2293
2294         Relanding(r111754): HTMLPluginElement is not destroyed on reload or navigation if getNPObject is called
2295         https://bugs.webkit.org/show_bug.cgi?id=80428
2296
2297         Reviewed by Eric Seidel and Ryosuke Niwa.
2298
2299         Make HTMLPluginElement release its m_NPObject in detach() to break a
2300         reference-counting cycle that happens on reload or navigation. With this
2301         change, HTMLPlugInElement::removedFromDocument is unnecessary, so it
2302         was removed. Note that Releasing m_NPObject does not result in a call to
2303         the plugin; it simply releases a reference count on the wrapper object
2304         for this HTMLPlugInElement. (The plugin's NPP_Deallocate is invoked
2305         when the render tree is destroyed, when PluginView calls
2306         PluginPackage::unload.) Thus, it is safe to release m_NPObject in
2307         detach, because it can not result in layout or style changes.
2308
2309         Also added numberOfLiveNodes() and numberOfLiveDocuments() to
2310         window.internals to enable testing.
2311
2312         Test: plugins/netscape-dom-access-and-reload.html
2313
2314         * WebCore.exp.in:
2315         * html/HTMLPlugInElement.cpp:
2316         (WebCore::HTMLPlugInElement::detach):
2317         * html/HTMLPlugInElement.h:
2318         (HTMLPlugInElement):
2319         * testing/Internals.cpp:
2320         (WebCore):
2321         (WebCore::Internals::numberOfLiveNodes):
2322         (WebCore::Internals::numberOfLiveDocuments):
2323         * testing/Internals.h:
2324         (Internals):
2325         * testing/Internals.idl:
2326
2327 2012-03-23  Ryosuke Niwa  <rniwa@webkit.org>
2328
2329         CSSParser doesn't set border-*-width/style/color to initial by border shorthand property
2330         https://bugs.webkit.org/show_bug.cgi?id=82040
2331
2332         Reviewed by Antti Koivisto.
2333
2334         The border shorthand property sets values for border-width, border-style, and border-color shorthand properties.
2335         While CSSParser::parseValue can process these shorthand properties properly and set the longhand properties
2336         such as border-top-width, border-right-width, ... border-left-color, CSSParser::addProperty can't and the
2337         initialization in parseShorthand fails for the border property.
2338
2339         Fixed the bug by explicitly initializing longhand properties.
2340
2341         Changing the behavior here is unlikely to break the Web since our behavior already differs from that of Firefox
2342         and Internet Explorer. Both of those browsers return the actual initial values such as "medium" and "currentColor".
2343         This discrepancy is tracked by https://bugs.webkit.org/show_bug.cgi?id=82078.
2344
2345         Test: fast/css/border-shorthand-initialize-longhands.html
2346
2347         * css/CSSParser.cpp:
2348         (WebCore::CSSParser::parseValue): Uses borderAbridgedLonghand.
2349         (WebCore::CSSParser::parseShorthand): Uses longhand properties for initialization if one is available.
2350         This allows us to initialize multiple properties (e.g. border-*-color) for a single property missing in the set.
2351         * css/CSSPropertyLonghand.cpp:
2352         (WebCore::borderAbridgedLonghand): Added. The longhand here (border-width, border-style, border-color) is
2353         "abridged" in the sense that they're still shorthands.
2354         * css/CSSPropertyLonghand.h:
2355         (WebCore::CSSPropertyLonghand::CSSPropertyLonghand):
2356         (CSSPropertyLonghand): Added the version that takes longhand instances for initialization purposes.
2357         (WebCore::CSSPropertyLonghand::longhandsForInitialization):
2358
2359 2012-03-23  Tony Chang  <tony@chromium.org>
2360
2361         [chromium] rename newwtf target back to wtf
2362         https://bugs.webkit.org/show_bug.cgi?id=82064
2363
2364         Reviewed by Adam Barth.
2365
2366         No new tests, only renaming a build target.
2367
2368         * WebCore.gyp/WebCore.gyp:
2369
2370 2012-03-23  Adrienne Walker  <enne@google.com>
2371
2372         [chromium] Turn off painting of scrollbars on compositor thread for unsupported platforms
2373         https://bugs.webkit.org/show_bug.cgi?id=82066
2374
2375         Reviewed by James Robinson.
2376
2377         With threaded compositing, OSX will crash and Windows will have black
2378         scrollbars. Fix that by reverting to the previosu behavior of updating
2379         scrollbars on the main thread instead.
2380
2381         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
2382         (WebCore::scrollbarLayerDidChange):
2383
2384 2012-03-23  Dan Bernstein  <mitz@apple.com>
2385
2386         <rdar://problem/7883987> ASSERTION FAILED: ASSERT(input == AnimationStateInputEndTimerFired || input == AnimationStateInputPlayStatePaused) in AnimationBase::updateStateMachine causing multiple "crashes" on Lion Intel Debug WebKit testers
2387         https://bugs.webkit.org/show_bug.cgi?id=81351
2388
2389         Rubber-stamped by Jessie Berlin.
2390
2391         * page/animation/AnimationBase.cpp:
2392         (WebCore::AnimationBase::updateStateMachine): Replaced the assertion with a LOG_ERROR so that
2393         the issue is still noticeable, but it does not automatically make the debug bots red.
2394
2395 2012-03-23  Mike Lawther  <mikelawther@chromium.org>
2396
2397         CSS3 calc: image sizing works with mixed percentage/absolute
2398         https://bugs.webkit.org/show_bug.cgi?id=82017
2399
2400         Reviewed by Ojan Vafai.
2401
2402         Test: css3/calc/img-size-expected.html
2403
2404         * rendering/RenderBox.cpp:
2405         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
2406         (WebCore::RenderBox::computeReplacedLogicalHeightUsing):
2407
2408 2012-03-23  Julien Chaffraix  <jchaffraix@webkit.org>
2409
2410         REGRESSION(107971): Google Voice contact list is broken in WebKit due to badly allocating the extra height
2411         https://bugs.webkit.org/show_bug.cgi?id=81826
2412
2413         Reviewed by Tony Chang.
2414
2415         Covered by tables/mozilla/bugs/bug27038-{1|2}.html.
2416
2417         This partly reverts r107971: the extra logical height distribution change was not needed
2418         to fix the bug (it is needed by the test though). We revert to giving all the extra height
2419         to the first tbody and not the first section.
2420
2421         This is broken but unfortunately some websites are relying on that. Getting a real
2422         distribution algorithm is covered by bug 81824. However this is super tricky to get
2423         right and I did not want to add more compatibility risks until I have something solid.
2424
2425         * rendering/RenderTable.cpp:
2426         (WebCore::RenderTable::distributeExtraLogicalHeight):
2427
2428 2012-03-23  Xingnan Wang  <xingnan.wang@intel.com>
2429
2430         Optimize for IPP in DirectConvolver::process()
2431         https://bugs.webkit.org/show_bug.cgi?id=80255
2432
2433         Reviewed by Chris Rogers.
2434
2435         Increase ~2X performance by conv() in IPP.
2436
2437         * platform/audio/DirectConvolver.cpp:
2438         (WebCore::DirectConvolver::DirectConvolver):
2439         (WebCore::DirectConvolver::process):
2440         * platform/audio/DirectConvolver.h:
2441         (DirectConvolver):
2442
2443 2012-03-23  Tommy Widenflycht  <tommyw@google.com>
2444
2445         MediaStream API (JSEP): Introducing PeerConnection00 and IceCallback
2446         https://bugs.webkit.org/show_bug.cgi?id=81657
2447
2448         Reviewed by Adam Barth.
2449
2450         Last major WebCore patch for the JSEP PeerConnection, together with the associated
2451         IceCallback (they both depend on each other and IceCallback has very few lines of real code).
2452
2453         My next patch after this one will do a major overhaul of the existing layout tests
2454         and add a few new ones.
2455
2456         * GNUmakefile.list.am:
2457         * Modules/mediastream/DOMWindowMediaStream.idl:
2458         * Modules/mediastream/IceCallback.h: Added.
2459         (WebCore):
2460         (IceCallback):
2461         (WebCore::IceCallback::~IceCallback):
2462         * Modules/mediastream/IceCallback.idl: Added.
2463         * Modules/mediastream/PeerConnection00.cpp: Added.
2464         (WebCore):
2465         (WebCore::PeerConnection00::create):
2466         (WebCore::PeerConnection00::PeerConnection00):
2467         (WebCore::PeerConnection00::~PeerConnection00):
2468         (WebCore::PeerConnection00::hasLocalAudioTrack):
2469         (WebCore::PeerConnection00::hasLocalVideoTrack):
2470         (WebCore::PeerConnection00::parseMediaHints):
2471         (WebCore::PeerConnection00::createOffer):
2472         (WebCore::PeerConnection00::createAnswer):
2473         (WebCore::PeerConnection00::setLocalDescription):
2474         (WebCore::PeerConnection00::setRemoteDescription):
2475         (WebCore::PeerConnection00::localDescription):
2476         (WebCore::PeerConnection00::remoteDescription):
2477         (WebCore::PeerConnection00::startIce):
2478         (WebCore::PeerConnection00::processIceMessage):
2479         (WebCore::PeerConnection00::readyState):
2480         (WebCore::PeerConnection00::iceState):
2481         (WebCore::PeerConnection00::addStream):
2482         (WebCore::PeerConnection00::removeStream):
2483         (WebCore::PeerConnection00::localStreams):
2484         (WebCore::PeerConnection00::remoteStreams):
2485         (WebCore::PeerConnection00::close):
2486         (WebCore::PeerConnection00::didGenerateIceCandidate):
2487         (WebCore::PeerConnection00::didChangeReadyState):
2488         (WebCore::PeerConnection00::didChangeIceState):
2489         (WebCore::PeerConnection00::didAddRemoteStream):
2490         (WebCore::PeerConnection00::didRemoveRemoteStream):
2491         (WebCore::PeerConnection00::interfaceName):
2492         (WebCore::PeerConnection00::scriptExecutionContext):
2493         (WebCore::PeerConnection00::stop):
2494         (WebCore::PeerConnection00::eventTargetData):
2495         (WebCore::PeerConnection00::ensureEventTargetData):
2496         (WebCore::PeerConnection00::changeReadyState):
2497         (WebCore::PeerConnection00::changeIceState):
2498         * Modules/mediastream/PeerConnection00.h: Added.
2499         (WebCore):
2500         (PeerConnection00):
2501         (WebCore::PeerConnection00::refEventTarget):
2502         (WebCore::PeerConnection00::derefEventTarget):
2503         * Modules/mediastream/PeerConnection00.idl: Added.
2504         * WebCore.gypi:
2505         * bindings/generic/RuntimeEnabledFeatures.h:
2506         (WebCore::RuntimeEnabledFeatures::webkitPeerConnection00Enabled):
2507         * bindings/js/JSPeerConnection00Custom.cpp: Added.
2508         (WebCore):
2509         (WebCore::JSPeerConnection00Constructor::constructJSPeerConnection00):
2510         * dom/EventTargetFactory.in:
2511
2512 2012-03-23  Adrienne Walker  <enne@google.com>
2513
2514         [chromium] Fix scrollbarLayerLostContext flaky test crash on 10.6
2515         https://bugs.webkit.org/show_bug.cgi?id=82062
2516
2517         Reviewed by James Robinson.
2518
2519         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
2520         (CCScrollbarLayerImpl):
2521
2522 2012-03-23  Tommy Widenflycht  <tommyw@google.com>
2523
2524         [chromium] MediaStream API (JSEP): Extending WebMediaStreamCenter
2525         https://bugs.webkit.org/show_bug.cgi?id=81924
2526
2527         Reviewed by Adam Barth.
2528
2529         Nothing to test, just moving methods.
2530
2531         * platform/mediastream/MediaStreamCenter.cpp:
2532         (WebCore::MediaStreamCenter::constructSDP):
2533         (WebCore):
2534
2535 2012-03-23  Sami Kyostila  <skyostil@chromium.org>
2536
2537         Reuse buffer allocation if canvas size does not change
2538         https://bugs.webkit.org/show_bug.cgi?id=80871
2539
2540         Reviewed by Stephen White.
2541
2542         If the user changes the width or height attributes of a canvas element,
2543         the contents of the canvas should be cleared and the context state
2544         should be reset. This has become a common idiom to clear the canvas
2545         "efficiently" at the start of a frame.
2546
2547         Previously, this code path triggered a full reallocation of the image
2548         buffer backing the canvas, leading to reduced performance. This patch
2549         implements an optimization where we reuse the previous image buffer
2550         allocation if the size of the canvas did not change. Also, instead of
2551         clearing the canvas every time its dimensions are touched, we only clear
2552         if anything has been drawn into the canvas since it was previously
2553         cleared.
2554
2555         Note that for now this optimization only applies for 2D canvases,
2556         since it is not entirely clear how touching the dimensions of a WebGL
2557         canvas should work.
2558
2559         Test: fast/canvas/canvas-resize-after-paint-without-layout.html +
2560               existing layout tests for canvas resetting.
2561
2562         * html/HTMLCanvasElement.cpp:
2563         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
2564         (WebCore::HTMLCanvasElement::reset):
2565         (WebCore::HTMLCanvasElement::createImageBuffer): Save the initial
2566         graphics context state so we can restore it without creating a new
2567         context.
2568         (WebCore::HTMLCanvasElement::clearImageBuffer):
2569         (WebCore):
2570         (WebCore::HTMLCanvasElement::clearCopiedImage):
2571         * html/HTMLCanvasElement.h:
2572         (HTMLCanvasElement):
2573         * html/canvas/CanvasRenderingContext2D.cpp:
2574         (WebCore::CanvasRenderingContext2D::reset): No need to notify the
2575         compositor when the context is reset, because clearing the image buffer
2576         does the same thing. We can also skip the notification if we did not
2577         have an image buffer at the time of the reset, because the reset will
2578         not have any visual impact in this case. Finally, if the canvas size
2579         did change, the notification is also unnecessary because of the call
2580         to RenderObject::repaint() from HTMLCanvasElement::reset().
2581
2582 2012-03-22  Martin Robinson  <mrobinson@igalia.com>
2583
2584         Fix some code generation warnings on GTK+.
2585
2586         Reviewed by Gustavo Noronha Silva.
2587
2588         No new tests. This just fixes warnings.
2589
2590         * GNUmakefile.am: Remove nonexistent directories from the list IDL directories.
2591
2592 2012-03-23  Sheriff Bot  <webkit.review.bot@gmail.com>
2593
2594         Unreviewed, rolling out r111751.
2595         http://trac.webkit.org/changeset/111751
2596         https://bugs.webkit.org/show_bug.cgi?id=82060
2597
2598         caused 15% page cycler regression for chromium-linux
2599         (Requested by eae on #webkit).
2600
2601         * css/CSSStyleSelector.cpp:
2602         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
2603
2604 2012-03-23  Kentaro Hara  <haraken@chromium.org>
2605
2606         Support [ImplementedAs] for attributes
2607         https://bugs.webkit.org/show_bug.cgi?id=81605
2608
2609         Reviewed by Adam Barth.
2610
2611         [ImplementedAs] just supports methods. [ImplementedAs] should support
2612         attributes too.
2613
2614         Explained here: https://trac.webkit.org/wiki/WebKitIDL#ImplementedAs
2615
2616         Test: bindings/scripts/test/TestObj.idl
2617
2618         * bindings/scripts/CodeGenerator.pm: Modified to support [ImplementedAs] for attributes.
2619         (AttributeNameForGetterAndSetter):
2620
2621         * bindings/scripts/test/TestObj.idl: Added a test case.
2622
2623         * bindings/scripts/test/CPP/WebDOMTestObj.cpp: Updated run-bindings-tests results.
2624         (WebDOMTestObj::strawberry):
2625         (WebDOMTestObj::setStrawberry):
2626         * bindings/scripts/test/CPP/WebDOMTestObj.h:
2627         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
2628         (webkit_dom_test_obj_get_strawberry):
2629         (webkit_dom_test_obj_set_strawberry):
2630         (webkit_dom_test_obj_get_property):
2631         (webkit_dom_test_obj_class_init):
2632         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
2633         * bindings/scripts/test/JS/JSTestObj.cpp:
2634         (WebCore):
2635         (WebCore::jsTestObjStrawberry):
2636         (WebCore::setJSTestObjStrawberry):
2637         * bindings/scripts/test/JS/JSTestObj.h:
2638         (WebCore):
2639         * bindings/scripts/test/ObjC/DOMTestObj.h:
2640         * bindings/scripts/test/ObjC/DOMTestObj.mm:
2641         (-[DOMTestObj strawberry]):
2642         (-[DOMTestObj setStrawberry:]):
2643         * bindings/scripts/test/V8/V8TestObj.cpp:
2644         (WebCore::TestObjInternal::strawberryAttrGetter):
2645         (TestObjInternal):
2646         (WebCore::TestObjInternal::strawberryAttrSetter):
2647         (WebCore):
2648
2649 2012-03-23  Tommy Widenflycht  <tommyw@google.com>
2650
2651         The JSC code generator doesn't generate correct code for Constructors
2652         https://bugs.webkit.org/show_bug.cgi?id=82046
2653
2654         Reviewed by Kentaro Hara.
2655
2656         The main bulk of generated code for constructors uses the name jsConstructor
2657         for the created object, and then calls GenerateParametersCheck which generates
2658         code that uses the name castedThis.
2659
2660         * bindings/scripts/CodeGeneratorJS.pm:
2661         (GenerateConstructorDefinition):
2662         * bindings/scripts/test/JS/JSTestInterface.cpp:
2663         (WebCore::JSTestInterfaceConstructor::constructJSTestInterface):
2664         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
2665         (WebCore::JSTestNamedConstructorNamedConstructor::constructJSTestNamedConstructor):
2666         * bindings/scripts/test/JS/JSTestObj.cpp:
2667         (WebCore::JSTestObjConstructor::finishCreation):
2668         (WebCore::JSTestObjConstructor::constructJSTestObj):
2669         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
2670         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::constructJSTestSerializedScriptValueInterface):
2671         * bindings/scripts/test/TestObj.idl:
2672         * bindings/scripts/test/V8/V8TestObj.cpp:
2673         (WebCore::V8TestObj::constructorCallback):
2674
2675 2012-03-23  Tommy Widenflycht  <tommyw@google.com>
2676
2677         The JSC code generator can't handle boolean arguments for Callbacks
2678         https://bugs.webkit.org/show_bug.cgi?id=82045
2679
2680         Reviewed by Kentaro Hara.
2681
2682         CodeGeneratorJS.pm only handles DOMStrings and objects as arguments
2683         for a Callback, so I added support for boolean values as well.
2684
2685         * bindings/scripts/CodeGeneratorJS.pm:
2686         (GenerateCallbackImplementation):
2687         * bindings/scripts/test/CPP/WebDOMTestCallback.cpp:
2688         (WebDOMTestCallback::callbackWithBoolean):
2689         * bindings/scripts/test/CPP/WebDOMTestCallback.h:
2690         (WebDOMTestCallback):
2691         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
2692         (webkit_dom_test_callback_callback_with_boolean):
2693         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
2694         * bindings/scripts/test/JS/JSTestCallback.cpp:
2695         (WebCore::JSTestCallback::callbackWithBoolean):
2696         (WebCore):
2697         * bindings/scripts/test/JS/JSTestCallback.h:
2698         (JSTestCallback):
2699         * bindings/scripts/test/ObjC/DOMTestCallback.h:
2700         * bindings/scripts/test/ObjC/DOMTestCallback.mm:
2701         (-[DOMTestCallback callbackWithBoolean:]):
2702         * bindings/scripts/test/TestCallback.idl:
2703         * bindings/scripts/test/V8/V8TestCallback.cpp:
2704         (WebCore::V8TestCallback::callbackWithBoolean):
2705         (WebCore):
2706         * bindings/scripts/test/V8/V8TestCallback.h:
2707         (V8TestCallback):
2708
2709 2012-03-23  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2710
2711         Touch adjustment forgets some subtarget quads.
2712         https://bugs.webkit.org/show_bug.cgi?id=82044
2713
2714         Reviewed by Kenneth Rohde Christiansen.
2715
2716         Do not uncritically skip all nodes that are ancestors to other test results.
2717         Instead return the inner-most element if multiple nodes have the same distance.
2718
2719         Test: touchadjustment/block-testing.html
2720
2721         * page/TouchAdjustment.cpp:
2722         (WebCore::TouchAdjustment::compileSubtargetList):
2723         (WebCore::TouchAdjustment::findNodeWithLowestDistanceMetric):
2724
2725 2012-03-23  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2726
2727         TouchAdjustment does not correct for frame position
2728         https://bugs.webkit.org/show_bug.cgi?id=82043
2729
2730         Reviewed by Kenneth Rohde Christiansen.
2731
2732         Convert geometry to window coordinates before calculating distance.
2733
2734         Test: touchadjustment/iframe.html
2735
2736         * page/TouchAdjustment.cpp:
2737         (WebCore::TouchAdjustment::distanceSquaredToTargetCenterLine):
2738
2739 2012-03-23  Vlad Voicu  <vladv@rosedu.org>
2740
2741         Fixed minor WebInspector display issue
2742         Clicking on disabled sections in Styles Sidebar Pane creates new elements.
2743         https://bugs.webkit.org/show_bug.cgi?id=81925
2744
2745         Reviewed by Timothy Hatcher
2746
2747         No new tests should be required.
2748
2749         * inspector/front-end/StylesSidebarPane.js:
2750         (WebInspector.StylePropertiesSection.prototype._handleEmptySpaceClick):
2751         (WebInspector.StylePropertyTreeElement.prototype):
2752
2753 2012-03-23  Kentaro Hara  <haraken@chromium.org>
2754
2755         Unreviewed, rebaselined run-bindings-tests results.
2756
2757         * bindings/scripts/test/CPP/WebDOMTestObj.cpp:
2758         * bindings/scripts/test/CPP/WebDOMTestObj.h:
2759         * bindings/scripts/test/JS/JSTestObj.cpp:
2760         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
2761         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
2762         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
2763         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
2764         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
2765         * bindings/scripts/test/V8/V8TestObj.cpp:
2766         (WebCore::TestObjInternal::methodWithCallbackArgCallback):
2767         (WebCore::TestObjInternal::methodWithNonCallbackArgAndCallbackArgCallback):
2768         (WebCore::TestObjInternal::methodWithCallbackAndOptionalArgCallback):
2769         (WebCore::TestObjInternal::overloadedMethod5Callback):
2770         (WebCore::TestObjInternal::overloadedMethodCallback):
2771
2772 2012-03-23  Ryosuke Niwa  <rniwa@webkit.org>
2773
2774         cssText should use StringBuilder
2775         https://bugs.webkit.org/show_bug.cgi?id=82028
2776
2777         Reviewed by Hajime Morita.
2778
2779         Make StylePropertySet::asText more efficient by deploying StringBuilder;
2780         avoids heap churn by String::operator+ and String::operator+=.
2781
2782         * css/StylePropertySet.cpp:
2783         (WebCore::StylePropertySet::asText):
2784
2785 2012-03-23  Ryosuke Niwa  <rniwa@webkit.org>
2786
2787         REGRESSION(r111754): plugins/reloadplugins-and-pages.html fails on all platforms
2788         https://bugs.webkit.org/show_bug.cgi?id=82035
2789
2790         Rollout r111754 since it caused a test to fail and the test added by the patch
2791         is failing on Mac WebKit 2.
2792
2793         * WebCore.exp.in:
2794         * html/HTMLPlugInElement.cpp:
2795         (WebCore::HTMLPlugInElement::detach):
2796         (WebCore):
2797         (WebCore::HTMLPlugInElement::removedFromDocument):
2798         * html/HTMLPlugInElement.h:
2799         (HTMLPlugInElement):
2800         * testing/Internals.cpp:
2801         * testing/Internals.h:
2802         (Internals):
2803         * testing/Internals.idl:
2804
2805 2012-03-23  Adam Barth  <abarth@webkit.org>
2806
2807         Move Notifications APIs from DOMWindow.idl to DOMWindowNotifications.idl (Part 2)
2808         https://bugs.webkit.org/show_bug.cgi?id=82026
2809
2810         Reviewed by Kentaro Hara.
2811
2812         This patch removes DOMWindow::resetNotifications, which was unneeded
2813         special-case logic for clearing the notifications center.  The previous
2814         patch that tried to accomplish the same thing did not override
2815         willDetachPage, which is why it caused crashes.
2816
2817         There's actually a cleaner way to handle these cases, which will let us
2818         implement reconnectFrame, but that will need to wait for the next
2819         patch.
2820
2821         * notifications/DOMWindowNotifications.cpp:
2822         (WebCore::DOMWindowNotifications::DOMWindowNotifications):
2823         (WebCore::DOMWindowNotifications::from):
2824         (WebCore::DOMWindowNotifications::webkitNotifications):
2825         (WebCore):
2826         (WebCore::DOMWindowNotifications::disconnectFrame):
2827         (WebCore::DOMWindowNotifications::willDetachPage):
2828         (WebCore::DOMWindowNotifications::reset):
2829         * notifications/DOMWindowNotifications.h:
2830         (DOMWindowNotifications):
2831         * page/DOMWindow.cpp:
2832         (WebCore::DOMWindow::willDetachPage):
2833         (WebCore::DOMWindow::disconnectDOMWindowProperties):
2834         (WebCore::DOMWindow::clearDOMWindowProperties):
2835         * page/DOMWindow.h:
2836         (DOMWindow):
2837         * page/Frame.cpp:
2838         (WebCore::Frame::willDetachPage):
2839
2840 2012-03-22  Adam Barth  <abarth@webkit.org>
2841
2842         Move Notifications APIs from DOMWindow.idl to DOMWindowNotifications.idl (Part 1)
2843         https://bugs.webkit.org/show_bug.cgi?id=82015
2844
2845         Reviewed by Kentaro Hara.
2846
2847         This patch moves DOMWindow.webkitNotifications from DOMWindow.idl to
2848         DOMWindowNotificiations.idl in preparation for moving notificiations
2849         into Modules.
2850
2851         A future patch will remove DOMWindow::resetNotificaitions in favor of
2852         more general mechanisms.
2853
2854         * CMakeLists.txt:
2855         * DerivedSources.make:
2856         * DerivedSources.pri:
2857         * GNUmakefile.list.am:
2858         * Target.pri:
2859         * WebCore.gypi:
2860         * WebCore.vcproj/WebCore.vcproj:
2861         * WebCore.xcodeproj/project.pbxproj:
2862         * notifications/DOMWindowNotifications.cpp: Added.
2863         (WebCore):
2864         (WebCore::DOMWindowNotifications::DOMWindowNotifications):
2865         (WebCore::DOMWindowNotifications::~DOMWindowNotifications):
2866         (WebCore::DOMWindowNotifications::from):
2867         (WebCore::DOMWindowNotifications::webkitNotifications):
2868         (WebCore::DOMWindowNotifications::reset):
2869         (WebCore::DOMWindowNotifications::supplementName):
2870         * notifications/DOMWindowNotifications.h: Added.
2871         (WebCore):
2872         (DOMWindowNotifications):
2873         * notifications/DOMWindowNotifications.idl: Added.
2874         * page/DOMWindow.cpp:
2875         (WebCore::DOMWindow::~DOMWindow):
2876         (WebCore):
2877         (WebCore::DOMWindow::resetNotifications):
2878         * page/DOMWindow.h:
2879         (WebCore):
2880         (DOMWindow):
2881         * page/DOMWindow.idl:
2882
2883 2012-03-22  Li Yin  <li.yin@intel.com>
2884
2885         A client MUST close a connection if it detects a masked frame
2886         https://bugs.webkit.org/show_bug.cgi?id=81361
2887
2888         Reviewed by Kent Tamura.
2889
2890         A server must not mask any frames that it sends to the client.
2891         Change the test case, not mask the frames from server to client.
2892         
2893         Test: http/tests/websocket/tests/hybi/invalid-masked-frames-from-server.html
2894
2895         * Modules/websockets/WebSocketChannel.cpp:
2896         (WebCore::WebSocketChannel::processFrame):
2897
2898 2012-03-22  Li Yin  <li.yin@intel.com>
2899
2900         [WebSocket]The minimal number of bytes MUST be used to encode the length
2901         https://bugs.webkit.org/show_bug.cgi?id=81443
2902
2903         Reviewed by Kent Tamura.
2904
2905         From RFC 6455 http://tools.ietf.org/html/rfc6455#section-5.2
2906         the minimal number of bytes MUST be used to encode the length
2907         
2908         New test case : http/tests/websocket/tests/hybi/invalid-encode-length.html
2909
2910         * Modules/websockets/WebSocketChannel.cpp:
2911         (WebCore::WebSocketChannel::parseFrame):
2912
2913 2012-03-22  Adam Barth  <abarth@webkit.org>
2914
2915         Unreviewed.  Sort xcodeproj file.
2916
2917         * WebCore.xcodeproj/project.pbxproj:
2918
2919 2012-03-22  Mao Yujie  <yujie.mao@intel.com>
2920
2921         Implement strict testing criterion for callback function definition
2922         https://bugs.webkit.org/show_bug.cgi?id=80005
2923
2924         Reviewed by Adam Barth.
2925
2926         Callback function should be defined as the function type instead of
2927         the object type.
2928
2929         LayoutTest: fast/dom/MediaStream/argument-types.html
2930
2931         * bindings/scripts/CodeGeneratorJS.pm:
2932         (GenerateParametersCheckExpression):
2933         (GenerateParametersCheck):
2934         * bindings/scripts/CodeGeneratorV8.pm:
2935         (GenerateParametersCheckExpression):
2936         (GenerateParametersCheck):
2937
2938 2012-03-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2939
2940         Convert hasGrammarMarker to use Internals interface
2941         https://bugs.webkit.org/show_bug.cgi?id=82004
2942
2943         Reviewed by Ryosuke Niwa.
2944
2945         Remove hasGrammarMarker functions, because it is able to work in the
2946         cross-port way through the Internals interface.
2947
2948         No new tests, since we are improving here the infra-structure
2949         for testing a specific method.
2950
2951         * testing/Internals.cpp:
2952         (WebCore::Internals::hasGrammarMarker):
2953         (WebCore):
2954         * testing/Internals.h:
2955         (Internals):
2956         * testing/Internals.idl:
2957
2958 2012-03-22  Xingnan Wang  <xingnan.wang@intel.com>
2959
2960         Add exception for the setter of "fftSize" in RealtimeAnalyserNode
2961         https://bugs.webkit.org/show_bug.cgi?id=81748
2962
2963         Reviewed by Chris Rogers.
2964
2965         * Modules/webaudio/RealtimeAnalyser.cpp:
2966         (WebCore::RealtimeAnalyser::setFftSize):
2967         * Modules/webaudio/RealtimeAnalyser.h:
2968         (RealtimeAnalyser):
2969         * Modules/webaudio/RealtimeAnalyserNode.cpp:
2970         (WebCore::RealtimeAnalyserNode::setFftSize):
2971         (WebCore):
2972         * Modules/webaudio/RealtimeAnalyserNode.h:
2973         (RealtimeAnalyserNode):
2974         * Modules/webaudio/RealtimeAnalyserNode.idl:
2975
2976 2012-03-22  Leo Yang  <leo.yang@torchmobile.com.cn>
2977
2978         [BlackBerry] Add HistoryItemViewState for BlackBerry port
2979         https://bugs.webkit.org/show_bug.cgi?id=81867
2980
2981         Reviewed by Rob Buis.
2982
2983         HistoryItemViewState is the blackberry specific field of HistoryItem.
2984         It's used to maintain the porting specific view state.
2985
2986         No new test because the port can't be built yet.
2987
2988         * history/HistoryItem.h:
2989         (HistoryItem):
2990         (WebCore::HistoryItem::viewState):
2991
2992 2012-03-22  SravanKumar Sandela  <ssandela@innominds.com>
2993
2994         Fieldset unexpectedly stretches to minimum intrinsic width
2995         https://bugs.webkit.org/show_bug.cgi?id=79128
2996
2997         Reviewed by Julien Chaffraix.
2998
2999         Fieldset element width will now check if css width is specified explicitly
3000         before stretching to minimum intrinsic width. The reference
3001         can be taken from IE9, instead of FF(FF acknowledged the broken behavior). 
3002
3003         Tests: fast/forms/fieldset-width-nostretch-ifspecified-expected.html
3004                fast/forms/fieldset-width-nostretch-ifspecified.html
3005
3006         * rendering/RenderFieldset.cpp:
3007         (WebCore::RenderFieldset::stretchesToMinIntrinsicLogicalWidth):
3008         (WebCore):
3009         * rendering/RenderFieldset.h:
3010         (RenderFieldset):
3011
3012 2012-03-22  Shawn Singh  <shawnsingh@chromium.org>
3013
3014         [chromium] Target surface should be damaged for a new layers even when layer had no changes
3015         https://bugs.webkit.org/show_bug.cgi?id=81879
3016
3017         Reviewed by Adrienne Walker.
3018
3019         Unit test added to CCDamageTrackerTest.
3020
3021         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
3022         (WebCore::CCDamageTracker::removeRectFromCurrentFrame): added a
3023         boolean arg to detect if the layer is new on this update.
3024
3025         (WebCore::CCDamageTracker::extendDamageForLayer): added logic that
3026         damages the target surface if the layer is new.
3027
3028         (WebCore::CCDamageTracker::extendDamageForRenderSurface): added
3029         logic that damages the target surface if the descendant surface is
3030         new; similar logic for the surface's replica if the replica is new.
3031
3032         * platform/graphics/chromium/cc/CCDamageTracker.h:
3033         (CCDamageTracker):
3034
3035 2012-03-22  Charles Wei  <charles.wei@torchmobile.com.cn>
3036
3037         [BlackBerry] Need to store the meta info of a page in the ViewState of the history
3038         https://bugs.webkit.org/show_bug.cgi?id=82000
3039
3040         Reviewed by Rob Buis.
3041
3042         Internally reviewed by George Staikos.
3043
3044         No new tests, BlackBerry porting doesn't build yet upstreaming.
3045
3046         * history/blackberry/HistoryItemViewState.h:
3047         (WebCore::HistoryItemViewState::HistoryItemViewState):
3048         (HistoryItemViewState):
3049
3050 2012-03-22  Adam Klein  <adamk@chromium.org>
3051
3052         [v8] wrapSlow methods should ref underlying object before creating wrapper
3053         https://bugs.webkit.org/show_bug.cgi?id=81919
3054
3055         Reviewed by Adam Barth.
3056
3057         Because instatiating the wrapper can trigger GC, it's important that
3058         wrapSlow() hold a reference to an object when creating a wrapper for
3059         that object. Once the V8 wrapper exists and is associated with the object,
3060         the reference can be handed off (via leakRef) to be handled by the normal
3061         binding code logic (where derefObject is called if the handle is GCed).
3062
3063         Binding tests have been updated to reflect this change.
3064
3065         Testing the change directly is hard. Any test landed today would only
3066         be a valid test until V8's logic about when to GC changes, at which point
3067         it would become dead weight. So I don't think it's worth landing a
3068         layout test along with this.
3069
3070         * bindings/scripts/CodeGeneratorV8.pm:
3071         (GenerateHeader): Make wrapSlow take a PassRefPtr for RefCounted objects.
3072         (GenerateToV8Converters): Get rid of the explicit call to ref() and
3073         instead call leakRef() when adding a RefCounted object to the DOM map.
3074         (GetPassRefPtrType): Helper to generate "PassRefPtr<T>", or "PassRefPtr<T<U> >" as appropriate.
3075         * bindings/scripts/test/V8/V8Float64Array.cpp:
3076         (WebCore::V8Float64Array::wrapSlow):
3077         * bindings/scripts/test/V8/V8Float64Array.h:
3078         (V8Float64Array):
3079         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
3080         (WebCore::V8TestActiveDOMObject::wrapSlow):
3081         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
3082         (V8TestActiveDOMObject):
3083         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
3084         (WebCore::V8TestCustomNamedGetter::wrapSlow):
3085         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
3086         (V8TestCustomNamedGetter):
3087         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
3088         (WebCore::V8TestEventConstructor::wrapSlow):
3089         * bindings/scripts/test/V8/V8TestEventConstructor.h:
3090         (V8TestEventConstructor):
3091         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
3092         (WebCore::V8TestEventTarget::wrapSlow):
3093         * bindings/scripts/test/V8/V8TestEventTarget.h:
3094         (V8TestEventTarget):
3095         * bindings/scripts/test/V8/V8TestInterface.cpp:
3096         (WebCore::V8TestInterface::wrapSlow):
3097         * bindings/scripts/test/V8/V8TestInterface.h:
3098         (V8TestInterface):
3099         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
3100         (WebCore::V8TestMediaQueryListListener::wrapSlow):
3101         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
3102         (V8TestMediaQueryListListener):
3103         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
3104         (WebCore::V8TestNamedConstructor::wrapSlow):
3105         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
3106         (V8TestNamedConstructor):
3107         * bindings/scripts/test/V8/V8TestObj.cpp:
3108         (WebCore::V8TestObj::wrapSlow):
3109         * bindings/scripts/test/V8/V8TestObj.h:
3110         (V8TestObj):
3111         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
3112         (WebCore::V8TestSerializedScriptValueInterface::wrapSlow):
3113         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
3114         (V8TestSerializedScriptValueInterface):
3115
3116 2012-03-22  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
3117
3118         [BlackBerry] add interface clearCredentials() and clearNeverRememberSites()
3119         https://bugs.webkit.org/show_bug.cgi?id=81887
3120
3121         Reviewed by Rob Buis.
3122
3123         Fixed SQL issue when clearing table logins and table never_remember.
3124
3125         No new tests.
3126
3127         * platform/network/blackberry/CredentialBackingStore.cpp:
3128         (WebCore::CredentialBackingStore::clearLogins):
3129         (WebCore::CredentialBackingStore::clearNeverRemember):
3130
3131 2012-03-22  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
3132
3133         [BlackBerry] http authenticate dialog popup only once no matter authentication pass or fail
3134         https://bugs.webkit.org/show_bug.cgi?id=80135
3135
3136         Reviewed by Rob Buis.
3137
3138         Modified the interface function authenticationChallenge() in class
3139         PageClientBlackBerry, moved Credential from return value to the
3140         function's reference parameter, and returned a bool to indicate if
3141         user pressed Ok button or not.
3142         Removed the logic which checks m_currentWebChallenge not null,
3143         because we should challenge user again if the last provided credential
3144         is not valid; also added the logic that will popup challenge
3145         dialog again immediately if user press Ok buttton directly without
3146         inputting anything.
3147
3148         No new tests.
3149
3150         * platform/blackberry/PageClientBlackBerry.h:
3151         * platform/network/blackberry/NetworkJob.cpp:
3152         (WebCore::NetworkJob::handleAuthHeader):
3153         (WebCore::NetworkJob::sendRequestWithCredentials):
3154
3155 2012-03-22  Jason Liu  <jason.liu@torchmobile.com.cn>
3156
3157         [BlackBerry] Synchronize platform/network/blackberry
3158         https://bugs.webkit.org/show_bug.cgi?id=81874
3159
3160         We changed a lot in these files locally. But the changes are not upstreamed.
3161         It is not convenient to do the other upstreaming work based on these differences.
3162         So upstream these changes.
3163
3164         Reviewed by Rob Buis.
3165
3166         No new tests. Just synchronize codes.
3167
3168         * platform/network/blackberry/NetworkJob.cpp:
3169         (WebCore::NetworkJob::NetworkJob):
3170         (WebCore::NetworkJob::initialize):
3171         (WebCore::NetworkJob::handleNotifyHeaderReceived):
3172         (WebCore::NetworkJob::handleNotifyDataReceived):
3173         (WebCore::NetworkJob::sendResponseIfNeeded):
3174         (WebCore::NetworkJob::sendRequestWithCredentials):
3175         (WebCore::NetworkJob::handleAbout):
3176         * platform/network/blackberry/NetworkJob.h:
3177         (WebCore::NetworkJob::isError):
3178         (NetworkJob):
3179         * platform/network/blackberry/NetworkManager.cpp:
3180         (WebCore::NetworkManager::startJob):
3181         * platform/network/blackberry/ResourceRequest.h:
3182         (WebCore::ResourceRequest::ResourceRequest):
3183         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
3184         (WebCore::platformTargetTypeForRequest):
3185
3186 2012-03-22  Tom Sepez  <tsepez@chromium.org>
3187
3188         XSS Auditor bypass via script tag src=data:, URLS.
3189         https://bugs.webkit.org/show_bug.cgi?id=81948
3190
3191         Reviewed by Adam Barth.
3192
3193         This change fixes an XSSAuditor bypass wherby a script with a data: URL src
3194         attribute could evade detection by using characters from the page to create
3195         a snippet for matching not found in the URL's reflected vector.  This change 
3196         terminates the snippet for matching earlier in these cases.
3197         
3198         Test: http/tests/security/xssAuditor/script-tag-with-source-data-url2.html
3199
3200         * html/parser/XSSAuditor.cpp:
3201         (WebCore::XSSAuditor::decodedSnippetForAttribute):
3202
3203 2012-03-22  Dana Jansens  <danakj@chromium.org>
3204
3205         [chromium] Incorrect assert on animating opacity for a surface
3206         https://bugs.webkit.org/show_bug.cgi?id=81994
3207
3208         Reviewed by Adrienne Walker.
3209
3210         Draw opacity and animation state match on the surface itself. A
3211         surface with animating opacity always has an owning layer without
3212         animation, as the surface does the animation for it.
3213
3214         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3215         (WebCore::CCLayerTreeHost::paintLayerContents):
3216
3217 2012-03-22  Dana Jansens  <danakj@chromium.org>
3218
3219         [chromium] Skip frames when checkerboarding an animation
3220         https://bugs.webkit.org/show_bug.cgi?id=81716
3221
3222         Reviewed by Adrienne Walker.
3223
3224         This will stop drawing frames when prepareToDraw fails, if the draw is
3225         not forced. The expected behaviour is outlined below by the unit tests.
3226
3227         When a draw fails, we:
3228         1. Set m_needsRedraw to try again next vsync
3229         2. Set m_needsCommit because we need more data from webkit to succeed
3230         3. Set m_drawIfPossibleFailed. This allows us to try draw again within
3231         the same vsync *if* a commit finishes during this time.
3232
3233         Unit test: CCSchedulerTest.RequestRedrawInsideFailedDraw
3234                    CCSchedulerTest.RequestCommitInsideFailedDraw
3235                    CCSchedulerTest.NoBeginFrameWhenDrawFails
3236                    CCSchedulerStateMachineTest.TestFailedDrawSetsNeedsCommitAndDoesNotDrawAgain
3237                    CCSchedulerStateMachineTest.TestSetNeedsRedrawDuringFailedDrawDoesNotRemoveNeedsRedraw
3238                    CCSchedulerStateMachineTest.TestCommitAfterFailedDrawAllowsDrawInSameFrame
3239                    CCSchedulerStateMachineTest.TestCommitAfterFailedAndSuccessfulDrawDoesNotAllowDrawInSameFrame
3240                    CCSchedulerStateMachineTest.TestFailedDrawIsRetriedNextVSync
3241
3242         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3243         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
3244         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
3245         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3246         (CCLayerTreeHostImpl):
3247         * platform/graphics/chromium/cc/CCScheduler.cpp:
3248         (WebCore::CCScheduler::processScheduledActions):
3249         * platform/graphics/chromium/cc/CCScheduler.h:
3250         (CCSchedulerClient):
3251         * platform/graphics/chromium/cc/CCSchedulerStateMachine.cpp:
3252         (WebCore::CCSchedulerStateMachine::CCSchedulerStateMachine):
3253         (WebCore::CCSchedulerStateMachine::nextAction):
3254         (WebCore::CCSchedulerStateMachine::updateState):
3255         (WebCore::CCSchedulerStateMachine::didDrawIfPossibleCompleted):
3256         (WebCore):
3257         * platform/graphics/chromium/cc/CCSchedulerStateMachine.h:
3258         (CCSchedulerStateMachine):
3259         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
3260         (WebCore::CCThreadProxy::scheduledActionDrawAndSwapInternal):
3261         (WebCore):
3262         (WebCore::CCThreadProxy::scheduledActionDrawAndSwapIfPossible):
3263         (WebCore::CCThreadProxy::scheduledActionDrawAndSwapForced):
3264         * platform/graphics/chromium/cc/CCThreadProxy.h:
3265         (CCThreadProxy):
3266
3267 2012-03-22  W. James MacLean  <wjmaclean@chromium.org>
3268
3269         [chromium] Force update of nonFastScrollableRegion if target CCLayerImpl has been freshly created.
3270         https://bugs.webkit.org/show_bug.cgi?id=81968
3271
3272         Reviewed by Adrienne Walker.
3273
3274         Added unit test to existing tests for TreeSynchronizer.
3275
3276         When creating a new CCLayerImpl during tree synchronization, make sure we transfer the nonFastScrollableRegion as
3277         the new CCLayerImpl will default to an empty region.
3278
3279         * platform/graphics/chromium/LayerChromium.h:
3280         (WebCore::LayerChromium::nonFastScrollableRegion):
3281         (WebCore::LayerChromium::setNonFastScrollableRegionChanged):
3282         * platform/graphics/chromium/TreeSynchronizer.cpp:
3283         (WebCore::TreeSynchronizer::reuseOrCreateCCLayerImpl):
3284
3285 2012-03-22  Raphael Kubo da Costa  <rakuco@FreeBSD.org>
3286
3287         [CMake] Unreviewed build fix after r111778.
3288
3289         * CMakeLists.txt: Replace ${JAVASCRIPTCORE_DIR}/wtf includes with
3290         ${WTF_DIR}/wtf ones.
3291
3292 2012-03-22  Tony Chang  <tony@chromium.org>
3293
3294         Unreviewed, fix chromium build after wtf move.
3295
3296         Only use newwtf, remove references to wtf.
3297
3298         * WebCore.gyp/WebCore.gyp:
3299
3300 2012-03-22  Benjamin Poulain  <bpoulain@apple.com>
3301
3302         Remove an obsolete comment regarding magic frames from Geolocation
3303         https://bugs.webkit.org/show_bug.cgi?id=81871
3304
3305         Reviewed by Alexey Proskuryakov.
3306
3307         Moving a frame into another document is no longer possible after r111361. The comment
3308         is now irrelevant.
3309
3310         * Modules/geolocation/Geolocation.cpp:
3311         (WebCore::Geolocation::stop):
3312
3313 2012-03-22  Csaba Osztrogonác  <ossy@webkit.org>
3314
3315         Actually move WTF files to their new home
3316         https://bugs.webkit.org/show_bug.cgi?id=81844
3317
3318         [Qt] Unreviewed buildfix after r111778.
3319
3320         * Target.pri:
3321
3322 2012-03-22  Kentaro Hara  <haraken@chromium.org>
3323
3324         run-bindings-tests output a lot of errors in TestSerializedScriptValueInterface.idl
3325         https://bugs.webkit.org/show_bug.cgi?id=81852
3326
3327         Reviewed by Adam Barth.
3328
3329         run-bindings-tests output a lot of errors in TestSerializedScriptValueInterface.idl:
3330
3331         Use of uninitialized value in string eq at WebCore/bindings/scripts/CodeGeneratorJS.pm line 2743.
3332         Use of uninitialized value $name in substitution (s///) at WebCore/bindings/scripts/CodeGenerator.pm line 119.
3333         Use of uninitialized value $type in string eq at WebCore/bindings/scripts/CodeGeneratorJS.pm line 2969.
3334         Use of uninitialized value $type in string eq at WebCore/bindings/scripts/CodeGeneratorJS.pm line 2972.
3335         Use of uninitialized value $type in hash element at WebCore/bindings/scripts/CodeGenerator.pm line 367.
3336         Use of uninitialized value $type in hash element at WebCore/bindings/scripts/CodeGenerator.pm line 368.
3337         ...
3338
3339         This is because [Constructor(...)] does not yet support [Optional] arguments.
3340         It just supports [Optional=DefaultIsUndefined] and [Optional=DefaultIsNullString] arguments:
3341         https://trac.webkit.org/wiki/WebKitIDL#Constructor
3342
3343         This patch replaces [Optional] with [Optional=DefaultIsUndefined]
3344         in TestSerializedScriptValueInterface.idl.
3345
3346         Test: bindings/scripts/test/TestSerializedScriptValueInterface.idl
3347
3348         * bindings/scripts/CodeGeneratorJS.pm:
3349         (GenerateConstructorDefinition):
3350         * bindings/scripts/CodeGeneratorV8.pm:
3351         (GenerateConstructorCallback):
3352         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
3353         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::constructJSTestSerializedScriptValueInterface):
3354         * bindings/scripts/test/TestSerializedScriptValueInterface.idl:
3355         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
3356         (WebCore::V8TestSerializedScriptValueInterface::constructorCallback):
3357
3358 2012-03-22  Michal Mocny  <mmocny@google.com>
3359
3360         [chromium] LayerRendererChromium should use GpuMemoryAllocationChanged callback to explicitly manage framebuffer.
3361         https://bugs.webkit.org/show_bug.cgi?id=81823
3362
3363         Reviewed by Adrienne Walker.
3364
3365         New UnitTests: LayerRendererChromiumTest
3366
3367         * platform/graphics/chromium/LayerRendererChromium.cpp:
3368         (LayerRendererGpuMemoryAllocationChangedCallbackAdapter):
3369         (WebCore::LayerRendererGpuMemoryAllocationChangedCallbackAdapter::create):
3370         (WebCore::LayerRendererGpuMemoryAllocationChangedCallbackAdapter::~LayerRendererGpuMemoryAllocationChangedCallbackAdapter):
3371         (WebCore::LayerRendererGpuMemoryAllocationChangedCallbackAdapter::onGpuMemoryAllocationChanged):
3372         (WebCore::LayerRendererGpuMemoryAllocationChangedCallbackAdapter::LayerRendererGpuMemoryAllocationChangedCallbackAdapter):
3373         (WebCore):
3374         (WebCore::LayerRendererChromium::LayerRendererChromium):
3375         (WebCore::LayerRendererChromium::initialize):
3376         (WebCore::LayerRendererChromium::~LayerRendererChromium):
3377         (WebCore::LayerRendererChromium::setVisible):
3378         (WebCore::LayerRendererChromium::swapBuffers):
3379         (WebCore::LayerRendererChromium::discardFramebuffer):
3380         (WebCore::LayerRendererChromium::ensureFramebuffer):
3381         * platform/graphics/chromium/LayerRendererChromium.h:
3382         (WebCore):
3383         (LayerRendererChromiumClient):
3384         (LayerRendererChromium):
3385         (WebCore::LayerRendererChromium::isFramebufferDiscarded):
3386         (ScopedEnsureFramebufferAllocation):
3387         (WebCore::ScopedEnsureFramebufferAllocation::ScopedEnsureFramebufferAllocation):
3388         (WebCore::ScopedEnsureFramebufferAllocation::~ScopedEnsureFramebufferAllocation):
3389         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
3390         (WebCore::LayerRendererCapabilities::LayerRendererCapabilities):
3391         (LayerRendererCapabilities):
3392         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3393         (WebCore::CCLayerTreeHostImpl::setVisible):
3394         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3395         (CCLayerTreeHostImpl):
3396         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
3397         (WebCore::CCSingleThreadProxy::compositeAndReadback):
3398         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
3399         (WebCore::CCThreadProxy::compositeAndReadback):
3400
3401 2012-03-22  Adam Barth  <abarth@webkit.org>
3402
3403         ContainerNode::insertedIntoTree and removedFromTree use weak iteration patterns
3404         https://bugs.webkit.org/show_bug.cgi?id=80570
3405
3406         Reviewed by Ryosuke Niwa.
3407
3408         These functions use weak iteration patterns, but as far as I can tell,
3409         we never execute script below these functions.  This patch adds ASSERTs
3410         to help us avoid adding events in the future.
3411
3412         * dom/ContainerNode.cpp:
3413         (WebCore::ContainerNode::insertedIntoTree):
3414         (WebCore::ContainerNode::removedFromTree):
3415         * html/HTMLMediaElement.cpp:
3416         (WebCore::HTMLMediaElement::loadInternal):
3417             - There's a somewhat complex call chain from insertedIntoTree into
3418               HTMLMediaElement, and somewhat complex control flow below
3419               loadInternal that eventually leads to the BeforeLoad event being
3420               fired.  In studying this code, I don't see a way for the
3421               BeforeLoad event to be fired during insertedIntoTree, but I've
3422               added this assert here to make sure we don't call loadInternal
3423               when we're not supposed to dispatch events.  This ASSERT should
3424               help us catch these BeforeLoad errors more quickly.
3425
3426 2012-03-22  Raphael Kubo da Costa  <rakuco@FreeBSD.org>
3427
3428         Crash in fast/dom/navigator-detached-nocrash.html
3429         https://bugs.webkit.org/show_bug.cgi?id=81773
3430
3431         Reviewed by Adam Barth.
3432
3433         BatteryManager::create() blindly assumes the Navigator* it
3434         receives has a valid Frame, which is not always the case, as made
3435         evident by the crashing test.
3436
3437         Follow abarth's suggestion and just stop
3438         NavigatorBattery::webkitBattery() before it reaches the call to
3439         BatteryManager::create() if that's the case.
3440
3441         No new tests, covered by fast/dom/navigator-detached-nocrash.html.
3442
3443         * Modules/battery/NavigatorBattery.cpp:
3444         (WebCore::NavigatorBattery::webkitBattery):
3445
3446 2012-03-22  Emil A Eklund  <eae@chromium.org>
3447
3448         Unreviewed, add missing include statement for CSSValueList.h.
3449
3450         * css/CSSStyleSelector.h:
3451
3452 2012-03-22  Tony Chang  <tony@chromium.org>
3453
3454         flexbox flexing implementation should match the spec
3455         https://bugs.webkit.org/show_bug.cgi?id=70796
3456
3457         Reviewed by Ojan Vafai.
3458
3459         Match the algorithm in the spec. Handling min/max constraints are slightly improved.
3460         http://dev.w3.org/csswg/css3-flexbox/#resolve-the-flexible-lengths
3461
3462         New test cases in css3/flexbox/flex-algorithm-min-max.html.
3463
3464         * rendering/RenderFlexibleBox.cpp:
3465         (WebCore::adjustFlexSizeForMinAndMax): Step 5 of resolving flexible lengths.
3466         (WebCore):
3467         (WebCore::RenderFlexibleBox::Violation::Violation):
3468         (RenderFlexibleBox::Violation):
3469         (WebCore::RenderFlexibleBox::freezeViolations): Used by step 6.
3470         (WebCore::RenderFlexibleBox::resolveFlexibleLengths):
3471         * rendering/RenderFlexibleBox.h:
3472
3473 2012-03-22  Emil A Eklund  <eae@chromium.org>
3474
3475         Unreviewed, add missing import.
3476
3477         * rendering/RenderThemeMac.mm:
3478
3479 2012-03-22  Anders Carlsson  <andersca@apple.com>
3480
3481         ASSERT(!needsLayout) in RenderView.cpp when visiting http://www.panic.com/blog/
3482         https://bugs.webkit.org/show_bug.cgi?id=81953
3483         <rdar://problem/11086998>
3484
3485         Reviewed by Sam Weinig.
3486
3487         If a page ends up creating CATiledLayers, CA transactions can be committed outside of the normal
3488         CA run loop observer, so we can't call setNeedsDisplay on tile cache layers directly because then
3489         we'll end up calling into painting code before all the layers have been flushed.
3490
3491         Fix this by adding a list of dirty rects to platformCALayerDidCreateTiles and change GraphicsLayerCA to
3492         mark them as dirty. This ensures that any CA transaction commits won't cause newly added layers to be painted.
3493
3494         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
3495         (WebCore::LayerClient::platformCALayerDidCreateTiles):
3496         * platform/graphics/ca/GraphicsLayerCA.cpp:
3497         (WebCore::GraphicsLayerCA::platformCALayerDidCreateTiles):
3498         * platform/graphics/ca/GraphicsLayerCA.h:
3499         (GraphicsLayerCA):
3500         * platform/graphics/ca/PlatformCALayerClient.h:
3501         (PlatformCALayerClient):
3502         * platform/graphics/ca/mac/TileCache.mm:
3503         (WebCore::TileCache::setScale):
3504         (WebCore::TileCache::revalidateTiles):
3505         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
3506         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerDidCreateTiles):
3507
3508 2012-03-19  Robert Hogan  <robert@webkit.org>
3509
3510         Text should overflow when list item height set to 0
3511         https://bugs.webkit.org/show_bug.cgi?id=78726
3512
3513         Reviewed by Julien Chaffraix.
3514
3515         Tests: css2.1/20110323/height-applies-to-010a-expected.html
3516                fast/css/heightless-list-item-expected.html
3517                fast/css/heightless-list-item.html
3518
3519         * rendering/RenderListItem.cpp:
3520         (WebCore::RenderListItem::paint):
3521            If the list item has height:0, only paint it if the list item allows any block or inline content 
3522            to overflow unclipped. The zero-height check is a shortcut to avoid unnecessary painting and 
3523            this seems to be the only case where there's something to do.
3524
3525 2012-03-22  Dave Michael  <dmichael@chromium.org>
3526
3527         HTMLPluginElement is not destroyed on reload or navigation if getNPObject is called
3528         https://bugs.webkit.org/show_bug.cgi?id=80428
3529
3530         Reviewed by Eric Seidel.
3531
3532         Make HTMLPluginElement release its m_NPObject in detach() to break a
3533         reference-counting cycle that happens on reload or navigation. With this
3534         change, HTMLPlugInElement::removedFromDocument is unnecessary, so it
3535         was removed. Note that Releasing m_NPObject does not result in a call to
3536         the plugin; it simply releases a reference count on the wrapper object
3537         for this HTMLPlugInElement. (The plugin's NPP_Deallocate is invoked
3538         when the render tree is destroyed, when PluginView calls
3539         PluginPackage::unload.) Thus, it is safe to release m_NPObject in
3540         detach, because it can not result in layout or style changes.
3541
3542         Also added numberOfLiveNodes() and numberOfLiveDocuments() to
3543         window.internals to enable testing.
3544
3545         Test: plugins/netscape-dom-access-and-reload.html
3546
3547         * WebCore.exp.in:
3548         * html/HTMLPlugInElement.cpp:
3549         (WebCore::HTMLPlugInElement::detach):
3550         * html/HTMLPlugInElement.h:
3551         (HTMLPlugInElement):
3552         * testing/Internals.cpp:
3553         (WebCore::Internals::numberOfLiveDocuments):
3554         (WebCore::Internals::numberOfLiveNodes):
3555         (WebCore):
3556         * testing/Internals.h:
3557         (Internals):
3558         * testing/Internals.idl:
3559
3560 2012-03-22  Shawn Singh  <shawnsingh@chromium.org>
3561
3562         [chromium] Make CCDamageTracker robust to empty layer lists
3563         https://bugs.webkit.org/show_bug.cgi?id=81831
3564
3565         Reviewed by Adrienne Walker.
3566
3567         Added a unit test in CCDamageTrackerTest that causes a crash in
3568         the old code. With this patch applied, the crash will not occur.
3569         In theory, that crash should never occur anyway, unless there is a
3570         bug outside the damage tracker, but for robustness it's
3571         appropriate to handle it properly.
3572
3573         In addition to this fix, performed some trivial maintenance on the
3574         damage tracker code.
3575
3576         * platform/graphics/chromium/cc/CCDamageTracker.cpp:
3577         (WebCore::CCDamageTracker::updateDamageTrackingState): removed
3578         unclean code that accessed the targetSurface to get necessary
3579         information. Instead, we now pass those args through the damage
3580         tracker's API.
3581
3582         * platform/graphics/chromium/cc/CCDamageTracker.h:
3583         (CCDamageTracker): modified args passed to damage tracker on update.
3584
3585         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3586         (WebCore::CCLayerTreeHostImpl::trackDamageForAllSurfaces):
3587         modified args passed to damage tracker on update.
3588
3589 2012-03-22  Julien Chaffraix  <jchaffraix@webkit.org>
3590
3591         Enable style sharing for elements with a style attribute
3592         https://bugs.webkit.org/show_bug.cgi?id=81523
3593
3594         Reviewed by Antti Koivisto.
3595
3596         Memory improvement change only.
3597
3598         Overall, this is a performance wash (some benchmarks may regress a bit due to the increase in time taken
3599         by CSSStyleSelector::locateSharedStyle as we try more nodes, others increase their performance due to style sharing).
3600
3601         Instrumenting our style sharing, this should give us some nice memory shavings on some benchmarks:
3602         - HTML5 isn't impacted as it doesn't use much inline style
3603         - page cyclers' intl1 showed a 6% increase in style sharing.
3604
3605         * css/CSSStyleSelector.cpp:
3606         (WebCore::CSSStyleSelector::canShareStyleWithElement):
3607         This method now handles inline style like presentation attributes on the element.
3608
3609         (WebCore::CSSStyleSelector::collectMatchingRulesForList):
3610         (WebCore::CSSStyleSelector::locateSharedStyle):
3611         Don't bail out for an element with an inline style declaration.
3612
3613         (WebCore::CSSStyleSelector::stylesEqual):
3614         Generalized attributeStylesEqual to share the logic between attribute and
3615         inline style property set. This means that attribute checks are actually
3616         doing a little extra more work but that didn't impact our benchmarks.
3617
3618 2012-03-22  Kevin Ollivier  <kevino@theolliviers.com>
3619
3620         [wx] Unreviewed. WebDOM build fix after array type changes.
3621
3622         * bindings/scripts/CodeGeneratorCPP.pm:
3623         (ShouldSkipType):
3624
3625 2012-03-22  Pavel Feldman  <pfeldman@chromium.org>
3626
3627         Web Inspector: text gutter decorations should move upon edits.
3628         https://bugs.webkit.org/show_bug.cgi?id=81932
3629
3630         Reviewed by Vsevolod Vlasov.
3631
3632         Decorations set by the line number now shift as editing inserts / removes lines.
3633
3634         * inspector/front-end/TextViewer.js:
3635         (WebInspector.TextViewer.prototype._syncLineHeight):
3636         (WebInspector.TextEditorGutterPanel):
3637         (WebInspector.TextEditorGutterPanel.prototype.textChanged):
3638         (WebInspector.TextEditorGutterPanel.prototype.syncClientHeight):
3639         (WebInspector.TextEditorGutterPanel.prototype.addDecoration):
3640         (WebInspector.TextEditorGutterPanel.prototype.removeDecoration):
3641
3642 2012-03-21  Robert Hogan  <robert@webkit.org>
3643
3644         CSS 2.1 failure: fixed-table-layout-006 fails
3645         https://bugs.webkit.org/show_bug.cgi?id=78412
3646
3647         Reviewed by Julien Chaffraix.
3648
3649         Tests: css2.1/20110323/fixed-table-layout-006.htm
3650                fast/css/fixed-table-layout-cell-padding.htm
3651
3652         In fixed tables, positive width specified on a column should include borders and padding.
3653         See the thread at http://lists.w3.org/Archives/Public/www-style/2011Oct/0502.html. The discussion
3654         there resulted in a whole new set of tests for section 17.5.2.1 in the CSS 2.1 spec. See 
3655         http://test.csswg.org/harness/test/CSS21_DEV/section/17.5.2.1/. This patch allows WebKit
3656         to pass all of them, and all tests for the 17.5.2.1 section as a whole. I'll land them all separately.
3657     
3658         * rendering/FixedTableLayout.cpp:
3659         (WebCore::FixedTableLayout::calcWidthArray): Include border width and cell padding in the width of the column.
3660          Note that borderAndPaddingLogicalWidth() returns the border width for separate and collapsed borders as appropriate.
3661
3662 2012-03-22  Simon Fraser  <simon.fraser@apple.com>
3663
3664         Factor compositing layer updates after scroll into a new method
3665         https://bugs.webkit.org/show_bug.cgi?id=81943
3666
3667         Reviewed by Dean Jackson.
3668
3669         Move some code that updates compositing layers after scrolling
3670         into its own method, for cleanliness.
3671
3672         * rendering/RenderLayer.cpp:
3673         (WebCore::RenderLayer::scrollTo):
3674         (WebCore::RenderLayer::updateCompositingLayersAfterScroll):
3675         (WebCore):
3676         * rendering/RenderLayer.h:
3677         (RenderLayer):
3678
3679 2012-03-22  Gavin Barraclough  <barraclough@apple.com>
3680
3681         Add JSValue::isFunction
3682         https://bugs.webkit.org/show_bug.cgi?id=81935
3683
3684         Reviewed by Geoff Garen.
3685
3686         This would be useful in the WebCore bindings code.
3687         Also, remove asFunction, replace with jsCast<JSFunction*>.
3688
3689         * bindings/js/JSInjectedScriptHostCustom.cpp:
3690         (WebCore::JSInjectedScriptHost::functionDetails):
3691         * bindings/js/ScriptCallStackFactory.cpp:
3692         (WebCore::createScriptCallStack):
3693
3694 2012-03-22  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3695
3696         TiledBackingStore: Fix test regressions that appeared with r111560.
3697         https://bugs.webkit.org/show_bug.cgi?id=81519
3698
3699         Reviewed by Kenneth Rohde Christiansen.
3700
3701         The visible rect wasn't intersected with the contents rect anymore which
3702         could lead to an astronomical layer size to check for intersecting tiles.
3703
3704         Add a visibleContentsRect that doesn't do the conversion and use it
3705         in visibleAreaIsCovered.
3706
3707         * platform/graphics/TiledBackingStore.cpp:
3708         (WebCore::TiledBackingStore::visibleContentsRect):
3709         (WebCore):
3710         (WebCore::TiledBackingStore::visibleRect):
3711         (WebCore::TiledBackingStore::visibleAreaIsCovered):
3712         * platform/graphics/TiledBackingStore.h:
3713         (TiledBackingStore):
3714
3715 2012-03-22  Joe Thomas  <joethomas@motorola.com>
3716
3717         Make Length Calculation functions non-inline
3718         https://bugs.webkit.org/show_bug.cgi?id=81733
3719
3720         Currently length calculation functions in LengthFunctions.h are inline. These functions are pretty big to be inline.
3721         And these functions are expected to grow again when new length units will be introduced in bug 27160.
3722
3723         A decent rule of thumb is to not inline a function if it is more than 10 lines long. Also it's typically not cost effective to inline
3724         functions with loops or switch statements. (Reference: http://google-styleguide.googlecode.com/svn/trunk/cppguide.xml#Inline_Functions).
3725
3726         Ran PerformanceTests/Parser/html5-full-render.html on Mac Snow-Leopard with and without the patch and did not see much performance difference.
3727
3728         Reviewed by Antti Koivisto.
3729
3730         * CMakeLists.txt:
3731         * GNUmakefile.list.am:
3732         * Target.pri:
3733         * WebCore.gypi:
3734         * WebCore.vcproj/WebCore.vcproj:
3735         * WebCore.xcodeproj/project.pbxproj:
3736         * css/LengthFunctions.cpp: Added.
3737         (WebCore):
3738         (WebCore::miminumValueForLength):
3739         (WebCore::valueForLength):
3740         (WebCore::floatValueForLength):
3741         * css/LengthFunctions.h:
3742         (WebCore):
3743
3744 2012-03-22  Alexis Menard  <alexis.menard@openbossa.org>
3745
3746         Increase code sharing between CSSParser and CSSPropertyLonghand.
3747         https://bugs.webkit.org/show_bug.cgi?id=81587
3748
3749         Reviewed by Antti Koivisto.
3750
3751         Expose the longhands declaration for a given shorthand in CSSPropertyLonghand and
3752         make CSSParser use them. It will make the declaration of longhands in one place only.
3753         Remove the map of CSSPropertyLonghand and replace it by a regular switch/case.
3754         The map doesn't bring much here and it's cleaner and faster to use the switch.
3755         It also shows a little performance improvement in CSS/CSSPropertySetterGetter.html.
3756
3757         No new tests : no behavior change.
3758
3759         * css/CSSParser.cpp:
3760         (WebCore::CSSParser::parseValue):
3761         (WebCore::CSSParser::parseAnimationShorthand):
3762         (WebCore::CSSParser::parseTransitionShorthand):
3763         (WebCore::CSSParser::parseShorthand):
3764         Modify the prototype of this function to directly use the CSSPropertyLonghand.
3765         * css/CSSParser.h:
3766         (WebCore):
3767         (CSSParser):
3768         * css/CSSPropertyLonghand.cpp:
3769         (WebCore):
3770         (WebCore::backgroundLonghand):
3771         (WebCore::backgroundPositionLonghand):
3772         (WebCore::backgroundRepeatLonghand):
3773         (WebCore::borderLonghand):
3774         (WebCore::borderBottomLonghand):
3775         (WebCore::borderColorLonghand):
3776         (WebCore::borderImageLonghand):
3777         (WebCore::borderLeftLonghand):
3778         (WebCore::borderRadiusLonghand):
3779         (WebCore::borderRightLonghand):
3780         (WebCore::borderSpacingLonghand):
3781         (WebCore::borderStyleLonghand):
3782         (WebCore::borderTopLonghand):
3783         (WebCore::borderWidthLonghand):
3784         (WebCore::listStyleLonghand):
3785         (WebCore::fontLonghand):
3786         (WebCore::marginLonghand):
3787         (WebCore::outlineLonghand):
3788         (WebCore::overflowLonghand):
3789         (WebCore::paddingLonghand):
3790         (WebCore::webkitAnimationLonghand):
3791         (WebCore::webkitBorderAfterLonghand):
3792         (WebCore::webkitBorderBeforeLonghand):
3793         (WebCore::webkitBorderEndLonghand):
3794         (WebCore::webkitBorderStartLonghand):
3795         (WebCore::webkitColumnsLonghand):
3796         (WebCore::webkitColumnRuleLonghand):
3797         (WebCore::webkitFlexFlowLonghand):
3798         (WebCore::webkitMarginCollapseLonghand):
3799         (WebCore::webkitMarqueeLonghand):
3800         (WebCore::webkitMaskLonghand):
3801         (WebCore::webkitMaskPositionLonghand):
3802         (WebCore::webkitMaskRepeatLonghand):
3803         (WebCore::webkitTextEmphasisLonghand):
3804         (WebCore::webkitTextStrokeLonghand):
3805         (WebCore::webkitTransitionLonghand):
3806         (WebCore::webkitTransformOriginLonghand):
3807         (WebCore::webkitWrapLonghand):
3808         (WebCore::longhandForProperty):
3809         * css/CSSPropertyLonghand.h:
3810         (WebCore):
3811
3812 2012-03-22  Emil A Eklund  <eae@chromium.org>
3813
3814         Unreviewed, touching file to force bots to pick up CSS_SHADERS flag change. 
3815
3816         * css/CSSStyleSelector.h:
3817         (CSSStyleSelector):
3818
3819 2012-03-22  Xingnan Wang  <xingnan.wang@intel.com>
3820
3821         ReverbConvolver::latencyFrames() should return 0.
3822         https://bugs.webkit.org/show_bug.cgi?id=81806
3823
3824         Reviewed by Chris Rogers.
3825
3826         * platform/audio/ReverbConvolver.cpp:
3827         (WebCore::ReverbConvolver::latencyFrames):
3828
3829 2012-03-22  Tony Chang  <tony@chromium.org>
3830
3831         refactor flexbox in preparation for flex-line-pack
3832         https://bugs.webkit.org/show_bug.cgi?id=81843
3833
3834         Reviewed by Ojan Vafai.
3835
3836         Replace WrapReverseContext with a vector of LineContexts that contain
3837         the same information, plus values needed for flex-align.
3838
3839         alignChildren has been moved to after all the lines have been
3840         positioned. We want to align children after flex-line-pack has changed
3841         the size of each line to avoid unnecessary layouts.
3842
3843         Take 2: Remove the assert. If there are no children, then there are no
3844         flex lines. Instead, assert that child is not null.
3845
3846         No new tests, just refactoring.
3847
3848         * rendering/RenderFlexibleBox.cpp:
3849         (WebCore::RenderFlexibleBox::LineContext::LineContext): New struct,
3850         holds information needed for wrap-reverse and aligning children.
3851         (RenderFlexibleBox::LineContext):
3852         (WebCore::RenderFlexibleBox::layoutFlexItems): alignChildren after layout out all the lines rather than after each line.
3853         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): don't alignChildren
3854         (WebCore::RenderFlexibleBox::alignChildren): align all flex items, not just a line at a time.
3855         (WebCore::RenderFlexibleBox::flipForWrapReverse): Update to use LineContext
3856         * rendering/RenderFlexibleBox.h:
3857
3858 2012-03-22  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
3859
3860         Event dispatching in XMLHttpRequestProgressEventThrottle should go through XMLHttpRequestProgressEventThrottle::dispatchEvent
3861         https://bugs.webkit.org/show_bug.cgi?id=46743
3862
3863         Reviewed by Julien Chaffraix
3864         Based on original patch by Anton D'Auria
3865
3866         In preparation for platform-specific queuing of XMLHttpRequest events,
3867         this patch changes all calls to m_target->dispatchEvent to
3868         XMLHttpRequestProgressEventThrottle::dispatchEvent.
3869         Currently, we queue only one progress event on suspend() if we have
3870         throttled progress events. We should be able to queue all XHR events
3871         that can be generated after suspend(), if the platform network layer
3872         continues to receive data.
3873         XMLHttpRequest uses XMLHttpRequestProgressEventThrottle to dispatch only
3874         download events, so this doesn't change behavior of upload events, which
3875         aren't throttled or queued.
3876
3877         * xml/XMLHttpRequest.cpp:
3878         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
3879         * xml/XMLHttpRequestProgressEventThrottle.cpp:
3880         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchReadyStateChangeEvent):
3881         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchEvent):
3882         (WebCore::XMLHttpRequestProgressEventThrottle::flushProgressEvent):
3883         (WebCore::XMLHttpRequestProgressEventThrottle::dispatchPausedEvent):
3884         (WebCore::XMLHttpRequestProgressEventThrottle::fired):
3885         * xml/XMLHttpRequestProgressEventThrottle.h:
3886         (XMLHttpRequestProgressEventThrottle):
3887
3888 2012-03-22  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
3889
3890         [EFL] Map BackSpace key code to Unicode value
3891         https://bugs.webkit.org/show_bug.cgi?id=81130
3892
3893         Reviewed by Gustavo Noronha Silva.
3894
3895         Test: fast/events/backspace-navigates-back.html
3896
3897         * platform/efl/EflKeyboardUtilities.cpp:
3898         (WebCore::createKeyMap): Map BackSpace to Unicode value
3899
3900 2012-03-22  Abhishek Arya  <inferno@chromium.org>
3901
3902         Incorrect beforeChild parent calculation in RenderRubyBase::moveChildren.
3903         https://bugs.webkit.org/show_bug.cgi?id=80297
3904
3905         Reviewed by Julien Chaffraix.
3906
3907         beforeChild might share the same anonymous block parent with other previous
3908         siblings. Before moving the children across ruby bases, we need to make sure
3909         to split the tree across the beforeChild correctly.
3910
3911         Test: fast/ruby/ruby-text-before-child-split.html
3912
3913         * rendering/RenderRubyBase.cpp:
3914         (WebCore::RenderRubyBase::moveChildren):
3915
3916 2012-03-22  Kristóf Kosztyó  <kkristof@inf.u-szeged.hu>
3917
3918         [Qt] Fix Qt minimal build after r111692
3919
3920         Reviewed by Csaba Osztrogonác.
3921
3922         * bindings/js/JSScriptProfileNodeCustom.cpp:
3923
3924 2012-03-22  Adrienne Walker  <enne@google.com>
3925
3926         [chromium] Fix scrollbar layers holding onto invalid textures after lost context
3927         https://bugs.webkit.org/show_bug.cgi?id=81841
3928
3929         Reviewed by James Robinson.
3930
3931         Unit test: CCLayerTreeHostImplTest.scrollbarLayerLostContext
3932
3933         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
3934         (WebCore::CCScrollbarLayerImpl::willDraw):
3935
3936 2012-03-22  Philippe Normand  <pnormand@igalia.com>
3937
3938         [GTK] ASSERT bug in WebAudio (AudioFileReader)
3939         https://bugs.webkit.org/show_bug.cgi?id=81777
3940
3941         Reviewed by Martin Robinson.
3942
3943         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
3944         (WebCore::AudioFileReader::decodeAudioForBusCreation): Don't steal
3945         the GstBus floating reference.
3946         (WebCore::AudioFileReader::createBus): Ditto.
3947
3948 2012-03-22  Ilya Tikhonovsky  <loislo@chromium.org>
3949
3950         Unreviewed: Web Inspector: fix syntax error in text.
3951
3952         * English.lproj/localizedStrings.js:
3953         * inspector/front-end/HeapSnapshotProxy.js:
3954         (WebInspector.HeapSnapshotWorker.prototype._messageReceived):
3955
3956 2012-03-22  Sheriff Bot  <webkit.review.bot@gmail.com>
3957
3958         Unreviewed, rolling out r111688.
3959         http://trac.webkit.org/changeset/111688
3960         https://bugs.webkit.org/show_bug.cgi?id=81912
3961
3962         "Heap profiler test fails" (Requested by yurys on #webkit).
3963
3964         * inspector/front-end/HeapSnapshot.js:
3965         (WebInspector.HeapSnapshot.prototype._buildRetainers):
3966
3967 2012-03-22  Dana Jansens  <danakj@chromium.org>
3968
3969         [chromium] Early out in a new prepareToDraw() step if checkerboarding an accelerated animation in order to skip the frame
3970         https://bugs.webkit.org/show_bug.cgi?id=81437
3971
3972         Reviewed by Adrienne Walker.
3973
3974         Split CCLayerTreeHostImpl::drawLayers() into two phases:
3975         prepareToDraw() and drawLayers().
3976
3977         When calculating a RenderPass, and we checkerboard a quad on a
3978         layer, bubble this info back up to CCLayerTreeHostImpl. If the
3979         layer is transforming in an animation, then abort the prepareToDraw()
3980         phase and cause it to return false back to the thread proxy.
3981
3982         Unit test: CCLayerTreeHostImplTest.prepareToDrawFailsWhenAnimationUsesCheckerboard
3983
3984         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
3985         (WebCore::CCLayerImpl::appendQuads):
3986         * platform/graphics/chromium/cc/CCLayerImpl.h:
3987         (CCLayerImpl):
3988         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3989         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
3990         (WebCore::CCLayerTreeHostImpl::prepareToDraw):
3991         (WebCore):
3992         (WebCore::CCLayerTreeHostImpl::drawLayers):
3993         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3994         (CCLayerTreeHostImpl):
3995         (FrameData):
3996         * platform/graphics/chromium/cc/CCQuadCuller.cpp:
3997         (WebCore::CCQuadCuller::append):
3998         * platform/graphics/chromium/cc/CCQuadCuller.h:
3999         (CCQuadCuller):
4000         * platform/graphics/chromium/cc/CCRenderPass.cpp:
4001         (WebCore::CCRenderPass::appendQuadsForLayer):
4002         * platform/graphics/chromium/cc/CCRenderPass.h:
4003         (CCRenderPass):
4004         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
4005         (WebCore::CCScrollbarLayerImpl::appendQuads):
4006         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
4007         (CCScrollbarLayerImpl):
4008         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
4009         (WebCore::CCSingleThreadProxy::doComposite):
4010         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.cpp:
4011         (WebCore::CCSolidColorLayerImpl::appendQuads):
4012         * platform/graphics/chromium/cc/CCSolidColorLayerImpl.h:
4013         (CCSolidColorLayerImpl):
4014         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
4015         (WebCore::CCTextureLayerImpl::appendQuads):
4016         * platform/graphics/chromium/cc/CCTextureLayerImpl.h:
4017         (CCTextureLayerImpl):
4018         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
4019         (WebCore::CCThreadProxy::scheduledActionDrawAndSwap):
4020         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
4021         (WebCore::CCTiledLayerImpl::appendQuads):
4022         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
4023         (CCTiledLayerImpl):
4024         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
4025         (WebCore::CCVideoLayerImpl::appendQuads):
4026         * platform/graphics/chromium/cc/CCVideoLayerImpl.h:
4027         (CCVideoLayerImpl):
4028
4029 2012-03-22  Levi Weintraub  <leviw@chromium.org>
4030
4031         Correct LayoutUnit usage in Accessibility code
4032         https://bugs.webkit.org/show_bug.cgi?id=81789
4033
4034         Reviewed by Eric Seidel.
4035
4036         Reverting Accessibility hit testing code back to integers. Accessibility hit tests originate from
4037         the embedder and don't accumulate offsets, so we get nothing from using LayoutUnits, and needlessly
4038         expose them to the embedder.
4039
4040         No new tests. No change in behavior.
4041
4042         * accessibility/AccessibilityListBox.cpp:
4043         (WebCore::AccessibilityListBox::elementAccessibilityHitTest): See above.
4044         * accessibility/AccessibilityListBox.h:
4045         (AccessibilityListBox):
4046         * accessibility/AccessibilityObject.cpp:
4047         (WebCore::AccessibilityObject::clickPoint): This value is only ever used to display a context menu,
4048         which is always done with integer coordinates.
4049         (WebCore::AccessibilityObject::boundingBoxForQuads): This is a bounding box built from floats. We
4050         don't pixel snap floats, so we return an integer bounding box.
4051         (WebCore::AccessibilityObject::elementAccessibilityHitTest): See above.
4052         (WebCore::AccessibilityObject::scrollToMakeVisible): Pixel snapping the bounding box and simplifying
4053         up the code to position it at (0,0).
4054         * accessibility/AccessibilityObject.h:
4055         (WebCore::AccessibilityObject::accessibilityHitTest): See above.
4056         (AccessibilityObject):
4057         (WebCore::AccessibilityObject::pixelSnappedBoundingBoxRect): Convenience method for embedder callers.
4058         * accessibility/AccessibilityRenderObject.cpp:
4059         (WebCore::AccessibilityRenderObject::visiblePositionForPoint): The point passed in here is comes from
4060         screen coordinates and originates in embedder code. Reverting it to take an integer.
4061         (WebCore::AccessibilityRenderObject::accessibilityImageMapHitTest): See above.
4062         (WebCore::AccessibilityRenderObject::accessibilityHitTest): See above.
4063         * accessibility/AccessibilityRenderObject.h: