Fix crash due to unexpected Node deletion during MutationObserver registration book...
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2013-07-26  Ryosuke Niwa  <rniwa@webkit.org>
2
3         Fix crash due to unexpected Node deletion during MutationObserver registration book-keeping
4         https://bugs.webkit.org/show_bug.cgi?id=119124
5
6         Reviewed by Sam Weinig.
7
8         Merge https://chromium.googlesource.com/chromium/blink/+/b6afb927695b3acf2c75c25f05e99682660993e2
9
10         No new tests since I could not reproduce the crash with the test attached in the Blink change.
11
12         The bug was caused by Node::unregisterMutationObserver removing the MutationObserverRegistration
13         that holds the last ref to the node. Avoid that by explicitly allocating a local RefPtr to the node
14         in MutationObserverRegistration::unregister. Also rename it to unregisterAndDelete to clarify
15         the semantics and make it a static member function to be even safer.
16
17         * dom/MutationObserver.cpp:
18         (WebCore::MutationObserver::disconnect):
19         * dom/MutationObserverRegistration.cpp:
20         (WebCore::MutationObserverRegistration::unregisterAndDelete):
21         * dom/MutationObserverRegistration.h:
22
23 2013-07-29  Alex Christensen  <achristensen@apple.com>
24
25         Moved GLTransportSurface.h and .cpp out of efl-specific directory.
26         https://bugs.webkit.org/show_bug.cgi?id=119163
27
28         Reviewed by Alexis Menard.
29
30         * PlatformEfl.cmake: Changed directory of GLTransportSurface.cpp.
31         * platform/graphics/surfaces/GLTransportSurface.cpp: Copied from WebCore/platform/graphics/surfaces/efl/GLTransportSurface.cpp.
32         * platform/graphics/surfaces/GLTransportSurface.h: Copied from WebCore/platform/graphics/surfaces/efl/GLTransportSurface.h.
33         * platform/graphics/surfaces/efl/GLTransportSurface.cpp: Removed.
34         * platform/graphics/surfaces/efl/GLTransportSurface.h: Removed.
35
36 2013-07-29  Alex Christensen  <achristensen@apple.com>
37
38         Speculative implementation of missing GraphicsContext3D methods on Windows.
39         https://bugs.webkit.org/show_bug.cgi?id=119167
40
41         Reviewed by Dean Jackson.
42
43         * WebCore.vcxproj/WebCore.vcxproj:
44         * WebCore.vcxproj/WebCore.vcxproj.filters:
45         * platform/graphics/win/GraphicsContext3DWin.cpp: Added.
46         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
47         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
48         (WebCore::GraphicsContext3D::create):
49         (WebCore::GraphicsContext3D::GraphicsContext3D):
50         (WebCore::GraphicsContext3D::~GraphicsContext3D):
51         (WebCore::GraphicsContext3D::setContextLostCallback):
52         (WebCore::GraphicsContext3D::setErrorMessageCallback):
53         (WebCore::GraphicsContext3D::makeContextCurrent):
54         (WebCore::GraphicsContext3D::platformGraphicsContext3D):
55         (WebCore::GraphicsContext3D::platformTexture):
56         (WebCore::GraphicsContext3D::isGLES2Compliant):
57         (WebCore::GraphicsContext3D::platformLayer):
58
59 2013-07-29  Dean Jackson  <dino@apple.com>
60
61         Max IOSurfaceDimension should be an inclusive upper bound
62         https://bugs.webkit.org/show_bug.cgi?id=119206
63         <rdar://problem/14555311>
64
65         Reviewed by Simon Fraser.
66
67         The maxIOSurfaceDimension value should be an inclusive upper bound.
68         Change the greater than or equal to into a greater than. This will
69         allow canvas elements of this dimension to be accelerated.
70
71         * platform/graphics/cg/ImageBufferCG.cpp:
72         (WebCore::ImageBuffer::ImageBuffer): Change >= to >
73
74 2013-07-29  Renata Hodovan  <reni@webkit.org>
75
76         ASSERT_NOT_REACHED was touched in WebCore::SVGAnimatedType::valueAsString
77         https://bugs.webkit.org/show_bug.cgi?id=118744
78
79         Reviewed by Philip Rogers.
80
81         If we have an <animateTransform> tag that sets the attributeName and attributeType
82         properties however they are not consistent and we shouldn't try to apply it.
83         It is already checked and catched in SVGAnimateElement::resetAnimatedType() but
84         DontApplyAnimation case isn't handled properly. The patch forces an early return
85         in this case.
86
87         Test: svg/animations/attributeNameAndAttributeTypeMissmatch.svg
88
89         * svg/SVGAnimateElement.cpp:
90         (WebCore::SVGAnimateElement::resetAnimatedType):
91
92 2013-07-29  Allan Sandfeld Jensen  <allan.jensen@digia.com>
93
94         REGRESSION(148300) GIFs not reanimated after resumeActiveDOMObjectAndAnimations
95         https://bugs.webkit.org/show_bug.cgi?id=119217
96
97         Reviewed by Tim Horton.
98
99         Commit 148300 introduced a new better was of restarting GIF animations after
100         they have been suspended. Unfortunately the method was not activated when a page
101         is resumed but only when it is returning from background.
102
103         This fixes GIF animations that are stopped during user interaction on Qt and other
104         platforms using suspendActiveDOMObjectAndAnimations.
105
106         * page/Frame.cpp:
107         (WebCore::Frame::resumeActiveDOMObjectsAndAnimations):
108
109 2013-07-29  Alex Christensen  <achristensen@apple.com>
110
111         Made EGL useable by non-cairo ports.
112         https://bugs.webkit.org/show_bug.cgi?id=119177
113
114         Reviewed by Brent Fulgham.
115
116         * platform/graphics/cairo/GLContext.h:
117         * platform/graphics/egl/GLContextEGL.cpp:
118         (WebCore::GLContextEGL::GLContextEGL):
119         * platform/graphics/egl/GLContextEGL.h:
120         Protected Cairo-specific code with #if USE(CAIRO)
121
122 2013-07-29  Sergio Correia  <sergio.correia@openbossa.org>
123
124         CoordinatedGraphics: Add API to get and set the active state of a WebView
125         https://bugs.webkit.org/show_bug.cgi?id=119067
126
127         Reviewed by Noam Rosenthal.
128
129         Added a method to return whether a scene is active or not.
130
131         No new tests, no behavior change.
132
133         * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
134         (WebCore::CoordinatedGraphicsScene::isActive): Added method to return the
135         active state of the scene.
136
137 2013-07-29  Mario Sanchez Prada  <mario.prada@samsung.com>
138
139         [ATK] Issues with edge cases when getting offsets for a text range in AtkText
140         https://bugs.webkit.org/show_bug.cgi?id=118908
141
142         Reviewed by Martin Robinson.
143
144         Reimplement getSelectionOffsetsForObject() just in term of
145         Positions instead of using ranges, which makes it simpler and
146         works better. Also, make sure we use the right Node as reference
147         for the accessibility object by getting the proper one both for
148         text control objects (e.g. input, text area) and normal ones.
149
150         * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
151         (getNodeForAccessibilityObject): New helper function to ensure we
152         always get the relevant object from the DOM tree for a given
153         accessibility object, in the context of the implementation of
154         AtkText, so it works both with Text Controls and other elements.
155         (getSelectionOffsetsForObject): Rewritten this function in terms
156         of VisiblePositions and avoiding weird operations with ranges, so
157         we have more control to fine tune the results and give more
158         accurate ones. Besides, now it works better with edge cases.
159
160 2013-07-29  Zan Dobersek  <zdobersek@igalia.com>
161
162         Clean up DragImage
163         https://bugs.webkit.org/show_bug.cgi?id=118981
164
165         Reviewed by Anders Carlsson.
166
167         * dom/Clipboard.h: Add forward declaration for the Range class. This was not necessary until now as the forward
168         declaration was introduced in the DragImage header, from where it's being removed due to not being required in that class.
169         * page/Frame.h: Ditto.
170         * platform/DragImage.cpp: Remove the unnecessary DragController and FontRenderingMode header inclusions.
171         The latter is already included in the header.
172         * platform/DragImage.h: Remove the forward declaration for the Range class - it's not used by the DragImage class at all.
173
174 2013-07-29  Kwang Yul Seo  <skyul@company100.net>
175
176         [EFL] Improve string use in ErrorsEfl
177         https://bugs.webkit.org/show_bug.cgi?id=119207
178
179         Reviewed by Christophe Dumez.
180
181         Use ASCIILiteral for constant strings becoming WTFStrings.
182
183         No behavior change.
184
185         * platform/efl/ErrorsEfl.cpp:
186         (WebCore::cancelledError):
187         (WebCore::blockedError):
188         (WebCore::cannotShowURLError):
189         (WebCore::interruptedForPolicyChangeError):
190         (WebCore::cannotShowMIMETypeError):
191         (WebCore::fileDoesNotExistError):
192         (WebCore::pluginWillHandleLoadError):
193         (WebCore::downloadCancelledByUserError):
194         (WebCore::printerNotFoundError):
195         (WebCore::invalidPageRangeToPrint):
196
197 2013-07-28  Andreas Kling  <akling@apple.com>
198
199         Don't update the text track override CSS every time a media element is created.
200         <http://webkit.org/b/119199>
201         <rdar://problem/14572855>
202
203         Reviewed by Darin Adler.
204
205         We should only have to update the CSS if the accessibility caption preferences are changed.
206         This was forcing a full style recalc in every Document any time a media element is instantiated.
207
208         * page/CaptionUserPreferencesMediaAF.cpp:
209         (WebCore::CaptionUserPreferencesMediaAF::setInterestedInCaptionPreferenceChanges):
210
211 2013-07-28  Andy Estes  <aestes@apple.com>
212
213         Stop exporting Widget::frameRectsChanged()
214         https://bugs.webkit.org/show_bug.cgi?id=119196
215
216         Reviewed by Darin Adler.
217
218         The definition is inlined in a private header, so there's no need to
219         export a symbol to link against. On the Mac, since we compile with
220         -fvisibility-inlines-hidden, removing the symbol from the export file
221         silences an ld warning about exporting a hidden symbol.
222
223         * WebCore.exp.in: Removed __ZN7WebCore6Widget17frameRectsChangedEv.
224
225 2013-07-28  Sam Weinig  <sam@webkit.org>
226
227         Clean up CSSPrimitiveValue::equals a bit
228         https://bugs.webkit.org/show_bug.cgi?id=119195
229
230         Reviewed by Andreas Kling.
231
232         * css/CSSPrimitiveValue.cpp:
233         (WebCore::CSSPrimitiveValue::equals):
234         This should not change behavior, but is quite a bit clearer.
235
236 2013-07-27  Ryuan Choi  <ryuan.choi@samsung.com>
237
238         [EFL] Bump required version of EFL to 1.7
239         https://bugs.webkit.org/show_bug.cgi?id=119144
240
241         Reviewed by Christophe Dumez.
242
243         * platform/efl/FileSystemEfl.cpp: Removed workaround code which was fixed at Eina 1.7
244         (WebCore::listDirectory):
245
246 2013-07-27  Jacky Jiang  <zhajiang@blackberry.com>
247
248         Replace all uses of GraphicsLayer::create function with the one that takes a GraphicsLayerFactory
249         https://bugs.webkit.org/show_bug.cgi?id=119186
250
251         Reviewed by Anders Carlsson.
252
253         Remove GraphicsLayer::create(GraphicsLayerClient*) function since it's
254         been deprecated by r130072.
255
256         * WebCore.exp.in:
257         * WebCore.order:
258         * platform/graphics/GraphicsLayer.h:
259         * platform/graphics/blackberry/GraphicsLayerBlackBerry.cpp:
260         * platform/graphics/ca/GraphicsLayerCA.cpp:
261         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
262
263 2013-07-27  Alexey Proskuryakov  <ap@apple.com>
264
265         HTMLParserScheduler gets into an inconsistent state when suspended for reasons
266         other than WillDeferLoading
267         https://bugs.webkit.org/show_bug.cgi?id=119172
268
269         Reviewed by Sam Weinig.
270
271         When loading is not deferred, even a suspended parser will be processing new data
272         from network, potentially starting its next chunk timer.
273
274         Limit suspending to when we can actually enforce it.
275
276         Here is what happens for each ReasonForSuspension:
277         - JavaScriptDebuggerPaused: continuing to parse is probably wrong, but in practice,
278         this is unlikely to happen while debugging, and wasn't properly prevented before
279         this patch anyway.
280         - WillDeferLoading: No change in behavior.
281         - DocumentWillBecomeInactive: This is about page cache, and documents are only allowed
282         to be cached when fully loaded.
283         - PageWillBeSuspended: This appears to be part of Frame::suspendActiveDOMObjectsAndAnimations()
284         implementation, I'm guessing that it is appropriate to continue loading.
285
286         * dom/Document.cpp:
287         (WebCore::Document::suspendScheduledTasks):
288         (WebCore::Document::resumeScheduledTasks):
289         Only suspend/resume parsing when loading is deferred. This is not expressed directly,
290         but it's important to do this to avoid executing JS behind alerts and other modal dialogs.
291
292         * html/parser/HTMLParserScheduler.h: Added m_suspended member variable for assertions.
293
294         * html/parser/HTMLParserScheduler.cpp:
295         (WebCore::HTMLParserScheduler::HTMLParserScheduler):
296         (WebCore::HTMLParserScheduler::continueNextChunkTimerFired):
297         (WebCore::HTMLParserScheduler::scheduleForResume):
298         (WebCore::HTMLParserScheduler::suspend):
299         (WebCore::HTMLParserScheduler::resume):
300         Update m_suspended and assert as appropriate. No behavior changes for release mode.
301
302         * page/Frame.cpp: (WebCore::Frame::suspendActiveDOMObjectsAndAnimations):
303         Added a FIXME.
304
305 2013-07-27  Alexey Proskuryakov  <ap@apple.com>
306
307         Make SuspendableTimer safer
308         https://bugs.webkit.org/show_bug.cgi?id=119127
309
310         Reviewed by Sam Weinig.
311
312         SuspendableTimer now enforces that it stays suspended until resumed (or until stopped
313         and started again). To ensure this, TimerBase is now a private base class, and parts of
314         its interface that clients use are reimplemented with suspend/resume in mind.
315
316         Derived classes are still allowed to override TimerBase virtual functions (notably
317         fired() and alignedFireTime()).
318
319         * dom/DocumentEventQueue.cpp:
320         (WebCore::DocumentEventQueueTimer): Removed an extraneous WTF_MAKE_NONCOPYABLE,
321         TimerBase has it already.
322         (WebCore::DocumentEventQueueTimer::create): Use our normal create() pattern.
323         (WebCore::DocumentEventQueue::DocumentEventQueue): Made the constructor private, accordingly.
324         (WebCore::DocumentEventQueue::cancelEvent): Use SuspendableTimer::cancel(), which
325         is a new name to disambiguate TimerBase::stop() and ActiveDOMObject::stop().
326         (WebCore::DocumentEventQueue::close): Ditto.
327
328         * page/DOMTimer.cpp:
329         (WebCore::DOMTimer::fired): Now that SuspendableTimer knows whether it's currently
330         suspended, assert that it's not.
331         (WebCore::DOMTimer::didStop): Separated ActiveDOMObject::stop() implementation from
332         additional cleanup, allowing for better SuspendableTimer encapsulation.
333
334         * page/DOMTimer.h: Added FINAL and OVVERIDE specifiers as appropriate.
335
336         * page/SuspendableTimer.h: Added FINAL (and OVERRIDE) qualifiers to ActiveDOMObject
337         methods. A derived class that wants to override current behavior is most likely not
338         a timer, and thus shouldn't be a derived class.
339         (WebCore::SuspendableTimer::isActive): SuspendableTimer with a next fire time is
340         active even if suspended, we shouldn't overwrite its saved data thinking that it's
341         inactive.
342         (WebCore::SuspendableTimer::isSuspended): Exposed to clients (m_suspended is no
343         longer debug only).
344
345         * page/SuspendableTimer.cpp:
346         (WebCore::SuspendableTimer::SuspendableTimer): Updated for new variable names.
347         (WebCore::SuspendableTimer::stop): This is ActiveDOMObject::stop(), which is called
348         before final destruction. We don't track this state directly, but can approximate
349         with setting m_suspended, so even if someone tries to start the timer afterwards,
350         it won't fire.
351         (WebCore::SuspendableTimer::suspend): Updated for new names.
352         (WebCore::SuspendableTimer::resume): Ditto.
353         (WebCore::SuspendableTimer::didStop): No-op default implementation for client hook.
354         (WebCore::SuspendableTimer::cancel): Equivalent of TimerBase::stop(), which also
355         works when suspended. 
356         (WebCore::SuspendableTimer::startRepeating): Replacement for TimerBase function with
357         the same name, which works correctly when suspended. We don't want to actually start
358         the timer in this case.
359         (WebCore::SuspendableTimer::startOneShot): Ditto.
360         (WebCore::SuspendableTimer::repeatInterval): Ditto.
361         (WebCore::SuspendableTimer::augmentFireInterval): Ditto.
362         (WebCore::SuspendableTimer::augmentRepeatInterval): Ditto.
363
364 2013-07-27  Sam Weinig  <sam@webkit.org>
365
366         Add assertions for CSSPrimitiveValue's m_value.valueID accessor
367         https://bugs.webkit.org/show_bug.cgi?id=119180
368
369         Reviewed by Andreas Kling.
370
371         * css/CSSPrimitiveValueMappings.h:
372         (WebCore::CSSPrimitiveValue::operator CSSReflectionDirection):
373         (WebCore::CSSPrimitiveValue::operator ColumnSpan):
374         (WebCore::CSSPrimitiveValue::operator PrintColorAdjust):
375         (WebCore::CSSPrimitiveValue::operator EBorderStyle):
376         (WebCore::CSSPrimitiveValue::operator OutlineIsAuto):
377         (WebCore::CSSPrimitiveValue::operator CompositeOperator):
378         (WebCore::CSSPrimitiveValue::operator ControlPart):
379         (WebCore::CSSPrimitiveValue::operator EBackfaceVisibility):
380         (WebCore::CSSPrimitiveValue::operator EFillAttachment):
381         (WebCore::CSSPrimitiveValue::operator EFillBox):
382         (WebCore::CSSPrimitiveValue::operator EFillRepeat):
383         (WebCore::CSSPrimitiveValue::operator EBoxPack):
384         (WebCore::CSSPrimitiveValue::operator EBoxAlignment):
385         (WebCore::CSSPrimitiveValue::operator EBoxDecorationBreak):
386         (WebCore::CSSPrimitiveValue::operator BackgroundEdgeOrigin):
387         (WebCore::CSSPrimitiveValue::operator EBoxSizing):
388         (WebCore::CSSPrimitiveValue::operator EBoxDirection):
389         (WebCore::CSSPrimitiveValue::operator EBoxLines):
390         (WebCore::CSSPrimitiveValue::operator EBoxOrient):
391         (WebCore::CSSPrimitiveValue::operator ECaptionSide):
392         (WebCore::CSSPrimitiveValue::operator EClear):
393         (WebCore::CSSPrimitiveValue::operator ECursor):
394         (WebCore::CSSPrimitiveValue::operator CursorVisibility):
395         (WebCore::CSSPrimitiveValue::operator EDisplay):
396         (WebCore::CSSPrimitiveValue::operator EEmptyCell):
397         (WebCore::CSSPrimitiveValue::operator EAlignItems):
398         (WebCore::CSSPrimitiveValue::operator EJustifyContent):
399         (WebCore::CSSPrimitiveValue::operator EFlexDirection):
400         (WebCore::CSSPrimitiveValue::operator EAlignContent):
401         (WebCore::CSSPrimitiveValue::operator EFlexWrap):
402         (WebCore::CSSPrimitiveValue::operator EFloat):
403         (WebCore::CSSPrimitiveValue::operator LineBreak):
404         (WebCore::CSSPrimitiveValue::operator EListStylePosition):
405         (WebCore::CSSPrimitiveValue::operator EListStyleType):
406         (WebCore::CSSPrimitiveValue::operator EMarginCollapse):
407         (WebCore::CSSPrimitiveValue::operator EMarqueeBehavior):
408         (WebCore::CSSPrimitiveValue::operator RegionFragment):
409         (WebCore::CSSPrimitiveValue::operator EMarqueeDirection):
410         (WebCore::CSSPrimitiveValue::operator ENBSPMode):
411         (WebCore::CSSPrimitiveValue::operator EOverflow):
412         (WebCore::CSSPrimitiveValue::operator EPageBreak):
413         (WebCore::CSSPrimitiveValue::operator EPosition):
414         (WebCore::CSSPrimitiveValue::operator EResize):
415         (WebCore::CSSPrimitiveValue::operator ETableLayout):
416         (WebCore::CSSPrimitiveValue::operator ETextAlign):
417         (WebCore::CSSPrimitiveValue::operator TextAlignLast):
418         (WebCore::CSSPrimitiveValue::operator TextJustify):
419         (WebCore::CSSPrimitiveValue::operator TextDecoration):
420         (WebCore::CSSPrimitiveValue::operator TextDecorationStyle):
421         (WebCore::CSSPrimitiveValue::operator TextUnderlinePosition):
422         (WebCore::CSSPrimitiveValue::operator ETextSecurity):
423         (WebCore::CSSPrimitiveValue::operator ETextTransform):
424         (WebCore::CSSPrimitiveValue::operator EUnicodeBidi):
425         (WebCore::CSSPrimitiveValue::operator EUserDrag):
426         (WebCore::CSSPrimitiveValue::operator EUserModify):
427         (WebCore::CSSPrimitiveValue::operator EUserSelect):
428         (WebCore::CSSPrimitiveValue::operator EVerticalAlign):
429         (WebCore::CSSPrimitiveValue::operator EVisibility):
430         (WebCore::CSSPrimitiveValue::operator EWhiteSpace):
431         (WebCore::CSSPrimitiveValue::operator EWordBreak):
432         (WebCore::CSSPrimitiveValue::operator EOverflowWrap):
433         (WebCore::CSSPrimitiveValue::operator TextDirection):
434         (WebCore::CSSPrimitiveValue::operator WritingMode):
435         (WebCore::CSSPrimitiveValue::operator TextCombine):
436         (WebCore::CSSPrimitiveValue::operator RubyPosition):
437         (WebCore::CSSPrimitiveValue::operator TextEmphasisPosition):
438         (WebCore::CSSPrimitiveValue::operator TextOverflow):
439         (WebCore::CSSPrimitiveValue::operator TextEmphasisFill):
440         (WebCore::CSSPrimitiveValue::operator TextEmphasisMark):
441         (WebCore::CSSPrimitiveValue::operator TextOrientation):
442         (WebCore::CSSPrimitiveValue::operator EPointerEvents):
443         (WebCore::CSSPrimitiveValue::operator FontDescription::Kerning):
444         (WebCore::CSSPrimitiveValue::operator FontSmoothingMode):
445         (WebCore::CSSPrimitiveValue::operator FontWeight):
446         (WebCore::CSSPrimitiveValue::operator FontItalic):
447         (WebCore::CSSPrimitiveValue::operator FontSmallCaps):
448         (WebCore::CSSPrimitiveValue::operator TextRenderingMode):
449         (WebCore::CSSPrimitiveValue::operator ColorSpace):
450         (WebCore::CSSPrimitiveValue::operator Hyphens):
451         (WebCore::CSSPrimitiveValue::operator LineSnap):
452         (WebCore::CSSPrimitiveValue::operator LineAlign):
453         (WebCore::CSSPrimitiveValue::operator Order):
454         (WebCore::CSSPrimitiveValue::operator ESpeak):
455         (WebCore::CSSPrimitiveValue::operator BlendMode):
456         (WebCore::CSSPrimitiveValue::operator LineCap):
457         (WebCore::CSSPrimitiveValue::operator LineJoin):
458         (WebCore::CSSPrimitiveValue::operator WindRule):
459         (WebCore::CSSPrimitiveValue::operator EAlignmentBaseline):
460         (WebCore::CSSPrimitiveValue::operator EBorderCollapse):
461         (WebCore::CSSPrimitiveValue::operator EBorderFit):
462         (WebCore::CSSPrimitiveValue::operator EImageRendering):
463         (WebCore::CSSPrimitiveValue::operator ETransformStyle3D):
464         (WebCore::CSSPrimitiveValue::operator ColumnAxis):
465         (WebCore::CSSPrimitiveValue::operator ColumnProgression):
466         (WebCore::CSSPrimitiveValue::operator WrapFlow):
467         (WebCore::CSSPrimitiveValue::operator WrapThrough):
468         (WebCore::CSSPrimitiveValue::operator GridAutoFlow):
469         (WebCore::CSSPrimitiveValue::operator EBufferedRendering):
470         (WebCore::CSSPrimitiveValue::operator EColorInterpolation):
471         (WebCore::CSSPrimitiveValue::operator EColorRendering):
472         (WebCore::CSSPrimitiveValue::operator EDominantBaseline):
473         (WebCore::CSSPrimitiveValue::operator EShapeRendering):
474         (WebCore::CSSPrimitiveValue::operator ETextAnchor):
475         (WebCore::CSSPrimitiveValue::operator SVGWritingMode):
476         (WebCore::CSSPrimitiveValue::operator EVectorEffect):
477         (WebCore::CSSPrimitiveValue::operator EMaskType):
478         Assert that the CSSPrimitiveValue is holding a CSSValueID before accessing it.
479
480 2013-07-26  Sam Weinig  <sam@webkit.org>
481
482         Stop pretending to support <string> for text-align.
483         https://bugs.webkit.org/show_bug.cgi?id=119107
484
485         Reviewed by Andreas Kling.
486
487         Test: fast/css/text-align-string-crash.html
488
489         * css/CSSParser.cpp:
490         (WebCore::CSSParser::parseValue):
491         Stop pretending to support <string> for text-align.
492
493         * css/DeprecatedStyleBuilder.cpp:
494         (WebCore::ApplyPropertyTextAlign::applyValue):
495         ASSERT that only value IDs get passed.
496
497 2013-07-26  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
498
499         Introduce toSVGRectElement(), use it
500         https://bugs.webkit.org/show_bug.cgi?id=119126
501
502         Reviewed by Andreas Kling.
503
504         As a step to change static_cast with toSVGXXX, static_cast<SVGRectElement*> can
505         be changed with toSVGRectElement().
506
507         No new tests, no behavior change.
508
509         * rendering/svg/RenderSVGRect.cpp:
510         (WebCore::RenderSVGRect::updateShapeFromElement):
511         * rendering/svg/SVGPathData.cpp:
512         (WebCore::updatePathFromRectElement):
513         * rendering/svg/SVGRenderTreeAsText.cpp:
514         (WebCore::operator<<):
515         * svg/SVGRectElement.h:
516         (WebCore::toSVGRectElement):
517
518 2013-07-26  Yongjun Zhang  <yongjun_zhang@apple.com>
519
520         With frame flattening on, too many resize events fired if document is resized in onresize handler.
521         https://bugs.webkit.org/show_bug.cgi?id=119075
522
523         Reviewed by Simon Fraser.
524
525         With http://trac.webkit.org/changeset/149287, WebCore also sends resize event in FrameView::setFrameRect.  When
526         flattening an iframe, setFrameRect could be called multiple times from RenderFrameBase::layoutWithFlattening and
527         we could get multiple resize events.  This patch adds a flag in FrameView to disallow sending resize events if
528         we are inside layoutWithFlattening.  The resize event will be sent in performPostLayoutTasks after the iframe
529         is done laying out.
530
531         Manually tested by verifying the rendering slowness in www.hi-pda.com is fixed when frame flattening is enabled.
532
533         * page/FrameView.cpp:
534         (WebCore::FrameView::FrameView):
535         (WebCore::FrameView::setFrameRect):
536         * page/FrameView.h:
537         (WebCore::FrameView::setResizeEventAllowed):
538         (WebCore::FrameView::resizeEventAllowed):
539         * rendering/RenderFrameBase.cpp:
540         (WebCore::RenderFrameBase::layoutWithFlattening):
541
542 2013-07-26  Dean Jackson  <dino@apple.com>
543
544         Allow new transitions to run even when controller is suspended
545         https://bugs.webkit.org/show_bug.cgi?id=119171
546         <rdar://problem/14511404>
547
548         Reviewed by Simon Fraser.
549
550         Expose a new property on AnimationController that allows newly created
551         animations to run even if the controller says it is suspended. See WebKit
552         ChangeLog for more details.
553
554         Test: transitions/created-while-suspended.html
555
556         * WebCore.exp.in: Export the new methods so WebView can use them.
557         * page/animation/AnimationController.cpp:
558         (WebCore::AnimationControllerPrivate::AnimationControllerPrivate): Initialize new flag to false.
559         (WebCore::AnimationControllerPrivate::startAnimationsIfNotSuspended): Check new flag is not true.
560         (WebCore::AnimationControllerPrivate::setAllowsNewAnimationsWhileSuspended): Expose setter.
561         (WebCore::AnimationController::allowsNewAnimationsWhileSuspended): "Public" getter.
562         (WebCore::AnimationController::setAllowsNewAnimationsWhileSuspended): "Public" setter.
563         * page/animation/AnimationController.h:
564         * page/animation/AnimationControllerPrivate.h:
565         (WebCore::AnimationControllerPrivate::allowsNewAnimationsWhileSuspended):
566         * page/animation/CompositeAnimation.cpp:
567         (WebCore::CompositeAnimation::CompositeAnimation): Only suspend if new flag is false. Everything else
568         relies on the m_suspended flag, so the real code change is this one line.
569
570 2013-07-26  Brent Fulgham  <bfulgham@apple.com>
571
572         [Windows] Unreviewed build fix.
573
574         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
575         (WebCore::createMetadataKeyNames): Do not include Media Selection
576         synbols when building without Media Selection API.
577
578 2013-07-26  Oliver Hunt  <oliver@apple.com>
579
580         REGRESSION(FTL?): Crashes in plugin tests
581         https://bugs.webkit.org/show_bug.cgi?id=119141
582
583         Reviewed by Michael Saboff.
584
585         Getting the correct semantics to appease the inspector is fairly
586         awful with the iterator system.  For the time being lets just revert
587         to requesting a full stack trace as we did in the past. 
588
589         * bindings/js/ScriptCallStackFactory.cpp:
590         (WebCore::createScriptCallStack):
591
592 2013-07-26  Brent Fulgham  <bfulgham@apple.com>
593
594         [Windows] Unreviewed build fix.
595
596         Correct build when targeting a release that does not have the AVCF
597         Legible Output infrastructure.
598
599         * platform/graphics/avfoundation/cf/AVFoundationCFSoftLinking.h: Exclude
600         a soft-link target when the API doesn't exist.
601         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
602         Correct include options for non-Legible Output supporting environments.
603         (WebCore::MediaPlayerPrivateAVFoundationCF::processLegacyClosedCaptionsTracks):
604         Prevent build failure when building with legacy caption support.
605
606 2013-07-26  Andreas Kling  <akling@apple.com>
607
608         Apply FINAL to the RenderObject hierarchy.
609         <http://webkit.org/b/115977>
610
611         Mostly from Blink r148795 by <cevans@chromium.org>
612         <http://src.chromium.org/viewvc/blink?view=revision&revision=148795>
613
614         * rendering/: Beat things with the FINAL stick.
615         * WebCore.exp.in: Export a now-needed symbol.
616
617 2013-07-26  Tim Horton  <timothy_horton@apple.com>
618
619         Add a mode where autosizing fixes the FrameView height to at least the WKView height
620         https://bugs.webkit.org/show_bug.cgi?id=119104
621         <rdar://problem/14549021>
622
623         Reviewed by Anders Carlsson.
624
625         * WebCore.exp.in: Export FrameView::setAutoSizeFixedMinimumHeight.
626         * page/FrameView.cpp:
627         (WebCore::FrameView::FrameView):
628         Initialize m_autoSizeFixedMinimumHeight to 0.
629
630         (WebCore::FrameView::autoSizeIfEnabled):
631         Increase the FrameView height to m_autoSizeFixedMinimumHeight if necessary,
632         and do another layout. Store the computed intrinsic content size.
633
634         (WebCore::FrameView::setAutoSizeFixedMinimumHeight): Added.
635
636         * page/FrameView.h:
637         (WebCore::FrameView::autoSizingIntrinsicContentSize): Added.
638
639 2013-07-26  Brent Fulgham  <bfulgham@apple.com>
640
641         [Windows] Remove workarounds now that rdar://problem/14390466 is fixed.
642         https://bugs.webkit.org/show_bug.cgi?id=119150
643
644         Reviewed by Anders Carlsson.
645
646         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
647         (WebCore::AVFWrapper::createPlayer): Remove workaround to add legible output
648         after player is created.
649         (WebCore::AVFWrapper::createPlayerItem): Remove workaround to delay adding
650         legible output until player is created.
651         (WebCore::AVFWrapper::platformLayer): Get rid of unused temporary.
652
653 2013-07-26  Brent Fulgham  <bfulgham@apple.com>
654
655         [Windows] Unreviewed gardening.
656
657         * WebCore.vcxproj/WebCore.vcxproj: Add missing header file to ease code viewing.
658         * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.
659
660 2013-07-26  Arvid Nilsson  <anilsson@rim.com>
661
662         [BlackBerry] LayerTiler fails to render layer after waking up
663         https://bugs.webkit.org/show_bug.cgi?id=119146
664
665         Reviewed by George Staikos.
666
667         When the application is backgrounded, all tiles are freed up to
668         release memory back to the system. We also mark the contents as dirty
669         in LayerTiler::deleteTextures() so tiles will be repopulated when
670         waking up again.
671
672         The problem was caused by an optimization to avoid re-rendering tiles
673         repeatedly until the UI thread catches up with the fact that we have
674         indeed rendered those tiles (which will happen when the UI thread next
675         composites a frame).
676
677         When contents are dirty, we're not supposed to perform this
678         optimization (i.e. we're not supposed to skip rendering) because the
679         appearance of the layer has changed, so we do need to render those
680         tiles. Unfortunately, the code that was supposed to forget the list of
681         tiles rendered was in a conditional, "if (frontVisibility)", which
682         happened to be false sometimes when the app woke up again. So we ended
683         up perpetually skipping those render jobs, and the UI thread kept
684         yelling at us to render them.
685
686         Fixed by unconditionally dropping the list of tiles rendered when
687         contents are dirty.
688
689         This can't be detected without pixel tests, which BB DRT currently
690         doesn't support.
691
692         JIRA 452460
693
694         * platform/graphics/blackberry/LayerTiler.cpp:
695         (WebCore::LayerVisibility::clearTilesRendered):
696         (WebCore::LayerTiler::updateTextureContentsIfNeeded):
697
698 2013-07-25  Ryosuke Niwa  <rniwa@webkit.org>
699
700         Remove unused HTMLTextFormControlElement::textRendererAfterUpdateLayout
701         https://bugs.webkit.org/show_bug.cgi?id=119121
702
703         Reviewed by Andreas Kling.
704
705         Merge https://chromium.googlesource.com/chromium/blink/+/3255ce725711707fe1fd18be91a6d06789517220.
706
707         * html/HTMLTextFormControlElement.cpp:
708         * html/HTMLTextFormControlElement.h:
709
710 2013-07-25  Ryosuke Niwa  <rniwa@webkit.org>
711
712         Fix document leak when selection is created inside the document
713         https://bugs.webkit.org/show_bug.cgi?id=119122
714
715         Reviewed by Andreas Kling.
716
717         Merge https://chromium.googlesource.com/chromium/blink/+/b908cb4c8da93316d787de31c93f2a43de332a10
718
719         The bug was caused by FrameSelection::m_previousCaretNode holding onto a Node, leaking its document.
720         Fixed the bug by explicitly clearing it in FrameSelection::prepareForDestruction.
721
722         Test: editing/selection/leak-document-with-selection-inside.html
723
724         * editing/FrameSelection.cpp:
725         (WebCore::FrameSelection::prepareForDestruction):
726
727 2013-07-25  Andreas Kling  <akling@apple.com>
728
729         ChromeClient::focusedNodeChanged() should be focusedElementChanged().
730         <http://webkit.org/b/119110>
731
732         Reviewed by Anders Carlsson.
733
734         Because only Elements can be focused.
735
736         * dom/Document.cpp:
737         (WebCore::Document::setFocusedElement):
738         * loader/EmptyClients.h:
739         (WebCore::EmptyChromeClient::focusedElementChanged):
740         * page/Chrome.cpp:
741         (WebCore::Chrome::focusedElementChanged):
742         * page/Chrome.h:
743         * page/ChromeClient.h:
744
745 2013-07-25  Kwang Yul Seo  <skyul@company100.net>
746
747         [WK2][Soup] Add private browsing support
748         https://bugs.webkit.org/show_bug.cgi?id=118657
749
750         Reviewed by Gustavo Noronha Silva.
751
752         Support private browsing by adding a method to create a private
753         browsing soup session. This private browsing session uses a
754         non-persistent cookie jar and does not use the disk cache feature.
755
756         No new tests. Covered by existing private browsing tests.
757
758         * platform/network/NetworkStorageSession.h:
759         (WebCore::NetworkStorageSession::isPrivateBrowsingSession):
760         Add USE(SOUP) guard to isPrivateBrowsingSession() and m_isPrivate.
761
762         * platform/network/ResourceHandle.h:
763         Add a factory method to create a private browsing session for soup.
764
765         * platform/network/soup/CookieJarSoup.cpp:
766         (WebCore::createPrivateBrowsingCookieJar):
767         * platform/network/soup/CookieJarSoup.h:
768         Add a method to create a non-persistent cookie jar for private browsing.
769
770         * platform/network/soup/NetworkStorageSessionSoup.cpp:
771         (WebCore::NetworkStorageSession::NetworkStorageSession):
772         Initialize m_isPrivate to false.
773         (WebCore::NetworkStorageSession::createPrivateBrowsingSession):
774         Implement the method by invoking ResourceHandle::createPrivateBrowsingSession.
775
776         * platform/network/soup/ResourceHandleSoup.cpp:
777         (WebCore::createSoupSession):
778         Extract common soup session creation code so that both defaultSession
779         and createPrivateBrowsingSession can use this function to create a soup
780         session.
781         (WebCore::ResourceHandle::defaultSession):
782         Change to use createSoupSession.
783         (WebCore::ResourceHandle::createPrivateBrowsingSession):
784         Create a session which uses a non-persistent cookie jar.
785
786 2013-07-25  Tim Horton  <timothy_horton@apple.com>
787
788         Null check m_frame in maximum and minimumScrollPosition
789         https://bugs.webkit.org/show_bug.cgi?id=119109
790         <rdar://problem/14545393>
791
792         Reviewed by Darin Adler.
793
794         * page/FrameView.cpp:
795         (WebCore::FrameView::minimumScrollPosition):
796         (WebCore::FrameView::maximumScrollPosition):
797         Null-check m_frame (and move the early-return after the clamp-to-0
798         as the revert in r152911 should have).
799
800 2013-07-25  Anders Carlsson  <andersca@apple.com>
801
802         Localizable.strings generated by extract-localizable-strings should be UTF-8
803         https://bugs.webkit.org/show_bug.cgi?id=119106
804
805         Reviewed by Mark Rowe.
806
807         * English.lproj/Localizable.strings:
808         Re-encode this as UTF-8 and remove the BOM.
809
810         * WebCore.xcodeproj/project.pbxproj:
811         Set the file encoding of Localizable.strings to UTF-8.
812
813 2013-07-25  Ryosuke Niwa  <rniwa@webkit.org>
814
815         Don't force layout when querying a fixed or non-box margin/padding property
816         https://bugs.webkit.org/show_bug.cgi?id=118032
817
818         Reviewed by David Hyatt.
819
820         Merge https://chromium.googlesource.com/chromium/blink/+/66427d0825fcc2975bd50220cdcaa2504d6f36e5.
821
822         This patch avoids layout in ComputedStyleExtractor::propertyValue for margin and padding properties
823         when they are of fixed length. According to the Blink patch's author, this improves the page load
824         time of economist.com by 27%.
825
826         The actual code change is significantly different from the original Blink patch since we've done
827         some refactorins in r152938 and r153067 to make this change more self-contained.
828
829         Test: fast/css/computed-width-without-renderer.html
830
831         * css/CSSComputedStyleDeclaration.cpp:
832         (WebCore::zoomAdjustedPaddingOrMarginPixelValue):
833         (WebCore::paddingOrMarginIsRendererDependent):
834         (WebCore::isLayoutDependent):
835         (WebCore::ComputedStyleExtractor::propertyValue):
836
837 2013-07-25  Sam Weinig  <sam@webkit.org>
838
839         -[WebHTMLView attributedSubstringForProposedRange:actualRange:] does not include strikethrough attribute in the returned attributed string
840         https://bugs.webkit.org/show_bug.cgi?id=119099
841         <rdar://problem/13439291>
842
843         Reviewed by Enrica Casucci.
844
845         Tests:
846             API Test: AttributedStringTest_Strikethrough
847
848         * platform/mac/HTMLConverter.mm:
849         (+[WebHTMLConverter editingAttributedStringFromRange:]):
850         Set the NSStrikethroughStyleAttributeName attribute when text-decoration: line-through is seen.
851
852 2013-07-25  Pratik Solanki  <psolanki@apple.com>
853
854         Unreviewed build fix after r153333.
855
856         * platform/network/cf/ResourceResponseCFNet.cpp: Remove toTimeT since it is no longer called.
857
858 2013-07-25  Christophe Dumez  <ch.dumez@sisa.samsung.com>
859
860         Unreviewed EFL build fix after r153315.
861
862         Fix build error after we started compiling with c++0x support
863         in r153315.
864
865         * platform/efl/RenderThemeEfl.cpp:
866         (WebCore::toEdjeGroup):
867
868 2013-07-25  Anders Carlsson  <andersca@apple.com>
869
870         Remove lastModifiedDate from ResourceResponse
871         https://bugs.webkit.org/show_bug.cgi?id=119092
872
873         Reviewed by Andreas Kling.
874
875         Computing m_lastResponseDate is costly on some platforms and we already have a better way to
876         get the last response time, so convert the two call sites that used to call ResourceresponseBase::lastModifiedDate()
877         over to using lastModified() instead.
878
879         * platform/network/ResourceResponseBase.cpp:
880         (WebCore::ResourceResponseBase::ResourceResponseBase):
881         (WebCore::ResourceResponseBase::adopt):
882         (WebCore::ResourceResponseBase::copyData):
883         * platform/network/ResourceResponseBase.h:
884         * platform/network/cf/ResourceResponseCFNet.cpp:
885         (WebCore::ResourceResponse::platformLazyInit):
886         * plugins/PluginStream.cpp:
887         (WebCore::lastModifiedDate):
888         (WebCore::PluginStream::startStream):
889
890 2013-07-25  Yi Shen  <max.hong.shen@gmail.com>
891
892         Optimize the thread locks for API Shims
893         https://bugs.webkit.org/show_bug.cgi?id=118573
894
895         Reviewed by Geoffrey Garen.
896
897         Remove the thread lock from API Shims if the VM has an exclusive thread (e.g. the VM 
898         only used by WebCore's main thread).
899
900         No new tests required since no functionality changed.
901
902         * bindings/js/JSDOMWindowBase.cpp:
903         (WebCore::JSDOMWindowBase::commonVM):
904
905 2013-07-25  Bear Travis  <betravis@adobe.com>
906
907         [CSS Shapes] Shape methods and member variables should be guarded with the CSS_SHAPES flag
908         https://bugs.webkit.org/show_bug.cgi?id=117277
909
910         Reviewed by Alexandru Chiculita.
911
912         This patch adds some compile guards that were missing from the RenderStyle and
913         StyleRareNonInheritedData files. When the compile guard caused parameters to
914         not be used, the parameters were marked using UNUSED_PARAM.
915
916         * css/CSSPropertyNames.in: Inserting a line to trigger build.
917         * rendering/RenderBlock.cpp:
918         (WebCore::shapeInfoRequiresRelayout):
919         (WebCore::RenderBlock::updateRegionsAndShapesBeforeChildLayout):
920         (WebCore::RenderBlock::logicalRightFloatOffsetForLine):
921         * rendering/RenderBox.cpp:
922         (WebCore::isCandidateForOpaquenessTest):
923         * rendering/RenderBox.h:
924         * rendering/RenderObject.h:
925         * rendering/style/RenderStyle.cpp:
926         (WebCore::RenderStyle::changeRequiresLayout):
927         (WebCore::RenderStyle::changeRequiresRepaint):
928         * rendering/style/RenderStyle.h:
929         * rendering/style/StyleRareNonInheritedData.cpp:
930         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
931         (WebCore::StyleRareNonInheritedData::operator==):
932         * rendering/style/StyleRareNonInheritedData.h:
933
934 2013-07-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
935
936         Introduce toSVGPatternElement(), use it
937         https://bugs.webkit.org/show_bug.cgi?id=119013
938
939         Reviewed by Andreas Kling.
940
941         As a step to change static_cast with toSVGXXX, static_cast<SVGPatternElement*> can
942         be changed with toSVGPatternElement().
943
944         Merge from https://src.chromium.org/viewvc/blink?view=rev&revision=154734
945
946         * rendering/svg/RenderSVGResourcePattern.cpp:
947         (WebCore::RenderSVGResourcePattern::buildPattern):
948         * rendering/svg/SVGRenderTreeAsText.cpp:
949         (WebCore::writeSVGResourceContainer):
950         * rendering/svg/SVGResources.cpp:
951         (WebCore::targetReferenceFromResource):
952         * svg/SVGPatternElement.h:
953         (WebCore::toSVGPatternElement):
954
955 2013-06-21  Mark Lam  <mark.lam@apple.com>
956
957         Fixed broken build: updated to match SmallStrings changes in r151864.
958
959         Not reviewed.
960
961         No new tests.
962
963         * bindings/js/JSDOMBinding.h:
964         (WebCore::jsStringWithCache):
965
966 2013-06-15  Filip Pizlo  <fpizlo@apple.com>
967
968         Concurrent JIT shouldn't try to recompute the CodeBlockHash as part of debug dumps, since doing so may fail if dealing with a CachedScript that doesn't have its script string handy
969         https://bugs.webkit.org/show_bug.cgi?id=117676
970
971         Reviewed by Sam Weinig.
972
973         Remove the broken hack for the concurrent JIT, since now the concurrent JIT won't use this code anymore.
974
975         No new tests because no new behavior.
976
977         * loader/cache/CachedScript.cpp:
978         (WebCore::CachedScript::script):
979
980 2013-06-10  Mark Lam  <mark.lam@apple.com>
981
982         Introducing the StackIterator class.
983         https://bugs.webkit.org/show_bug.cgi?id=117390.
984
985         Reviewed by Geoffrey Garen.
986
987         No new tests.
988
989         * ForwardingHeaders/interpreter/StackIterator.h: Added.
990         * bindings/js/JSXMLHttpRequestCustom.cpp:
991         (WebCore::JSXMLHttpRequest::send):
992         * bindings/js/ScriptCallStackFactory.cpp:
993         (WebCore::createScriptCallStack):
994
995 2013-06-09  Filip Pizlo  <fpizlo@apple.com>
996
997         Unreviewed, fix build. Use at() instead of operator[] because of ambiguity on some compilers.
998
999         * page/CaptionUserPreferencesMac.mm:
1000         (WebCore::languageIdentifier):
1001
1002 2013-05-27  Filip Pizlo  <fpizlo@apple.com>
1003
1004         testRunner should be able to tell you if a function is DFG compiled
1005         https://bugs.webkit.org/show_bug.cgi?id=116847
1006
1007         Reviewed by Mark Hahnenberg.
1008
1009         Bail early if we're in the compilation thread. This is only relevant for
1010         debug dumps.
1011
1012         No new tests becase no new behavior.
1013
1014         * loader/cache/CachedScript.cpp:
1015         (WebCore::CachedScript::script):
1016
1017 2013-05-25  Mark Lam  <mark.lam@apple.com>
1018
1019         Remove Interpreter::retrieveLastCaller().
1020         https://bugs.webkit.org/show_bug.cgi?id=116753.
1021
1022         Reviewed by Geoffrey Garen.
1023
1024         This is part of the refactoring effort to get rid of functions walking
1025         the JS stack in their own way.
1026
1027         No new tests.
1028
1029         * bindings/js/JSXMLHttpRequestCustom.cpp:
1030         (WebCore::JSXMLHttpRequest::send):
1031         * bindings/js/ScriptCallStackFactory.cpp:
1032         (WebCore::createScriptCallStack):
1033
1034 2013-05-05  Geoffrey Garen  <ggaren@apple.com>
1035
1036         Rolled back in r149527 with crash fixed.
1037
1038         Reviewed by Oliver Hunt.
1039
1040             Rationalized 'this' value conversion
1041             https://bugs.webkit.org/show_bug.cgi?id=115542
1042
1043 2013-04-29  Filip Pizlo  <fpizlo@apple.com>
1044
1045         fourthTier: String::utf8() should also be available as StringImpl::utf8() so that you don't have to ref() a StringImpl just to get its utf8()
1046         https://bugs.webkit.org/show_bug.cgi?id=115393
1047
1048         Reviewed by Geoffrey Garen.
1049
1050         No new tests because no new behavior.
1051
1052         * Modules/websockets/WebSocket.cpp:
1053         (WebCore::WebSocket::close):
1054         * Modules/websockets/WebSocketChannel.cpp:
1055         (WebCore::WebSocketChannel::send):
1056         * html/MediaFragmentURIParser.cpp:
1057         (WebCore::MediaFragmentURIParser::parseFragments):
1058
1059 2013-07-24  Simon Fraser  <simon.fraser@apple.com>
1060
1061         [iOS] Captions are clipped in documents using pagination
1062         https://bugs.webkit.org/show_bug.cgi?id=119072
1063
1064         Reviewed by Beth Dakin.
1065
1066         MediaControlTextTrackContainerElement::createTextTrackRepresentationImage() is called
1067         to paint captions into a layer used for fullscreen video. It did the painting using
1068         a subtree paint, but starting at the root RenderView's layer. This is problematic,
1069         because the caption painting is subject to clipping for columns, and any enclosing
1070         overflow:hidden container.
1071         
1072         Fix this by starting the paint at the MediaControlTextTrackContainerElement's
1073         renderer's layer. By doing this we don't have to worry about an offset, so no
1074         translation is required.
1075         
1076         Also make sure we update layer before grabbing the renderer (in case layout
1077         destroys it).
1078
1079         * html/shadow/MediaControlElements.cpp:
1080         (WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage):
1081
1082 2013-07-24  Simon Fraser  <simon.fraser@apple.com>
1083
1084         REGRESSION (r152335): Mac Pro title occluded in MobileSafari; can't scroll page
1085         https://bugs.webkit.org/show_bug.cgi?id=119066
1086         <rdar://problem/14499184>
1087
1088         Reviewed by Daniel Bates.
1089
1090         Following <http://trac.webkit.org/changeset/152335> (bug #118337) we set
1091         the z-index to 0 on every element with CSS "overflow: scroll" and
1092         "-webkit-overflow-scrolling: touch" regardless of whether the element has
1093         non-auto z-index. Instead we should only set the z-index to 0 for such elements
1094         that have an auto z-index.
1095
1096         * css/StyleResolver.cpp:
1097         (WebCore::StyleResolver::adjustRenderStyle):
1098
1099 2013-07-24  Ryosuke Niwa  <rniwa@webkit.org>
1100
1101         Use-after-free in ApplyStyleCommand::removeInlineStyle
1102         https://bugs.webkit.org/show_bug.cgi?id=118627
1103
1104         Reviewed by Oliver Hunt.
1105         
1106         Merge https://chromium.googlesource.com/chromium/blink/+/b6471d077e012b05ccba14d0ce8e6d616106c8e6
1107
1108         Unfortunately, there is no test case for this bug.
1109
1110         * editing/ApplyStyleCommand.cpp:
1111         (WebCore::ApplyStyleCommand::removeInlineStyle):
1112
1113 2013-07-24  Zan Dobersek  <zdobersek@igalia.com>
1114
1115         Remove CheckedInt, use Checked<T, RecordOverflow> instead
1116         https://bugs.webkit.org/show_bug.cgi?id=119022
1117
1118         Reviewed by Oliver Hunt.
1119
1120         Following the cleanup in r153062, the CheckedInt uses are replaced with
1121         using the Checked<T, RecordOverflow> class. The CheckedInt header is not
1122         used anywhere anymore and is thus removed.
1123
1124         * GNUmakefile.list.am:
1125         * WebCore.xcodeproj/project.pbxproj:
1126         * html/canvas/CheckedInt.h: Removed.
1127         * html/canvas/DataView.cpp:
1128         (WebCore::DataView::create):
1129         * html/canvas/WebGLBuffer.cpp:
1130         (WebCore::WebGLBuffer::associateBufferSubDataImpl):
1131         * html/canvas/WebGLRenderingContext.cpp:
1132         (WebCore::WebGLRenderingContext::drawArrays):
1133
1134 2013-07-24  Andreas Kling  <akling@apple.com>
1135
1136         RenderMenuList computes the width of its longest option twice.
1137         <http://webkit.org/b/119046>
1138         <rdar://problem/14534679>
1139
1140         Reviewed by Darin Adler.
1141
1142         Rename the RenderMenuList::m_optionsChanged flag to m_needsOptionsWidthUpdate,
1143         and make sure it gets cleared after we do a width computation in response to font changes.
1144
1145         * rendering/RenderMenuList.cpp:
1146         (WebCore::RenderMenuList::styleDidChange):
1147
1148 2013-07-24  Zan Dobersek  <zdobersek@igalia.com>
1149
1150         Make KURL::hasPath private
1151         https://bugs.webkit.org/show_bug.cgi?id=118279
1152
1153         Reviewed by Darin Adler.
1154
1155         * platform/KURL.h: The KURL::hasPath method is not used outside of the KURL class, so it is made private.
1156
1157 2013-07-24  Jessie Berlin  <jberlin@apple.com>
1158
1159         Remove WKPageGetPlugInInformation - it is not used anymore
1160         https://bugs.webkit.org/show_bug.cgi?id=119047
1161
1162         Rubber-stamped by Alexey Proskuryakov.
1163
1164         Revert r152328, which added a key used only in the callback info for
1165         WKPageGetPlugInInformation.
1166
1167         * WebCore.exp.in:
1168
1169 2013-07-24  Robert Hogan  <robert@webkit.org>
1170
1171         Border drawing incorrect when using both border-collapse: collapse and overflow: hidden on a table
1172         https://bugs.webkit.org/show_bug.cgi?id=18305
1173
1174         Reviewed by David Hyatt.
1175
1176         overflowClipRect() clips out the table's half of a collapsed border when there is an overflow clip
1177         on the table. This prevents the table's half of the border ever getting painted. 
1178
1179         To fix this, clip to the border box of tables when we're in the paint phase that gets the sections to draw the collapsed borders
1180         or when we're self painting. This will allow the table's half of the border to get painted. In the case where the table is self
1181         painting we ensure that content gets clipped to cell's side of the collapsed border by ensuring the clip passed to child layers
1182         from the table clips to the inside of the collapsed border. 
1183
1184         It's worth noting that a table's collapsed borders are painted by the table's layer using functions in 
1185         RenderTableSection and RenderTableCell. So if a table section has a self-painting layer this patch still works, because
1186         the borders aren't painted by the section's layer.
1187
1188         Tests: fast/table/overflow-table-collapsed-borders-cell-painting-table-self-painting-layer.html
1189                fast/table/overflow-table-collapsed-borders-cell-painting.html
1190                fast/table/overflow-table-collapsed-borders-section-layer-painting.html
1191                fast/table/overflow-table-collapsed-borders-section-layer-table-self-painting-layer.html
1192                fast/table/overflow-table-collapsed-borders-section-self-painting-layer-painting.html
1193                fast/table/overflow-table-collapsed-borders-section-self-painting-layer-table-self-painting-layer.html
1194                fast/table/table-overflow.html
1195
1196         * rendering/RenderBox.cpp:
1197         (WebCore::RenderBox::pushContentsClip):
1198         (WebCore::RenderBox::overflowClipRect):
1199         * rendering/RenderBox.h:
1200         (WebCore::RenderBox::overflowClipRectForChildLayers):
1201         * rendering/RenderLayer.cpp:
1202         (WebCore::RenderLayer::calculateClipRects):
1203         * rendering/RenderTable.cpp:
1204         (WebCore::RenderTable::overflowClipRect):
1205         * rendering/RenderTable.h:
1206         (WebCore::RenderTable::overflowClipRectForChildLayers):
1207
1208 2013-07-24  Frédéric Wang  <fred.wang@free.fr>
1209
1210         Graphical elements inside mphantom should not be visible.
1211         https://bugs.webkit.org/show_bug.cgi?id=116600.
1212
1213         Reviewed by Chris Fleizach.
1214
1215         Test: mathml/presentation/phantom.html
1216
1217         * rendering/mathml/RenderMathMLFraction.cpp:
1218         (WebCore::RenderMathMLFraction::paint): don't paint the fraction bar when the visibility is not "visible"
1219         * rendering/mathml/RenderMathMLRoot.cpp:
1220         (WebCore::RenderMathMLRoot::paint): don't paint the radical symbol when the visibility is not "visible"
1221
1222 2013-07-24  Brendan Long  <b.long@cablelabs.com>
1223
1224         WebVTTParser's identifier buffering can ignore subsequent lines
1225         https://bugs.webkit.org/show_bug.cgi?id=118483
1226
1227         Reviewed by Eric Carlson.
1228
1229         No new tests since this bug can't be reproduced in layout tests.
1230
1231         * html/track/WebVTTParser.cpp:
1232         (WebCore::WebVTTParser::parseBytes): Only buffer the identifier if we haven't read an entire line.
1233
1234 2013-07-23  Andreas Kling  <akling@apple.com>
1235
1236         REGRESSION(r150867): FrameView auto-sizing + delegate denied image load may cause StyleResolver to re-enter itself.
1237         <rdar://problem/14324895>
1238         <http://webkit.org/b/119023>
1239
1240         Reviewed by Simon Fraser.
1241
1242         The bug happened when FrameView::autoSizeIfEnabled() was getting called below FrameLoader::checkCompleted()
1243         triggered by an incorrect loadDone() callback originating in SubresourceLoader::didCancel().
1244
1245         * css/StyleResolver.cpp:
1246         (WebCore::StyleResolver::loadPendingResources):
1247
1248             Add an assertion that this function is not getting re-entered. If a similar bug occurs
1249             in the future, this will help the lucky person debugging.
1250
1251         * loader/SubresourceLoader.cpp:
1252         (WebCore::SubresourceLoader::didCancel):
1253
1254             Don't notifyDone() if the SubresourceLoader is in Uninitialized state.
1255
1256 2013-07-23  Tim Horton  <timothy_horton@apple.com>
1257
1258         Pixel-snap the unavailable plugin indicator arrow for maximum sharpness
1259         https://bugs.webkit.org/show_bug.cgi?id=119024
1260         <rdar://problem/14523331>
1261
1262         Reviewed by Anders Carlsson.
1263
1264         * rendering/RenderEmbeddedObject.cpp:
1265         (WebCore::addReplacementArrowPath):
1266         (WebCore::RenderEmbeddedObject::getReplacementTextGeometry):
1267         Pixel-snap the unavailable plugin indicator arrow. Snapping directions
1268         were chosen by eye/symmetry to look best on 1x and 2x devices at
1269         1x and 2x page scale.
1270
1271 2013-07-19  Ryosuke Niwa  <rniwa@webkit.org>
1272
1273         The computed values of fix length padding should be subpixel precision like margin
1274         https://bugs.webkit.org/show_bug.cgi?id=118936
1275
1276         Reviewed by Simon Fraser.
1277
1278         The bug was caused by ComputedStyleExtractor::propertyValue always returning the used value
1279         for padding. Fixed the bug by returning the computed value when they're of fixed length.
1280
1281         This aligns the behaviors of getComputedStyle(~).padding~ with getComputedStyle(~).margin~,
1282         which had been fixed in r102149. While the current CSSOM specification says getComputedStyle
1283         should return the used values for margins when display property is set to anything but none,
1284         new behavior matches that of Chrome, Firefox, and Internet Explorer.
1285
1286         Also extracted zoomAdjustedPaddingOrMarginPixelValue to reduce the code duplication.
1287
1288         Test: fast/css/getComputedStyle/getComputedStyle-padding-margin-subpixel-length.html
1289
1290         * css/CSSComputedStyleDeclaration.cpp:
1291         (WebCore::zoomAdjustedPaddingOrMarginPixelValue): Extracted.
1292         (WebCore::ComputedStyleExtractor::propertyValue):
1293
1294 2013-07-23  Alex Christensen  <achristensen@apple.com>
1295
1296         Updated ANGLE to latest git commit (047373aa3eb408be62be52ade840fa5f11e72337).
1297         https://bugs.webkit.org/show_bug.cgi?id=118550
1298
1299         Reviewed by Dean Jackson.
1300
1301         * CMakeLists.txt: Renamed DetectRecursion to DetectCallDepth and added Uniform.cpp.
1302
1303 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1304
1305         Use Checked<uint32_t, RecordOverflow> instead of CheckedInt in GraphicsContext3D
1306         https://bugs.webkit.org/show_bug.cgi?id=118988
1307
1308         Reviewed by Oliver Hunt.
1309
1310         Use the WTF's Checked class, with uint32_t as the numeric type and RecordOverflow as the overflow handler,
1311         instead of the CheckedInt class. This removes a layering violation that's occurring due to including the CheckedInt
1312         header that's currently located in the WebCore layer (alongside the HTML canvas code in Source/WebCore/html/canvas).
1313
1314         * platform/graphics/GraphicsContext3D.cpp:
1315         (WebCore::GraphicsContext3D::computeImageSizeInBytes):
1316
1317 2013-07-23  Zalan Bujtas  <zalan@apple.com>
1318
1319         REGRESSION(r152313): Links in certain twitter postings don't warp correctly on page
1320         https://bugs.webkit.org/show_bug.cgi?id=118435
1321
1322         Reviewed by David Hyatt.
1323
1324         When we find an empty inline in the middle of the word, prefer breaking it before 
1325         instead of after to match other browsers' rendering.
1326
1327         Test: fast/text/whitespace/inline-whitespace-wrapping-12.html
1328
1329         * rendering/RenderBlockLineLayout.cpp:
1330         (WebCore::canBreakAtThisPosition):
1331
1332 2013-07-23  Alexey Proskuryakov  <ap@apple.com>
1333
1334         Dictionary hotkey does not work on vertical text
1335         https://bugs.webkit.org/show_bug.cgi?id=118993
1336         <rdar://problem/14478260>
1337
1338         Reviewed by Enrica Casucci.
1339
1340         Test: platform/mac/editing/input/firstrectforcharacterrange-vertical.html
1341
1342         * editing/Editor.cpp:
1343         (WebCore::collapseCaretWidth): A helper function.
1344         (WebCore::Editor::firstRectForRange): Many changes:
1345         - use RenderObject::absoluteBoundingBoxRectForRange() in regular case, because
1346         that's more direct that getting caret rects and computing bounding rect from those.
1347         - handle collapsed ranges separately, because absoluteBoundingBoxRectForRange()
1348         doesn't provide the needed result, and because it can be done faster.
1349         - wherever we use carets to compute the result, account for vertical text (in a hackish
1350         way, as we don't have layout information at Editor level).
1351
1352         * rendering/RenderBlock.cpp: (WebCore::RenderBlock::localCaretRect): Removed
1353         dead code.
1354
1355 2013-07-23  Bem Jones-Bey  <bjonesbe@adobe.com>
1356
1357         [CSS Shapes] New positioning model: Borders
1358         https://bugs.webkit.org/show_bug.cgi?id=118822
1359
1360         Reviewed by Dean Jackson.
1361
1362         Converting to the shape coordinate system was not properly accounting
1363         for borders and padding. This has been fixed and a new convienence
1364         method added because of the added complexity of the conversion.
1365
1366         Test: csswg/submitted/shapes/shape-outside/shape-outside-floats-square-border-000.html
1367
1368         * rendering/RenderBlock.cpp:
1369         (WebCore::RenderBlock::logicalLeftFloatOffsetForLine): Update to use
1370             computeSegmentsForContainingBlockLine to do the coordinate
1371             conversion.
1372         (WebCore::RenderBlock::logicalRightFloatOffsetForLine): Ditto.
1373         * rendering/RenderBlockLineLayout.cpp:
1374         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded): Ditto.
1375         * rendering/shapes/ShapeOutsideInfo.cpp:
1376         (WebCore::ShapeOutsideInfo::computeSegmentsForContainingBlockLine):
1377             Add new method to do the coordinate conversion from the containing
1378             block coordinate system to the coordinate system of the shape so
1379             that the segments can be correctly calculated.
1380
1381 2013-07-23  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1382
1383         Remove deprecated and unused compositing settings
1384         https://bugs.webkit.org/show_bug.cgi?id=119014
1385
1386         Reviewed by Andreas Kling.
1387
1388         * page/Settings.in:
1389
1390 2013-07-23  Tim Horton  <timothy_horton@apple.com>
1391
1392         Add a test for plug-in unavailability indicator obscurity detection
1393         https://bugs.webkit.org/show_bug.cgi?id=119007
1394
1395         Reviewed by Anders Carlsson.
1396
1397         Test: plugins/unavailable-plugin-indicator-obscurity.html
1398
1399         Expose the ability to test whether the unavailable plugin indicator
1400         is obscured via the internals object.
1401
1402         * testing/Internals.cpp:
1403         (WebCore::Internals::isPluginUnavailabilityIndicatorObscured):
1404         * testing/Internals.h:
1405         * testing/Internals.idl:
1406         Expose RenderEmbeddedObject::isReplacementObscured as
1407         internals.isPluginUnavailabilityIndicatorObscured for testing purposes.
1408
1409 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1410
1411         [Soup] Clean up header inclusions in ResourceRequest(Soup), SocketStreamHandle
1412         https://bugs.webkit.org/show_bug.cgi?id=118984
1413
1414         Reviewed by Darin Adler.
1415
1416         Execute a minor cleanup of the header inclusions in Soup-specific ResourceRequestSoup.cpp, ResourceRequest.h
1417         and SocketStreamHandle.h source files. The inclusions are sorted into proper order, with blank lines and unnecessary
1418         reinclusions removed.
1419
1420         * platform/network/soup/ResourceRequest.h:
1421         * platform/network/soup/ResourceRequestSoup.cpp:
1422         * platform/network/soup/SocketStreamHandle.h:
1423
1424 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1425
1426         [Soup] Remove unnecessary header inclusions in ResourceHandleSoup.cpp
1427         https://bugs.webkit.org/show_bug.cgi?id=118983
1428
1429         Reviewed by Martin Robinson.
1430
1431         Remove inclusions of the CachedResourceLoader, ChromeClient, Frame and Page headers. These are not
1432         necessary (anymore) and only prevent the source file to be built independently of WebCore, as it should be.
1433
1434         * platform/network/soup/ResourceHandleSoup.cpp:
1435
1436 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1437
1438         Remove unnecessary header inclusions in GraphicsContext3D.cpp, GraphicsContext3DOpenGLCommon.cpp
1439         https://bugs.webkit.org/show_bug.cgi?id=118989
1440
1441         Reviewed by Darin Adler.
1442
1443         * platform/graphics/GraphicsContext3D.cpp: Remove the unnecessary DrawingBuffer header inclusion.
1444         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp: Remove the unnecessary
1445         CanvasRenderingContext and WebGLObject header inclusions.
1446
1447 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1448
1449         Remove the topDocumentURL member of the GraphicsContext3D::Attributes struct
1450         https://bugs.webkit.org/show_bug.cgi?id=118987
1451
1452         Reviewed by Darin Adler.
1453
1454         Remove the topDocumentURL member that currently resides in the GraphicsContext3D::Attributes struct.
1455         It's not used anywhere and only has one place where it is set, in WebGLRenderingContext::create.
1456
1457         * html/canvas/WebGLRenderingContext.cpp:
1458         (WebCore::WebGLRenderingContext::create):
1459         * platform/graphics/GraphicsContext3D.h:
1460
1461 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1462
1463         Remove unused DrawingBuffer::paintRenderingResultsToImageData
1464         https://bugs.webkit.org/show_bug.cgi?id=118986
1465
1466         Reviewed by Darin Adler.
1467
1468         Remove the paintRenderingResultsToImageData method of the DrawingBuffer class. It is not used anywhere
1469         and also introduces a nasty layering violation by including and operating with the ImageData class.
1470
1471         * platform/graphics/gpu/DrawingBuffer.cpp:
1472         * platform/graphics/gpu/DrawingBuffer.h:
1473
1474 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1475
1476         Remove unnecessary includes in FormDataBuilder.cpp
1477         https://bugs.webkit.org/show_bug.cgi?id=118991
1478
1479         Reviewed by Darin Adler.
1480
1481         * platform/network/FormDataBuilder.cpp: Remove the Frame and FrameLoader header inclusions,
1482         nothing these two headers provide is used in this source file.
1483
1484 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1485
1486         Fix the style of the ContentDispositionType enum definition
1487         https://bugs.webkit.org/show_bug.cgi?id=118990
1488
1489         Reviewed by Darin Adler.
1490
1491         * platform/network/HTTPParsers.h: Align the style of the ContentDispositionType enumeration
1492         definition with the other enumeration definitions in the HTTPParsers header, using the
1493         'enum Name { ... }' style instead of a typedef.
1494
1495 2013-07-23  Zan Dobersek  <zdobersek@igalia.com>
1496
1497         [GTK] Mock GDK_IS_X11_DISPLAY macro can be redefined unnecessarily
1498         https://bugs.webkit.org/show_bug.cgi?id=118980
1499
1500         Reviewed by Martin Robinson.
1501
1502         * platform/gtk/GtkVersioning.h: Only define the GDK_IS_X11_DISPLAY macro when using the GTK+ 2 API version
1503         as that's the only supported configuration where the macro is not defined. Definining it only if it's not
1504         yet defined at the time of inclusion of this header can cause redefinitions in GTK+ headers that are normally
1505         included later.
1506
1507 2013-07-22  Beth Dakin  <bdakin@apple.com>
1508
1509         StickyPositionConstraints should store the constrainingRectAtLastLayout
1510         https://bugs.webkit.org/show_bug.cgi?id=118999
1511
1512         Reviewed by Simon Fraser.
1513
1514         Much like how FixedPositionConstraints store a viewportRectAtLastLayout, 
1515         StickyConstraints should store a constrainingRectAtLastLayout. We'll need this to 
1516         get sticky right in overflow areas once overflow areas scroll on the scrolling 
1517         thread. 
1518
1519         * page/scrolling/ScrollingConstraints.h:
1520         (WebCore::StickyPositionViewportConstraints::StickyPositionViewportConstraints):
1521         (WebCore::StickyPositionViewportConstraints::constrainingRectAtLastLayout):
1522         (WebCore::StickyPositionViewportConstraints::setConstrainingRectAtLastLayout):
1523         * rendering/RenderBoxModelObject.cpp:
1524         (WebCore::RenderBoxModelObject::computeStickyPositionConstraints):
1525
1526 2013-07-22  Santosh Mahto  <santosh.ma@samsung.com>
1527
1528         DateInputType constructor initiate incorrect base class
1529         https://bugs.webkit.org/show_bug.cgi?id=118962
1530
1531         Reviewed by Gyuyoung Kim.
1532
1533         No new test required since solving code error
1534
1535         * html/DateInputType.cpp:
1536         (WebCore::DateInputType::DateInputType):
1537         Corrected the base class instantiation in constructor.
1538
1539 2013-07-22  Tim Horton  <timothy_horton@apple.com>
1540
1541         Plug-in unavailability indicator should not be displayed if a blocked plugin's indicator is clipped
1542         https://bugs.webkit.org/show_bug.cgi?id=118998
1543         <rdar://problem/14511268>
1544
1545         Reviewed by Anders Carlsson.
1546         
1547         * html/HTMLEmbedElement.cpp:
1548         (WebCore::HTMLEmbedElement::updateWidget):
1549         * html/HTMLObjectElement.cpp:
1550         (WebCore::HTMLObjectElement::updateWidget):
1551         * html/HTMLPlugInElement.cpp:
1552         (WebCore::HTMLPlugInElement::defaultEventHandler):
1553         (WebCore::HTMLPlugInElement::supportsFocus):
1554         * html/HTMLPlugInImageElement.cpp:
1555         (WebCore::HTMLPlugInImageElement::updateWidgetIfNecessary):
1556         * loader/SubframeLoader.cpp:
1557         (WebCore::SubframeLoader::createJavaAppletWidget):
1558         (WebCore::SubframeLoader::loadPlugin):
1559         * page/FrameView.cpp:
1560         (WebCore::FrameView::updateWidget):
1561         Rename showsUnavailablePluginIndicator to isPluginUnavailable, since being unavailable
1562         and actually showing the indicator are two totally different things.
1563
1564         * WebCore.exp.in: Expose setUnavailablePluginIndicatorIsHidden.
1565
1566         * rendering/RenderEmbeddedObject.cpp:
1567         (WebCore::RenderEmbeddedObject::RenderEmbeddedObject):
1568         Rename m_showsUnavailablePluginIndicator to m_isPluginUnavailable.
1569         Add m_isUnavailablePluginIndicatorHidden, defaulting to false.
1570
1571         (WebCore::RenderEmbeddedObject::setPluginUnavailabilityReasonWithDescription):
1572         Set m_isPluginUnavailable when we get an unavailability reason.
1573
1574         (WebCore::RenderEmbeddedObject::paint):
1575         (WebCore::RenderEmbeddedObject::setUnavailablePluginIndicatorIsHidden): Added.
1576
1577         * rendering/RenderEmbeddedObject.h:
1578         (WebCore::RenderEmbeddedObject::isPluginUnavailable): Added.
1579
1580         (WebCore::RenderEmbeddedObject::showsUnavailablePluginIndicator):
1581         Repurpose "showsUnavailablePluginIndicator" to actually represent whether
1582         the indicator is displayed (i.e. the plugin is unavailable, and the
1583         indicator is not hidden).
1584
1585 2013-07-22  Tim Horton  <timothy_horton@apple.com>
1586
1587         RenderEmbeddedObject::isReplacementObscured should include the arrow in its area-of-interest
1588         https://bugs.webkit.org/show_bug.cgi?id=118995
1589         <rdar://problem/14516421>
1590
1591         Reviewed by Anders Carlsson.
1592
1593         * rendering/RenderEmbeddedObject.cpp:
1594         (WebCore::RenderEmbeddedObject::unavailablePluginIndicatorBounds):
1595         Rename method from replacementTextRect to unavailablePluginIndicatorBounds for accuracy.
1596         Use the bounding box of the indicator's path, which includes the rounded rect behind
1597         the text as well as the arrow button.
1598
1599         (WebCore::RenderEmbeddedObject::isReplacementObscured):
1600         * rendering/RenderEmbeddedObject.h:
1601
1602 2013-07-22  Tim Horton  <timothy_horton@apple.com>
1603
1604         <applet> plugins are instantiated post-attach (instead of post-layout like for object and embed)
1605         https://bugs.webkit.org/show_bug.cgi?id=118994
1606         <rdar://problem/14511232>
1607
1608         Reviewed by Anders Carlsson.
1609
1610         Make <applet> consistent with <object> and <embed>, deferring plugin
1611         instantiation to post-layout, so that layout is up-to-date if anything
1612         needs it (like RenderEmbeddedObject::isReplacementObscured) during creation.
1613
1614         * html/HTMLAppletElement.cpp:
1615         (WebCore::HTMLAppletElement::updateWidget):
1616         Copy code from HTMLObjectElement/HTMLEmbedElement that defers plugin
1617         creation until post-layout tasks. Java is always an NPAPI plugin, so
1618         we should always defer if requested.
1619
1620 2013-07-22  Benjamin Poulain  <benjamin@webkit.org>
1621
1622         Do not allocate 2 AtomicString just to do a comparison in HTMLAnchorElement::setRel()
1623         https://bugs.webkit.org/show_bug.cgi?id=118941
1624
1625         Reviewed by Gavin Barraclough.
1626
1627         Currently, the only type of link relation supported by HTMLAnchorElement is RelationNoReferrer.
1628
1629         To find the value, we create a SpaceSplitString with the input value of the attribute (which
1630         create one or more AtomicString depending on the input). Then we create a new AtomicString for
1631         the literal "noreferrer". Finally, we compare the pointers and throw away all the AtomicStrings.
1632
1633         This causes a lot of memory operations for something really simple.
1634
1635         This patch adds a little helper method to SpaceSplitString to find a literal in the input. The only
1636         allocation happens if we need to foldCase(). The following operations are done without allocating
1637         new buffer and without hashing the input.
1638
1639         * dom/SpaceSplitString.cpp:
1640         (WebCore::tokenizeSpaceSplitString):
1641         (WebCore::AppendTokenToVectorTokenProcessor::AppendTokenToVectorTokenProcessor):
1642         (WebCore::AppendTokenToVectorTokenProcessor::processToken):
1643         (WebCore::SpaceSplitStringData::createVector):
1644         (WebCore::TokenIsEqualToCStringTokenProcessor::TokenIsEqualToCStringTokenProcessor):
1645         (WebCore::TokenIsEqualToCStringTokenProcessor::processToken):
1646         (WebCore::TokenIsEqualToCStringTokenProcessor::referenceStringWasFound):
1647         (WebCore::SpaceSplitString::spaceSplitStringContainsValue):
1648         * dom/SpaceSplitString.h:
1649         (WebCore::SpaceSplitString::spaceSplitStringContainsValue):
1650         * html/HTMLAnchorElement.cpp:
1651         (WebCore::HTMLAnchorElement::setRel):
1652
1653 2013-07-22  Zalan Bujtas  <zalan@apple.com>
1654
1655         segfault in RenderLayerCompositor when the iframe's position attribute is changed and it embeds <object>.
1656         https://bugs.webkit.org/show_bug.cgi?id=118965
1657
1658         Reviewed by Simon Fraser.
1659
1660         Do not change the composition state unless we can reliably figure out the iframe's size.
1661         If the renderer is not yet attached, its size is not computable.
1662
1663         Test: compositing/iframes/iframe-position-absolute-with-padding-percentage-crash.html
1664
1665         * rendering/RenderLayerCompositor.cpp:
1666         (WebCore::RenderLayerCompositor::requiresCompositingForFrame):
1667
1668 2013-07-22  Chris Fleizach  <cfleizach@apple.com>
1669
1670         AX: VoiceOver only read the first column in a safari table
1671         https://bugs.webkit.org/show_bug.cgi?id=118992
1672
1673         Reviewed by Tim Horton.
1674
1675         In case the first section has fewer columns than the rest of the table, the AXTable was only reporting the number of
1676         columns for the first section. We need to take the max number of columns out of all sections.
1677
1678         Test: accessibility/table-with-mismatch-column-count-in-initial-section.html
1679
1680         * accessibility/AccessibilityTable.cpp:
1681         (WebCore::AccessibilityTable::addChildren):
1682
1683 2013-07-22  Beth Dakin  <bdakin@apple.com>
1684
1685         StickyPositionContraints should not need to change to account for a RenderLayer's 
1686         scrollOffset
1687         https://bugs.webkit.org/show_bug.cgi?id=118958
1688         -and corresponding-
1689         <rdar://problem/12469203>
1690
1691         Reviewed by Simon Fraser.
1692
1693         Before this patch, to get sticky offsets right in overflow areas, the 
1694         StickyPositionConstraints changed on every scroll to factor it in. This will be a 
1695         problem once we can scroll overflow areas on the scrolling thread. The constraints 
1696         should never have to change to account for the scroll position. This patch fixes 
1697         that issue by changing the StickyPositionViewportConstraints’s containerBlockRect 
1698         and stickyBoxRect to be in a coordinate space that is relative to the scrolling 
1699         ancestor rather than being absolute. This patch also removes ‘absolute’ from those 
1700         variable names since they are no longer absolute.
1701
1702         A few re-names in the StickyPositionViewportConstraints class. The parameter to 
1703         computeStickyOffset() used to be called viewportRect, and is now called 
1704         constrainingRect. m_absoluteStickyBoxRect is now m_stickyBoxRect, and 
1705         m_absoluteContainingBlockRect is now m_containingBlockRect. And finally, 
1706         layerPositionForViewportRect() is now layerPositionForConstrainingRect()
1707         * page/scrolling/ScrollingConstraints.cpp:
1708         (WebCore::StickyPositionViewportConstraints::computeStickyOffset):
1709         (WebCore::StickyPositionViewportConstraints::layerPositionForConstrainingRect):
1710         * page/scrolling/ScrollingConstraints.h:
1711         (WebCore::StickyPositionViewportConstraints::StickyPositionViewportConstraints):
1712         (WebCore::StickyPositionViewportConstraints::containingBlockRect):
1713         (WebCore::StickyPositionViewportConstraints::setContainingBlockRect):
1714         (WebCore::StickyPositionViewportConstraints::stickyBoxRect):
1715         (WebCore::StickyPositionViewportConstraints::setStickyBoxRect):
1716         (WebCore::StickyPositionViewportConstraints::operator==):
1717
1718         Accounting for the re-names. 
1719         * page/scrolling/ScrollingStateStickyNode.cpp:
1720         (WebCore::ScrollingStateStickyNode::syncLayerPositionForViewportRect):
1721         (WebCore::ScrollingStateStickyNode::dumpProperties):
1722         * page/scrolling/mac/ScrollingTreeStickyNode.mm:
1723         (WebCore::ScrollingTreeStickyNode::parentScrollPositionDidChange):
1724
1725         Compute all values relative to the scrolling ancestor. This requires some juggling 
1726         in the overflow case to factor border and padding in or out.
1727         * rendering/RenderBoxModelObject.cpp:
1728         (WebCore::RenderBoxModelObject::computeStickyPositionConstraints):
1729
1730         This is where the scrollOffset should be factored in.
1731         (WebCore::RenderBoxModelObject::stickyPositionOffset):
1732
1733 2013-07-22  Dean Jackson  <dino@apple.com>
1734
1735         PlugIn content can disappear after restarting
1736         https://bugs.webkit.org/show_bug.cgi?id=118982
1737
1738         Reviewed by Simon Fraser.
1739
1740         When a snapshotted plug-in is restarted, we inserted its compositing
1741         layer back into the tree, but didn't recalculate style. This meant
1742         that a subsequent compositing tree operation (such as any hardware
1743         animation) could cause the content to disappear.
1744
1745         * html/HTMLPlugInImageElement.cpp:
1746         (WebCore::HTMLPlugInImageElement::setDisplayState): Force a style recalc.
1747         (WebCore::HTMLPlugInImageElement::removeSnapshotTimerFired): Ditto.
1748
1749 2013-07-22  Zalan Bujtas  <zalan@apple.com>
1750
1751         REGRESSION(r152227) Images with compositing layer don't show up unless the containing window is resized.
1752         https://bugs.webkit.org/show_bug.cgi?id=118951
1753
1754         Reviewed by Simon Fraser.
1755
1756         Ensure that the content rect is initialized when the image is set on the graphics layer.
1757
1758         RenderLayerBacking::updateGraphicsLayerGeometry() only updates the contents rect when
1759         the associated graphics layer has a content layer. Since the image gets committed 
1760         on the graphics layer after the update calls, the contents rect is left uninitialized.
1761
1762         Test: compositing/images/positioned-image-content-rect.html
1763
1764         * rendering/RenderLayerBacking.cpp:
1765         (WebCore::RenderLayerBacking::updateImageContents):
1766
1767 2013-07-22  Diego Pino Garcia  <dpino@igalia.com>
1768
1769         [Old Web Inspector] When right-clicking on a DataGrid column, show editing menu option as "Edit <columnName>" instead of just "Edit"
1770         https://bugs.webkit.org/show_bug.cgi?id=118971
1771
1772         Reviewed by Timothy Hatcher.
1773
1774         * English.lproj/localizedStrings.js: 
1775         * inspector/front-end/DataGrid.js: Change "Edit" for "Edit <columnTitle>"
1776         (WebInspector.DataGrid.prototype._contextMenuInDataTable):
1777
1778 2013-07-22  Alex Christensen  <achristensen@apple.com>
1779
1780         Added assembly files to Windows 64-bit builds.
1781         https://bugs.webkit.org/show_bug.cgi?id=118931
1782
1783         Reviewed by Brent Fulgham.
1784
1785         * WebCore.vcxproj/WebCore.vcxproj: Added PaintHooks.asm for x64 and enabled MASM.
1786         * WebCore.vcxproj/WebCore.vcxproj.filters: Added PaintHooks.asm.
1787
1788 2013-07-22  Jakob Petsovits  <jpetsovits@blackberry.com>
1789
1790         [BlackBerry] Fix WebGL to a 2D canvas copies.
1791         https://bugs.webkit.org/show_bug.cgi?id=118921
1792         https://jira.bbqnx.net/browse/BRWSR-12714
1793         JIRA 449577
1794
1795         Reviewed by George Staikos.
1796
1797         The transform here was converted incorrectly when it
1798         replaced the pixel copy that was there before.
1799         As a true draw transformation, it doesn't need the "- 1"
1800         modification that pixel copies often require.
1801
1802         Fixes existing webgl/conformance/canvas tests.
1803
1804         * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
1805         (WebCore::GraphicsContext3D::paintToCanvas):
1806
1807 2013-07-22  peavo@outlook.com  <peavo@outlook.com>
1808
1809         [Curl] Download fails for certain urls.
1810         https://bugs.webkit.org/show_bug.cgi?id=118468
1811
1812         Reviewed by Brent Fulgham.
1813
1814         The current Curl download implementation has a few shortcomings:
1815         1) Downloading from secure locations fails. We need to provide Curl with the path to a certificate file (.pem file).
1816         2) Cookies are not set in the download request. We need to give Curl the path to the cookie file.
1817         3) When a normal load is converted to a download, some of the headers from the original request is not sent (e.g. Referer, User agent).
1818
1819         * platform/network/curl/CurlDownload.cpp:
1820         (WebCore::CurlDownload::CurlDownload): Initialize custom headers member.
1821         (WebCore::CurlDownload::~CurlDownload): Free custom headers member.
1822         (WebCore::CurlDownload::init): Set certificate and cookie file path.
1823         (WebCore::CurlDownload::closeFile): Check file handle against value for invalid platform handle.
1824         (WebCore::CurlDownload::writeDataToFile): Added utility method to write download data to file.
1825         (WebCore::CurlDownload::addHeaders): Added utility method to add headers to request.
1826         (WebCore::CurlDownload::didReceiveData): Use writeDataToFile utility method.
1827         * platform/network/curl/CurlDownload.h:
1828         Put class in WebCore namespace.
1829         Added method to init download from resource handle, request, and response object.
1830         Added utility method to write download data to file.
1831         Added utility method to add headers to request.
1832         Added custom headers member.
1833
1834 2013-07-22  Eric Carlson  <eric.carlson@apple.com>
1835
1836         [iOS] captions sometimes positioned incorrectly after fullscreen state change
1837         https://bugs.webkit.org/show_bug.cgi?id=118912
1838
1839         Reviewed by Jer Noble.
1840
1841         * html/shadow/MediaControlElements.cpp:
1842         (WebCore::MediaControlTextTrackContainerElement::updateDisplay): Call clearTextTrackRepresentation.
1843         (WebCore::MediaControlTextTrackContainerElement::updateTimerFired): Call updateDisplay so
1844             cues are re-rendered with the updated size.
1845         (WebCore::MediaControlTextTrackContainerElement::clearTextTrackRepresentation): Cleanup the
1846             text track representation.
1847         (WebCore::MediaControlTextTrackContainerElement::enteredFullscreen): New, force cues to be updated.
1848         (WebCore::MediaControlTextTrackContainerElement::exitedFullscreen): Ditto.
1849         * html/shadow/MediaControlElements.h:
1850
1851         * html/shadow/MediaControls.cpp:
1852         (WebCore::MediaControls::enteredFullscreen): Call MediaControlTextTrackContainerElement::enteredFullscreen.
1853         (WebCore::MediaControls::exitedFullscreen): Call MediaControlTextTrackContainerElement::exitedFullscreen.
1854
1855 2013-07-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1856
1857         [Qt][WK1] Support direct painting without GraphicsSurface
1858         https://bugs.webkit.org/show_bug.cgi?id=118302
1859
1860         Reviewed by Jocelyn Turcotte.
1861
1862         Configure the WebGL OpenGL context to share texture with
1863         the HostWindow OpenGL if available, and paint accelerated
1864         using the the now shared textures.
1865
1866         This should return the performance without GraphicsSurface
1867         on the WK1 code path to what it was before r135995 (28/11 2012).
1868
1869         * platform/graphics/qt/GraphicsContext3DQt.cpp:
1870         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
1871         (WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
1872
1873 2013-07-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1874
1875         Introduce toSVGUseElement(), use it
1876         https://bugs.webkit.org/show_bug.cgi?id=118942
1877
1878         Reviewed by Allan Sandfeld Jensen.
1879
1880         As a step to change static_cast with toSVGXXX, static_cast<SVGUseElement*> can
1881         be changed with toSVGUseElement().
1882
1883         No new tests, no behavior change.
1884
1885         * dom/EventRetargeter.h:
1886         (WebCore::EventRetargeter::eventTargetRespectingTargetRules):
1887         * page/EventHandler.cpp:
1888         (WebCore::instanceAssociatedWithShadowTreeElement):
1889         * rendering/svg/RenderSVGResourceClipper.cpp:
1890         (WebCore::RenderSVGResourceClipper::drawContentIntoMaskImage):
1891         * rendering/svg/RenderSVGTransformableContainer.cpp:
1892         (WebCore::RenderSVGTransformableContainer::calculateLocalTransform):
1893         * svg/SVGStyledElement.cpp:
1894         (WebCore::SVGStyledElement::title):
1895         * svg/SVGUseElement.cpp:
1896         (WebCore::dumpInstanceTree):
1897         (WebCore::SVGUseElement::buildInstanceTree):
1898         (WebCore::SVGUseElement::expandUseElementsInShadowTree):
1899         * svg/SVGUseElement.h:
1900         (WebCore::toSVGUseElement):
1901
1902 2013-07-22  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1903
1904         Use toSVGPathElement() instead of static_cast<>
1905         https://bugs.webkit.org/show_bug.cgi?id=118960
1906
1907         Reviewed by Allan Sandfeld Jensen.
1908
1909         Though there is toSVGPathElement(), some files still use static_cast<SVGPathElement*>.
1910         To remove all static_cast<> use, we need to change argument from SVGElement to Element.
1911
1912         Merge from https://src.chromium.org/viewvc/blink?view=rev&revision=154621
1913
1914         No new tests, no behavior change.
1915
1916         * rendering/svg/RenderSVGTextPath.cpp:
1917         (WebCore::RenderSVGTextPath::layoutPath):
1918         * rendering/svg/SVGPathData.cpp:
1919         (WebCore::updatePathFromPathElement):
1920         * rendering/svg/SVGRenderTreeAsText.cpp:
1921         (WebCore::operator<<):
1922         * svg/SVGMPathElement.cpp:
1923         (WebCore::SVGMPathElement::pathElement):
1924         * svg/SVGPathElement.h:
1925         (WebCore::toSVGPathElement):
1926         * svg/SVGPathSegList.cpp:
1927         (WebCore::SVGPathSegList::commitChange):
1928         * svg/properties/SVGAnimatedPathSegListPropertyTearOff.h:
1929         (WebCore::SVGAnimatedPathSegListPropertyTearOff::animValDidChange):
1930         * svg/properties/SVGPathSegListPropertyTearOff.cpp:
1931         (WebCore::SVGPathSegListPropertyTearOff::contextElement):
1932
1933 2013-07-11  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1934
1935         [Qt] Implement more of DOM3 KeyEvent key-identifiers
1936         https://bugs.webkit.org/show_bug.cgi?id=118566
1937
1938         Reviewed by Jocelyn Turcotte.
1939
1940         Implemented as many of the key values from http://www.w3.org/TR/DOM-Level-3-Events/#key-values-list
1941         as Qt keycodes support.
1942
1943         Also corrected the mapping of the Menu key, which was confused because MENU
1944         is also the ancient Microsoft speak for the Alt keys.
1945
1946         * platform/qt/PlatformKeyboardEventQt.cpp:
1947         (WebCore::keyIdentifierForQtKeyCode):
1948
1949 2013-07-21  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1950
1951         Introduce toSVGGradientElement(), use it
1952         https://bugs.webkit.org/show_bug.cgi?id=118943
1953
1954         Reviewed by Andreas Kling.
1955
1956         As a step to change static_cast with toSVGXXX, static_cast<SVGGradientElement*> can
1957         be changed with toSVGGradientElement().
1958
1959         No new tests, no behavior change.
1960
1961         * rendering/svg/RenderSVGGradientStop.cpp:
1962         (WebCore::RenderSVGGradientStop::gradientElement):
1963         * rendering/svg/RenderSVGResourceGradient.cpp:
1964         (WebCore::RenderSVGResourceGradient::applyResource):
1965         * rendering/svg/SVGResources.cpp:
1966         (WebCore::targetReferenceFromResource):
1967         * svg/SVGGradientElement.h:
1968         (WebCore::toSVGGradientElement):
1969         * svg/SVGLinearGradientElement.cpp:
1970         (WebCore::SVGLinearGradientElement::collectGradientAttributes):
1971         * svg/SVGRadialGradientElement.cpp:
1972         (WebCore::SVGRadialGradientElement::collectGradientAttributes):
1973
1974 2013-07-21  Andreas Kling  <akling@apple.com>
1975
1976         KURL creates duplicate strings when completing data: URIs.
1977         <http://webkit.org/b/118952>
1978         <rdar://problem/14504480>
1979
1980         Reviewed by Anders Carlsson.
1981
1982         When checking if the original URL input string can be reused, compare against the part
1983         of the parsing buffer that we would actually return, not the entire buffer.
1984
1985         632 kB progression on <http://www.nytimes.com/>
1986
1987         Test: KURLTest.KURLDataURIStringSharing
1988
1989         * platform/KURL.cpp:
1990         (WebCore::KURL::parse):
1991
1992 2013-07-20  Benjamin Poulain  <benjamin@webkit.org>
1993
1994         Add ASCIILiteral() on strings allocated often enough to appear in my Instruments
1995         https://bugs.webkit.org/show_bug.cgi?id=118937
1996
1997         Reviewed by Alexey Proskuryakov.
1998
1999         * html/BaseCheckableInputType.cpp:
2000         (WebCore::BaseCheckableInputType::saveFormControlState):
2001         (WebCore::BaseCheckableInputType::fallbackValue):
2002         * html/HTMLTextFormControlElement.cpp:
2003         (WebCore::HTMLTextFormControlElement::updatePlaceholderVisibility):
2004         * inspector/InspectorApplicationCacheAgent.cpp:
2005         (WebCore::InspectorApplicationCacheAgent::InspectorApplicationCacheAgent):
2006         * loader/cache/CachedScript.cpp:
2007         (WebCore::CachedScript::CachedScript):
2008         * platform/network/ResourceRequestBase.h:
2009         (WebCore::ResourceRequestBase::ResourceRequestBase):
2010
2011 2013-07-20  Dean Jackson  <dino@apple.com>
2012
2013         Updated ANGLE is leaking like a sieve
2014         https://bugs.webkit.org/show_bug.cgi?id=118939
2015
2016         Rollout 152863, r152821, r152929 and r152755.
2017
2018         * CMakeLists.txt:
2019
2020 2013-07-19  Jer Noble  <jer.noble@apple.com>
2021
2022         Pagination: Do not paint the baseBackgroundColor if asked to skipRootBackground.
2023         https://bugs.webkit.org/show_bug.cgi?id=118933
2024
2025         Reviewed by Simon Fraser.
2026
2027         Captions rendered through TextTrackRepresentation are rendered with a background
2028         color when in paginated views. Do not fill the paint area with the
2029         baseBackgroundColor when the paint flags include SkipRootBackground.
2030
2031         * rendering/RenderView.cpp:
2032         (WebCore::RenderView::paint):
2033
2034 2013-07-19  Brady Eidson  <beidson@apple.com>
2035
2036         Pages should not be able to abuse users inside beforeunload handlers.
2037         <rdar://problem/14475779> and https://bugs.webkit.org/show_bug.cgi?id=118871.
2038
2039         Reviewed by Alexey Proskuryakov.
2040
2041         Tests: fast/loader/show-only-one-beforeunload-dialog.html
2042                http/tests/misc/iframe-beforeunload-dialog-matching-ancestor-securityorigin.html
2043                http/tests/misc/iframe-beforeunload-dialog-not-matching-ancestor-securityorigin.html
2044
2045         * loader/FrameLoader.cpp:
2046         (WebCore::FrameLoader::FrameLoader):
2047         (WebCore::FrameLoader::shouldClose):
2048         (WebCore::FrameLoader::handleBeforeUnloadEvent):
2049         (WebCore::FrameLoader::shouldCloseFiringBeforeUnloadEvent): Renamed from fireBeforeUnloadEvent.
2050           Add logic to enforce "1 beforeunload dialog per navigation" as well as "iframes can only show beforeunload 
2051           dialogs if their entire ancestry's security origins match the navigating frame."
2052         * loader/FrameLoader.h:
2053         * loader/FrameLoader.h:
2054
2055         Add the ability for Page to know when any frame is dispatching beforeunload:
2056         * page/Page.cpp:
2057         (WebCore::Page::Page):
2058         (WebCore::Page::incrementFrameHandlingBeforeUnloadEventCount):
2059         (WebCore::Page::decrementFrameHandlingBeforeUnloadEventCount):
2060         (WebCore::Page::isAnyFrameHandlingBeforeUnloadEvent):
2061         * page/Page.h:
2062
2063         * page/DOMWindow.cpp:
2064         (WebCore::DOMWindow::print): Disallow if any frame is in beforeunload dispatch.
2065         (WebCore::DOMWindow::alert): Ditto.
2066         (WebCore::DOMWindow::confirm): Ditto.
2067         (WebCore::DOMWindow::prompt): Ditto.
2068         (WebCore::DOMWindow::showModalDialog): Ditto.
2069
2070 2013-07-19  Chris Fleizach  <cfleizach@apple.com>
2071
2072         AX: VoiceOver not detecting misspelled words don't work in all cases
2073         https://bugs.webkit.org/show_bug.cgi?id=118924
2074
2075         Reviewed by Tim Horton.
2076
2077         VoiceOver is now looking for a new misspelled attribute.
2078
2079         * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
2080         (AXAttributeStringSetSpelling):
2081         (AXAttributedStringAppendText):
2082
2083 2013-07-19  Ryosuke Niwa  <rniwa@webkit.org>
2084
2085         Extract computeRenderStyleForProperty and nodeOrItsAncestorNeedsStyleRecalc from ComputedStyleExtractor::propertyValue
2086         https://bugs.webkit.org/show_bug.cgi?id=118930
2087
2088         Reviewed by Andreas Kling.
2089
2090         Extracted two functions as a preparation to fix bugs 118032 and 118618.
2091
2092         * css/CSSComputedStyleDeclaration.cpp:
2093         (WebCore::nodeOrItsAncestorNeedsStyleRecalc):
2094         (WebCore::computeRenderStyleForProperty):
2095         (WebCore::ComputedStyleExtractor::propertyValue):
2096
2097 2013-07-19  Andreas Kling  <akling@apple.com>
2098
2099         Cache style declaration CSSOM wrappers directly on MutableStylePropertySet.
2100         <http://webkit.org/b/118883>
2101
2102         Reviewed by Gavin Barraclough
2103
2104         Merge https://chromium.googlesource.com/chromium/blink/+/183bcd51eb0e79cab930cf46695df05dc793630f
2105         From Blink r153700 by <ager@chromium.org>:
2106
2107         In my measurements the mapping is adding more overhead than just having a field
2108         in all MutableStylePropertySet objects. So this saves memory and makes access
2109         faster.
2110
2111         * css/StylePropertySet.cpp:
2112         (WebCore::MutableStylePropertySet::MutableStylePropertySet):
2113         (WebCore::MutableStylePropertySet::~MutableStylePropertySet):
2114         (WebCore::StylePropertySet::hasCSSOMWrapper):
2115         (WebCore::MutableStylePropertySet::cssStyleDeclaration):
2116         (WebCore::MutableStylePropertySet::ensureCSSStyleDeclaration):
2117         (WebCore::MutableStylePropertySet::ensureInlineCSSStyleDeclaration):
2118         * css/StylePropertySet.h:
2119         (WebCore::StylePropertySet::StylePropertySet):
2120
2121 2013-07-19  Brent Fulgham  <bfulgham@apple.com>
2122
2123         [Windows] Avoid passing addresses of temporaries to Windows API.
2124         https://bugs.webkit.org/show_bug.cgi?id=118917
2125
2126         Reviewed by Anders Carlsson.
2127
2128         The temporary Vector returned by String::charactersWithNullTermination
2129         was going out of scope before its first use, causing Windows API to
2130         receive garbage memory.
2131
2132         * platform/win/ContextMenuWin.cpp:
2133         (WebCore::ContextMenu::createPlatformContextMenuFromItems):
2134         * platform/win/PasteboardWin.cpp:
2135         (WebCore::createGlobalHDropContent):
2136         * platform/win/SSLKeyGeneratorWin.cpp:
2137         (WebCore::WebCore::signedPublicKeyAndChallengeString):
2138
2139 2013-07-19  Zoltan Horvath  <zoltan@webkit.org>
2140
2141         [CSS Shapes] Remove lineWithinShapeBounds() from ShapeInfo since it's no longer used
2142         https://bugs.webkit.org/show_bug.cgi?id=118913
2143
2144         Reviewed by Andreas Kling.
2145
2146         No new tests, no behavior change.
2147
2148         * rendering/shapes/ShapeInfo.h: Remove lineWithinShapeBounds().
2149
2150 2013-07-19  Alex Christensen  <achristensen@apple.com>
2151
2152         Added x64 configuration to Visual Studio build.
2153         https://bugs.webkit.org/show_bug.cgi?id=118888
2154
2155         Reviewed by Brent Fulgham.
2156
2157         * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj:
2158         * WebCore.vcxproj/WebCore.vcxproj:
2159         * WebCore.vcxproj/WebCoreGenerated.vcxproj:
2160         * WebCore.vcxproj/WebCoreTestSupport.vcxproj:
2161
2162 2013-07-19  Abhijeet Kandalkar  <abhijeet.k@samsung.com>
2163
2164         Spatial Navigation handling of space key in <select> appears to confuse listIndex and optionIndex.
2165         https://bugs.webkit.org/show_bug.cgi?id=99525
2166
2167         HTMLSelect Element inherently contains the logic to focus option node and thus, implementing an explicit logic to find the focus index is not required.
2168
2169         Reviewed by Joseph Pecoraro.
2170
2171         Test: fast/spatial-navigation/snav-multiple-select-optgroup.html
2172
2173         * html/HTMLSelectElement.cpp:
2174         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
2175         * page/SpatialNavigation.cpp:
2176         (WebCore::canScrollInDirection):
2177         * rendering/RenderListBox.cpp:
2178         (WebCore::RenderListBox::addFocusRingRects):
2179
2180 2013-07-19  David Hyatt  <hyatt@apple.com>
2181
2182         OSX: ePub: Unable to select text in vertical Japanese book
2183         https://bugs.webkit.org/show_bug.cgi?id=118864
2184         <rdar://problem/14109351>
2185
2186         Reviewed by Dan Bernstein and Sam Weinig.
2187
2188         This patch fixes all of the various writing-mode and pagination combinations
2189         so that the columns are painted in the correct location. The code that sets up
2190         the initial painting translation offset in the block direction and that advances
2191         that offset has been pulled into two helper functions, initialBlockOffsetForPainting
2192         and blockDeltaForPaintingNextColumn, and that code is now shared by the four call
2193         sites that need it (painting and hit testing in RenderBlock and painting and hit testing
2194         in RenderLayer).
2195         
2196         This patch also backs out the maximumScrollPosition change, since it only occurred because
2197         of incorrect sizing of the RenderView, and this sizing issue has now been corrected by
2198         ensuring that computeLogicalHeight() always makes sure you are the size of the viewport
2199         and does not shrink you to the column height.
2200         
2201         There was also a race condition that caused pagination to be incorrect if layout occurred
2202         before the html/body renderer that set the writing-mode were available. When this happened,
2203         the writing mode got propagated up to the view, but the column styles didn't get
2204         adjusted to compensate for the writing mode change.
2205
2206         Added tests for every pagination and writing-mode combination in fast/multicol/pagination.
2207
2208         * css/StyleResolver.cpp:
2209         (WebCore::StyleResolver::styleForDocument):
2210         (WebCore::StyleResolver::adjustRenderStyle):
2211         Move setStylesForPaginationMode into RenderStyle and make it a member function. This is
2212         necessary so that the style can be adjusted dynamically to fix the race condition mentioned
2213         above.
2214
2215         * page/FrameView.cpp:
2216         (WebCore::FrameView::maximumScrollPosition):
2217         Back out this change since the symptom it was fixing only occurred because the logical
2218         height of the view was being set incorrectly.
2219
2220         * rendering/RenderBlock.cpp:
2221         (WebCore::RenderBlock::checkForPaginationLogicalHeightChange):
2222         Patch the column code that sets up the initial page height to use the pagination API's
2223         page height rather than the viewport logical height. This allows the view to still match
2224         the viewport in dimensions rather than being incorrectly sized to the column height.
2225         
2226         (WebCore::RenderBlock::initialBlockOffsetForPainting):
2227         (WebCore::RenderBlock::blockDeltaForPaintingNextColumn):
2228         Two new helper functions used to set up the block direction paint/hit testing translation.
2229         The major bug fix that occurred in this code is that the old block axis code didn't handle
2230         reversal correctly and it also used physical coordinates to try to determine the translation
2231         offset, when you really need to use logical coordinates in the original writing mode coordinate
2232         system to determine the offset.
2233
2234         (WebCore::RenderBlock::paintColumnContents):
2235         Patched to call the new helper functions.
2236
2237         (WebCore::ColumnRectIterator::ColumnRectIterator):
2238         (WebCore::ColumnRectIterator::adjust):
2239         (WebCore::ColumnRectIterator::update):
2240         Patched to call the new helper functions.
2241
2242         * rendering/RenderBlock.h:
2243         Add the two new helper functions to the RenderBlock header.
2244
2245         * rendering/RenderBox.cpp:
2246         (WebCore::RenderBox::styleDidChange):
2247         If the writing mode of the html/body propagates to the viewport and changes its writing mode,
2248         also change our column styles to match if we're in paginated mode.
2249
2250         (WebCore::RenderBox::computeLogicalHeight):
2251         (WebCore::RenderBox::computePercentageLogicalHeight):
2252         Call the new pageOrViewLogicalHeight function on RenderView instead of
2253         RenderBox::viewLogicalHeightForPercentages (which is now removed).
2254
2255         * rendering/RenderLayer.cpp:
2256         (WebCore::RenderLayer::paintChildLayerIntoColumns):
2257         (WebCore::RenderLayer::hitTestChildLayerColumns):
2258         Patched to use the two new helper functions for block direction paint offset setup and
2259         advancement.
2260
2261         * rendering/RenderView.cpp:
2262         (WebCore::RenderView::pageOrViewLogicalHeight):
2263         New helper function that does what viewLogicalHeightForPercentages used to do but also
2264         handles returning the page length for block axis column progression. Again, this is to
2265         allow the view to retain its correct size (matching the viewport).
2266
2267         (WebCore::RenderView::viewLogicalHeight):
2268         Back out the code that made the view grow or shrink to the size of the Pagination API page
2269         length when the progression was block axis. This was the source of most of the scroll origin
2270         and scrolling issues.
2271
2272         * rendering/RenderView.h:
2273         Add the new pageOrViewLogicalHeight() function.
2274
2275         * rendering/style/RenderStyle.cpp:
2276         (WebCore::RenderStyle::setColumnStylesFromPaginationMode):
2277         This is the old StyleResolver function for setting up the column styles. It's in RenderStyle
2278         now so that it can be called at any time to change a style rather than only at style resolution
2279         time.
2280
2281         * rendering/style/RenderStyle.h:
2282         Declaration of the setColumnStylesFromPaginationMode function.
2283
2284 2013-07-19  peavo@outlook.com  <peavo@outlook.com>
2285
2286         [Curl] Http response code 401 (Authentication required) is not handled.
2287         https://bugs.webkit.org/show_bug.cgi?id=118849
2288
2289         Reviewed by Brent Fulgham.
2290
2291         The current Curl implementation does not handle a 401 response.
2292         When receiving http code 401, we need to give a notification that authorization is required, by calling the appropriate notification method.
2293         This gives a WebKit client the possibility to present a password dialog to the user.
2294         In response to this, we should provide Curl with the given username and password, so another request can be sent with the given credentials.
2295
2296         * platform/network/ResourceHandle.h:
2297             Added method to check if credential storage should be used.
2298         * platform/network/ResourceHandleInternal.h:
2299             Added member to keep track of number of authentication failures.
2300         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
2301         * platform/network/curl/ResourceHandleCurl.cpp:
2302         (WebCore::ResourceHandle::shouldUseCredentialStorage):
2303             Added method to check if credential storage should be used.
2304         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge):
2305             Implement method; notify client when authentication is required.
2306         (WebCore::ResourceHandle::receivedCredential):
2307             Implement method; provide Curl with password and username when available.
2308         (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential):
2309             Implement method; reset Curl username and password.
2310         (WebCore::ResourceHandle::receivedCancellation):
2311             Implement method; notify client that authorization has been cancelled.
2312         * platform/network/curl/ResourceHandleManager.cpp:
2313         (WebCore::isHttpAuthentication):
2314             Added function to check if http code is an 'Authorization required' code.
2315         (WebCore::getProtectionSpace):
2316             Added function to initialize a protection space object from a Curl handle and a response object. 
2317         (WebCore::headerCallback):
2318             Notify client when authorization is required.
2319         (WebCore::ResourceHandleManager::applyAuthenticationToRequest):
2320             Added method to set Curl username and password.
2321         (WebCore::ResourceHandleManager::initializeHandle):
2322             Use method to set Curl username and password.
2323         * platform/network/curl/ResourceHandleManager.h:
2324             Added method to set Curl username and password.
2325
2326 2013-07-19  Radu Stavila  <stavila@adobe.com>
2327
2328         Hover doesn't work for block elements inside a href element
2329         https://bugs.webkit.org/show_bug.cgi?id=118907
2330
2331         Reviewed by David Hyatt.
2332
2333         Added test for hovering block elements inside a href element.
2334
2335         Test: fast/css/hover-display-block.html
2336
2337         * rendering/RenderObject.cpp:
2338         (WebCore::RenderObject::hoverAncestor):
2339
2340 2013-07-19  Zoltan Horvath  <zoltan@webkit.org>
2341
2342         [CSS Shapes] Clear overflowing line's segments in pushShapeContentOverflowBelowTheContentBox
2343         https://bugs.webkit.org/show_bug.cgi?id=118002
2344
2345         Reviewed by David Hyatt.
2346
2347         When the last line in the shape overlaps with the shape bottom boundaries we need to clear the computed segments. (We need to compute
2348         the segments anyway, since shape-outside's code uses the same code path to determine its segments and the line containing is not a
2349         requirement in that case.) Rather then doing the job in RenderBlock::LineBreaker::nextLineBreak I moved the functionality to its correct
2350         place to pushShapeContentOverflowBelowTheContentBox. Now all the overflow related functionality is located in one function. I fixed the
2351         corresponding layout test.
2352
2353         Tests: I modified shape-inside-overflow.html.
2354
2355         * rendering/RenderBlockLineLayout.cpp:
2356         (WebCore::pushShapeContentOverflowBelowTheContentBox): Remove segments if line overlaps with the shape's boundaries.
2357         (WebCore::RenderBlock::LineBreaker::nextLineBreak): Move segments clear logic to pushShapeContentOverflowBelowContentBox.
2358
2359 2013-07-19  Geoffrey Garen  <ggaren@apple.com>
2360
2361         TrailingObjects shouldn't shrink vector capacity in a loop
2362         https://bugs.webkit.org/show_bug.cgi?id=118322
2363
2364         Reviewed by Darin Adler.
2365
2366         This seems to take about 3% off the profile of loading a large text file.
2367
2368         * rendering/RenderBlockLineLayout.cpp:
2369         (WebCore::TrailingObjects::clear): clear() has the built-in side effect
2370         of throwing away existing capacity. Use shrink(0) to indicate that we
2371         want to keep our existing capacity.
2372
2373 2013-07-19  Diego Pino Garcia  <dpino@igalia.com>
2374
2375         [GTK] Merge decamelizations fix ups in the GObject DOM bindings code generator
2376         https://bugs.webkit.org/show_bug.cgi?id=117543
2377
2378         Reviewed by Carlos Garcia Campos.
2379
2380         Ensure that all the code that calls to decamelize() applies the same fix ups
2381
2382         Now all functions that need to decamelize a string should simply call
2383         to decamelize(). This function calls to FixUpDecamelize to apply some
2384         fix ups.
2385
2386         * bindings/scripts/CodeGeneratorGObject.pm:
2387         (decamelize): decamelizes a string and applies fix ups
2388         (FixUpDecamelize): applies a series of fix ups to a decamelized string
2389         (GetParentGObjType): moved fix ups to FixUpDecamelize()
2390         (GenerateProperties): simply call to decamelize
2391         (GenerateHeader): simply call to decamelize
2392         (GetGReturnMacro): simply call to decamelize
2393         (GenerateFunction): simply call to decamelize
2394         (GenerateCFile): simply call to decamelize
2395         (GenerateEventTargetIface): simply call to decamelize
2396
2397 2013-07-19  Kwang Yul Seo  <skyul@company100.net>
2398
2399         Unreviewed.
2400
2401         Fix an assertion failure which causes debug bots to fail.
2402
2403         * platform/network/NetworkStateNotifier.cpp:
2404         (WebCore::NetworkStateNotifier::addNetworkStateChangeListener):
2405
2406 2013-07-19  Miguel Gomez  <magomez@igalia.com>
2407
2408         [GTK] media/video-seek-multiple.html is failing
2409         https://bugs.webkit.org/show_bug.cgi?id=117580
2410
2411         Reviewed by Philippe Normand.
2412
2413         When receiving several seek calls in a row, ensure that the final position
2414         is the one requested in the last call received.
2415
2416         Already covered in test media/video-seek-multiple.html
2417
2418         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2419         (WebCore::MediaPlayerPrivateGStreamer::seek):
2420
2421 2013-07-19  Kangil Han  <kangil.han@samsung.com>
2422
2423         Use explicit HTMLFrameElementBase cast and introduce toHTMLFrameElementBase
2424         https://bugs.webkit.org/show_bug.cgi?id=118873
2425
2426         Reviewed by Ryosuke Niwa.
2427
2428         It should be HTMLFrameElementBase that embraces both HTMLFrameElement and HTMLIFrameElement.
2429         This also makes correct toFooElement possible.
2430         Next, to avoid direct use of static_cast, this patch introduces toHTMLFrameElementBase for code cleanup.
2431
2432         * editing/FrameSelection.cpp:
2433         (WebCore::scanForForm):
2434         * html/HTMLBodyElement.cpp:
2435         (WebCore::HTMLBodyElement::didNotifySubtreeInsertions):
2436         * html/HTMLFrameElementBase.h:
2437         (WebCore::toHTMLFrameElementBase):
2438         * loader/SubframeLoader.cpp:
2439         (WebCore::SubframeLoader::loadSubframe):
2440         * page/EventHandler.cpp:
2441         (WebCore::targetIsFrame):
2442         * page/FrameView.cpp:
2443         (WebCore::FrameView::init):
2444         * rendering/RenderFrameBase.cpp:
2445         (WebCore::RenderFrameBase::layoutWithFlattening):
2446         * rendering/RenderLayer.cpp:
2447         (WebCore::frameElementAndViewPermitScroll):
2448         (WebCore::RenderLayer::scrollRectToVisible):
2449
2450 2013-07-18  Christophe Dumez  <ch.dumez@sisa.samsung.com>
2451
2452         Bindings generation tests are failing
2453         https://bugs.webkit.org/show_bug.cgi?id=118877
2454
2455         Reviewed by Kentaro Hara.
2456
2457         I inadvertently removed the wrong part of the if statement
2458         in r152845, causing hasAttribute() to be used unconditionally
2459         for reflected boolean attributes instead of fastHasAttribute().
2460         This patch fixes the issue.
2461
2462         No new tests, covered by bindings tests.
2463
2464         * bindings/scripts/CodeGenerator.pm:
2465         (GetterExpression):
2466
2467 2013-07-18  Kwang Yul Seo  <skyul@company100.net>
2468
2469         WorkerGlobalScope should support onoffline/ononline event handlers
2470         https://bugs.webkit.org/show_bug.cgi?id=118832
2471
2472         Reviewed by Alexey Proskuryakov.
2473
2474         HTML5 spec says that WorkerGlobalScope should support
2475         onoffline/ononline event handlers as stated in
2476         http://www.whatwg.org/specs/web-apps/current-work/multipage/offline.html#event-offline
2477
2478         Modified NetworkStateNotifier to support multiple callbacks and added a
2479         callback to dispatch offline and online events to WorkerGlobalScope
2480         when network state is changed.
2481
2482         No new test because the current test infrastructure does not provide a
2483         mock network state notifier.
2484
2485         * page/Page.cpp:
2486         (WebCore::networkStateChanged):
2487         Change the function to take an additional argument, isOnLine so that we
2488         can remove a call to NetworkStateNotifier::onLine().
2489         (WebCore::Page::Page):
2490         Use NetworkStateNotifier::addNetworkStateChangeListener which
2491         allows us to add multiple callbacks.
2492
2493         * platform/network/NetworkStateNotifier.cpp:
2494         (WebCore::NetworkStateNotifier::addNetworkStateChangeListener):
2495         Replace NetworkStateNotifier::setNetworkStateChangedFunction with
2496         NetworkStateNotifier::addNetworkStateChangeListener.
2497         (WebCore::NetworkStateNotifier::notifyNetworkStateChange):
2498         A helper method to notify all registered network state change
2499         callbacks.
2500         * platform/network/NetworkStateNotifier.h:
2501         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
2502         * platform/network/blackberry/NetworkStateNotifierBlackBerry.cpp:
2503         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
2504         (WebCore::NetworkStateNotifier::networkStateChange):
2505         * platform/network/efl/NetworkStateNotifierEfl.cpp:
2506         (WebCore::NetworkStateNotifier::networkInterfaceChanged):
2507         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
2508         * platform/network/mac/NetworkStateNotifierMac.cpp:
2509         (WebCore::NetworkStateNotifier::networkStateChangeTimerFired):
2510         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
2511         * platform/network/qt/NetworkStateNotifierQt.cpp:
2512         (WebCore::NetworkStateNotifier::updateState):
2513         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
2514         * platform/network/win/NetworkStateNotifierWin.cpp:
2515         (WebCore::NetworkStateNotifier::addressChanged):
2516         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
2517         Replace m_networkStateChangedFunction() with notifyNetworkStateChange().
2518
2519         * workers/Worker.cpp:
2520         (WebCore::networkStateChanged):
2521         Notify network state change by iterating all Workers.
2522         (WebCore::Worker::Worker):
2523         Initialize allWorkers and add networkStateChanged to
2524         NetworkStateNotifier in first invocation. Add this Worker to
2525         allWorkers.
2526         (WebCore::Worker::~Worker):
2527         Remove this Worker from allWorkers.
2528         (WebCore::Worker::notifyNetworkStateChange):
2529         * workers/Worker.h:
2530         * workers/WorkerGlobalScope.h:
2531         Add onoffline and ononline event handlers.
2532         * workers/WorkerGlobalScope.idl:
2533         Add onoffline and ononline event handlers
2534         * workers/WorkerGlobalScopeProxy.h:
2535
2536         * workers/WorkerMessagingProxy.cpp:
2537         (WebCore::NotifyNetworkStateChangeTask::create):
2538         (WebCore::NotifyNetworkStateChangeTask::NotifyNetworkStateChangeTask):
2539         (WebCore::NotifyNetworkStateChangeTask::performTask):
2540         A subclass of ScriptExecutionContext::Task to dispatch offline and
2541         online events to WorkerGlobalScope.
2542         (WebCore::WorkerMessagingProxy::notifyNetworkStateChange):
2543         Notify network state change using ScriptExecutionContext::postTask to
2544         dispatch events across threads.
2545         * workers/WorkerMessagingProxy.h:
2546
2547 2013-07-18  Ryosuke Niwa  <rniwa@webkit.org>
2548
2549         Build fix after r152876.
2550
2551         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
2552         (WebCore::MediaPlayerPrivateAVFoundation::processNewAndRemovedTextTracks):
2553
2554 2013-07-18  Brent Fulgham  <bfulgham@apple.com>
2555
2556         [Media] Share more code between Mac and Windows implementation files.
2557         https://bugs.webkit.org/show_bug.cgi?id=118801
2558
2559         Reviewed by Eric Carlson.
2560
2561         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
2562         (WebCore::MediaPlayerPrivateAVFoundation::clearTextTracks): Move
2563         implementation from ObjC file to parent file.
2564         (WebCore::MediaPlayerPrivateAVFoundation::processNewAndRemovedTextTracks):
2565         Ditto.
2566         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
2567         Remove duplicate implementation.
2568         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
2569         Ditto.
2570         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
2571         Ditto.
2572         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
2573         Ditto.
2574         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
2575         Ditto.
2576
2577 2013-07-18  Alex Christensen  <achristensen@apple.com>
2578
2579         Fixed compile errors for non-Cairo platforms using EGL.
2580         https://bugs.webkit.org/show_bug.cgi?id=118536
2581
2582         Reviewed by Brent Fulgham.
2583
2584         * platform/graphics/egl/GLContextEGL.cpp: Added #if USE(CAIRO) around cairo.h.
2585         (WebCore::GLContextEGL::~GLContextEGL): Added #if USE(CAIRO) around cairo_device_destroy call. 
2586
2587 2013-07-18  Jer Noble  <jer.noble@apple.com>
2588
2589         New PDFPlugin doesn't support WebKitOmitPDFSupport, acts as if Plug-ins are off
2590         https://bugs.webkit.org/show_bug.cgi?id=118858
2591
2592         Reviewed by Eric Carlson.
2593
2594         Expand the scope of rejecting non video/ or audio/ MIME types when
2595         filling the MIME type cache.
2596
2597         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2598         (WebCore::shouldRejectMIMEType): Added utility function.
2599
2600 2013-07-17  Brent Fulgham  <bfulgham@apple.com>
2601
2602         [Windows] Support in-band text tracks.
2603         https://bugs.webkit.org/show_bug.cgi?id=103770
2604
2605         Reviewed by Eric Carlson.
2606
2607         Existing media tests cover these features.
2608
2609         * WebCore.vcxproj/WebCore.vcxproj: Add new files for Windows captions
2610         * WebCore.vcxproj/WebCore.vcxproj.filters: ditto.
2611         * config.h: Make sure proper buid flags are turned on when building
2612         with AVCF_LEGIBLE_OUTPUT.
2613         * page/CaptionUserPreferencesMediaAF.cpp: Revise to reduce soft linking
2614         duplication between Mac and Windows.
2615         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp: Update
2616         to support Windows platform by removing compiler guards and adding
2617         Windows declarations for soft-link functions.
2618         * platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h: Ditto.
2619         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
2620         Remove build guards preventing Windows from using LegibleOutput
2621         features.
2622         (WebCore::MediaPlayerPrivateAVFoundation::MediaPlayerPrivateAVFoundation):
2623         (WebCore::MediaPlayerPrivateAVFoundation::seek):
2624         (WebCore::MediaPlayerPrivateAVFoundation::seekCompleted):
2625         (WebCore::MediaPlayerPrivateAVFoundation::dispatchNotification):
2626         (WebCore::MediaPlayerPrivateAVFoundation::trackModeChanged):
2627         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
2628         (WebCore::MediaPlayerPrivateAVFoundation::contentsNeedsDisplay): Ditto
2629         * platform/graphics/avfoundation/cf/AVFoundationCFSoftLinking.h:
2630         Add new LegibleOutput support functions, and try to reduce duplication
2631         between Windows and Mac soft link declarations.
2632         * platform/graphics/avfoundation/cf/CoreMediaSoftLinking.h: Ditto.
2633         * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.cpp: Added.
2634         (WebCore::InbandTextTrackPrivateAVCF::InbandTextTrackPrivateAVCF):
2635         (WebCore::InbandTextTrackPrivateAVCF::disconnect):
2636         (WebCore::InbandTextTrackPrivateAVCF::kind):
2637         (WebCore::InbandTextTrackPrivateAVCF::isClosedCaptions):
2638         (WebCore::InbandTextTrackPrivateAVCF::isSDH):
2639         (WebCore::InbandTextTrackPrivateAVCF::containsOnlyForcedSubtitles):
2640         (WebCore::InbandTextTrackPrivateAVCF::isMainProgramContent):
2641         (WebCore::InbandTextTrackPrivateAVCF::isEasyToRead):
2642         (WebCore::InbandTextTrackPrivateAVCF::label):
2643         (WebCore::InbandTextTrackPrivateAVCF::language):
2644         (WebCore::InbandTextTrackPrivateAVCF::isDefault):
2645         * platform/graphics/avfoundation/cf/InbandTextTrackPrivateAVCF.h: Added.
2646         (WebCore::InbandTextTrackPrivateAVCF::create):
2647         (WebCore::InbandTextTrackPrivateAVCF::~InbandTextTrackPrivateAVCF):
2648         (WebCore::InbandTextTrackPrivateAVCF::mediaSelectionOption):
2649         * platform/graphics/avfoundation/cf/InbandTextTrackPrivateLegacyAVCF.cpp: Added.
2650         (WebCore::InbandTextTrackPrivateLegacyAVCF::InbandTextTrackPrivateLegacyAVCF):
2651         (WebCore::InbandTextTrackPrivateLegacyAVCF::disconnect):
2652         (WebCore::InbandTextTrackPrivateLegacyAVCF::kind):
2653         (WebCore::InbandTextTrackPrivateLegacyAVCF::isClosedCaptions):
2654         (WebCore::InbandTextTrackPrivateLegacyAVCF::containsOnlyForcedSubtitles):
2655         (WebCore::InbandTextTrackPrivateLegacyAVCF::isMainProgramContent):
2656         (WebCore::InbandTextTrackPrivateLegacyAVCF::isEasyToRead):
2657         (WebCore::InbandTextTrackPrivateLegacyAVCF::label):
2658         (WebCore::InbandTextTrackPrivateLegacyAVCF::language):
2659         * platform/graphics/avfoundation/cf/InbandTextTrackPrivateLegacyAVCF.h: Added.
2660         (WebCore::InbandTextTrackPrivateLegacyAVCF::create):
2661         (WebCore::InbandTextTrackPrivateLegacyAVCF::~InbandTextTrackPrivateLegacyAVCF):
2662         (WebCore::InbandTextTrackPrivateLegacyAVCF::avPlayerItemTrack):
2663         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
2664         Update to support LegibleOutput features for the Windows port.
2665         (WebCore::AVFWrapper::currentTrack): Added.
2666         (WebCore::AVFWrapper::legibleOutput): Added.
2667         (WebCore::createMetadataKeyNames): Added missing key names.
2668         (WebCore::avLegibleOutput): Added.
2669         (WebCore::safeMediaSelectionGroupForLegibleMedia): Added.
2670         (WebCore::MediaPlayerPrivateAVFoundationCF::cancelLoad): Clear text
2671         tracks when cancelling.
2672         (WebCore::MediaPlayerPrivateAVFoundationCF::setCurrentTrack): Added.
2673         (WebCore::MediaPlayerPrivateAVFoundationCF::currentTrack): Added.
2674         (WebCore::MediaPlayerPrivateAVFoundationCF::platformDuration): Revised
2675         to match logic in Objective C implementation.
2676         (WebCore::MediaPlayerPrivateAVFoundationCF::currentTime): Revised
2677         to match logic in Objective C implementation.
2678         (WebCore::MediaPlayerPrivateAVFoundationCF::paintCurrentFrameInContext):
2679         Check presence of metadata before proceeding. Revised to match logic
2680         in Objective C implementation.
2681         (WebCore::MediaPlayerPrivateAVFoundationCF::paint): Ditto.
2682         (WebCore::MediaPlayerPrivateAVFoundationCF::tracksChanged): Update for
2683         in-band text tracks.
2684         (WebCore::MediaPlayerPrivateAVFoundationCF::clearTextTracks): Added.
2685         (WebCore::MediaPlayerPrivateAVFoundationCF::processLegacyClosedCaptionsTracks):
2686         Added.
2687         (WebCore::MediaPlayerPrivateAVFoundationCF::processNewAndRemovedTextTracks):
2688         Added.
2689         (WebCore::MediaPlayerPrivateAVFoundationCF::processMediaSelectionOptions):
2690         Added.
2691         (WebCore::AVFWrapper::setCurrentTrack): Added.
2692         (WebCore::MediaPlayerPrivateAVFoundationCF::languageOfPrimaryAudioTrack):
2693         Added.
2694         (WebCore::AVFWrapper::AVFWrapper): Add new initializers.
2695         (WebCore::AVFWrapper::~AVFWrapper): Clean up text track information.
2696         (WebCore::AVFWrapper::createPlayer): Add Legible Output support.
2697         (WebCore::AVFWrapper::createPlayerItem): Ditto.
2698         (WebCore::LegibleOutputData::LegibleOutputData): Added.
2699         (WebCore::AVFWrapper::processCue): Added.
2700         (WebCore::AVFWrapper::legibleOutputCallback): Added.
2701         (WebCore::AVFWrapper::safeMediaSelectionGroupForLegibleMedia): Added.
2702         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h:
2703         Update to support LegibleOutput features for the Windows port.
2704         * platform/win/SoftLinking.h: Change signature of variable accessor
2705         to match Mac so reduce duplicate code.
2706
2707 2013-07-18  Christophe Dumez  <ch.dumez@sisa.samsung.com>
2708
2709         Make atob() / btoa() argument non optional
2710         https://bugs.webkit.org/show_bug.cgi?id=118844
2711
2712         Reviewed by Kentaro Hara.
2713
2714         According to the latest specification, the argument to atob() / btoa()
2715         should not be optional:
2716         http://www.whatwg.org/specs/web-apps/current-work/multipage/webappapis.html#windowbase64
2717
2718         This patch makes WebKit behave according to the specification. The argument
2719         is also mandatory in Firefox, IE10 and Blink.
2720
2721         atob() / btoa() are also moved to their own WindowBase64 interface which
2722         the Window interface implements. This does not change the behavior but
2723         this is closer to the specification and it will make exposing those
2724         methods to workers easier later on.
2725
2726         No new tests, already covered by:
2727         fast/dom/Window/atob-btoa.html
2728
2729         * CMakeLists.txt:
2730         * DerivedSources.make:
2731         * DerivedSources.pri:
2732         * GNUmakefile.list.am:
2733         * page/DOMWindow.idl:
2734         * page/WindowBase64.idl: Added.
2735
2736 2013-07-18  Antoine Quint  <graouts@apple.com>
2737
2738         Crash in WebCore::createMarkup()
2739         https://bugs.webkit.org/show_bug.cgi?id=118847
2740
2741         Reviewed by Ryosuke Niwa.
2742
2743         Also check that we have a containingBlock() for the renderer() so that we
2744         may safely call node() on it.
2745
2746         * editing/markup.cpp:
2747         (WebCore::highestAncestorToWrapMarkup):
2748
2749 2013-07-18  Praveen R Jadhav  <praveen.j@samsung.com>
2750
2751         Only the first call to 'stop' method of AudioBufferSourceNode must be entertained.
2752         https://bugs.webkit.org/show_bug.cgi?id=118776
2753
2754         Reviewed by Jer Noble.
2755
2756         Subsequent calls to 'stop' for a AudioSourceBufferNode throws an exception.
2757         End time set by first 'stop' method is used for processing.
2758
2759         No new tests. audiobuffersource-exception.html is updated.
2760
2761         * Modules/webaudio/AudioScheduledSourceNode.cpp:
2762         (WebCore::AudioScheduledSourceNode::stop):
2763
2764 2013-07-18  Christophe Dumez  <ch.dumez@sisa.samsung.com>
2765
2766         Simplify SVG animated type handling in the JSC bindings generator
2767         https://bugs.webkit.org/show_bug.cgi?id=118845
2768
2769         Reviewed by Kentaro Hara.
2770
2771         Simplify IsSVGAnimatedType subroutine in the bindings generator so that
2772         we no longer need to hardcode SVG animated types. Also remove the
2773         CanUseFastAttribute subroutine as it is equivalent to IsSVGAnimatedType.
2774         This allows us to simplify the GetterExpression subroutine so that
2775         we can use fastHasAttribute() unconditionally for boolean type.
2776
2777         No new tests, no behavior change.
2778
2779         * bindings/scripts/CodeGenerator.pm:
2780         (IsSVGAnimatedType):
2781         (GetterExpression):
2782
2783 2013-07-18  Christophe Dumez  <ch.dumez@sisa.samsung.com>
2784
2785         Use [ImplementedAs] instead of special casing in the bindings generators
2786         https://bugs.webkit.org/show_bug.cgi?id=118848
2787
2788         Reviewed by Kentaro Hara.
2789
2790         In several instances, special casing were used in the bindings generator to avoid
2791         name clashes in the implementation. The [ImplementedBy] IDL extended attribute is
2792         meant to solve this issue so we now use it instead.
2793
2794         No new tests, no behavior change.
2795
2796         * bindings/scripts/CodeGenerator.pm:
2797         (WK_ucfirst):
2798         (AttributeNameForGetterAndSetter):
2799         * bindings/scripts/CodeGeneratorJS.pm:
2800         (GenerateImplementation):
2801         (NativeToJSValue):
2802         * bindings/scripts/CodeGeneratorObjC.pm:
2803         (GenerateHeader):
2804         (GenerateImplementation):
2805         * svg/SVGAElement.idl:
2806         * svg/SVGFECompositeElement.cpp:
2807         (WebCore::SVGFECompositeElement::SVGFECompositeElement):
2808         (WebCore::SVGFECompositeElement::parseAttribute):
2809         (WebCore::SVGFECompositeElement::setFilterEffectAttribute):
2810         (WebCore::SVGFECompositeElement::build):
2811         * svg/SVGFECompositeElement.h:
2812         * svg/SVGFECompositeElement.idl:
2813         * svg/SVGFEMorphologyElement.cpp:
2814         (WebCore::SVGFEMorphologyElement::SVGFEMorphologyElement):
2815         (WebCore::SVGFEMorphologyElement::parseAttribute):
2816         (WebCore::SVGFEMorphologyElement::setFilterEffectAttribute):
2817         (WebCore::SVGFEMorphologyElement::build):
2818         * svg/SVGFEMorphologyElement.h:
2819         * svg/SVGFEMorphologyElement.idl:
2820         * svg/SVGTransform.cpp:
2821         (WebCore::SVGTransform::updateSVGMatrix):
2822         * svg/SVGTransform.h:
2823         * svg/SVGTransform.idl:
2824
2825 2013-07-18  Zalan Bujtas  <zalan@apple.com>
2826
2827         Incorrect calculated width for mspace.
2828         https://bugs.webkit.org/show_bug.cgi?id=118601
2829
2830         Reviewed by Chris Fleizach.
2831
2832         Use intrinsic logical widths to size <mspace> properly.
2833         This patch also fixes an assert on isPreferredLogicalHeightDirty() which occurs
2834         while layouting <mspace>. The assert fix is required, so that the sizing can be
2835         fixed.
2836
2837         Test: mathml/presentation/mspace-prefered-width.html
2838
2839         * rendering/mathml/RenderMathMLBlock.cpp:
2840         (WebCore::parseMathMLLength): switch to LayoutUnits.
2841         (WebCore::parseMathMLNamedSpace): switch to LayoutUnits.
2842         * rendering/mathml/RenderMathMLBlock.h:
2843         * rendering/mathml/RenderMathMLFraction.cpp:
2844         (WebCore::RenderMathMLFraction::updateFromElement):
2845         * rendering/mathml/RenderMathMLFraction.h:
2846         * rendering/mathml/RenderMathMLSpace.cpp:
2847         (WebCore::RenderMathMLSpace::computeIntrinsicLogicalWidths):
2848         * rendering/mathml/RenderMathMLSpace.h:
2849
2850 2013-07-18  Ryosuke Niwa  <rniwa@webkit.org>
2851
2852         willWriteSelectionToPasteboard and willPerformDragSourceAction editing callbacks are not called for drag and drop
2853         https://bugs.webkit.org/show_bug.cgi?id=118828
2854
2855         Reviewed by Gavin Barraclough.
2856
2857         Call these two callbacks when we start a drag and drop.
2858
2859         No new tests for now but we should start logging these callbacks in DRT and WTR's EditorClients.
2860
2861         * page/DragController.cpp:
2862         (WebCore::DragController::startDrag):
2863
2864 2013-07-18  Santosh Mahto  <santosh.ma@samsung.com>
2865
2866         ASSERTION FAILED: !listItems().size() || m_activeSelectionAnchorIndex >= 0 in WebCore::HTMLSelectElement::updateListBoxSelection
2867         https://bugs.webkit.org/show_bug.cgi?id=118591
2868
2869         Reviewed by Kent Tamura.
2870
2871         Test: fast/forms/select/selectall-command-crash.html
2872
2873         * html/HTMLSelectElement.cpp:
2874         (WebCore::HTMLSelectElement::selectAll):
2875         We should return this function if activeSelectionAnchorIndex is not valid index
2876
2877 2013-07-18  Ryuan Choi  <ryuan.choi@samsung.com>
2878
2879         [EFL] Refactor spin.edc not to use offset
2880         https://bugs.webkit.org/show_bug.cgi?id=118830
2881
2882         Reviewed by Gyuyoung Kim.
2883
2884         EDJE allows offset to specify the pixel based position,
2885         but it's not good way if you want to locate object like arrow top or bottom.
2886
2887         Instead, this patch uses align property.
2888
2889         * platform/efl/DefaultTheme/widget/spinner/spinner.edc:
2890
2891 2013-07-18  Nick Diego Yamane  <nick.yamane@openbossa.org>
2892
2893         [gstreamer] Avoid calls to g_slist_index in webKitWebAudioSrcLoop()
2894         https://bugs.webkit.org/show_bug.cgi?id=118827
2895
2896         Reviewed by Philippe Normand.
2897
2898         webKitWebAudioSrcLoop() currently calls g_slist_index for each element 
2899         to get its index in a list it's iterating over. g_list_index function uses
2900         a sequential search to find that element, which is clearly unecessary.
2901         This patch adds a local variable to store the current index and use it 
2902         instead of calling g_slist_index function.
2903
2904         No new tests, no behavior changes.
2905
2906         * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
2907         (webKitWebAudioSrcLoop):
2908
2909 2013-07-17  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2910
2911         Introduce toSVGInlineFlowBox() and use it
2912         https://bugs.webkit.org/show_bug.cgi?id=118794
2913
2914         Reviewed by Andreas Kling.
2915
2916         As a step to change static_cast with toSVGXXX, static_cast<SVGInlineFlowBox*> can
2917         be changed with toSVGInlineFlowBox().
2918
2919         Blink merge from https://src.chromium.org/viewvc/blink?view=rev&revision=154385
2920
2921         No new tests, no behavior change.
2922
2923         * rendering/svg/SVGInlineFlowBox.cpp:
2924         (WebCore::SVGInlineFlowBox::paintSelectionBackground):
2925         * rendering/svg/SVGInlineFlowBox.h:
2926         (WebCore::toSVGInlineFlowBox):
2927         * rendering/svg/SVGRootInlineBox.cpp:
2928         (WebCore::SVGRootInlineBox::paint):
2929         (WebCore::SVGRootInlineBox::layoutCharactersInTextBoxes):
2930         (WebCore::SVGRootInlineBox::layoutChildBoxes):
2931
2932 2013-07-17  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2933
2934         Use toSVGMarkerElement() instead of static_cast<>
2935         https://bugs.webkit.org/show_bug.cgi?id=118800
2936
2937         Reviewed by Andreas Kling.
2938
2939         Though there is toSVGMarkerElement(), some files still use static_cast<SVGMarkerElement*>.
2940         To remove all static_cast<> use, we need to change argument from SVGElement to Node.
2941
2942         No new tests, no behavior changes.
2943
2944         * rendering/svg/RenderSVGResourceMarker.cpp:
2945         (WebCore::RenderSVGResourceMarker::referencePoint):
2946         (WebCore::RenderSVGResourceMarker::angle):
2947         (WebCore::RenderSVGResourceMarker::markerTransformation):
2948         (WebCore::RenderSVGResourceMarker::viewportTransform):
2949         (WebCore::RenderSVGResourceMarker::calcViewport):
2950         * rendering/svg/RenderSVGResourceMarker.h:
2951         (WebCore::RenderSVGResourceMarker::markerUnits):
2952         * svg/SVGMarkerElement.h:
2953         (WebCore::toSVGMarkerElement):
2954
2955 2013-07-17  Jacky Jiang  <zhajiang@blackberry.com>
2956
2957         Dereference null pointer crash in Length::decrementCalculatedRef()
2958         https://bugs.webkit.org/show_bug.cgi?id=118686
2959
2960         Reviewed by Simon Fraser.
2961
2962         Length(Calculated) won't insert any CalculationValue to CalculationValueHandleMap;
2963         therefore, we dereference null CalculationValue pointer when the temporary
2964         Length object goes out of the scope.
2965         Length(Calculated) is not allowed as it doesn't make sense that we construct
2966         a Calculated Length object with uninitialized calc expression.
2967         The code just wants to blend with zero. To fix the bug, we can just blend
2968         with Length(0, Fixed) here as we currently can blend different type units
2969         and zero has the same behavior regardless of unit.
2970
2971         Test: transitions/transition-transform-translate-calculated-length-crash.html
2972
2973         * platform/graphics/transforms/TranslateTransformOperation.cpp:
2974         (WebCore::TranslateTransformOperation::blend):
2975
2976 2013-07-17  Tim Horton  <timothy_horton@apple.com>
2977
2978         Update blocked/missing plug-in UI
2979         https://bugs.webkit.org/show_bug.cgi?id=118347
2980         <rdar://problem/14209318>
2981
2982         Reviewed by Sam Weinig.
2983
2984         * WebCore.exp.in:
2985         Export RenderEmbeddedObject::setPluginUnavailabilityReasonWithDescription.
2986
2987         * rendering/RenderEmbeddedObject.cpp:
2988         (WebCore::replacementTextRoundedRectPressedColor):
2989         (WebCore::replacementTextRoundedRectColor):
2990         (WebCore::replacementTextColor):
2991         Change colors to new design and add some more constants.
2992
2993         (WebCore::shouldUnavailablePluginMessageBeButton): Added.
2994
2995         (WebCore::RenderEmbeddedObject::setPluginUnavailabilityReasonWithDescription): Added.
2996         (WebCore::RenderEmbeddedObject::setPluginUnavailabilityReason):
2997         Call through to the -WithDescription variant.
2998
2999         (WebCore::RenderEmbeddedObject::paintReplaced):
3000         Fill the background, and otherwise match the new design.
3001
3002         (WebCore::addReplacementArrowPath):
3003         Add an arrow to the given path, inside the given rect.
3004
3005         (WebCore::RenderEmbeddedObject::getReplacementTextGeometry):
3006         Add a 1px padding to the bottom of the text.
3007         Add a circle and an arrow into the indicator as per the new design.
3008
3009         (WebCore::RenderEmbeddedObject::isInUnavailablePluginIndicator):
3010         Hit-test the indicator arrow as well; otherwise, the fact that the arrow
3011         is a hole in the path means it won't be hit.
3012
3013         * rendering/RenderEmbeddedObject.h:
3014
3015 2013-07-17  Commit Queue  <commit-queue@webkit.org>
3016
3017         Unreviewed, rolling out r152701, r152703, r152739, r152754,
3018         and r152756.
3019         http://trac.webkit.org/changeset/152701
3020         http://trac.webkit.org/changeset/152703
3021         http://trac.webkit.org/changeset/152739
3022         http://trac.webkit.org/changeset/152754
3023         http://trac.webkit.org/changeset/152756
3024         https://bugs.webkit.org/show_bug.cgi?id=118821
3025
3026         this was a buggy fix and we're going to try something
3027         different (Requested by thorton on #webkit).
3028
3029         * CMakeLists.txt:
3030         * DerivedSources.make:
3031         * DerivedSources.pri:
3032         * GNUmakefile.am:
3033         * WebCore.exp.in:
3034         * WebCore.vcxproj/WebCore.vcxproj:
3035         * WebCore.vcxproj/WebCore.vcxproj.filters:
3036         * WebCore.xcodeproj/project.pbxproj:
3037         * css/CSSDefaultStyleSheets.cpp:
3038         (WebCore::CSSDefaultStyleSheets::ensureDefaultStyleSheetsForElement):
3039         * css/unavailablePlugIns.css: Removed.
3040         * dom/EventListener.h:
3041         * html/HTMLAppletElement.cpp:
3042         (WebCore::HTMLAppletElement::updateWidget):
3043         * html/HTMLPlugInElement.cpp:
3044         (WebCore::HTMLPlugInElement::defaultEventHandler):
3045         * html/HTMLPlugInImageElement.cpp:
3046         (WebCore::HTMLPlugInImageElement::didAddUserAgentShadowRoot):
3047         * loader/SubframeLoader.cpp:
3048         (WebCore::SubframeLoader::createJavaAppletWidget):
3049         * page/ChromeClient.h:
3050         (WebCore::ChromeClient::shouldUnavailablePluginMessageBeButton):
3051         * rendering/RenderEmbeddedObject.cpp:
3052         (WebCore::replacementTextRoundedRectPressedColor):
3053         (WebCore::RenderEmbeddedObject::RenderEmbeddedObject):
3054         (WebCore::RenderEmbeddedObject::setPluginUnavailabilityReason):
3055         (WebCore::RenderEmbeddedObject::setUnavailablePluginIndicatorIsPressed):
3056         (WebCore::RenderEmbeddedObject::paint):
3057         (WebCore::RenderEmbeddedObject::paintReplaced):
3058         (WebCore::RenderEmbeddedObject::getReplacementTextGeometry):
3059         (WebCore::RenderEmbeddedObject::replacementTextRect):
3060         (WebCore::RenderEmbeddedObject::isReplacementObscured):
3061         (WebCore::RenderEmbeddedObject::layout):
3062         (WebCore::RenderEmbeddedObject::isInUnavailablePluginIndicator):
3063         (WebCore::shouldUnavailablePluginMessageBeButton):
3064         (WebCore::RenderEmbeddedObject::handleUnavailablePluginIndicatorEvent):
3065         (WebCore::RenderEmbeddedObject::getCursor):
3066         (WebCore::RenderEmbeddedObject::canHaveChildren):
3067         * rendering/RenderEmbeddedObject.h:
3068         * rendering/RenderWidget.h:
3069
3070 2013-07-17  Simon Fraser  <simon.fraser@apple.com>
3071
3072         Optimize RenderLayerCompositor's OverlapMap
3073         https://bugs.webkit.org/show_bug.cgi?id=118764
3074
3075         Reviewed by Tim Horton.
3076
3077         Overlap stack items can have RectLists with hundreds of rectangles.
3078         This makes the linear search in OverlapMap::overlapsLayers() very slow.
3079         
3080         Optimize by storing the bounding rect of the list of rects, and doing an early
3081         check on that. This reduces time spent in RenderLayer::scrollTo() by 13% in some
3082         content with lots of layers inside an overflow:scroll.
3083
3084         * rendering/RenderLayerCompositor.cpp:
3085         (WebCore::RenderLayerCompositor::OverlapMap::overlapsLayers):
3086         (WebCore::RenderLayerCompositor::OverlapMap::popCompositingContainer):
3087         (WebCore::RenderLayerCompositor::OverlapMap::RectList::append):
3088         (WebCore::RenderLayerCompositor::OverlapMap::RectList::intersects):
3089
3090 2013-07-17  Bem Jones-Bey  <bjonesbe@adobe.com>
3091
3092         [CSS Shapes] Port refactoring of shape-outside code from Blink
3093         https://bugs.webkit.org/show_bug.cgi?id=118757
3094
3095         Reviewed by Dean Jackson.
3096
3097         Refactor the left and right offset methods to reduce the number of
3098         arguments by splitting the methods into smaller methods. This
3099         refactoring was requested as part of porting support for stacked
3100         floats with shape-outside to Blink.
3101
3102         Also add a variable when calling computeSegmentsForLine to make it
3103         more readable and easier to follow the coordinate system change.
3104
3105         No new tests, no behavior change.
3106
3107         * rendering/RenderBlock.cpp:
3108         (WebCore::RenderBlock::computeLogicalLocationForFloat): Update to use
3109             the refactored IgnoringShapeOutside methods.
3110         (WebCore::RenderBlock::logicalLeftFloatOffsetForLine): New method to
3111             compute the offset contributed by left floats.
3112         (WebCore::RenderBlock::adjustLogicalLeftOffsetForLine): New method to
3113             compute misc adjustments to the left offset.
3114         (WebCore::RenderBlock::logicalRightFloatOffsetForLine): New method to
3115             compute the offset contributed by right floats.
3116         (WebCore::RenderBlock::adjustLogicalRightOffsetForLine): New method to
3117             compute misc adjustments to the right offset.
3118         * rendering/RenderBlock.h:
3119         (WebCore::RenderBlock::logicalRightOffsetForLine): Implement original
3120             method in terms of the float offset computation method and the
3121             offset adjustment method. This method takes into account the
3122             shape-outside on any floats when computing the offset.
3123         (WebCore::RenderBlock::logicalLeftOffsetForLine): Ditto.
3124         (WebCore::RenderBlock::logicalRightOffsetForLineIgnoringShapeOutside):
3125             Compute the right offset as if there was no shape-outside on any
3126             of the floats.
3127         (WebCore::RenderBlock::logicalLeftOffsetForLineIgnoringShapeOutside):
3128             Compute the left offset as if there was no shape-outside on any
3129             of the floats.
3130         * rendering/RenderBlockLineLayout.cpp:
3131         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded): Update
3132             to use a variable to make the calls to computeSegmentsForLine more
3133             explicit about the coordinate system conversion.
3134
3135 2013-07-17  Zalan Bujtas  <zalan@apple.com>
3136
3137         Wrong linebox height, when block element parent has vertical-align property defined.
3138         https://bugs.webkit.org/show_bug.cgi?id=118245
3139
3140         Reviewed by David Hyatt.
3141
3142         Do not push the current element to the next, when it is still considered empty, even with
3143         some object(s) in front. Behave as if it was actually empty.
3144         Inline elements like <span></span> generate such lines.
3145
3146         Test: fast/css/empty-span-with-parent-div-and-vertical-align.html
3147
3148         * rendering/RenderBlockLineLayout.cpp:
3149         (WebCore::RenderBlock::LineBreaker::nextSegmentBreak):
3150
3151 2013-07-17  Andreas Kling  <akling@apple.com>
3152
3153         CSS selector list splitting should be by component, not by selector.
3154         <http://webkit.org/b/118761>
3155         <rdar://problem/14421609>
3156
3157         Reviewed by Antti Koivisto.
3158
3159         Test (amended): fast/css/rule-selector-overflow.html
3160
3161         * css/CSSSelectorList.h:
3162         * css/CSSSelectorList.cpp:
3163         (WebCore::CSSSelectorList::CSSSelectorList):
3164         (WebCore::CSSSelectorList::componentCount):
3165         * css/CSSStyleRule.cpp:
3166         (WebCore::CSSStyleRule::setSelectorText):
3167
3168             Renamed CSSSelectorList::length() to componentCount() and made it public.
3169
3170         * css/RuleSet.h:
3171
3172             maximumSelectorCount => maximumSelectorComponentCount
3173
3174         * css/StyleRule.cpp:
3175         (WebCore::StyleRule::splitIntoMultipleRulesWithMaximumSelectorComponentCount):
3176
3177             Make the splits after accumulating 'maximumSelectorComponentCount' components.
3178
3179         * css/StyleRule.h:
3180         * css/StyleSheetContents.cpp:
3181         (WebCore::StyleSheetContents::parserAppendRule):
3182
3183             splitIntoMultipleRulesWithMaximumSelectorCount => splitIntoMultipleRulesWithMaximumSelectorComponentCount
3184
3185 2013-07-17  Rob Buis  <rwlbuis@webkit.org>
3186
3187         [Mac] REGRESSION(r152685): svg/custom/xlink-prefix-in-attributes.html failed unexpectedly
3188         https://bugs.webkit.org/show_bug.cgi?id=118701
3189
3190         Reviewed by Ryosuke Niwa.
3191
3192         Use the computed attribute prefix, otherwise href being in xlink namespace but not having any prefix
3193         will cause outputting the xlink namespace in appendNamespace.
3194
3195         Patch fixes svg/custom/xlink-prefix-in-attributes.html.
3196
3197         * editing/MarkupAccumulator.cpp:
3198         (WebCore::MarkupAccumulator::appendAttribute):
3199
3200 2013-07-17  Chris Fleizach  <cfleizach@apple.com>
3201
3202         Regression: columnheader/rowheader roles not exposed correctly
3203         https://bugs.webkit.org/show_bug.cgi?id=113628
3204
3205         Reviewed by Tim Horton.
3206
3207         When we determine the row and column headers we look at the ARIA role being returned, but
3208         since TableCell overrides the determineAccessibilityRole method, the ARIA role is never set.
3209
3210         Test: platform/mac/accessibility/aria-columnrowheaders.html
3211
3212         * accessibility/AccessibilityTableCell.cpp:
3213         (WebCore::AccessibilityTableCell::determineAccessibilityRole):
3214
3215 2013-07-17  Christophe Dumez  <ch.dumez@sisa.samsung.com>
3216
3217         Get rid of SVGPoint special case from the bindings generator
3218         https://bugs.webkit.org/show_bug.cgi?id=118783
3219
3220         Reviewed by Kentaro Hara.
3221
3222         Get rid of SVGPoint special case from the bindings generator by adding a
3223         new SVGPoint.h header that contains a typedef to FloatPoint.
3224
3225         Also use SVGPoint type in the implementation API for consistency with
3226         the IDL.
3227
3228         No new tests, no behavior change.
3229
3230         * bindings/scripts/CodeGenerator.pm:
3231         (SkipIncludeHeader):
3232         * bindings/scripts/test/JS/JSTestObj.cpp:
3233         (WebCore::jsTestObjMutablePoint):
3234         (WebCore::jsTestObjImmutablePoint):
3235         (WebCore::setJSTestObjMutablePoint):
3236         (WebCore::setJSTestObjImmutablePoint):
3237         (WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
3238         (WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
3239         * bindings/scripts/test/JS/JSTestTypedefs.cpp:
3240         (WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
3241         * bindings/scripts/test/ObjC/DOMTestObj.mm:
3242         (-[DOMTestObj mutablePoint]):
3243         (-[DOMTestObj immutablePoint]):
3244         (-[DOMTestObj mutablePointFunction]):
3245         (-[DOMTestObj immutablePointFunction]):
3246         * bindings/scripts/test/ObjC/DOMTestTypedefs.mm:
3247         (-[DOMTestTypedefs immutablePointFunction]):
3248         * rendering/svg/RenderSVGRoot.cpp:
3249         (WebCore::RenderSVGRoot::buildLocalToBorderBoxTransform):
3250         * rendering/svg/SVGTextQuery.cpp:
3251         (WebCore::SVGTextQuery::startPositionOfCharacter):
3252         (WebCore::SVGTextQuery::endPositionOfCharacter):
3253         (WebCore::SVGTextQuery::characterNumberAtPosition):
3254         * rendering/svg/SVGTextQuery.h:
3255         * svg/SVGPathElement.cpp:
3256         (WebCore::SVGPathElement::getPointAtLength):
3257         * svg/SVGPathElement.h:
3258         * svg/SVGPathTraversalStateBuilder.cpp:
3259         (WebCore::SVGPathTraversalStateBuilder::currentPoint):
3260         * svg/SVGPathTraversalStateBuilder.h:
3261         * svg/SVGPathUtilities.cpp:
3262         (WebCore::getPointAtLengthOfSVGPathByteStream):
3263         * svg/SVGPathUtilities.h:
3264         * svg/SVGPoint.h: Added.
3265         * svg/SVGPointList.cpp:
3266         (WebCore::SVGPointList::valueAsString):
3267         * svg/SVGPointList.h:
3268         * svg/SVGSVGElement.cpp:
3269         (WebCore::SVGSVGElement::createSVGPoint):
3270         * svg/SVGSVGElement.h:
3271         * svg/SVGTextContentElement.cpp:
3272         (WebCore::SVGTextContentElement::getStartPositionOfChar):
3273         (WebCore::SVGTextContentElement::getEndPositionOfChar):
3274         (WebCore::SVGTextContentElement::getCharNumAtPosition):
3275         * svg/SVGTextContentElement.h:
3276         * svg/SVGZoomEvent.cpp:
3277         (WebCore::SVGZoomEvent::previousTranslate):
3278         (WebCore::SVGZoomEvent::newTranslate):
3279         * svg/SVGZoomEvent.h:
3280
3281 2013-07-17  Carlos Garcia Campos  <cgarcia@igalia.com>
3282
3283         [GStreamer] webkitwebsrc: use SubResourceLoader
3284         https://bugs.webkit.org/show_bug.cgi?id=73743
3285
3286         Reviewed by Philippe Normand.
3287
3288         * GNUmakefile.list.am: Add new files to compilation.
3289         * PlatformEfl.cmake: Ditto.
3290         * PlatformGTK.cmake: Ditto.
3291         * loader/SubresourceLoader.h: Add getOrCreateReadBuffer() when
3292         using SOUP.
3293         * loader/cache/CachedRawResource.h:
3294         * loader/cache/CachedRawResourceClient.h:
3295         (WebCore::CachedRawResourceClient::getOrCreateReadBuffer): Added
3296         to allow the client to allocate the read buffer.
3297         * loader/cache/CachedResource.h:
3298         (WebCore::CachedResource::getOrCreateReadBuffer):
3299         * loader/soup/CachedRawResourceSoup.cpp: Added.
3300         (WebCore::CachedRawResource::getOrCreateReadBuffer): Iterate the
3301         clients until one returns a valid read buffer or return NULL to
3302         fallback to the default read buffer.
3303         * loader/soup/SubresourceLoaderSoup.cpp: Added.
3304         (WebCore::SubresourceLoader::getOrCreateReadBuffer): Call
3305         CachedResource::getOrCreateReadBuffer().
3306         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
3307         (StreamingClient): Make this a CachedRawResourceClient.
3308         (_WebKitWebSrcPrivate): Remove frame and resourceHandle and add a
3309         cached resource handle.
3310         (webKitWebSrcDispose): Clear the player pointer.
3311         (webKitWebSrcStop): Remove the client from the cached resource.
3312         (webKitWebSrcStart): Use CachedResourceLoader to schedule a
3313         CachedRawResource load for the media without buffering the data.
3314         (webKitWebSrcNeedDataMainCb): Call CachedResource::setDefersLoading.
3315         (webKitWebSrcEnoughDataMainCb): Ditto.
3316         (webKitWebSrcSetMediaPlayer): Simply update the player pointer.
3317         (StreamingClient::responseReceived): Update to the
3318         CachedRawResourceClient API.
3319         (StreamingClient::dataReceived): Ditto.
3320         (StreamingClient::getOrCreateReadBuffer): Ditto.
3321         (StreamingClient::notifyFinished): Ditto.
3322
3323 2013-07-17  Kwang Yul Seo  <skyul@company100.net>
3324
3325         Remove unused member variable m_domURL from WorkerGlobalScope
3326         https://bugs.webkit.org/show_bug.cgi?id=118784
3327
3328         Reviewed by Christophe Dumez.
3329
3330         WorkerContext::webkitURL() was removed in r107082, and this was the
3331         only place where the member variable |m_domURL| in WorkerContext was
3332         mutated. This variable is no longer needed and so it should be removed.
3333
3334         No behavior change.
3335
3336         * workers/WorkerGlobalScope.h:
3337
3338 2013-07-17  Mihai Maerean  <mmaerean@adobe.com>
3339
3340         ASSERTION FAILED: layoutState->m_renderer == this in WebCore::RenderBlock::offsetFromLogicalTopOfFirstPage
3341         https://bugs.webkit.org/show_bug.cgi?id=118587
3342
3343         Reviewed by David Hyatt.
3344
3345         The fix consists in not calling containingBlockLogicalHeightForPositioned for flow threads (in
3346         RenderBox::availableLogicalHeightUsing) as it gets to handle the RenderView as it would have been flowed into
3347         the flow thread.
3348
3349         Test: fast/regions/crash-div-outside-body-vertical-rl.html
3350
3351         * rendering/RenderBox.cpp:
3352         (WebCore::RenderBox::availableLogicalHeightUsing):
3353
3354 2013-07-17  Kangil Han  <kangil.han@samsung.com>
3355
3356         Use toHTMLMediaElement
3357         https://bugs.webkit.org/show_bug.cgi?id=118727
3358
3359         Reviewed by Ryosuke Niwa.
3360
3361         To avoid direct use of static_cast, this patch uses toHTMLMediaElement for code cleanup.
3362
3363         * bindings/js/JSHTMLMediaElementCustom.cpp:
3364         (WebCore::JSHTMLMediaElement::setController):
3365         * html/HTMLMediaElement.h:
3366         (WebCore::toHTMLMediaElement):
3367         * html/HTMLSourceElement.cpp:
3368         (WebCore::HTMLSourceElement::insertedInto):
3369         (WebCore::HTMLSourceElement::removedFrom):
3370         * html/HTMLTrackElement.cpp:
3371         (WebCore::HTMLTrackElement::removedFrom):
3372         (WebCore::HTMLTrackElement::mediaElement):
3373         * html/shadow/MediaControlElementTypes.cpp:
3374         (WebCore::toParentMediaElement):
3375         * loader/SubframeLoader.cpp:
3376         (WebCore::SubframeLoader::loadMediaPlayerProxyPlugin):
3377         * page/FrameView.cpp:
3378         (WebCore::FrameView::updateWidget):
3379         * platform/efl/RenderThemeEfl.cpp:
3380         (WebCore::RenderThemeEfl::paintMediaFullscreenButton):
3381         (WebCore::RenderThemeEfl::paintMediaMuteButton):
3382         (WebCore::RenderThemeEfl::paintMediaToggleClosedCaptionsButton):
3383         * platform/graphics/wince/MediaPlayerProxy.cpp:
3384         (WebCore::WebMediaPlayerProxy::initEngine):
3385         (WebCore::WebMediaPlayerProxy::element):
3386         * platform/gtk/RenderThemeGtk.cpp:
3387         (WebCore::getMediaElementFromRenderObject):
3388         * rendering/HitTestResult.cpp:
3389         (WebCore::HitTestResult::mediaElement):
3390         * rendering/RenderLayerBacking.cpp:
3391         (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration):
3392         * rendering/RenderLayerCompositor.cpp:
3393         (WebCore::RenderLayerCompositor::requiresCompositingForVideo):
3394         * rendering/RenderMedia.cpp:
3395         (WebCore::RenderMedia::mediaElement):
3396         * rendering/RenderThemeMac.mm:
3397         (WebCore::RenderThemeMac::paintMediaSliderTrack):
3398         * rendering/RenderThemeWinCE.cpp:
3399         (WebCore::mediaElementParent):
3400         * testing/Internals.cpp:
3401         (WebCore::Internals::simulateAudioInterruption):
3402
3403 2013-07-16  Ryuan Choi  <ryuan.choi@samsung.com>
3404
3405         Remove Platform(EFL) guard from Widget::frameRectsChanged
3406         https://bugs.webkit.org/show_bug.cgi?id=118782
3407
3408         Reviewed by Christophe Dumez.
3409
3410         Since r58487, Widget::frameRectsChanged was moved to cpp and guarded.
3411         But we can move back to header because WebKit/Efl refactored related code in r145710.
3412
3413         No new tests, refactoring.
3414
3415         * platform/Widget.cpp: Removed platform guard and move frameRectsChangd() back to header.
3416         * platform/Widget.h:
3417         (WebCore::Widget::frameRectsChanged):
3418         * platform/efl/WidgetEfl.cpp:
3419
3420 2013-07-16  Alex Christensen  <achristensen@apple.com>
3421
3422         Update ANGLE to r2426.
3423         https://bugs.webkit.org/show_bug.cgi?id=118550
3424
3425         Reviewed by Dean Jackson.
3426
3427         * CMakeLists.txt: Renamed DetectRecursion to DetectCallDepth and added builtin_symbol_table.
3428
3429 2013-07-16  Tim Horton  <timothy_horton@apple.com>
3430
3431         Many crashes loading Java applets after r152701
3432         https://bugs.webkit.org/show_bug.cgi?id=118760
3433         <rdar://problem/14462836>
3434
3435         Reviewed by Dean Jackson.
3436
3437         * html/HTMLAppletElement.cpp:
3438         (WebCore::HTMLAppletElement::updateWidget):
3439         Re-acquire the renderer after calling createJavaAppletWidget,
3440         because it can cause reattach, leaving our renderer pointer stale.
3441
3442         * loader/SubframeLoader.cpp:
3443         (WebCore::SubframeLoader::createJavaAppletWidget):
3444         Null-check renderer, as element->renderEmbeddedObject() can very clearly
3445         return null in some cases.
3446
3447 2013-07-16  Pratik Solanki  <psolanki@apple.com>
3448
3449         Missing break in WebGLRenderingContext::validateCompressedTexFuncData()
3450         https://bugs.webkit.org/show_bug.cgi?id=118742
3451
3452         Reviewed by Ryosuke Niwa.
3453
3454         * html/canvas/WebGLRenderingContext.cpp:
3455         (WebCore::WebGLRenderingContext::validateCompressedTexFuncData):
3456
3457 2013-07-16  Andreas Kling  <akling@apple.com>
3458