Mouseup event does not fire on Scroll Bar
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-02-20  Mike West  <mkwst@chromium.org>
2
3         Mouseup event does not fire on Scroll Bar
4         https://bugs.webkit.org/show_bug.cgi?id=25811
5
6         Reviewed by Tony Chang.
7
8         Currently, clicking on a scrollbar fires a mousedown event, but not a
9         mouseup event. This causes problems for code like jQuery UI's
10         draggable[1], as the drag starts, but is never cancelled. Other use
11         cases are noted in the slightly old Chromium bug[2].
12
13         If a mouseup event is received after a mousedown event on a scrollbar,
14         this patch dispatches a mouseup event on the same node the mousedown
15         event dispatched on. This matches Gecko's behavior.
16
17         [1]: http://bugs.jqueryui.com/ticket/6925
18         [2]: http://crbug.com/14204
19
20         Tests: fast/scrolling/scrollbar-mousedown-mouseup.html
21                fast/scrolling/scrollbar-mousedown-move-mouseup.html
22
23         * page/EventHandler.cpp:
24         (WebCore::EventHandler::handleMouseReleaseEvent):
25             If a mouseup event follow a mousedown event on a scrollbar,
26             dispatch an event on the same node from which the mousedown event
27             was triggered.
28
29 2013-02-20  Takashi Sakamoto  <tasak@google.com>
30
31         [Refactoring] Make m_state an on-stack object
32         https://bugs.webkit.org/show_bug.cgi?id=109909
33
34         Reviewed by Antti Koivisto.
35
36         Mode m_state, an instance of StyleResolver::State, an on-stack object.
37         The state is only required in styleForElement, styleForKeyframe and
38         so on. No need to keep the state outside of those methods.
39
40         No new tests, because just refactoring.
41
42         * css/BasicShapeFunctions.cpp:
43         (WebCore::convertToLength):
44         (WebCore::basicShapeForValue):
45         * css/BasicShapeFunctions.h:
46         (WebCore):
47         Replaced StyleResolver* with StyleResolver::State&.
48         * css/CSSGradientValue.cpp:
49         (WebCore::CSSGradientValue::gradientWithStylesResolved):
50         * css/CSSGradientValue.h:
51         (CSSGradientValue):
52         Replaced StyleResolver* with StyleResolver::State&.
53         * css/CSSToStyleMap.cpp:
54         (WebCore::CSSToStyleMap::style):
55         (WebCore::CSSToStyleMap::rootElementStyle):
56         (WebCore::CSSToStyleMap::useSVGZoomRules):
57         (WebCore::CSSToStyleMap::styleImage):
58         * css/CSSToStyleMap.h:
59         (WebCore):
60         (WebCore::CSSToStyleMap::CSSToStyleMap):
61         (CSSToStyleMap):
62         Replaced StyleResolver* with StyleResolver::State&.
63         * css/SVGCSSStyleSelector.cpp:
64         (WebCore::StyleResolver::applySVGProperty):
65         Replaced m_state with state which is given as an argument of
66         applySVGProperty.
67         * css/StyleBuilder.cpp:
68         (WebCore::ApplyPropertyExpanding::applyInheritValue):
69         (WebCore::ApplyPropertyExpanding::applyInitialValue):
70         (WebCore::ApplyPropertyExpanding::applyValue):
71         (WebCore::ApplyPropertyDefaultBase::applyInheritValue):
72         (WebCore::ApplyPropertyDefaultBase::applyInitialValue):
73         (WebCore::ApplyPropertyDefaultBase::applyValue):
74         (WebCore::ApplyPropertyDefault::applyValue):
75         (WebCore::ApplyPropertyNumber::applyValue):
76         (WebCore::ApplyPropertyStyleImage::applyValue):
77         (WebCore::ApplyPropertyAuto::applyInheritValue):
78         (WebCore::ApplyPropertyAuto::applyInitialValue):
79         (WebCore::ApplyPropertyAuto::applyValue):
80         (WebCore::ApplyPropertyClip::convertToLength):
81         (WebCore::ApplyPropertyClip::applyInheritValue):
82         (WebCore::ApplyPropertyClip::applyInitialValue):
83         (WebCore::ApplyPropertyClip::applyValue):
84         (WebCore::ApplyPropertyColor::applyInheritValue):
85         (WebCore::ApplyPropertyColor::applyInitialValue):
86         (WebCore::ApplyPropertyColor::applyValue):
87         (WebCore::ApplyPropertyColor::applyColorValue):
88         (WebCore::ApplyPropertyDirection::applyValue):
89         (WebCore::ApplyPropertyLength::applyValue):
90         (WebCore::ApplyPropertyString::applyValue):
91         (WebCore::ApplyPropertyBorderRadius::applyValue):
92         (WebCore::ApplyPropertyFillLayer::applyInheritValue):
93         (WebCore::ApplyPropertyFillLayer::applyInitialValue):
94         (WebCore::ApplyPropertyFillLayer::applyValue):
95         (WebCore::ApplyPropertyComputeLength::applyValue):
96         (WebCore::ApplyPropertyFont::applyInheritValue):
97         (WebCore::ApplyPropertyFont::applyInitialValue):
98         (WebCore::ApplyPropertyFont::applyValue):
99         (WebCore::ApplyPropertyFontSize::applyInheritValue):
100         (WebCore::ApplyPropertyFontSize::applyInitialValue):
101         (WebCore::ApplyPropertyFontSize::applyValue):
102         (WebCore::ApplyPropertyFontWeight::applyValue):
103         (WebCore::ApplyPropertyFontVariantLigatures::applyInheritValue):
104         (WebCore::ApplyPropertyFontVariantLigatures::applyInitialValue):
105         (WebCore::ApplyPropertyFontVariantLigatures::applyValue):
106         (WebCore::ApplyPropertyBorderImage::applyValue):
107         (WebCore::ApplyPropertyBorderImageModifier::applyInheritValue):
108         (WebCore::ApplyPropertyBorderImageModifier::applyInitialValue):
109         (WebCore::ApplyPropertyBorderImageModifier::applyValue):
110         (WebCore::ApplyPropertyBorderImageSource::applyValue):
111         (WebCore::ApplyPropertyCounter::emptyFunction):
112         (WebCore::ApplyPropertyCounter::applyInheritValue):
113         (WebCore::ApplyPropertyCounter::applyValue):
114         (WebCore::ApplyPropertyCursor::applyInheritValue):
115         (WebCore::ApplyPropertyCursor::applyInitialValue):
116         (WebCore::ApplyPropertyCursor::applyValue):
117         (WebCore::ApplyPropertyTextAlign::applyValue):
118         (WebCore::ApplyPropertyTextDecoration::applyValue):
119         (WebCore::ApplyPropertyLineHeight::applyValue):
120         (WebCore::ApplyPropertyPageSize::applyInheritValue):
121         (WebCore::ApplyPropertyPageSize::applyInitialValue):
122         (WebCore::ApplyPropertyPageSize::applyValue):
123         (WebCore::ApplyPropertyTextEmphasisStyle::applyInheritValue):
124         (WebCore::ApplyPropertyTextEmphasisStyle::applyInitialValue):
125         (WebCore::ApplyPropertyTextEmphasisStyle::applyValue):
126         (WebCore::ApplyPropertyAnimation::map):
127         (WebCore::ApplyPropertyAnimation::applyInheritValue):
128         (WebCore::ApplyPropertyAnimation::applyInitialValue):
129         (WebCore::ApplyPropertyAnimation::applyValue):
130         (WebCore::ApplyPropertyOutlineStyle::applyInheritValue):
131         (WebCore::ApplyPropertyOutlineStyle::applyInitialValue):
132         (WebCore::ApplyPropertyOutlineStyle::applyValue):
133         (WebCore::ApplyPropertyResize::applyValue):
134         (WebCore::ApplyPropertyVerticalAlign::applyValue):
135         (WebCore::ApplyPropertyAspectRatio::applyInheritValue):
136         (WebCore::ApplyPropertyAspectRatio::applyInitialValue):
137         (WebCore::ApplyPropertyAspectRatio::applyValue):
138         (WebCore::ApplyPropertyZoom::resetEffectiveZoom):
139         (WebCore::ApplyPropertyZoom::applyInheritValue):
140         (WebCore::ApplyPropertyZoom::applyInitialValue):
141         (WebCore::ApplyPropertyZoom::applyValue):
142         (WebCore::ApplyPropertyDisplay::isValidDisplayValue):
143         (WebCore::ApplyPropertyDisplay::applyInheritValue):
144         (WebCore::ApplyPropertyDisplay::applyInitialValue):
145         (WebCore::ApplyPropertyDisplay::applyValue):
146         (WebCore::ApplyPropertyClipPath::applyValue):
147         (WebCore::ApplyPropertyExclusionShape::applyValue):
148         (WebCore::ApplyPropertyImageResolution::applyInheritValue):
149         (WebCore::ApplyPropertyImageResolution::applyInitialValue):
150         (WebCore::ApplyPropertyImageResolution::applyValue):
151         * css/StyleBuilder.h:
152         (WebCore):
153         (PropertyHandler):
154         (WebCore::PropertyHandler::applyInheritValue):
155         (WebCore::PropertyHandler::applyInitialValue):
156         (WebCore::PropertyHandler::applyValue):
157         Replaced StyleResolver* with StyleResolver::State&.
158         * css/StyleResolver.cpp:
159         (WebCore):
160         (WebCore::StyleResolver::StyleResolver):
161         Removed m_styleMap. Now m_styleMap is an on-stack object.
162         (WebCore::StyleResolver::collectMatchingRules):
163         (WebCore::StyleResolver::collectMatchingRulesForRegion):
164         (WebCore::StyleResolver::sortAndTransferMatchedRules):
165         (WebCore::StyleResolver::matchScopedAuthorRules):
166         (WebCore::StyleResolver::styleSharingCandidateMatchesHostRules):
167         (WebCore::StyleResolver::matchHostRules):
168         (WebCore::StyleResolver::matchAuthorRules):
169         (WebCore::StyleResolver::matchUserRules):
170         (WebCore::StyleResolver::matchUARules):
171         (WebCore::StyleResolver::collectMatchingRulesForList):
172         (WebCore::StyleResolver::sortMatchedRules):
173         (WebCore::StyleResolver::matchAllRules):
174         (WebCore::StyleResolver::initElement):
175         (WebCore::StyleResolver::styleSharingCandidateMatchesRuleSet):
176         (WebCore::StyleResolver::canShareStyleWithControl):
177         (WebCore::StyleResolver::sharingCandidateHasIdenticalStyleAffectingAttributes):
178         (WebCore::StyleResolver::canShareStyleWithElement):
179         (WebCore::StyleResolver::findSiblingForStyleSharing):
180         (WebCore::StyleResolver::locateSharedStyle):
181         (WebCore::StyleResolver::styleForElement):
182         (WebCore::StyleResolver::styleForKeyframe):
183         (WebCore::StyleResolver::keyframeStylesForAnimation):
184         (WebCore::StyleResolver::pseudoStyleForElement):
185         (WebCore::StyleResolver::styleForPage):
186         (WebCore::StyleResolver::defaultStyleForElement):
187         (WebCore::StyleResolver::adjustRenderStyle):
188         (WebCore::StyleResolver::updateFont):
189         (WebCore::StyleResolver::pseudoStyleRulesForElement):
190         (WebCore::StyleResolver::ruleMatches):
191         (WebCore::StyleResolver::checkRegionSelector):
192         (WebCore::StyleResolver::applyProperties):
193         (WebCore::StyleResolver::applyMatchedProperties):
194         (WebCore::StyleResolver::isLeftPage):
195         (WebCore::StyleResolver::applyPropertyWithNullCheck):
196         (WebCore::StyleResolver::applyFontPropertyToStyle):
197         (WebCore::StyleResolver::resolveVariables):
198         (WebCore::StyleResolver::applyProperty):
199         (WebCore::StyleResolver::styleImage):
200         (WebCore::StyleResolver::cachedOrPendingFromValue):
201         (WebCore::StyleResolver::generatedOrPendingFromValue):
202         (WebCore::StyleResolver::setOrPendingFromValue):
203         (WebCore::StyleResolver::cursorOrPendingFromValue):
204         (WebCore::StyleResolver::checkForTextSizeAdjust):
205         (WebCore::StyleResolver::checkForZoomChange):
206         (WebCore::StyleResolver::checkForGenericFamilyChange):
207         (WebCore::StyleResolver::initializeFontStyle):
208         (WebCore::StyleResolver::setFontSize):
209         (WebCore::StyleResolver::colorFromPrimitiveValue):
210         (WebCore::StyleResolver::loadPendingSVGDocuments):
211         (WebCore::StyleResolver::styleShader):
212         (WebCore::StyleResolver::cachedOrPendingStyleShaderFromValue):
213         (WebCore::StyleResolver::loadPendingShaders):
214         (WebCore::StyleResolver::parseCustomFilterTransformParameter):
215         (WebCore::StyleResolver::parseCustomFilterParameter):
216         (WebCore::StyleResolver::parseCustomFilterParameterList):
217         (WebCore::StyleResolver::createCustomFilterOperationWithInlineSyntax):
218         (WebCore::StyleResolver::createCustomFilterOperation):
219         (WebCore::StyleResolver::createFilterOperations):
220         (WebCore::StyleResolver::loadPendingImage):
221         (WebCore::StyleResolver::loadPendingImages):
222         (WebCore::StyleResolver::loadPendingResources):
223         Just replaced m_state with state and added one more parameter to
224         provide the state.
225         (WebCore::StyleResolver::reportMemoryUsage):
226         Since m_state was removed, removed a code for reporting m_state's
227         memory usage.
228         * css/StyleResolver.h:
229         (StyleResolver):
230         (WebCore::StyleResolver::isRightPage):
231         (WebCore::StyleResolver::State::State):
232         (WebCore::StyleResolver::State::document):
233         Since State::m_element is not always available (sometimes, 0),
234         added m_document to State and modified to return the m_document.
235         (WebCore::StyleResolver::State::useSVGZoomRules):
236         Moved StyleResolver to State.
237         (State):
238         * html/canvas/CanvasRenderingContext2D.cpp:
239         (WebCore::CanvasRenderingContext2D::setFont):
240         Moved the code, updating a style by using a given StylePropertySet,
241         to StyleResolver.
242
243 2013-02-20  Ojan Vafai  <ojan@chromium.org>
244
245         AutoTableLayout applies min-width redundantly with RenderTable
246         https://bugs.webkit.org/show_bug.cgi?id=110426
247
248         Reviewed by Emil A Eklund.
249
250         * rendering/AutoTableLayout.cpp:
251         (WebCore::AutoTableLayout::computePreferredLogicalWidths):
252         This code used to do something, but has since been superceded by
253         code in RenderTable::computePreferredLogicalWidths.
254
255 2013-02-20  Dirk Schulze  <krit@webkit.org>
256
257         Enable CANVAS_PATH flag
258         https://bugs.webkit.org/show_bug.cgi?id=108508
259
260         Uneviewed attempt to fix Qt minimal build.
261
262         * html/canvas/DOMPath.h:
263         (WebCore::DOMPath::DOMPath):
264
265 \2013-02-20  Mark Lam  <mark.lam@apple.com>
266
267         Rename DatabaseBackendAsync to DatabaseBackend.
268         https://bugs.webkit.org/show_bug.cgi?id=110422.
269
270         Reviewed by Geoffrey Garen.
271
272         This is a purely cosmetic change to make the naming consistent with
273         the front-end Database.
274
275         No new tests.
276
277         * CMakeLists.txt:
278         * GNUmakefile.list.am:
279         * Modules/webdatabase/ChangeVersionWrapper.cpp:
280         (WebCore::ChangeVersionWrapper::performPreflight):
281         (WebCore::ChangeVersionWrapper::performPostflight):
282         * Modules/webdatabase/Database.cpp:
283         (WebCore::Database::Database):
284         (WebCore::Database::from):
285         (WebCore::Database::backend):
286         * Modules/webdatabase/Database.h:
287         * Modules/webdatabase/DatabaseBackend.cpp: Copied from Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.cpp.
288         (WebCore::DatabaseBackend::DatabaseBackend):
289         (WebCore::DatabaseBackend::openAndVerifyVersion):
290         (WebCore::DatabaseBackend::performOpenAndVerify):
291         (WebCore::DatabaseBackend::close):
292         (WebCore::DatabaseBackend::runTransaction):
293         (WebCore::DatabaseBackend::inProgressTransactionCompleted):
294         (WebCore::DatabaseBackend::scheduleTransaction):
295         (WebCore::DatabaseBackend::scheduleTransactionStep):
296         (WebCore::DatabaseBackend::transactionClient):
297         (WebCore::DatabaseBackend::transactionCoordinator):
298         * Modules/webdatabase/DatabaseBackend.h: Copied from Source/WebCore/Modules/webdatabase/DatabaseBackendAsync.h.
299         * Modules/webdatabase/DatabaseBackendAsync.cpp: Removed.
300         * Modules/webdatabase/DatabaseBackendAsync.h: Removed.
301         * Modules/webdatabase/DatabaseBackendBase.cpp:
302         (WebCore::DatabaseBackendBase::~DatabaseBackendBase):
303         * Modules/webdatabase/DatabaseManager.cpp:
304         * Modules/webdatabase/DatabaseServer.cpp:
305         * Modules/webdatabase/DatabaseTask.cpp:
306         (WebCore::DatabaseTask::DatabaseTask):
307         (WebCore::DatabaseBackend::DatabaseOpenTask::DatabaseOpenTask):
308         (WebCore::DatabaseBackend::DatabaseOpenTask::doPerformTask):
309         (WebCore::DatabaseBackend::DatabaseOpenTask::debugTaskName):
310         (WebCore::DatabaseBackend::DatabaseCloseTask::DatabaseCloseTask):
311         (WebCore::DatabaseBackend::DatabaseCloseTask::doPerformTask):
312         (WebCore::DatabaseBackend::DatabaseCloseTask::debugTaskName):
313         (WebCore::DatabaseBackend::DatabaseTransactionTask::DatabaseTransactionTask):
314         (WebCore::DatabaseBackend::DatabaseTransactionTask::~DatabaseTransactionTask):
315         (WebCore::DatabaseBackend::DatabaseTransactionTask::doPerformTask):
316         (WebCore::DatabaseBackend::DatabaseTransactionTask::debugTaskName):
317         (WebCore::DatabaseBackend::DatabaseTableNamesTask::DatabaseTableNamesTask):
318         (WebCore::DatabaseBackend::DatabaseTableNamesTask::doPerformTask):
319         (WebCore::DatabaseBackend::DatabaseTableNamesTask::debugTaskName):
320         * Modules/webdatabase/DatabaseTask.h:
321         (WebCore::DatabaseTask::database):
322         (DatabaseTask):
323         (WebCore::DatabaseBackend::DatabaseOpenTask::create):
324         (DatabaseBackend::DatabaseOpenTask):
325         (WebCore::DatabaseBackend::DatabaseCloseTask::create):
326         (DatabaseBackend::DatabaseCloseTask):
327         (WebCore::DatabaseBackend::DatabaseTableNamesTask::create):
328         (DatabaseBackend::DatabaseTableNamesTask):
329         * Modules/webdatabase/DatabaseThread.cpp:
330         (WebCore::DatabaseThread::recordDatabaseOpen):
331         (WebCore::DatabaseThread::recordDatabaseClosed):
332         (WebCore::SameDatabasePredicate::SameDatabasePredicate):
333         (SameDatabasePredicate):
334         (WebCore::DatabaseThread::unscheduleDatabaseTasks):
335         * Modules/webdatabase/DatabaseThread.h:
336         * Modules/webdatabase/SQLStatementBackend.cpp:
337         (WebCore::SQLStatementBackend::execute):
338         (WebCore::SQLStatementBackend::setDatabaseDeletedError):
339         (WebCore::SQLStatementBackend::setVersionMismatchedError):
340         (WebCore::SQLStatementBackend::setFailureDueToQuota):
341         * Modules/webdatabase/SQLStatementBackend.h:
342         * Modules/webdatabase/SQLTransactionBackend.cpp:
343         (WebCore::SQLTransactionBackend::create):
344         (WebCore::SQLTransactionBackend::SQLTransactionBackend):
345         * Modules/webdatabase/SQLTransactionBackend.h:
346         (WebCore::SQLTransactionBackend::database):
347         * Modules/webdatabase/SQLTransactionCoordinator.cpp:
348         (WebCore::getDatabaseIdentifier):
349         * Target.pri:
350         * WebCore.gypi:
351         * WebCore.vcproj/WebCore.vcproj:
352         * WebCore.vcxproj/WebCore.vcxproj:
353         * WebCore.vcxproj/WebCore.vcxproj.filters:
354         * WebCore.xcodeproj/project.pbxproj:
355
356 2013-02-20  David Kilzer  <ddkilzer@apple.com>
357
358         Upstream SharedTimerIOS.mm
359         <http://webkit.org/b/110161>
360
361         Reviewed by Benjamin Poulain.
362
363         * Configurations/WebCore.xcconfig:
364         (EXCLUDED_SOURCE_FILE_NAMES_iphoneos): Add SharedTimerMac.mm.
365         * WebCore.xcodeproj/project.pbxproj: Add SharedTimerIOS.mm.
366         * platform/ios/SharedTimerIOS.mm: Add.
367         (WebCore):
368         (-[WebCoreResumeNotifierIOS init]):
369         (-[WebCoreResumeNotifierIOS dealloc]):
370         (-[WebCoreResumeNotifierIOS didWake]):
371         (WebCore::setSharedTimerFiredFunction):
372         (WebCore::timerFired):
373         (WebCore::setSharedTimerFireInterval):
374         (WebCore::stopSharedTimer):
375
376 2013-02-20  Ojan Vafai  <ojan@chromium.org>
377
378         Speculative fix for EFL and Windows compilers not realizing
379         that all possible cases have a return value from this switch.
380
381         * rendering/RenderBox.cpp:
382         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
383
384 2013-02-20  David Hyatt  <hyatt@apple.com>
385
386         [New Multicolumn] Fix overflow computation for column blocks.
387         https://bugs.webkit.org/show_bug.cgi?id=110392.
388
389         Reviewed by Simon Fraser.
390
391         * rendering/RenderBox.cpp:
392         (WebCore::RenderBox::addOverflowFromChild):
393         Exclude in-flow RenderFlowThreads from overflow propagation.
394
395         * rendering/RenderMultiColumnSet.h:
396         * rendering/RenderRegion.h:
397         (WebCore::RenderRegion::shouldHaveAutoLogicalHeight):
398          * rendering/RenderRegionSet.h:
399         (RenderRegionSet):
400         Override shouldHaveAutoLogicalHeight to always be false
401         for region sets and for columns. Eventually we're going to try
402         to leverage this code to do column balancing, and that's why
403         RenderMultiColumnSet has a unique override.
404
405 2013-02-20  Brandon Jones  <bajones@google.com>
406  
407         Printing WebGL canvases in Chrome uses stale data after first print
408         https://bugs.webkit.org/show_bug.cgi?id=110003
409  
410         Reviewed by Kenneth Russell.
411  
412         Unable to validate printed content automatically. No regression in existing WebGL tests.
413  
414          * html/canvas/WebGLRenderingContext.cpp:
415          (WebCore):
416          (WebCore::WebGLRenderingContext::paintRenderingResultsToCanvas):
417
418 2013-02-20  Christian Biesinger  <cbiesinger@chromium.org>
419
420         Incorrect rendering for flex boxes with percentage height in a table cell
421         https://bugs.webkit.org/show_bug.cgi?id=110389
422
423         Reviewed by Tony Chang.
424
425         Tests: css3/flexbox/flex-percentage-height-in-table-standards-mode.html
426                css3/flexbox/flex-percentage-height-in-table.html
427
428         * rendering/RenderFlexibleBox.cpp:
429         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
430         Always update the logical height of the flex box, not just when it is
431         auto. If necessary, the later updateLogicalHeight() call will adjust
432         it.
433
434 2013-02-20  Philip Rogers  <pdr@google.com>
435
436         Account for transform in SVG background images
437         https://bugs.webkit.org/show_bug.cgi?id=110295
438
439         Reviewed by Dirk Schulze.
440
441         Tiled SVG background images are rendererd by drawing the SVG content into a temporary
442         image buffer, then stamping out a tiled pattern using this buffer. Previously the
443         image buffer did not account for CSS transforms which could result in pixelated backgrounds.
444
445         This patch takes advantage of the context's transform when sizing the temporary tiling
446         image buffer. Because the context's transform also includes scale, this patch simplifies
447         the SVG image code to no longer track scale.
448
449         Test: svg/as-background-image/svg-transformed-background.html
450
451         * loader/cache/CachedImage.cpp:
452         (WebCore):
453         (WebCore::CachedImage::imageForRenderer):
454
455             CachedImage::lookupOrCreateImageForRenderer no longer creates images so it has been
456             refactored into just "imageForRenderer". Previously there were two versions of
457             lookupOrCreateImageForRenderer; these have been folded into imageForRenderer.
458
459         * loader/cache/CachedImage.h:
460         * svg/graphics/SVGImage.cpp:
461         (WebCore::SVGImage::drawPatternForContainer):
462
463             To create the temporary tiling image buffer, the final size in screen coordinates is
464             needed. This is now computed using the current context's CTM. Because the CTM
465             already includes the page scale, all page scale tracking can be removed.
466
467             The adjustments to srcRect and the pattern transform are the same as before, just
468             refactored to use imageBufferScale which has x and y components.
469
470         * svg/graphics/SVGImage.h:
471         * svg/graphics/SVGImageCache.cpp:
472         (WebCore::SVGImageCache::setContainerSizeForRenderer):
473
474             Because the page scale needed to be cached between calls to
475             setContainerSizeForRenderer, this function was written to modify an existing cache
476             entry. Because the page scale no longer needs to be tracked, this code has been
477             simplified to re-write any existing cache entry.
478
479         (WebCore::SVGImageCache::imageSizeForRenderer):
480
481             This function has been simplified by calling SVGImageForContainer::size() instead
482             of computing this value manually. The value returned remains the same, containing
483             the container size multiplied by zoom.
484
485         (WebCore::SVGImageCache::imageForRenderer):
486
487             Previously we set the page scale on every call to imageForRenderer. Because page scale
488             no longer needs to be tracked, this function has been simplified to simply return
489             the cached SVGImageForContainer.
490
491         * svg/graphics/SVGImageForContainer.cpp:
492         (WebCore::SVGImageForContainer::drawPattern):
493         * svg/graphics/SVGImageForContainer.h:
494         (WebCore::SVGImageForContainer::create):
495         (WebCore::SVGImageForContainer::SVGImageForContainer):
496         (SVGImageForContainer):
497
498 2013-02-20  Jer Noble  <jer.noble@apple.com>
499
500         Crash in com.apple.WebKit2.WebProcessService at com.apple.avfoundation: __73-[AVAssetResourceLoader _attemptDelegateHandlingOfRequestWithDictionary:]_block_invoke + 51
501         https://bugs.webkit.org/show_bug.cgi?id=110385
502
503         Reviewed by Eric Carlson.
504
505         Ensure AVFoundation does not attempt to message a dead object by explicitly disassociating
506         the AVAssetResourceLoaderDelegate on MediaPlayerPrivateAVFoundationObjC destruction.
507
508         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
509         (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC):
510
511 2013-02-20  Ojan Vafai  <ojan@chromium.org>
512
513         Positioned, replaced elements with intrinsic width keywords compute the wrong width
514         https://bugs.webkit.org/show_bug.cgi?id=110393
515
516         Reviewed by Emil A Eklund.
517
518         Test: fast/css-intrinsic-dimensions/intrinsic-sized-replaced-absolutes.html
519
520         * rendering/RenderBox.cpp:
521         (WebCore::RenderBox::computeReplacedLogicalWidthUsing):
522         Add the intrinsic size keywords to the switch. Confusingly, we have to
523         subtract the border and padding since the callers expect the content width.
524
525         * rendering/RenderReplaced.cpp:
526         (WebCore::RenderReplaced::computeReplacedLogicalWidth):
527         Don't do the intrinsic ratio calculation if the width is an
528         intrinsic width keyword, as per, http://dev.w3.org/csswg/css3-sizing/#replaced-intrinsic.
529
530         (WebCore::RenderReplaced::computeIntrinsicLogicalWidths):
531         (WebCore::RenderReplaced::computePreferredLogicalWidths):
532         The old code was trying to apply the intrinsic ratio calculation to
533         the intrinsic width, which is wrong per spec.
534
535 2013-02-20  Alec Flett  <alecflett@chromium.org>
536
537         LevelDB: Remove excess vector copy
538         https://bugs.webkit.org/show_bug.cgi?id=110399
539
540         Reviewed by Tony Chang.
541
542         Remove an extra copy introduced by the makeVector function.
543
544         No new tests, this is covered by existing tests.
545
546         * platform/leveldb/LevelDBDatabase.cpp:
547         (WebCore::LevelDBDatabase::safeGet):
548
549 2013-02-20  Simon Fraser  <simon.fraser@apple.com>
550
551         Zoomed, slow-scrolling pages keep recreating tiles when scrolled
552         https://bugs.webkit.org/show_bug.cgi?id=110379
553
554         Reviewed by Tim Horton.
555
556         On slow-scrolling pages the TileCache makes the tiles the size of
557         the visible rect to minimize per-tile painting overhead. If the size
558         of that rect changes, the TileCache re-creates all the tiles.
559         
560         This was a problem whem zoomed, because mapping the visible rect
561         through the scale transform and then rounding it would cause the
562         size to keep changing, causing lots of tile re-creation.
563         
564         Fix by carrying the visibleRect around as a FloatRect, and doing
565         the same for the exposedRect. We then only expand to integers
566         when computing the tile size. This also fixes an issue where we could
567         sometimes make extra tiles because of fractional bits of tiles at the edges,
568         as shown by the test result change.
569
570         * platform/graphics/TiledBacking.h:
571         * platform/graphics/ca/GraphicsLayerCA.cpp:
572         (WebCore::GraphicsLayerCA::updateVisibleRect):
573         * platform/graphics/ca/mac/TileCache.h:
574         * platform/graphics/ca/mac/TileCache.mm:
575         (WebCore::TileCache::setVisibleRect):
576         (WebCore::TileCache::setExposedRect):
577         (WebCore::TileCache::prepopulateRect):
578         (WebCore::TileCache::computeTileCoverageRect):
579         (WebCore::TileCache::tileSizeForCoverageRect):
580         (WebCore::TileCache::blankPixelCountForTiles):
581         (WebCore::TileCache::revalidateTiles):
582         (WebCore::TileCache::ensureTilesForRect):
583         * platform/graphics/ca/mac/WebTileLayer.mm:
584         (-[WebTileLayer logFilledFreshTile]):
585
586 2013-02-20  Julien Chaffraix  <jchaffraix@webkit.org>
587
588         [CSS Grid Layout] Implement the auto-placement algorithm without grid growth
589         https://bugs.webkit.org/show_bug.cgi?id=110277
590
591         Reviewed by Tony Chang.
592
593         Tests: fast/css-grid-layout/grid-item-addition-auto-placement-update.html
594                fast/css-grid-layout/grid-item-removal-auto-placement-update.html
595                fast/css-grid-layout/grid-auto-flow-resolution.html (extended to cover more cases)
596
597         This change implements most of the auto-placement algorithm per
598         http://dev.w3.org/csswg/css3-grid-layout/#auto-placement-algo
599
600         To limit the size of the code change, it doesn't implement growing the grid if there
601         are no empty grid areas. If we don't find any empty grid areas, we just insert in the first
602         one, like what grid-auto-flow: none would do (which explains the test failures).
603
604         * rendering/RenderGrid.cpp:
605         (WebCore::RenderGrid::GridIterator::nextEmptyGridArea):
606         Added this function to return the GridCoordinate of the next empty grid area along
607         the iterator's direction.
608
609         (WebCore::RenderGrid::placeItemsOnGrid):
610         Split this function into the different steps below. For efficiency, collect the auto vs specified
611         major axis grid items in different Vectors.
612
613         (WebCore::RenderGrid::placeSpecifiedMajorAxisItemsOnGrid):
614         Added this function that implements part of step 1 of the algorithm (the grid items without
615         auto row / column are already handled in placeItemsOnGrid).
616
617         (WebCore::RenderGrid::placeAutoMajorAxisItemsOnGrid):
618         Added this function that iterates over the auto grid items and call placeAutoMajorAxisItemOnGrid.
619
620         (WebCore::RenderGrid::placeAutoMajorAxisItemOnGrid):
621         Added this method to handle the step 4 of the algorithm. Based on the minor axis's position,
622         it either walks along the major axis once or several times until it finds an empty grid area
623         for the grid item.
624
625         (WebCore::RenderGrid::autoPlacementMajorAxisPositionForChild):
626         (WebCore::RenderGrid::autoPlacementMinorAxisPositionForChild):
627         (WebCore::RenderGrid::autoPlacementMajorAxisDirection):
628         (WebCore::RenderGrid::autoPlacementMinorAxisDirection):
629         Added these helper functions that return minor / major axis positions & direction.
630
631         * rendering/RenderGrid.h:
632         Added the previous new RenderGrid functions.
633
634 2013-02-20  Vincent Scheib  <scheib@chromium.org>
635
636         Accept 'allowfullscreen' in addition to 'webkitallowfullscreen'.
637         https://bugs.webkit.org/show_bug.cgi?id=110374
638
639         Reviewed by Adam Barth.
640
641         The fullscreen API also includes a new HTML attribute for iframes
642         which permits its use. That attribute, 'allowfullcreen' is now
643         included in the HTML specification [1] and is stable enough
644         to remove the webkit prefix.
645
646         [1] http://www.whatwg.org/specs/web-apps/current-work/multipage/the-iframe-element.html#attr-iframe-allowfullscreen
647
648         Tests: fullscreen/full-screen-enabled-prefixed.html
649                fullscreen/full-screen-iframe-allowed-prefixed.html
650                fullscreen/full-screen-iframe-with-mixed-allow-webkitallow-attribute.html
651
652         * dom/Document.cpp:
653         (WebCore::isAttributeOnAllOwners):
654         (WebCore::Document::fullScreenIsAllowedForElement):
655         (WebCore::Document::webkitFullscreenEnabled):
656         * html/HTMLAttributeNames.in:
657
658 2013-02-20  Roger Fong  <roger_fong@apple.com>
659
660         Unreviewed. Remove references to SAFARI_THEME from Windows Solution.
661         <rdar://problem/13258710>
662
663         * config.h:
664         * page/Settings.cpp:
665         * page/Settings.h:
666         * platform/win/ScrollbarThemeWin.cpp:
667         * rendering/RenderThemeWin.cpp:
668
669 2013-02-20  Roger Fong  <roger_fong@apple.com>
670
671         Get VS2010 Solution B&I ready.
672         <rdar://problem/1322988>
673
674         Rubberstamped by Timothy Horton.
675
676         Add Production configuration. 
677         Add a WebCore submit solution with a DebugSuffix configuration. 
678         Modify WebCore.make as necessary.
679         
680         * DerivedSources.make:
681         * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj:
682         * WebCore.vcxproj/QTMovieWin/QTMovieWinCommon.props:
683         * WebCore.vcxproj/QTMovieWin/QTMovieWinProduction.props: Added.
684         * WebCore.vcxproj/QTMovieWin/QTMovieWinRelease.props:
685         * WebCore.vcxproj/WebCore.make: Added.
686         * WebCore.vcxproj/WebCore.sln: Removed.
687         * WebCore.vcxproj/WebCore.submit.sln: Copied from Source/WebCore/WebCore.vcxproj/WebCore.sln.
688         * WebCore.vcxproj/WebCore.vcxproj:
689         * WebCore.vcxproj/WebCoreGenerated.vcxproj:
690         * WebCore.vcxproj/WebCoreGeneratedProduction.props: Added.
691         * WebCore.vcxproj/WebCoreGeneratedRelease.props:
692         * WebCore.vcxproj/WebCoreProduction.props: Added.
693         * WebCore.vcxproj/WebCoreRelease.props:
694         * WebCore.vcxproj/WebCoreTestSupport.vcxproj:
695
696 2013-02-20  Adam Klein  <adamk@chromium.org>
697
698         [v8] Fix an erroneous WrapperGrouper call in preparation for refactoring
699         https://bugs.webkit.org/show_bug.cgi?id=110396
700
701         Reviewed by Kentaro Hara.
702
703         This is in preparation for a refactor to expose a simplified
704         WrapperGrouper interface to V8 wrapper classes enabling them to
705         specify multiple roots per wrapper object. 
706
707         * bindings/v8/V8GCController.cpp: Since MutationObservers are not Nodes, the correct call here is addObjectToGroup, as it is for all other non-Node wrappers.
708
709 2013-02-20  Levi Weintraub  <leviw@chromium.org>
710
711         Line layout (but not pref widths) double-counts word spacing when between inlines
712         https://bugs.webkit.org/show_bug.cgi?id=110381
713
714         Reviewed by Emil A Eklund.
715
716         When a word break with a space occurs between inlines and word-spacing is non-zero,
717         line layout incorrectly committed the word-spacing value to the line twice, causing
718         wrapping in inline-blocks. To fix this, clear the word-spacing value when between
719         words and ignoring spaces, as we will already have added the word-spacing to the
720         line.
721
722         Test: fast/text/word-space-between-inlines.html
723
724         * rendering/RenderBlockLineLayout.cpp:
725         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
726
727 2013-02-20  Nate Chapin  <japhet@chromium.org>
728
729         Crash in WebCore::FrameLoader::checkCompleted()
730         https://bugs.webkit.org/show_bug.cgi?id=110237
731
732         Reviewed by Abhishek Arya.
733
734         Test: http/tests/misc/delete-frame-during-readystatechange.html
735
736         * loader/FrameLoader.cpp:
737         (WebCore::FrameLoader::checkCompleted): Protect before setReadyState() is called.
738
739 2013-02-20  David Grogan  <dgrogan@chromium.org>
740
741         IndexedDB: Limit LevelDB's max open files
742         https://bugs.webkit.org/show_bug.cgi?id=109993
743
744         Reviewed by Tony Chang.
745
746         LevelDB keeps up to 1000 (by default) data files open at a time to
747         avoid having to open() them. This has caused chromium to hit the
748         process-wide open file limit. This patch changes max_open_files to 20,
749         as that's the minimum permitted by LevelDB and we have no reason to
750         think that performance will suffer because of the extra open calls.
751
752         No new tests - a chromium browser test that tracks the open LevelDB
753         files is plausible but is blocked on http://crbug.com/177249/.
754
755         * platform/leveldb/LevelDBDatabase.cpp:
756         (WebCore::openDB):
757
758 2013-02-20  David Hyatt  <hyatt@apple.com>
759
760         [New Multicolumn] Resize RenderMultiColumnSets around their columns.
761         https://bugs.webkit.org/show_bug.cgi?id=110378.
762
763         Reviewed by Dirk Schulze.
764
765         Test: fast/multicol/newmulticol/positioned-with-constrained-height.html.
766
767         * rendering/RenderBlock.h:
768         (RenderBlock):
769         Make computeOverflow public so that RenderMultiColumnFlowThread can
770         access it.
771
772         * rendering/RenderMultiColumnFlowThread.cpp:
773         (WebCore::RenderMultiColumnFlowThread::layout):
774         Subclass layout to recompute the overflow for RenderMultiColumnBlock
775         after the flow thread has finished layout. This way it can account
776         for changes in RenderMultiColumnSets without having to do a second
777         layout pass.
778
779         * rendering/RenderMultiColumnFlowThread.h:
780         (RenderMultiColumnFlowThread):
781         Override layout().
782
783         * rendering/RenderMultiColumnSet.cpp:
784         (WebCore::RenderMultiColumnSet::columnCount):
785         Clean up a comment that referred to portions as region rects still.
786
787         (WebCore::RenderMultiColumnSet::setFlowThreadPortionRect):
788         * rendering/RenderMultiColumnSet.h:
789         * rendering/RenderRegion.h:
790         (WebCore::RenderRegion::setFlowThreadPortionRect):
791         Make setFlowThreadPortionRect virtual and actually mutate the size
792         and position of RenderMultiColumnSets so that they enclose their
793         column rects.
794
795 2013-02-20  Dirk Schulze  <krit@webkit.org>
796
797         Enable CANVAS_PATH flag
798         https://bugs.webkit.org/show_bug.cgi?id=108508
799
800         Reviewed by Simon Fraser.
801
802         Enable CANVAS_PATH flag on trunk.
803
804         Existing tests cover the feature.
805
806         * Configurations/FeatureDefines.xcconfig:
807
808 2013-02-20  Sheriff Bot  <webkit.review.bot@gmail.com>
809
810         Unreviewed, rolling out r143441.
811         http://trac.webkit.org/changeset/143441
812         https://bugs.webkit.org/show_bug.cgi?id=110376
813
814         May be causing chromium content_browsertests failures.
815         (Requested by vollick on #webkit).
816
817         * bindings/v8/ScriptValue.cpp:
818         (WebCore::ScriptValue::serialize):
819         (WebCore::ScriptValue::getString):
820         (WebCore::ScriptValue::toString):
821         (WebCore::ScriptValue::toInspectorValue):
822         * bindings/v8/ScriptValue.h:
823         (WebCore::ScriptValue::ScriptValue):
824         (WebCore::ScriptValue::operator=):
825         (WebCore::ScriptValue::operator==):
826         (WebCore::ScriptValue::isEqual):
827         (WebCore::ScriptValue::isFunction):
828         (WebCore::ScriptValue::isNull):
829         (WebCore::ScriptValue::isUndefined):
830         (WebCore::ScriptValue::isObject):
831         (WebCore::ScriptValue::hasNoValue):
832         (WebCore::ScriptValue::clear):
833         (WebCore::ScriptValue::v8Value):
834         (ScriptValue):
835         * bindings/v8/SharedPersistent.h:
836         (WebCore):
837         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
838         (WebCore::InjectedScriptHost::scriptValueAsNode):
839         * bindings/v8/custom/V8MessageEventCustom.cpp:
840         (WebCore::V8MessageEvent::dataAttrGetterCustom):
841
842 2013-02-15  Dirk Schulze  <krit@webkit.org>
843
844         [Chromium] Add runtime flag for CanvasPath
845         https://bugs.webkit.org/show_bug.cgi?id=109997
846
847         Reviewed by Adam Barth.
848
849         Add runtime flag for Chromium.
850
851         * bindings/generic/RuntimeEnabledFeatures.cpp:
852         (WebCore):
853         * bindings/generic/RuntimeEnabledFeatures.h:
854         (RuntimeEnabledFeatures):
855         (WebCore::RuntimeEnabledFeatures::setCanvasPathEnabled):
856         (WebCore::RuntimeEnabledFeatures::canvasPathEnabled):
857         * html/canvas/DOMPath.idl:
858         * page/DOMWindow.idl:
859
860 2013-02-20  Laszlo Gombos  <l.gombos@samsung.com>
861
862         Remove unnecessary includes for Platform.h from headers
863         https://bugs.webkit.org/show_bug.cgi?id=110300
864
865         Reviewed by Alexey Proskuryakov.
866
867         wtf/Platform.h only need to be included in a few places directly
868         as it is included in config.h. Remove the unnecessay duplicate as
869         it can be confusing.
870
871         No new tests, no change in functionality.
872
873         * platform/SecureTextInput.h:
874         * platform/audio/Biquad.h:
875         * platform/audio/FFTFrame.h:
876         * platform/graphics/cpu/arm/filters/FEBlendNEON.h:
877         * platform/graphics/cpu/arm/filters/NEONHelpers.h:
878         * platform/graphics/filters/FELighting.h:
879
880 2013-02-20  Florin Malita  <fmalita@chromium.org>
881
882         [SVG] Update of element referenced by multiple 'use' nodes is absurdly slow
883         https://bugs.webkit.org/show_bug.cgi?id=97905
884
885         Reviewed by Dirk Schulze.
886
887         Rebuilding the shadow and instance trees of dependent use nodes recursively can be
888         extremely inefficient with non-trivial dependency graphs (the trees are not constructed
889         in topological order).
890
891         To avoid redundant buildShadowAndInstanceTree() invokations, separate the invalidation
892         phase from the actual tree (re)building phase, and only descend into the dependency DAG
893         during the invalidation phase (recursion also stops at nodes that have been previously
894         invalidated).
895
896         No new tests: functional coverage provided by existing tests, perfomance tracked by
897         PerformanceTests/SVG/SvgNestedUse.html.
898
899         * svg/SVGUseElement.cpp:
900         (WebCore::SVGUseElement::buildPendingResource):
901         (WebCore::SVGUseElement::buildShadowAndInstanceTree):
902         (WebCore::SVGUseElement::invalidateShadowTree):
903         (WebCore):
904         (WebCore::SVGUseElement::invalidateDependentShadowTrees):
905         * svg/SVGUseElement.h:
906         (SVGUseElement):
907
908 2013-02-20  Tim Horton  <timothy_horton@apple.com>
909
910         RenderLayerBacking should initialize TiledBacking's isInWindow state with Page's isInWindow, not isOnscreen
911         https://bugs.webkit.org/show_bug.cgi?id=110370
912         <rdar://problem/13254006>
913
914         Reviewed by Simon Fraser.
915
916         * rendering/RenderLayerBacking.cpp:
917         (WebCore::RenderLayerBacking::RenderLayerBacking):
918
919 2013-02-20  Mark Lam  <mark.lam@apple.com>
920
921         Cleanup the SQLTransaction and SQLTransactionBackend state dispatch
922         to only honor a state transition request if the associated database
923         hasn't been interrupted.
924         https://bugs.webkit.org/show_bug.cgi?id=110247.
925
926         Reviewed by Antti Koivisto.
927
928         No new tests.
929
930         * Modules/webdatabase/SQLTransaction.cpp:
931         (WebCore::SQLTransaction::performPendingCallback):
932         (WebCore::SQLTransaction::computeNextStateAndCleanupIfNeeded):
933         * Modules/webdatabase/SQLTransaction.h:
934         * Modules/webdatabase/SQLTransactionBackend.cpp:
935         (WebCore::SQLTransactionBackend::computeNextStateAndCleanupIfNeeded):
936         (WebCore::SQLTransactionBackend::performNextStep):
937         * Modules/webdatabase/SQLTransactionBackend.h:
938
939 2013-02-20  Alexey Proskuryakov  <ap@apple.com>
940
941         ResourceHandle::loadResourceSynchronously should have blob support in cross-platform code
942         https://bugs.webkit.org/show_bug.cgi?id=110364
943
944         Reviewed by Anders Carlsson.
945
946         * platform/network/ResourceHandle.h:
947         * platform/network/ResourceHandle.cpp: (WebCore::ResourceHandle::loadResourceSynchronously):
948         Added a cross-platform version to keep blob-related logic in one place.
949
950         * platform/network/blackberry/ResourceHandleBlackBerry.cpp:
951         (WebCore::ResourceHandle::platformLoadResourceSynchronously):
952         * platform/network/cf/ResourceHandleCFNet.cpp:
953         (WebCore::ResourceHandle::platformLoadResourceSynchronously):
954         * platform/network/curl/ResourceHandleCurl.cpp:
955         (WebCore::ResourceHandle::platformLoadResourceSynchronously):
956         * platform/network/mac/ResourceHandleMac.mm:
957         (WebCore::ResourceHandle::platformLoadResourceSynchronously):
958         * platform/network/qt/ResourceHandleQt.cpp:
959         (WebCore::ResourceHandle::platformLoadResourceSynchronously):
960         * platform/network/soup/ResourceHandleSoup.cpp:
961         (WebCore::ResourceHandle::platformLoadResourceSynchronously):
962         * platform/network/win/ResourceHandleWin.cpp:
963         (WebCore::ResourceHandle::platformLoadResourceSynchronously):
964         Renamed loadResourceSynchronously to platformLoadResourceSynchronously,
965         removed blob handling from platforms that had it.
966
967 2013-02-20  David Hyatt  <hyatt@apple.com>
968
969         [New Multicolumn] RenderMultiColumnFlowThreads should establish a BFC.
970         https://bugs.webkit.org/show_bug.cgi?id=110366.
971
972         Reviewed by Antti Koivisto.
973
974         RenderFlowThreads should establish a block formatting context always.
975         CSS Regions have named flow thread that they absolutely position, and so
976         they got this for free by being absolutely positioned.
977         
978         RenderMultiColumnFlowThreads, however, are relative positioned, so we need
979         to just add an isRenderFlowThread case specifically so we're not dependent
980         on the positioning scheme used for the flow thread to establish the BFC.
981         
982         Test: fast/multicol/newmulticol/float-*.html.
983
984         * rendering/RenderBlock.cpp:
985         (WebCore::RenderBlock::MarginInfo::MarginInfo):
986
987 2013-02-20  David Hyatt  <hyatt@apple.com>
988
989         [New Multicolumn] Column gap is computed incorrectly.
990         https://bugs.webkit.org/show_bug.cgi?id=110360.
991
992         Reviewed by Simon Fraser.
993
994         Test: fast/multicol/newmulticol/layers-split-across-columns.html.
995
996         * rendering/RenderMultiColumnSet.cpp:
997         (WebCore::RenderMultiColumnSet::columnGap):
998         Make sure we ask the RenderMultiColumnBlock for the gap rather than our
999         own style, since we don't actually have the gap value in our style.
1000         
1001         (WebCore::RenderMultiColumnSet::flowThreadPortionOverflowRect):
1002         * rendering/RenderMultiColumnSet.h:
1003         Fix another spot where the columnGap was an int. It should be a LayoutUnit.
1004
1005 2013-02-20  Robert Hogan  <robert@webkit.org>
1006
1007         No caret on empty contenteditable element with negative text-indent
1008         https://bugs.webkit.org/show_bug.cgi?id=108633
1009
1010         Reviewed by Ryosuke Niwa.
1011
1012         Test: fast/repaint/paint-caret-in-div-with-negative-indent.html
1013
1014         When an editable element has a negative text indent we won't paint the caret when the
1015         element is empty because it falls outside the element's border box. To ensure the caret is painted,
1016         account for any negative indent with our overflow.
1017
1018         * rendering/RenderBlock.cpp:
1019         (WebCore::RenderBlock::computeOverflow):
1020
1021 2013-02-20  Ojan Vafai  <ojan@chromium.org>
1022
1023         Remove stretchesToMinIntrinsicLogicalWidth
1024         https://bugs.webkit.org/show_bug.cgi?id=110266
1025
1026         Reviewed by Emil Eklund.
1027
1028         This was only used by fieldsets and now we have a way to express this
1029         concept in CSS.
1030
1031         * WebCore.order:
1032         * css/html.css:
1033         Make fieldsets min-width: -webkit-min-content.
1034
1035         * rendering/RenderBox.cpp:
1036         (WebCore::RenderBox::computeLogicalWidthInRegion):
1037         (WebCore::RenderBox::computePositionedLogicalWidth):
1038         * rendering/RenderBox.h:
1039         Remove all calls to stretchesToMinIntrinsicLogicalWidth.
1040
1041 2013-02-20  Ojan Vafai  <ojan@chromium.org>
1042
1043         Make intrinsic width values work for positioned elements
1044         https://bugs.webkit.org/show_bug.cgi?id=110264
1045
1046         Reviewed by Tony Chang.
1047
1048         Tests: fast/css-intrinsic-dimensions/intrinsic-sized-absolutes.html
1049                fast/css-intrinsic-dimensions/width-shrinks-avoid-floats.html
1050
1051         * rendering/RenderBox.cpp:
1052         (WebCore::RenderBox::computeIntrinsicLogicalWidthUsing):
1053         (WebCore::RenderBox::computeLogicalWidthInRegionUsing):
1054         Move the computation of intrinsic widths out into a helper function so that
1055         computePositionedLogicalWidthUsing can use it. As per the current spec,
1056         fill-available measures shrink to avoid floats. http://dev.w3.org/csswg/css3-sizing/
1057
1058         (WebCore::RenderBox::computePositionedLogicalWidth):
1059         Compute intrinsic min-widths in addition to non-zero ones. Intrinsic widths
1060         return true for isZero. width and max-width don't need modifying since they already
1061         call computePositionedLogicalWidthUsing for intrinsic widths.
1062
1063         (WebCore::RenderBox::computePositionedLogicalWidthUsing):
1064         Compute intrinsic widths and use a Fixed length for the rest of the positioned width
1065         computation. Doesn't include bordersPlusPadding because the caller, expected the content
1066         width and adds in the bordersPlusPadding later.
1067
1068         * rendering/RenderBox.h:
1069
1070 2013-02-20  Robert Hogan  <robert@webkit.org>
1071
1072         input element with placeholder text and width set to 100% on focus causes overflow even after losing focus
1073         https://bugs.webkit.org/show_bug.cgi?id=109020
1074
1075         Reviewed by David Hyatt.
1076
1077         Tests: fast/forms/input-placeholder-layout-view.html
1078                fast/forms/textarea-placeholder-layout-view.html
1079
1080         Placeholder elements don't affect layout so shouldn't contribute overflow either.
1081
1082         * rendering/RenderTextControlSingleLine.cpp:
1083         (WebCore::RenderTextControlSingleLine::layout):
1084
1085 2013-02-20  Mark Lam  <mark.lam@apple.com>
1086
1087         Rename DatabaseBackend to DatabaseBackendBase.
1088         https://bugs.webkit.org/show_bug.cgi?id=110303.
1089
1090         Rubber stamped by Alexey Proskuryakov.
1091
1092         This is a purely cosmetic change to make the naming consistent with
1093         the front-end DatabaseBase.
1094
1095         No new tests.
1096
1097         * CMakeLists.txt:
1098         * GNUmakefile.list.am:
1099         * Modules/webdatabase/AbstractDatabaseServer.h:
1100         * Modules/webdatabase/Database.cpp:
1101         (WebCore::Database::create):
1102         (WebCore::Database::version):
1103         * Modules/webdatabase/Database.h:
1104         (Database):
1105         * Modules/webdatabase/DatabaseBackend.cpp: Removed.
1106         * Modules/webdatabase/DatabaseBackend.h: Removed.
1107         * Modules/webdatabase/DatabaseBackendAsync.cpp:
1108         (WebCore::DatabaseBackendAsync::DatabaseBackendAsync):
1109         (WebCore::DatabaseBackendAsync::performOpenAndVerify):
1110         * Modules/webdatabase/DatabaseBackendAsync.h:
1111         * Modules/webdatabase/DatabaseBackendBase.cpp: Copied from Source/WebCore/Modules/webdatabase/DatabaseBackend.cpp.
1112         (WebCore::DatabaseBackendBase::databaseInfoTableName):
1113         (WebCore::DatabaseBackendBase::DatabaseBackendBase):
1114         (WebCore::DatabaseBackendBase::~DatabaseBackendBase):
1115         (WebCore::DatabaseBackendBase::closeDatabase):
1116         (WebCore::DatabaseBackendBase::version):
1117         (WebCore::DoneCreatingDatabaseOnExitCaller::DoneCreatingDatabaseOnExitCaller):
1118         (DoneCreatingDatabaseOnExitCaller):
1119         (WebCore::DatabaseBackendBase::performOpenAndVerify):
1120         (WebCore::DatabaseBackendBase::securityOrigin):
1121         (WebCore::DatabaseBackendBase::stringIdentifier):
1122         (WebCore::DatabaseBackendBase::displayName):
1123         (WebCore::DatabaseBackendBase::estimatedSize):
1124         (WebCore::DatabaseBackendBase::fileName):
1125         (WebCore::DatabaseBackendBase::details):
1126         (WebCore::DatabaseBackendBase::getVersionFromDatabase):
1127         (WebCore::DatabaseBackendBase::setVersionInDatabase):
1128         (WebCore::DatabaseBackendBase::setExpectedVersion):
1129         (WebCore::DatabaseBackendBase::getCachedVersion):
1130         (WebCore::DatabaseBackendBase::setCachedVersion):
1131         (WebCore::DatabaseBackendBase::getActualVersionForTransaction):
1132         (WebCore::DatabaseBackendBase::disableAuthorizer):
1133         (WebCore::DatabaseBackendBase::enableAuthorizer):
1134         (WebCore::DatabaseBackendBase::setAuthorizerReadOnly):
1135         (WebCore::DatabaseBackendBase::setAuthorizerPermissions):
1136         (WebCore::DatabaseBackendBase::lastActionChangedDatabase):
1137         (WebCore::DatabaseBackendBase::lastActionWasInsert):
1138         (WebCore::DatabaseBackendBase::resetDeletes):
1139         (WebCore::DatabaseBackendBase::hadDeletes):
1140         (WebCore::DatabaseBackendBase::resetAuthorizer):
1141         (WebCore::DatabaseBackendBase::maximumSize):
1142         (WebCore::DatabaseBackendBase::incrementalVacuumIfNeeded):
1143         (WebCore::DatabaseBackendBase::interrupt):
1144         (WebCore::DatabaseBackendBase::isInterrupted):
1145         (WebCore::DatabaseBackendBase::reportOpenDatabaseResult):
1146         (WebCore::DatabaseBackendBase::reportChangeVersionResult):
1147         (WebCore::DatabaseBackendBase::reportStartTransactionResult):
1148         (WebCore::DatabaseBackendBase::reportCommitTransactionResult):
1149         (WebCore::DatabaseBackendBase::reportExecuteStatementResult):
1150         (WebCore::DatabaseBackendBase::reportVacuumDatabaseResult):
1151         * Modules/webdatabase/DatabaseBackendBase.h: Copied from Source/WebCore/Modules/webdatabase/DatabaseBackend.h.
1152         (DatabaseBackendBase):
1153         * Modules/webdatabase/DatabaseBackendSync.cpp:
1154         (WebCore::DatabaseBackendSync::DatabaseBackendSync):
1155         * Modules/webdatabase/DatabaseBackendSync.h:
1156         * Modules/webdatabase/DatabaseBase.h:
1157         * Modules/webdatabase/DatabaseManager.cpp:
1158         (WebCore::DatabaseManager::openDatabaseBackend):
1159         (WebCore::DatabaseManager::openDatabase):
1160         (WebCore::DatabaseManager::openDatabaseSync):
1161         (WebCore::DatabaseManager::getMaxSizeForDatabase):
1162         * Modules/webdatabase/DatabaseManager.h:
1163         (DatabaseManager):
1164         * Modules/webdatabase/DatabaseServer.cpp:
1165         (WebCore::DatabaseServer::openDatabase):
1166         (WebCore::DatabaseServer::createDatabase):
1167         (WebCore::DatabaseServer::getMaxSizeForDatabase):
1168         * Modules/webdatabase/DatabaseServer.h:
1169         * Modules/webdatabase/DatabaseSync.cpp:
1170         (WebCore::DatabaseSync::create):
1171         * Modules/webdatabase/DatabaseSync.h:
1172         (DatabaseSync):
1173         * Modules/webdatabase/DatabaseTracker.cpp:
1174         (WebCore::DatabaseTracker::getMaxSizeForDatabase):
1175         (WebCore::DatabaseTracker::databaseChanged):
1176         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
1177         (WebCore::DatabaseTracker::doneCreatingDatabase):
1178         (WebCore::DatabaseTracker::addOpenDatabase):
1179         (WebCore::DatabaseTracker::removeOpenDatabase):
1180         (WebCore::DatabaseTracker::getOpenDatabases):
1181         (WebCore::DatabaseTracker::deleteDatabaseFile):
1182         * Modules/webdatabase/DatabaseTracker.h:
1183         (DatabaseTracker):
1184         * Modules/webdatabase/OriginQuotaManager.cpp:
1185         (WebCore::OriginQuotaManager::markDatabase):
1186         * Modules/webdatabase/OriginQuotaManager.h:
1187         (OriginQuotaManager):
1188         * Modules/webdatabase/SQLTransactionClient.cpp:
1189         (WebCore::SQLTransactionClient::didCommitWriteTransaction):
1190         (WebCore::SQLTransactionClient::didExecuteStatement):
1191         (WebCore::SQLTransactionClient::didExceedQuota):
1192         * Modules/webdatabase/SQLTransactionClient.h:
1193         (SQLTransactionClient):
1194         * Modules/webdatabase/chromium/DatabaseObserver.h:
1195         (DatabaseObserver):
1196         * Modules/webdatabase/chromium/DatabaseTrackerChromium.cpp:
1197         (WebCore::DatabaseTracker::addOpenDatabase):
1198         (WebCore::NotifyDatabaseObserverOnCloseTask::create):
1199         (WebCore::NotifyDatabaseObserverOnCloseTask::NotifyDatabaseObserverOnCloseTask):
1200         (NotifyDatabaseObserverOnCloseTask):
1201         (WebCore::DatabaseTracker::removeOpenDatabase):
1202         (WebCore::DatabaseTracker::prepareToOpenDatabase):
1203         (WebCore::DatabaseTracker::failedToOpenDatabase):
1204         (WebCore::DatabaseTracker::getMaxSizeForDatabase):
1205         (WebCore::DatabaseTracker::CloseOneDatabaseImmediatelyTask::create):
1206         (WebCore::DatabaseTracker::CloseOneDatabaseImmediatelyTask::CloseOneDatabaseImmediatelyTask):
1207         (DatabaseTracker::CloseOneDatabaseImmediatelyTask):
1208         (WebCore::DatabaseTracker::closeOneDatabaseImmediately):
1209         * Modules/webdatabase/chromium/SQLTransactionClientChromium.cpp:
1210         (WebCore::NotifyDatabaseChangedTask::create):
1211         (WebCore::NotifyDatabaseChangedTask::NotifyDatabaseChangedTask):
1212         (NotifyDatabaseChangedTask):
1213         (WebCore::SQLTransactionClient::didCommitWriteTransaction):
1214         (WebCore::SQLTransactionClient::didExecuteStatement):
1215         (WebCore::SQLTransactionClient::didExceedQuota):
1216         * Target.pri:
1217         * WebCore.gypi:
1218         * WebCore.vcproj/WebCore.vcproj:
1219         * WebCore.vcxproj/WebCore.vcxproj:
1220         * WebCore.vcxproj/WebCore.vcxproj.filters:
1221         * WebCore.xcodeproj/project.pbxproj:
1222
1223 2013-02-20  Eric Carlson  <eric.carlson@apple.com>
1224
1225         iOS does not use CaptionUserPreferencesMac
1226         https://bugs.webkit.org/show_bug.cgi?id=110259
1227
1228         Reviewed by Dean Jackson.
1229
1230         * page/CaptionUserPreferencesMac.h: Add PLATFORM(IOS) guard
1231         * page/CaptionUserPreferencesMac.mm: Ditto.
1232
1233         * page/PageGroup.cpp:
1234         (WebCore::PageGroup::captionPreferences): Ditto.
1235
1236 2013-02-19  David Hyatt  <hyatt@apple.com>
1237
1238         [New Multicolumn] Make layers paint properly in columns.
1239         https://bugs.webkit.org/show_bug.cgi?id=110296.
1240
1241         Reviewed by Sam Weinig.
1242
1243         Construct the style for the RenderMultiColumnFlowThread such that it
1244         establishes a stacking context (by being position:relative
1245         with a z-index of 0). This causes the layer collection code
1246         to correctly ignore the RenderFlowThread layers during normal
1247         painting.
1248         
1249         Fix more clipping bugs to eliminate subpixel layout differences
1250         between old and new multicolumn.
1251
1252         Test: fast/multicol/newmulticol/layers-in-multicol.html
1253
1254         * rendering/RenderMultiColumnBlock.cpp:
1255         (WebCore::createMultiColumnFlowThreadStyle):
1256         (WebCore):
1257         (WebCore::RenderMultiColumnBlock::addChild):
1258         Use a custom style (similar to what normal RenderFlowThreads do)
1259         for the RenderMultiColumnFlowThread that makes it a stacking
1260         context.
1261         
1262         * rendering/RenderMultiColumnSet.cpp:
1263         (WebCore::RenderMultiColumnSet::flowThreadPortionOverflowRect):
1264         Fix the overflow calculations out the leftmost and rightmost
1265         columns to actually look at the physical placement of the columns.
1266         The old code was backwards for RTL.
1267         
1268         * rendering/RenderRegion.cpp:
1269         (WebCore::RenderRegion::overflowRectForFlowThreadPortion):
1270         Fix the clipping done by overflowRectForFlowThreadPortion to min
1271         and max with the passed-in portion rect so that subclasses that
1272         inflate the rect prior to passing it into the method don't have that
1273         inflation discarded.
1274
1275 2013-02-20  Alexander Pavlov  <apavlov@chromium.org>
1276
1277         Web Inspector: CSSProperty.status defaults to "style" not "active"
1278         https://bugs.webkit.org/show_bug.cgi?id=110348
1279
1280         Reviewed by Timothy Hatcher.
1281
1282         * inspector/Inspector.json: Fix the default property status to be "style" in the description.
1283
1284 2013-02-20  Dan Carney  <dcarney@google.com>
1285
1286         [v8] potentially disposed handle returned for npapi object
1287         https://bugs.webkit.org/show_bug.cgi?id=110331
1288
1289         Reviewed by Kentaro Hara.
1290
1291         No new tests. No change in functionality.
1292
1293         * bindings/v8/V8NPUtils.cpp:
1294         (WebCore::convertNPVariantToV8Object):
1295
1296 2013-02-20  Xabier Rodriguez Calvar  <calvaris@igalia.com>  and  Martin Robinson  <mrobinson@igalia.com>
1297
1298         [Gtk] HTML5 Media controls require a design refresh
1299         https://bugs.webkit.org/show_bug.cgi?id=83869
1300
1301         Created new controls that depend less on Gtk and more in CSS.
1302
1303         Reviewed by Philippe Normand.
1304
1305         * GNUmakefile.list.am: Added compilation for MediaControlsGtk.cpp
1306         and MediaControlsGtk.h
1307         * css/mediaControlsGtk.css: Taken from Chromium and adapted for
1308         WebKitGtk+.
1309         * html/shadow/MediaControlsGtk.cpp: Added.
1310         (WebCore): Added MediaControlsGtk class.
1311         (WebCore::MediaControlsGtk::MediaControlsGtk): Class constructor
1312         (WebCore::MediaControls::create): Creates the Gtk+ controls
1313         components.
1314         (WebCore::MediaControlsGtk::createControls): Creates the Gtk+
1315         controls components.
1316         (WebCore::MediaControlsGtk::initializeControls): Initializes all
1317         media controls.
1318         (WebCore::MediaControlsGtk::setMediaController): Sets the media
1319         controller.
1320         (WebCore::MediaControlsGtk::reset): Resets the controllers.
1321         (WebCore::MediaControlsGtk::playbackStarted): Invoked when the
1322         playback starts
1323         (WebCore::MediaControlsGtk::updateCurrentTimeDisplay): Updates the
1324         controls when the current time shall be updated.
1325         (WebCore::MediaControlsGtk::changedMute): Updates the controls
1326         then the mute changes.
1327         (WebCore::MediaControlsGtk::showVolumeSlider): Invoked when the
1328         volume slider is meant to be shown.
1329         (WebCore::MediaControlsGtk::createTextTrackDisplay): Creates the
1330         track display. Though it is not used by us, it needs to be created
1331         to prevent immediate crashes when loading a video.
1332         * html/shadow/MediaControlsGtk.h: Added.
1333         (WebCore): Added the MediaControlsGtk class.
1334         (MediaControlsGtk): Added the MediaControlsGtk class.
1335         * platform/gtk/RenderThemeGtk.cpp:
1336         (WebCore): Added getStockSymbolicIconForWidgetType function
1337         signature to load symbolic icons.
1338         (WebCore::supportsFocus): Added media control widgets to support
1339         focus so that the focus ring is not painted by WebCore.
1340         (WebCore::RenderThemeGtk::paintMediaButton): Added the symbolic
1341         icon support. It supports now normal and symbolic icons at the
1342         same time.
1343         (WebCore::RenderThemeGtk::paintMediaFullscreenButton): Added the
1344         symbolic icon support.
1345         (WebCore::RenderThemeGtk::paintMediaMuteButton): Added the
1346         symbolic icon support.
1347         (WebCore::RenderThemeGtk::paintMediaPlayButton): Added the
1348         symbolic icon support.
1349         (WebCore::RenderThemeGtk::paintMediaSeekBackButton): Added the
1350         symbolic icon support.
1351         (WebCore::RenderThemeGtk::paintMediaSeekForwardButton): Added the
1352         symbolic icon support.
1353         (WebCore::borderRadiiFromStyle): Created the radii info from the
1354         style.
1355         (WebCore::RenderThemeGtk::paintMediaSliderTrack): Removed the
1356         background and the Gtk widget support as it is painted with
1357         CSS. Also paint the time ranges with the CSS style.
1358         (WebCore::RenderThemeGtk::paintMediaSliderThumb): Paint slider
1359         thumb according to the CSS parameters.
1360         (WebCore::RenderThemeGtk::paintMediaVolumeSliderContainer):
1361         Delegates in the CSS.
1362         (WebCore::RenderThemeGtk::paintMediaVolumeSliderTrack): Fills the
1363         track up to the volume level and delegates the border in the CSS.
1364         (WebCore::RenderThemeGtk::paintMediaVolumeSliderThumb): Delegates
1365         in the paintMediaSliderThumb method so the thumb is painted the
1366         same with the CSS parameters.
1367         (WebCore::RenderThemeGtk::paintMediaCurrentTime): Removed the Gtk
1368         background to use only CSS.
1369         * platform/gtk/RenderThemeGtk.h:
1370         (RenderThemeGtk): Changed paintMediaButton to support the symbolic
1371         and normal icons at the same time.
1372         * platform/gtk/RenderThemeGtk2.cpp:
1373         (WebCore::RenderThemeGtk::adjustSliderThumbSize): Not adjusting
1374         the thumb size and letting the CSS decide that for media slider.
1375         (WebCore::getStockSymbolicIconForWidgetType): Implemented as a
1376         fallback to the normal stock icons.
1377         * platform/gtk/RenderThemeGtk3.cpp:
1378         (WebCore):
1379         (WebCore::RenderThemeGtk::adjustSliderThumbSize): Not adjusting
1380         the thumb size and letting the CSS decide that for the media
1381         sliders.
1382         (WebCore::getStockSymbolicIconForWidgetType): Added this function
1383         to load symbolic icons. It falls back to normal icons if the
1384         symbolic is not found.
1385
1386 2013-02-20  Andras Becsi  <andras.becsi@digia.com>
1387
1388         [Qt] Rename AncestorChainWalker.h to EventPathWalker.h in the project file.
1389
1390         Unreviewed gardening.
1391
1392         AncestorChainWalker has been renamed to EventPathWalker in r143422.
1393         Rename the header in the project file as well so that it shows up in QtCreator.
1394
1395         No new tests needed.
1396
1397         * Target.pri:
1398
1399 2013-02-20  Ilya Tikhonovsky  <loislo@chromium.org>
1400
1401         Web Inspector: fix for frontend closure compile errors.
1402         https://bugs.webkit.org/show_bug.cgi?id=110329
1403
1404         Reviewed by Vsevolod Vlasov.
1405
1406         It has no tests because it has no code changes.
1407
1408         * inspector/front-end/HeapSnapshot.js:
1409         (HeapSnapshotMetainfo):
1410         * inspector/front-end/NativeMemorySnapshotView.js:
1411         (WebInspector.NativeSnapshotProfileType.prototype.buttonClicked.didReceiveMemorySnapshot):
1412         (WebInspector.NativeSnapshotProfileType.prototype.buttonClicked):
1413
1414 2013-02-20  Florin Malita  <fmalita@chromium.org>
1415
1416         Clear SVGPathSeg role on removal.
1417         https://bugs.webkit.org/show_bug.cgi?id=110058
1418
1419         Reviewed by Dirk Schulze.
1420
1421         SVGPathSegListPropertyTearOff::initialize() and SVGPathSegListPropertyTearOff::replaceItem()
1422         need to clear the context and role for segments being expunged from the list, similarly to
1423         removeItem(). Otherwise, processIncomingListItemValue() can get confused and attempt to
1424         remove stale segments.
1425
1426         Test: svg/dom/SVGPathSegList-crash.html
1427
1428         * svg/properties/SVGPathSegListPropertyTearOff.cpp:
1429         (WebCore::SVGPathSegListPropertyTearOff::clearContextAndRoles):
1430         (WebCore::SVGPathSegListPropertyTearOff::clear):
1431         (WebCore::SVGPathSegListPropertyTearOff::replaceItem):
1432         (WebCore):
1433         * svg/properties/SVGPathSegListPropertyTearOff.h:
1434         (WebCore::SVGPathSegListPropertyTearOff::initialize):
1435         (SVGPathSegListPropertyTearOff):
1436
1437 2013-02-20  Sheriff Bot  <webkit.review.bot@gmail.com>
1438
1439         Unreviewed, rolling out r143434.
1440         http://trac.webkit.org/changeset/143434
1441         https://bugs.webkit.org/show_bug.cgi?id=110326
1442
1443         added reftest fails on chromium mac 10.6 (Requested by
1444         toyoshim on #webkit).
1445
1446         * rendering/RenderFileUploadControl.cpp:
1447         (WebCore::RenderFileUploadControl::paintObject):
1448
1449 2013-02-19  Vsevolod Vlasov  <vsevik@chromium.org>
1450
1451         Web Inspector: Make UISourceCode.path() an array of path segments.
1452         https://bugs.webkit.org/show_bug.cgi?id=110229
1453
1454         Reviewed by Pavel Feldman.
1455
1456         * inspector/front-end/FileSystemProjectDelegate.js:
1457         (WebInspector.FileSystemProjectDelegate.prototype._filePathForPath):
1458         (WebInspector.FileSystemProjectDelegate.prototype.innerCallback):
1459         (WebInspector.FileSystemProjectDelegate.prototype.requestFileContent):
1460         (WebInspector.FileSystemProjectDelegate.prototype._contentTypeForPath):
1461         (WebInspector.FileSystemProjectDelegate.prototype.populate.filesLoaded):
1462         (WebInspector.FileSystemProjectDelegate.prototype.populate):
1463         * inspector/front-end/SimpleWorkspaceProvider.js:
1464         (WebInspector.SimpleProjectDelegate.prototype.requestFileContent):
1465         (WebInspector.SimpleProjectDelegate.prototype.searchInFileContent):
1466         (WebInspector.SimpleProjectDelegate.prototype.addFile):
1467         (WebInspector.SimpleProjectDelegate.prototype._ensureUniquePath):
1468         (WebInspector.SimpleProjectDelegate.prototype.removeFile):
1469         (WebInspector.SimpleWorkspaceProvider.pathForSplittedURL):
1470         (WebInspector.SimpleWorkspaceProvider.prototype.addFileByName):
1471         (WebInspector.SimpleWorkspaceProvider.prototype.removeFileByName):
1472         * inspector/front-end/UISourceCode.js:
1473         (WebInspector.UISourceCode.prototype.uri):
1474         * inspector/front-end/Workspace.js:
1475         (WebInspector.Project.prototype._fileAdded):
1476         (WebInspector.Project.prototype._fileRemoved):
1477         (WebInspector.Project.prototype.uiSourceCode):
1478         (WebInspector.Workspace.prototype.uiSourceCodeForURL):
1479         (WebInspector.Workspace.prototype.urlForPath):
1480
1481 2013-02-20  Yury Semikhatsky  <yurys@chromium.org>
1482
1483         Web Inspector: fix message for non-existent domain warning
1484         https://bugs.webkit.org/show_bug.cgi?id=110315
1485
1486         Reviewed by Alexander Pavlov.
1487
1488         Only send (Heap)Profiler.resetProfiles event if the client has
1489         requested profile headers before.
1490
1491         * inspector/InspectorHeapProfilerAgent.cpp:
1492         (HeapProfilerAgentState):
1493         (WebCore):
1494         (WebCore::InspectorHeapProfilerAgent::InspectorHeapProfilerAgent):
1495         (WebCore::InspectorHeapProfilerAgent::resetFrontendProfiles):
1496         (WebCore::InspectorHeapProfilerAgent::clearFrontend):
1497         (WebCore::InspectorHeapProfilerAgent::restore):
1498         (WebCore::InspectorHeapProfilerAgent::getProfileHeaders):
1499         * inspector/InspectorHeapProfilerAgent.h:
1500         (InspectorHeapProfilerAgent):
1501         * inspector/InspectorProfilerAgent.cpp:
1502         (ProfilerAgentState):
1503         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
1504         (WebCore::InspectorProfilerAgent::addProfile):
1505         (WebCore::InspectorProfilerAgent::disable):
1506         (WebCore::InspectorProfilerAgent::getProfileHeaders):
1507         (WebCore):
1508         (WebCore::InspectorProfilerAgent::resetFrontendProfiles):
1509         (WebCore::InspectorProfilerAgent::restore):
1510         * inspector/InspectorProfilerAgent.h:
1511         (InspectorProfilerAgent):
1512
1513 2013-02-19  Vsevolod Vlasov  <vsevik@chromium.org>
1514
1515         Web Inspector: Move workspace specific code from FileMapping to workspace.
1516         https://bugs.webkit.org/show_bug.cgi?id=110219
1517
1518         Reviewed by Pavel Feldman.
1519
1520         Extracted workspace specific code from FileMapping to Workspace.
1521         This allows to reduce usage of uri and eventually make UISourceCode.path an array of path segments.
1522
1523         Test: inspector/workspace-mapping.html
1524
1525         * inspector/front-end/CSSStyleModel.js:
1526         (WebInspector.CSSStyleModel.prototype.rawLocationToUILocation):
1527         * inspector/front-end/CompilerScriptMapping.js:
1528         (WebInspector.CompilerScriptMapping.prototype.rawLocationToUILocation):
1529         (WebInspector.CompilerScriptMapping.prototype.get addScript.get this):
1530         (WebInspector.CompilerScriptMapping.prototype.get addScript):
1531         * inspector/front-end/FileMapping.js:
1532         (WebInspector.FileMapping):
1533         (WebInspector.FileMapping.prototype.mappingEntryForURL):
1534         (WebInspector.FileMapping.prototype.mappingEntryForPath):
1535         * inspector/front-end/FileSystemMapping.js:
1536         (WebInspector.FileSystemMapping.prototype.fileSystemPathForPrefix):
1537         (WebInspector.FileSystemMappingImpl.prototype.addFileSystemMapping):
1538         (WebInspector.FileSystemMappingImpl.prototype.removeFileSystemMapping):
1539         (WebInspector.FileSystemMappingImpl.prototype.fileSystemPathForPrefix):
1540         * inspector/front-end/FileSystemProjectDelegate.js:
1541         (WebInspector.FileSystemProjectDelegate):
1542         (WebInspector.FileSystemProjectDelegate.prototype.populate.filesLoaded):
1543         (WebInspector.FileSystemProjectDelegate.prototype.populate):
1544         (WebInspector.FileSystemWorkspaceProvider):
1545         (WebInspector.FileSystemWorkspaceProvider.prototype._fileSystemAdded):
1546         * inspector/front-end/IsolatedFileSystemManager.js:
1547         (WebInspector.IsolatedFileSystemManager):
1548         * inspector/front-end/NetworkUISourceCodeProvider.js:
1549         (WebInspector.NetworkUISourceCodeProvider):
1550         (WebInspector.NetworkUISourceCodeProvider.prototype._addFile):
1551         * inspector/front-end/ResourceScriptMapping.js:
1552         (WebInspector.ResourceScriptMapping.prototype._workspaceUISourceCodeForScript):
1553         * inspector/front-end/ResourceUtils.js:
1554         (WebInspector.displayNameForURL):
1555         * inspector/front-end/SASSSourceMapping.js:
1556         (WebInspector.SASSSourceMapping.prototype._reloadCSS):
1557         (WebInspector.SASSSourceMapping.prototype._bindUISourceCode):
1558         (WebInspector.SASSSourceMapping.prototype.rawLocationToUILocation):
1559         * inspector/front-end/ScriptsPanel.js:
1560         (WebInspector.ScriptsPanel.prototype.canShowAnchorLocation):
1561         * inspector/front-end/SimpleWorkspaceProvider.js:
1562         (WebInspector.SimpleWorkspaceProvider.pathForSplittedURL):
1563         (WebInspector.SimpleWorkspaceProvider.prototype._innerAddFileForURL):
1564         * inspector/front-end/StylesSourceMapping.js:
1565         (WebInspector.StylesSourceMapping.prototype.rawLocationToUILocation):
1566         (WebInspector.StylesSourceMapping.prototype._resourceAdded):
1567         (WebInspector.StylesSourceMapping.prototype._mainFrameCreatedOrNavigated):
1568         (WebInspector.StyleContentBinding):
1569         (WebInspector.StyleContentBinding.prototype._innerStyleSheetChanged):
1570         * inspector/front-end/Workspace.js:
1571         (WebInspector.Workspace):
1572         (WebInspector.Workspace.prototype.hasMappingForURL):
1573         (WebInspector.Workspace.prototype._fileSystemPathForEntry):
1574         (WebInspector.Workspace.prototype.uiSourceCodeForURL):
1575         (WebInspector.Workspace.prototype.urlForPath):
1576         * inspector/front-end/inspector.js:
1577
1578 2013-02-20  Alexander Pavlov  <apavlov@chromium.org>
1579
1580         Web Inspector: Introduce SecurityOriginAdded and SecurityOriginRemoved events into ResourceTreeModel
1581         https://bugs.webkit.org/show_bug.cgi?id=110232
1582
1583         Reviewed by Vsevolod Vlasov.
1584
1585         * inspector/front-end/ResourceTreeModel.js:
1586         (WebInspector.ResourceTreeModel):
1587         (WebInspector.ResourceTreeModel.prototype._addFrame):
1588         (WebInspector.ResourceTreeModel.prototype._addSecurityOrigin): Added.
1589         (WebInspector.ResourceTreeModel.prototype._removeSecurityOrigin): Added.
1590         (WebInspector.ResourceTreeModel.prototype._handleMainFrameDetached): Added.
1591         (WebInspector.ResourceTreeModel.prototype._frameNavigated):
1592         (WebInspector.ResourceTreeModel.prototype._frameDetached):
1593
1594 2013-02-20  Dan Carney  <dcarney@google.com>
1595
1596         [v8] ScriptValue has dangerous copy semantics
1597         https://bugs.webkit.org/show_bug.cgi?id=110206
1598
1599         Reviewed by Kentaro Hara.
1600
1601         Update ScriptValue to used a SharedPersistent,
1602         making it impossible to return dead references.
1603
1604         No new tests. No change in functionality.
1605
1606         * bindings/v8/ScriptValue.cpp:
1607         (WebCore::ScriptValue::serialize):
1608         (WebCore::ScriptValue::getString):
1609         (WebCore::ScriptValue::toString):
1610         (WebCore::ScriptValue::toInspectorValue):
1611         * bindings/v8/ScriptValue.h:
1612         (WebCore::ScriptValue::ScriptValue):
1613         (WebCore::ScriptValue::operator=):
1614         (WebCore::ScriptValue::operator==):
1615         (WebCore::ScriptValue::isEqual):
1616         (WebCore::ScriptValue::isFunction):
1617         (WebCore::ScriptValue::isNull):
1618         (WebCore::ScriptValue::isUndefined):
1619         (WebCore::ScriptValue::isObject):
1620         (WebCore::ScriptValue::hasNoValue):
1621         (WebCore::ScriptValue::clear):
1622         (ScriptValue):
1623         (WebCore::ScriptValue::v8Value):
1624         (WebCore::ScriptValue::v8ValueRaw):
1625         * bindings/v8/SharedPersistent.h:
1626         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1627         (WebCore::InjectedScriptHost::scriptValueAsNode):
1628         * bindings/v8/custom/V8MessageEventCustom.cpp:
1629         (WebCore::V8MessageEvent::dataAttrGetterCustom):
1630
1631 2013-02-20  Andrey Lushnikov  <lushnikov@chromium.org>
1632
1633         Web Inspector: highlight undefined word in JavaScript
1634         https://bugs.webkit.org/show_bug.cgi?id=109585
1635
1636         Reviewed by Vsevolod Vlasov.
1637
1638         Test enhancement: inspector/syntax-highlight-javascript.html
1639
1640         Add global object value properties to tokenizer and add a css style
1641         class to highlight "undefined" with gray color.
1642
1643         * inspector/front-end/SourceJavaScriptTokenizer.js:
1644         (WebInspector.SourceJavaScriptTokenizer.prototype.nextToken):
1645         * inspector/front-end/SourceJavaScriptTokenizer.re2js:
1646         * inspector/front-end/inspectorSyntaxHighlight.css:
1647         (.webkit-javascript-undef):
1648
1649 2013-02-20  Mike West  <mkwst@chromium.org>
1650
1651         Use EventPathWalker rather than parentNode() to normalize event targets in EventHandler.
1652         https://bugs.webkit.org/show_bug.cgi?id=110037
1653
1654         Reviewed by Ryosuke Niwa.
1655
1656         We need to teach EventHandler about Shadow DOM in a few places in order
1657         to ensure that we properly target events dispatched upon text nodes.
1658         Rather than naively grabbing the text node's direct parent via
1659         parentNode(), we need to account for the case in which the text node is
1660         distributed[1] to an insertion point inside a shadow host.
1661         EventPathWalker::parent understands these relationships, and should
1662         be used when dealing with mouse, drag, and touch events.
1663
1664         [1]: http://www.w3.org/TR/shadow-dom/#dfn-distribution
1665
1666         * page/EventHandler.cpp:
1667         (WebCore::EventHandler::handleMouseDraggedEvent):
1668         (WebCore::EventHandler::handleTouchEvent):
1669         (WebCore::EventHandler::passGestureEventToWidgetIfPossible):
1670         (WebCore::EventHandler::updateDragAndDrop):
1671             Refactor parentNode callsites to use EventPathWalker::parent().
1672
1673 2013-02-20  Vsevolod Vlasov  <vsevik@chromium.org>
1674
1675         Web Inspector: [Regression] Search in ProfilesPanel is broken
1676         https://bugs.webkit.org/show_bug.cgi?id=110312
1677
1678         Reviewed by Pavel Feldman.
1679
1680         * inspector/front-end/CPUProfileView.js:
1681         (WebInspector.CPUProfileView.prototype.matchesQuery):
1682         (WebInspector.CPUProfileView.prototype.performSearch):
1683
1684 2013-02-20  Eugene Klyuchnikov  <eustas@chromium.org>
1685
1686         Web Inspector: View.markAsRoot should never be invoked on attached view.
1687         https://bugs.webkit.org/show_bug.cgi?id=110224
1688
1689         Reviewed by Pavel Feldman.
1690
1691         This will cause CSS loading problems after "show".
1692
1693         * inspector/front-end/Drawer.js:
1694         Ensure child view is detached before marked as root.
1695         * inspector/front-end/View.js:
1696         (WebInspector.View.prototype.markAsRoot): Added assertion.
1697
1698 2013-02-20  Nils Barth  <nbarth@google.com>
1699
1700         File upload control doesn't apply CSS vertical padding or border to file name
1701         https://bugs.webkit.org/show_bug.cgi?id=109011
1702
1703         Reviewed by Hajime Morrita.
1704
1705         Test: fast/forms/file/file-vertical-padding-border.html
1706
1707         * rendering/RenderFileUploadControl.cpp:
1708             Add borderTop() and paddingTop() when computing position.
1709         (WebCore::RenderFileUploadControl::paintObject):
1710
1711 2013-02-19  Andrey Adaikin  <aandrey@chromium.org>
1712
1713         Few methods in WebGLRenderingContext.idl have incorrect signatures
1714         https://bugs.webkit.org/show_bug.cgi?id=110305
1715
1716         Reviewed by Kentaro Hara.
1717
1718         * html/canvas/WebGLRenderingContext.idl:
1719
1720 2013-02-19  Tim Horton  <timothy_horton@apple.com>
1721
1722         Clarify isInWindow vs. isVisible path through to RenderLayerCompositor
1723         https://bugs.webkit.org/show_bug.cgi?id=110261
1724         <rdar://problem/13196122>
1725
1726         Reviewed by Simon Fraser.
1727
1728         Remove RenderLayerCompositor::willMoveOffscreen/didMoveOnscreen.
1729         Add RenderLayerCompositor::setIsInWindow, and pipe in-window changes through from Page::setIsInWindow.
1730         Adjust a few Document functions that previously called RenderView::didMoveOnscreen/willMoveOffscreen to use setIsInWindow instead, since in-window state changes are occurring when attaching and detaching documents.
1731
1732         * WebCore.exp.in: Export Page::setIsInWindow.
1733         * dom/Document.cpp:
1734         (WebCore::Document::attach): Use setIsInWindow instead of didMoveOnscreen.
1735         (WebCore::Document::documentWillBecomeInactive): Use setIsInWindow instead of willMoveOffscreen.
1736         (WebCore::Document::documentDidResumeFromPageCache): Use setIsInWindow instead of didMoveOnscreen.
1737         * page/FrameView.cpp:
1738         (WebCore::FrameView::didMoveOnscreen):
1739         (WebCore::FrameView::willMoveOffscreen):
1740         RenderView doesn't care about moving on/offscreen, just in-window state.
1741         (WebCore::FrameView::setIsInWindow): Added. Forward isInWindow changes to our RenderView.
1742         * page/FrameView.h:
1743         (FrameView): Add setIsInWindow.
1744         * page/Page.cpp:
1745         (WebCore::Page::setIsInWindow): Added. Forward isInWindow changes to the Page's FrameViews.
1746         * page/Page.h:
1747         (Page): Add setIsInWindow.
1748         (WebCore::Page::isInWindow):
1749         * rendering/RenderLayerCompositor.cpp:
1750         (WebCore::RenderLayerCompositor::setIsInWindow): Added. Replace willMoveOffscreen/didMoveOnscreen with setIsInWindow,
1751         since that's the only change we actually care about.
1752         * rendering/RenderLayerCompositor.h:
1753         (RenderLayerCompositor): Add setIsInWindow.
1754         * rendering/RenderView.cpp:
1755         (WebCore::RenderView::setIsInWindow): Added. Replace willMoveOffscreen/didMoveOnscreen with setIsInWindow,
1756         since that's the only change RenderLayerCompositor actually cares about.
1757         * rendering/RenderView.h:
1758         (RenderView): Add setIsInWindow.
1759
1760 2013-02-19  Eugene Klyuchnikov  <eustas@chromium.org>
1761
1762         Web Inspector: Cleanup and add JSDocs to SuggestBox
1763         https://bugs.webkit.org/show_bug.cgi?id=110202
1764
1765         Reviewed by Pavel Feldman.
1766
1767         SuggestBox contains some obsolete/unused code and not fully
1768         covered with JSDocs.
1769
1770         * inspector/front-end/SuggestBox.js:
1771         (WebInspector.SuggestBox.prototype.visible):
1772         Replaced getter with function.
1773         (WebInspector.SuggestBox.prototype._onScrollOrResize):
1774         Use camel-case for function names.
1775         (WebInspector.SuggestBox.prototype._onBoxMouseDown): Ditto.
1776         (WebInspector.SuggestBox.prototype.updateSuggestions):
1777         Removed unused code.
1778         (WebInspector.SuggestBox.prototype.hide): Adopt changes.
1779         (WebInspector.SuggestBox.prototype._applySuggestion): Ditto.
1780         * inspector/front-end/TextPrompt.js:
1781         (WebInspector.TextPrompt.prototype.isSuggestBoxVisible): Ditto.
1782
1783 2013-02-19  Hayato Ito <hayato@chromium.org>
1784
1785         Calculate EventPath in EventDispatcher's constructor.
1786         https://bugs.webkit.org/show_bug.cgi?id=109905
1787
1788         Reviewed by Dimitri Glazkov.
1789
1790         This patch calculates an EventPath in EventDispatcher's
1791         constructor and removes EventDispatcher::ensureEventPath().
1792         We don't have any reason to initialize an EventPath lazily.
1793
1794         No tests. No change in behavior.
1795
1796         * dom/EventDispatcher.cpp:
1797         (WebCore::EventDispatcher::EventDispatcher):
1798         (WebCore::EventDispatcher::dispatch):
1799         * dom/EventDispatcher.h:
1800         (WebCore::EventDispatcher::eventPath):
1801         (EventDispatcher):
1802         * dom/FocusEvent.cpp:
1803         (WebCore::FocusEventDispatchMediator::dispatchEvent):
1804         (WebCore::BlurEventDispatchMediator::dispatchEvent):
1805         (WebCore::FocusInEventDispatchMediator::dispatchEvent):
1806         (WebCore::FocusOutEventDispatchMediator::dispatchEvent):
1807         * dom/MouseEvent.cpp:
1808         (WebCore::MouseEventDispatchMediator::dispatchEvent):
1809
1810 2013-02-19  Simon Fraser  <simon.fraser@apple.com>
1811
1812         Fix TileCache tile size when zoomed on slow-scrolling site
1813         https://bugs.webkit.org/show_bug.cgi?id=110289
1814
1815         Reviewed by Tim Horton.
1816         
1817         In slow scrolling mode, we use the tile coverage rect as the tile size
1818         (so a single tile covers the viewport). When zoomed, the tile coverage rect
1819         shrinks relative to the TileCache, so scale the tile size back up.
1820
1821         Test: platform/mac-wk2/tiled-drawing/tile-size-slow-zoomed.html
1822
1823         * platform/graphics/ca/mac/TileCache.mm:
1824         (WebCore::TileCache::tileSizeForCoverageRect):
1825
1826 2013-02-19  Hayato Ito  <hayato@chromium.org>
1827
1828         Rename AncestorChainWalker.
1829         https://bugs.webkit.org/show_bug.cgi?id=110146
1830
1831         Reviewed by Dimitri Glazkov.
1832
1833         Rename AncestorChainWalker to EventPathWalker.
1834         The term of EventPath is used in DOM Core spec.  EventPath was
1835         already introduced into a EventContext.h in r112055. We should
1836         spread this term into the Walker class since they share the same
1837         purpose.
1838
1839         No new tests, no behavior change.
1840
1841         * CMakeLists.txt:
1842         * GNUmakefile.list.am:
1843         * Target.pri:
1844         * WebCore.gypi:
1845         * WebCore.xcodeproj/project.pbxproj:
1846         * dom/DOMAllInOne.cpp:
1847         * dom/EventDispatcher.cpp:
1848         * dom/EventPathWalker.cpp: Renamed from Source/WebCore/dom/AncestorChainWalker.cpp.
1849         (WebCore):
1850         (WebCore::EventPathWalker::EventPathWalker):
1851         (WebCore::EventPathWalker::parent): parent() is now a static function to cover simple use cases.
1852         (WebCore::EventPathWalker::moveToParent): Renamed from parent().
1853         * dom/EventPathWalker.h: Renamed from Source/WebCore/dom/AncestorChainWalker.h.
1854         (WebCore):
1855         (EventPathWalker):
1856         (WebCore::EventPathWalker::node):
1857         (WebCore::EventPathWalker::isVisitingInsertionPointInReprojection): Renamed from isCrossingInsertionPoint().
1858         * dom/EventRetargeter.cpp:
1859         (WebCore::EventRetargeter::calculateEventPath):
1860         (WebCore::EventRetargeter::buildRelatedNodeMap):
1861         * dom/TreeScope.cpp:
1862         (WebCore::TreeScope::focusedNode):
1863         * html/HTMLLIElement.cpp:
1864         (WebCore::HTMLLIElement::attach):
1865         * page/EventHandler.cpp:
1866         (WebCore::EventHandler::updateMouseEventTargetNode):
1867         (WebCore::EventHandler::handleWheelEvent):
1868
1869 2013-02-19  Dean Jackson  <dino@apple.com>
1870
1871         Snapshotted plugin label should not be selectable
1872         https://bugs.webkit.org/show_bug.cgi?id=110286
1873
1874         Reviewed by Simon Fraser.
1875
1876         Update the CSS to make it clear that you should click
1877         on a snapshot (use the finger pointer) and disable
1878         text selection.
1879
1880         * css/plugIns.css:
1881         (embed::-webkit-snapshotted-plugin-content .snapshot-container .snapshot-label):
1882
1883 2013-02-19  Hans Muller  <hmuller@adobe.com>
1884
1885         [CSS Exclusions] Enable shape-inside support for ellipses
1886         https://bugs.webkit.org/show_bug.cgi?id=109868
1887
1888         Reviewed by Dirk Schulze.
1889
1890         This change is very similar to the one recently made for circles:
1891         removed the test that disabled ellipse values for shape-inside.
1892         The remaining support for ellipses, which is based on rounded rectangles
1893         whose width/height is equal to their radiusX/radiusY, has not changed.
1894
1895         Test: fast/exclusions/shape-inside/shape-inside-ellipse.html
1896
1897         * rendering/ExclusionShapeInsideInfo.h:
1898         (WebCore::ExclusionShapeInsideInfo::isEnabledFor): No longer disallows any BasicShape type.
1899
1900 2013-02-19  Uday Kiran  <udaykiran@motorola.com>
1901
1902         'round' not implemented in border-image
1903         https://bugs.webkit.org/show_bug.cgi?id=14185
1904
1905         Reviewed by David Hyatt.
1906
1907         Add rendering support for 'round' keyword of border-image-repeat CSS property
1908         http://dev.w3.org/csswg/css3-background/#border-image-repeat
1909         Rebased original patch by Benjamin Otte <otte@gnome.org> and made few fixes.
1910
1911         Test: fast/borders/border-image-02.html
1912
1913         * platform/graphics/GraphicsContext.cpp:
1914         (WebCore::GraphicsContext::drawTiledImage):
1915         * platform/graphics/GraphicsContext.h:
1916         (GraphicsContext):
1917         * platform/graphics/Image.cpp:
1918         (WebCore::Image::drawTiled):
1919         * platform/graphics/Image.h:
1920         (Image):
1921         * rendering/RenderBoxModelObject.cpp:
1922         (WebCore::RenderBoxModelObject::paintNinePieceImage): For 'round' keyword,
1923         the image is tiled (repeated) to fill the area. If it does not fill the area
1924         with a whole number of tiles, the image is rescaled so that it does.
1925
1926 2013-02-19  Conrad Shultz  <conrad_shultz@apple.com>
1927
1928         Allow UI clients to handle vertical wheel events.
1929         https://bugs.webkit.org/show_bug.cgi?id=110006
1930
1931         Reviewed by Tim Horton.
1932
1933         Add API to allow matching changes in WebKit2 to control rubber-banding behavior at vertical page extrema.
1934         If rubber-banding is disabled during a scroll event that would otherwise trigger rubber-banding, dispatch
1935         didNotHandleWheelEvent() to the page UI client.
1936
1937         * WebCore.exp.in:
1938         Export new rubber-banding API.
1939
1940         * page/Page.cpp:
1941         (WebCore):
1942         (WebCore::Page::rubberBandsAtBottom):
1943         Proxy for the corresponding function in ScrollingCoordinator.
1944         (WebCore::Page::setRubberBandsAtBottom):
1945         Ditto.
1946         (WebCore::Page::rubberBandsAtTop):
1947         Ditto.
1948         (WebCore::Page::setRubberBandsAtTop):
1949         Ditto.
1950
1951         * page/Page.h:
1952         (Page):
1953         Declare new rubber-banding API (above).
1954
1955         * page/scrolling/ScrollingCoordinator.h:
1956         (WebCore::ScrollingCoordinator::rubberBandsAtBottom):
1957         Stub API implementation.
1958         (WebCore::ScrollingCoordinator::setRubberBandsAtBottom):
1959         Ditto.
1960         (WebCore::ScrollingCoordinator::rubberBandsAtTop):
1961         Ditto.
1962         (WebCore::ScrollingCoordinator::setRubberBandsAtTop):
1963         Ditto.
1964
1965         * page/scrolling/ScrollingTree.cpp:
1966         (WebCore::ScrollingTree::ScrollingTree):
1967         Initialize new member variables.
1968         (WebCore::ScrollingTree::setMainFramePinState):
1969         Set top/bottom pinned states.
1970         (WebCore::ScrollingTree::rubberBandsAtBottom):
1971         New accessor function.
1972         (WebCore::ScrollingTree::setRubberBandsAtBottom):
1973         New mutator function.
1974         (WebCore::ScrollingTree::rubberBandsAtTop):
1975         New accessor function.
1976         (WebCore::ScrollingTree::setRubberBandsAtTop):
1977         New mutator function.
1978         (WebCore::ScrollingTree::willWheelEventStartSwipeGesture):
1979         Start a vertical swipe event if the frame is pinned at the top or bottom and associated rubber-banding is disabled.
1980
1981         * page/scrolling/ScrollingTree.h:
1982         (ScrollingTree):
1983         Declare new rubber-banding API and associated member variables.
1984
1985         * page/scrolling/mac/ScrollingCoordinatorMac.h:
1986         (ScrollingCoordinatorMac):
1987         Declare API overrides.
1988
1989         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
1990         (WebCore::ScrollingCoordinatorMac::rubberBandsAtBottom):
1991         Method override; proxy to corresponding function in ScrollingTree.
1992         (WebCore::ScrollingCoordinatorMac::setRubberBandsAtBottom):
1993         Ditto.
1994         (WebCore::ScrollingCoordinatorMac::rubberBandsAtTop):
1995         Ditto.
1996         (WebCore::ScrollingCoordinatorMac::setRubberBandsAtTop):
1997         Ditto.
1998
1999         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
2000         (WebCore::ScrollingTreeScrollingNodeMac::pinnedInDirection):
2001         Remove trailing whitespace.
2002         (WebCore::ScrollingTreeScrollingNodeMac::updateMainFramePinState):
2003         Calculate and pass vertical pinning state to ScrollingTree::setMainFramePinState().
2004
2005 2013-02-19  Simon Fraser  <simon.fraser@apple.com>
2006
2007         Rubber-banding should not affect the visibleRect of the TileCache
2008         https://bugs.webkit.org/show_bug.cgi?id=110278
2009
2010         Reviewed by Beth Dakin.
2011         
2012         When rubber-banding a slow-scrolling page, or image document, we would constantly re-create
2013         the bottom tile because of the logic that adapts the tile size to the visible rect when slow
2014         scrolling.
2015         
2016         Avoid that by ensuring that the visibleRect is not affected by rubber-banding. This is done
2017         via a GraphicsLayerClient function that allows RenderLayerCompositor to provide a custom
2018         position for the scroll layer. We constrain that scroll position to remove the overhang that
2019         results from rubber-banding.
2020
2021         I wasn't able to make a test for this, even with internals.setScrollViewPosition().
2022
2023         * platform/graphics/GraphicsLayerClient.h:
2024         (GraphicsLayerClient):
2025         (WebCore::GraphicsLayerClient::customPositionForVisibleRectComputation):
2026         * platform/graphics/ca/GraphicsLayerCA.cpp:
2027         (WebCore::GraphicsLayerCA::computeVisibleRect):
2028         * rendering/RenderLayerCompositor.cpp:
2029         (WebCore::RenderLayerCompositor::customPositionForVisibleRectComputation):
2030         * rendering/RenderLayerCompositor.h:
2031
2032 2013-02-19  Tony Gentilcore  <tonyg@chromium.org>
2033
2034         Fix crash in preloading scanning base tags with no href attribute for background parser
2035         https://bugs.webkit.org/show_bug.cgi?id=110276
2036
2037         Reviewed by Eric Seidel.
2038
2039         Previously a <base> tag without an href attribute (like the one in fast/dom/HTMLAnchorElement/set-href-attribute-rebase.html)
2040         would crash the background parser's preload scanner.
2041
2042         To fix that, we only call stripLeadingAndTrailingHTMLSpaces() if the href attribute is non-null. This matches the main thread parser.
2043
2044         Along with this, I decided to templatize updatePredictedBaseURL() so that the main and background parser can share the same impl.
2045
2046         This required making CompactHTMLToken and HTMLToken a little more similar:
2047         1. Give HTMLToken a getAttributeItem() method.
2048         2. Move CompactAttribute to CompactHTMLToken::Attribute and make it a struct.
2049
2050         No new tests because covered by existing tests.
2051
2052         * html/parser/AtomicHTMLToken.h:
2053         (WebCore::AtomicHTMLToken::AtomicHTMLToken):
2054         * html/parser/CompactHTMLToken.cpp:
2055         (SameSizeAsCompactHTMLToken):
2056         (WebCore::CompactHTMLToken::CompactHTMLToken):
2057         (WebCore::CompactHTMLToken::getAttributeItem):
2058         (WebCore::CompactHTMLToken::isSafeToSendToAnotherThread):
2059         * html/parser/CompactHTMLToken.h:
2060         (WebCore::CompactHTMLToken::Attribute::Attribute):
2061         (Attribute):
2062         (WebCore::CompactHTMLToken::attributes):
2063         (CompactHTMLToken):
2064         (WebCore::CompactHTMLToken::publicIdentifier):
2065         (WebCore::CompactHTMLToken::systemIdentifier):
2066         * html/parser/HTMLParserIdioms.h:
2067         (WebCore):
2068         (WebCore::stripLeadingAndTrailingHTMLSpaces):
2069         * html/parser/HTMLPreloadScanner.cpp:
2070         (WebCore::TokenPreloadScanner::StartTagScanner::processAttributes):
2071         (WebCore):
2072         (WebCore::TokenPreloadScanner::updatePredictedBaseURL):
2073         * html/parser/HTMLPreloadScanner.h:
2074         * html/parser/HTMLToken.h:
2075         (WebCore::HTMLToken::getAttributeItem):
2076         (HTMLToken):
2077
2078 2013-02-19  Mark Lam  <mark.lam@apple.com>
2079
2080         Introducing AbstractSQLTransaction and AbstractSQLTransactionBackend.
2081         https://bugs.webkit.org/show_bug.cgi?id=110273.
2082
2083         Reviewed by Anders Carlsson.
2084
2085         This is part of the webdatabase refactoring for webkit2.
2086         - Also changed the frontend and backend to only refer to the
2087           abstract interface of each other.
2088
2089         No new tests.
2090
2091         * Modules/webdatabase/AbstractSQLTransaction.h: Added.
2092         (AbstractSQLTransaction):
2093         (WebCore::AbstractSQLTransaction::~AbstractSQLTransaction):
2094         * Modules/webdatabase/AbstractSQLTransactionBackend.h: Added.
2095         (AbstractSQLTransactionBackend):
2096         (WebCore::AbstractSQLTransactionBackend::~AbstractSQLTransactionBackend):
2097         * Modules/webdatabase/SQLTransaction.cpp:
2098         (WebCore::SQLTransaction::hasCallback):
2099         (WebCore::SQLTransaction::hasSuccessCallback):
2100         (WebCore::SQLTransaction::hasErrorCallback):
2101         (WebCore::SQLTransaction::setBackend):
2102         * Modules/webdatabase/SQLTransaction.h:
2103         (SQLTransaction):
2104         * Modules/webdatabase/SQLTransactionBackend.cpp:
2105         (WebCore::SQLTransactionBackend::create):
2106         (WebCore::SQLTransactionBackend::SQLTransactionBackend):
2107         * Modules/webdatabase/SQLTransactionBackend.h:
2108         (SQLTransactionBackend):
2109         * Modules/webdatabase/SQLTransactionStateMachine.h:
2110
2111 2013-02-19  Emil A Eklund  <eae@chromium.org>
2112
2113         Change computeStickyPositionConstraints to use LayoutBoxExtent for margins
2114         https://bugs.webkit.org/show_bug.cgi?id=108872
2115
2116         Reviewed by Levi Weintraub.
2117         
2118         Change RenderBoxModelObject::computeStickyPositionConstraints to
2119         use a LayoutBoxExtent to represent margins.
2120
2121         No new tests, no change in functionality.
2122
2123         * platform/graphics/LayoutRect.h:
2124         (WebCore::LayoutRect::contract):
2125         Add version contract methods that takes a LayoutBoxExtent object.
2126         
2127         * platform/graphics/LayoutSize.h:
2128         (WebCore::LayoutSize::shrink):
2129         Add shrink method.
2130         
2131         * rendering/RenderBoxModelObject.cpp:
2132         (WebCore::RenderBoxModelObject::computeStickyPositionConstraints):
2133         Change to use a LayoutBoxExtent object to represent margins.
2134
2135 2013-02-19  Tony Gentilcore  <tonyg@chromium.org>
2136
2137         Disable ASSERT(!hasInsertionPoint()) for background parser
2138         https://bugs.webkit.org/show_bug.cgi?id=110251
2139
2140         Reviewed by Adam Barth.
2141
2142         The background parser crashes about 10 layout tests by hitting ASSERT(!hasInsertionPoint()).
2143         Now, finish() is the thing that closes the HTMLInputStream which removes the insertion point.
2144         In these tests, a document.open() calls insert() which clears the HTMLInputStream which causes
2145         there to be an insertion point again.
2146
2147         With the main thread parser, insert() is called before finish() so the ASSERT passes.
2148         However, with the threaded parser, finish() is called before insert(), so we fail the ASSERT.
2149
2150         This patch disables the ASSERT for the background parser because m_input isn't really relevant.
2151         This causes us to pass the tests. However, there is a risk that now hasInsertionPoint() may be incorrect
2152         and Document has a non-debug branch that tests hasInsertionPoint().
2153
2154         No new tests because covered by existing tests.
2155
2156         * html/parser/HTMLDocumentParser.cpp:
2157         (WebCore::HTMLDocumentParser::prepareToStopParsing):
2158         (WebCore::HTMLDocumentParser::attemptToRunDeferredScriptsAndEnd):
2159
2160 2013-02-19  Hans Muller  <hmuller@adobe.com>
2161
2162         [CSS Exclusions] Enable shape-inside support for ellipses
2163         https://bugs.webkit.org/show_bug.cgi?id=109868
2164
2165         Reviewed by Dirk Schulze.
2166
2167         This change is very similar to the one recently made for circles:
2168         removed the test that disabled ellipse values for shape-inside.
2169         The remaining support for ellipses, which is based on rounded rectangles
2170         whose width/height is equal to their radiusX/radiusY, has not changed.
2171
2172         Test: fast/exclusions/shape-inside/shape-inside-ellipse.html
2173
2174         * rendering/ExclusionShapeInsideInfo.h:
2175         (WebCore::ExclusionShapeInsideInfo::isEnabledFor): No longer disallows any BasicShape type.
2176
2177 2013-02-19  Simon Fraser  <simon.fraser@apple.com>
2178
2179         Separate constraining for overhang from fixed-position zooming behavior in scrollOffsetForFixedPosition()
2180         https://bugs.webkit.org/show_bug.cgi?id=110267
2181
2182         Reviewed by Beth Dakin.
2183
2184         The static scrollOffsetForFixedPosition() function in ScrollingCoordinator did two things;
2185         it constrained the scroll position when rubber-banding, and applied the special scaling for
2186         fixed position when zoomed.
2187         
2188         Separate these out so that we can use the rubber-banding constrained elsewhere.
2189
2190         * page/FrameView.cpp:
2191         (WebCore::FrameView::scrollOffsetForFixedPosition): The static function is here now.
2192         * page/FrameView.h:
2193         * page/scrolling/ScrollingCoordinator.cpp: Code moved to FrameView.
2194         * page/scrolling/ScrollingCoordinator.h:
2195         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
2196         (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition): scrollOffsetForFixedPosition()
2197         is now on FrameView.
2198         * platform/ScrollableArea.cpp:
2199         (WebCore::constrainedScrollPosition): Helper to constrain one axis for overhang.
2200         (WebCore::ScrollableArea::constrainScrollPositionForOverhang): Static function that
2201         can be called by FrameView::scrollOffsetForFixedPosition().
2202         * platform/ScrollableArea.h: Static function constrainScrollPositionForOverhang()
2203         so we can call it from another thread. Also a member fuction of the same name, which takes
2204         the scrollPosition as input (so we can feed it a layer position in a later patch).
2205
2206 2013-02-19  Tony Gentilcore  <tonyg@chromium.org>
2207
2208         Fix checkThatTokensAreSafeToSendToAnotherThread() now that the preload scanner is enabled
2209         https://bugs.webkit.org/show_bug.cgi?id=110258
2210
2211         Reviewed by Adam Barth.
2212
2213         We were hitting this ASSERT on numerous tests with the background parser enabled. This copy fixes the assertion.
2214
2215         No new tests becuase covered by existing tests.
2216
2217         * html/parser/HTMLResourcePreloader.h:
2218         (WebCore::PreloadRequest::setCharset):
2219
2220 2013-02-19  Tony Gentilcore  <tonyg@chromium.org>
2221
2222         Fix typo: inititatorFor->initiatorFor
2223         https://bugs.webkit.org/show_bug.cgi?id=110260
2224
2225         Reviewed by Adam Barth.
2226
2227         No new tests because no changed functionality.
2228
2229         * html/parser/HTMLPreloadScanner.cpp:
2230         (WebCore::TokenPreloadScanner::initiatorFor):
2231         (WebCore::TokenPreloadScanner::StartTagScanner::createPreloadRequest):
2232         * html/parser/HTMLPreloadScanner.h:
2233
2234 2013-02-19  Tony Chang  <tony@chromium.org>
2235
2236         Convert 3 settings to use Settings.in
2237         https://bugs.webkit.org/show_bug.cgi?id=109875
2238
2239         Reviewed by Ryosuke Niwa.
2240
2241         Convert mediaEnabled, applicationChromeMode and DOMPasteAllowed to
2242         use Settings.in. They previously had inconsistently named setters.
2243
2244         No new tests, this is a refactoring.
2245
2246         * Source/WebCore/WebCore.exp.in: Remove symbols that are now inlined from exports.
2247         * Source/WebCore/WebCore.order: Remove symbols that no longer exist.
2248         * dom/make_names.pl:
2249         (printConstructorInterior): Rename isMediaEnabled to mediaEnabled.
2250         (printWrapperFunctions): Rename isMediaEnabled to mediaEnabled.
2251         * editing/EditorCommand.cpp:
2252         (WebCore::supportedPaste): Rename isDOMPasteAllowed to DOMPasteAllowed.
2253         * page/Settings.cpp:
2254         (WebCore::Settings::Settings): Remove custom code.
2255         * page/Settings.h:
2256         (Settings): Remove custom code.
2257         * page/Settings.in: Add entries for mediaEnabled, applicationChromeMode and DOMPasteAllowed.
2258         * page/make_settings.pl:
2259         (setterFunctionName): Expand uppercase rules to include DOM.
2260         * rendering/RenderTheme.cpp:
2261         (WebCore::RenderTheme::isDefault): Rename inApplicationChromeMode to applicationChromeMode.
2262         * rendering/RenderThemeWin.cpp:
2263         (WebCore::documentIsInApplicationChromeMode): Rename inApplicationChromeMode to applicationChromeMode.
2264
2265 2013-02-19  Julien Chaffraix  <jchaffraix@webkit.org>
2266
2267         [CSS Grid Layout] Refactor the code in preparation of auto placement support
2268         https://bugs.webkit.org/show_bug.cgi?id=110244
2269
2270         Reviewed by Ojan Vafai.
2271
2272         Test: fast/css-grid-layout/grid-auto-flow-resolution.html
2273
2274         In order to support auto placement, we need to iterate over the grid items with
2275         auto row / column several times. This changes makes us do that in a very simple,
2276         not-yet-conformant way. While touching this code, the distinction between grid-auto-flow
2277         none and row / column was better drawn (and enforced).
2278
2279         * rendering/RenderGrid.cpp:
2280         (WebCore::RenderGrid::resolveGridPositionFromStyle):
2281         Made it illegal to call resolveGridPositionFromStyle if the grid track is auto and
2282         grid-auto-flow is not none. This would catch bad use of the function.
2283
2284         (WebCore::RenderGrid::maximumIndexInDirection):
2285         Updated to bail out if the grid track is auto. Also improved the comment.
2286
2287         (WebCore::RenderGrid::placeItemsOnGrid):
2288         Updated the function to do several iterations. Also handled the grid-auto-flow: none
2289         case differently as it shouldn't need the extra iteration(s).
2290
2291 2013-02-19  David Hyatt  <hyatt@apple.com>
2292
2293         [New Multicolumn] REGRESSION: RenderMultiColumnSets broken by the RenderRegion -> RenderBlock subclassing.
2294         https://bugs.webkit.org/show_bug.cgi?id=110239.
2295
2296         Reviewed by Simon Fraser.
2297
2298         Test: fast/multicol/newmulticol/column-rules-fixed-height.html
2299
2300         * rendering/RenderBlock.cpp:
2301         (WebCore::RenderBlock::columnRectAt):
2302         Make sure the columnGap() in the old multicolumn code is always expressed as a LayoutUnit. This was the
2303         one place where it was still an int.
2304
2305         * rendering/RenderFlowThread.cpp:
2306         (WebCore::RenderFlowThread::paintFlowThreadPortionInRegion):
2307         Rework the painting of flow thread portions to account for the fact that regions paint at an integral
2308         translation. This means you have to construct clipping around that integral destination. Subpixel layout
2309         regions did not clip correctly as a result of this issue.
2310
2311         * rendering/RenderMultiColumnSet.cpp:
2312         (WebCore::RenderMultiColumnSet::columnRectAt):
2313         Fix the same bug with columnGap() that the old column code has, i.e., one spot where it was an int.
2314
2315         (WebCore::RenderMultiColumnSet::paintObject):
2316         RenderMultiColumnSet should be using paintObject and not paint and it needs to check for visibility
2317         and phases now that it is a RenderBlock subclass.
2318
2319         (WebCore::RenderMultiColumnSet::paintColumnRules):
2320         Fix the bug that Opera guys fixed in the old multi-column code. They didn't patch the new code, so this
2321         takes care of that.
2322
2323         * rendering/RenderMultiColumnSet.h:
2324         (RenderMultiColumnSet):
2325         Change to use paintObject instead of paint.
2326
2327 2013-02-19  Branimir Lambov  <blambov@google.com>
2328
2329         Fix 'slice' aspect ratio calculation
2330         https://bugs.webkit.org/show_bug.cgi?id=99984
2331
2332         Reviewed by Dirk Schulze.
2333
2334         Previously the calculation for the 'slice' aspect ratio would incorrectly calculate the
2335         source rect location based on the destination rect offset. This caused our source rect to be
2336         incorrect, and sometimes render outside the visible area completely. After this patch
2337         our implementation matches the implementation of both Gecko and Presto.
2338
2339         The relevant spec section:
2340         http://www.w3.org/TR/SVG/single-page.html#coords-PreserveAspectRatioAttribute
2341
2342         Tests: svg/as-image/image-preserveAspectRatio-all.svg
2343                svg/filters/feImage-preserveAspectRatio-all.svg
2344
2345         * svg/SVGPreserveAspectRatio.cpp:
2346         (WebCore::SVGPreserveAspectRatio::transformRect):
2347
2348 2013-02-19  Kentaro Hara  <haraken@google.com>
2349
2350         [V8] ScriptRunner::runCompiledScript() should return Handle<Value>() when OOM occurs
2351         https://bugs.webkit.org/show_bug.cgi?id=110254
2352
2353         Reviewed by Adam Barth.
2354
2355         Chromium bug: https://code.google.com/p/chromium/issues/detail?id=176951
2356
2357         Currently ScriptRunner::runCompiledScript() calls
2358         ASSERT(script.IsEmpty()) when OOM occurs. The Chromium bug is
2359         hitting the ASSERT(). The ASSERT() does not make sense at all.
2360         Instead, we should return an empty handle when OOM occurs.
2361
2362         No tests. The bug happens only when OOM occurs.
2363
2364         * bindings/v8/ScriptRunner.cpp:
2365         (WebCore::ScriptRunner::runCompiledScript):
2366
2367 2013-02-19  Elliott Sprehn  <esprehn@chromium.org>
2368
2369         Support both MutationObserver and WebKitMutationObserver
2370         https://bugs.webkit.org/show_bug.cgi?id=109776
2371
2372         Reviewed by Ojan Vafai.
2373
2374         We should allow new MutationObserver now that we support parser generated
2375         mutations. This leaves the old prefixed constructor in until we decide
2376         people don't depend on it.
2377
2378         Test: fast/dom/MutationObserver/mutation-observer-prefix.html
2379
2380         * page/DOMWindow.idl:
2381
2382 2013-02-19  Elliott Sprehn  <esprehn@chromium.org>
2383
2384         Remove RenderText::updateText
2385         https://bugs.webkit.org/show_bug.cgi?id=109991
2386
2387         Reviewed by Eric Seidel.
2388
2389         There's no reason for the generic RenderText::updateText virtual hook
2390         anymore now that r143060 made RenderQuote stop setting dirty bits during
2391         layout since the hook is only used by RenderCounter.
2392
2393         Instead add updateCounterIfNeeded and make it clear this is a hack for
2394         counters.
2395
2396         * rendering/RenderBlockLineLayout.cpp:
2397         (WebCore::updateCounterIfNeeded): Added, not handles the counter specific hack.
2398         (WebCore::dirtyLineBoxesForRenderer):
2399         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
2400         * rendering/RenderCounter.cpp:
2401         (WebCore::RenderCounter::updateCounter):
2402         * rendering/RenderCounter.h:
2403         (RenderCounter):
2404         * rendering/RenderQuote.cpp:
2405         (WebCore::RenderQuote::styleDidChange):
2406         (WebCore::RenderQuote::updateDepth):
2407         * rendering/RenderQuote.h:
2408         (RenderQuote):
2409         * rendering/RenderText.h:
2410         (RenderText):
2411
2412 2013-02-19  Tony Chang  <tony@chromium.org>
2413
2414         Border changes on tables with collapsed borders doesn't relayout table cells
2415         https://bugs.webkit.org/show_bug.cgi?id=109774
2416
2417         Reviewed by David Hyatt.
2418
2419         Test: fast/table/border-collapsing/dynamic-border-width-change.html
2420
2421         Changes to border top and border bottom on table rows also changes the size
2422         of the table cell causing a relayout to be needed.
2423
2424         * rendering/RenderTableRow.cpp:
2425         (WebCore::borderWidthChanged): Also include border top and bottom.
2426         (WebCore::RenderTableRow::styleDidChange): Remove logical from the helper function name.
2427
2428 2013-02-19  Kentaro Hara  <haraken@chromium.org>
2429
2430         Unreviewed. Rebaselined run-bindings-tests.
2431
2432         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
2433         (WebCore::JSTestNamedConstructorNamedConstructor::constructJSTestNamedConstructor):
2434         * bindings/scripts/test/JS/JSTestObj.cpp:
2435         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNullString):
2436
2437 2013-02-19  ChangSeok Oh  <changseok.oh@collabora.com>
2438
2439         [GTK][AC] Implement matrix transform animation with clutter ac backend
2440         https://bugs.webkit.org/show_bug.cgi?id=109848
2441
2442         Reviewed by Gustavo Noronha Silva.
2443
2444         Clutter 1.12 doesn't support additive transform animations yet, so the combination
2445         of two or more transformations(such as rotation after translation) runs unexpectedly.
2446         So we use a matrix transformation instead for the case.
2447
2448         Covered by existing animation tests.
2449
2450         * platform/graphics/clutter/GraphicsLayerClutter.cpp:
2451         (WebCore::getValueFunctionNameForTransformOperation):
2452         (WebCore::GraphicsLayerClutter::createTransformAnimationsFromKeyframes):
2453         * platform/graphics/clutter/PlatformClutterAnimation.cpp:
2454         (WebCore::toClutterActorPropertyString): Add actor property "transform"
2455         (WebCore::clutterMatrixProgress): Handle interpolation between two matrices instead of default clutter_matrix_progress.
2456         (WebCore):
2457         (WebCore::PlatformClutterAnimation::supportsAdditiveValueFunction):
2458         (WebCore::PlatformClutterAnimation::setFromValue): for TransformationMatrix.
2459         (WebCore::PlatformClutterAnimation::setToValue): ditto.
2460         (WebCore::PlatformClutterAnimation::addClutterTransitionForProperty):
2461         (WebCore::PlatformClutterAnimation::addTransformTransition):
2462         * platform/graphics/clutter/PlatformClutterAnimation.h:
2463         (PlatformClutterAnimation):
2464         * platform/graphics/clutter/TransformationMatrixClutter.cpp: Add copy constructor for CoglMatrix.
2465         (WebCore::TransformationMatrix::TransformationMatrix):
2466         (WebCore):
2467         * platform/graphics/transforms/TransformationMatrix.h:
2468         (TransformationMatrix):
2469
2470 2013-02-19  Kassy Coan  <kassycoan@chromium.org>
2471
2472         Update FeatureObserver on top level navigation in addition to page destruction.
2473         https://bugs.webkit.org/show_bug.cgi?id=109874
2474
2475         Reviewed by Adam Barth.
2476
2477         No new tests. Only effect is to histogram more frequently.
2478
2479         * loader/FrameLoader.cpp:
2480         (WebCore::FrameLoader::dispatchDidCommitLoad):
2481         * page/FeatureObserver.cpp:
2482         (WebCore::FeatureObserver::~FeatureObserver):
2483         (WebCore):
2484         (WebCore::FeatureObserver::updateMeasurements):
2485         (WebCore::FeatureObserver::didCommitLoad):
2486         * page/FeatureObserver.h:
2487         (FeatureObserver):
2488
2489 2013-02-19  Morten Stenshorne  <mstensho@opera.com>
2490
2491         Remove unnecessary (and problematic) copy-constructor from LayoutUnit
2492         https://bugs.webkit.org/show_bug.cgi?id=110121
2493
2494         This copy constructor does what a default copy constructor would do, so
2495         it's not necessary. Furthermore, this copy constructor is the only
2496         reason why LayoutUnit becomes non-POD, and that triggers a gdb bug,
2497         making it impossible to do things like "print location()" when inside
2498         some RenderBlock, for instance.
2499
2500         Gdb bug http://sourceware.org/bugzilla/show_bug.cgi?id=15154 reported.
2501
2502         Reviewed by Benjamin Poulain.
2503
2504         No tests. Apart from dealing with buggy debuggers, this is just code cleanup.
2505
2506         * platform/LayoutUnit.h:
2507
2508 2013-02-19  Emil A Eklund  <eae@chromium.org>
2509
2510         LayoutUnit::epsilon shouldn't be necessary to place floats
2511         https://bugs.webkit.org/show_bug.cgi?id=94000
2512
2513         Reviewed by Levi Weintraub.
2514         
2515         Currently, to get float placement correct, we need to have an
2516         epsilon tolerance in RenderBlock::computeLogicalLocationForFloat
2517         for the width of the line to fit them on. This really shouldn't
2518         be necessary, and probably indicates we're losing precision
2519         elsewhere.
2520         
2521         Remove epsilon as it no longer appears to be needed. All layout
2522         tests pass without it.
2523
2524         No new tests, covered by existing tests.
2525
2526         * rendering/RenderBlock.cpp:
2527         (WebCore::RenderBlock::computeLogicalLocationForFloat):
2528
2529 2013-02-19  Tim Volodine  <timvolodine@chromium.org>
2530
2531         Text Autosizing: prevent oscillation of font sizes during autosizing
2532         https://bugs.webkit.org/show_bug.cgi?id=108205
2533
2534         Reviewed by Kenneth Rohde Christiansen.
2535
2536         On some websites autosized font-sizes oscillate due to layouts caused by
2537         hovering or incremental page loading (and on other sites font sizes do
2538         eventually stabilize, but it takes many layouts before they reach a steady
2539         size). To prevent all these cases, we no longer allow the autosizing
2540         multiplier to change after it has been set (to a value other than 1).
2541
2542         This won't always give exactly the same results, but testing on 2000 top
2543         sites shows that this makes little difference in practice, and it prevents
2544         these very jarring cases. As a happy side-effect, this speeds up layouts
2545         as font sizes change less.
2546
2547         Test: fast/text-autosizing/oscillation-javascript-fontsize-change.html
2548
2549         * page/FrameView.cpp:
2550         (WebCore::FrameView::setFrameRect):
2551         * page/Settings.cpp:
2552         (WebCore::Settings::setTextAutosizingFontScaleFactor):
2553         * rendering/TextAutosizer.cpp:
2554         (WebCore::TextAutosizer::recalculateMultipliers):
2555         (WebCore):
2556         (WebCore::TextAutosizer::processContainer):
2557         * rendering/TextAutosizer.h:
2558         (TextAutosizer):
2559
2560 2013-02-19  Youenn Fablet  <youennf@gmail.com>
2561
2562         [EFL][DRT] http/tests/loading/307-after-303-after-post.html times out
2563         https://bugs.webkit.org/show_bug.cgi?id=93214
2564
2565         Ensured that GET verb is consistently used for any request
2566         coming after a redirection that triggers switching to GET.
2567
2568         Reviewed by Martin Robinson.
2569
2570         * platform/network/soup/ResourceHandleSoup.cpp:
2571         (WebCore::doRedirect):
2572
2573 2013-02-19  Andras Becsi  <andras.becsi@digia.com>
2574
2575         [Qt] Fix compilation if Qt was configured with -no-rtti
2576         https://bugs.webkit.org/show_bug.cgi?id=110234
2577
2578         Reviewed by Noam Rosenthal.
2579
2580         Availability of dynamic_cast should be checked.
2581
2582         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
2583         (WebCore::GraphicsLayerTextureMapper::updateBackingStoreIfNeeded):
2584
2585 2013-02-18  Alexey Proskuryakov  <ap@apple.com>
2586
2587         Unregistered blob URLs have incorrect MIME type
2588         https://bugs.webkit.org/show_bug.cgi?id=110166
2589
2590         Reviewed by Sam Weinig.
2591
2592         * page/SecurityOrigin.cpp: (WebCore::SecurityOrigin::shouldUseInnerURL): Added a FIXME.
2593
2594         * platform/network/BlobResourceHandle.cpp: (WebCore::BlobResourceHandle::notifyResponseOnError):
2595         Pass an accurate MIME type (for a delegate to see).
2596
2597 2013-02-19  Joshua Bell  <jsbell@chromium.org>
2598
2599         IndexedDB: additional checks on LevelDB decoding
2600         https://bugs.webkit.org/show_bug.cgi?id=109711
2601
2602         Reviewed by Tony Chang.
2603
2604         Watch out for decoding errors caused by corrupted data, and exit various
2605         decode/compare operations earlier.
2606
2607         Covered by existing LayoutTests and Chromium's webkit_unit_tests
2608
2609         * Modules/indexeddb/IDBLevelDBCoding.cpp:
2610         (WebCore::IDBLevelDBCoding::decodeStringWithLength): Bail if length is negative.
2611         (WebCore::IDBLevelDBCoding::compareEncodedStringsWithLength): Distinguish error case.
2612         (WebCore::IDBLevelDBCoding::extractEncodedIDBKey): Bail if length is negative.
2613         (WebCore::IDBLevelDBCoding::compareEncodedIDBKeys): Distinguish error case.
2614         (WebCore::IDBLevelDBCoding::compare): Plumb through "ok".
2615         (WebCore::IDBLevelDBCoding::ObjectStoreDataKey::compare): Ditto.
2616         (WebCore::IDBLevelDBCoding::ExistsEntryKey::compare): Ditto.
2617         (WebCore::IDBLevelDBCoding::IndexDataKey::compare): Ditto.
2618         * Modules/indexeddb/IDBLevelDBCoding.h: Updated method signatures.
2619
2620 2013-02-19  ChangSeok Oh  <changseok.oh@collabora.com>
2621
2622         [GTK][AC] Implement keyframe animations with clutter ac backend
2623         https://bugs.webkit.org/show_bug.cgi?id=110057
2624
2625         Reviewed by Gustavo Noronha Silva.
2626
2627         This patch brings accelerated keyframe animation with clutter to WebKitGtk+.
2628         Changes of GraphicsLayerClutter are based on GraphicsLayerCA. But major changes
2629         of PlatformClutterAnimation are implemented with clutter keyframe transition apis.
2630         See http://developer.gnome.org/clutter/stable/ClutterKeyframeTransition.html
2631
2632         Covered by existing animation tests.
2633
2634         * platform/graphics/clutter/GraphicsLayerClutter.cpp:
2635         (WebCore::GraphicsLayerClutter::createKeyframeAnimation):
2636         (WebCore::GraphicsLayerClutter::setTransformAnimationKeyframes):
2637         (WebCore::GraphicsLayerClutter::setAnimationKeyframes):
2638         * platform/graphics/clutter/PlatformClutterAnimation.cpp:
2639         (WebCore::toClutterActorPropertyString):
2640         (WebCore::PlatformClutterAnimation::PlatformClutterAnimation):
2641         (WebCore::PlatformClutterAnimation::setTimingFunction):
2642         (WebCore::PlatformClutterAnimation::setValues):
2643         (WebCore::PlatformClutterAnimation::setKeyTimes):
2644         (WebCore::PlatformClutterAnimation::setTimingFunctions):
2645         (WebCore::PlatformClutterAnimation::addClutterTransitionForProperty):
2646         (WebCore):
2647         (WebCore::PlatformClutterAnimation::addClutterKeyframeTransitionForProperty):
2648         (WebCore::PlatformClutterAnimation::addOpacityTransition):
2649         (WebCore::PlatformClutterAnimation::addTransformTransition):
2650         (WebCore::PlatformClutterAnimation::addAnimationForKey):
2651         (WebCore::PlatformClutterAnimation::removeAnimationForKey):
2652         * platform/graphics/clutter/PlatformClutterAnimation.h:
2653         (PlatformClutterAnimation):
2654
2655 2013-02-19  Claudio Saavedra  <csaavedra@igalia.com>
2656
2657         [harfbuzz] Crash in harfbuzz related code
2658         https://bugs.webkit.org/show_bug.cgi?id=110145
2659
2660         Reviewed by Martin Robinson.
2661
2662         Patch by Behdad Esfahbod <behdad@google.com>
2663
2664         * platform/graphics/harfbuzz/HarfBuzzShaper.cpp:
2665         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns): Ask harfbuzz
2666         to guess the segment properties.
2667
2668 2013-02-19  Pavel Podivilov  <podivilov@chromium.org>
2669
2670         Web Inspector: release backtrace object group on each step.
2671         https://bugs.webkit.org/show_bug.cgi?id=110223
2672
2673         Reviewed by Pavel Feldman.
2674
2675         * inspector/InspectorDebuggerAgent.cpp:
2676         (WebCore):
2677         (WebCore::InspectorDebuggerAgent::stepOver):
2678         (WebCore::InspectorDebuggerAgent::stepInto):
2679         (WebCore::InspectorDebuggerAgent::stepOut):
2680
2681 2013-02-19  Sheriff Bot  <webkit.review.bot@gmail.com>
2682
2683         Unreviewed, rolling out r142975.
2684         http://trac.webkit.org/changeset/142975
2685         https://bugs.webkit.org/show_bug.cgi?id=110225
2686
2687         Introduces hard-to-reproduce crashes upon inspected page
2688         navigation on Mac (Requested by apavlov on #webkit).
2689
2690         * dom/DocumentStyleSheetCollection.cpp:
2691         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
2692         * inspector/Inspector.json:
2693         * inspector/InspectorCSSAgent.cpp:
2694         (WebCore::InspectorCSSAgent::InspectorCSSAgent):
2695         (WebCore::InspectorCSSAgent::clearFrontend):
2696         (WebCore::InspectorCSSAgent::enable):
2697         (WebCore::InspectorCSSAgent::getAllStyleSheets):
2698         (WebCore::InspectorCSSAgent::collectStyleSheets):
2699         (WebCore::InspectorCSSAgent::bindStyleSheet):
2700         (WebCore::InspectorCSSAgent::viaInspectorStyleSheet):
2701         (WebCore::InspectorCSSAgent::detectOrigin):
2702         (WebCore::InspectorCSSAgent::buildObjectForRule):
2703         * inspector/InspectorCSSAgent.h:
2704         (InspectorCSSAgent):
2705         * inspector/InspectorInstrumentation.cpp:
2706         (WebCore):
2707         * inspector/InspectorInstrumentation.h:
2708         (WebCore):
2709         (InspectorInstrumentation):
2710         * inspector/front-end/CSSStyleModel.js:
2711         (WebInspector.CSSStyleModel.prototype.getViaInspectorResourceForRule):
2712         (WebInspector.CSSStyleModelResourceBinding.prototype.):
2713         (WebInspector.CSSStyleModelResourceBinding.prototype.requestStyleSheetIdForResource):
2714         (WebInspector.CSSStyleModelResourceBinding.prototype.requestResourceURLForStyleSheetId):
2715         (WebInspector.CSSStyleModelResourceBinding.prototype._styleSheetIdForResource):
2716         (WebInspector.CSSStyleModelResourceBinding.prototype._loadStyleSheetHeaders):
2717         (WebInspector.CSSStyleModelResourceBinding.prototype.headersLoaded):
2718         (WebInspector.CSSStyleModelResourceBinding.prototype._requestViaInspectorResource):
2719         (WebInspector.CSSStyleModelResourceBinding.prototype._getOrCreateInspectorResource):
2720         (WebInspector.CSSStyleModelResourceBinding.prototype._reset):
2721         * inspector/front-end/SASSSourceMapping.js:
2722         (WebInspector.SASSSourceMapping.prototype._styleSheetChanged.callback):
2723         (WebInspector.SASSSourceMapping.prototype._styleSheetChanged):
2724         * inspector/front-end/StylesSidebarPane.js:
2725         (WebInspector.StylePropertiesSection.prototype._createRuleOriginNode.callback):
2726         (WebInspector.StylePropertiesSection.prototype._createRuleOriginNode):
2727         * inspector/front-end/StylesSourceMapping.js:
2728         (WebInspector.StyleContentBinding.prototype.callback):
2729         (WebInspector.StyleContentBinding.prototype.setStyleContent):
2730         (WebInspector.StyleContentBinding.prototype.):
2731         (WebInspector.StyleContentBinding.prototype._innerStyleSheetChanged):
2732
2733 2013-02-19  Julien Chaffraix  <jchaffraix@webkit.org>
2734
2735         RenderGrid::computedUsedBreadthOfGridTracks can read past m_grid's size
2736         https://bugs.webkit.org/show_bug.cgi?id=110126
2737
2738         Reviewed by Ojan Vafai.
2739
2740         The issue comes from how we store the column information inside m_grid.
2741         Because m_grid is a Vector of rows, we could lose the column information
2742         if we had no row, no grid item but some columns defined in CSS. As the
2743         logic would assume that our row / column size would be greater than what
2744         the style defines explicitely, we would access past our Vector's boundary.
2745
2746         The fix is to ensure that we have at least a row so that we can store the
2747         column information in every case. This fix is overly broad as it also forces
2748         the grid to have one column, which shouldn't be an issue.
2749
2750         Test: fast/css-grid-layout/grid-element-empty-row-column.html
2751
2752         * rendering/RenderGrid.cpp:
2753         (WebCore::RenderGrid::maximumIndexInDirection):
2754         Forced this function to return at least one as the maximum index so that
2755         m_grid has at least one row / column.
2756
2757         (WebCore::RenderGrid::placeItemsOnGrid):
2758         Added a ASSERT that m_grid is bigger than the explicit grid-rows / grid-columns.
2759         Also changed an existing ASSERT to use gridWasPopulated for consistency and changed
2760         the code not to call gridRowCount as it would ASSERT (we are in the middle of populating
2761         the grid).
2762
2763         * rendering/RenderGrid.h:
2764         (WebCore::RenderGrid::gridWasPopulated):
2765         Added this helper function.
2766
2767         (WebCore::RenderGrid::gridColumnCount):
2768         Replaced a now unneeded branch with an ASSERT. As placeItemsOnGrid should be called
2769         prior to read m_grid, this change should be fine.
2770
2771         (WebCore::RenderGrid::gridRowCount):
2772         Added an ASSERT.
2773
2774 2013-02-19  Sergio Villar Senin  <svillar@igalia.com>
2775
2776         [Soup] Use synchronous calls to close completely processed streams
2777         https://bugs.webkit.org/show_bug.cgi?id=107432
2778
2779         Reviewed by Martin Robinson.
2780
2781         There is no need to close already processed streams in asynchronous
2782         calls since they won't block. Using the synchronous call will save
2783         us some code and unnecessary asynchronous burden. This is kind of
2784         a code refactor so no new tests needed.
2785
2786         * platform/network/soup/ResourceHandleSoup.cpp:
2787         (WebCore):
2788         (WebCore::redirectSkipCallback):
2789         (WebCore::readCallback):
2790
2791 2013-02-19  Andrey Adaikin  <aandrey@chromium.org>
2792
2793         Web Inspector: [Canvas] use timeline's didBeginFrame for marking frame end calls
2794         https://bugs.webkit.org/show_bug.cgi?id=110130
2795
2796         Reviewed by Pavel Feldman.
2797
2798         In Web Inspector canvas profiler use timeline's didBeginFrame for marking frame end calls instead of an ad-hoc timeout-based solution.
2799
2800         * inspector/InjectedScriptCanvasModule.cpp:
2801         (WebCore::InjectedScriptCanvasModule::markFrameEnd):
2802         (WebCore):
2803         * inspector/InjectedScriptCanvasModule.h:
2804         (InjectedScriptCanvasModule):
2805         * inspector/InjectedScriptCanvasModuleSource.js:
2806         (.):
2807         * inspector/InspectorCanvasAgent.cpp:
2808         (WebCore::InspectorCanvasAgent::hasUninstrumentedCanvases):
2809         (WebCore::InspectorCanvasAgent::notifyRenderingContextWasWrapped):
2810         (WebCore::InspectorCanvasAgent::findFramesWithUninstrumentedCanvases):
2811         (WebCore::InspectorCanvasAgent::frameNavigated):
2812         (WebCore::InspectorCanvasAgent::didBeginFrame):
2813         (WebCore):
2814         * inspector/InspectorCanvasAgent.h:
2815         (InspectorCanvasAgent):
2816         * inspector/InspectorController.cpp:
2817         (WebCore::InspectorController::didBeginFrame):
2818
2819 2013-02-19  Vsevolod Vlasov  <vsevik@chromium.org>
2820
2821         Web Inspector: Decouple various file system project implementation parts for better testability and cover with tests.
2822         https://bugs.webkit.org/show_bug.cgi?id=110204
2823
2824         Reviewed by Pavel Feldman.
2825
2826         Extracted FileSystemWorkspaceProvider from IsolatedFileSystemManager to take care of managing workspace projects and projectDelegates.
2827         Replaced FileMapping.urlForURI with urlForPath method that does not need any information about workspace structure anymore.
2828
2829         Test: inspector/file-system-project.html
2830
2831         * inspector/front-end/FileMapping.js:
2832         (WebInspector.FileMapping.prototype.urlForPath):
2833         * inspector/front-end/FileSystemProjectDelegate.js:
2834         (WebInspector.FileSystemProjectDelegate):
2835         (WebInspector.FileSystemProjectDelegate.prototype.populate.filesLoaded):
2836         (WebInspector.FileSystemProjectDelegate.prototype.populate):
2837         (WebInspector.FileSystemWorkspaceProvider):
2838         (WebInspector.FileSystemWorkspaceProvider.prototype._fileSystemAdded):
2839         (WebInspector.FileSystemWorkspaceProvider.prototype._fileSystemRemoved):
2840         * inspector/front-end/IsolatedFileSystem.js:
2841         (WebInspector.IsolatedFileSystem):
2842         (WebInspector.IsolatedFileSystem.prototype.name):
2843         (WebInspector.IsolatedFileSystem.prototype.rootURL):
2844         * inspector/front-end/IsolatedFileSystemManager.js:
2845         (WebInspector.IsolatedFileSystemManager):
2846         (WebInspector.IsolatedFileSystemManager.prototype._innerAddFileSystem):
2847         (WebInspector.IsolatedFileSystemManager.prototype._fileSystemRemoved):
2848         (WebInspector.IsolatedFileSystemManager.prototype._isolatedFileSystem):
2849         (WebInspector.IsolatedFileSystemManager.prototype.requestDOMFileSystem):
2850         * inspector/front-end/inspector.js:
2851
2852 2013-02-19  Andrey Adaikin  <aandrey@chromium.org>
2853
2854         Web Inspector: [Canvas] do not replace replay image with spinner icon
2855         https://bugs.webkit.org/show_bug.cgi?id=110213
2856
2857         Reviewed by Pavel Feldman.
2858
2859         Otherwise it's visually hard to see changes in the replay image. Instead show a small spinner icon in the bottom right corner.
2860
2861         * inspector/front-end/CanvasProfileView.js:
2862         (WebInspector.CanvasProfileView):
2863         (WebInspector.CanvasProfileView.prototype._enableWaitIcon):
2864         * inspector/front-end/canvasProfiler.css:
2865         (#canvas-replay-image-container):
2866         (.canvas-debug-info):
2867         (.canvas-spinner-icon):
2868
2869 2013-02-19  Andrey Adaikin  <aandrey@chromium.org>
2870
2871         Web Inspector: [Canvas] UI: tweak replay control buttons behavior
2872         https://bugs.webkit.org/show_bug.cgi?id=110207
2873
2874         Reviewed by Pavel Feldman.
2875
2876         New behavior for control buttons in the Canvas profiler.
2877         - The NextCall button (~StepInto) on a node group should expand it and move into its first child (instead of expanding and moving into the next node group)
2878         - The NextDrawCall button (~StepOver) should move to a next node that has children (instead of just iterating call group nodes, ignoring frame nodes).
2879         - The ReplayLast button should select the last expanded node (instead of always selecting last frame group node).
2880
2881         * inspector/front-end/CanvasProfileView.js:
2882         (WebInspector.CanvasProfileView.prototype._onReplayStepClick):
2883         (WebInspector.CanvasProfileView.prototype._onReplayDrawingCallClick):
2884         (WebInspector.CanvasProfileView.prototype._onReplayLastStepClick):
2885
2886 2013-02-19  Andrei Bucur  <abucur@adobe.com>
2887
2888         [CSS Regions] Assertion in RenderFlowThread::removeRenderBoxRegionInfo
2889         https://bugs.webkit.org/show_bug.cgi?id=109914
2890
2891         Reviewed by David Hyatt.
2892
2893         This patch moves a part of the invalidation operations inside the RenderFlowThread::invalidateRegions call. The maps
2894         are cleared anyway at layout time but doing this earlier makes sure the flow thread is in a more consistent state
2895         (the RenderFlowThread object has both the region chain invalidated and the regions information cleared).
2896
2897         RenderFlowThread::removeRenderBoxRegionInfo will check if the region chain is invalidated. If true, it means the
2898         flow thread has a layout scheduled and the regions information is not yet reliable. In this case we just return from the
2899         function and wait for the layout to cleanup the box information.
2900
2901         Test: fast/regions/remove-box-info-assert.html
2902
2903         * rendering/RenderFlowThread.cpp:
2904         (WebCore::RenderFlowThread::removeRegionFromThread):
2905         (WebCore::RenderFlowThread::invalidateRegions):
2906         (WebCore):
2907         (WebCore::RenderFlowThread::layout):
2908         (WebCore::RenderFlowThread::removeRenderBoxRegionInfo):
2909         * rendering/RenderFlowThread.h:
2910         * rendering/RenderNamedFlowThread.cpp:
2911         (WebCore::RenderNamedFlowThread::removeRegionFromThread):
2912
2913 2013-02-19  Alberto Garcia  <agarcia@igalia.com>
2914
2915         Fix build broekn by r142988.
2916         https://bugs.webkit.org/show_bug.cgi?id=109530
2917
2918         Unreviewed. Build fix.
2919
2920         Properly add shortMonthFormat() to the LocaleNone class.
2921
2922         * platform/text/LocaleNone.cpp:
2923         (LocaleNone):
2924         (WebCore::LocaleNone::shortMonthFormat):
2925
2926 2013-02-19  Anton Vayvod  <avayvod@chromium.org>
2927
2928         [Text Autosizing] Combine narrow descendants of a cluster into groups that should be autosized with the same multiplier.
2929         https://bugs.webkit.org/show_bug.cgi?id=109825
2930
2931         Enhancement of the approach introduced in https://bugs.webkit.org/show_bug.cgi?id=109573.
2932         Instead of using the same text size multiplier for all narrow descendants of any autosizing
2933         cluster, group the descendants by how much narrower they are than the cluster's
2934         |blockContainingAllText| and process each group separately with a different multiplier for
2935         each one.
2936         For example, we want nested comments on the page to be autosized as a group but separately
2937         from a sidebar on the same page.
2938
2939         Reviewed by Kenneth Rohde Christiansen.
2940
2941         Updated the existing test to verify the patch.
2942
2943         * rendering/TextAutosizer.cpp:
2944         (WebCore::TextAutosizer::processClusterInternal):
2945
2946             Splits the narrow descendants of the autosizing cluster into groups before processing
2947             each group individually.
2948
2949         (WebCore::TextAutosizer::getNarrowDescendantsGroupedByWidth):
2950
2951             Sorts the narrow descendants of the given cluster into groups, combining them by the
2952             difference between their content widths. If sorted by width, two consecutive nodes
2953             belong to the same group if their width difference is no greater than 100 CSS units.
2954
2955         * rendering/TextAutosizer.h:
2956
2957             New method definitions.
2958
2959 2013-02-18  Ilya Tikhonovsky  <loislo@chromium.org>
2960
2961         Web Inspector: Native Memory Instrumentation: show user provided name property of the heap snapshot node.
2962         https://bugs.webkit.org/show_bug.cgi?id=110124
2963
2964         Reviewed by Yury Semikhatsky.
2965
2966         Publish userProvidedName into grid node.
2967
2968         * inspector/front-end/HeapSnapshotGridNodes.js:
2969         (WebInspector.HeapSnapshotGenericObjectNode):
2970         (WebInspector.HeapSnapshotGenericObjectNode.prototype._createObjectCell):
2971         (WebInspector.HeapSnapshotGenericObjectNode.prototype.get data):
2972         * inspector/front-end/HeapSnapshotProxy.js:
2973         (WebInspector.HeapSnapshotWorker):
2974         * inspector/front-end/NativeHeapSnapshot.js:
2975         (WebInspector.NativeHeapSnapshotNode.prototype.serialize):
2976
2977 2013-02-19  Arpita Bahuguna  <a.bah@samsung.com>
2978
2979         Caret is not displayed when trying to focus inside a contenteditable element containing an empty block.
2980         https://bugs.webkit.org/show_bug.cgi?id=108053
2981
2982         Reviewed by Ryosuke Niwa.
2983
2984         Test: editing/selection/caret-in-div-containing-empty-block.html
2985
2986         * rendering/RenderBox.cpp:
2987         (WebCore::RenderBox::localCaretRect):
2988         When trying to compute the caret rect for the contenteditable div, the
2989         border and the padding were not considered. Because of this, for the
2990         given test case, which had a border defined on the containing div, the
2991         caret was being painted just atop the border, thereby masking it.
2992
2993         Have modified the code to ensure that the computed caret rect takes
2994         into account the border and padding (if any) specified on the box, but only
2995         if the node doesn't have content that shall be skipped for editing.
2996
2997         We do not add border and padding while computing the caret rect for any
2998         element that either has no content or has content that shall be skipped
2999         for editing purposes. This holds true for table elements as well.
3000
3001         This helps avoid the caret displacement previsouly observed before/after
3002         any controls placed within the contenteditable box, when considering
3003         border and padding in computation of the caret rect.
3004
3005 2013-02-19  Mihnea Ovidenie  <mihnea@adobe.com>
3006
3007         CSSRegions: crash positioned object with inline containing block in flow thread
3008         https://bugs.webkit.org/show_bug.cgi?id=108307
3009
3010         Reviewed by David Hyatt.
3011
3012         The fix for https://bugs.webkit.org/show_bug.cgi?id=69896 allowed positioned blocks work
3013         with variable width regions. However, the information needed for that is available only
3014         when the container used for positioning is a block.
3015
3016         This patch ensures we are using this solution only when the container used for positioning
3017         is a block. This needs to be revisited when we will extend support for other types of boxes
3018         as mentioned in RenderBox::renderBoxRegionInfo.
3019
3020         Test: fast/regions/positioned-object-inline-cb-crash.html
3021
3022         * rendering/RenderBox.cpp:
3023         (WebCore::RenderBox::renderBoxRegionInfo):
3024         (WebCore::RenderBox::containingBlockLogicalWidthForPositioned):
3025         (WebCore::RenderBox::computePositionedLogicalWidth): Make sure we are using containerBlocks
3026         that are blocks. Add an assert that the type of containerBlock we are using can have
3027         computed RenderBoxRegionInfo.
3028         (WebCore::RenderBox::computePositionedLogicalHeight):
3029         * rendering/RenderBoxModelObject.h:
3030         (WebCore::RenderBoxModelObject::canHaveBoxInfoInRegion): This helper method
3031         will return the boxes that may have computed RenderBoxRegionInfo. Currently,
3032         returns true for blocks only.
3033
3034 2013-02-19  Ryosuke Niwa  <rniwa@webkit.org>
3035
3036         Yet anther JSC build fix after r143304.
3037
3038         * bindings/js/JSDOMBinding.h:
3039         (WebCore::argumentOrNull):
3040
3041 2013-02-19  Kentaro Hara  <haraken@chromium.org>
3042
3043         Unreviewed build fix. Fixed warning caused by r143305.
3044
3045         * bindings/scripts/CodeGeneratorJS.pm:
3046         (GenerateParametersCheck):
3047         * bindings/scripts/CodeGeneratorV8.pm:
3048         (GenerateParametersCheck):
3049
3050 2013-02-19  Kentaro Hara  <haraken@chromium.org>
3051
3052         Unreviewed build fix after r143304.
3053
3054         * bindings/js/JSDOMBinding.h:
3055         (WebCore::argumentOrNull):
3056
3057 2013-02-19  Kentaro Hara  <haraken@chromium.org>
3058
3059         [V8] Remove redundant usage of MAYBE_MISSING_PARAMETER() macro
3060         https://bugs.webkit.org/show_bug.cgi?id=109899
3061
3062         Reviewed by Adam Barth.
3063
3064         Currently:
3065
3066         - MAYBE_MISSING_PARAMETER(args, index, DefaultIsUndefined) returns args[index].
3067         - MAYBE_MISSING_PARAMETER(args, index, DefaultIsNullString) returns Local<Value>()
3068         if args[index] is missing (i.e. the length of |args| is less than |index|).
3069         It returns args[index] otherwise.
3070
3071         No one other than CodeGeneratorV8.pm uses
3072         MAYBE_MISSING_PARAMETER(args, index, DefaultIsUndefined). Instead, we simply use
3073         args[index]. We should remove the redundant usage from CodeGeneratorV8.pm too.
3074         The long-name macro has been making generated code less readable.
3075
3076         In addition, we can rename MAYBE_MISSING_PARAMETER() to argumentOrNull().
3077
3078         No tests. No change in behavior.
3079
3080         * bindings/scripts/CodeGeneratorV8.pm:
3081         (GenerateParametersCheck):
3082         * bindings/scripts/test/V8/V8Float64Array.cpp:
3083         (WebCore::Float64ArrayV8Internal::fooCallback):
3084         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
3085         (WebCore::TestActiveDOMObjectV8Internal::excitingFunctionCallback):
3086         (WebCore::TestActiveDOMObjectV8Internal::postMessageCallback):
3087         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
3088         (WebCore::TestCustomNamedGetterV8Internal::anotherFunctionCallback):
3089         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
3090         (WebCore::TestEventTargetV8Internal::itemCallback):
3091         (WebCore::TestEventTargetV8Internal::dispatchEventCallback):
3092         * bindings/scripts/test/V8/V8TestInterface.cpp:
3093         (WebCore::TestInterfaceV8Internal::supplementalMethod2Callback):
3094         (WebCore::V8TestInterface::constructorCallback):
3095         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
3096         (WebCore::TestMediaQueryListListenerV8Internal::methodCallback):
3097         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
3098         (WebCore::V8TestNamedConstructorConstructorCallback):
3099         * bindings/scripts/test/V8/V8TestObj.cpp:
3100         (WebCore::TestObjV8Internal::voidMethodWithArgsCallback):
3101         (WebCore::TestObjV8Internal::longMethodWithArgsCallback):
3102         (WebCore::TestObjV8Internal::objMethodWithArgsCallback):
3103         (WebCore::TestObjV8Internal::methodWithSequenceArgCallback):
3104         (WebCore::TestObjV8Internal::methodReturningSequenceCallback):
3105         (WebCore::TestObjV8Internal::methodThatRequiresAllArgsAndThrowsCallback):
3106         (WebCore::TestObjV8Internal::optionsObjectCallback):
3107         (WebCore::TestObjV8Internal::methodWithOptionalArgCallback):
3108         (WebCore::TestObjV8Internal::methodWithNonOptionalArgAndOptionalArgCallback):
3109         (WebCore::TestObjV8Internal::methodWithNonOptionalArgAndTwoOptionalArgsCallback):
3110         (WebCore::TestObjV8Internal::methodWithOptionalStringCallback):
3111         (WebCore::TestObjV8Internal::methodWithOptionalStringIsUndefinedCallback):
3112         (WebCore::TestObjV8Internal::methodWithOptionalStringIsNullStringCallback):
3113         (WebCore::TestObjV8Internal::methodWithNonCallbackArgAndCallbackArgCallback):
3114         (WebCore::TestObjV8Internal::overloadedMethod1Callback):
3115         (WebCore::TestObjV8Internal::overloadedMethod2Callback):
3116         (WebCore::TestObjV8Internal::overloadedMethod3Callback):
3117         (WebCore::TestObjV8Internal::overloadedMethod4Callback):
3118         (WebCore::TestObjV8Internal::overloadedMethod6Callback):
3119         (WebCore::TestObjV8Internal::overloadedMethod7Callback):
3120         (WebCore::TestObjV8Internal::overloadedMethod8Callback):
3121         (WebCore::TestObjV8Internal::overloadedMethod9Callback):
3122         (WebCore::TestObjV8Internal::overloadedMethod10Callback):
3123         (WebCore::TestObjV8Internal::overloadedMethod11Callback):
3124         (WebCore::TestObjV8Internal::classMethodWithOptionalCallback):
3125         (WebCore::TestObjV8Internal::overloadedMethod12Callback):
3126         (WebCore::TestObjV8Internal::enabledAtRuntimeMethod1Callback):
3127         (WebCore::TestObjV8Internal::enabledAtRuntimeMethod2Callback):
3128         (WebCore::TestObjV8Internal::enabledPerContextMethod1Callback):
3129         (WebCore::TestObjV8Internal::enabledPerContextMethod2Callback):
3130         (WebCore::TestObjV8Internal::stringArrayFunctionCallback):
3131         (WebCore::TestObjV8Internal::domStringListFunctionCallback):
3132         (WebCore::TestObjV8Internal::convert1Callback):
3133         (WebCore::TestObjV8Internal::convert2Callback):
3134         (WebCore::TestObjV8Internal::convert4Callback):
3135         (WebCore::TestObjV8Internal::convert5Callback):
3136         (WebCore::TestObjV8Internal::strictFunctionCallback):
3137         (WebCore::TestObjV8Internal::variadicStringMethodCallback):
3138         (WebCore::TestObjV8Internal::variadicDoubleMethodCallback):
3139         (WebCore::TestObjV8Internal::variadicNodeMethodCallback):
3140         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
3141         (WebCore::V8TestOverloadedConstructors::constructor1Callback):
3142         (WebCore::V8TestOverloadedConstructors::constructor2Callback):
3143         (WebCore::V8TestOverloadedConstructors::constructor3Callback):
3144         (WebCore::V8TestOverloadedConstructors::constructor4Callback):
3145         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
3146         (WebCore::V8TestSerializedScriptValueInterface::constructorCallback):
3147         * bindings/scripts/test/V8/V8TestTypedefs.cpp:
3148         (WebCore::TestTypedefsV8Internal::funcCallback):
3149         (WebCore::TestTypedefsV8Internal::setShadowCallback):
3150         (WebCore::TestTypedefsV8Internal::methodWithSequenceArgCallback):
3151         (WebCore::TestTypedefsV8Internal::nullableArrayArgCallback):
3152         (WebCore::TestTypedefsV8Internal::stringArrayFunctionCallback):
3153         (WebCore::TestTypedefsV8Internal::stringArrayFunction2Callback):
3154         (WebCore::V8TestTypedefs::constructorCallback):
3155         * bindings/v8/V8BindingMacros.h:
3156         (WebCore):
3157         * bindings/v8/custom/V8HistoryCustom.cpp:
3158         (WebCore::V8History::pushStateCallbackCustom):
3159         (WebCore::V8History::replaceStateCallbackCustom):
3160
3161 2013-02-19  Kentaro Hara  <haraken@chromium.org>
3162
3163         [JSC] MAYBE_MISSING_PARAMETER(..., DefaultIsNullString) macro is redundant
3164         https://bugs.webkit.org/show_bug.cgi?id=109902
3165
3166         Reviewed by Adam Barth.
3167
3168         Currently:
3169
3170         - MAYBE_MISSING_PARAMETER(exec, index, DefaultIsUndefined)
3171           returns exec->argument(index).
3172         - MAYBE_MISSING_PARAMETER(exec, index, DefaultIsNullString)
3173           returns JSValue() if exec->argument(index) is missing
3174           (i.e. the length of the argument is less than index).
3175           It returns exec->argument(index) otherwise.
3176
3177         No one other than CodeGeneratorJS.pm uses
3178         MAYBE_MISSING_PARAMETER(exec, index, DefaultIsUndefined).
3179         Instead, we simply use exec->argument(index). We should remove
3180         the redundant usage in CodeGeneratorJS.pm too. The long-name macro
3181         has been making generated code less readable.
3182
3183         In addition, we can rename MAYBE_MISSING_PARAMETER() to argumentOrNull().
3184
3185         c.f. corresponding V8 bug: https://bugs.webkit.org/show_bug.cgi?id=109899
3186
3187         No tests. No change in behavior.
3188
3189         * bindings/js/JSDOMBinding.h:
3190         (WebCore):
3191         * bindings/scripts/CodeGeneratorJS.pm:
3192         (GenerateParametersCheck):
3193         * bindings/scripts/test/JS/JSFloat64Array.cpp:
3194         (WebCore::jsFloat64ArrayPrototypeFunctionFoo):
3195         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
3196         (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
3197         (WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessage):
3198         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
3199         (WebCore::jsTestCustomNamedGetterPrototypeFunctionAnotherFunction):
3200         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
3201         (WebCore::jsTestEventTargetPrototypeFunctionItem):
3202         (WebCore::jsTestEventTargetPrototypeFunctionDispatchEvent):
3203         * bindings/scripts/test/JS/JSTestInterface.cpp:
3204         (WebCore::JSTestInterfaceConstructor::constructJSTestInterface):
3205         (WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
3206         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
3207         (WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):
3208         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
3209         (WebCore::JSTestNamedConstructorNamedConstructor::constructJSTestNamedConstructor):
3210         * bindings/scripts/test/JS/JSTestObj.cpp:
3211         (WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
3212         (WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
3213         (WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
3214         (WebCore::jsTestObjPrototypeFunctionMethodWithSequenceArg):
3215         (WebCore::jsTestObjPrototypeFunctionMethodReturningSequence):
3216         (WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
3217         (WebCore::jsTestObjPrototypeFunctionSerializedValue):
3218         (WebCore::jsTestObjPrototypeFunctionOptionsObject):
3219         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArg):
3220         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
3221         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
3222         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalString):
3223         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefined):
3224         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNullString):
3225         (WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
3226         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
3227         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
3228         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
3229         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
3230         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod6):
3231         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod7):
3232         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod8):
3233         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod9):
3234         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
3235         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod11):
3236         (WebCore::jsTestObjConstructorFunctionClassMethodWithOptional):
3237         (WebCore::jsTestObjConstructorFunctionOverloadedMethod11):
3238         (WebCore::jsTestObjConstructorFunctionOverloadedMethod12):
3239         (WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
3240         (WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
3241         (WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
3242         (WebCore::jsTestObjPrototypeFunctionConvert1):
3243         (WebCore::jsTestObjPrototypeFunctionConvert2):
3244         (WebCore::jsTestObjPrototypeFunctionConvert4):
3245         (WebCore::jsTestObjPrototypeFunctionConvert5):
3246         (WebCore::jsTestObjPrototypeFunctionStrictFunction):
3247         (WebCore::jsTestObjPrototypeFunctionVariadicStringMethod):
3248         (WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethod):
3249         (WebCore::jsTestObjPrototypeFunctionVariadicNodeMethod):
3250         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
3251         (WebCore::JSTestOverloadedConstructorsConstructor::constructJSTestOverloadedConstructors1):
3252         (WebCore::JSTestOverloadedConstructorsConstructor::constructJSTestOverloadedConstructors2):
3253         (WebCore::JSTestOverloadedConstructorsConstructor::constructJSTestOverloadedConstructors3):
3254         (WebCore::JSTestOverloadedConstructorsConstructor::constructJSTestOverloadedConstructors4):
3255         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
3256         (WebCore::JSTestSerializedScriptValueInterfaceConstructor::constructJSTestSerializedScriptValueInterface):
3257         (WebCore::jsTestSerializedScriptValueInterfacePrototypeFunctionAcceptTransferList):
3258         (WebCore::jsTestSerializedScriptValueInterfacePrototypeFunctionMultiTransferList):
3259         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
3260         (WebCore::JSTestTypedefsConstructor::constructJSTestTypedefs):
3261         (WebCore::jsTestTypedefsPrototypeFunctionFunc):
3262         (WebCore::jsTestTypedefsPrototypeFunctionMultiTransferList):
3263         (WebCore::jsTestTypedefsPrototypeFunctionSetShadow):
3264         (WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
3265         (WebCore::jsTestTypedefsPrototypeFunctionNullableArrayArg):
3266         (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction):
3267         (WebCore::jsTestTypedefsPrototypeFunctionStringArrayFunction2):
3268
3269 2013-02-18  Hayato Ito  <hayato@chromium.org>
3270
3271         Make EventDispatcher take an Event object in its constructor.
3272         https://bugs.webkit.org/show_bug.cgi?id=109898
3273
3274         Reviewed by Dimitri Glazkov.
3275
3276         Re-landing r143145, which caused a crash when deltaX and deltaY of a PlatformWheelEvent are both zero.
3277
3278         Fixed a crash by early exiting in EventDispatcher::dispatchEvent(Node*, PassRefPtr<EventDispatcher*>)
3279         if mediator's event() returns null.
3280
3281         Also Added a layout test to catch this kind of crash in the future.
3282
3283         Test: fast/events/platform-wheelevent-with-delta-zero-crash.html
3284
3285         * dom/EventDispatchMediator.cpp:
3286         (WebCore::EventDispatchMediator::dispatchEvent):
3287         * dom/EventDispatcher.cpp:
3288         (WebCore::EventDispatcher::dispatchEvent):
3289         (WebCore::EventDispatcher::EventDispatcher):
3290         (WebCore::EventDispatcher::ensureEventPath):
3291         (WebCore::EventDispatcher::dispatchSimulatedClick):
3292         (WebCore::EventDispatcher::dispatch):
3293         (WebCore::EventDispatcher::dispatchEventPreProcess):
3294         (WebCore::EventDispatcher::dispatchEventAtCapturing):
3295         (WebCore::EventDispatcher::dispatchEventAtTarget):
3296         (WebCore::EventDispatcher::dispatchEventAtBubbling):
3297         (WebCore::EventDispatcher::dispatchEventPostProcess):
3298         * dom/EventDispatcher.h:
3299         (EventDispatcher):
3300         (WebCore::EventDispatcher::node):
3301         (WebCore::EventDispatcher::event):
3302         * dom/FocusEvent.cpp:
3303         (WebCore::FocusEventDispatchMediator::dispatchEvent):
3304         (WebCore::BlurEventDispatchMediator::dispatchEvent):
3305         (WebCore::FocusInEventDispatchMediator::dispatchEvent):
3306         (WebCore::FocusOutEventDispatchMediator::dispatchEvent):
3307         * dom/GestureEvent.cpp:
3308         (WebCore::GestureEventDispatchMediator::dispatchEvent):
3309         * dom/MouseEvent.cpp:
3310         (WebCore::MouseEventDispatchMediator::dispatchEvent):
3311         * dom/WheelEvent.cpp:
3312         (WebCore::WheelEventDispatchMediator::dispatchEvent):
3313         Assert event() rather than an early exit since this code path should be hit only when event() is non-null.
3314
3315 2013-02-18  Takashi Sakamoto  <tasak@google.com>
3316
3317         :before/:after pseudo elements do not always apply to the proper element
3318         https://bugs.webkit.org/show_bug.cgi?id=93925
3319
3320         Reviewed by Dimitri Glazkov.
3321
3322         Disable sharing a style with siblings if :after or :before pseudo style
3323         is unique.
3324
3325         Test: fast/css/before-after-pseudo-class.html
3326
3327         * css/StyleResolver.cpp:
3328         (WebCore::StyleResolver::canShareStyleWithElement):
3329         Added a new condition, hasUniquePseudoStyle.
3330         * rendering/style/RenderStyle.cpp:
3331         (WebCore::RenderStyle::hasUniquePseudoStyle):
3332         Added to check whether any pseudo style has unique bit or not.
3333         (WebCore):
3334         * rendering/style/RenderStyle.h:
3335
3336 2013-02-18  Andy Estes  <aestes@apple.com>
3337
3338         Focusing a new frame (via window.focus()) should blur the active element in the current frame
3339         https://bugs.webkit.org/show_bug.cgi?id=110172
3340
3341         Reviewed by Ryosuke Niwa.
3342
3343         When a change in the focused node crosses a frame boundary, WebKit
3344         doesn't always succeed in blurring the old focused node before focusing
3345         the new one.
3346
3347         Each document remembers its focused node, and a Page-scoped
3348         FocusController remembers the focused frame. If a new focused node is
3349         in a different frame than the focused frame, FocusController tells the
3350         old frame's document to clear its focused node before focusing the new
3351         one (and remembering the new frame).
3352
3353         Unfortunately, web content can confuse FocusController by calling
3354         window.focus() at the wrong time. Since window.focus() changes
3355         FocusController's focused frame without focusing a new node,
3356         FocusController won't think that a frame boundary is being crossed if a
3357         node in this frame is later focused. Therefore it won't clear the old
3358         frame's focused node (it won't even know which frame contained the old
3359         focused node), causing at least two bugs:
3360
3361         1) The node in the old frame will not receive a blur event.
3362         2) Calling document.activeElement on the main frame will return the
3363            previously focused node, but the HTML5 spec says it should return
3364            the frame owner element if a subframe has focus.
3365
3366         Fix both of these bugs by explicitly clearing the current frame's
3367         focused node if window.focus() changes the focused frame. This fix
3368         carries some compatibility risk by changing a long-standing behavior
3369         of the engine (we've had this bug since the beginning of the project,
3370         AFAICT). On the upside, it matches the behavior of both Firefox and IE,
3371         matches what HTML5 says about subframe focus, and fixes at least one
3372         well-known enterprise web app.
3373
3374         Tests: fast/dom/HTMLDocument/active-element-frames.html
3375                fast/frames/frame-focus-blurs-active-element.html
3376
3377         * page/DOMWindow.cpp:
3378         (WebCore::DOMWindow::focus): If the frame being focused is not the same
3379         as the currently focused frame, clear the currently focused frame's
3380         focused node.
3381
3382 2013-02-18  Simon Fraser  <simon.fraser@apple.com>
3383
3384         Clean up the boolean argument to visibleContentRect
3385         https://bugs.webkit.org/show_bug.cgi?id=110167
3386
3387         Reviewed by Simon Fraser.
3388
3389         Replace the boolean argument to visibleContentRect() with
3390         an enum.
3391
3392         No behavior change.
3393
3394         * WebCore.exp.in:
3395         * dom/Document.cpp:
3396         (WebCore::Document::viewportSize):
3397         * inspector/InspectorOverlay.cpp:
3398         (WebCore::InspectorOverlay::update):
3399         * page/DOMWindow.cpp:
3400         (WebCore::DOMWindow::innerHeight):
3401         (WebCore::DOMWindow::innerWidth):
3402         * page/FrameView.cpp:
3403         (WebCore::FrameView::calculateScrollbarModesForLayout):
3404         (WebCore::FrameView::layout):
3405         (WebCore::FrameView::performPostLayoutTasks):
3406         (WebCore::FrameView::windowClipRect):
3407         * page/SpatialNavigation.cpp:
3408         (WebCore::canScrollInDirection):
3409         * platform/ScrollView.cpp:
3410         (WebCore::ScrollView::unscaledVisibleContentSize):
3411         (WebCore::ScrollView::visibleContentRect):
3412         (WebCore::ScrollView::layoutSize):
3413         (WebCore::ScrollView::updateScrollbars):
3414         (WebCore::ScrollView::paint):
3415         * platform/ScrollView.h:
3416         * platform/ScrollableArea.cpp:
3417         (WebCore::ScrollableArea::visibleContentRect):
3418         * platform/ScrollableArea.h:
3419         * rendering/RenderDialog.cpp:
3420         (WebCore::RenderDialog::layout):
3421         * rendering/RenderLayer.cpp:
3422         (WebCore::RenderLayer::maximumScrollPosition):
3423         (WebCore::RenderLayer::visibleContentRect):
3424         * rendering/RenderLayer.h:
3425         * rendering/RenderLayerCompositor.cpp:
3426         (WebCore::RenderLayerCompositor::frameViewDidChangeSize):
3427         (WebCore::RenderLayerCompositor::updateRootLayerPosition):
3428
3429 2013-02-18  Ryosuke Niwa  <rniwa@webkit.org>
3430
3431         That didn't work either. Just make it public. This is why I hate nested classes. They just don't work.
3432
3433         * rendering/RenderBlock.h:
3434         (RenderBlock):
3435
3436 2013-02-18  Ryosuke Niwa  <rniwa@webkit.org>
3437
3438         Windows build fix. Apparently Visual Studio still has a lot of bugs with respect to nested classes.
3439         Work around